diff --git a/deploy-stg.sh b/deploy-stg.sh new file mode 100644 index 0000000..b62a27d --- /dev/null +++ b/deploy-stg.sh @@ -0,0 +1,7 @@ +BASEDIR=$(dirname "$0") + +npx webpack --mode production --progress || exit $? + +rsync -azv $BASEDIR/public/* system-praktyk@kadet.net:~/stg/front +rsync -azv $BASEDIR/build/* system-praktyk@kadet.net:~/stg/front + diff --git a/src/api/type.ts b/src/api/type.ts index aa6c577..08ad36f 100644 --- a/src/api/type.ts +++ b/src/api/type.ts @@ -2,7 +2,7 @@ import { InternshipType } from "@/data"; import { axios } from "@/api/index"; import { InternshipTypeDTO, internshipTypeDtoTransformer } from "@/api/dto/type"; -const AVAILABLE_INTERNSHIP_TYPES = '/internshipTypes'; +const AVAILABLE_INTERNSHIP_TYPES = '/internshipTypes/current'; export async function available(): Promise { const response = await axios.get(AVAILABLE_INTERNSHIP_TYPES); diff --git a/src/app.tsx b/src/app.tsx index dc69b6d..47d9ad6 100644 --- a/src/app.tsx +++ b/src/app.tsx @@ -98,9 +98,12 @@ function App() {
{ - { routes.map(({ name, content, middlewares = [], ...route }) => - { processMiddlewares([ ...middlewares, content ]) } - ) } + { routes.map(({ name, content, middlewares = [], ...route }) => + { + const Next = () => processMiddlewares([ ...middlewares, content ]) + return + } } /> + ) } }