From f465635b3926c74ab4d002848c94afb3d186e572 Mon Sep 17 00:00:00 2001 From: dinesh Date: Wed, 1 May 2024 11:18:45 -0700 Subject: [PATCH 01/11] exam search dropdown --- frontend/package-lock.json | 62 +++++++++++++++++++ frontend/package.json | 9 +-- .../exams/add-exam-form-components.ts | 52 ++++++++-------- .../src/components/exams/add-exam-modal.vue | 2 +- frontend/src/main.ts | 5 ++ frontend/src/utils/config-helper.ts | 15 +++++ 6 files changed, 115 insertions(+), 30 deletions(-) diff --git a/frontend/package-lock.json b/frontend/package-lock.json index 9d763102f..cb7916650 100644 --- a/frontend/package-lock.json +++ b/frontend/package-lock.json @@ -5463,8 +5463,12 @@ "version": "1.0.3", "resolved": "https://registry.npmjs.org/aes-decrypter/-/aes-decrypter-1.0.3.tgz", "integrity": "sha512-rsx8pfx7wJsn+ziYbpJ8XA5c93hKAtBCrfydxJqJCMT+qfjipd/B5wC2xHtBcoxyvlqJcpeAo3K55t0lXOn9yQ==", +<<<<<<< HEAD "license": "Apache-2.0", "dependencies": { +======= + "requires": { +>>>>>>> 15da563c (exam search dropdown) "pkcs7": "^0.2.3" } }, @@ -13170,10 +13174,23 @@ "version": "4.3.2", "resolved": "https://registry.npmjs.org/global/-/global-4.3.2.tgz", "integrity": "sha512-/4AybdwIDU4HkCUbJkZdWpe4P6vuw/CUtu+0I1YlLIPe7OlUO7KNJ+q/rO70CW2/NW6Jc6I62++Hzsf5Alu6rQ==", +<<<<<<< HEAD "license": "MIT", "dependencies": { "min-document": "^2.19.0", "process": "~0.5.1" +======= + "requires": { + "min-document": "^2.19.0", + "process": "~0.5.1" + }, + "dependencies": { + "process": { + "version": "0.5.2", + "resolved": "https://registry.npmjs.org/process/-/process-0.5.2.tgz", + "integrity": "sha512-oNpcutj+nYX2FjdEW7PGltWhXulAnFlM0My/k48L90hARCOJtvBbQXc/6itV2jDvU5xAAtonP+r6wmQgCcbAUA==" + } +>>>>>>> 15da563c (exam search dropdown) } }, "node_modules/global-dirs": { @@ -18119,8 +18136,12 @@ "node_modules/m3u8-parser": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/m3u8-parser/-/m3u8-parser-2.1.0.tgz", +<<<<<<< HEAD "integrity": "sha512-WbEpQ2FUaNGbJ0YanSeyj9D9ruu4FUvz+ZvebIzI2bSME+PUwcPXO1kKXZkjcPUAFruDikoOI5fWQNIA6JCCOQ==", "license": "Apache-2.0" +======= + "integrity": "sha512-WbEpQ2FUaNGbJ0YanSeyj9D9ruu4FUvz+ZvebIzI2bSME+PUwcPXO1kKXZkjcPUAFruDikoOI5fWQNIA6JCCOQ==" +>>>>>>> 15da563c (exam search dropdown) }, "node_modules/magic-string": { "version": "0.30.10", @@ -18466,7 +18487,11 @@ "version": "2.19.0", "resolved": "https://registry.npmjs.org/min-document/-/min-document-2.19.0.tgz", "integrity": "sha512-9Wy1B3m3f66bPPmU5hdA4DR4PB2OfDU/+GS3yAB7IQozE3tqXaVv2zOjgla7MEGSRv95+ILmOuvhLkOK6wJtCQ==", +<<<<<<< HEAD "dependencies": { +======= + "requires": { +>>>>>>> 15da563c (exam search dropdown) "dom-walk": "^0.1.0" } }, @@ -20146,6 +20171,7 @@ "node_modules/pkcs7": { "version": "0.2.3", "resolved": "https://registry.npmjs.org/pkcs7/-/pkcs7-0.2.3.tgz", +<<<<<<< HEAD "integrity": "sha512-kJRwmADEQUg+qJyRgWLtpEL9q9cFjZschejTEK3GRjKvnsU9G5WWoe/wKqRgbBoqWdVSeTUKP6vIA3Y72M3rWA==", "license": "Apache2", "bin": { @@ -20155,6 +20181,9 @@ "node": "^0.10", "npm": "^1.4.6" } +======= + "integrity": "sha512-kJRwmADEQUg+qJyRgWLtpEL9q9cFjZschejTEK3GRjKvnsU9G5WWoe/wKqRgbBoqWdVSeTUKP6vIA3Y72M3rWA==" +>>>>>>> 15da563c (exam search dropdown) }, "node_modules/pkg-dir": { "version": "3.0.0", @@ -21972,8 +22001,12 @@ "version": "1.0.0", "resolved": "https://registry.npmjs.org/rust-result/-/rust-result-1.0.0.tgz", "integrity": "sha512-6cJzSBU+J/RJCF063onnQf0cDUOHs9uZI1oroSGnHOph+CQTIJ5Pp2hK5kEQq1+7yE/EEWfulSNXAQ2jikPthA==", +<<<<<<< HEAD "license": "MIT", "dependencies": { +======= + "requires": { +>>>>>>> 15da563c (exam search dropdown) "individual": "^2.0.0" } }, @@ -22036,7 +22069,11 @@ "version": "4.0.0", "resolved": "https://registry.npmjs.org/safe-json-parse/-/safe-json-parse-4.0.0.tgz", "integrity": "sha512-RjZPPHugjK0TOzFrLZ8inw44s9bKox99/0AZW9o/BEQVrJfhI+fIHMErnPyRa89/yRXUUr93q+tiN6zhoVV4wQ==", +<<<<<<< HEAD "dependencies": { +======= + "requires": { +>>>>>>> 15da563c (exam search dropdown) "rust-result": "^1.0.0" } }, @@ -24021,9 +24058,13 @@ "node_modules/tsml": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/tsml/-/tsml-1.0.1.tgz", +<<<<<<< HEAD "integrity": "sha512-3KmepnH9SUsoOVtg013CRrL7c+AK7ECaquAsJdvu4288EDJuraqBlP4PDXT/rLEJ9YDn4jqLAzRJsnFPx+V6lg==", "deprecated": "no longer maintained", "license": "MIT" +======= + "integrity": "sha512-3KmepnH9SUsoOVtg013CRrL7c+AK7ECaquAsJdvu4288EDJuraqBlP4PDXT/rLEJ9YDn4jqLAzRJsnFPx+V6lg==" +>>>>>>> 15da563c (exam search dropdown) }, "node_modules/tsutils": { "version": "3.21.0", @@ -24704,8 +24745,12 @@ "node_modules/videojs-font": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/videojs-font/-/videojs-font-2.1.0.tgz", +<<<<<<< HEAD "integrity": "sha512-zFqWpLrXf1q8NtYx5qtZhMC6SLUFScDmR6j+UGPogobxR21lvXShhnzcNNMdOxJUuFLiToJ/BPpFUQwX4xhpvA==", "license": "Apache-2.0" +======= + "integrity": "sha512-zFqWpLrXf1q8NtYx5qtZhMC6SLUFScDmR6j+UGPogobxR21lvXShhnzcNNMdOxJUuFLiToJ/BPpFUQwX4xhpvA==" +>>>>>>> 15da563c (exam search dropdown) }, "node_modules/videojs-hotkeys": { "version": "0.2.28", @@ -24717,8 +24762,12 @@ "version": "1.1.2", "resolved": "https://registry.npmjs.org/videojs-ie8/-/videojs-ie8-1.1.2.tgz", "integrity": "sha512-0Zb2T4MLkpfZbeGMK/Z93b8Lrepr+rLFoHgQV1CoDeFqXvH7b+Vsd/VHoILGxQrgCSHFQ7mAODR6oyMjuiD4/g==", +<<<<<<< HEAD "license": "Apache 2.0", "dependencies": { +======= + "requires": { +>>>>>>> 15da563c (exam search dropdown) "es5-shim": "^4.5.1" } }, @@ -24974,7 +25023,16 @@ "integrity": "sha512-RRQNLT8Mzr8z7eL4p7BtKvRaTSGdCbTy2+Mm5HTJvLGYSSeG9gDzNasJPP/yOYKLy+/cLG/ftrqq5fvkFwBJEw==", "license": "MIT" }, +<<<<<<< HEAD "node_modules/vue-select": { +======= + "vue-search-select": { + "version": "2.9.6", + "resolved": "https://registry.npmjs.org/vue-search-select/-/vue-search-select-2.9.6.tgz", + "integrity": "sha512-N9EWEgmH1m1a3hL+KSCuIXlOKILFi3uXJVCRx3Fcmi93S2nNqWZuXeH/iuXijPjJEfIGTiRq7hc+N6ifqdrl0Q==" + }, + "vue-select": { +>>>>>>> 15da563c (exam search dropdown) "version": "3.20.3", "resolved": "https://registry.npmjs.org/vue-select/-/vue-select-3.20.3.tgz", "integrity": "sha512-aDaq4rPBrDavh7NDLgAP8e0G8UNElh6vO3itGWjhf1y9KaGRWtFw21cUkSRHGgj0V5FlCG4EaRb1xdE/C9J+eg==", @@ -25949,8 +26007,12 @@ "version": "2.4.0", "resolved": "https://registry.npmjs.org/xhr/-/xhr-2.4.0.tgz", "integrity": "sha512-TUbBsdAuJbX8olk9hsDwGK8P1ri1XlV+PdEWkYw+HQQbpkiBR8PLgD1F3kQDPBs9l4Px34hP9rCYAZOCCAENbw==", +<<<<<<< HEAD "license": "MIT", "dependencies": { +======= + "requires": { +>>>>>>> 15da563c (exam search dropdown) "global": "~4.3.0", "is-function": "^1.0.1", "parse-headers": "^2.0.0", diff --git a/frontend/package.json b/frontend/package.json index 0c62de7d2..253797226 100644 --- a/frontend/package.json +++ b/frontend/package.json @@ -33,8 +33,8 @@ "bootstrap-vue": "^2.22.0", "buefy": "^0.9.21", "buffer": "^6.0.3", - "camunda-formio-tasklist-vue": "1.0.18", - "core-js": "^3.9.1", + "camunda-formio-tasklist-vue": "^1.0.19", + "core-js": "3.9.1", "crypto-browserify": "^3.12.0", "es6-promise": "^4.2.8", "es6-shim": "^0.35.6", @@ -63,8 +63,9 @@ "vue-class-component": "^7.2.3", "vue-fragment": "^1.5.2", "vue-property-decorator": "^9.1.2", - "vue-router": "^3.5.1", - "vue-video-player": "^5.0.2", + "vue-router": "3.5.1", + "vue-search-select": "^2.9.6", + "vue-video-player": "5.0.2", "vue2-datepicker": "^3.11.0", "vue2-timepicker": "^1.1.6", "vuetify": "^2.6.10", diff --git a/frontend/src/components/exams/add-exam-form-components.ts b/frontend/src/components/exams/add-exam-form-components.ts index 6b7b93772..ca7440cdd 100644 --- a/frontend/src/components/exams/add-exam-form-components.ts +++ b/frontend/src/components/exams/add-exam-form-components.ts @@ -6,6 +6,7 @@ import { mapState } from 'vuex' import DatePicker from 'vue2-datepicker' import OfficeDrop from './office-drop.vue' import moment from 'moment' +import { ModelListSelect } from "vue-search-select" // Checkmark @Component({ @@ -182,7 +183,8 @@ export class DateQuestion extends Vue { // DropdownQuestion @Component({ components: { - Checkmark + Checkmark, + ModelListSelect }, computed: { ...mapState({ @@ -203,31 +205,21 @@ export class DateQuestion extends Vue {
- + +
+
-
- -
- ` }) @@ -261,10 +253,14 @@ export class DropdownQuestion extends Vue { @State('addExamModal') private addExamModal!: any @State('capturedExam') private capturedExam!: any @State('nonITAExam') private nonITAExam!: any + private objectItem:any = {}; @Mutation('setAddExamModalSetting') public setAddExamModalSetting: any get dropItems () { + this.objectItem = { + exam_type_id: this.capturedExam.exam_type_id + } const sorter = (a, b) => { const typeA = a.exam_type_name const typeB = b.exam_type_name @@ -306,6 +302,11 @@ export class DropdownQuestion extends Vue { } } + get selectedExam () { + console.log("sdfsdf"); + return this.capturedExam.exam_type_id ?? 0; + } + get inputText () { if (this.exam_object && this.exam_object.exam_type_name) { return this.exam_object.exam_type_name @@ -337,13 +338,14 @@ export class DropdownQuestion extends Vue { this.setAddExamModalSetting({ step1MenuOpen: false }) } - preHandleInput (id) { + preHandleInput (item) { this.handleInput({ target: { name: 'exam_type_id', - value: id + value: item.exam_type_id } }) + console.log("CAPTURED EXAM", item.exam_type_id); } } diff --git a/frontend/src/components/exams/add-exam-modal.vue b/frontend/src/components/exams/add-exam-modal.vue index 1d34c50cd..377c64fbc 100644 --- a/frontend/src/components/exams/add-exam-modal.vue +++ b/frontend/src/components/exams/add-exam-modal.vue @@ -9,7 +9,7 @@ @shown="initialize" @hidden="hideModal" :size="modalSize" - scrollable + style="overflow: visible !important;" >