Commit 5d5315b0f9af96cf1f42942a64f34694983def8b
1 parent
d84fa5db26
Exists in
master
and in
2 other branches
close add-notification dialogue box, hide delete option from teacher's list, han…
…dle password able/disable function in add student screen and show data of admit card and show messages if not available
Showing
6 changed files
with
63 additions
and
39 deletions
Show diff stats
src/Services/http.js
1 | 1 | import axios from 'axios' |
2 | 2 | import store from '@/store/store' |
3 | 3 | import Vue from 'vue' |
4 | -import {vm1} from "@/main.js" | |
4 | +import { vm1 } from "@/main.js" | |
5 | 5 | |
6 | 6 | const baseDomain = "https://api-dashboard.intrack.in/v1"; |
7 | 7 | |
... | ... | @@ -45,29 +45,31 @@ export default () => { |
45 | 45 | return Promise.reject(error) |
46 | 46 | }) |
47 | 47 | instance.interceptors.response.use((response) => { |
48 | - // do something with the response data | |
48 | + // do something with the response data | |
49 | 49 | |
50 | 50 | |
51 | - return response; | |
52 | - }, error => { | |
53 | - // handle the response error | |
54 | - console.log("error in interceptor - ",error.response.status) | |
55 | - var customError | |
56 | - const errorNo = error.response.status | |
51 | + return response; | |
52 | + }, error => { | |
53 | + // handle the response error | |
54 | + console.log("error in interceptor - ", error.response.status) | |
55 | + var customError | |
56 | + const errorNo = error.response.status | |
57 | 57 | |
58 | - switch (errorNo) { | |
59 | - case 401: | |
60 | - customError = "Session expired" | |
61 | - console.log("what is this - ", vm1) | |
62 | - vm1.$store.dispatch("setToken", null); | |
63 | - vm1.$router.replace({ path: "/" }); | |
64 | - | |
65 | - vm1.$store.dispatch("Id", null); | |
66 | - | |
67 | - break; | |
68 | - } | |
69 | - }) | |
70 | - // response parse | |
58 | + switch (errorNo) { | |
59 | + case 401: | |
60 | + customError = "Session expired" | |
61 | + console.log("what is this - ", vm1) | |
62 | + vm1.$store.dispatch("setToken", null); | |
63 | + vm1.$router.replace({ path: "/" }); | |
64 | + | |
65 | + vm1.$store.dispatch("Id", null); | |
66 | + | |
67 | + break; | |
68 | + } | |
69 | + | |
70 | + return Promise.reject(error); | |
71 | + }) | |
72 | + // response parse | |
71 | 73 | |
72 | 74 | return instance; |
73 | 75 | } |
74 | 76 | \ No newline at end of file | ... | ... |
src/pages/Notification/notification.vue
src/pages/Parent/parents.vue
... | ... | @@ -700,6 +700,7 @@ |
700 | 700 | :type="e1 ? 'password' : 'text'" |
701 | 701 | :rules="password" |
702 | 702 | placeholder="Enter Your Password" |
703 | + :disabled="isFatherCellExists" | |
703 | 704 | required |
704 | 705 | ></v-text-field> |
705 | 706 | </v-flex> |
... | ... | @@ -986,7 +987,8 @@ export default { |
986 | 987 | }, |
987 | 988 | editMpin: { |
988 | 989 | mPin: "" |
989 | - } | |
990 | + }, | |
991 | + isFatherCellExists: false | |
990 | 992 | }), |
991 | 993 | watch: { |
992 | 994 | menu(val) { |
... | ... | @@ -1085,6 +1087,7 @@ export default { |
1085 | 1087 | this.getParentDetails(); |
1086 | 1088 | this.clear(); |
1087 | 1089 | this.loading = false; |
1090 | + this.isFatherCellExists = true; | |
1088 | 1091 | this.addParentDialog = false; |
1089 | 1092 | }) |
1090 | 1093 | .catch(error => { | ... | ... |
src/pages/Report/admitCard.vue
... | ... | @@ -83,7 +83,7 @@ |
83 | 83 | v-model="getReport.form" |
84 | 84 | item-text="name" |
85 | 85 | item-value="value" |
86 | - @change="getReport(getReport.form)" | |
86 | + | |
87 | 87 | required |
88 | 88 | ></v-autocomplete> |
89 | 89 | </v-flex> |
... | ... | @@ -148,8 +148,7 @@ |
148 | 148 | </div> |
149 | 149 | </v-flex> |
150 | 150 | <v-flex xs4 style="text-align:center;margin-bottom:0px"> |
151 | - <!-- {{userData.profilePicUrl}} --> | |
152 | - <img | |
151 | + <!-- <img | |
153 | 152 | v-if="getScheduleList.studentData.profilePicUrl" |
154 | 153 | :src="getScheduleList.studentData.profilePicUrl" |
155 | 154 | style="widht:80px;height:80px;" |
... | ... | @@ -158,7 +157,18 @@ |
158 | 157 | v-if="!getScheduleList.studentData.profilePicUrl" |
159 | 158 | src="/static/icon/user.png" |
160 | 159 | style="widht:80px;" |
161 | - /> | |
160 | + /> --> | |
161 | + <img | |
162 | + src="/static/icon/user.png" | |
163 | + v-if="!getScheduleList.studentData.profilePicUrl" | |
164 | + width="80" | |
165 | + /> | |
166 | + <img | |
167 | + :src="getScheduleList.studentData.profilePicUrl" | |
168 | + onerror="this.src='/static/icon/user.png';" | |
169 | + v-if="getScheduleList.studentData.profilePicUrl" | |
170 | + width="80" | |
171 | + /> | |
162 | 172 | </v-flex> |
163 | 173 | </v-layout> |
164 | 174 | <v-layout> |
... | ... | @@ -388,6 +398,7 @@ export default { |
388 | 398 | getStudentsList: [], |
389 | 399 | getScheduleList: [], |
390 | 400 | getScheduleListArray: [], |
401 | + getReport: {}, | |
391 | 402 | examName: [], |
392 | 403 | typeList: [ |
393 | 404 | { |
... | ... | @@ -442,16 +453,6 @@ export default { |
442 | 453 | }, |
443 | 454 | |
444 | 455 | methods: { |
445 | - getReport() { | |
446 | - if (this.getReport.form === "frontPart") { | |
447 | - this.frontPart = true; | |
448 | - this.backPart = false; | |
449 | - } | |
450 | - if (this.getReport.form === "backPart") { | |
451 | - this.frontPart = false; | |
452 | - this.backPart = true; | |
453 | - } | |
454 | - }, | |
455 | 456 | getExamList() { |
456 | 457 | this.showLoader = true; |
457 | 458 | this.loadingSearch = true; |
... | ... | @@ -543,7 +544,21 @@ export default { |
543 | 544 | .then(response => { |
544 | 545 | this.showTable = true; |
545 | 546 | this.getScheduleList = response.data.data; |
547 | + if (response.data.data.scheduleData.length === 0) { | |
548 | + this.showLoader = false; | |
549 | + this.snackbar = true; | |
550 | + this.text = 'Student not found!'; | |
551 | + return; | |
552 | + } | |
546 | 553 | this.showData = true; |
554 | + if (this.getReport.form === "frontPart") { | |
555 | + this.frontPart = true; | |
556 | + this.backPart = false; | |
557 | + } | |
558 | + if (this.getReport.form === "backPart") { | |
559 | + this.frontPart = false; | |
560 | + this.backPart = true; | |
561 | + } | |
547 | 562 | this.showLoader = false; |
548 | 563 | }) |
549 | 564 | .catch(error => { | ... | ... |
src/pages/Students/students.vue
... | ... | @@ -1322,6 +1322,7 @@ |
1322 | 1322 | :rules="password" |
1323 | 1323 | v-model="parentData.password" |
1324 | 1324 | placeholder="Enter Your Password" |
1325 | + :disabled="isFatherCellExists" | |
1325 | 1326 | required |
1326 | 1327 | ></v-text-field> |
1327 | 1328 | </v-flex> |
... | ... | @@ -2053,7 +2054,8 @@ export default { |
2053 | 2054 | weight: "", |
2054 | 2055 | rollNo: "", |
2055 | 2056 | establishmentYear: new Date().getFullYear() |
2056 | - } | |
2057 | + }, | |
2058 | + isFatherCellExists: false | |
2057 | 2059 | }), |
2058 | 2060 | watch: { |
2059 | 2061 | menu(val) { |
... | ... | @@ -2388,6 +2390,7 @@ export default { |
2388 | 2390 | this.parentData = response.data.data; |
2389 | 2391 | this.parentId = response.data.data._id; |
2390 | 2392 | this.showLoader = false; |
2393 | + this.isFatherCellExists = true; | |
2391 | 2394 | }) |
2392 | 2395 | .catch(error => { |
2393 | 2396 | console.log("err====>", error.response.data.message); | ... | ... |
src/pages/Teachers/teachers.vue
... | ... | @@ -540,7 +540,7 @@ |
540 | 540 | /> |
541 | 541 | <span>Edit</span> |
542 | 542 | </v-tooltip> |
543 | - <v-tooltip top v-if="role != 'TEACHER' "> | |
543 | + <!-- <v-tooltip top v-if="role != 'TEACHER' "> | |
544 | 544 | <img |
545 | 545 | slot="activator" |
546 | 546 | style="cursor:pointer; width:20px; height:20px; " |
... | ... | @@ -549,7 +549,7 @@ |
549 | 549 | class="mr-3" |
550 | 550 | /> |
551 | 551 | <span>Delete</span> |
552 | - </v-tooltip> | |
552 | + </v-tooltip> --> | |
553 | 553 | </span> |
554 | 554 | </td> |
555 | 555 | </tr> | ... | ... |