Skip to content

Commit

Permalink
ccfri-3756 - lock AFS page after submit
Browse files Browse the repository at this point in the history
  • Loading branch information
vietle-cgi committed Nov 26, 2024
1 parent 0dc1b99 commit 9c8fc68
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,12 @@
<div class="mb-2">Please select one of the following options regarding the approvable fee schedule:</div>
<v-radio-group v-model="updatedValue" :rules="rules.required" :disabled="readonly" color="primary">
<v-radio label="I accept" :value="AFS_STATUSES.ACCEPT" />
<div v-if="updatedValue === AFS_STATUSES.ACCEPT" class="text-body-2 pl-2">
<div v-if="!readonly && updatedValue === AFS_STATUSES.ACCEPT" class="text-body-2 pl-2">
After submission please wait to receive notification confirming your approval to participate in CCFRI.
</div>
<v-radio label="I want to upload supporting documents" :value="AFS_STATUSES.UPLOAD_DOCUMENTS" />
<v-radio label="I decline" :value="AFS_STATUSES.DECLINE" />
<div v-if="updatedValue === AFS_STATUSES.DECLINE" class="text-body-2 pl-2">
<div v-if="!readonly && updatedValue === AFS_STATUSES.DECLINE" class="text-body-2 pl-2">
After submission please wait to receive confirmation from the ministry on the results of your CCFRI application.
</div>
</v-radio-group>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -67,10 +67,11 @@
</div>
<v-skeleton-loader :loading="isEmpty(afs)" type="table-tbody">
<v-container fluid class="pa-0">
<AfsDecisionCard v-model="afs.afsStatus" />
<AfsDecisionCard v-model="afs.afsStatus" :readonly="isReadOnly" />
<AppDocumentUpload
v-if="afs?.afsStatus === AFS_STATUSES.UPLOAD_DOCUMENTS"
:loading="isLoading"
:readonly="isReadOnly"
:uploaded-documents="filteredUploadedDocuments"
:document-type="DOCUMENT_TYPES.APPLICATION_AFS"
:show-error-message="showErrorMessage && !isSupportingDocumentsUploaded"
Expand Down Expand Up @@ -213,7 +214,6 @@ export default {
back() {
this.$router.push(this.previousPath);
},
// TODO (vietle-cgi) - CCFRI-3756 - work in progress
async save(showMessage) {
try {
if (this.isReadOnly) return;
Expand Down
7 changes: 4 additions & 3 deletions frontend/src/components/util/AppDocumentUpload.vue
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<template>
<v-form>
<template v-if="!readonly">
<template v-if="title">
<div class="mb-2">
<span class="text-h6 font-weight-bold mr-6">{{ title }}</span>
<span> (Required)</span>
Expand All @@ -10,16 +10,17 @@
xls, and xlsx.
</div>
</template>
<v-card elevation="2" :class="!readonly ? 'pa-4 my-4' : ''">
<v-card elevation="2" :class="!readonly ? 'pa-4 my-4' : 'pb-6'">
<AppButton
v-if="showAddFileButton"
id="add-new-file"
:primary="false"
size="large"
class="add-file-button"
@click="addFile"
>Add File</AppButton
>
Add File
</AppButton>
<div v-if="documents.length > 0" class="mt-6">
<v-row v-for="item in documents" :key="item.id" no-gutters>
<v-col cols="12" md="4" class="pr-4">
Expand Down

0 comments on commit 9c8fc68

Please sign in to comment.