File tree 4 files changed +9
-9
lines changed
4 files changed +9
-9
lines changed Original file line number Diff line number Diff line change @@ -20,13 +20,13 @@ COPY --from=builder /opt/app/node_modules /opt/app/node_modules
20
20
CMD node /opt/app/index.js
21
21
22
22
23
- FROM node:16 as dev
23
+ FROM node:lts-alpine as dev
24
24
25
25
ENV NODE_ENV development
26
26
27
- WORKDIR /soroka-backend
27
+ WORKDIR /opt/app
28
28
29
- COPY --from=builder /opt/app/ /soroka-backend
29
+ COPY --from=builder /opt/app/ /opt/app
30
30
31
31
RUN npm install
32
32
Original file line number Diff line number Diff line change 1
1
import React from 'react'
2
2
3
3
const ImportAction = ( ) => {
4
- async function submitForm ( form ) {
4
+ async function submitForm ( form : HTMLFormElement ) {
5
5
const formData = new FormData ( form )
6
6
7
7
const response = await fetch (
@@ -24,7 +24,7 @@ const ImportAction = () => {
24
24
style = { { display : "flex" , flexDirection : "column" } }
25
25
onSubmit = { ( event ) => {
26
26
event . preventDefault ( )
27
- submitForm ( event . target )
27
+ submitForm ( event . currentTarget )
28
28
} }
29
29
>
30
30
< label style = { { fontSize : "1.5rem" } } htmlFor = "csvFile" >
Original file line number Diff line number Diff line change 1
1
import AdminJS from 'adminjs'
2
2
import AdminJSExpress from '@adminjs/express'
3
- import AdminJSSequelize = require ( '@adminjs/sequelize' )
3
+ import * as AdminJSSequelize from '@adminjs/sequelize'
4
4
import sequelize from '../../providers/db'
5
5
6
6
AdminJS . registerAdapter ( AdminJSSequelize )
@@ -36,7 +36,7 @@ const adminJs = new AdminJS({
36
36
icon : 'Upload' ,
37
37
isVisible : true ,
38
38
handler : async ( ) => { console . log ( ) } ,
39
- component : AdminJS . bundle ( '../../admin/components/import-action-component.jsx ' ) ,
39
+ component : AdminJS . bundle ( '../../admin/components/import-action-component' ) ,
40
40
} ,
41
41
} ,
42
42
} ,
Original file line number Diff line number Diff line change 7
7
"esModuleInterop" : true ,
8
8
"strictPropertyInitialization" : false ,
9
9
"experimentalDecorators" : true ,
10
- "emitDecoratorMetadata" : true
10
+ "emitDecoratorMetadata" : true ,
11
+ "jsx" : " react"
11
12
}
12
13
}
13
-
You can’t perform that action at this time.
0 commit comments