diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 00000000..d02bc726 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,33 @@ +# Build Stage +FROM node:20-alpine AS build-stage + +# Set the working directory inside the container +WORKDIR /app + +# Enable pnpm using corepack +RUN corepack enable + +# Copy pnpm related files and package.json to leverage Docker layer caching +COPY package.json pnpm-lock.yaml ./ + +# Install dependencies using pnpm +# Using --frozen-lockfile ensures consistent installations based on pnpm-lock.yaml +RUN --mount=type=cache,id=pnpm-store,target=/root/.pnpm-store pnpm install --frozen-lockfile + +# Copy the rest of the application files +COPY . . + +# Build the Vue.js application for production +RUN pnpm build + +# Production Stage +FROM nginx:stable-alpine AS production-stage + +# Copy the built Vue.js application from the build stage to Nginx's web root +COPY --from=build-stage /app/dist /usr/share/nginx/html + +# Expose port 80 for Nginx +EXPOSE 80 + +# Command to run Nginx in the foreground +CMD ["nginx", "-g", "daemon off;"] diff --git a/app/components/app/encounter/dropdown-action.vue b/app/components/app/encounter/dropdown-action.vue index 0815e6a7..8cd656a7 100644 --- a/app/components/app/encounter/dropdown-action.vue +++ b/app/components/app/encounter/dropdown-action.vue @@ -89,10 +89,10 @@ function proceedItem(action: string) { function getLinks() { switch (activeServicePosition.value) { - case 'medical': + case 'med': linkItemsFiltered.value = baseLinkItems.filter((item) => item.groups?.includes('medical')) break - case 'registration': + case 'reg': linkItemsFiltered.value = baseLinkItems.filter((item) => item.groups?.includes('registration')) break default: diff --git a/app/components/content/device-order/list.vue b/app/components/content/device-order/list.vue index 1ffa324d..e5cc455b 100644 --- a/app/components/content/device-order/list.vue +++ b/app/components/content/device-order/list.vue @@ -28,6 +28,7 @@ import ConfirmationInfo from '~/components/app/device-order/confirmation-info.vu // Props const props = defineProps<{ encounter_id: number + canUpdate?: boolean }>() const encounter_id = props.encounter_id @@ -153,7 +154,7 @@ function pickItem(): DeviceOrder | null { :pagination-meta="paginationMeta" @page-change="handlePageChange" /> -
() const route = useRoute() const type = computed(() => (route.query.menu as string) || 'early-medical-assessment') @@ -23,8 +31,9 @@ const ActiveForm = computed(() => formMap[type.value] || EarlyForm)