Commit 39a6d21a09a7e34f3563d641d8157b854a700ce6
1 parent
8e8d14254a
Exists in
master
and in
2 other branches
improve add student fuctionality in students screen while admin login and hide p…
…pt option from course detail while teacher login
Showing
2 changed files
with
7 additions
and
6 deletions
Show diff stats
src/pages/Course/courseDetail.vue
1 | <template> | 1 | <template> |
2 | <v-container fluid class="body-color"> | 2 | <v-container fluid class="body-color"> |
3 | <!-- ****** Edit Chapter detail ****** --> | 3 | <!-- ****** Edit Chapter detail ****** --> |
4 | <v-dialog v-model="editCourseDetailDialog" max-width="1000px" scrollable> | 4 | <v-dialog v-model="editCourseDetailDialog" max-width="1000px" scrollable> |
5 | <v-card class="card-style pa-2" dark> | 5 | <v-card class="card-style pa-2" dark> |
6 | <v-layout> | 6 | <v-layout> |
7 | <v-flex xs12> | 7 | <v-flex xs12> |
8 | <label class="title text-xs-center">Edit Chapter</label> | 8 | <label class="title text-xs-center">Edit Chapter</label> |
9 | <v-icon size="24" class="right" @click="editCourseDetailDialog = false">cancel</v-icon> | 9 | <v-icon size="24" class="right" @click="editCourseDetailDialog = false">cancel</v-icon> |
10 | </v-flex> | 10 | </v-flex> |
11 | </v-layout> | 11 | </v-layout> |
12 | <v-card-text> | 12 | <v-card-text> |
13 | <v-layout wrap> | 13 | <v-layout wrap> |
14 | <v-flex xs12 sm12> | 14 | <v-flex xs12 sm12> |
15 | <v-layout> | 15 | <v-layout> |
16 | <v-flex xs4 class="pt-4 subheading"> | 16 | <v-flex xs4 class="pt-4 subheading"> |
17 | <label class="right">Select Class:</label> | 17 | <label class="right">Select Class:</label> |
18 | </v-flex> | 18 | </v-flex> |
19 | <v-flex xs8 sm6 class="ml-3"> | 19 | <v-flex xs8 sm6 class="ml-3"> |
20 | <v-select | 20 | <v-select |
21 | small | 21 | small |
22 | :items="addclass" | 22 | :items="addclass" |
23 | label="Select Class" | 23 | label="Select Class" |
24 | v-model="editedCourse.classId" | 24 | v-model="editedCourse.classId" |
25 | item-text="classNum" | 25 | item-text="classNum" |
26 | item-value="_id" | 26 | item-value="_id" |
27 | name="Select Class" | 27 | name="Select Class" |
28 | @change="getCourses(editedCourse.classId)" | 28 | @change="getCourses(editedCourse.classId)" |
29 | class="mr-2" | 29 | class="mr-2" |
30 | required | 30 | required |
31 | ></v-select> | 31 | ></v-select> |
32 | </v-flex> | 32 | </v-flex> |
33 | </v-layout> | 33 | </v-layout> |
34 | </v-flex> | 34 | </v-flex> |
35 | <v-flex xs12 sm12> | 35 | <v-flex xs12 sm12> |
36 | <v-layout> | 36 | <v-layout> |
37 | <v-flex xs4 class="pt-4 subheading"> | 37 | <v-flex xs4 class="pt-4 subheading"> |
38 | <label class="right">Select Course:</label> | 38 | <label class="right">Select Course:</label> |
39 | </v-flex> | 39 | </v-flex> |
40 | <v-flex xs8 sm6 class="ml-3"> | 40 | <v-flex xs8 sm6 class="ml-3"> |
41 | <v-select | 41 | <v-select |
42 | :items="courseData" | 42 | :items="courseData" |
43 | label="Select Course" | 43 | label="Select Course" |
44 | v-model="editedCourse.courseId" | 44 | v-model="editedCourse.courseId" |
45 | item-text="courseName" | 45 | item-text="courseName" |
46 | item-value="_id" | 46 | item-value="_id" |
47 | required | 47 | required |
48 | class="ml-2" | 48 | class="ml-2" |
49 | ></v-select> | 49 | ></v-select> |
50 | </v-flex> | 50 | </v-flex> |
51 | </v-layout> | 51 | </v-layout> |
52 | </v-flex> | 52 | </v-flex> |
53 | </v-layout> | 53 | </v-layout> |
54 | <v-layout> | 54 | <v-layout> |
55 | <v-flex xs12 sm12 md11 lg11> | 55 | <v-flex xs12 sm12 md11 lg11> |
56 | <v-card-actions class="hidden-xs-only hidden-sm-only"> | 56 | <v-card-actions class="hidden-xs-only hidden-sm-only"> |
57 | <v-spacer></v-spacer> | 57 | <v-spacer></v-spacer> |
58 | <v-btn round dark @click="save" :loading="editLoading" class="add-button mr-4">Save</v-btn> | 58 | <v-btn round dark @click="save" :loading="editLoading" class="add-button mr-4">Save</v-btn> |
59 | </v-card-actions> | 59 | </v-card-actions> |
60 | <v-card-actions class="hidden-md-only hidden-lg-only hidden-xl-only"> | 60 | <v-card-actions class="hidden-md-only hidden-lg-only hidden-xl-only"> |
61 | <v-spacer></v-spacer> | 61 | <v-spacer></v-spacer> |
62 | <v-btn round dark @click="save" :loading="editLoading" class="add-button">Save</v-btn> | 62 | <v-btn round dark @click="save" :loading="editLoading" class="add-button">Save</v-btn> |
63 | <v-spacer></v-spacer> | 63 | <v-spacer></v-spacer> |
64 | </v-card-actions> | 64 | </v-card-actions> |
65 | </v-flex> | 65 | </v-flex> |
66 | </v-layout> | 66 | </v-layout> |
67 | </v-card-text> | 67 | </v-card-text> |
68 | </v-card> | 68 | </v-card> |
69 | </v-dialog> | 69 | </v-dialog> |
70 | <!-- DIALOG BOX - EDIT CHAPTER--> | 70 | <!-- DIALOG BOX - EDIT CHAPTER--> |
71 | <v-dialog v-model="editChapterDetailDialog" max-width="1000px" scrollable> | 71 | <v-dialog v-model="editChapterDetailDialog" max-width="1000px" scrollable> |
72 | <v-card class="card-style pa-2" dark> | 72 | <v-card class="card-style pa-2" dark> |
73 | <v-layout> | 73 | <v-layout> |
74 | <v-flex xs12> | 74 | <v-flex xs12> |
75 | <label class="title text-xs-center">Edit Chapter</label> | 75 | <label class="title text-xs-center">Edit Chapter</label> |
76 | <v-icon | 76 | <v-icon |
77 | size="24" | 77 | size="24" |
78 | class="right" | 78 | class="right" |
79 | @click="editChapterDetailDialog = false; trigger = 'reset'; emptyPdf = 'reset' " | 79 | @click="editChapterDetailDialog = false; trigger = 'reset'; emptyPdf = 'reset' " |
80 | >cancel</v-icon> | 80 | >cancel</v-icon> |
81 | </v-flex> | 81 | </v-flex> |
82 | </v-layout> | 82 | </v-layout> |
83 | <v-card-text> | 83 | <v-card-text> |
84 | <v-layout wrap> | 84 | <v-layout wrap> |
85 | <!-- CHAPTER NAME --> | 85 | <!-- CHAPTER NAME --> |
86 | <v-flex xs12 sm12> | 86 | <v-flex xs12 sm12> |
87 | <v-layout> | 87 | <v-layout> |
88 | <v-flex xs4 class="pt-4 subheading"> | 88 | <v-flex xs4 class="pt-4 subheading"> |
89 | <label class="right">Chapter Name:</label> | 89 | <label class="right">Chapter Name:</label> |
90 | </v-flex> | 90 | </v-flex> |
91 | <v-flex xs8 sm6 class="ml-3"> | 91 | <v-flex xs8 sm6 class="ml-3"> |
92 | <v-text-field | 92 | <v-text-field |
93 | v-model="editChapter.chapterName" | 93 | v-model="editChapter.chapterName" |
94 | placeholder="fill your Title" | 94 | placeholder="fill your Title" |
95 | type="text" | 95 | type="text" |
96 | required | 96 | required |
97 | ></v-text-field> | 97 | ></v-text-field> |
98 | </v-flex> | 98 | </v-flex> |
99 | </v-layout> | 99 | </v-layout> |
100 | </v-flex> | 100 | </v-flex> |
101 | <!-- DESCRIPTION --> | 101 | <!-- DESCRIPTION --> |
102 | <v-flex xs12 sm12> | 102 | <v-flex xs12 sm12> |
103 | <v-layout> | 103 | <v-layout> |
104 | <v-flex xs4 class="pt-4 subheading"> | 104 | <v-flex xs4 class="pt-4 subheading"> |
105 | <label class="right">Description:</label> | 105 | <label class="right">Description:</label> |
106 | </v-flex> | 106 | </v-flex> |
107 | <v-flex xs8 sm6 class="ml-3"> | 107 | <v-flex xs8 sm6 class="ml-3"> |
108 | <v-text-field | 108 | <v-text-field |
109 | placeholder="fill your Description" | 109 | placeholder="fill your Description" |
110 | v-model="editChapter.description" | 110 | v-model="editChapter.description" |
111 | type="text" | 111 | type="text" |
112 | required | 112 | required |
113 | ></v-text-field> | 113 | ></v-text-field> |
114 | </v-flex> | 114 | </v-flex> |
115 | </v-layout> | 115 | </v-layout> |
116 | </v-flex> | 116 | </v-flex> |
117 | <!-- UPLOAD PPT --> | 117 | <!-- UPLOAD PPT --> |
118 | <v-flex xs12> | 118 | <!-- <v-flex xs12> |
119 | <v-layout> | 119 | <v-layout> |
120 | <v-flex xs4 class="pt-4 subheading"> | 120 | <v-flex xs4 class="pt-4 subheading"> |
121 | <label class="right">Upload PPT:</label> | 121 | <label class="right">Upload PPT:</label> |
122 | </v-flex> | 122 | </v-flex> |
123 | <v-flex xs8 sm6 class="ml-3"> | 123 | <v-flex xs8 sm6 class="ml-3"> |
124 | <UploadFiles | 124 | <UploadFiles |
125 | @fileSelected="fileSelected($event,'uploadPPT')" | 125 | @fileSelected="fileSelected($event,'uploadPPT')" |
126 | label="Add PPT" | 126 | label="Add PPT" |
127 | reference="EditPpt" | 127 | reference="EditPpt" |
128 | id="editPptInput" | 128 | id="editPptInput" |
129 | :trigger="trigger" | 129 | :trigger="trigger" |
130 | ></UploadFiles> | 130 | ></UploadFiles> |
131 | </v-flex> | 131 | </v-flex> |
132 | </v-layout> | 132 | </v-layout> |
133 | </v-flex> | 133 | </v-flex>--> |
134 | <!-- UPLOAD PDF --> | 134 | <!-- UPLOAD PDF --> |
135 | <v-flex xs12> | 135 | <v-flex xs12> |
136 | <v-layout> | 136 | <v-layout> |
137 | <v-flex xs4 class="pt-4 subheading"> | 137 | <v-flex xs4 class="pt-4 subheading"> |
138 | <label class="right">Upload PDF:</label> | 138 | <label class="right">Upload PDF:</label> |
139 | </v-flex> | 139 | </v-flex> |
140 | <v-flex xs8 sm6 class="ml-3"> | 140 | <v-flex xs8 sm6 class="ml-3"> |
141 | <UploadPdf | 141 | <UploadPdf |
142 | @pdfFileSelected="pdfFileSelected($event,'uploadPDF')" | 142 | @pdfFileSelected="pdfFileSelected($event,'uploadPDF')" |
143 | label="Add PDF" | 143 | label="Add PDF" |
144 | reference="editPdf" | 144 | reference="editPdf" |
145 | id="editPdfInput" | 145 | id="editPdfInput" |
146 | :emptyPdf="emptyPdf" | 146 | :emptyPdf="emptyPdf" |
147 | ></UploadPdf> | 147 | ></UploadPdf> |
148 | </v-flex> | 148 | </v-flex> |
149 | </v-layout> | 149 | </v-layout> |
150 | </v-flex> | 150 | </v-flex> |
151 | </v-layout> | 151 | </v-layout> |
152 | <!-- <v-flex xs12 v-if="editChapter.chapterPoints.length != 0"> | 152 | <!-- <v-flex xs12 v-if="editChapter.chapterPoints.length != 0"> |
153 | <v-layout | 153 | <v-layout |
154 | wrap | 154 | wrap |
155 | v-for="(editChapterPoint,index) in editChapter.chapterPoints" | 155 | v-for="(editChapterPoint,index) in editChapter.chapterPoints" |
156 | :key="index" | 156 | :key="index" |
157 | > | 157 | > |
158 | <v-flex xs12 sm12 md4 class="pt-4 subheading"> | 158 | <v-flex xs12 sm12 md4 class="pt-4 subheading"> |
159 | <label class="right hidden-xs-only hidden-sm-only">Chapter Points:</label> | 159 | <label class="right hidden-xs-only hidden-sm-only">Chapter Points:</label> |
160 | <label class="hidden-md-only hidden-lg-only hidden-xl-only">Chapter Points:</label> | 160 | <label class="hidden-md-only hidden-lg-only hidden-xl-only">Chapter Points:</label> |
161 | </v-flex> | 161 | </v-flex> |
162 | <v-layout> | 162 | <v-layout> |
163 | <v-flex xs10 sm10 sm5 md9 class="ml-3"> | 163 | <v-flex xs10 sm10 sm5 md9 class="ml-3"> |
164 | <v-text-field :value="editChapterPoint" type="text" required></v-text-field> | 164 | <v-text-field :value="editChapterPoint" type="text" required></v-text-field> |
165 | </v-flex> | 165 | </v-flex> |
166 | <v-flex xs2 class="pt-4"> | 166 | <v-flex xs2 class="pt-4"> |
167 | <v-icon @click="deleteUrl(index)">cancel</v-icon> | 167 | <v-icon @click="deleteUrl(index)">cancel</v-icon> |
168 | </v-flex> | 168 | </v-flex> |
169 | </v-layout> | 169 | </v-layout> |
170 | </v-layout> | 170 | </v-layout> |
171 | </v-flex>--> | 171 | </v-flex>--> |
172 | <v-flex xs12> | 172 | <v-flex xs12> |
173 | <div v-for="(updateImage,index) in updates" :key="index"> | 173 | <div v-for="(updateImage,index) in updates" :key="index"> |
174 | <v-layout wrap> | 174 | <v-layout wrap> |
175 | <v-flex xs12 sm12 md4 class="pt-4 subheading"> | 175 | <v-flex xs12 sm12 md4 class="pt-4 subheading"> |
176 | <label class="right hidden-xs-only hidden-sm-only">Chapter Points:</label> | 176 | <label class="right hidden-xs-only hidden-sm-only">Chapter Points:</label> |
177 | <label class="hidden-md-only hidden-lg-only hidden-xl-only">Chapter Points:</label> | 177 | <label class="hidden-md-only hidden-lg-only hidden-xl-only">Chapter Points:</label> |
178 | </v-flex> | 178 | </v-flex> |
179 | <v-layout> | 179 | <v-layout> |
180 | <v-flex xs10 sm12 md9 class="ml-3"> | 180 | <v-flex xs10 sm12 md9 class="ml-3"> |
181 | <v-text-field | 181 | <v-text-field |
182 | v-model="updateImage.value" | 182 | v-model="updateImage.value" |
183 | placeholder="Upload new Chapter Points" | 183 | placeholder="Upload new Chapter Points" |
184 | required | 184 | required |
185 | ></v-text-field> | 185 | ></v-text-field> |
186 | </v-flex> | 186 | </v-flex> |
187 | <v-flex xs2 class="pt-4"> | 187 | <v-flex xs2 class="pt-4"> |
188 | <v-icon @click="deleteUpdate(index)" v-if="index !=0">cancel</v-icon> | 188 | <v-icon @click="deleteUpdate(index)" v-if="index !=0">cancel</v-icon> |
189 | <v-icon @click="update">add_circle</v-icon> | 189 | <v-icon @click="update">add_circle</v-icon> |
190 | </v-flex> | 190 | </v-flex> |
191 | </v-layout> | 191 | </v-layout> |
192 | </v-layout> | 192 | </v-layout> |
193 | </div> | 193 | </div> |
194 | </v-flex> | 194 | </v-flex> |
195 | <v-layout> | 195 | <v-layout> |
196 | <v-flex xs12 sm12 md11 lg11> | 196 | <v-flex xs12 sm12 md11 lg11> |
197 | <v-card-actions class="hidden-xs-only hidden-sm-only"> | 197 | <v-card-actions class="hidden-xs-only hidden-sm-only"> |
198 | <v-spacer></v-spacer> | 198 | <v-spacer></v-spacer> |
199 | <v-btn | 199 | <v-btn |
200 | round | 200 | round |
201 | dark | 201 | dark |
202 | @click="saveChapter" | 202 | @click="saveChapter" |
203 | :loading="editLoading" | 203 | :loading="editLoading" |
204 | class="add-button mr-4" | 204 | class="add-button mr-4" |
205 | >Save</v-btn> | 205 | >Save</v-btn> |
206 | </v-card-actions> | 206 | </v-card-actions> |
207 | <v-card-actions class="hidden-md-only hidden-lg-only hidden-xl-only"> | 207 | <v-card-actions class="hidden-md-only hidden-lg-only hidden-xl-only"> |
208 | <v-spacer></v-spacer> | 208 | <v-spacer></v-spacer> |
209 | <v-btn | 209 | <v-btn |
210 | round | 210 | round |
211 | dark | 211 | dark |
212 | @click="saveChapter" | 212 | @click="saveChapter" |
213 | :loading="editLoading" | 213 | :loading="editLoading" |
214 | class="add-button" | 214 | class="add-button" |
215 | >Save</v-btn> | 215 | >Save</v-btn> |
216 | <v-spacer></v-spacer> | 216 | <v-spacer></v-spacer> |
217 | </v-card-actions> | 217 | </v-card-actions> |
218 | </v-flex> | 218 | </v-flex> |
219 | </v-layout> | 219 | </v-layout> |
220 | </v-card-text> | 220 | </v-card-text> |
221 | </v-card> | 221 | </v-card> |
222 | </v-dialog> | 222 | </v-dialog> |
223 | <!-- ADD NEW CHAPTER--> | 223 | <!-- ADD NEW CHAPTER--> |
224 | <v-dialog v-model="addChapterDialog" max-width="1000px" scrollable> | 224 | <v-dialog v-model="addChapterDialog" max-width="1000px" scrollable> |
225 | <v-card class="card-style pa-2" dark> | 225 | <v-card class="card-style pa-2" dark> |
226 | <v-layout> | 226 | <v-layout> |
227 | <v-flex xs12> | 227 | <v-flex xs12> |
228 | <label class="title text-xs-center">Add Chapter Detail</label> | 228 | <label class="title text-xs-center">Add Chapter Detail</label> |
229 | <v-icon | 229 | <v-icon |
230 | size="24" | 230 | size="24" |
231 | class="right" | 231 | class="right" |
232 | @click="addChapterDialog = false; trigger = 'reset'; emptyPdf = 'reset' " | 232 | @click="addChapterDialog = false; trigger = 'reset'; emptyPdf = 'reset' " |
233 | >cancel</v-icon> | 233 | >cancel</v-icon> |
234 | </v-flex> | 234 | </v-flex> |
235 | </v-layout> | 235 | </v-layout> |
236 | <v-card-text> | 236 | <v-card-text> |
237 | <v-layout wrap> | 237 | <v-layout wrap> |
238 | <v-flex xs12 sm12> | 238 | <v-flex xs12 sm12> |
239 | <v-layout> | 239 | <v-layout> |
240 | <v-flex xs4 class="pt-4 subheading"> | 240 | <v-flex xs4 class="pt-4 subheading"> |
241 | <label class="right">Chapter Name:</label> | 241 | <label class="right">Chapter Name:</label> |
242 | </v-flex> | 242 | </v-flex> |
243 | <v-flex xs8 sm6 class="ml-3"> | 243 | <v-flex xs8 sm6 class="ml-3"> |
244 | <v-text-field | 244 | <v-text-field |
245 | v-model="addChapterItem.chapterName" | 245 | v-model="addChapterItem.chapterName" |
246 | placeholder="fill your Title" | 246 | placeholder="fill your Title" |
247 | type="text" | 247 | type="text" |
248 | required | 248 | required |
249 | ></v-text-field> | 249 | ></v-text-field> |
250 | </v-flex> | 250 | </v-flex> |
251 | </v-layout> | 251 | </v-layout> |
252 | </v-flex> | 252 | </v-flex> |
253 | <v-flex xs12 sm12> | 253 | <v-flex xs12 sm12> |
254 | <v-layout> | 254 | <v-layout> |
255 | <v-flex xs4 class="pt-4 subheading"> | 255 | <v-flex xs4 class="pt-4 subheading"> |
256 | <label class="right">Description:</label> | 256 | <label class="right">Description:</label> |
257 | </v-flex> | 257 | </v-flex> |
258 | <v-flex xs8 sm6 class="ml-3"> | 258 | <v-flex xs8 sm6 class="ml-3"> |
259 | <v-text-field | 259 | <v-text-field |
260 | placeholder="fill your Description" | 260 | placeholder="fill your Description" |
261 | v-model="addChapterItem.description" | 261 | v-model="addChapterItem.description" |
262 | type="text" | 262 | type="text" |
263 | required | 263 | required |
264 | ></v-text-field> | 264 | ></v-text-field> |
265 | </v-flex> | 265 | </v-flex> |
266 | </v-layout> | 266 | </v-layout> |
267 | </v-flex> | 267 | </v-flex> |
268 | <!-- UPLOAD PPT --> | 268 | <!-- UPLOAD PPT --> |
269 | <v-flex xs12> | 269 | <!-- <v-flex xs12> |
270 | <v-layout> | 270 | <v-layout> |
271 | <v-flex xs4 class="pt-4 subheading"> | 271 | <v-flex xs4 class="pt-4 subheading"> |
272 | <label class="right">Upload PPT:</label> | 272 | <label class="right">Upload PPT:</label> |
273 | </v-flex> | 273 | </v-flex> |
274 | <v-flex xs8 sm6 class="ml-3"> | 274 | <v-flex xs8 sm6 class="ml-3"> |
275 | <UploadFiles | 275 | <UploadFiles |
276 | @fileSelected="fileSelected($event,'uploadPPT')" | 276 | @fileSelected="fileSelected($event,'uploadPPT')" |
277 | label="Add PPT" | 277 | label="Add PPT" |
278 | reference="newChapterPpt" | 278 | reference="newChapterPpt" |
279 | id="newChapterPptInput" | 279 | id="newChapterPptInput" |
280 | :trigger="trigger" | 280 | :trigger="trigger" |
281 | ></UploadFiles> | 281 | ></UploadFiles> |
282 | </v-flex> | 282 | </v-flex> |
283 | </v-layout> | 283 | </v-layout> |
284 | </v-flex> | 284 | </v-flex>--> |
285 | <!-- UPLOAD PDF --> | 285 | <!-- UPLOAD PDF --> |
286 | <v-flex xs12> | 286 | <v-flex xs12> |
287 | <v-layout> | 287 | <v-layout> |
288 | <v-flex xs4 class="pt-4 subheading"> | 288 | <v-flex xs4 class="pt-4 subheading"> |
289 | <label class="right">Upload PDF:</label> | 289 | <label class="right">Upload PDF:</label> |
290 | </v-flex> | 290 | </v-flex> |
291 | <v-flex xs8 sm6 class="ml-3"> | 291 | <v-flex xs8 sm6 class="ml-3"> |
292 | <UploadPdf | 292 | <UploadPdf |
293 | @pdfFileSelected="pdfFileSelected($event,'uploadPDF')" | 293 | @pdfFileSelected="pdfFileSelected($event,'uploadPDF')" |
294 | label="Add PDF" | 294 | label="Add PDF" |
295 | reference="newChapterPdf" | 295 | reference="newChapterPdf" |
296 | id="newChapterPdfInput" | 296 | id="newChapterPdfInput" |
297 | :emptyPdf="emptyPdf" | 297 | :emptyPdf="emptyPdf" |
298 | ></UploadPdf> | 298 | ></UploadPdf> |
299 | </v-flex> | 299 | </v-flex> |
300 | </v-layout> | 300 | </v-layout> |
301 | </v-flex> | 301 | </v-flex> |
302 | </v-layout> | 302 | </v-layout> |
303 | <v-flex xs12> | 303 | <v-flex xs12> |
304 | <div v-for="(chapterPoints,index) in findsChapterPoint" :key="index"> | 304 | <div v-for="(chapterPoints,index) in findsChapterPoint" :key="index"> |
305 | <v-layout> | 305 | <v-layout> |
306 | <v-flex xs4 class="pt-4 subheading"> | 306 | <v-flex xs4 class="pt-4 subheading"> |
307 | <label class="right">Chapter Points:</label> | 307 | <label class="right">Chapter Points:</label> |
308 | </v-flex> | 308 | </v-flex> |
309 | <v-flex xs8 sm8 md6 class="ml-3"> | 309 | <v-flex xs8 sm8 md6 class="ml-3"> |
310 | <v-text-field | 310 | <v-text-field |
311 | placeholder="fill your Chapter Points" | 311 | placeholder="fill your Chapter Points" |
312 | v-model="chapterPoints.value" | 312 | v-model="chapterPoints.value" |
313 | type="text" | 313 | type="text" |
314 | name="link" | 314 | name="link" |
315 | required | 315 | required |
316 | ></v-text-field> | 316 | ></v-text-field> |
317 | </v-flex> | 317 | </v-flex> |
318 | <v-flex xs2 class="pt-4"> | 318 | <v-flex xs2 class="pt-4"> |
319 | <v-icon @click="deleteChapterPoint(index)" v-if="index !=0 ">cancel</v-icon> | 319 | <v-icon @click="deleteChapterPoint(index)" v-if="index !=0 ">cancel</v-icon> |
320 | <v-icon @click="addChapterPoint()">add_circle</v-icon> | 320 | <v-icon @click="addChapterPoint()">add_circle</v-icon> |
321 | </v-flex> | 321 | </v-flex> |
322 | </v-layout> | 322 | </v-layout> |
323 | </div> | 323 | </div> |
324 | </v-flex> | 324 | </v-flex> |
325 | <v-layout> | 325 | <v-layout> |
326 | <v-flex xs12 sm12 md11 lg11> | 326 | <v-flex xs12 sm12 md11 lg11> |
327 | <v-card-actions class="hidden-xs-only hidden-sm-only"> | 327 | <v-card-actions class="hidden-xs-only hidden-sm-only"> |
328 | <v-spacer></v-spacer> | 328 | <v-spacer></v-spacer> |
329 | <v-btn | 329 | <v-btn |
330 | round | 330 | round |
331 | dark | 331 | dark |
332 | @click="submitChapter" | 332 | @click="submitChapter" |
333 | :loading="editLoading" | 333 | :loading="editLoading" |
334 | class="add-button mr-4" | 334 | class="add-button mr-4" |
335 | >Submit</v-btn> | 335 | >Submit</v-btn> |
336 | </v-card-actions> | 336 | </v-card-actions> |
337 | <v-card-actions class="hidden-md-only hidden-lg-only hidden-xl-only"> | 337 | <v-card-actions class="hidden-md-only hidden-lg-only hidden-xl-only"> |
338 | <v-spacer></v-spacer> | 338 | <v-spacer></v-spacer> |
339 | <v-btn round dark @click="save" :loading="editLoading" class="add-button">Save</v-btn> | 339 | <v-btn round dark @click="save" :loading="editLoading" class="add-button">Save</v-btn> |
340 | <v-spacer></v-spacer> | 340 | <v-spacer></v-spacer> |
341 | </v-card-actions> | 341 | </v-card-actions> |
342 | </v-flex> | 342 | </v-flex> |
343 | </v-layout> | 343 | </v-layout> |
344 | </v-card-text> | 344 | </v-card-text> |
345 | </v-card> | 345 | </v-card> |
346 | </v-dialog> | 346 | </v-dialog> |
347 | 347 | ||
348 | <!-- ****** PROFILE Gallery ****** --> | 348 | <!-- ****** PROFILE Gallery ****** --> |
349 | 349 | ||
350 | <v-dialog v-model="viewProfileGallery" max-width="1000" scrollable> | 350 | <v-dialog v-model="viewProfileGallery" max-width="1000" scrollable> |
351 | <v-card flat class="card-style pa-3" dark> | 351 | <v-card flat class="card-style pa-3" dark> |
352 | <v-layout> | 352 | <v-layout> |
353 | <v-flex xs12> | 353 | <v-flex xs12> |
354 | <label class="title text-xs-center">View Course Detail</label> | 354 | <label class="title text-xs-center">View Course Detail</label> |
355 | <v-icon size="24" class="right" @click="closeProfileGallery">cancel</v-icon> | 355 | <v-icon size="24" class="right" @click="closeProfileGallery">cancel</v-icon> |
356 | </v-flex> | 356 | </v-flex> |
357 | </v-layout> | 357 | </v-layout> |
358 | <v-card-text> | 358 | <v-card-text> |
359 | <v-container grid-list-md> | 359 | <v-container grid-list-md> |
360 | <v-layout wrap> | 360 | <v-layout wrap> |
361 | <v-flex xs12> | 361 | <v-flex xs12> |
362 | <v-layout> | 362 | <v-layout> |
363 | <v-flex xs4 sm6> | 363 | <v-flex xs4 sm6> |
364 | <h5 class="right my-1"> | 364 | <h5 class="right my-1"> |
365 | <b>Chapter Name:</b> | 365 | <b>Chapter Name:</b> |
366 | </h5> | 366 | </h5> |
367 | </v-flex> | 367 | </v-flex> |
368 | <v-flex sm6 xs8> | 368 | <v-flex sm6 xs8> |
369 | <h5 class="my-1">{{ editedItem.chapterName }}</h5> | 369 | <h5 class="my-1">{{ editedItem.chapterName }}</h5> |
370 | </v-flex> | 370 | </v-flex> |
371 | </v-layout> | 371 | </v-layout> |
372 | <v-layout> | 372 | <v-layout> |
373 | <v-flex xs4 sm6> | 373 | <v-flex xs4 sm6> |
374 | <h5 class="right my-1"> | 374 | <h5 class="right my-1"> |
375 | <b>Description:</b> | 375 | <b>Description:</b> |
376 | </h5> | 376 | </h5> |
377 | </v-flex> | 377 | </v-flex> |
378 | <v-flex sm6 xs8> | 378 | <v-flex sm6 xs8> |
379 | <h5 class="my-1">{{ editedItem.description }}</h5> | 379 | <h5 class="my-1">{{ editedItem.description }}</h5> |
380 | </v-flex> | 380 | </v-flex> |
381 | </v-layout> | 381 | </v-layout> |
382 | <v-layout> | 382 | <v-layout> |
383 | <v-flex xs5 sm6> | 383 | <v-flex xs5 sm6> |
384 | <h5 class="right my-1"> | 384 | <h5 class="right my-1"> |
385 | <b>Chapter Points:</b> | 385 | <b>Chapter Points:</b> |
386 | </h5> | 386 | </h5> |
387 | </v-flex> | 387 | </v-flex> |
388 | <v-flex sm6 xs8> | 388 | <v-flex sm6 xs8> |
389 | <h5 class="my-1"> | 389 | <h5 class="my-1"> |
390 | <ul v-for="chapterPoint in editedItem.chapterPoints" :key="chapterPoint"> | 390 | <ul v-for="chapterPoint in editedItem.chapterPoints" :key="chapterPoint"> |
391 | <li>{{ chapterPoint}}</li> | 391 | <li>{{ chapterPoint}}</li> |
392 | </ul> | 392 | </ul> |
393 | </h5> | 393 | </h5> |
394 | </v-flex> | 394 | </v-flex> |
395 | </v-layout> | 395 | </v-layout> |
396 | <!-- LINK TO PDF --> | 396 | <!-- LINK TO PDF --> |
397 | <v-layout row justify-center> | 397 | <v-layout row justify-center> |
398 | <v-flex xs6> | 398 | <v-flex xs6> |
399 | <div style="width: 100%;"> | 399 | <div style="width: 100%;"> |
400 | <a | 400 | <a |
401 | :href="editedItem.pdfFileUrl" | 401 | :href="editedItem.pdfFileUrl" |
402 | target="_blank" | 402 | target="_blank" |
403 | style="text-decoration: none!important;" | 403 | style="text-decoration: none!important;" |
404 | > | 404 | > |
405 | <v-btn flat block> | 405 | <v-btn flat block> |
406 | <span> | 406 | <span> |
407 | <h5> | 407 | <h5> |
408 | <b>Open PDF</b> | 408 | <b>Open PDF</b> |
409 | </h5> | 409 | </h5> |
410 | </span> | 410 | </span> |
411 | </v-btn> | 411 | </v-btn> |
412 | </a> | 412 | </a> |
413 | </div> | 413 | </div> |
414 | </v-flex> | 414 | </v-flex> |
415 | </v-layout> | 415 | </v-layout> |
416 | </v-flex> | 416 | </v-flex> |
417 | </v-layout> | 417 | </v-layout> |
418 | </v-container> | 418 | </v-container> |
419 | </v-card-text> | 419 | </v-card-text> |
420 | </v-card> | 420 | </v-card> |
421 | </v-dialog> | 421 | </v-dialog> |
422 | 422 | ||
423 | <!-- ****** Course Detail TABLE ****** --> | 423 | <!-- ****** Course Detail TABLE ****** --> |
424 | <v-container grid-list-lg class="pa-0"> | 424 | <v-container grid-list-lg class="pa-0"> |
425 | <v-layout row wrap> | 425 | <v-layout row wrap> |
426 | <!-- <v-btn | 426 | <!-- <v-btn |
427 | fab | 427 | fab |
428 | dark | 428 | dark |
429 | class="open-dialog-button hidden-xl-only hidden-md-only hidden-lg-only" | 429 | class="open-dialog-button hidden-xl-only hidden-md-only hidden-lg-only" |
430 | small | 430 | small |
431 | @click="addCourseDetailDialog = true" | 431 | @click="addCourseDetailDialog = true" |
432 | > | 432 | > |
433 | <v-icon dark>add</v-icon> | 433 | <v-icon dark>add</v-icon> |
434 | </v-btn>--> | 434 | </v-btn>--> |
435 | <v-flex xs12 sm4> | 435 | <v-flex xs12 sm4> |
436 | <v-btn block round class="open-dialog-button" dark @click="addCourseDetailDialog = true"> | 436 | <v-btn block round class="open-dialog-button" dark @click="addCourseDetailDialog = true"> |
437 | <v-icon class="white--text pr-1" size="20">add</v-icon> | 437 | <v-icon class="white--text pr-1" size="20">add</v-icon> |
438 | <span class="hidden-sm-and-down">Add Course Detail</span> | 438 | <span class="hidden-sm-and-down">Add Course Detail</span> |
439 | <span class="hidden-md-and-up">Add</span> | 439 | <span class="hidden-md-and-up">Add</span> |
440 | </v-btn> | 440 | </v-btn> |
441 | </v-flex> | 441 | </v-flex> |
442 | 442 | ||
443 | <v-flex xs12 sm4 md2> | 443 | <v-flex xs12 sm4 md2> |
444 | <v-select | 444 | <v-select |
445 | :items="addclass" | 445 | :items="addclass" |
446 | label="Select Class" | 446 | label="Select Class" |
447 | v-model="getCourse.classId" | 447 | v-model="getCourse.classId" |
448 | item-text="classNum" | 448 | item-text="classNum" |
449 | item-value="_id" | 449 | item-value="_id" |
450 | name="Select Class" | 450 | name="Select Class" |
451 | @change="getCourses(getCourse.classId)" | 451 | @change="getCourses(getCourse.classId)" |
452 | required | 452 | required |
453 | ></v-select> | 453 | ></v-select> |
454 | </v-flex> | 454 | </v-flex> |
455 | <v-flex xs12 sm4 md2> | 455 | <v-flex xs12 sm4 md2> |
456 | <v-select | 456 | <v-select |
457 | :items="courseData" | 457 | :items="courseData" |
458 | label="Select Course" | 458 | label="Select Course" |
459 | v-model="getCourse.courseId" | 459 | v-model="getCourse.courseId" |
460 | item-text="courseName" | 460 | item-text="courseName" |
461 | item-value="_id" | 461 | item-value="_id" |
462 | required | 462 | required |
463 | @change="getCourseDetailsList(getCourse.courseId)" | 463 | @change="getCourseDetailsList(getCourse.courseId)" |
464 | ></v-select> | 464 | ></v-select> |
465 | </v-flex> | 465 | </v-flex> |
466 | 466 | ||
467 | <v-flex xs12 sm1 v-if="show"> | 467 | <v-flex xs12 sm1 v-if="show"> |
468 | <v-btn icon large flat @click="show = false;showSearch = true;"> | 468 | <v-btn icon large flat @click="show = false;showSearch = true;"> |
469 | <v-avatar size="27"> | 469 | <v-avatar size="27"> |
470 | <img src="/static/icon/search.png" alt="icon" /> | 470 | <img src="/static/icon/search.png" alt="icon" /> |
471 | </v-avatar> | 471 | </v-avatar> |
472 | </v-btn> | 472 | </v-btn> |
473 | </v-flex> | 473 | </v-flex> |
474 | 474 | ||
475 | <v-flex xs12 sm3 md3 v-if="showSearch"> | 475 | <v-flex xs12 sm3 md3 v-if="showSearch"> |
476 | <div style="display: inline-block;width: 70%;"> | 476 | <div style="display: inline-block;width: 70%;"> |
477 | <v-text-field | 477 | <v-text-field |
478 | autofocus | 478 | autofocus |
479 | v-model="search" | 479 | v-model="search" |
480 | label="Search" | 480 | label="Search" |
481 | prepend-inner-icon="search" | 481 | prepend-inner-icon="search" |
482 | color="primary" | 482 | color="primary" |
483 | ></v-text-field> | 483 | ></v-text-field> |
484 | </div> | 484 | </div> |
485 | <div style="display: inline-block;"> | 485 | <div style="display: inline-block;"> |
486 | <v-icon @click="closeSearch" color="error">close</v-icon> | 486 | <v-icon @click="closeSearch" color="error">close</v-icon> |
487 | </div> | 487 | </div> |
488 | </v-flex> | 488 | </v-flex> |
489 | </v-layout> | 489 | </v-layout> |
490 | </v-container> | 490 | </v-container> |
491 | <v-data-table | 491 | <v-data-table |
492 | :headers="headers" | 492 | :headers="headers" |
493 | :items="CourseDetailsList" | 493 | :items="CourseDetailsList" |
494 | :pagination.sync="pagination" | 494 | :pagination.sync="pagination" |
495 | :search="search" | 495 | :search="search" |
496 | item-key="_id" | 496 | item-key="_id" |
497 | > | 497 | > |
498 | <template slot="items" slot-scope="props"> | 498 | <template slot="items" slot-scope="props"> |
499 | <tr class="tr" @click="courseTableRow(props.item._id)"> | 499 | <tr class="tr" @click="courseTableRow(props.item._id)"> |
500 | <td class="td td-row">{{ props.index + 1}}</td> | 500 | <td class="td td-row">{{ props.index + 1}}</td> |
501 | <td class="td td-row text-xs-center">{{ props.item.classId.classNum }}</td> | 501 | <td class="td td-row text-xs-center">{{ props.item.classId.classNum }}</td> |
502 | <td class="td td-row text-xs-center">{{ props.item.courseId.courseName }}</td> | 502 | <td class="td td-row text-xs-center">{{ props.item.courseId.courseName }}</td> |
503 | <td class="td td-row text-xs-center"> | 503 | <td class="td td-row text-xs-center"> |
504 | <div style="vertical-align: top;"> | 504 | <div style="vertical-align: top;"> |
505 | <v-tooltip top> | 505 | <v-tooltip top> |
506 | <v-icon | 506 | <v-icon |
507 | slot="activator" | 507 | slot="activator" |
508 | style="cursor:pointer;font-size:22px;position: relative;top: -4px; " | 508 | style="cursor:pointer;font-size:22px;position: relative;top: -4px; " |
509 | class="mr-3" | 509 | class="mr-3" |
510 | @click="addChapters(props.item)" | 510 | @click="addChapters(props.item)" |
511 | >add_circle_outline</v-icon> | 511 | >add_circle_outline</v-icon> |
512 | <span>Add</span> | 512 | <span>Add</span> |
513 | </v-tooltip> | 513 | </v-tooltip> |
514 | <v-tooltip top> | 514 | <v-tooltip top> |
515 | <img | 515 | <img |
516 | slot="activator" | 516 | slot="activator" |
517 | style="cursor:pointer; width:25px; height:25px; " | 517 | style="cursor:pointer; width:25px; height:25px; " |
518 | class="mr-3" | 518 | class="mr-3" |
519 | @click="props.expanded = !props.expanded" | 519 | @click="props.expanded = !props.expanded" |
520 | src="/static/icon/view.png" | 520 | src="/static/icon/view.png" |
521 | /> | 521 | /> |
522 | <span>View</span> | 522 | <span>View</span> |
523 | </v-tooltip> | 523 | </v-tooltip> |
524 | <v-tooltip top> | 524 | <v-tooltip top> |
525 | <img | 525 | <img |
526 | slot="activator" | 526 | slot="activator" |
527 | style="cursor:pointer; width:20px; height:18px; " | 527 | style="cursor:pointer; width:20px; height:18px; " |
528 | class="mr-3" | 528 | class="mr-3" |
529 | @click="editItem(props.item)" | 529 | @click="editItem(props.item)" |
530 | src="/static/icon/edit.png" | 530 | src="/static/icon/edit.png" |
531 | /> | 531 | /> |
532 | <span>Edit</span> | 532 | <span>Edit</span> |
533 | </v-tooltip> | 533 | </v-tooltip> |
534 | <v-tooltip top> | 534 | <v-tooltip top> |
535 | <img | 535 | <img |
536 | slot="activator" | 536 | slot="activator" |
537 | style="cursor:pointer; width:20px; height:20px; " | 537 | style="cursor:pointer; width:20px; height:20px; " |
538 | class="mr-3" | 538 | class="mr-3" |
539 | @click="deleteItem(props.item)" | 539 | @click="deleteItem(props.item)" |
540 | src="/static/icon/delete.png" | 540 | src="/static/icon/delete.png" |
541 | /> | 541 | /> |
542 | <span>Delete</span> | 542 | <span>Delete</span> |
543 | </v-tooltip> | 543 | </v-tooltip> |
544 | </div> | 544 | </div> |
545 | </td> | 545 | </td> |
546 | </tr> | 546 | </tr> |
547 | </template> | 547 | </template> |
548 | <!-- CHAPTERS IN A COURSE --> | 548 | <!-- CHAPTERS IN A COURSE --> |
549 | <template slot="expand"> | 549 | <template slot="expand"> |
550 | <v-data-table :items="chapters" hide-actions item-key="chapterName" style="width: auto;"> | 550 | <v-data-table :items="chapters" hide-actions item-key="chapterName" style="width: auto;"> |
551 | <template slot="items" slot-scope="props"> | 551 | <template slot="items" slot-scope="props"> |
552 | <tr class="tr" @click="props.expanded = !props.expanded"> | 552 | <tr class="tr" @click="props.expanded = !props.expanded"> |
553 | <td class="td td-row">{{ props.index + 1}}</td> | 553 | <td class="td td-row">{{ props.index + 1}}</td> |
554 | <td class="text-xs-center td td-row">{{ props.item.chapterName}}</td> | 554 | <td class="text-xs-center td td-row">{{ props.item.chapterName}}</td> |
555 | <td class="text-xs-center td td-row">{{ props.item.description }}</td> | 555 | <td class="text-xs-center td td-row">{{ props.item.description }}</td> |
556 | <td class="text-xs-center td td-row"> | 556 | <td class="text-xs-center td td-row"> |
557 | <v-tooltip top> | 557 | <v-tooltip top> |
558 | <v-icon | 558 | <v-icon |
559 | slot="activator" | 559 | slot="activator" |
560 | style="cursor:pointer;font-size:22px;position: relative;top: -4px; " | 560 | style="cursor:pointer;font-size:22px;position: relative;top: -4px; " |
561 | class="mr-3" | 561 | class="mr-3" |
562 | @click="$router.push({name: 'Live Online Class', query: {chapterId: props.item._id, chapterName: props.item.chapterName, courseId: getCourse.courseId, classId: getCourse.classId }})" | 562 | @click="$router.push({name: 'Live Online Class', query: {chapterId: props.item._id, chapterName: props.item.chapterName, courseId: getCourse.courseId, classId: getCourse.classId }})" |
563 | >video_call</v-icon> | 563 | >video_call</v-icon> |
564 | <span>Live Session</span> | 564 | <span>Live Session</span> |
565 | </v-tooltip> | 565 | </v-tooltip> |
566 | <v-tooltip top> | 566 | <v-tooltip top> |
567 | <img | 567 | <img |
568 | slot="activator" | 568 | slot="activator" |
569 | style="cursor:pointer; width:25px; height:25px; " | 569 | style="cursor:pointer; width:25px; height:25px; " |
570 | class="mr-3" | 570 | class="mr-3" |
571 | @click="profile(props.item)" | 571 | @click="profile(props.item)" |
572 | src="/static/icon/view.png" | 572 | src="/static/icon/view.png" |
573 | /> | 573 | /> |
574 | <span>View</span> | 574 | <span>View</span> |
575 | </v-tooltip> | 575 | </v-tooltip> |
576 | <v-tooltip top> | 576 | <v-tooltip top> |
577 | <img | 577 | <img |
578 | slot="activator" | 578 | slot="activator" |
579 | style="cursor:pointer; width:20px; height:18px; " | 579 | style="cursor:pointer; width:20px; height:18px; " |
580 | class="mr-3" | 580 | class="mr-3" |
581 | @click="editChapterItem(props.item)" | 581 | @click="editChapterItem(props.item)" |
582 | src="/static/icon/edit.png" | 582 | src="/static/icon/edit.png" |
583 | /> | 583 | /> |
584 | <span>Edit</span> | 584 | <span>Edit</span> |
585 | </v-tooltip> | 585 | </v-tooltip> |
586 | <v-tooltip top> | 586 | <v-tooltip top> |
587 | <img | 587 | <img |
588 | slot="activator" | 588 | slot="activator" |
589 | style="cursor:pointer; width:20px; height:20px; " | 589 | style="cursor:pointer; width:20px; height:20px; " |
590 | class="mr-3" | 590 | class="mr-3" |
591 | @click="deleteChapters(props.item)" | 591 | @click="deleteChapters(props.item)" |
592 | src="/static/icon/delete.png" | 592 | src="/static/icon/delete.png" |
593 | /> | 593 | /> |
594 | <span>Delete Chapter</span> | 594 | <span>Delete Chapter</span> |
595 | </v-tooltip> | 595 | </v-tooltip> |
596 | </td> | 596 | </td> |
597 | </tr> | 597 | </tr> |
598 | </template> | 598 | </template> |
599 | </v-data-table> | 599 | </v-data-table> |
600 | </template> | 600 | </template> |
601 | 601 | ||
602 | <v-alert | 602 | <v-alert |
603 | slot="no-results" | 603 | slot="no-results" |
604 | :value="true" | 604 | :value="true" |
605 | color="error" | 605 | color="error" |
606 | icon="warning" | 606 | icon="warning" |
607 | >Your search for "{{ search }}" found no results.</v-alert> | 607 | >Your search for "{{ search }}" found no results.</v-alert> |
608 | </v-data-table> | 608 | </v-data-table> |
609 | <!-- ****** ADD Course Detail ****** --> | 609 | <!-- ****** ADD Course Detail ****** --> |
610 | <v-dialog v-model="addCourseDetailDialog" max-width="600px" persistent> | 610 | <v-dialog v-model="addCourseDetailDialog" max-width="600px" persistent> |
611 | <v-card flat class="card-style pa-2" dark> | 611 | <v-card flat class="card-style pa-2" dark> |
612 | <v-layout> | 612 | <v-layout> |
613 | <v-flex xs12> | 613 | <v-flex xs12> |
614 | <label class="title text-xs-center">Add Course Details</label> | 614 | <label class="title text-xs-center">Add Course Details</label> |
615 | <v-icon | 615 | <v-icon |
616 | size="24" | 616 | size="24" |
617 | class="right" | 617 | class="right" |
618 | @click="addCourseDetailDialog = false; clear() ; trigger = 'reset' ; emptyPdf = 'reset' " | 618 | @click="addCourseDetailDialog = false; clear() ; trigger = 'reset' ; emptyPdf = 'reset' " |
619 | >cancel</v-icon> | 619 | >cancel</v-icon> |
620 | </v-flex> | 620 | </v-flex> |
621 | </v-layout> | 621 | </v-layout> |
622 | <v-form ref="form" v-model="valid" lazy-validation> | 622 | <v-form ref="form" v-model="valid" lazy-validation> |
623 | <v-container fluid> | 623 | <v-container fluid> |
624 | <v-flex xs12> | 624 | <v-flex xs12> |
625 | <v-layout> | 625 | <v-layout> |
626 | <v-flex xs4 class="pt-4 subheading"> | 626 | <v-flex xs4 class="pt-4 subheading"> |
627 | <label class="right hidden-xs-only hidden-sm-only">Select Class:</label> | 627 | <label class="right hidden-xs-only hidden-sm-only">Select Class:</label> |
628 | <label class="right hidden-lg-only hidden-md-only hidden-xl-only">Class:</label> | 628 | <label class="right hidden-lg-only hidden-md-only hidden-xl-only">Class:</label> |
629 | </v-flex> | 629 | </v-flex> |
630 | <v-flex xs8 sm8 md7 class="ml-3"> | 630 | <v-flex xs8 sm8 md7 class="ml-3"> |
631 | <v-select | 631 | <v-select |
632 | :items="addclass" | 632 | :items="addclass" |
633 | label="Select Class" | 633 | label="Select Class" |
634 | v-model="addCourseDetail.classId" | 634 | v-model="addCourseDetail.classId" |
635 | item-text="classNum" | 635 | item-text="classNum" |
636 | item-value="_id" | 636 | item-value="_id" |
637 | name="Select Class" | 637 | name="Select Class" |
638 | :rules="clsssRules" | 638 | :rules="clsssRules" |
639 | @change="getCourses(addCourseDetail.classId)" | 639 | @change="getCourses(addCourseDetail.classId)" |
640 | required | 640 | required |
641 | ></v-select> | 641 | ></v-select> |
642 | </v-flex> | 642 | </v-flex> |
643 | </v-layout> | 643 | </v-layout> |
644 | </v-flex> | 644 | </v-flex> |
645 | <v-flex xs12> | 645 | <v-flex xs12> |
646 | <v-layout> | 646 | <v-layout> |
647 | <v-flex xs4 class="pt-4 subheading"> | 647 | <v-flex xs4 class="pt-4 subheading"> |
648 | <label class="right hidden-xs-only hidden-sm-only">Select Course:</label> | 648 | <label class="right hidden-xs-only hidden-sm-only">Select Course:</label> |
649 | <label class="right hidden-lg-only hidden-md-only hidden-xl-only">Course:</label> | 649 | <label class="right hidden-lg-only hidden-md-only hidden-xl-only">Course:</label> |
650 | </v-flex> | 650 | </v-flex> |
651 | <v-flex xs8 sm8 md7 class="ml-3"> | 651 | <v-flex xs8 sm8 md7 class="ml-3"> |
652 | <v-select | 652 | <v-select |
653 | :items="courseData" | 653 | :items="courseData" |
654 | label="Select Course" | 654 | label="Select Course" |
655 | v-model="addCourseDetail.courseId" | 655 | v-model="addCourseDetail.courseId" |
656 | item-text="courseName" | 656 | item-text="courseName" |
657 | item-value="_id" | 657 | item-value="_id" |
658 | :rules="courseRules" | 658 | :rules="courseRules" |
659 | required | 659 | required |
660 | ></v-select> | 660 | ></v-select> |
661 | </v-flex> | 661 | </v-flex> |
662 | </v-layout> | 662 | </v-layout> |
663 | </v-flex> | 663 | </v-flex> |
664 | <v-flex xs12> | 664 | <v-flex xs12> |
665 | <v-layout> | 665 | <v-layout> |
666 | <v-flex xs4 class="pt-4 subheading"> | 666 | <v-flex xs4 class="pt-4 subheading"> |
667 | <label class="right">Chapter Name:</label> | 667 | <label class="right">Chapter Name:</label> |
668 | </v-flex> | 668 | </v-flex> |
669 | <v-flex xs8 sm8 md7 class="ml-3"> | 669 | <v-flex xs8 sm8 md7 class="ml-3"> |
670 | <v-text-field | 670 | <v-text-field |
671 | v-model="addCourseDetail.chapterName" | 671 | v-model="addCourseDetail.chapterName" |
672 | placeholder="fill your Title" | 672 | placeholder="fill your Title" |
673 | name="name" | 673 | name="name" |
674 | type="text" | 674 | type="text" |
675 | :rules="chapterNameRules" | 675 | :rules="chapterNameRules" |
676 | required | 676 | required |
677 | ></v-text-field> | 677 | ></v-text-field> |
678 | </v-flex> | 678 | </v-flex> |
679 | </v-layout> | 679 | </v-layout> |
680 | </v-flex> | 680 | </v-flex> |
681 | <!-- DESCRIPTION --> | 681 | <!-- DESCRIPTION --> |
682 | <v-flex xs12> | 682 | <v-flex xs12> |
683 | <v-layout> | 683 | <v-layout> |
684 | <v-flex xs4 class="pt-4 subheading"> | 684 | <v-flex xs4 class="pt-4 subheading"> |
685 | <label class="right">Description:</label> | 685 | <label class="right">Description:</label> |
686 | </v-flex> | 686 | </v-flex> |
687 | <v-flex xs8 sm8 md7 class="ml-3"> | 687 | <v-flex xs8 sm8 md7 class="ml-3"> |
688 | <v-text-field | 688 | <v-text-field |
689 | placeholder="fill your Description" | 689 | placeholder="fill your Description" |
690 | :rules="descriptionRules" | 690 | :rules="descriptionRules" |
691 | v-model="addCourseDetail.description" | 691 | v-model="addCourseDetail.description" |
692 | type="text" | 692 | type="text" |
693 | name="email" | 693 | name="email" |
694 | required | 694 | required |
695 | ></v-text-field> | 695 | ></v-text-field> |
696 | </v-flex> | 696 | </v-flex> |
697 | </v-layout> | 697 | </v-layout> |
698 | </v-flex> | 698 | </v-flex> |
699 | <!-- UPLOAD PPT --> | 699 | <!-- UPLOAD PPT --> |
700 | <v-flex xs12> | 700 | <!-- <v-flex xs12> |
701 | <v-layout> | 701 | <v-layout> |
702 | <v-flex xs4 class="pt-4 subheading"> | 702 | <v-flex xs4 class="pt-4 subheading"> |
703 | <label class="right">Upload PPT:</label> | 703 | <label class="right">Upload PPT:</label> |
704 | </v-flex> | 704 | </v-flex> |
705 | <v-flex xs8 sm8 md7 class="ml-3"> | 705 | <v-flex xs8 sm8 md7 class="ml-3"> |
706 | <UploadFiles | 706 | <UploadFiles |
707 | @fileSelected="fileSelected($event,'uploadPPT')" | 707 | @fileSelected="fileSelected($event,'uploadPPT')" |
708 | label="Add PPT" | 708 | label="Add PPT" |
709 | reference="newCoursePpt" | 709 | reference="newCoursePpt" |
710 | id="newCoursePptInput" | 710 | id="newCoursePptInput" |
711 | :trigger="trigger" | 711 | :trigger="trigger" |
712 | ></UploadFiles> | 712 | ></UploadFiles> |
713 | </v-flex> | 713 | </v-flex> |
714 | </v-layout> | 714 | </v-layout> |
715 | </v-flex> | 715 | </v-flex>--> |
716 | <!-- UPLOAD PDF --> | 716 | <!-- UPLOAD PDF --> |
717 | <v-flex xs12> | 717 | <v-flex xs12> |
718 | <v-layout> | 718 | <v-layout> |
719 | <v-flex xs4 class="pt-4 subheading"> | 719 | <v-flex xs4 class="pt-4 subheading"> |
720 | <label class="right">Upload PDF:</label> | 720 | <label class="right">Upload PDF:</label> |
721 | </v-flex> | 721 | </v-flex> |
722 | <v-flex xs8 sm8 md7 class="ml-3"> | 722 | <v-flex xs8 sm8 md7 class="ml-3"> |
723 | <UploadPdf | 723 | <UploadPdf |
724 | @pdfFileSelected="pdfFileSelected($event,'uploadPDF')" | 724 | @pdfFileSelected="pdfFileSelected($event,'uploadPDF')" |
725 | label="Add PDF" | 725 | label="Add PDF" |
726 | reference="newCoursePdf" | 726 | reference="newCoursePdf" |
727 | id="newCoursePdfInput" | 727 | id="newCoursePdfInput" |
728 | :emptyPdf="emptyPdf" | 728 | :emptyPdf="emptyPdf" |
729 | ></UploadPdf> | 729 | ></UploadPdf> |
730 | </v-flex> | 730 | </v-flex> |
731 | </v-layout> | 731 | </v-layout> |
732 | </v-flex> | 732 | </v-flex> |
733 | <v-layout> | 733 | <v-layout> |
734 | <v-flex xs12> | 734 | <v-flex xs12> |
735 | <div v-for="(chapterPoints,index) in finds" :key="index"> | 735 | <div v-for="(chapterPoints,index) in finds" :key="index"> |
736 | <v-layout> | 736 | <v-layout> |
737 | <v-flex xs4 class="pt-4 subheading"> | 737 | <v-flex xs4 class="pt-4 subheading"> |
738 | <label class="right">Chapter Points:</label> | 738 | <label class="right">Chapter Points:</label> |
739 | </v-flex> | 739 | </v-flex> |
740 | <v-flex xs8 sm8 md6 class="ml-3"> | 740 | <v-flex xs8 sm8 md6 class="ml-3"> |
741 | <v-text-field | 741 | <v-text-field |
742 | placeholder="fill your Chapter Points" | 742 | placeholder="fill your Chapter Points" |
743 | v-model="chapterPoints.value" | 743 | v-model="chapterPoints.value" |
744 | type="text" | 744 | type="text" |
745 | required | 745 | required |
746 | ></v-text-field> | 746 | ></v-text-field> |
747 | </v-flex> | 747 | </v-flex> |
748 | <v-flex xs2 class="pt-4"> | 748 | <v-flex xs2 class="pt-4"> |
749 | <v-icon @click="deleteFind(index)" v-if="index !=0 ">cancel</v-icon> | 749 | <v-icon @click="deleteFind(index)" v-if="index !=0 ">cancel</v-icon> |
750 | <v-icon @click="addFind">add_circle</v-icon> | 750 | <v-icon @click="addFind">add_circle</v-icon> |
751 | </v-flex> | 751 | </v-flex> |
752 | </v-layout> | 752 | </v-layout> |
753 | </div> | 753 | </div> |
754 | </v-flex> | 754 | </v-flex> |
755 | </v-layout> | 755 | </v-layout> |
756 | <v-layout> | 756 | <v-layout> |
757 | <v-flex xs12 sm12> | 757 | <v-flex xs12 sm12> |
758 | <v-layout class="right"> | 758 | <v-layout class="right"> |
759 | <v-btn @click="clear();" round dark class="clear-button">Clear</v-btn> | 759 | <v-btn @click="clear();" round dark class="clear-button">Clear</v-btn> |
760 | <v-btn @click="submit" round dark :loading="loading" class="add-button">Add</v-btn> | 760 | <v-btn @click="submit" round dark :loading="loading" class="add-button">Add</v-btn> |
761 | </v-layout> | 761 | </v-layout> |
762 | </v-flex> | 762 | </v-flex> |
763 | </v-layout> | 763 | </v-layout> |
764 | </v-container> | 764 | </v-container> |
765 | </v-form> | 765 | </v-form> |
766 | </v-card> | 766 | </v-card> |
767 | </v-dialog> | 767 | </v-dialog> |
768 | <v-snackbar | 768 | <v-snackbar |
769 | :timeout="timeout" | 769 | :timeout="timeout" |
770 | :top="y === 'top'" | 770 | :top="y === 'top'" |
771 | :right="x === 'right'" | 771 | :right="x === 'right'" |
772 | :vertical="mode === 'vertical'" | 772 | :vertical="mode === 'vertical'" |
773 | v-model="snackbar" | 773 | v-model="snackbar" |
774 | :color="color" | 774 | :color="color" |
775 | >{{ text }}</v-snackbar> | 775 | >{{ text }}</v-snackbar> |
776 | <div class="loader" v-if="showLoader"> | 776 | <div class="loader" v-if="showLoader"> |
777 | <v-progress-circular indeterminate color="white"></v-progress-circular> | 777 | <v-progress-circular indeterminate color="white"></v-progress-circular> |
778 | </div> | 778 | </div> |
779 | </v-container> | 779 | </v-container> |
780 | </template> | 780 | </template> |
781 | 781 | ||
782 | <script> | 782 | <script> |
783 | import http from "@/Services/http.js"; | 783 | import http from "@/Services/http.js"; |
784 | import UploadFiles from "@/pages/Common/UploadFiles.vue"; | 784 | import UploadFiles from "@/pages/Common/UploadFiles.vue"; |
785 | import UploadPdf from "@/pages/Common/UploadPdf.vue"; | 785 | import UploadPdf from "@/pages/Common/UploadPdf.vue"; |
786 | import AllApiCalls from "@/Services/AllApiCalls.js"; | 786 | import AllApiCalls from "@/Services/AllApiCalls.js"; |
787 | 787 | ||
788 | export default { | 788 | export default { |
789 | mixins: [AllApiCalls], | 789 | mixins: [AllApiCalls], |
790 | components: { | 790 | components: { |
791 | UploadFiles, | 791 | UploadFiles, |
792 | UploadPdf, | 792 | UploadPdf, |
793 | }, | 793 | }, |
794 | data: () => ({ | 794 | data: () => ({ |
795 | snackbar: false, | 795 | snackbar: false, |
796 | y: "top", | 796 | y: "top", |
797 | x: "right", | 797 | x: "right", |
798 | mode: "", | 798 | mode: "", |
799 | timeout: 3000, | 799 | timeout: 3000, |
800 | text: "", | 800 | text: "", |
801 | loading: false, | 801 | loading: false, |
802 | color: "", | 802 | color: "", |
803 | date: null, | 803 | date: null, |
804 | search: "", | 804 | search: "", |
805 | show: true, | 805 | show: true, |
806 | addCourseDetailDialog: false, | 806 | addCourseDetailDialog: false, |
807 | showSearch: false, | 807 | showSearch: false, |
808 | showLoader: false, | 808 | showLoader: false, |
809 | editCourseDetailDialog: false, | 809 | editCourseDetailDialog: false, |
810 | editChapterDetailDialog: false, | 810 | editChapterDetailDialog: false, |
811 | viewProfileGallery: false, | 811 | viewProfileGallery: false, |
812 | valid: true, | 812 | valid: true, |
813 | editLoading: false, | 813 | editLoading: false, |
814 | addclass: [], | 814 | addclass: [], |
815 | courseData: [], | 815 | courseData: [], |
816 | addSection: [], | 816 | addSection: [], |
817 | getCourse: {}, | 817 | getCourse: {}, |
818 | finds: [{ value: "" }], | 818 | finds: [{ value: "" }], |
819 | findsChapterPoint: [{ value: "" }], | 819 | findsChapterPoint: [{ value: "" }], |
820 | updates: [], | 820 | updates: [], |
821 | youTubeLink: {}, | 821 | youTubeLink: {}, |
822 | addCourseDetail: { | 822 | addCourseDetail: { |
823 | chapters: [ | 823 | chapters: [ |
824 | { | 824 | { |
825 | chapterName: "", | 825 | chapterName: "", |
826 | description: "", | 826 | description: "", |
827 | chapterPoints: [], | 827 | chapterPoints: [], |
828 | }, | 828 | }, |
829 | ], | 829 | ], |
830 | }, | 830 | }, |
831 | chapters: [], | 831 | chapters: [], |
832 | pagination: { | 832 | pagination: { |
833 | rowsPerPage: 10, | 833 | rowsPerPage: 10, |
834 | }, | 834 | }, |
835 | editFiles: [], | 835 | editFiles: [], |
836 | files: [], | 836 | files: [], |
837 | courseData: [], | 837 | courseData: [], |
838 | token: "", | 838 | token: "", |
839 | courseId: "", | 839 | courseId: "", |
840 | clsssRules: [(v) => !!v || " Class is required"], | 840 | clsssRules: [(v) => !!v || " Class is required"], |
841 | courseRules: [(v) => !!v || " Course is required"], | 841 | courseRules: [(v) => !!v || " Course is required"], |
842 | chapterNameRules: [(v) => !!v || " Tilte is required"], | 842 | chapterNameRules: [(v) => !!v || " Tilte is required"], |
843 | descriptionRules: [(v) => !!v || " Description is required"], | 843 | descriptionRules: [(v) => !!v || " Description is required"], |
844 | headers: [ | 844 | headers: [ |
845 | { | 845 | { |
846 | align: "", | 846 | align: "", |
847 | text: "No", | 847 | text: "No", |
848 | sortable: false, | 848 | sortable: false, |
849 | value: "index", | 849 | value: "index", |
850 | }, | 850 | }, |
851 | { | 851 | { |
852 | text: "Class Name", | 852 | text: "Class Name", |
853 | value: "classNum", | 853 | value: "classNum", |
854 | sortable: false, | 854 | sortable: false, |
855 | align: "center", | 855 | align: "center", |
856 | }, | 856 | }, |
857 | { | 857 | { |
858 | text: "Course Name", | 858 | text: "Course Name", |
859 | value: "courseName", | 859 | value: "courseName", |
860 | sortable: false, | 860 | sortable: false, |
861 | align: "center", | 861 | align: "center", |
862 | }, | 862 | }, |
863 | { text: "Action", value: "", sortable: false, align: "center" }, | 863 | { text: "Action", value: "", sortable: false, align: "center" }, |
864 | ], | 864 | ], |
865 | CourseDetailsList: [], | 865 | CourseDetailsList: [], |
866 | editedIndex: -1, | 866 | editedIndex: -1, |
867 | editedItem: {}, | 867 | editedItem: {}, |
868 | editedCourse: {}, | 868 | editedCourse: {}, |
869 | editChapter: { | 869 | editChapter: { |
870 | chapterPoints: [], | 870 | chapterPoints: [], |
871 | }, | 871 | }, |
872 | index: "", | 872 | index: "", |
873 | addChapterItem: {}, | 873 | addChapterItem: {}, |
874 | addChapterItemObj: {}, | 874 | addChapterItemObj: {}, |
875 | addChapterDialog: false, | 875 | addChapterDialog: false, |
876 | }), | 876 | }), |
877 | methods: { | 877 | methods: { |
878 | getCourses(classId) { | 878 | getCourses(classId) { |
879 | this.showLoader = true; | 879 | this.showLoader = true; |
880 | http() | 880 | http() |
881 | .get("/getCourseesList", { | 881 | .get("/getCourseesList", { |
882 | params: { | 882 | params: { |
883 | classId: classId, | 883 | classId: classId, |
884 | }, | 884 | }, |
885 | }) | 885 | }) |
886 | .then((response) => { | 886 | .then((response) => { |
887 | this.editChapter.courseId = ""; | 887 | this.editChapter.courseId = ""; |
888 | this.courseData = response.data.data; | 888 | this.courseData = response.data.data; |
889 | // console.log("this.courseData", this.courseData); | 889 | // console.log("this.courseData", this.courseData); |
890 | this.showLoader = false; | 890 | this.showLoader = false; |
891 | }) | 891 | }) |
892 | .catch((err) => { | 892 | .catch((err) => { |
893 | console.log("err====>", err); | 893 | console.log("err====>", err); |
894 | this.showLoader = false; | 894 | this.showLoader = false; |
895 | }); | 895 | }); |
896 | }, | 896 | }, |
897 | getCourseDetailsList() { | 897 | getCourseDetailsList() { |
898 | this.showLoader = true; | 898 | this.showLoader = true; |
899 | http() | 899 | http() |
900 | .get("/getParticularCourseDetail", { | 900 | .get("/getParticularCourseDetail", { |
901 | params: { | 901 | params: { |
902 | courseId: this.getCourse.courseId, | 902 | courseId: this.getCourse.courseId, |
903 | }, | 903 | }, |
904 | }) | 904 | }) |
905 | .then((response) => { | 905 | .then((response) => { |
906 | this.CourseDetailsList = response.data.data; | 906 | this.CourseDetailsList = response.data.data; |
907 | if (response.data.data[0]) { | 907 | if (response.data.data[0]) { |
908 | this.chapters = response.data.data[0].chapters; | 908 | this.chapters = response.data.data[0].chapters; |
909 | } | 909 | } |
910 | this.showLoader = false; | 910 | this.showLoader = false; |
911 | }) | 911 | }) |
912 | .catch((error) => { | 912 | .catch((error) => { |
913 | // console.log("err====>", err); | 913 | // console.log("err====>", err); |
914 | this.showLoader = false; | 914 | this.showLoader = false; |
915 | if (error.response.status === 401) { | 915 | if (error.response.status === 401) { |
916 | this.$router.replace({ path: "/" }); | 916 | this.$router.replace({ path: "/" }); |
917 | this.$store.dispatch("setToken", null); | 917 | this.$store.dispatch("setToken", null); |
918 | this.$store.dispatch("Id", null); | 918 | this.$store.dispatch("Id", null); |
919 | } | 919 | } |
920 | }); | 920 | }); |
921 | }, | 921 | }, |
922 | courseTableRow(id) { | 922 | courseTableRow(id) { |
923 | this.courseId = id; | 923 | this.courseId = id; |
924 | }, | 924 | }, |
925 | addChapters(item) { | 925 | addChapters(item) { |
926 | this.editedIndex = this.CourseDetailsList.indexOf(item); | 926 | this.editedIndex = this.CourseDetailsList.indexOf(item); |
927 | this.addChapterItemObj = Object.assign({}, item); | 927 | this.addChapterItemObj = Object.assign({}, item); |
928 | this.addChapterItem.courseDetailId = this.addChapterItemObj._id; | 928 | this.addChapterItem.courseDetailId = this.addChapterItemObj._id; |
929 | this.addChapterDialog = true; | 929 | this.addChapterDialog = true; |
930 | }, | 930 | }, |
931 | submitChapter() { | 931 | submitChapter() { |
932 | this.addChapterItem.chapterPoints = []; | 932 | this.addChapterItem.chapterPoints = []; |
933 | for (let i = 0; i < this.findsChapterPoint.length; i++) { | 933 | for (let i = 0; i < this.findsChapterPoint.length; i++) { |
934 | this.addChapterItem.chapterPoints.push(this.findsChapterPoint[i].value); | 934 | this.addChapterItem.chapterPoints.push(this.findsChapterPoint[i].value); |
935 | } | 935 | } |
936 | this.loading = true; | 936 | this.loading = true; |
937 | http() | 937 | http() |
938 | .put("/addChapters", this.addChapterItem) | 938 | .put("/addChapters", this.addChapterItem) |
939 | .then((response) => { | 939 | .then((response) => { |
940 | this.addChapterDialog = false; | 940 | this.addChapterDialog = false; |
941 | this.loading = false; | 941 | this.loading = false; |
942 | this.snackbar = true; | 942 | this.snackbar = true; |
943 | this.text = response.data.message; | 943 | this.text = response.data.message; |
944 | this.color = "green"; | 944 | this.color = "green"; |
945 | this.addChapterItem = {}; | 945 | this.addChapterItem = {}; |
946 | this.removeChapterPoint(); | 946 | this.removeChapterPoint(); |
947 | this.getCourseDetailsList(); | 947 | this.getCourseDetailsList(); |
948 | }) | 948 | }) |
949 | .catch((error) => { | 949 | .catch((error) => { |
950 | this.snackbar = true; | 950 | this.snackbar = true; |
951 | this.text = error.response.data.message; | 951 | this.text = error.response.data.message; |
952 | this.color = "error"; | 952 | this.color = "error"; |
953 | this.loading = false; | 953 | this.loading = false; |
954 | }); | 954 | }); |
955 | }, | 955 | }, |
956 | profile(item) { | 956 | profile(item) { |
957 | console.log("chaper - ", item); | 957 | console.log("chaper - ", item); |
958 | this.editedIndex = this.chapters.indexOf(item); | 958 | this.editedIndex = this.chapters.indexOf(item); |
959 | this.editedItem = Object.assign({}, item); | 959 | this.editedItem = Object.assign({}, item); |
960 | this.viewProfileGallery = true; | 960 | this.viewProfileGallery = true; |
961 | }, | 961 | }, |
962 | editItem(item) { | 962 | editItem(item) { |
963 | this.editedIndex = this.CourseDetailsList.indexOf(item); | 963 | this.editedIndex = this.CourseDetailsList.indexOf(item); |
964 | this.editedCourse = Object.assign({}, item); | 964 | this.editedCourse = Object.assign({}, item); |
965 | this.editCourseDetailDialog = true; | 965 | this.editCourseDetailDialog = true; |
966 | }, | 966 | }, |
967 | editChapterItem(item) { | 967 | editChapterItem(item) { |
968 | this.editedIndex = this.chapters.indexOf(item); | 968 | this.editedIndex = this.chapters.indexOf(item); |
969 | this.editChapter = Object.assign({}, item); | 969 | this.editChapter = Object.assign({}, item); |
970 | this.updates = []; | 970 | this.updates = []; |
971 | for (let i = 0; i < this.editChapter.chapterPoints.length; i++) { | 971 | for (let i = 0; i < this.editChapter.chapterPoints.length; i++) { |
972 | this.updates.push({ value: this.editChapter.chapterPoints[i] }); | 972 | this.updates.push({ value: this.editChapter.chapterPoints[i] }); |
973 | } | 973 | } |
974 | this.editChapterDetailDialog = true; | 974 | this.editChapterDetailDialog = true; |
975 | }, | 975 | }, |
976 | deleteItem(item) { | 976 | deleteItem(item) { |
977 | let deleteGallery = { | 977 | let deleteGallery = { |
978 | courseDetailId: item._id, | 978 | courseDetailId: item._id, |
979 | }; | 979 | }; |
980 | http() | 980 | http() |
981 | .delete( | 981 | .delete( |
982 | "/deleteCourseDetail", | 982 | "/deleteCourseDetail", |
983 | confirm("Are you sure you want to delete this?") && { | 983 | confirm("Are you sure you want to delete this?") && { |
984 | params: deleteGallery, | 984 | params: deleteGallery, |
985 | headers: { | 985 | headers: { |
986 | Authorization: "Bearer " + this.token, | 986 | Authorization: "Bearer " + this.token, |
987 | }, | 987 | }, |
988 | } | 988 | } |
989 | ) | 989 | ) |
990 | .then((response) => { | 990 | .then((response) => { |
991 | this.snackbar = true; | 991 | this.snackbar = true; |
992 | this.text = "Successfully delete Course Details"; | 992 | this.text = "Successfully delete Course Details"; |
993 | this.color = "green"; | 993 | this.color = "green"; |
994 | this.getCourseDetailsList(); | 994 | this.getCourseDetailsList(); |
995 | }) | 995 | }) |
996 | .catch((error) => { | 996 | .catch((error) => { |
997 | // console.log(error); | 997 | // console.log(error); |
998 | this.snackbar = true; | 998 | this.snackbar = true; |
999 | this.text = error.response.data.message; | 999 | this.text = error.response.data.message; |
1000 | this.color = "error"; | 1000 | this.color = "error"; |
1001 | }); | 1001 | }); |
1002 | }, | 1002 | }, |
1003 | deleteChapters(item) { | 1003 | deleteChapters(item) { |
1004 | // console.log("item", item); | 1004 | // console.log("item", item); |
1005 | let deleteChapters = { | 1005 | let deleteChapters = { |
1006 | courseDetailId: this.courseId, | 1006 | courseDetailId: this.courseId, |
1007 | chapterId: item._id, | 1007 | chapterId: item._id, |
1008 | }; | 1008 | }; |
1009 | http() | 1009 | http() |
1010 | .put( | 1010 | .put( |
1011 | "/deleteChapters", | 1011 | "/deleteChapters", |
1012 | confirm("Are you sure you want to delete this?") && deleteChapters | 1012 | confirm("Are you sure you want to delete this?") && deleteChapters |
1013 | ) | 1013 | ) |
1014 | .then((response) => { | 1014 | .then((response) => { |
1015 | this.snackbar = true; | 1015 | this.snackbar = true; |
1016 | this.text = "Successfully delete Chapters"; | 1016 | this.text = "Successfully delete Chapters"; |
1017 | this.color = "green"; | 1017 | this.color = "green"; |
1018 | this.getCourseDetailsList(); | 1018 | this.getCourseDetailsList(); |
1019 | }) | 1019 | }) |
1020 | .catch((error) => { | 1020 | .catch((error) => { |
1021 | // console.log(error); | 1021 | // console.log(error); |
1022 | this.snackbar = true; | 1022 | this.snackbar = true; |
1023 | this.text = error.response.data.message; | 1023 | this.text = error.response.data.message; |
1024 | this.color = "error"; | 1024 | this.color = "error"; |
1025 | }); | 1025 | }); |
1026 | }, | 1026 | }, |
1027 | close() { | 1027 | close() { |
1028 | this.editCourseDetailDialog = false; | 1028 | this.editCourseDetailDialog = false; |
1029 | }, | 1029 | }, |
1030 | closeProfileGallery() { | 1030 | closeProfileGallery() { |
1031 | this.viewProfileGallery = false; | 1031 | this.viewProfileGallery = false; |
1032 | }, | 1032 | }, |
1033 | submit() { | 1033 | submit() { |
1034 | let chapters = []; | 1034 | let chapters = []; |
1035 | var chapterPoints = []; | 1035 | var chapterPoints = []; |
1036 | for (let i = 0; i < this.finds.length; i++) { | 1036 | for (let i = 0; i < this.finds.length; i++) { |
1037 | chapterPoints.push(this.finds[i].value); | 1037 | chapterPoints.push(this.finds[i].value); |
1038 | // console.log("this.finds[i].value", this.finds[i].value); | 1038 | // console.log("this.finds[i].value", this.finds[i].value); |
1039 | chapters = [ | 1039 | chapters = [ |
1040 | { | 1040 | { |
1041 | chapterName: this.addCourseDetail.chapterName, | 1041 | chapterName: this.addCourseDetail.chapterName, |
1042 | description: this.addCourseDetail.description, | 1042 | description: this.addCourseDetail.description, |
1043 | chapterPoints: chapterPoints, | 1043 | chapterPoints: chapterPoints, |
1044 | uploadPdf: this.pdfFile, | 1044 | uploadPdf: this.pdfFile, |
1045 | uploadPpt: this.pptFile, | 1045 | uploadPpt: this.pptFile, |
1046 | }, | 1046 | }, |
1047 | ]; | 1047 | ]; |
1048 | } | 1048 | } |
1049 | if (this.$refs.form.validate()) { | 1049 | if (this.$refs.form.validate()) { |
1050 | // console.log("this.addCourseDetail", this.addCourseDetail); | 1050 | // console.log("this.addCourseDetail", this.addCourseDetail); |
1051 | var courseDetailsData = { | 1051 | var courseDetailsData = { |
1052 | classId: this.addCourseDetail.classId, | 1052 | classId: this.addCourseDetail.classId, |
1053 | courseId: this.addCourseDetail.courseId, | 1053 | courseId: this.addCourseDetail.courseId, |
1054 | chapters: chapters, | 1054 | chapters: chapters, |
1055 | }; | 1055 | }; |
1056 | this.loading = true; | 1056 | this.loading = true; |
1057 | http() | 1057 | http() |
1058 | .post("/createCourseDetail", courseDetailsData) | 1058 | .post("/createCourseDetail", courseDetailsData) |
1059 | .then((response) => { | 1059 | .then((response) => { |
1060 | this.addCourseDetailDialog = false; | 1060 | this.addCourseDetailDialog = false; |
1061 | this.loading = false; | 1061 | this.loading = false; |
1062 | this.snackbar = true; | 1062 | this.snackbar = true; |
1063 | this.text = response.data.message; | 1063 | this.text = response.data.message; |
1064 | this.color = "green"; | 1064 | this.color = "green"; |
1065 | this.clear(); | 1065 | this.clear(); |
1066 | this.trigger = "reset"; | 1066 | this.trigger = "reset"; |
1067 | this.emptyPdf = "reset"; | 1067 | this.emptyPdf = "reset"; |
1068 | this.removeAddFind(); | 1068 | this.removeAddFind(); |
1069 | }) | 1069 | }) |
1070 | .catch((error) => { | 1070 | .catch((error) => { |
1071 | this.snackbar = true; | 1071 | this.snackbar = true; |
1072 | this.text = error.response.data.message; | 1072 | this.text = error.response.data.message; |
1073 | this.color = "error"; | 1073 | this.color = "error"; |
1074 | this.loading = false; | 1074 | this.loading = false; |
1075 | }); | 1075 | }); |
1076 | } | 1076 | } |
1077 | }, | 1077 | }, |
1078 | clear() { | 1078 | clear() { |
1079 | this.$refs.form.reset(); | 1079 | this.$refs.form.reset(); |
1080 | }, | 1080 | }, |
1081 | saveChapter() { | 1081 | saveChapter() { |
1082 | this.editedItem.courseDetailId = this.editedItem._id; | 1082 | this.editedItem.courseDetailId = this.editedItem._id; |
1083 | // console.log("this.updates", this.updates); | 1083 | // console.log("this.updates", this.updates); |
1084 | var chapterPoints = []; | 1084 | var chapterPoints = []; |
1085 | for (let i = 0; i < this.updates.length; i++) { | 1085 | for (let i = 0; i < this.updates.length; i++) { |
1086 | chapterPoints.push(this.updates[i].value); | 1086 | chapterPoints.push(this.updates[i].value); |
1087 | } | 1087 | } |
1088 | var updateData = { | 1088 | var updateData = { |
1089 | courseDetailId: this.courseId, | 1089 | courseDetailId: this.courseId, |
1090 | chapterId: this.editChapter._id, | 1090 | chapterId: this.editChapter._id, |
1091 | chapterName: this.editChapter.chapterName, | 1091 | chapterName: this.editChapter.chapterName, |
1092 | description: this.editChapter.description, | 1092 | description: this.editChapter.description, |
1093 | chapterPoints: chapterPoints, | 1093 | chapterPoints: chapterPoints, |
1094 | uploadPdf: this.pdfFile, | 1094 | uploadPdf: this.pdfFile, |
1095 | uploadPpt: this.pptFile, | 1095 | uploadPpt: this.pptFile, |
1096 | }; | 1096 | }; |
1097 | this.editLoading = true; | 1097 | this.editLoading = true; |
1098 | http() | 1098 | http() |
1099 | .put("/updateChapters", updateData) | 1099 | .put("/updateChapters", updateData) |
1100 | .then((response) => { | 1100 | .then((response) => { |
1101 | this.editChapterDetailDialog = false; | 1101 | this.editChapterDetailDialog = false; |
1102 | this.snackbar = true; | 1102 | this.snackbar = true; |
1103 | this.text = response.data.message; | 1103 | this.text = response.data.message; |
1104 | this.color = "green"; | 1104 | this.color = "green"; |
1105 | this.editLoading = false; | 1105 | this.editLoading = false; |
1106 | // this.removeUpdatePoints(); | 1106 | // this.removeUpdatePoints(); |
1107 | this.trigger = "reset"; | 1107 | this.trigger = "reset"; |
1108 | this.emptyPdf = "reset"; | 1108 | this.emptyPdf = "reset"; |
1109 | this.getCourseDetailsList(); | 1109 | this.getCourseDetailsList(); |
1110 | }) | 1110 | }) |
1111 | .catch((error) => { | 1111 | .catch((error) => { |
1112 | this.editLoading = false; | 1112 | this.editLoading = false; |
1113 | this.snackbar = true; | 1113 | this.snackbar = true; |
1114 | this.text = error.response.data.message; | 1114 | this.text = error.response.data.message; |
1115 | this.color = "error"; | 1115 | this.color = "error"; |
1116 | }); | 1116 | }); |
1117 | }, | 1117 | }, |
1118 | save() { | 1118 | save() { |
1119 | var updateData = { | 1119 | var updateData = { |
1120 | courseDetailId: this.editedCourse._id, | 1120 | courseDetailId: this.editedCourse._id, |
1121 | courseId: this.editedCourse.courseId, | 1121 | courseId: this.editedCourse.courseId, |
1122 | classId: this.editedCourse.classId, | 1122 | classId: this.editedCourse.classId, |
1123 | }; | 1123 | }; |
1124 | this.editLoading = true; | 1124 | this.editLoading = true; |
1125 | http() | 1125 | http() |
1126 | .put("/updateCourseDetail", updateData) | 1126 | .put("/updateCourseDetail", updateData) |
1127 | .then((response) => { | 1127 | .then((response) => { |
1128 | this.getCourseDetailsList(); | 1128 | this.getCourseDetailsList(); |
1129 | this.editCourseDetailDialog = false; | 1129 | this.editCourseDetailDialog = false; |
1130 | this.snackbar = true; | 1130 | this.snackbar = true; |
1131 | this.text = response.data.message; | 1131 | this.text = response.data.message; |
1132 | this.color = "green"; | 1132 | this.color = "green"; |
1133 | this.editLoading = false; | 1133 | this.editLoading = false; |
1134 | // this.editChapterPointName = ""; | 1134 | // this.editChapterPointName = ""; |
1135 | this.editFiles = []; | 1135 | this.editFiles = []; |
1136 | }) | 1136 | }) |
1137 | .catch((error) => { | 1137 | .catch((error) => { |
1138 | this.editLoading = false; | 1138 | this.editLoading = false; |
1139 | this.snackbar = true; | 1139 | this.snackbar = true; |
1140 | this.text = error.response.data.message; | 1140 | this.text = error.response.data.message; |
1141 | this.color = "error"; | 1141 | this.color = "error"; |
1142 | }); | 1142 | }); |
1143 | }, | 1143 | }, |
1144 | getAllClasses() { | 1144 | getAllClasses() { |
1145 | http() | 1145 | http() |
1146 | .get("/getClassesList", { | 1146 | .get("/getClassesList", { |
1147 | headers: { Authorization: "Bearer " + this.token }, | 1147 | headers: { Authorization: "Bearer " + this.token }, |
1148 | }) | 1148 | }) |
1149 | .then((response) => { | 1149 | .then((response) => { |
1150 | this.addclass = response.data.data; | 1150 | this.addclass = response.data.data; |
1151 | }) | 1151 | }) |
1152 | .catch((err) => { | 1152 | .catch((err) => { |
1153 | // console.log("err====>", err); | 1153 | // console.log("err====>", err); |
1154 | }); | 1154 | }); |
1155 | }, | 1155 | }, |
1156 | removeChapterPoint: function () { | 1156 | removeChapterPoint: function () { |
1157 | this.findsChapterPoint = [{ value: "" }]; | 1157 | this.findsChapterPoint = [{ value: "" }]; |
1158 | }, | 1158 | }, |
1159 | removeAddFind: function () { | 1159 | removeAddFind: function () { |
1160 | this.finds = [{ value: "" }]; | 1160 | this.finds = [{ value: "" }]; |
1161 | }, | 1161 | }, |
1162 | addFind: function () { | 1162 | addFind: function () { |
1163 | this.finds.push({ value: "" }); | 1163 | this.finds.push({ value: "" }); |
1164 | }, | 1164 | }, |
1165 | addChapterPoint: function () { | 1165 | addChapterPoint: function () { |
1166 | this.findsChapterPoint.push({ value: "" }); | 1166 | this.findsChapterPoint.push({ value: "" }); |
1167 | }, | 1167 | }, |
1168 | update: function () { | 1168 | update: function () { |
1169 | this.updates.push({ value: "" }); | 1169 | this.updates.push({ value: "" }); |
1170 | }, | 1170 | }, |
1171 | // removeUpdatePoints: function() { | 1171 | // removeUpdatePoints: function() { |
1172 | // this.updates = [{ value: "" }]; | 1172 | // this.updates = [{ value: "" }]; |
1173 | // }, | 1173 | // }, |
1174 | deleteFind: function (index) { | 1174 | deleteFind: function (index) { |
1175 | this.finds.splice(index, 1); | 1175 | this.finds.splice(index, 1); |
1176 | if (index === 0) this.addFind(); | 1176 | if (index === 0) this.addFind(); |
1177 | }, | 1177 | }, |
1178 | deleteChapterPoint: function (index) { | 1178 | deleteChapterPoint: function (index) { |
1179 | this.findsChapterPoint.splice(index, 1); | 1179 | this.findsChapterPoint.splice(index, 1); |
1180 | if (index === 0) this.addChapterPoint(); | 1180 | if (index === 0) this.addChapterPoint(); |
1181 | }, | 1181 | }, |
1182 | deleteUpdate: function (index) { | 1182 | deleteUpdate: function (index) { |
1183 | this.updates.splice(index, 1); | 1183 | this.updates.splice(index, 1); |
1184 | if (index === 0) this.update(); | 1184 | if (index === 0) this.update(); |
1185 | }, | 1185 | }, |
1186 | deleteUrl: function (index, youTubelinkId, id) { | 1186 | deleteUrl: function (index, youTubelinkId, id) { |
1187 | this.editChapter.chapterPoints.splice(index, 1); | 1187 | this.editChapter.chapterPoints.splice(index, 1); |
1188 | if (index === 0) this.update(); | 1188 | if (index === 0) this.update(); |
1189 | }, | 1189 | }, |
1190 | displaySearch() { | 1190 | displaySearch() { |
1191 | this.show = false; | 1191 | this.show = false; |
1192 | this.showSearch = true; | 1192 | this.showSearch = true; |
1193 | }, | 1193 | }, |
1194 | closeSearch() { | 1194 | closeSearch() { |
1195 | this.showSearch = false; | 1195 | this.showSearch = false; |
1196 | this.show = true; | 1196 | this.show = true; |
1197 | this.search = ""; | 1197 | this.search = ""; |
1198 | }, | 1198 | }, |
1199 | }, | 1199 | }, |
1200 | mounted() { | 1200 | mounted() { |
1201 | this.token = this.$store.state.token; | 1201 | this.token = this.$store.state.token; |
1202 | this.getAllClasses(); | 1202 | this.getAllClasses(); |
1203 | }, | 1203 | }, |
1204 | }; | 1204 | }; |
1205 | </script> | 1205 | </script> |
src/pages/Students/students.vue
1 | <template> | 1 | <template> |
2 | <v-container fluid class="body-color"> | 2 | <v-container fluid class="body-color"> |
3 | <!-- ****** EDITS STUDENTS DETAILS ****** --> | 3 | <!-- ****** EDITS STUDENTS DETAILS ****** --> |
4 | <v-dialog v-model="editStudentDialog" max-width="1700px" scrollable> | 4 | <v-dialog v-model="editStudentDialog" max-width="1700px" scrollable> |
5 | <v-card flat class="card-style pa-2" dark> | 5 | <v-card flat class="card-style pa-2" dark> |
6 | <v-layout> | 6 | <v-layout> |
7 | <v-flex xs12> | 7 | <v-flex xs12> |
8 | <label class="title text-xs-center">Edit Student Details</label> | 8 | <label class="title text-xs-center">Edit Student Details</label> |
9 | <v-icon size="24" class="right" @click="editStudentDialog = false">cancel</v-icon> | 9 | <v-icon size="24" class="right" @click="editStudentDialog = false">cancel</v-icon> |
10 | </v-flex> | 10 | </v-flex> |
11 | </v-layout> | 11 | </v-layout> |
12 | <v-card-text> | 12 | <v-card-text> |
13 | <v-form ref="form"> | 13 | <v-form ref="form"> |
14 | <v-container fluid> | 14 | <v-container fluid> |
15 | <v-layout> | 15 | <v-layout> |
16 | <v-flex xs12 class="text-xs-center text-sm-center text-md-center text-lg-center"> | 16 | <v-flex xs12 class="text-xs-center text-sm-center text-md-center text-lg-center"> |
17 | <v-avatar size="100px" v-if="!editedItem.profilePicUrl && !editImageUrl"> | 17 | <v-avatar size="100px" v-if="!editedItem.profilePicUrl && !editImageUrl"> |
18 | <img src="/static/icon/user.png" /> | 18 | <img src="/static/icon/user.png" /> |
19 | </v-avatar> | 19 | </v-avatar> |
20 | <img | 20 | <img |
21 | :src="editedItem.profilePicUrl" | 21 | :src="editedItem.profilePicUrl" |
22 | v-else-if="editedItem.profilePicUrl && !editImageUrl" | 22 | v-else-if="editedItem.profilePicUrl && !editImageUrl" |
23 | height="150" | 23 | height="150" |
24 | style="border-radius:50%; width:150px" | 24 | style="border-radius:50%; width:150px" |
25 | /> | 25 | /> |
26 | <img | 26 | <img |
27 | v-if="editImageUrl" | 27 | v-if="editImageUrl" |
28 | :src="editImageUrl" | 28 | :src="editImageUrl" |
29 | style="border-radius:50%; width:150px;height:150px" | 29 | style="border-radius:50%; width:150px;height:150px" |
30 | /> | 30 | /> |
31 | <input | 31 | <input |
32 | type="file" | 32 | type="file" |
33 | style="display: none" | 33 | style="display: none" |
34 | ref="editDataImage" | 34 | ref="editDataImage" |
35 | accept="image/*" | 35 | accept="image/*" |
36 | @change="onEditFilePicked" | 36 | @change="onEditFilePicked" |
37 | /> | 37 | /> |
38 | </v-flex> | 38 | </v-flex> |
39 | </v-layout> | 39 | </v-layout> |
40 | <v-layout wrap> | 40 | <v-layout wrap> |
41 | <v-flex xs12 sm4> | 41 | <v-flex xs12 sm4> |
42 | <v-layout> | 42 | <v-layout> |
43 | <v-flex xs4 class="pt-4 subheading"> | 43 | <v-flex xs4 class="pt-4 subheading"> |
44 | <label class="right hidden-xs-only hidden-sm-only">Select Class:</label> | 44 | <label class="right hidden-xs-only hidden-sm-only">Select Class:</label> |
45 | <label class="right hidden-lg-only hidden-md-only hidden-xl-only">Class:</label> | 45 | <label class="right hidden-lg-only hidden-md-only hidden-xl-only">Class:</label> |
46 | </v-flex> | 46 | </v-flex> |
47 | <v-flex xs8 class="ml-3"> | 47 | <v-flex xs8 class="ml-3"> |
48 | <v-select | 48 | <v-select |
49 | :items="addclass" | 49 | :items="addclass" |
50 | label="Select Class" | 50 | label="Select Class" |
51 | v-model="editedItem.select" | 51 | v-model="editedItem.select" |
52 | item-text="classNum" | 52 | item-text="classNum" |
53 | item-value="_id" | 53 | item-value="_id" |
54 | name="Select Class" | 54 | name="Select Class" |
55 | @change="getSections(editedItem.select)" | 55 | @change="getSections(editedItem.select)" |
56 | required | 56 | required |
57 | ></v-select> | 57 | ></v-select> |
58 | </v-flex> | 58 | </v-flex> |
59 | </v-layout> | 59 | </v-layout> |
60 | </v-flex> | 60 | </v-flex> |
61 | <v-flex xs12 sm4> | 61 | <v-flex xs12 sm4> |
62 | <v-layout> | 62 | <v-layout> |
63 | <v-flex xs4 class="pt-4 subheading"> | 63 | <v-flex xs4 class="pt-4 subheading"> |
64 | <label class="right hidden-xs-only hidden-sm-only">Select Section:</label> | 64 | <label class="right hidden-xs-only hidden-sm-only">Select Section:</label> |
65 | <label class="right hidden-lg-only hidden-md-only hidden-xl-only">Section:</label> | 65 | <label class="right hidden-lg-only hidden-md-only hidden-xl-only">Section:</label> |
66 | </v-flex> | 66 | </v-flex> |
67 | <v-flex xs8 class="ml-3"> | 67 | <v-flex xs8 class="ml-3"> |
68 | <v-select | 68 | <v-select |
69 | :items="addSection" | 69 | :items="addSection" |
70 | label="Select Section" | 70 | label="Select Section" |
71 | v-model="editedItem.selectSection" | 71 | v-model="editedItem.selectSection" |
72 | item-text="name" | 72 | item-text="name" |
73 | item-value="_id" | 73 | item-value="_id" |
74 | name="Select Section" | 74 | name="Select Section" |
75 | required | 75 | required |
76 | ></v-select> | 76 | ></v-select> |
77 | </v-flex> | 77 | </v-flex> |
78 | </v-layout> | 78 | </v-layout> |
79 | </v-flex> | 79 | </v-flex> |
80 | <v-flex xs12 sm4> | 80 | <v-flex xs12 sm4> |
81 | <v-layout> | 81 | <v-layout> |
82 | <v-flex xs4 class="pt-4 subheading"> | 82 | <v-flex xs4 class="pt-4 subheading"> |
83 | <label class="right hidden-xs-only hidden-sm-only">Full Name:</label> | 83 | <label class="right hidden-xs-only hidden-sm-only">Full Name:</label> |
84 | <label class="right hidden-lg-only hidden-md-only hidden-xl-only">Name:</label> | 84 | <label class="right hidden-lg-only hidden-md-only hidden-xl-only">Name:</label> |
85 | </v-flex> | 85 | </v-flex> |
86 | <v-flex xs8 class="ml-3"> | 86 | <v-flex xs8 class="ml-3"> |
87 | <v-text-field | 87 | <v-text-field |
88 | v-model="editedItem.name" | 88 | v-model="editedItem.name" |
89 | placeholder="fill your full Name" | 89 | placeholder="fill your full Name" |
90 | name="name" | 90 | name="name" |
91 | type="text" | 91 | type="text" |
92 | required | 92 | required |
93 | ></v-text-field> | 93 | ></v-text-field> |
94 | </v-flex> | 94 | </v-flex> |
95 | </v-layout> | 95 | </v-layout> |
96 | </v-flex> | 96 | </v-flex> |
97 | </v-layout> | 97 | </v-layout> |
98 | <v-layout wrap> | 98 | <v-layout wrap> |
99 | <v-flex xs12 sm4> | 99 | <v-flex xs12 sm4> |
100 | <v-layout> | 100 | <v-layout> |
101 | <v-flex xs4 class="pt-4 subheading"> | 101 | <v-flex xs4 class="pt-4 subheading"> |
102 | <label class="right hidden-xs-only hidden-sm-only">Email Id:</label> | 102 | <label class="right hidden-xs-only hidden-sm-only">Email Id:</label> |
103 | <label class="right hidden-lg-only hidden-md-only hidden-xl-only">Email:</label> | 103 | <label class="right hidden-lg-only hidden-md-only hidden-xl-only">Email:</label> |
104 | </v-flex> | 104 | </v-flex> |
105 | <v-flex xs8 class="ml-3"> | 105 | <v-flex xs8 class="ml-3"> |
106 | <v-text-field | 106 | <v-text-field |
107 | placeholder="fill your email" | 107 | placeholder="fill your email" |
108 | v-model="editedItem.email" | 108 | v-model="editedItem.email" |
109 | type="text" | 109 | type="text" |
110 | name="email" | 110 | name="email" |
111 | required | 111 | required |
112 | ></v-text-field> | 112 | ></v-text-field> |
113 | </v-flex> | 113 | </v-flex> |
114 | </v-layout> | 114 | </v-layout> |
115 | </v-flex> | 115 | </v-flex> |
116 | <v-flex xs12 sm4> | 116 | <v-flex xs12 sm4> |
117 | <v-layout> | 117 | <v-layout> |
118 | <v-flex xs4 class="pt-4 subheading"> | 118 | <v-flex xs4 class="pt-4 subheading"> |
119 | <label class="right hidden-sm-only hidden-xs-only">Date of Birth:</label> | 119 | <label class="right hidden-sm-only hidden-xs-only">Date of Birth:</label> |
120 | <label class="right hidden-lg-only hidden-xl-only hidden-md-only">D.O.B:</label> | 120 | <label class="right hidden-lg-only hidden-xl-only hidden-md-only">D.O.B:</label> |
121 | </v-flex> | 121 | </v-flex> |
122 | <v-flex xs8 class="ml-3"> | 122 | <v-flex xs8 class="ml-3"> |
123 | <v-menu | 123 | <v-menu |
124 | ref="menu" | 124 | ref="menu" |
125 | :close-on-content-click="false" | 125 | :close-on-content-click="false" |
126 | v-model="menu1" | 126 | v-model="menu1" |
127 | :nudge-right="40" | 127 | :nudge-right="40" |
128 | lazy | 128 | lazy |
129 | transition="scale-transition" | 129 | transition="scale-transition" |
130 | offset-y | 130 | offset-y |
131 | full-width | 131 | full-width |
132 | min-width="290px" | 132 | min-width="290px" |
133 | > | 133 | > |
134 | <v-text-field | 134 | <v-text-field |
135 | slot="activator" | 135 | slot="activator" |
136 | v-model="editedItem.dob" | 136 | v-model="editedItem.dob" |
137 | placeholder="Select Dob" | 137 | placeholder="Select Dob" |
138 | ></v-text-field> | 138 | ></v-text-field> |
139 | <v-date-picker | 139 | <v-date-picker |
140 | ref="picker" | 140 | ref="picker" |
141 | v-model="editedItem.dob" | 141 | v-model="editedItem.dob" |
142 | :max="new Date().toISOString().substr(0, 10)" | 142 | :max="new Date().toISOString().substr(0, 10)" |
143 | min="1950-01-01" | 143 | min="1950-01-01" |
144 | @input="menu1 = false" | 144 | @input="menu1 = false" |
145 | ></v-date-picker> | 145 | ></v-date-picker> |
146 | </v-menu> | 146 | </v-menu> |
147 | </v-flex> | 147 | </v-flex> |
148 | </v-layout> | 148 | </v-layout> |
149 | </v-flex> | 149 | </v-flex> |
150 | <v-flex xs12 sm4> | 150 | <v-flex xs12 sm4> |
151 | <v-layout> | 151 | <v-layout> |
152 | <v-flex xs4 class="pt-4 subheading"> | 152 | <v-flex xs4 class="pt-4 subheading"> |
153 | <label class="right">City:</label> | 153 | <label class="right">City:</label> |
154 | </v-flex> | 154 | </v-flex> |
155 | <v-flex xs8 class="ml-3"> | 155 | <v-flex xs8 class="ml-3"> |
156 | <v-text-field | 156 | <v-text-field |
157 | v-model="editedItem.city" | 157 | v-model="editedItem.city" |
158 | placeholder="fill your City Name" | 158 | placeholder="fill your City Name" |
159 | name="City" | 159 | name="City" |
160 | type="text" | 160 | type="text" |
161 | required | 161 | required |
162 | ></v-text-field> | 162 | ></v-text-field> |
163 | </v-flex> | 163 | </v-flex> |
164 | </v-layout> | 164 | </v-layout> |
165 | </v-flex> | 165 | </v-flex> |
166 | </v-layout> | 166 | </v-layout> |
167 | <v-layout wrap> | 167 | <v-layout wrap> |
168 | <v-flex xs12 sm4> | 168 | <v-flex xs12 sm4> |
169 | <v-layout> | 169 | <v-layout> |
170 | <v-flex xs4 class="pt-4 subheading"> | 170 | <v-flex xs4 class="pt-4 subheading"> |
171 | <label class="right hidden-xs-only hidden-sm-only">Blood Group:</label> | 171 | <label class="right hidden-xs-only hidden-sm-only">Blood Group:</label> |
172 | <label class="right hidden-lg-only hidden-md-only hidden-xl-only">Blood:</label> | 172 | <label class="right hidden-lg-only hidden-md-only hidden-xl-only">Blood:</label> |
173 | </v-flex> | 173 | </v-flex> |
174 | <v-flex xs8 class="ml-3"> | 174 | <v-flex xs8 class="ml-3"> |
175 | <v-text-field | 175 | <v-text-field |
176 | v-model="editedItem.bloodGroup" | 176 | v-model="editedItem.bloodGroup" |
177 | placeholder="fill your BloodGroup" | 177 | placeholder="fill your BloodGroup" |
178 | name="state" | 178 | name="state" |
179 | type="text" | 179 | type="text" |
180 | required | 180 | required |
181 | ></v-text-field> | 181 | ></v-text-field> |
182 | </v-flex> | 182 | </v-flex> |
183 | </v-layout> | 183 | </v-layout> |
184 | </v-flex> | 184 | </v-flex> |
185 | <v-flex xs12 sm4> | 185 | <v-flex xs12 sm4> |
186 | <v-layout> | 186 | <v-layout> |
187 | <v-flex xs4 class="pt-4 subheading"> | 187 | <v-flex xs4 class="pt-4 subheading"> |
188 | <label class="right">Gender:</label> | 188 | <label class="right">Gender:</label> |
189 | </v-flex> | 189 | </v-flex> |
190 | <v-flex xs8 class="ml-3"> | 190 | <v-flex xs8 class="ml-3"> |
191 | <v-select | 191 | <v-select |
192 | :items="gender" | 192 | :items="gender" |
193 | v-model="editedItem.gender" | 193 | v-model="editedItem.gender" |
194 | placeholder="Select Gender" | 194 | placeholder="Select Gender" |
195 | required | 195 | required |
196 | ></v-select> | 196 | ></v-select> |
197 | </v-flex> | 197 | </v-flex> |
198 | </v-layout> | 198 | </v-layout> |
199 | </v-flex> | 199 | </v-flex> |
200 | <v-flex xs12 sm4> | 200 | <v-flex xs12 sm4> |
201 | <v-layout> | 201 | <v-layout> |
202 | <v-flex xs4 class="pt-4 subheading"> | 202 | <v-flex xs4 class="pt-4 subheading"> |
203 | <label class="right">Medical Notes:</label> | 203 | <label class="right">Medical Notes:</label> |
204 | </v-flex> | 204 | </v-flex> |
205 | <v-flex xs8 class="ml-3"> | 205 | <v-flex xs8 class="ml-3"> |
206 | <v-text-field | 206 | <v-text-field |
207 | v-model="editedItem.medicalNotes" | 207 | v-model="editedItem.medicalNotes" |
208 | placeholder="fill your medicalNotes" | 208 | placeholder="fill your medicalNotes" |
209 | required | 209 | required |
210 | ></v-text-field> | 210 | ></v-text-field> |
211 | </v-flex> | 211 | </v-flex> |
212 | </v-layout> | 212 | </v-layout> |
213 | </v-flex> | 213 | </v-flex> |
214 | </v-layout> | 214 | </v-layout> |
215 | <v-layout wrap> | 215 | <v-layout wrap> |
216 | <v-flex xs12 sm4> | 216 | <v-flex xs12 sm4> |
217 | <v-layout> | 217 | <v-layout> |
218 | <v-flex xs4 class="pt-4 subheading"> | 218 | <v-flex xs4 class="pt-4 subheading"> |
219 | <label class="right">Height:</label> | 219 | <label class="right">Height:</label> |
220 | </v-flex> | 220 | </v-flex> |
221 | <v-flex xs8 class="ml-3"> | 221 | <v-flex xs8 class="ml-3"> |
222 | <v-text-field | 222 | <v-text-field |
223 | v-model="editedItem.height" | 223 | v-model="editedItem.height" |
224 | placeholder="fill your Height" | 224 | placeholder="fill your Height" |
225 | name="state" | 225 | name="state" |
226 | type="text" | 226 | type="text" |
227 | required | 227 | required |
228 | ></v-text-field> | 228 | ></v-text-field> |
229 | </v-flex> | 229 | </v-flex> |
230 | </v-layout> | 230 | </v-layout> |
231 | </v-flex> | 231 | </v-flex> |
232 | <v-flex xs12 sm4> | 232 | <v-flex xs12 sm4> |
233 | <v-layout> | 233 | <v-layout> |
234 | <v-flex xs4 class="pt-4 subheading"> | 234 | <v-flex xs4 class="pt-4 subheading"> |
235 | <label class="right">Weight:</label> | 235 | <label class="right">Weight:</label> |
236 | </v-flex> | 236 | </v-flex> |
237 | <v-flex xs8 class="ml-3"> | 237 | <v-flex xs8 class="ml-3"> |
238 | <v-text-field | 238 | <v-text-field |
239 | v-model="editedItem.weight" | 239 | v-model="editedItem.weight" |
240 | placeholder="fill your Weight" | 240 | placeholder="fill your Weight" |
241 | name="pincode" | 241 | name="pincode" |
242 | required | 242 | required |
243 | ></v-text-field> | 243 | ></v-text-field> |
244 | </v-flex> | 244 | </v-flex> |
245 | </v-layout> | 245 | </v-layout> |
246 | </v-flex> | 246 | </v-flex> |
247 | <v-flex xs12 sm4> | 247 | <v-flex xs12 sm4> |
248 | <v-layout> | 248 | <v-layout> |
249 | <v-flex xs4 class="pt-4 subheading"> | 249 | <v-flex xs4 class="pt-4 subheading"> |
250 | <label class="right hidden-xs-only hidden-sm-only">Uplaod Image:</label> | 250 | <label class="right hidden-xs-only hidden-sm-only">Uplaod Image:</label> |
251 | <label class="right hidden-lg-only hidden-md-only hidden-xl-only">Uplaod:</label> | 251 | <label class="right hidden-lg-only hidden-md-only hidden-xl-only">Uplaod:</label> |
252 | </v-flex> | 252 | </v-flex> |
253 | <v-flex xs8 class="ml-3"> | 253 | <v-flex xs8 class="ml-3"> |
254 | <v-text-field | 254 | <v-text-field |
255 | label="Select Image" | 255 | label="Select Image" |
256 | @click="pickEditFile" | 256 | @click="pickEditFile" |
257 | v-model="editImageName" | 257 | v-model="editImageName" |
258 | append-icon="attach_file" | 258 | append-icon="attach_file" |
259 | ></v-text-field> | 259 | ></v-text-field> |
260 | </v-flex> | 260 | </v-flex> |
261 | </v-layout> | 261 | </v-layout> |
262 | </v-flex> | 262 | </v-flex> |
263 | </v-layout> | 263 | </v-layout> |
264 | <v-layout wrap> | 264 | <v-layout wrap> |
265 | <v-flex xs12 sm4> | 265 | <v-flex xs12 sm4> |
266 | <v-layout> | 266 | <v-layout> |
267 | <v-flex xs4 class="pt-4 subheading"> | 267 | <v-flex xs4 class="pt-4 subheading"> |
268 | <label class="right">State:</label> | 268 | <label class="right">State:</label> |
269 | </v-flex> | 269 | </v-flex> |
270 | <v-flex xs8 class="ml-3"> | 270 | <v-flex xs8 class="ml-3"> |
271 | <v-text-field | 271 | <v-text-field |
272 | v-model="editedItem.state" | 272 | v-model="editedItem.state" |
273 | placeholder="fill your State Name" | 273 | placeholder="fill your State Name" |
274 | name="state" | 274 | name="state" |
275 | type="text" | 275 | type="text" |
276 | required | 276 | required |
277 | ></v-text-field> | 277 | ></v-text-field> |
278 | </v-flex> | 278 | </v-flex> |
279 | </v-layout> | 279 | </v-layout> |
280 | </v-flex> | 280 | </v-flex> |
281 | <v-flex xs12 sm4> | 281 | <v-flex xs12 sm4> |
282 | <v-layout> | 282 | <v-layout> |
283 | <v-flex xs4 class="pt-4 subheading"> | 283 | <v-flex xs4 class="pt-4 subheading"> |
284 | <label class="right">Pincode:</label> | 284 | <label class="right">Pincode:</label> |
285 | </v-flex> | 285 | </v-flex> |
286 | <v-flex xs8 class="ml-3"> | 286 | <v-flex xs8 class="ml-3"> |
287 | <v-text-field | 287 | <v-text-field |
288 | v-model="editedItem.pincode" | 288 | v-model="editedItem.pincode" |
289 | placeholder="fill your pincode" | 289 | placeholder="fill your pincode" |
290 | name="pincode" | 290 | name="pincode" |
291 | type="number" | 291 | type="number" |
292 | required | 292 | required |
293 | ></v-text-field> | 293 | ></v-text-field> |
294 | </v-flex> | 294 | </v-flex> |
295 | </v-layout> | 295 | </v-layout> |
296 | </v-flex> | 296 | </v-flex> |
297 | <v-flex xs12 sm4> | 297 | <v-flex xs12 sm4> |
298 | <v-layout> | 298 | <v-layout> |
299 | <v-flex xs4 class="pt-4 subheading"> | 299 | <v-flex xs4 class="pt-4 subheading"> |
300 | <label class="right hidden-xs-only hidden-sm-only">Mobile No:</label> | 300 | <label class="right hidden-xs-only hidden-sm-only">Mobile No:</label> |
301 | <label class="right hidden-lg-only hidden-md-only hidden-xl-only">Mobile:</label> | 301 | <label class="right hidden-lg-only hidden-md-only hidden-xl-only">Mobile:</label> |
302 | </v-flex> | 302 | </v-flex> |
303 | <v-flex xs8 class="ml-3"> | 303 | <v-flex xs8 class="ml-3"> |
304 | <v-text-field | 304 | <v-text-field |
305 | v-model="editedItem.mobile" | 305 | v-model="editedItem.mobile" |
306 | placeholder="fill your MobileNo" | 306 | placeholder="fill your MobileNo" |
307 | name="mobileNo" | 307 | name="mobileNo" |
308 | type="number" | 308 | type="number" |
309 | required | 309 | required |
310 | ></v-text-field> | 310 | ></v-text-field> |
311 | </v-flex> | 311 | </v-flex> |
312 | </v-layout> | 312 | </v-layout> |
313 | </v-flex> | 313 | </v-flex> |
314 | </v-layout> | 314 | </v-layout> |
315 | <v-layout wrap> | 315 | <v-layout wrap> |
316 | <v-flex xs12 sm4> | 316 | <v-flex xs12 sm4> |
317 | <v-layout> | 317 | <v-layout> |
318 | <v-flex xs4 class="pt-4 subheading"> | 318 | <v-flex xs4 class="pt-4 subheading"> |
319 | <label class="right hidden-xs-only hidden-sm-only">Select Country:</label> | 319 | <label class="right hidden-xs-only hidden-sm-only">Select Country:</label> |
320 | <label class="right hidden-lg-only hidden-md-only hidden-xl-only">Country:</label> | 320 | <label class="right hidden-lg-only hidden-md-only hidden-xl-only">Country:</label> |
321 | </v-flex> | 321 | </v-flex> |
322 | <v-flex xs8 class="ml-3"> | 322 | <v-flex xs8 class="ml-3"> |
323 | <v-autocomplete | 323 | <v-autocomplete |
324 | v-model="editedItem.country" | 324 | v-model="editedItem.country" |
325 | :items="countries" | 325 | :items="countries" |
326 | placeholder="Select Country Name" | 326 | placeholder="Select Country Name" |
327 | required | 327 | required |
328 | ></v-autocomplete> | 328 | ></v-autocomplete> |
329 | </v-flex> | 329 | </v-flex> |
330 | </v-layout> | 330 | </v-layout> |
331 | </v-flex> | 331 | </v-flex> |
332 | <v-flex xs12 sm4 class="hidden-xs-only hidden-sm-only"> | 332 | <v-flex xs12 sm4 class="hidden-xs-only hidden-sm-only"> |
333 | <v-layout> | 333 | <v-layout> |
334 | <v-flex xs4 class="pt-4 subheading"> | 334 | <v-flex xs4 class="pt-4 subheading"> |
335 | <label class="right hidden-xs-only hidden-sm-only">Roll Number:</label> | 335 | <label class="right hidden-xs-only hidden-sm-only">Roll Number:</label> |
336 | <label class="right hidden-lg-only hidden-md-only hidden-xl-only">Roll No:</label> | 336 | <label class="right hidden-lg-only hidden-md-only hidden-xl-only">Roll No:</label> |
337 | </v-flex> | 337 | </v-flex> |
338 | <v-flex xs8 class="ml-3"> | 338 | <v-flex xs8 class="ml-3"> |
339 | <v-text-field | 339 | <v-text-field |
340 | v-model="editedItem.rollNo" | 340 | v-model="editedItem.rollNo" |
341 | placeholder="fill roll number" | 341 | placeholder="fill roll number" |
342 | required | 342 | required |
343 | ></v-text-field> | 343 | ></v-text-field> |
344 | </v-flex> | 344 | </v-flex> |
345 | </v-layout> | 345 | </v-layout> |
346 | </v-flex> | 346 | </v-flex> |
347 | <v-flex xs12 sm4 class="hidden-xs-only hidden-sm-only"> | 347 | <v-flex xs12 sm4 class="hidden-xs-only hidden-sm-only"> |
348 | <v-layout> | 348 | <v-layout> |
349 | <v-flex xs4 sm4 class="pt-4 subheading"> | 349 | <v-flex xs4 sm4 class="pt-4 subheading"> |
350 | <label class="right hidden-xs-only hidden-sm-only">Permanent Address:</label> | 350 | <label class="right hidden-xs-only hidden-sm-only">Permanent Address:</label> |
351 | <label | 351 | <label |
352 | class="right hidden-lg-only hidden-md-only hidden-xl-only" | 352 | class="right hidden-lg-only hidden-md-only hidden-xl-only" |
353 | >Permanent Address:</label> | 353 | >Permanent Address:</label> |
354 | </v-flex> | 354 | </v-flex> |
355 | <v-flex xs12 sm8 class="ml-3"> | 355 | <v-flex xs12 sm8 class="ml-3"> |
356 | <v-text-field | 356 | <v-text-field |
357 | v-model="editedItem.permanentAddress" | 357 | v-model="editedItem.permanentAddress" |
358 | placeholder="fill Your Permanent Address" | 358 | placeholder="fill Your Permanent Address" |
359 | required | 359 | required |
360 | ></v-text-field> | 360 | ></v-text-field> |
361 | </v-flex> | 361 | </v-flex> |
362 | </v-layout> | 362 | </v-layout> |
363 | </v-flex> | 363 | </v-flex> |
364 | </v-layout> | 364 | </v-layout> |
365 | <v-layout class="hidden-xs-only hidden-sm-only"> | 365 | <v-layout class="hidden-xs-only hidden-sm-only"> |
366 | <v-flex xs12 sm4> | 366 | <v-flex xs12 sm4> |
367 | <v-layout> | 367 | <v-layout> |
368 | <v-flex xs4 class="pt-4 subheading"> | 368 | <v-flex xs4 class="pt-4 subheading"> |
369 | <label class="right hidden-xs-only hidden-sm-only">Present Address:</label> | 369 | <label class="right hidden-xs-only hidden-sm-only">Present Address:</label> |
370 | <label | 370 | <label |
371 | class="right hidden-lg-only hidden-md-only hidden-xl-only" | 371 | class="right hidden-lg-only hidden-md-only hidden-xl-only" |
372 | >Present Address:</label> | 372 | >Present Address:</label> |
373 | </v-flex> | 373 | </v-flex> |
374 | <v-flex xs8 class="ml-3"> | 374 | <v-flex xs8 class="ml-3"> |
375 | <v-text-field | 375 | <v-text-field |
376 | v-model="editedItem.presentAddress" | 376 | v-model="editedItem.presentAddress" |
377 | placeholder="Select Country Name" | 377 | placeholder="Select Country Name" |
378 | required | 378 | required |
379 | ></v-text-field> | 379 | ></v-text-field> |
380 | </v-flex> | 380 | </v-flex> |
381 | </v-layout> | 381 | </v-layout> |
382 | </v-flex> | 382 | </v-flex> |
383 | </v-layout> | 383 | </v-layout> |
384 | <v-layout class="hidden-lg-only hidden-md-only hidden-xl-only" wrap> | 384 | <v-layout class="hidden-lg-only hidden-md-only hidden-xl-only" wrap> |
385 | <v-flex xs12 sm12> | 385 | <v-flex xs12 sm12> |
386 | <v-layout> | 386 | <v-layout> |
387 | <v-flex xs4 class="pt-4 subheading"> | 387 | <v-flex xs4 class="pt-4 subheading"> |
388 | <label class="right hidden-xs-only hidden-sm-only">Roll Number:</label> | 388 | <label class="right hidden-xs-only hidden-sm-only">Roll Number:</label> |
389 | <label class="right hidden-lg-only hidden-md-only hidden-xl-only">Roll No:</label> | 389 | <label class="right hidden-lg-only hidden-md-only hidden-xl-only">Roll No:</label> |
390 | </v-flex> | 390 | </v-flex> |
391 | <v-flex xs8 class="ml-3"> | 391 | <v-flex xs8 class="ml-3"> |
392 | <v-text-field | 392 | <v-text-field |
393 | v-model="editedItem.rollNo" | 393 | v-model="editedItem.rollNo" |
394 | placeholder="fill roll number" | 394 | placeholder="fill roll number" |
395 | required | 395 | required |
396 | ></v-text-field> | 396 | ></v-text-field> |
397 | </v-flex> | 397 | </v-flex> |
398 | </v-layout> | 398 | </v-layout> |
399 | </v-flex> | 399 | </v-flex> |
400 | </v-layout> | 400 | </v-layout> |
401 | <v-layout class="hidden-lg-only hidden-md-only hidden-xl-only" wrap> | 401 | <v-layout class="hidden-lg-only hidden-md-only hidden-xl-only" wrap> |
402 | <v-flex xs12 sm12> | 402 | <v-flex xs12 sm12> |
403 | <v-layout> | 403 | <v-layout> |
404 | <v-flex xs12 sm3 class="pt-4 subheading text-xs-center"> | 404 | <v-flex xs12 sm3 class="pt-4 subheading text-xs-center"> |
405 | <label class>Present Address :</label> | 405 | <label class>Present Address :</label> |
406 | </v-flex> | 406 | </v-flex> |
407 | </v-layout> | 407 | </v-layout> |
408 | <v-layout> | 408 | <v-layout> |
409 | <v-flex xs12 sm12> | 409 | <v-flex xs12 sm12> |
410 | <v-textarea | 410 | <v-textarea |
411 | v-model="editedItem.presentAddress" | 411 | v-model="editedItem.presentAddress" |
412 | placeholder="fill Your present Address" | 412 | placeholder="fill Your present Address" |
413 | required | 413 | required |
414 | ></v-textarea> | 414 | ></v-textarea> |
415 | </v-flex> | 415 | </v-flex> |
416 | </v-layout> | 416 | </v-layout> |
417 | </v-flex> | 417 | </v-flex> |
418 | <v-flex xs12 sm12> | 418 | <v-flex xs12 sm12> |
419 | <v-layout> | 419 | <v-layout> |
420 | <v-flex xs12 sm3 class="pt-4 pr-4 subheading text-xs-center addressForm"> | 420 | <v-flex xs12 sm3 class="pt-4 pr-4 subheading text-xs-center addressForm"> |
421 | <label>Permanent addr:</label> | 421 | <label>Permanent addr:</label> |
422 | </v-flex> | 422 | </v-flex> |
423 | </v-layout> | 423 | </v-layout> |
424 | <v-layout> | 424 | <v-layout> |
425 | <v-flex xs12 sm12> | 425 | <v-flex xs12 sm12> |
426 | <v-textarea | 426 | <v-textarea |
427 | name="input-4-3" | 427 | name="input-4-3" |
428 | v-model="editedItem.permanentAddress" | 428 | v-model="editedItem.permanentAddress" |
429 | placeholder="fill Your Permanent Address" | 429 | placeholder="fill Your Permanent Address" |
430 | required | 430 | required |
431 | ></v-textarea> | 431 | ></v-textarea> |
432 | </v-flex> | 432 | </v-flex> |
433 | </v-layout> | 433 | </v-layout> |
434 | </v-flex> | 434 | </v-flex> |
435 | </v-layout> | 435 | </v-layout> |
436 | <v-layout> | 436 | <v-layout> |
437 | <v-flex xs12 sm12> | 437 | <v-flex xs12 sm12> |
438 | <v-layout class="right"> | 438 | <v-layout class="right"> |
439 | <v-btn @click="save" round dark :loading="editLoading" class="add-button">Save</v-btn> | 439 | <v-btn @click="save" round dark :loading="editLoading" class="add-button">Save</v-btn> |
440 | </v-layout> | 440 | </v-layout> |
441 | </v-flex> | 441 | </v-flex> |
442 | </v-layout> | 442 | </v-layout> |
443 | </v-container> | 443 | </v-container> |
444 | </v-form> | 444 | </v-form> |
445 | </v-card-text> | 445 | </v-card-text> |
446 | </v-card> | 446 | </v-card> |
447 | </v-dialog> | 447 | </v-dialog> |
448 | 448 | ||
449 | <!-- ****** PROFILE VIEW STUDENTS DEATILS ****** --> | 449 | <!-- ****** PROFILE VIEW STUDENTS DEATILS ****** --> |
450 | 450 | ||
451 | <v-dialog v-model="profileStudentDialog" max-width="1000px" scrollable> | 451 | <v-dialog v-model="profileStudentDialog" max-width="1000px" scrollable> |
452 | <v-card flat class="card-style pa-3" dark> | 452 | <v-card flat class="card-style pa-3" dark> |
453 | <v-layout> | 453 | <v-layout> |
454 | <v-flex xs12> | 454 | <v-flex xs12> |
455 | <label class="title text-xs-center">View Student Details</label> | 455 | <label class="title text-xs-center">View Student Details</label> |
456 | <v-icon size="24" class="right" @click="profileStudentDialog = false">cancel</v-icon> | 456 | <v-icon size="24" class="right" @click="profileStudentDialog = false">cancel</v-icon> |
457 | </v-flex> | 457 | </v-flex> |
458 | </v-layout> | 458 | </v-layout> |
459 | <v-card-text> | 459 | <v-card-text> |
460 | <v-flex align-center justify-center layout text-xs-center class="mt-3"> | 460 | <v-flex align-center justify-center layout text-xs-center class="mt-3"> |
461 | <v-avatar size="100px"> | 461 | <v-avatar size="100px"> |
462 | <img src="/static/icon/user.png" v-if="!editedItem.profilePicUrl" /> | 462 | <img src="/static/icon/user.png" v-if="!editedItem.profilePicUrl" /> |
463 | <img :src="editedItem.profilePicUrl" v-else-if="editedItem.profilePicUrl" /> | 463 | <img :src="editedItem.profilePicUrl" v-else-if="editedItem.profilePicUrl" /> |
464 | </v-avatar> | 464 | </v-avatar> |
465 | </v-flex> | 465 | </v-flex> |
466 | <v-container grid-list-md> | 466 | <v-container grid-list-md> |
467 | <v-layout wrap> | 467 | <v-layout wrap> |
468 | <v-flex xs12 sm5> | 468 | <v-flex xs12 sm5> |
469 | <v-layout> | 469 | <v-layout> |
470 | <v-flex xs6 sm6> | 470 | <v-flex xs6 sm6> |
471 | <h5 class="right my-1"> | 471 | <h5 class="right my-1"> |
472 | <b>Full Name:</b> | 472 | <b>Full Name:</b> |
473 | </h5> | 473 | </h5> |
474 | </v-flex> | 474 | </v-flex> |
475 | <v-flex sm6 xs6> | 475 | <v-flex sm6 xs6> |
476 | <h5 class="my-1 left">{{ editedItem.name }}</h5> | 476 | <h5 class="my-1 left">{{ editedItem.name }}</h5> |
477 | </v-flex> | 477 | </v-flex> |
478 | </v-layout> | 478 | </v-layout> |
479 | </v-flex> | 479 | </v-flex> |
480 | <v-flex xs12 sm7> | 480 | <v-flex xs12 sm7> |
481 | <v-layout> | 481 | <v-layout> |
482 | <v-flex xs6 sm4> | 482 | <v-flex xs6 sm4> |
483 | <h5 class="right my-1"> | 483 | <h5 class="right my-1"> |
484 | <b>Email:</b> | 484 | <b>Email:</b> |
485 | </h5> | 485 | </h5> |
486 | </v-flex> | 486 | </v-flex> |
487 | <v-flex sm8 xs6> | 487 | <v-flex sm8 xs6> |
488 | <h5 class="my-1 left">{{ editedItem.email }}</h5> | 488 | <h5 class="my-1 left">{{ editedItem.email }}</h5> |
489 | </v-flex> | 489 | </v-flex> |
490 | </v-layout> | 490 | </v-layout> |
491 | </v-flex> | 491 | </v-flex> |
492 | </v-layout> | 492 | </v-layout> |
493 | <v-layout wrap> | 493 | <v-layout wrap> |
494 | <v-flex xs12 sm5> | 494 | <v-flex xs12 sm5> |
495 | <v-layout> | 495 | <v-layout> |
496 | <v-flex xs6 sm6> | 496 | <v-flex xs6 sm6> |
497 | <b> | 497 | <b> |
498 | <h5 class="right my-1"> | 498 | <h5 class="right my-1"> |
499 | <b>Gender:</b> | 499 | <b>Gender:</b> |
500 | </h5> | 500 | </h5> |
501 | </b> | 501 | </b> |
502 | </v-flex> | 502 | </v-flex> |
503 | <v-flex sm6 xs6> | 503 | <v-flex sm6 xs6> |
504 | <h5 class="my-1 left">{{ editedItem.gender }}</h5> | 504 | <h5 class="my-1 left">{{ editedItem.gender }}</h5> |
505 | </v-flex> | 505 | </v-flex> |
506 | </v-layout> | 506 | </v-layout> |
507 | </v-flex> | 507 | </v-flex> |
508 | <v-flex xs12 sm7> | 508 | <v-flex xs12 sm7> |
509 | <v-layout> | 509 | <v-layout> |
510 | <v-flex xs6 sm4> | 510 | <v-flex xs6 sm4> |
511 | <b> | 511 | <b> |
512 | <h5 class="right my-1"> | 512 | <h5 class="right my-1"> |
513 | <b>D.O.B:</b> | 513 | <b>D.O.B:</b> |
514 | </h5> | 514 | </h5> |
515 | </b> | 515 | </b> |
516 | </v-flex> | 516 | </v-flex> |
517 | <v-flex sm8 xs6> | 517 | <v-flex sm8 xs6> |
518 | <h5 class="my-1">{{ dates(editedItem.dob) }}</h5> | 518 | <h5 class="my-1">{{ dates(editedItem.dob) }}</h5> |
519 | </v-flex> | 519 | </v-flex> |
520 | </v-layout> | 520 | </v-layout> |
521 | </v-flex> | 521 | </v-flex> |
522 | </v-layout> | 522 | </v-layout> |
523 | <v-layout wrap> | 523 | <v-layout wrap> |
524 | <v-flex xs12 sm5> | 524 | <v-flex xs12 sm5> |
525 | <v-layout> | 525 | <v-layout> |
526 | <v-flex xs6 sm6> | 526 | <v-flex xs6 sm6> |
527 | <b> | 527 | <b> |
528 | <h5 class="right my-1"> | 528 | <h5 class="right my-1"> |
529 | <b>BloodGroup:</b> | 529 | <b>BloodGroup:</b> |
530 | </h5> | 530 | </h5> |
531 | </b> | 531 | </b> |
532 | </v-flex> | 532 | </v-flex> |
533 | <v-flex sm6 xs6> | 533 | <v-flex sm6 xs6> |
534 | <h5 class="my-1 left">{{ editedItem.bloodGroup }}</h5> | 534 | <h5 class="my-1 left">{{ editedItem.bloodGroup }}</h5> |
535 | </v-flex> | 535 | </v-flex> |
536 | </v-layout> | 536 | </v-layout> |
537 | </v-flex> | 537 | </v-flex> |
538 | <v-flex xs12 sm7> | 538 | <v-flex xs12 sm7> |
539 | <v-layout> | 539 | <v-layout> |
540 | <v-flex xs6 sm4> | 540 | <v-flex xs6 sm4> |
541 | <b> | 541 | <b> |
542 | <h5 class="right my-1"> | 542 | <h5 class="right my-1"> |
543 | <b>Roll No. :</b> | 543 | <b>Roll No. :</b> |
544 | </h5> | 544 | </h5> |
545 | </b> | 545 | </b> |
546 | </v-flex> | 546 | </v-flex> |
547 | <v-flex sm8 xs6> | 547 | <v-flex sm8 xs6> |
548 | <h5 class="my-1">{{ editedItem.rollNo }}</h5> | 548 | <h5 class="my-1">{{ editedItem.rollNo }}</h5> |
549 | </v-flex> | 549 | </v-flex> |
550 | </v-layout> | 550 | </v-layout> |
551 | </v-flex> | 551 | </v-flex> |
552 | </v-layout> | 552 | </v-layout> |
553 | <v-layout wrap> | 553 | <v-layout wrap> |
554 | <v-flex xs12 sm5> | 554 | <v-flex xs12 sm5> |
555 | <v-layout> | 555 | <v-layout> |
556 | <v-flex xs6 sm6> | 556 | <v-flex xs6 sm6> |
557 | <b> | 557 | <b> |
558 | <h5 class="right my-1"> | 558 | <h5 class="right my-1"> |
559 | <b>Height:</b> | 559 | <b>Height:</b> |
560 | </h5> | 560 | </h5> |
561 | </b> | 561 | </b> |
562 | </v-flex> | 562 | </v-flex> |
563 | <v-flex sm6 xs6> | 563 | <v-flex sm6 xs6> |
564 | <h5 class="my-1 left">{{ editedItem.height }}</h5> | 564 | <h5 class="my-1 left">{{ editedItem.height }}</h5> |
565 | </v-flex> | 565 | </v-flex> |
566 | </v-layout> | 566 | </v-layout> |
567 | </v-flex> | 567 | </v-flex> |
568 | <v-flex xs12 sm7> | 568 | <v-flex xs12 sm7> |
569 | <v-layout> | 569 | <v-layout> |
570 | <v-flex xs6 sm4> | 570 | <v-flex xs6 sm4> |
571 | <b> | 571 | <b> |
572 | <h5 class="right my-1"> | 572 | <h5 class="right my-1"> |
573 | <b>Weight:</b> | 573 | <b>Weight:</b> |
574 | </h5> | 574 | </h5> |
575 | </b> | 575 | </b> |
576 | </v-flex> | 576 | </v-flex> |
577 | <v-flex sm8 xs6> | 577 | <v-flex sm8 xs6> |
578 | <h5 class="my-1">{{ editedItem.weight }}</h5> | 578 | <h5 class="my-1">{{ editedItem.weight }}</h5> |
579 | </v-flex> | 579 | </v-flex> |
580 | </v-layout> | 580 | </v-layout> |
581 | </v-flex> | 581 | </v-flex> |
582 | </v-layout> | 582 | </v-layout> |
583 | <v-layout wrap> | 583 | <v-layout wrap> |
584 | <v-flex xs12 sm5> | 584 | <v-flex xs12 sm5> |
585 | <v-layout> | 585 | <v-layout> |
586 | <v-flex xs6 sm6> | 586 | <v-flex xs6 sm6> |
587 | <b> | 587 | <b> |
588 | <h5 class="right my-1"> | 588 | <h5 class="right my-1"> |
589 | <b>City:</b> | 589 | <b>City:</b> |
590 | </h5> | 590 | </h5> |
591 | </b> | 591 | </b> |
592 | </v-flex> | 592 | </v-flex> |
593 | <v-flex sm6 xs6> | 593 | <v-flex sm6 xs6> |
594 | <h5 class="my-1 left">{{ editedItem.city }}</h5> | 594 | <h5 class="my-1 left">{{ editedItem.city }}</h5> |
595 | </v-flex> | 595 | </v-flex> |
596 | </v-layout> | 596 | </v-layout> |
597 | </v-flex> | 597 | </v-flex> |
598 | <v-flex xs12 sm7> | 598 | <v-flex xs12 sm7> |
599 | <v-layout> | 599 | <v-layout> |
600 | <v-flex xs6 sm4> | 600 | <v-flex xs6 sm4> |
601 | <b> | 601 | <b> |
602 | <h5 class="right my-1"> | 602 | <h5 class="right my-1"> |
603 | <b>State:</b> | 603 | <b>State:</b> |
604 | </h5> | 604 | </h5> |
605 | </b> | 605 | </b> |
606 | </v-flex> | 606 | </v-flex> |
607 | <v-flex sm8 xs6> | 607 | <v-flex sm8 xs6> |
608 | <h5 class="my-1">{{ editedItem.state }}</h5> | 608 | <h5 class="my-1">{{ editedItem.state }}</h5> |
609 | </v-flex> | 609 | </v-flex> |
610 | </v-layout> | 610 | </v-layout> |
611 | </v-flex> | 611 | </v-flex> |
612 | </v-layout> | 612 | </v-layout> |
613 | <v-layout wrap> | 613 | <v-layout wrap> |
614 | <v-flex xs12 sm5> | 614 | <v-flex xs12 sm5> |
615 | <v-layout> | 615 | <v-layout> |
616 | <v-flex xs6 sm6> | 616 | <v-flex xs6 sm6> |
617 | <b> | 617 | <b> |
618 | <h5 class="right my-1"> | 618 | <h5 class="right my-1"> |
619 | <b>Pincode:</b> | 619 | <b>Pincode:</b> |
620 | </h5> | 620 | </h5> |
621 | </b> | 621 | </b> |
622 | </v-flex> | 622 | </v-flex> |
623 | <v-flex sm6 xs6> | 623 | <v-flex sm6 xs6> |
624 | <h5 class="my-1">{{ editedItem.pincode }}</h5> | 624 | <h5 class="my-1">{{ editedItem.pincode }}</h5> |
625 | </v-flex> | 625 | </v-flex> |
626 | </v-layout> | 626 | </v-layout> |
627 | </v-flex> | 627 | </v-flex> |
628 | <v-flex xs12 sm7> | 628 | <v-flex xs12 sm7> |
629 | <v-layout> | 629 | <v-layout> |
630 | <v-flex xs6 sm4> | 630 | <v-flex xs6 sm4> |
631 | <b> | 631 | <b> |
632 | <h5 class="right my-1"> | 632 | <h5 class="right my-1"> |
633 | <b>Country:</b> | 633 | <b>Country:</b> |
634 | </h5> | 634 | </h5> |
635 | </b> | 635 | </b> |
636 | </v-flex> | 636 | </v-flex> |
637 | <v-flex sm7 xs6> | 637 | <v-flex sm7 xs6> |
638 | <h5 class="my-1">{{ editedItem.country }}</h5> | 638 | <h5 class="my-1">{{ editedItem.country }}</h5> |
639 | </v-flex> | 639 | </v-flex> |
640 | </v-layout> | 640 | </v-layout> |
641 | </v-flex> | 641 | </v-flex> |
642 | </v-layout> | 642 | </v-layout> |
643 | <v-layout wrap> | 643 | <v-layout wrap> |
644 | <v-flex xs12 sm5> | 644 | <v-flex xs12 sm5> |
645 | <v-layout> | 645 | <v-layout> |
646 | <v-flex sm6 xs6> | 646 | <v-flex sm6 xs6> |
647 | <b> | 647 | <b> |
648 | <h5 class="right my-1"> | 648 | <h5 class="right my-1"> |
649 | <b>Mobile No:</b> | 649 | <b>Mobile No:</b> |
650 | </h5> | 650 | </h5> |
651 | </b> | 651 | </b> |
652 | </v-flex> | 652 | </v-flex> |
653 | <v-flex sm6 xs6> | 653 | <v-flex sm6 xs6> |
654 | <h5 class="my-1">{{ editedItem.mobile }}</h5> | 654 | <h5 class="my-1">{{ editedItem.mobile }}</h5> |
655 | </v-flex> | 655 | </v-flex> |
656 | </v-layout> | 656 | </v-layout> |
657 | </v-flex> | 657 | </v-flex> |
658 | <v-flex xs12 sm7> | 658 | <v-flex xs12 sm7> |
659 | <v-layout> | 659 | <v-layout> |
660 | <v-flex xs6 sm4> | 660 | <v-flex xs6 sm4> |
661 | <b> | 661 | <b> |
662 | <h5 class="right my-1"> | 662 | <h5 class="right my-1"> |
663 | <b>FahterName:</b> | 663 | <b>FahterName:</b> |
664 | </h5> | 664 | </h5> |
665 | </b> | 665 | </b> |
666 | </v-flex> | 666 | </v-flex> |
667 | <v-flex sm8 xs6> | 667 | <v-flex sm8 xs6> |
668 | <h5 class="my-1">{{ editedItem.fatherName }}</h5> | 668 | <h5 class="my-1">{{ editedItem.fatherName }}</h5> |
669 | </v-flex> | 669 | </v-flex> |
670 | </v-layout> | 670 | </v-layout> |
671 | </v-flex> | 671 | </v-flex> |
672 | </v-layout> | 672 | </v-layout> |
673 | <v-layout wrap> | 673 | <v-layout wrap> |
674 | <v-flex xs12 sm5> | 674 | <v-flex xs12 sm5> |
675 | <v-layout> | 675 | <v-layout> |
676 | <v-flex xs6 sm6> | 676 | <v-flex xs6 sm6> |
677 | <b> | 677 | <b> |
678 | <h5 class="right my-1"> | 678 | <h5 class="right my-1"> |
679 | <b>MotherName:</b> | 679 | <b>MotherName:</b> |
680 | </h5> | 680 | </h5> |
681 | </b> | 681 | </b> |
682 | </v-flex> | 682 | </v-flex> |
683 | <v-flex sm6 xs6> | 683 | <v-flex sm6 xs6> |
684 | <h5 class="my-1">{{ editedItem.motherName }}</h5> | 684 | <h5 class="my-1">{{ editedItem.motherName }}</h5> |
685 | </v-flex> | 685 | </v-flex> |
686 | </v-layout> | 686 | </v-layout> |
687 | </v-flex> | 687 | </v-flex> |
688 | <v-flex xs12 sm7> | 688 | <v-flex xs12 sm7> |
689 | <v-layout> | 689 | <v-layout> |
690 | <v-flex xs6 sm4> | 690 | <v-flex xs6 sm4> |
691 | <b> | 691 | <b> |
692 | <h5 class="right my-1"> | 692 | <h5 class="right my-1"> |
693 | <b>FatherCellNo:</b> | 693 | <b>FatherCellNo:</b> |
694 | </h5> | 694 | </h5> |
695 | </b> | 695 | </b> |
696 | </v-flex> | 696 | </v-flex> |
697 | <v-flex sm6 xs6> | 697 | <v-flex sm6 xs6> |
698 | <h5 class="my-1">{{ editedItem.fatherCellNo }}</h5> | 698 | <h5 class="my-1">{{ editedItem.fatherCellNo }}</h5> |
699 | </v-flex> | 699 | </v-flex> |
700 | </v-layout> | 700 | </v-layout> |
701 | </v-flex> | 701 | </v-flex> |
702 | </v-layout> | 702 | </v-layout> |
703 | <v-layout wrap> | 703 | <v-layout wrap> |
704 | <v-flex xs12 sm5> | 704 | <v-flex xs12 sm5> |
705 | <v-layout> | 705 | <v-layout> |
706 | <v-flex xs6 sm6> | 706 | <v-flex xs6 sm6> |
707 | <b> | 707 | <b> |
708 | <h5 class="right my-1"> | 708 | <h5 class="right my-1"> |
709 | <b>MotherCellNo:</b> | 709 | <b>MotherCellNo:</b> |
710 | </h5> | 710 | </h5> |
711 | </b> | 711 | </b> |
712 | </v-flex> | 712 | </v-flex> |
713 | <v-flex sm6 xs6> | 713 | <v-flex sm6 xs6> |
714 | <h5 class="my-1">{{ editedItem.motherCellNo }}</h5> | 714 | <h5 class="my-1">{{ editedItem.motherCellNo }}</h5> |
715 | </v-flex> | 715 | </v-flex> |
716 | </v-layout> | 716 | </v-layout> |
717 | </v-flex> | 717 | </v-flex> |
718 | <v-flex xs12 sm7> | 718 | <v-flex xs12 sm7> |
719 | <v-layout> | 719 | <v-layout> |
720 | <v-flex xs6 sm4> | 720 | <v-flex xs6 sm4> |
721 | <b> | 721 | <b> |
722 | <h5 class="my-1 right"> | 722 | <h5 class="my-1 right"> |
723 | <b>AcademicYear:</b> | 723 | <b>AcademicYear:</b> |
724 | </h5> | 724 | </h5> |
725 | </b> | 725 | </b> |
726 | </v-flex> | 726 | </v-flex> |
727 | <v-flex sm5 xs8> | 727 | <v-flex sm5 xs8> |
728 | <h5 class="my-1">{{ editedItem.establishmentYear }}</h5> | 728 | <h5 class="my-1">{{ editedItem.establishmentYear }}</h5> |
729 | </v-flex> | 729 | </v-flex> |
730 | </v-layout> | 730 | </v-layout> |
731 | </v-flex> | 731 | </v-flex> |
732 | </v-layout> | 732 | </v-layout> |
733 | <v-layout wrap> | 733 | <v-layout wrap> |
734 | <v-flex xs12 sm5> | 734 | <v-flex xs12 sm5> |
735 | <v-layout> | 735 | <v-layout> |
736 | <v-flex xs6 sm6> | 736 | <v-flex xs6 sm6> |
737 | <b> | 737 | <b> |
738 | <h5 class="my-1 right"> | 738 | <h5 class="my-1 right"> |
739 | <b>MedicalNotes:</b> | 739 | <b>MedicalNotes:</b> |
740 | </h5> | 740 | </h5> |
741 | </b> | 741 | </b> |
742 | </v-flex> | 742 | </v-flex> |
743 | <v-flex sm5 xs6> | 743 | <v-flex sm5 xs6> |
744 | <h5 class="my-1">{{ editedItem.medicalNotes }}</h5> | 744 | <h5 class="my-1">{{ editedItem.medicalNotes }}</h5> |
745 | </v-flex> | 745 | </v-flex> |
746 | </v-layout> | 746 | </v-layout> |
747 | </v-flex> | 747 | </v-flex> |
748 | <v-flex xs12 sm7 class="hidden-xs-only"> | 748 | <v-flex xs12 sm7 class="hidden-xs-only"> |
749 | <v-layout wrap> | 749 | <v-layout wrap> |
750 | <v-flex sm4> | 750 | <v-flex sm4> |
751 | <b> | 751 | <b> |
752 | <h5 class="my-1 right"> | 752 | <h5 class="my-1 right"> |
753 | <b>present Address:</b> | 753 | <b>present Address:</b> |
754 | </h5> | 754 | </h5> |
755 | </b> | 755 | </b> |
756 | </v-flex> | 756 | </v-flex> |
757 | <v-flex sm8> | 757 | <v-flex sm8> |
758 | <h5 class="my-1">{{ editedItem.presentAddress }}</h5> | 758 | <h5 class="my-1">{{ editedItem.presentAddress }}</h5> |
759 | </v-flex> | 759 | </v-flex> |
760 | </v-layout> | 760 | </v-layout> |
761 | </v-flex> | 761 | </v-flex> |
762 | <v-flex sm6 class="hidden-xs-only"> | 762 | <v-flex sm6 class="hidden-xs-only"> |
763 | <v-layout wrap> | 763 | <v-layout wrap> |
764 | <v-flex sm5> | 764 | <v-flex sm5> |
765 | <b> | 765 | <b> |
766 | <h5 class="my-1 right"> | 766 | <h5 class="my-1 right"> |
767 | <b>Permanent Address:</b> | 767 | <b>Permanent Address:</b> |
768 | </h5> | 768 | </h5> |
769 | </b> | 769 | </b> |
770 | </v-flex> | 770 | </v-flex> |
771 | <v-flex sm7> | 771 | <v-flex sm7> |
772 | <h5 class="my-1">{{ editedItem.permanentAddress }}</h5> | 772 | <h5 class="my-1">{{ editedItem.permanentAddress }}</h5> |
773 | </v-flex> | 773 | </v-flex> |
774 | </v-layout> | 774 | </v-layout> |
775 | </v-flex> | 775 | </v-flex> |
776 | </v-layout> | 776 | </v-layout> |
777 | <v-layout wrap class="hidden-sm-only hidden-md-only hidden-lg-only hidden-xl-only"> | 777 | <v-layout wrap class="hidden-sm-only hidden-md-only hidden-lg-only hidden-xl-only"> |
778 | <v-flex xs12 sm5> | 778 | <v-flex xs12 sm5> |
779 | <v-layout wrap> | 779 | <v-layout wrap> |
780 | <v-flex xs12 sm6> | 780 | <v-flex xs12 sm6> |
781 | <b> | 781 | <b> |
782 | <h5 class="my-1"> | 782 | <h5 class="my-1"> |
783 | <b>present Address:-</b> | 783 | <b>present Address:-</b> |
784 | </h5> | 784 | </h5> |
785 | </b> | 785 | </b> |
786 | </v-flex> | 786 | </v-flex> |
787 | <v-flex sm5 xs12> | 787 | <v-flex sm5 xs12> |
788 | <h5 class="my-1">{{ editedItem.presentAddress }}</h5> | 788 | <h5 class="my-1">{{ editedItem.presentAddress }}</h5> |
789 | </v-flex> | 789 | </v-flex> |
790 | </v-layout> | 790 | </v-layout> |
791 | </v-flex> | 791 | </v-flex> |
792 | <v-flex xs12 sm6> | 792 | <v-flex xs12 sm6> |
793 | <v-layout wrap> | 793 | <v-layout wrap> |
794 | <v-flex xs12 sm6> | 794 | <v-flex xs12 sm6> |
795 | <b> | 795 | <b> |
796 | <h5 class="my-1"> | 796 | <h5 class="my-1"> |
797 | <b>Permanent Address:-</b> | 797 | <b>Permanent Address:-</b> |
798 | </h5> | 798 | </h5> |
799 | </b> | 799 | </b> |
800 | </v-flex> | 800 | </v-flex> |
801 | <v-flex sm6 xs12> | 801 | <v-flex sm6 xs12> |
802 | <h5 class="my-1">{{ editedItem.permanentAddress }}</h5> | 802 | <h5 class="my-1">{{ editedItem.permanentAddress }}</h5> |
803 | </v-flex> | 803 | </v-flex> |
804 | </v-layout> | 804 | </v-layout> |
805 | </v-flex> | 805 | </v-flex> |
806 | </v-layout> | 806 | </v-layout> |
807 | </v-container> | 807 | </v-container> |
808 | </v-card-text> | 808 | </v-card-text> |
809 | </v-card> | 809 | </v-card> |
810 | </v-dialog> | 810 | </v-dialog> |
811 | 811 | ||
812 | <!-- ****** STUDENTS TABLE ****** --> | 812 | <!-- ****** STUDENTS TABLE ****** --> |
813 | <v-toolbar color="transparent" flat> | 813 | <v-toolbar color="transparent" flat> |
814 | <v-btn | 814 | <v-btn |
815 | fab | 815 | fab |
816 | dark | 816 | dark |
817 | class="open-dialog-button hidden-xl-only hidden-md-only hidden-lg-only" | 817 | class="open-dialog-button hidden-xl-only hidden-md-only hidden-lg-only" |
818 | small | 818 | small |
819 | @click="addStudentDialog = true" | 819 | @click="addStudentDialog = true" |
820 | > | 820 | > |
821 | <v-icon dark>add</v-icon> | 821 | <v-icon dark>add</v-icon> |
822 | </v-btn> | 822 | </v-btn> |
823 | <v-btn | 823 | <v-btn |
824 | v-if="role != 'TEACHER' " | 824 | v-if="role != 'TEACHER' " |
825 | round | 825 | round |
826 | class="open-dialog-button hidden-sm-only hidden-xs-only" | 826 | class="open-dialog-button hidden-sm-only hidden-xs-only" |
827 | dark | 827 | dark |
828 | @click="addStudentDialog = true" | 828 | @click="addStudentDialog = true" |
829 | > | 829 | > |
830 | <v-icon class="white--text pr-1" size="20">add</v-icon>Add Student | 830 | <v-icon class="white--text pr-1" size="20">add</v-icon>Add Student |
831 | </v-btn> | 831 | </v-btn> |
832 | <v-card-actions class="hidden-xs-only hidden-sm-only"> | 832 | <v-card-actions class="hidden-xs-only hidden-sm-only"> |
833 | <v-flex md13 lg12> | 833 | <v-flex md13 lg12> |
834 | <v-layout> | 834 | <v-layout> |
835 | <v-flex lg3 md4> | 835 | <v-flex lg3 md4> |
836 | <v-select | 836 | <v-select |
837 | :items="addclass" | 837 | :items="addclass" |
838 | label="Select Class" | 838 | label="Select Class" |
839 | v-model="selectStudents.select" | 839 | v-model="selectStudents.select" |
840 | item-text="classNum" | 840 | item-text="classNum" |
841 | item-value="_id" | 841 | item-value="_id" |
842 | name="Select Class" | 842 | name="Select Class" |
843 | :rules="classRules" | 843 | :rules="classRules" |
844 | @change="getSections(selectStudents.select)" | 844 | @change="getSections(selectStudents.select)" |
845 | required | 845 | required |
846 | class="ml-2" | 846 | class="ml-2" |
847 | ></v-select> | 847 | ></v-select> |
848 | </v-flex> | 848 | </v-flex> |
849 | <v-flex lg3 md4 class="ml-2"> | 849 | <v-flex lg3 md4 class="ml-2"> |
850 | <v-layout> | 850 | <v-layout> |
851 | <v-select | 851 | <v-select |
852 | :items="addSection" | 852 | :items="addSection" |
853 | label="Select Section" | 853 | label="Select Section" |
854 | v-model="selectStudents.selectSection" | 854 | v-model="selectStudents.selectSection" |
855 | item-text="name" | 855 | item-text="name" |
856 | item-value="_id" | 856 | item-value="_id" |
857 | name="Select Section" | 857 | name="Select Section" |
858 | :rules="sectionRules" | 858 | :rules="sectionRules" |
859 | required | 859 | required |
860 | ></v-select> | 860 | ></v-select> |
861 | </v-layout> | 861 | </v-layout> |
862 | </v-flex> | 862 | </v-flex> |
863 | </v-layout> | 863 | </v-layout> |
864 | </v-flex> | 864 | </v-flex> |
865 | </v-card-actions> | 865 | </v-card-actions> |
866 | <v-spacer></v-spacer> | 866 | <v-spacer></v-spacer> |
867 | <v-btn | 867 | <v-btn |
868 | @click="findStudents()" | 868 | @click="findStudents()" |
869 | round | 869 | round |
870 | dark | 870 | dark |
871 | :loading="loading" | 871 | :loading="loading" |
872 | class="open-dialog-button hidden-xs-only hidden-sm-only" | 872 | class="open-dialog-button hidden-xs-only hidden-sm-only" |
873 | >Find</v-btn> | 873 | >Find</v-btn> |
874 | <v-card-title class="body-1" v-show="show"> | 874 | <v-card-title class="body-1" v-show="show"> |
875 | <v-btn icon large flat @click="displaySearch"> | 875 | <v-btn icon large flat @click="displaySearch"> |
876 | <v-avatar size="27"> | 876 | <v-avatar size="27"> |
877 | <img src="/static/icon/search.png" alt="icon" /> | 877 | <img src="/static/icon/search.png" alt="icon" /> |
878 | </v-avatar> | 878 | </v-avatar> |
879 | </v-btn> | 879 | </v-btn> |
880 | </v-card-title> | 880 | </v-card-title> |
881 | <v-flex xs8 sm7 lg2 md3 v-if="showSearch"> | 881 | <v-flex xs8 sm7 lg2 md3 v-if="showSearch"> |
882 | <v-layout> | 882 | <v-layout> |
883 | <v-text-field | 883 | <v-text-field |
884 | autofocus | 884 | autofocus |
885 | v-model="search" | 885 | v-model="search" |
886 | label="Search" | 886 | label="Search" |
887 | prepend-inner-icon="search" | 887 | prepend-inner-icon="search" |
888 | color="primary" | 888 | color="primary" |
889 | ></v-text-field> | 889 | ></v-text-field> |
890 | <v-icon @click="closeSearch" color="error">close</v-icon> | 890 | <v-icon @click="closeSearch" color="error">close</v-icon> |
891 | </v-layout> | 891 | </v-layout> |
892 | </v-flex> | 892 | </v-flex> |
893 | </v-toolbar> | 893 | </v-toolbar> |
894 | <v-card flat class="elevation-0 transparent"> | 894 | <v-card flat class="elevation-0 transparent"> |
895 | <v-flex class="hidden-xl-only hidden-lg-only hidden-md-only"> | 895 | <v-flex class="hidden-xl-only hidden-lg-only hidden-md-only"> |
896 | <v-layout> | 896 | <v-layout> |
897 | <v-flex xs4> | 897 | <v-flex xs4> |
898 | <label class="right mt-4">Select Class:</label> | 898 | <label class="right mt-4">Select Class:</label> |
899 | </v-flex> | 899 | </v-flex> |
900 | <v-flex xs8> | 900 | <v-flex xs8> |
901 | <v-select | 901 | <v-select |
902 | :items="addclass" | 902 | :items="addclass" |
903 | label="Select Class" | 903 | label="Select Class" |
904 | v-model="selectStudents.select" | 904 | v-model="selectStudents.select" |
905 | item-text="classNum" | 905 | item-text="classNum" |
906 | item-value="_id" | 906 | item-value="_id" |
907 | name="Select Class" | 907 | name="Select Class" |
908 | :rules="classRules" | 908 | :rules="classRules" |
909 | @change="getSections(selectStudents.select)" | 909 | @change="getSections(selectStudents.select)" |
910 | class="px-2" | 910 | class="px-2" |
911 | ></v-select> | 911 | ></v-select> |
912 | </v-flex> | 912 | </v-flex> |
913 | </v-layout> | 913 | </v-layout> |
914 | <v-layout> | 914 | <v-layout> |
915 | <v-flex xs4> | 915 | <v-flex xs4> |
916 | <label class="right mt-4">Select Section:</label> | 916 | <label class="right mt-4">Select Section:</label> |
917 | </v-flex> | 917 | </v-flex> |
918 | <v-flex xs8> | 918 | <v-flex xs8> |
919 | <v-select | 919 | <v-select |
920 | :items="addSection" | 920 | :items="addSection" |
921 | label="Select Section" | 921 | label="Select Section" |
922 | v-model="selectStudents.selectSection" | 922 | v-model="selectStudents.selectSection" |
923 | item-text="name" | 923 | item-text="name" |
924 | item-value="_id" | 924 | item-value="_id" |
925 | name="Select Section" | 925 | name="Select Section" |
926 | :rules="sectionRules" | 926 | :rules="sectionRules" |
927 | class="px-2" | 927 | class="px-2" |
928 | required | 928 | required |
929 | ></v-select> | 929 | ></v-select> |
930 | </v-flex> | 930 | </v-flex> |
931 | </v-layout> | 931 | </v-layout> |
932 | <v-layout> | 932 | <v-layout> |
933 | <v-flex xs5 class="mx-auto mb-2"> | 933 | <v-flex xs5 class="mx-auto mb-2"> |
934 | <v-btn | 934 | <v-btn |
935 | @click="findStudents()" | 935 | @click="findStudents()" |
936 | block | 936 | block |
937 | round | 937 | round |
938 | dark | 938 | dark |
939 | :loading="loading" | 939 | :loading="loading" |
940 | class="add-button" | 940 | class="add-button" |
941 | >Find</v-btn> | 941 | >Find</v-btn> |
942 | </v-flex> | 942 | </v-flex> |
943 | </v-layout> | 943 | </v-layout> |
944 | </v-flex> | 944 | </v-flex> |
945 | </v-card> | 945 | </v-card> |
946 | <v-data-table | 946 | <v-data-table |
947 | :headers="headers" | 947 | :headers="headers" |
948 | :items="studentsData" | 948 | :items="studentsData" |
949 | :pagination.sync="pagination" | 949 | :pagination.sync="pagination" |
950 | :search="search" | 950 | :search="search" |
951 | > | 951 | > |
952 | <template slot="items" slot-scope="props"> | 952 | <template slot="items" slot-scope="props"> |
953 | <tr class="tr"> | 953 | <tr class="tr"> |
954 | <td class="text-xs-center td td-row">{{ props.item.rollNo}}</td> | 954 | <td class="text-xs-center td td-row">{{ props.item.rollNo}}</td> |
955 | <td class="text-xs-center td td-row"> | 955 | <td class="text-xs-center td td-row"> |
956 | <v-avatar size="40"> | 956 | <v-avatar size="40"> |
957 | <img :src="props.item.profilePicUrl" v-if="props.item.profilePicUrl" /> | 957 | <img :src="props.item.profilePicUrl" v-if="props.item.profilePicUrl" /> |
958 | <img src="/static/icon/user.png" v-else-if="!props.item.profilePicUrl" /> | 958 | <img src="/static/icon/user.png" v-else-if="!props.item.profilePicUrl" /> |
959 | </v-avatar> | 959 | </v-avatar> |
960 | </td> | 960 | </td> |
961 | <td class="text-xs-center td td-row">{{ props.item.name}}</td> | 961 | <td class="text-xs-center td td-row">{{ props.item.name}}</td> |
962 | <td class="text-xs-center td td-row">{{ props.item.gender }}</td> | 962 | <td class="text-xs-center td td-row">{{ props.item.gender }}</td> |
963 | <td class="text-xs-center td td-row">{{ props.item.parentId.fatherName }}</td> | 963 | <td class="text-xs-center td td-row">{{ props.item.parentId.fatherName }}</td> |
964 | <td class="text-xs-center td td-row">{{ props.item.parentId.motherName }}</td> | 964 | <td class="text-xs-center td td-row">{{ props.item.parentId.motherName }}</td> |
965 | <td class="text-xs-center td td-row">{{ props.item.establishmentYear }}</td> | 965 | <td class="text-xs-center td td-row">{{ props.item.establishmentYear }}</td> |
966 | <!-- <td class="text-xs-center td td-row">{{ props.item.mobile}}</td> --> | 966 | <!-- <td class="text-xs-center td td-row">{{ props.item.mobile}}</td> --> |
967 | <td class="text-xs-center td td-row"> | 967 | <td class="text-xs-center td td-row"> |
968 | <v-switch | 968 | <v-switch |
969 | class="pl-3" | 969 | class="pl-3" |
970 | :disabled="role === 'TEACHER'" | 970 | :disabled="role === 'TEACHER'" |
971 | v-model="props.item.status" | 971 | v-model="props.item.status" |
972 | @change="suspendStudentStatus(props.item.status,props.item._id)" | 972 | @change="suspendStudentStatus(props.item.status,props.item._id)" |
973 | ></v-switch> | 973 | ></v-switch> |
974 | </td> | 974 | </td> |
975 | <td class="text-xs-center td td-row"> | 975 | <td class="text-xs-center td td-row"> |
976 | <span> | 976 | <span> |
977 | <v-tooltip top> | 977 | <v-tooltip top> |
978 | <img | 978 | <img |
979 | slot="activator" | 979 | slot="activator" |
980 | style="cursor:pointer; width:25px; height:25px; " | 980 | style="cursor:pointer; width:25px; height:25px; " |
981 | class="mr-3" | 981 | class="mr-3" |
982 | @click="profile(props.item)" | 982 | @click="profile(props.item)" |
983 | src="/static/icon/view.png" | 983 | src="/static/icon/view.png" |
984 | /> | 984 | /> |
985 | <span>View</span> | 985 | <span>View</span> |
986 | </v-tooltip> | 986 | </v-tooltip> |
987 | <v-tooltip top v-if="role != 'TEACHER' "> | 987 | <v-tooltip top v-if="role != 'TEACHER' "> |
988 | <img | 988 | <img |
989 | slot="activator" | 989 | slot="activator" |
990 | style="cursor:pointer; width:20px; height:18px; " | 990 | style="cursor:pointer; width:20px; height:18px; " |
991 | class="mr-3" | 991 | class="mr-3" |
992 | @click="editItem(props.item)" | 992 | @click="editItem(props.item)" |
993 | src="/static/icon/edit.png" | 993 | src="/static/icon/edit.png" |
994 | /> | 994 | /> |
995 | <span>Edit</span> | 995 | <span>Edit</span> |
996 | </v-tooltip> | 996 | </v-tooltip> |
997 | <v-tooltip top v-if="role != 'TEACHER' "> | 997 | <v-tooltip top v-if="role != 'TEACHER' "> |
998 | <img | 998 | <img |
999 | slot="activator" | 999 | slot="activator" |
1000 | style="cursor:pointer; width:20px; height:20px; " | 1000 | style="cursor:pointer; width:20px; height:20px; " |
1001 | class="mr-3" | 1001 | class="mr-3" |
1002 | @click="deleteItem(props.item)" | 1002 | @click="deleteItem(props.item)" |
1003 | src="/static/icon/delete.png" | 1003 | src="/static/icon/delete.png" |
1004 | /> | 1004 | /> |
1005 | <span>Delete</span> | 1005 | <span>Delete</span> |
1006 | </v-tooltip> | 1006 | </v-tooltip> |
1007 | </span> | 1007 | </span> |
1008 | </td> | 1008 | </td> |
1009 | </tr> | 1009 | </tr> |
1010 | </template> | 1010 | </template> |
1011 | <v-alert | 1011 | <v-alert |
1012 | slot="no-results" | 1012 | slot="no-results" |
1013 | :value="true" | 1013 | :value="true" |
1014 | color="error" | 1014 | color="error" |
1015 | icon="warning" | 1015 | icon="warning" |
1016 | >Your search for "{{ search }}" found no results.</v-alert> | 1016 | >Your search for "{{ search }}" found no results.</v-alert> |
1017 | </v-data-table> | 1017 | </v-data-table> |
1018 | <!-- DIALOG -- ADD STUDENTS DETAILS --> | 1018 | <!-- DIALOG -- ADD STUDENTS DETAILS --> |
1019 | <v-dialog v-model="addStudentDialog" max-width="1280" v-if="addStudentDialog"> | 1019 | <v-dialog v-model="addStudentDialog" max-width="1280" v-if="addStudentDialog"> |
1020 | <v-card flat class="card-style pa-2" dark> | 1020 | <v-card flat class="card-style pa-2" dark> |
1021 | <v-layout> | 1021 | <v-layout> |
1022 | <v-flex xs12> | 1022 | <v-flex xs12> |
1023 | <label class="title text-xs-center">Add Student</label> | 1023 | <label class="title text-xs-center">Add Student</label> |
1024 | <v-icon | 1024 | <v-icon |
1025 | size="24" | 1025 | size="24" |
1026 | class="right" | 1026 | class="right" |
1027 | @click="$refs.parentForm.reset();$refs.parentFormLgScr.reset();$refs.form.reset();e2 = 1;addStudentDialog = false" | 1027 | @click="$refs.parentForm.reset();$refs.parentFormLgScr.reset();$refs.form.reset();e2 = 1;addStudentDialog = false" |
1028 | >cancel</v-icon> | 1028 | >cancel</v-icon> |
1029 | </v-flex> | 1029 | </v-flex> |
1030 | </v-layout> | 1030 | </v-layout> |
1031 | <v-container fluid> | 1031 | <v-container fluid> |
1032 | <v-layout align-center> | 1032 | <v-layout align-center> |
1033 | <v-flex xs12> | 1033 | <v-flex xs12> |
1034 | <v-stepper v-model="e2" flat class="card-style elevation-0" dark> | 1034 | <v-stepper v-model="e2" flat class="card-style elevation-0" dark> |
1035 | <v-stepper-header> | 1035 | <v-stepper-header> |
1036 | <v-stepper-step :complete="e2 > 1" step="1">Fill parent Details</v-stepper-step> | 1036 | <v-stepper-step :complete="e2 > 1" step="1">Fill parent Details</v-stepper-step> |
1037 | <v-divider></v-divider> | 1037 | <v-divider></v-divider> |
1038 | <v-stepper-step step="2">Fill Student Details</v-stepper-step> | 1038 | <v-stepper-step step="2">Fill Student Details</v-stepper-step> |
1039 | </v-stepper-header> | 1039 | </v-stepper-header> |
1040 | <v-stepper-items> | 1040 | <v-stepper-items> |
1041 | <v-stepper-content step="1"> | 1041 | <v-stepper-content step="1"> |
1042 | <v-container fluid class> | 1042 | <v-container fluid class> |
1043 | <v-flex xs12 sm12 class="hidden-md-only hidden-lg-only hidden-xl-only"> | 1043 | <v-flex xs12 sm12 class="hidden-md-only hidden-lg-only hidden-xl-only"> |
1044 | <v-form ref="parentForm" v-model="valid" lazy-validation> | 1044 | <v-form ref="parentForm" v-model="valid" lazy-validation> |
1045 | <v-layout wrap> | 1045 | <v-layout wrap> |
1046 | <v-flex xs12 sm6> | 1046 | <v-flex xs12 sm6> |
1047 | <v-layout wrap> | 1047 | <v-layout wrap> |
1048 | <v-flex xs12 class="pt-4 subheading"> | 1048 | <v-flex xs12 class="pt-4 subheading"> |
1049 | <label>Father Cell No:</label> | 1049 | <label>Father Cell No:</label> |
1050 | </v-flex> | 1050 | </v-flex> |
1051 | <v-flex xs12> | 1051 | <v-flex xs12> |
1052 | <v-text-field | 1052 | <v-text-field |
1053 | v-model.trim="parentData.fatherCellNo" | 1053 | v-model.trim="parentData.fatherCellNo" |
1054 | placeholder="fill your father Cell Number" | 1054 | placeholder="fill your father Cell Number" |
1055 | type="number" | 1055 | type="number" |
1056 | :rules="fatheCellNoRules" | 1056 | :rules="fatheCellNoRules" |
1057 | counter="10" | 1057 | counter="10" |
1058 | v-on:keyup="getParentDetails()" | 1058 | v-on:keyup="getParentDetails()" |
1059 | required | 1059 | required |
1060 | ></v-text-field> | 1060 | ></v-text-field> |
1061 | </v-flex> | 1061 | </v-flex> |
1062 | </v-layout> | 1062 | </v-layout> |
1063 | </v-flex> | 1063 | </v-flex> |
1064 | <v-flex xs12 sm6> | 1064 | <v-flex xs12 sm6> |
1065 | <v-layout wrap> | 1065 | <v-layout wrap> |
1066 | <v-flex xs12 class="pt-4 subheading"> | 1066 | <v-flex xs12 class="pt-4 subheading"> |
1067 | <label>Parent Email Id:</label> | 1067 | <label>Parent Email Id:</label> |
1068 | </v-flex> | 1068 | </v-flex> |
1069 | <v-flex xs12> | 1069 | <v-flex xs12> |
1070 | <v-text-field | 1070 | <v-text-field |
1071 | placeholder="fill Parent email" | 1071 | placeholder="fill Parent email" |
1072 | v-model="parentData.email" | 1072 | v-model="parentData.email" |
1073 | type="text" | 1073 | type="text" |
1074 | required | 1074 | required |
1075 | ></v-text-field> | 1075 | ></v-text-field> |
1076 | </v-flex> | 1076 | </v-flex> |
1077 | </v-layout> | 1077 | </v-layout> |
1078 | </v-flex> | 1078 | </v-flex> |
1079 | </v-layout> | 1079 | </v-layout> |
1080 | <v-layout wrap> | 1080 | <v-layout wrap> |
1081 | <v-flex xs12 sm6> | 1081 | <v-flex xs12 sm6> |
1082 | <v-layout wrap> | 1082 | <v-layout wrap> |
1083 | <v-flex xs12 class="pt-4 subheading"> | 1083 | <v-flex xs12 class="pt-4 subheading"> |
1084 | <label>Father Name:</label> | 1084 | <label>Father Name:</label> |
1085 | </v-flex> | 1085 | </v-flex> |
1086 | <v-flex xs12> | 1086 | <v-flex xs12> |
1087 | <v-text-field | 1087 | <v-text-field |
1088 | v-model="parentData.fatherName" | 1088 | v-model="parentData.fatherName" |
1089 | placeholder="Fill your father Name" | 1089 | placeholder="Fill your father Name" |
1090 | required | 1090 | required |
1091 | ></v-text-field> | 1091 | ></v-text-field> |
1092 | </v-flex> | 1092 | </v-flex> |
1093 | </v-layout> | 1093 | </v-layout> |
1094 | </v-flex> | 1094 | </v-flex> |
1095 | <v-flex xs12 sm6> | 1095 | <v-flex xs12 sm6> |
1096 | <v-layout wrap> | 1096 | <v-layout wrap> |
1097 | <v-flex xs12 class="pt-4 subheading"> | 1097 | <v-flex xs12 class="pt-4 subheading"> |
1098 | <label>Mother Name:</label> | 1098 | <label>Mother Name:</label> |
1099 | </v-flex> | 1099 | </v-flex> |
1100 | <v-flex xs12> | 1100 | <v-flex xs12> |
1101 | <v-text-field | 1101 | <v-text-field |
1102 | v-model="parentData.motherName" | 1102 | v-model="parentData.motherName" |
1103 | placeholder="fill your Mother Name" | 1103 | placeholder="fill your Mother Name" |
1104 | type="text" | 1104 | type="text" |
1105 | required | 1105 | required |
1106 | ></v-text-field> | 1106 | ></v-text-field> |
1107 | </v-flex> | 1107 | </v-flex> |
1108 | </v-layout> | 1108 | </v-layout> |
1109 | </v-flex> | 1109 | </v-flex> |
1110 | </v-layout> | 1110 | </v-layout> |
1111 | <v-layout wrap> | 1111 | <v-layout wrap> |
1112 | <v-flex xs12 sm6> | 1112 | <v-flex xs12 sm6> |
1113 | <v-layout wrap> | 1113 | <v-layout wrap> |
1114 | <v-flex xs12 class="pt-4 subheading"> | 1114 | <v-flex xs12 class="pt-4 subheading"> |
1115 | <label>Mother Cell No:</label> | 1115 | <label>Mother Cell No:</label> |
1116 | </v-flex> | 1116 | </v-flex> |
1117 | <v-flex xs12> | 1117 | <v-flex xs12> |
1118 | <v-text-field | 1118 | <v-text-field |
1119 | v-model="parentData.motherCellNo" | 1119 | v-model="parentData.motherCellNo" |
1120 | placeholder="fill your Mother Cell Number" | 1120 | placeholder="fill your Mother Cell Number" |
1121 | type="number" | 1121 | type="number" |
1122 | required | 1122 | required |
1123 | ></v-text-field> | 1123 | ></v-text-field> |
1124 | </v-flex> | 1124 | </v-flex> |
1125 | </v-layout> | 1125 | </v-layout> |
1126 | </v-flex> | 1126 | </v-flex> |
1127 | <v-flex xs12 sm6> | 1127 | <v-flex xs12 sm6> |
1128 | <v-layout wrap> | 1128 | <v-layout wrap> |
1129 | <v-flex xs12 class="pt-4 subheading"> | 1129 | <v-flex xs12 class="pt-4 subheading"> |
1130 | <label>Father Profession:</label> | 1130 | <label>Father Profession:</label> |
1131 | </v-flex> | 1131 | </v-flex> |
1132 | <v-flex xs12> | 1132 | <v-flex xs12> |
1133 | <v-text-field | 1133 | <v-text-field |
1134 | v-model="parentData.fatherProfession" | 1134 | v-model="parentData.fatherProfession" |
1135 | placeholder="fill your father profession" | 1135 | placeholder="fill your father profession" |
1136 | ></v-text-field> | 1136 | ></v-text-field> |
1137 | </v-flex> | 1137 | </v-flex> |
1138 | </v-layout> | 1138 | </v-layout> |
1139 | </v-flex> | 1139 | </v-flex> |
1140 | </v-layout> | 1140 | </v-layout> |
1141 | <v-layout wrap> | 1141 | <v-layout wrap> |
1142 | <v-flex xs12 sm6> | 1142 | <v-flex xs12 sm6> |
1143 | <v-layout wrap> | 1143 | <v-layout wrap> |
1144 | <v-flex xs12 class="pt-4 subheading"> | 1144 | <v-flex xs12 class="pt-4 subheading"> |
1145 | <label>Mother Profession:</label> | 1145 | <label>Mother Profession:</label> |
1146 | </v-flex> | 1146 | </v-flex> |
1147 | <v-flex xs12> | 1147 | <v-flex xs12> |
1148 | <v-text-field | 1148 | <v-text-field |
1149 | v-model="parentData.motherProfession" | 1149 | v-model="parentData.motherProfession" |
1150 | placeholder="fill your mother profession" | 1150 | placeholder="fill your mother profession" |
1151 | ></v-text-field> | 1151 | ></v-text-field> |
1152 | </v-flex> | 1152 | </v-flex> |
1153 | </v-layout> | 1153 | </v-layout> |
1154 | </v-flex> | 1154 | </v-flex> |
1155 | <v-flex xs12 sm6> | 1155 | <v-flex xs12 sm6> |
1156 | <v-layout wrap> | 1156 | <v-layout wrap> |
1157 | <v-flex xs12 class="pt-4 subheading"> | 1157 | <v-flex xs12 class="pt-4 subheading"> |
1158 | <label>Password:</label> | 1158 | <label>Password:</label> |
1159 | </v-flex> | 1159 | </v-flex> |
1160 | <v-flex xs12> | 1160 | <v-flex xs12> |
1161 | <v-text-field | 1161 | <v-text-field |
1162 | v-model="parentData.password" | 1162 | v-model="parentData.password" |
1163 | placeholder="Enter Your Password" | 1163 | placeholder="Enter Your Password" |
1164 | ></v-text-field> | 1164 | ></v-text-field> |
1165 | </v-flex> | 1165 | </v-flex> |
1166 | </v-layout> | 1166 | </v-layout> |
1167 | </v-flex> | 1167 | </v-flex> |
1168 | </v-layout> | 1168 | </v-layout> |
1169 | <v-flex sm12 class="hidden-xs-only"> | 1169 | <v-flex sm12 class="hidden-xs-only"> |
1170 | <v-card-actions> | 1170 | <v-card-actions> |
1171 | <v-spacer></v-spacer> | 1171 | <v-spacer></v-spacer> |
1172 | <v-btn | 1172 | <v-btn |
1173 | @click="submitParentDetails" | 1173 | @click="submitParentDetails" |
1174 | round | 1174 | round |
1175 | dark | 1175 | dark |
1176 | :loading="loading" | 1176 | :loading="loading" |
1177 | v-show="showParent" | 1177 | v-show="showParent" |
1178 | class="add-button" | 1178 | class="add-button" |
1179 | >Add</v-btn> | 1179 | >Add</v-btn> |
1180 | <v-btn | 1180 | <v-btn |
1181 | v-show="showNext" | 1181 | v-show="showNext" |
1182 | @click="e2 = 2" | 1182 | @click="e2 = 2" |
1183 | round | 1183 | round |
1184 | dark | 1184 | dark |
1185 | class="add-button" | 1185 | class="add-button" |
1186 | >Next</v-btn> | 1186 | >Next</v-btn> |
1187 | </v-card-actions> | 1187 | </v-card-actions> |
1188 | </v-flex> | 1188 | </v-flex> |
1189 | <v-flex | 1189 | <v-flex |
1190 | xs6 | 1190 | xs6 |
1191 | class="hidden-md-only hidden-sm-only hidden-lg-only hidden-xl-only mx-auto mt-2" | 1191 | class="hidden-md-only hidden-sm-only hidden-lg-only hidden-xl-only mx-auto mt-2" |
1192 | > | 1192 | > |
1193 | <v-btn | 1193 | <v-btn |
1194 | @click="submitParentDetails" | 1194 | @click="submitParentDetails" |
1195 | round | 1195 | round |
1196 | dark | 1196 | dark |
1197 | :loading="loading" | 1197 | :loading="loading" |
1198 | v-show="showParent" | 1198 | v-show="showParent" |
1199 | class="add-button" | 1199 | class="add-button" |
1200 | >Add</v-btn> | 1200 | >Add</v-btn> |
1201 | <v-btn | 1201 | <v-btn |
1202 | v-show="showNext" | 1202 | v-show="showNext" |
1203 | @click="e2 = 2" | 1203 | @click="e2 = 2" |
1204 | round | 1204 | round |
1205 | dark | 1205 | dark |
1206 | class="add-button" | 1206 | class="add-button" |
1207 | >Next</v-btn> | 1207 | >Next</v-btn> |
1208 | </v-flex> | 1208 | </v-flex> |
1209 | </v-form> | 1209 | </v-form> |
1210 | </v-flex> | 1210 | </v-flex> |
1211 | <v-flex xs12 sm12 class="hidden-xs-only hidden-sm-only"> | 1211 | <v-flex xs12 sm12 class="hidden-xs-only hidden-sm-only"> |
1212 | <v-form ref="parentFormLgScr" v-model="valid" lazy-validation> | 1212 | <v-form ref="parentFormLgScr" v-model="valid" lazy-validation> |
1213 | <v-layout wrap> | 1213 | <v-layout wrap> |
1214 | <v-flex xs12 sm6> | 1214 | <v-flex xs12 sm6> |
1215 | <v-layout> | 1215 | <v-layout> |
1216 | <v-flex xs4 class="pt-4 subheading"> | 1216 | <v-flex xs4 class="pt-4 subheading"> |
1217 | <label class="right">Father Cell No:</label> | 1217 | <label class="right">Father Cell No:</label> |
1218 | </v-flex> | 1218 | </v-flex> |
1219 | <v-flex xs8 class="ml-3"> | 1219 | <v-flex xs8 class="ml-3"> |
1220 | <v-text-field | 1220 | <v-text-field |
1221 | v-model.trim="parentData.fatherCellNo" | 1221 | v-model.trim="parentData.fatherCellNo" |
1222 | placeholder="fill your father Cell Number" | 1222 | placeholder="fill your father Cell Number" |
1223 | type="number" | 1223 | type="number" |
1224 | :rules="fatheCellNoRules" | 1224 | :rules="fatheCellNoRules" |
1225 | counter="10" | 1225 | counter="10" |
1226 | required | 1226 | required |
1227 | v-on:keyup="getParentDetails()" | 1227 | v-on:keyup="getParentDetails()" |
1228 | ></v-text-field> | 1228 | ></v-text-field> |
1229 | </v-flex> | 1229 | </v-flex> |
1230 | </v-layout> | 1230 | </v-layout> |
1231 | </v-flex> | 1231 | </v-flex> |
1232 | <v-flex xs12 sm6> | 1232 | <v-flex xs12 sm6> |
1233 | <v-layout> | 1233 | <v-layout> |
1234 | <v-flex xs4 class="pt-4 subheading"> | 1234 | <v-flex xs4 class="pt-4 subheading"> |
1235 | <label class="right">Parent Email Id:</label> | 1235 | <label class="right">Parent Email Id:</label> |
1236 | </v-flex> | 1236 | </v-flex> |
1237 | <v-flex xs8 class="ml-3"> | 1237 | <v-flex xs8 class="ml-3"> |
1238 | <v-text-field | 1238 | <v-text-field |
1239 | placeholder="fill Parent email" | 1239 | placeholder="fill Parent email" |
1240 | v-model="parentData.email" | 1240 | v-model="parentData.email" |
1241 | type="text" | 1241 | type="text" |
1242 | required | 1242 | required |
1243 | ></v-text-field> | 1243 | ></v-text-field> |
1244 | </v-flex> | 1244 | </v-flex> |
1245 | </v-layout> | 1245 | </v-layout> |
1246 | </v-flex> | 1246 | </v-flex> |
1247 | </v-layout> | 1247 | </v-layout> |
1248 | <v-layout wrap> | 1248 | <v-layout wrap> |
1249 | <v-flex xs12 sm6> | 1249 | <v-flex xs12 sm6> |
1250 | <v-layout> | 1250 | <v-layout> |
1251 | <v-flex xs4 class="pt-4 subheading"> | 1251 | <v-flex xs4 class="pt-4 subheading"> |
1252 | <label class="right">Father Name:</label> | 1252 | <label class="right">Father Name:</label> |
1253 | </v-flex> | 1253 | </v-flex> |
1254 | <v-flex xs8 class="ml-3"> | 1254 | <v-flex xs8 class="ml-3"> |
1255 | <v-text-field | 1255 | <v-text-field |
1256 | v-model="parentData.fatherName" | 1256 | v-model="parentData.fatherName" |
1257 | placeholder="Fill your father Name" | 1257 | placeholder="Fill your father Name" |
1258 | required | 1258 | required |
1259 | ></v-text-field> | 1259 | ></v-text-field> |
1260 | </v-flex> | 1260 | </v-flex> |
1261 | </v-layout> | 1261 | </v-layout> |
1262 | </v-flex> | 1262 | </v-flex> |
1263 | <v-flex xs12 sm6> | 1263 | <v-flex xs12 sm6> |
1264 | <v-layout> | 1264 | <v-layout> |
1265 | <v-flex xs4 class="pt-4 subheading"> | 1265 | <v-flex xs4 class="pt-4 subheading"> |
1266 | <label class="right">Mother Name:</label> | 1266 | <label class="right">Mother Name:</label> |
1267 | </v-flex> | 1267 | </v-flex> |
1268 | <v-flex xs8 class="ml-3"> | 1268 | <v-flex xs8 class="ml-3"> |
1269 | <v-text-field | 1269 | <v-text-field |
1270 | v-model="parentData.motherName" | 1270 | v-model="parentData.motherName" |
1271 | placeholder="fill your Mother Name" | 1271 | placeholder="fill your Mother Name" |
1272 | type="text" | 1272 | type="text" |
1273 | required | 1273 | required |
1274 | ></v-text-field> | 1274 | ></v-text-field> |
1275 | </v-flex> | 1275 | </v-flex> |
1276 | </v-layout> | 1276 | </v-layout> |
1277 | </v-flex> | 1277 | </v-flex> |
1278 | </v-layout> | 1278 | </v-layout> |
1279 | <v-layout wrap> | 1279 | <v-layout wrap> |
1280 | <v-flex xs12 sm6> | 1280 | <v-flex xs12 sm6> |
1281 | <v-layout> | 1281 | <v-layout> |
1282 | <v-flex xs4 class="pt-4 subheading"> | 1282 | <v-flex xs4 class="pt-4 subheading"> |
1283 | <label class="right">Mother Cell No:</label> | 1283 | <label class="right">Mother Cell No:</label> |
1284 | </v-flex> | 1284 | </v-flex> |
1285 | <v-flex xs8 class="ml-3"> | 1285 | <v-flex xs8 class="ml-3"> |
1286 | <v-text-field | 1286 | <v-text-field |
1287 | v-model="parentData.motherCellNo" | 1287 | v-model="parentData.motherCellNo" |
1288 | placeholder="fill your Mother Cell Number" | 1288 | placeholder="fill your Mother Cell Number" |
1289 | type="number" | 1289 | type="number" |
1290 | required | 1290 | required |
1291 | ></v-text-field> | 1291 | ></v-text-field> |
1292 | </v-flex> | 1292 | </v-flex> |
1293 | </v-layout> | 1293 | </v-layout> |
1294 | </v-flex> | 1294 | </v-flex> |
1295 | <v-flex xs12 sm6> | 1295 | <v-flex xs12 sm6> |
1296 | <v-layout> | 1296 | <v-layout> |
1297 | <v-flex xs4 class="pt-4 subheading"> | 1297 | <v-flex xs4 class="pt-4 subheading"> |
1298 | <label class="right">Father Profession:</label> | 1298 | <label class="right">Father Profession:</label> |
1299 | </v-flex> | 1299 | </v-flex> |
1300 | <v-flex xs8 class="ml-3"> | 1300 | <v-flex xs8 class="ml-3"> |
1301 | <v-text-field | 1301 | <v-text-field |
1302 | v-model="parentData.fatherProfession" | 1302 | v-model="parentData.fatherProfession" |
1303 | placeholder="fill your father profession" | 1303 | placeholder="fill your father profession" |
1304 | ></v-text-field> | 1304 | ></v-text-field> |
1305 | </v-flex> | 1305 | </v-flex> |
1306 | </v-layout> | 1306 | </v-layout> |
1307 | </v-flex> | 1307 | </v-flex> |
1308 | </v-layout> | 1308 | </v-layout> |
1309 | <v-layout wrap> | 1309 | <v-layout wrap> |
1310 | <v-flex xs12 sm6> | 1310 | <v-flex xs12 sm6> |
1311 | <v-layout> | 1311 | <v-layout> |
1312 | <v-flex xs4 class="pt-4 subheading"> | 1312 | <v-flex xs4 class="pt-4 subheading"> |
1313 | <label class="right">Mother Profession:</label> | 1313 | <label class="right">Mother Profession:</label> |
1314 | </v-flex> | 1314 | </v-flex> |
1315 | <v-flex xs8 class="ml-3"> | 1315 | <v-flex xs8 class="ml-3"> |
1316 | <v-text-field | 1316 | <v-text-field |
1317 | v-model="parentData.motherProfession" | 1317 | v-model="parentData.motherProfession" |
1318 | placeholder="fill your mother profession" | 1318 | placeholder="fill your mother profession" |
1319 | ></v-text-field> | 1319 | ></v-text-field> |
1320 | </v-flex> | 1320 | </v-flex> |
1321 | </v-layout> | 1321 | </v-layout> |
1322 | </v-flex> | 1322 | </v-flex> |
1323 | <v-flex xs12 sm6> | 1323 | <v-flex xs12 sm6> |
1324 | <v-layout> | 1324 | <v-layout> |
1325 | <v-flex xs4 class="pt-4 subheading"> | 1325 | <v-flex xs4 class="pt-4 subheading"> |
1326 | <label class="right">Password:</label> | 1326 | <label class="right">Password:</label> |
1327 | </v-flex> | 1327 | </v-flex> |
1328 | <v-flex xs8 class="ml-3"> | 1328 | <v-flex xs8 class="ml-3"> |
1329 | <v-text-field | 1329 | <v-text-field |
1330 | :append-icon="e1 ? 'visibility_off' : 'visibility'" | 1330 | :append-icon="e1 ? 'visibility_off' : 'visibility'" |
1331 | :append-icon-cb="() => (e1 = !e1)" | 1331 | :append-icon-cb="() => (e1 = !e1)" |
1332 | :type="e1 ? 'password' : 'text'" | 1332 | :type="e1 ? 'password' : 'text'" |
1333 | :rules="password" | 1333 | :rules="password" |
1334 | v-model="parentData.password" | 1334 | v-model="parentData.password" |
1335 | placeholder="Enter Your Password" | 1335 | placeholder="Enter Your Password" |
1336 | :disabled="isFatherCellExists" | 1336 | :disabled="isFatherCellExists" |
1337 | required | 1337 | required |
1338 | ></v-text-field> | 1338 | ></v-text-field> |
1339 | </v-flex> | 1339 | </v-flex> |
1340 | </v-layout> | 1340 | </v-layout> |
1341 | </v-flex> | 1341 | </v-flex> |
1342 | </v-layout> | 1342 | </v-layout> |
1343 | <v-flex sm12 class="hidden-xs-only"> | 1343 | <v-flex sm12 class="hidden-xs-only"> |
1344 | <v-card-actions> | 1344 | <v-card-actions> |
1345 | <v-spacer></v-spacer> | 1345 | <v-spacer></v-spacer> |
1346 | <v-btn | 1346 | <v-btn |
1347 | @click="submitParentDetails" | 1347 | @click="submitParentDetails" |
1348 | round | 1348 | round |
1349 | dark | 1349 | dark |
1350 | :loading="loading" | 1350 | :loading="loading" |
1351 | v-show="showParent" | 1351 | v-show="showParent" |
1352 | class="add-button" | 1352 | class="add-button" |
1353 | >Add</v-btn> | 1353 | >Add</v-btn> |
1354 | <v-btn | 1354 | <v-btn |
1355 | v-show="showNext" | 1355 | v-show="showNext" |
1356 | @click="e2 = 2" | 1356 | @click="e2 = 2" |
1357 | round | 1357 | round |
1358 | dark | 1358 | dark |
1359 | class="add-button" | 1359 | class="add-button" |
1360 | >Next</v-btn> | 1360 | >Next</v-btn> |
1361 | </v-card-actions> | 1361 | </v-card-actions> |
1362 | </v-flex> | 1362 | </v-flex> |
1363 | <v-flex | 1363 | <v-flex |
1364 | xs6 | 1364 | xs6 |
1365 | class="hidden-md-only hidden-sm-only hidden-lg-only hidden-xl-only mx-auto mt-2" | 1365 | class="hidden-md-only hidden-sm-only hidden-lg-only hidden-xl-only mx-auto mt-2" |
1366 | > | 1366 | > |
1367 | <v-btn | 1367 | <v-btn |
1368 | @click="submitParentDetails" | 1368 | @click="submitParentDetails" |
1369 | round | 1369 | round |
1370 | dark | 1370 | dark |
1371 | :loading="loading" | 1371 | :loading="loading" |
1372 | v-show="showParent" | 1372 | v-show="showParent" |
1373 | class="add-button" | 1373 | class="add-button" |
1374 | >Add</v-btn> | 1374 | >Add</v-btn> |
1375 | <v-btn | 1375 | <v-btn |
1376 | v-show="showNext" | 1376 | v-show="showNext" |
1377 | @click="e2 = 2" | 1377 | @click="e2 = 2" |
1378 | round | 1378 | round |
1379 | dark | 1379 | dark |
1380 | class="add-button" | 1380 | class="add-button" |
1381 | >Next</v-btn> | 1381 | >Next</v-btn> |
1382 | </v-flex> | 1382 | </v-flex> |
1383 | </v-form> | 1383 | </v-form> |
1384 | </v-flex> | 1384 | </v-flex> |
1385 | </v-container> | 1385 | </v-container> |
1386 | </v-stepper-content> | 1386 | </v-stepper-content> |
1387 | <v-stepper-content step="2"> | 1387 | <v-stepper-content step="2"> |
1388 | <v-flex xs12 sm12> | 1388 | <v-flex xs12 sm12> |
1389 | <v-form ref="form" v-model="valid" lazy-validation> | 1389 | <v-form ref="form" v-model="valid" lazy-validation> |
1390 | <v-layout> | 1390 | <v-layout> |
1391 | <v-flex | 1391 | <v-flex |
1392 | xs12 | 1392 | xs12 |
1393 | class="text-xs-center text-sm-center text-md-center text-lg-center" | 1393 | class="text-xs-center text-sm-center text-md-center text-lg-center" |
1394 | > | 1394 | > |
1395 | <v-avatar size="100px"> | 1395 | <v-avatar size="100px"> |
1396 | <img src="/static/icon/user.png" v-if="!imageUrl" /> | 1396 | <img src="/static/icon/user.png" v-if="!imageUrl" /> |
1397 | </v-avatar> | 1397 | </v-avatar> |
1398 | <input | 1398 | <input |
1399 | type="file" | 1399 | type="file" |
1400 | style="display: none" | 1400 | style="display: none" |
1401 | ref="image" | 1401 | ref="image" |
1402 | accept="image/*" | 1402 | accept="image/*" |
1403 | @change="onFilePicked" | 1403 | @change="onFilePicked" |
1404 | /> | 1404 | /> |
1405 | <img | 1405 | <img |
1406 | :src="imageData.imageUrl" | 1406 | :src="imageData.imageUrl" |
1407 | height="150" | 1407 | height="150" |
1408 | v-if="imageUrl" | 1408 | v-if="imageUrl" |
1409 | style="border-radius:50%; width:200px" | 1409 | style="border-radius:50%; width:200px" |
1410 | /> | 1410 | /> |
1411 | </v-flex> | 1411 | </v-flex> |
1412 | </v-layout> | 1412 | </v-layout> |
1413 | <v-layout wrap> | 1413 | <v-layout wrap> |
1414 | <v-flex xs12 sm6> | 1414 | <v-flex xs12 sm6> |
1415 | <v-layout> | 1415 | <v-layout> |
1416 | <v-flex x4 sm4 class="pt-4 subheading"> | 1416 | <v-flex x4 sm4 class="pt-4 subheading"> |
1417 | <label class="right hidden-xs-only hidden-sm-only">Select Class:</label> | 1417 | <label class="right hidden-xs-only hidden-sm-only">Select Class:</label> |
1418 | <label | 1418 | <label |
1419 | class="right hidden-lg-only hidden-md-only hidden-xl-only" | 1419 | class="right hidden-lg-only hidden-md-only hidden-xl-only" |
1420 | >Class:</label> | 1420 | >Class:</label> |
1421 | </v-flex> | 1421 | </v-flex> |
1422 | <v-flex xs8 sm8 class="ml-3"> | 1422 | <v-flex xs8 sm8 class="ml-3"> |
1423 | <v-select | 1423 | <v-select |
1424 | :items="addclass" | 1424 | :items="addclass" |
1425 | label="Select Class" | 1425 | label="Select Class" |
1426 | v-model="addStudents.select" | 1426 | v-model="addStudents.select" |
1427 | item-text="classNum" | 1427 | item-text="classNum" |
1428 | item-value="_id" | 1428 | item-value="_id" |
1429 | name="Select Class" | 1429 | name="Select Class" |
1430 | :rules="classRules" | 1430 | :rules="classRules" |
1431 | @change="getSection(addStudents.select)" | 1431 | @change="getSection(addStudents.select)" |
1432 | required | 1432 | required |
1433 | ></v-select> | 1433 | ></v-select> |
1434 | </v-flex> | 1434 | </v-flex> |
1435 | </v-layout> | 1435 | </v-layout> |
1436 | </v-flex> | 1436 | </v-flex> |
1437 | <v-flex xs12 sm6> | 1437 | <v-flex xs12 sm6> |
1438 | <v-layout> | 1438 | <v-layout> |
1439 | <v-flex xs4 class="pt-4 subheading"> | 1439 | <v-flex xs4 class="pt-4 subheading"> |
1440 | <label class="right hidden-xs-only hidden-sm-only">Select Section:</label> | 1440 | <label class="right hidden-xs-only hidden-sm-only">Select Section:</label> |
1441 | <label | 1441 | <label |
1442 | class="right hidden-lg-only hidden-md-only hidden-xl-only" | 1442 | class="right hidden-lg-only hidden-md-only hidden-xl-only" |
1443 | >Section:</label> | 1443 | >Section:</label> |
1444 | </v-flex> | 1444 | </v-flex> |
1445 | <v-flex xs8 class="ml-3"> | 1445 | <v-flex xs8 class="ml-3"> |
1446 | <v-select | 1446 | <v-select |
1447 | :items="addSection" | 1447 | :items="addSection" |
1448 | label="Select Section" | 1448 | label="Select Section" |
1449 | v-model="addStudents.selectSection" | 1449 | v-model="addStudents.selectSection" |
1450 | item-text="name" | 1450 | item-text="name" |
1451 | item-value="_id" | 1451 | item-value="_id" |
1452 | name="Select Section" | 1452 | name="Select Section" |
1453 | :rules="sectionRules" | 1453 | :rules="sectionRules" |
1454 | required | 1454 | required |
1455 | ></v-select> | 1455 | ></v-select> |
1456 | </v-flex> | 1456 | </v-flex> |
1457 | </v-layout> | 1457 | </v-layout> |
1458 | </v-flex> | 1458 | </v-flex> |
1459 | </v-layout> | 1459 | </v-layout> |
1460 | <v-layout wrap> | 1460 | <v-layout wrap> |
1461 | <v-flex xs12 sm6> | 1461 | <v-flex xs12 sm6> |
1462 | <v-layout> | 1462 | <v-layout> |
1463 | <v-flex xs4 sm4 class="pt-4 subheading"> | 1463 | <v-flex xs4 sm4 class="pt-4 subheading"> |
1464 | <label class="right hidden-xs-only hidden-sm-only">Full Name:</label> | 1464 | <label class="right hidden-xs-only hidden-sm-only">Full Name:</label> |
1465 | <label | 1465 | <label |
1466 | class="right hidden-lg-only hidden-md-only hidden-xl-only" | 1466 | class="right hidden-lg-only hidden-md-only hidden-xl-only" |
1467 | >Name:</label> | 1467 | >Name:</label> |
1468 | </v-flex> | 1468 | </v-flex> |
1469 | <v-flex xs8 sm8 class="ml-3"> | 1469 | <v-flex xs8 sm8 class="ml-3"> |
1470 | <v-text-field | 1470 | <v-text-field |
1471 | v-model="addStudents.name" | 1471 | v-model="addStudents.name" |
1472 | placeholder="fill your full Name" | 1472 | placeholder="fill your full Name" |
1473 | name="name" | 1473 | name="name" |
1474 | type="text" | 1474 | type="text" |
1475 | :rules="nameRules" | 1475 | :rules="nameRules" |
1476 | required | 1476 | required |
1477 | ></v-text-field> | 1477 | ></v-text-field> |
1478 | </v-flex> | 1478 | </v-flex> |
1479 | </v-layout> | 1479 | </v-layout> |
1480 | </v-flex> | 1480 | </v-flex> |
1481 | <v-flex xs12 sm6> | 1481 | <v-flex xs12 sm6> |
1482 | <v-layout> | 1482 | <v-layout> |
1483 | <v-flex xs4 sm4 class="pt-4 subheading"> | 1483 | <v-flex xs4 sm4 class="pt-4 subheading"> |
1484 | <label class="right">Email:</label> | 1484 | <label class="right">Email:</label> |
1485 | </v-flex> | 1485 | </v-flex> |
1486 | <v-flex xs8 sm8 class="ml-3"> | 1486 | <v-flex xs8 sm8 class="ml-3"> |
1487 | <v-text-field | 1487 | <v-text-field |
1488 | placeholder="fill your email" | 1488 | placeholder="fill your email" |
1489 | v-model="addStudents.email" | 1489 | v-model="addStudents.email" |
1490 | type="text" | 1490 | type="text" |
1491 | name="email" | 1491 | name="email" |
1492 | required | 1492 | required |
1493 | ></v-text-field> | 1493 | ></v-text-field> |
1494 | </v-flex> | 1494 | </v-flex> |
1495 | </v-layout> | 1495 | </v-layout> |
1496 | </v-flex> | 1496 | </v-flex> |
1497 | </v-layout> | 1497 | </v-layout> |
1498 | <v-layout wrap> | 1498 | <v-layout wrap> |
1499 | <v-flex xs12 sm6> | 1499 | <v-flex xs12 sm6> |
1500 | <v-layout> | 1500 | <v-layout> |
1501 | <v-flex xs4 sm4 class="pt-4 subheading"> | 1501 | <v-flex xs4 sm4 class="pt-4 subheading"> |
1502 | <label class="right hidden-sm-only hidden-xs-only">Date of Birth:</label> | 1502 | <label class="right hidden-sm-only hidden-xs-only">Date of Birth:</label> |
1503 | <label | 1503 | <label |
1504 | class="right hidden-lg-only hidden-xl-only hidden-md-only" | 1504 | class="right hidden-lg-only hidden-xl-only hidden-md-only" |
1505 | >D.O.B:</label> | 1505 | >D.O.B:</label> |
1506 | </v-flex> | 1506 | </v-flex> |
1507 | <v-flex xs8 sm8 class="ml-3"> | 1507 | <v-flex xs8 sm8 class="ml-3"> |
1508 | <v-menu | 1508 | <v-menu |
1509 | ref="menu" | 1509 | ref="menu" |
1510 | :close-on-content-click="false" | 1510 | :close-on-content-click="false" |
1511 | v-model="menu" | 1511 | v-model="menu" |
1512 | :nudge-right="40" | 1512 | :nudge-right="40" |
1513 | lazy | 1513 | lazy |
1514 | transition="scale-transition" | 1514 | transition="scale-transition" |
1515 | offset-y | 1515 | offset-y |
1516 | full-width | 1516 | full-width |
1517 | min-width="290px" | 1517 | min-width="290px" |
1518 | > | 1518 | > |
1519 | <v-text-field | 1519 | <v-text-field |
1520 | slot="activator" | 1520 | slot="activator" |
1521 | :rules="dateRules" | 1521 | :rules="dateRules" |
1522 | v-model="addStudents.date" | 1522 | v-model="addStudents.date" |
1523 | placeholder="Select date" | 1523 | placeholder="Select date" |
1524 | ></v-text-field> | 1524 | ></v-text-field> |
1525 | <v-date-picker | 1525 | <v-date-picker |
1526 | ref="picker" | 1526 | ref="picker" |
1527 | v-model="addStudents.date" | 1527 | v-model="addStudents.date" |
1528 | :max="new Date().toISOString().substr(0, 10)" | 1528 | :max="new Date().toISOString().substr(0, 10)" |
1529 | min="1950-01-01" | 1529 | min="1950-01-01" |
1530 | @input="menu = false" | 1530 | @input="menu = false" |
1531 | ></v-date-picker> | 1531 | ></v-date-picker> |
1532 | </v-menu> | 1532 | </v-menu> |
1533 | </v-flex> | 1533 | </v-flex> |
1534 | </v-layout> | 1534 | </v-layout> |
1535 | </v-flex> | 1535 | </v-flex> |
1536 | <v-flex xs12 sm6> | 1536 | <v-flex xs12 sm6> |
1537 | <v-layout> | 1537 | <v-layout> |
1538 | <v-flex xs4 class="pt-4 subheading"> | 1538 | <v-flex xs4 class="pt-4 subheading"> |
1539 | <label class="right">City:</label> | 1539 | <label class="right">City:</label> |
1540 | </v-flex> | 1540 | </v-flex> |
1541 | <v-flex xs8 class="ml-3"> | 1541 | <v-flex xs8 class="ml-3"> |
1542 | <v-text-field | 1542 | <v-text-field |
1543 | v-model="addStudents.city" | 1543 | v-model="addStudents.city" |
1544 | placeholder="fill your City Name" | 1544 | placeholder="fill your City Name" |
1545 | name="City" | 1545 | name="City" |
1546 | type="text" | 1546 | type="text" |
1547 | :rules="cityRules" | 1547 | :rules="cityRules" |
1548 | required | 1548 | required |
1549 | ></v-text-field> | 1549 | ></v-text-field> |
1550 | </v-flex> | 1550 | </v-flex> |
1551 | </v-layout> | 1551 | </v-layout> |
1552 | </v-flex> | 1552 | </v-flex> |
1553 | </v-layout> | 1553 | </v-layout> |
1554 | <v-layout wrap> | 1554 | <v-layout wrap> |
1555 | <v-flex xs12 sm6> | 1555 | <v-flex xs12 sm6> |
1556 | <v-layout> | 1556 | <v-layout> |
1557 | <v-flex xs4 class="pt-4 subheading"> | 1557 | <v-flex xs4 class="pt-4 subheading"> |
1558 | <label class="right">State:</label> | 1558 | <label class="right">State:</label> |
1559 | </v-flex> | 1559 | </v-flex> |
1560 | <v-flex xs8 class="ml-3"> | 1560 | <v-flex xs8 class="ml-3"> |
1561 | <v-text-field | 1561 | <v-text-field |
1562 | v-model="addStudents.state" | 1562 | v-model="addStudents.state" |
1563 | placeholder="fill your State Name" | 1563 | placeholder="fill your State Name" |
1564 | name="state" | 1564 | name="state" |
1565 | type="text" | 1565 | type="text" |
1566 | :rules="stateRules" | 1566 | :rules="stateRules" |
1567 | required | 1567 | required |
1568 | ></v-text-field> | 1568 | ></v-text-field> |
1569 | </v-flex> | 1569 | </v-flex> |
1570 | </v-layout> | 1570 | </v-layout> |
1571 | </v-flex> | 1571 | </v-flex> |
1572 | <v-flex xs12 sm6> | 1572 | <v-flex xs12 sm6> |
1573 | <v-layout> | 1573 | <v-layout> |
1574 | <v-flex xs4 class="pt-4 subheading"> | 1574 | <v-flex xs4 class="pt-4 subheading"> |
1575 | <label class="right">Pincode:</label> | 1575 | <label class="right">Pincode:</label> |
1576 | </v-flex> | 1576 | </v-flex> |
1577 | <v-flex xs8 class="ml-3"> | 1577 | <v-flex xs8 class="ml-3"> |
1578 | <v-text-field | 1578 | <v-text-field |
1579 | v-model="addStudents.pincode" | 1579 | v-model="addStudents.pincode" |
1580 | placeholder="fill your pincode" | 1580 | placeholder="fill your pincode" |
1581 | name="pincode" | 1581 | name="pincode" |
1582 | type="number" | 1582 | type="number" |
1583 | :rules="pincode" | 1583 | :rules="pincode" |
1584 | required | 1584 | required |
1585 | ></v-text-field> | 1585 | ></v-text-field> |
1586 | </v-flex> | 1586 | </v-flex> |
1587 | </v-layout> | 1587 | </v-layout> |
1588 | </v-flex> | 1588 | </v-flex> |
1589 | </v-layout> | 1589 | </v-layout> |
1590 | <v-layout wrap> | 1590 | <v-layout wrap> |
1591 | <v-flex xs12 sm6> | 1591 | <v-flex xs12 sm6> |
1592 | <v-layout> | 1592 | <v-layout> |
1593 | <v-flex xs4 class="pt-4 subheading"> | 1593 | <v-flex xs4 class="pt-4 subheading"> |
1594 | <label class="right hidden-xs-only hidden-sm-only">Mobile No:</label> | 1594 | <label class="right hidden-xs-only hidden-sm-only">Mobile No:</label> |
1595 | <label | 1595 | <label |
1596 | class="right hidden-lg-only hidden-md-only hidden-xl-only" | 1596 | class="right hidden-lg-only hidden-md-only hidden-xl-only" |
1597 | >Mobile:</label> | 1597 | >Mobile:</label> |
1598 | </v-flex> | 1598 | </v-flex> |
1599 | <v-flex xs8 class="ml-3"> | 1599 | <v-flex xs8 class="ml-3"> |
1600 | <v-text-field | 1600 | <v-text-field |
1601 | v-model="addStudents.mobile" | 1601 | v-model="addStudents.mobile" |
1602 | placeholder="fill your MobileNo" | 1602 | placeholder="fill your MobileNo" |
1603 | name="mobileNo" | 1603 | name="mobileNo" |
1604 | type="number" | 1604 | type="number" |
1605 | ></v-text-field> | 1605 | ></v-text-field> |
1606 | </v-flex> | 1606 | </v-flex> |
1607 | </v-layout> | 1607 | </v-layout> |
1608 | </v-flex> | 1608 | </v-flex> |
1609 | <v-flex xs12 sm6> | 1609 | <v-flex xs12 sm6> |
1610 | <v-layout> | 1610 | <v-layout> |
1611 | <v-flex xs4 class="pt-4 subheading"> | 1611 | <v-flex xs4 class="pt-4 subheading"> |
1612 | <label class="right hidden-xs-only hidden-sm-only">Select Country:</label> | 1612 | <label class="right hidden-xs-only hidden-sm-only">Select Country:</label> |
1613 | <label | 1613 | <label |
1614 | class="right hidden-lg-only hidden-md-only hidden-xl-only" | 1614 | class="right hidden-lg-only hidden-md-only hidden-xl-only" |
1615 | >Country:</label> | 1615 | >Country:</label> |
1616 | </v-flex> | 1616 | </v-flex> |
1617 | <v-flex xs8 class="ml-3"> | 1617 | <v-flex xs8 class="ml-3"> |
1618 | <v-autocomplete | 1618 | <v-autocomplete |
1619 | v-model="addStudents.country" | 1619 | v-model="addStudents.country" |
1620 | :rules="country" | 1620 | :rules="country" |
1621 | :items="countries" | 1621 | :items="countries" |
1622 | placeholder="Select Country Name" | 1622 | placeholder="Select Country Name" |
1623 | required | 1623 | required |
1624 | ></v-autocomplete> | 1624 | ></v-autocomplete> |
1625 | </v-flex> | 1625 | </v-flex> |
1626 | </v-layout> | 1626 | </v-layout> |
1627 | </v-flex> | 1627 | </v-flex> |
1628 | </v-layout> | 1628 | </v-layout> |
1629 | <v-layout wrap> | 1629 | <v-layout wrap> |
1630 | <v-flex xs12 sm6> | 1630 | <v-flex xs12 sm6> |
1631 | <v-layout> | 1631 | <v-layout> |
1632 | <v-flex xs4 class="pt-4 subheading"> | 1632 | <v-flex xs4 class="pt-4 subheading"> |
1633 | <label class="right">Gender:</label> | 1633 | <label class="right">Gender:</label> |
1634 | </v-flex> | 1634 | </v-flex> |
1635 | <v-flex xs8 class="ml-3"> | 1635 | <v-flex xs8 class="ml-3"> |
1636 | <v-select | 1636 | <v-select |
1637 | :items="gender" | 1637 | :items="gender" |
1638 | v-model="addStudents.gender" | 1638 | v-model="addStudents.gender" |
1639 | :rules="genderRules" | 1639 | :rules="genderRules" |
1640 | label="Select Gender" | 1640 | label="Select Gender" |
1641 | required | 1641 | required |
1642 | ></v-select> | 1642 | ></v-select> |
1643 | </v-flex> | 1643 | </v-flex> |
1644 | </v-layout> | 1644 | </v-layout> |
1645 | </v-flex> | 1645 | </v-flex> |
1646 | <v-flex xs12 sm6> | 1646 | <v-flex xs12 sm6> |
1647 | <v-layout> | 1647 | <v-layout> |
1648 | <v-flex xs4 class="pt-4 subheading"> | 1648 | <v-flex xs4 class="pt-4 subheading"> |
1649 | <label class="right hidden-xs-only hidden-sm-only">Blood Group:</label> | 1649 | <label class="right hidden-xs-only hidden-sm-only">Blood Group:</label> |
1650 | <label | 1650 | <label |
1651 | class="right hidden-lg-only hidden-md-only hidden-xl-only" | 1651 | class="right hidden-lg-only hidden-md-only hidden-xl-only" |
1652 | >Blood:</label> | 1652 | >Blood:</label> |
1653 | </v-flex> | 1653 | </v-flex> |
1654 | <v-flex xs8 class="ml-3"> | 1654 | <v-flex xs8 class="ml-3"> |
1655 | <v-text-field | 1655 | <v-text-field |
1656 | v-model="addStudents.bloodGroup" | 1656 | v-model="addStudents.bloodGroup" |
1657 | placeholder="Fill your Blood Group" | 1657 | placeholder="Fill your Blood Group" |
1658 | required | 1658 | required |
1659 | ></v-text-field> | 1659 | ></v-text-field> |
1660 | </v-flex> | 1660 | </v-flex> |
1661 | </v-layout> | 1661 | </v-layout> |
1662 | </v-flex> | 1662 | </v-flex> |
1663 | </v-layout> | 1663 | </v-layout> |
1664 | <v-layout wrap> | 1664 | <v-layout wrap> |
1665 | <v-flex xs12 sm6> | 1665 | <v-flex xs12 sm6> |
1666 | <v-layout> | 1666 | <v-layout> |
1667 | <v-flex xs4 class="pt-4 subheading"> | 1667 | <v-flex xs4 class="pt-4 subheading"> |
1668 | <label class="right hidden-xs-only hidden-sm-only">Roll Number:</label> | 1668 | <label class="right hidden-xs-only hidden-sm-only">Roll Number:</label> |
1669 | <label | 1669 | <label |
1670 | class="right hidden-lg-only hidden-md-only hidden-xl-only" | 1670 | class="right hidden-lg-only hidden-md-only hidden-xl-only" |
1671 | >Roll No:</label> | 1671 | >Roll No:</label> |
1672 | </v-flex> | 1672 | </v-flex> |
1673 | <v-flex xs8 class="ml-3"> | 1673 | <v-flex xs8 class="ml-3"> |
1674 | <v-text-field | 1674 | <v-text-field |
1675 | v-model="addStudents.rollNo" | 1675 | v-model="addStudents.rollNo" |
1676 | placeholder="Fill your Roll Number" | 1676 | placeholder="Fill your Roll Number" |
1677 | :rules="rollNo" | 1677 | :rules="rollNo" |
1678 | required | 1678 | required |
1679 | ></v-text-field> | 1679 | ></v-text-field> |
1680 | </v-flex> | 1680 | </v-flex> |
1681 | </v-layout> | 1681 | </v-layout> |
1682 | </v-flex> | 1682 | </v-flex> |
1683 | <v-flex xs12 sm6> | 1683 | <v-flex xs12 sm6> |
1684 | <v-layout> | 1684 | <v-layout> |
1685 | <v-flex xs4 class="pt-4 subheading"> | 1685 | <v-flex xs4 class="pt-4 subheading"> |
1686 | <label class="right hidden-xs-only hidden-sm-only">Medical Notes:</label> | 1686 | <label class="right hidden-xs-only hidden-sm-only">Medical Notes:</label> |
1687 | <label | 1687 | <label |
1688 | class="right hidden-lg-only hidden-md-only hidden-xl-only" | 1688 | class="right hidden-lg-only hidden-md-only hidden-xl-only" |
1689 | >Medical:</label> | 1689 | >Medical:</label> |
1690 | </v-flex> | 1690 | </v-flex> |
1691 | <v-flex xs8 class="ml-3"> | 1691 | <v-flex xs8 class="ml-3"> |
1692 | <v-text-field | 1692 | <v-text-field |
1693 | v-model="addStudents.medicalNotes" | 1693 | v-model="addStudents.medicalNotes" |
1694 | placeholder="Fill your Medical Notes" | 1694 | placeholder="Fill your Medical Notes" |
1695 | required | 1695 | required |
1696 | ></v-text-field> | 1696 | ></v-text-field> |
1697 | </v-flex> | 1697 | </v-flex> |
1698 | </v-layout> | 1698 | </v-layout> |
1699 | </v-flex> | 1699 | </v-flex> |
1700 | </v-layout> | 1700 | </v-layout> |
1701 | <v-layout wrap> | 1701 | <v-layout wrap> |
1702 | <v-flex xs12 sm6> | 1702 | <v-flex xs12 sm6> |
1703 | <v-layout> | 1703 | <v-layout> |
1704 | <v-flex xs4 class="pt-4 subheading"> | 1704 | <v-flex xs4 class="pt-4 subheading"> |
1705 | <label class="right">Height:</label> | 1705 | <label class="right">Height:</label> |
1706 | </v-flex> | 1706 | </v-flex> |
1707 | <v-flex xs8 class="ml-3"> | 1707 | <v-flex xs8 class="ml-3"> |
1708 | <v-text-field | 1708 | <v-text-field |
1709 | v-model="addStudents.height" | 1709 | v-model="addStudents.height" |
1710 | placeholder="Fill your Height" | 1710 | placeholder="Fill your Height" |
1711 | required | 1711 | required |
1712 | ></v-text-field> | 1712 | ></v-text-field> |
1713 | </v-flex> | 1713 | </v-flex> |
1714 | </v-layout> | 1714 | </v-layout> |
1715 | </v-flex> | 1715 | </v-flex> |
1716 | <v-flex xs12 sm6> | 1716 | <v-flex xs12 sm6> |
1717 | <v-layout> | 1717 | <v-layout> |
1718 | <v-flex xs4 class="pt-4 subheading"> | 1718 | <v-flex xs4 class="pt-4 subheading"> |
1719 | <label class="right">Weight:</label> | 1719 | <label class="right">Weight:</label> |
1720 | </v-flex> | 1720 | </v-flex> |
1721 | <v-flex xs8 class="ml-3"> | 1721 | <v-flex xs8 class="ml-3"> |
1722 | <v-text-field | 1722 | <v-text-field |
1723 | v-model="addStudents.weight" | 1723 | v-model="addStudents.weight" |
1724 | placeholder="Fill your Weight" | 1724 | placeholder="Fill your Weight" |
1725 | required | 1725 | required |
1726 | ></v-text-field> | 1726 | ></v-text-field> |
1727 | </v-flex> | 1727 | </v-flex> |
1728 | </v-layout> | 1728 | </v-layout> |
1729 | </v-flex> | 1729 | </v-flex> |
1730 | </v-layout> | 1730 | </v-layout> |
1731 | <v-layout wrap> | 1731 | <v-layout wrap> |
1732 | <v-flex xs12 sm6> | 1732 | <v-flex xs12 sm6> |
1733 | <v-layout> | 1733 | <v-layout> |
1734 | <v-flex xs4 class="pt-4 subheading"> | 1734 | <v-flex xs4 class="pt-4 subheading"> |
1735 | <label class="right hidden-xs-only hidden-sm-only">Uplaod Image:</label> | 1735 | <label class="right hidden-xs-only hidden-sm-only">Uplaod Image:</label> |
1736 | <label | 1736 | <label |
1737 | class="right hidden-lg-only hidden-md-only hidden-xl-only" | 1737 | class="right hidden-lg-only hidden-md-only hidden-xl-only" |
1738 | >Uplaod :</label> | 1738 | >Uplaod :</label> |
1739 | </v-flex> | 1739 | </v-flex> |
1740 | <v-flex xs8 class="ml-3"> | 1740 | <v-flex xs8 class="ml-3"> |
1741 | <v-text-field | 1741 | <v-text-field |
1742 | label="Select Image" | 1742 | label="Select Image" |
1743 | @click="pickFile" | 1743 | @click="pickFile" |
1744 | v-model="imageName" | 1744 | v-model="imageName" |
1745 | append-icon="attach_file" | 1745 | append-icon="attach_file" |
1746 | ></v-text-field> | 1746 | ></v-text-field> |
1747 | </v-flex> | 1747 | </v-flex> |
1748 | </v-layout> | 1748 | </v-layout> |
1749 | </v-flex> | 1749 | </v-flex> |
1750 | <v-flex xs12 sm6> | 1750 | <v-flex xs12 sm6> |
1751 | <v-layout> | 1751 | <v-layout> |
1752 | <v-flex xs4 class="pt-4 subheading"> | 1752 | <v-flex xs4 class="pt-4 subheading"> |
1753 | <label class="right hidden-xs-only hidden-sm-only">Academic Year:</label> | 1753 | <label class="right hidden-xs-only hidden-sm-only">Academic Year:</label> |
1754 | <label | 1754 | <label |
1755 | class="right hidden-lg-only hidden-md-only hidden-xl-only" | 1755 | class="right hidden-lg-only hidden-md-only hidden-xl-only" |
1756 | >Year:</label> | 1756 | >Year:</label> |
1757 | </v-flex> | 1757 | </v-flex> |
1758 | <v-flex xs8 class="ml-3"> | 1758 | <v-flex xs8 class="ml-3"> |
1759 | <v-text-field | 1759 | <v-text-field |
1760 | v-model="addStudents.establishmentYear" | 1760 | v-model="addStudents.establishmentYear" |
1761 | placeholder="fill your Academic Year" | 1761 | placeholder="fill your Academic Year" |
1762 | name="state" | 1762 | name="state" |
1763 | type="number" | 1763 | type="number" |
1764 | :rules="establishmentYearRules" | 1764 | :rules="establishmentYearRules" |
1765 | required | 1765 | required |
1766 | ></v-text-field> | 1766 | ></v-text-field> |
1767 | </v-flex> | 1767 | </v-flex> |
1768 | </v-layout> | 1768 | </v-layout> |
1769 | </v-flex> | 1769 | </v-flex> |
1770 | </v-layout> | 1770 | </v-layout> |
1771 | <v-layout wrap class="hidden-xs-only hidden-sm-only"> | 1771 | <v-layout wrap class="hidden-xs-only hidden-sm-only"> |
1772 | <v-flex xs12 sm6> | 1772 | <v-flex xs12 sm6> |
1773 | <v-layout> | 1773 | <v-layout> |
1774 | <v-flex xs4 sm4 class="pt-4 subheading"> | 1774 | <v-flex xs4 sm4 class="pt-4 subheading"> |
1775 | <label class="right">Present Address:</label> | 1775 | <label class="right">Present Address:</label> |
1776 | </v-flex> | 1776 | </v-flex> |
1777 | <v-flex xs8 sm8 class="ml-3"> | 1777 | <v-flex xs8 sm8 class="ml-3"> |
1778 | <v-text-field | 1778 | <v-text-field |
1779 | v-model="addStudents.presentAddress" | 1779 | v-model="addStudents.presentAddress" |
1780 | :rules="presentAddress" | 1780 | :rules="presentAddress" |
1781 | placeholder="fill Your present Address" | 1781 | placeholder="fill Your present Address" |
1782 | @keyup="copyData" | 1782 | @keyup="copyData" |
1783 | ></v-text-field> | 1783 | ></v-text-field> |
1784 | </v-flex> | 1784 | </v-flex> |
1785 | </v-layout> | 1785 | </v-layout> |
1786 | </v-flex> | 1786 | </v-flex> |
1787 | <v-flex xs12 sm6> | 1787 | <v-flex xs12 sm6> |
1788 | <v-layout> | 1788 | <v-layout> |
1789 | <v-flex xs4 sm4 class="pt-4 subheading addressForm"> | 1789 | <v-flex xs4 sm4 class="pt-4 subheading addressForm"> |
1790 | <label class="right">Permanent Address:</label> | 1790 | <label class="right">Permanent Address:</label> |
1791 | </v-flex> | 1791 | </v-flex> |
1792 | <v-flex xs12 sm8 class="ml-3"> | 1792 | <v-flex xs12 sm8 class="ml-3"> |
1793 | <v-switch | 1793 | <v-switch |
1794 | v-model="addStudents.permanentAddress" | 1794 | v-model="addStudents.permanentAddress" |
1795 | label="Select Permanent Address" | 1795 | label="Select Permanent Address" |
1796 | :value="addStudents.presentAddress" | 1796 | :value="addStudents.presentAddress" |
1797 | ></v-switch> | 1797 | ></v-switch> |
1798 | </v-flex> | 1798 | </v-flex> |
1799 | </v-layout> | 1799 | </v-layout> |
1800 | </v-flex> | 1800 | </v-flex> |
1801 | </v-layout> | 1801 | </v-layout> |
1802 | <v-layout class="hidden-xs-only hidden-sm-only"> | 1802 | <v-layout class="hidden-xs-only hidden-sm-only"> |
1803 | <v-flex xs12 sm6> | 1803 | <v-flex xs12 sm6> |
1804 | <v-layout> | 1804 | <v-layout> |
1805 | <v-flex xs4 sm4 class="pt-4 subheading addressForm"> | 1805 | <v-flex xs4 sm4 class="pt-4 subheading addressForm"> |
1806 | <label class="right">Permanent Address:</label> | 1806 | <label class="right">Permanent Address:</label> |
1807 | </v-flex> | 1807 | </v-flex> |
1808 | <v-flex xs12 sm8 class="ml-3"> | 1808 | <v-flex xs12 sm8 class="ml-3"> |
1809 | <v-text-field | 1809 | <v-text-field |
1810 | v-model="addStudents.permanentAddress" | 1810 | v-model="addStudents.permanentAddress" |
1811 | :rules="permanentAddress" | 1811 | :rules="permanentAddress" |
1812 | placeholder="fill Your Permanent Address" | 1812 | placeholder="fill Your Permanent Address" |
1813 | ></v-text-field> | 1813 | ></v-text-field> |
1814 | </v-flex> | 1814 | </v-flex> |
1815 | </v-layout> | 1815 | </v-layout> |
1816 | </v-flex> | 1816 | </v-flex> |
1817 | </v-layout> | 1817 | </v-layout> |
1818 | <v-layout class="hidden-lg-only hidden-md-only hidden-xl-only" wrap> | 1818 | <v-layout class="hidden-lg-only hidden-md-only hidden-xl-only" wrap> |
1819 | <v-flex xs12 sm12> | 1819 | <v-flex xs12 sm12> |
1820 | <v-layout> | 1820 | <v-layout> |
1821 | <v-flex xs12 sm12 class="pt-4 subheading text-xs-center"> | 1821 | <v-flex xs12 sm12 class="pt-4 subheading text-xs-center"> |
1822 | <label class>Present Address:</label> | 1822 | <label class>Present Address:</label> |
1823 | </v-flex> | 1823 | </v-flex> |
1824 | </v-layout> | 1824 | </v-layout> |
1825 | <v-layout> | 1825 | <v-layout> |
1826 | <v-flex xs12 sm12> | 1826 | <v-flex xs12 sm12> |
1827 | <v-textarea | 1827 | <v-textarea |
1828 | name="input-4-3" | 1828 | name="input-4-3" |
1829 | v-model="addStudents.presentAddress" | 1829 | v-model="addStudents.presentAddress" |
1830 | :rules="presentAddress" | 1830 | :rules="presentAddress" |
1831 | placeholder="fill Your present Address" | 1831 | placeholder="fill Your present Address" |
1832 | required | 1832 | required |
1833 | ></v-textarea> | 1833 | ></v-textarea> |
1834 | </v-flex> | 1834 | </v-flex> |
1835 | </v-layout> | 1835 | </v-layout> |
1836 | </v-flex> | 1836 | </v-flex> |
1837 | <v-flex xs12 sm12> | 1837 | <v-flex xs12 sm12> |
1838 | <v-layout> | 1838 | <v-layout> |
1839 | <v-flex | 1839 | <v-flex |
1840 | xs12 | 1840 | xs12 |
1841 | sm12 | 1841 | sm12 |
1842 | class="pt-4 pr-4 subheading text-xs-center addressForm" | 1842 | class="pt-4 pr-4 subheading text-xs-center addressForm" |
1843 | > | 1843 | > |
1844 | <label>Permanent Address:</label> | 1844 | <label>Permanent Address:</label> |
1845 | </v-flex> | 1845 | </v-flex> |
1846 | </v-layout> | 1846 | </v-layout> |
1847 | <v-layout> | 1847 | <v-layout> |
1848 | <v-flex xs12 sm12> | 1848 | <v-flex xs12 sm12> |
1849 | <v-textarea | 1849 | <v-textarea |
1850 | name="input-4-3" | 1850 | name="input-4-3" |
1851 | v-model="addStudents.permanentAddress" | 1851 | v-model="addStudents.permanentAddress" |
1852 | :rules="permanentAddress" | 1852 | :rules="permanentAddress" |
1853 | placeholder="fill Your Permanent Address" | 1853 | placeholder="fill Your Permanent Address" |
1854 | required | 1854 | required |
1855 | ></v-textarea> | 1855 | ></v-textarea> |
1856 | </v-flex> | 1856 | </v-flex> |
1857 | </v-layout> | 1857 | </v-layout> |
1858 | </v-flex> | 1858 | </v-flex> |
1859 | </v-layout> | 1859 | </v-layout> |
1860 | <v-layout> | 1860 | <v-layout> |
1861 | <v-flex xs12 sm12> | 1861 | <v-flex xs12 sm12> |
1862 | <v-layout class="right"> | 1862 | <v-layout class="right"> |
1863 | <!-- <v-flex xs6> --> | 1863 | <!-- <v-flex xs6> --> |
1864 | <v-btn round dark @click="e2 = 1" class="clear-button">Back</v-btn> | 1864 | <v-btn round dark @click="e2 = 1" class="clear-button">Back</v-btn> |
1865 | <!-- </v-flex> | 1865 | <!-- </v-flex> |
1866 | <v-flex xs6>--> | 1866 | <v-flex xs6>--> |
1867 | <v-btn | 1867 | <v-btn |
1868 | @click="submit" | 1868 | @click="submit" |
1869 | round | 1869 | round |
1870 | dark | 1870 | dark |
1871 | :loading="loading" | 1871 | :loading="loading" |
1872 | class="add-button" | 1872 | class="add-button" |
1873 | >Add</v-btn> | 1873 | >Add</v-btn> |
1874 | <!-- </v-flex> --> | 1874 | <!-- </v-flex> --> |
1875 | </v-layout> | 1875 | </v-layout> |
1876 | </v-flex> | 1876 | </v-flex> |
1877 | </v-layout> | 1877 | </v-layout> |
1878 | </v-form> | 1878 | </v-form> |
1879 | </v-flex> | 1879 | </v-flex> |
1880 | </v-stepper-content> | 1880 | </v-stepper-content> |
1881 | </v-stepper-items> | 1881 | </v-stepper-items> |
1882 | </v-stepper> | 1882 | </v-stepper> |
1883 | </v-flex> | 1883 | </v-flex> |
1884 | </v-layout> | 1884 | </v-layout> |
1885 | </v-container> | 1885 | </v-container> |
1886 | </v-card> | 1886 | </v-card> |
1887 | </v-dialog> | 1887 | </v-dialog> |
1888 | <v-snackbar | 1888 | <v-snackbar |
1889 | :timeout="timeout" | 1889 | :timeout="timeout" |
1890 | :top="y === 'top'" | 1890 | :top="y === 'top'" |
1891 | :right="x === 'right'" | 1891 | :right="x === 'right'" |
1892 | :vertical="mode === 'vertical'" | 1892 | :vertical="mode === 'vertical'" |
1893 | v-model="snackbar" | 1893 | v-model="snackbar" |
1894 | :color="color" | 1894 | :color="color" |
1895 | >{{ text }}</v-snackbar> | 1895 | >{{ text }}</v-snackbar> |
1896 | <div class="loader" v-if="showLoader"> | 1896 | <div class="loader" v-if="showLoader"> |
1897 | <v-progress-circular indeterminate color="white"></v-progress-circular> | 1897 | <v-progress-circular indeterminate color="white"></v-progress-circular> |
1898 | </div> | 1898 | </div> |
1899 | </v-container> | 1899 | </v-container> |
1900 | </template> | 1900 | </template> |
1901 | 1901 | ||
1902 | <script> | 1902 | <script> |
1903 | import http from "@/Services/http.js"; | 1903 | import http from "@/Services/http.js"; |
1904 | import moment from "moment"; | 1904 | import moment from "moment"; |
1905 | import countryList from "@/script/country.js"; | 1905 | import countryList from "@/script/country.js"; |
1906 | import parent from "@/script/parents.js"; | 1906 | import parent from "@/script/parents.js"; |
1907 | 1907 | ||
1908 | export default { | 1908 | export default { |
1909 | data: () => ({ | 1909 | data: () => ({ |
1910 | e1: true, | 1910 | e1: true, |
1911 | e2: 0, | 1911 | e2: 0, |
1912 | showParent: true, | 1912 | showParent: true, |
1913 | showNext: false, | 1913 | showNext: false, |
1914 | snackbar: false, | 1914 | snackbar: false, |
1915 | y: "top", | 1915 | y: "top", |
1916 | x: "right", | 1916 | x: "right", |
1917 | role: "", | 1917 | role: "", |
1918 | mode: "", | 1918 | mode: "", |
1919 | append: "", | 1919 | append: "", |
1920 | timeout: 3000, | 1920 | timeout: 3000, |
1921 | text: "", | 1921 | text: "", |
1922 | show: true, | 1922 | show: true, |
1923 | color: "", | 1923 | color: "", |
1924 | showSearch: false, | 1924 | showSearch: false, |
1925 | showLoader: false, | 1925 | showLoader: false, |
1926 | loading: false, | 1926 | loading: false, |
1927 | editLoading: false, | 1927 | editLoading: false, |
1928 | date: null, | 1928 | date: null, |
1929 | search: "", | 1929 | search: "", |
1930 | password: "", | 1930 | password: "", |
1931 | menu: false, | 1931 | menu: false, |
1932 | menu1: false, | 1932 | menu1: false, |
1933 | editStudentDialog: false, | 1933 | editStudentDialog: false, |
1934 | profileStudentDialog: false, | 1934 | profileStudentDialog: false, |
1935 | addStudentDialog: false, | 1935 | addStudentDialog: false, |
1936 | valid: true, | 1936 | valid: true, |
1937 | addclass: [], | 1937 | addclass: [], |
1938 | addSection: [], | 1938 | addSection: [], |
1939 | gender: ["Male", "Female"], | 1939 | gender: ["Male", "Female"], |
1940 | pagination: { | 1940 | pagination: { |
1941 | rowsPerPage: 10, | 1941 | rowsPerPage: 10, |
1942 | }, | 1942 | }, |
1943 | imageData: {}, | 1943 | imageData: {}, |
1944 | imageName: "", | 1944 | imageName: "", |
1945 | imageUrl: "", | 1945 | imageUrl: "", |
1946 | imageFile: "", | 1946 | imageFile: "", |
1947 | editImageName: "", | 1947 | editImageName: "", |
1948 | editImageUrl: "", | 1948 | editImageUrl: "", |
1949 | nameRules: [(v) => !!v || " Full Name is required"], | 1949 | nameRules: [(v) => !!v || " Full Name is required"], |
1950 | dateRules: [(v) => !!v || " DOB is required"], | 1950 | dateRules: [(v) => !!v || " DOB is required"], |
1951 | cityRules: [(v) => !!v || " City Name is required"], | 1951 | cityRules: [(v) => !!v || " City Name is required"], |
1952 | pincode: [(v) => !!v || " Pincode is required"], | 1952 | pincode: [(v) => !!v || " Pincode is required"], |
1953 | country: [(v) => !!v || " Country Name is required"], | 1953 | country: [(v) => !!v || " Country Name is required"], |
1954 | rollNo: [(v) => !!v || "Roll No is required"], | 1954 | rollNo: [(v) => !!v || "Roll No is required"], |
1955 | permanentAddress: [(v) => !!v || " Permanent Address is required"], | 1955 | permanentAddress: [(v) => !!v || " Permanent Address is required"], |
1956 | presentAddress: [(v) => !!v || " Present Address is required"], | 1956 | presentAddress: [(v) => !!v || " Present Address is required"], |
1957 | stateRules: [(v) => !!v || "State Name is required"], | 1957 | stateRules: [(v) => !!v || "State Name is required"], |
1958 | classRules: [(v) => !!v || " Class Name is required"], | 1958 | classRules: [(v) => !!v || " Class Name is required"], |
1959 | sectionRules: [(v) => !!v || " Section Name is required"], | 1959 | sectionRules: [(v) => !!v || " Section Name is required"], |
1960 | genderRules: [(v) => !!v || " Select Gender is required"], | 1960 | genderRules: [(v) => !!v || " Select Gender is required"], |
1961 | fatheCellNoRules: [ | 1961 | fatheCellNoRules: [ |
1962 | (v) => !!v || " father Cell Number is required", | 1962 | (v) => !!v || " father Cell Number is required", |
1963 | (v) => v <= 10000000000 || "Max 10 characters is required", | 1963 | (v) => v <= 10000000000 || "Max 10 characters is required", |
1964 | ], | 1964 | ], |
1965 | password: [ | 1965 | password: [ |
1966 | (v) => !!v || "Password field is Required.", | 1966 | (v) => !!v || "Password field is Required.", |
1967 | // v => (/^(?=.*[a-z])(?=.*[0-9])(?=.*[!@#$%^&*])(?=.{8,})/).test(v) && v.length >= 8 | 1967 | // v => (/^(?=.*[a-z])(?=.*[0-9])(?=.*[!@#$%^&*])(?=.{8,})/).test(v) && v.length >= 8 |
1968 | ], | 1968 | ], |
1969 | mobileNoRule: [(v) => !!v || " Mobile Number is required"], | 1969 | mobileNoRule: [(v) => !!v || " Mobile Number is required"], |
1970 | establishmentYearRules: [(v) => !!v || " Academic Year is required"], | 1970 | establishmentYearRules: [(v) => !!v || " Academic Year is required"], |
1971 | errorMessages: "", | 1971 | errorMessages: "", |
1972 | countries: [], | 1972 | countries: [], |
1973 | headers: [ | 1973 | headers: [ |
1974 | { | 1974 | { |
1975 | text: "Roll No.", | 1975 | text: "Roll No.", |
1976 | align: "center", | 1976 | align: "center", |
1977 | sortable: false, | 1977 | sortable: false, |
1978 | value: "rollNo", | 1978 | value: "rollNo", |
1979 | }, | 1979 | }, |
1980 | { | 1980 | { |
1981 | text: "Profile Pic", | 1981 | text: "Profile Pic", |
1982 | value: "profilePicUrl", | 1982 | value: "profilePicUrl", |
1983 | sortable: false, | 1983 | sortable: false, |
1984 | align: "center", | 1984 | align: "center", |
1985 | }, | 1985 | }, |
1986 | { text: "Name", value: "name", sortable: false, align: "center" }, | 1986 | { text: "Name", value: "name", sortable: false, align: "center" }, |
1987 | { text: "Gender", value: "gender", sortable: false, align: "center" }, | 1987 | { text: "Gender", value: "gender", sortable: false, align: "center" }, |
1988 | { | 1988 | { |
1989 | text: "Father Name", | 1989 | text: "Father Name", |
1990 | value: "fatherName", | 1990 | value: "fatherName", |
1991 | sortable: false, | 1991 | sortable: false, |
1992 | align: "center", | 1992 | align: "center", |
1993 | }, | 1993 | }, |
1994 | { | 1994 | { |
1995 | text: "Mother Name", | 1995 | text: "Mother Name", |
1996 | value: "motherName", | 1996 | value: "motherName", |
1997 | sortable: false, | 1997 | sortable: false, |
1998 | align: "center", | 1998 | align: "center", |
1999 | }, | 1999 | }, |
2000 | { | 2000 | { |
2001 | text: "Academic Year", | 2001 | text: "Academic Year", |
2002 | value: "establishmentYear", | 2002 | value: "establishmentYear", |
2003 | sortable: false, | 2003 | sortable: false, |
2004 | align: "center", | 2004 | align: "center", |
2005 | }, | 2005 | }, |
2006 | // { text: "Mobile No", value: "mobile", sortable: false, align: "center" }, | 2006 | // { text: "Mobile No", value: "mobile", sortable: false, align: "center" }, |
2007 | { | 2007 | { |
2008 | text: "Status", | 2008 | text: "Status", |
2009 | value: "status", | 2009 | value: "status", |
2010 | sortable: false, | 2010 | sortable: false, |
2011 | align: "center", | 2011 | align: "center", |
2012 | }, | 2012 | }, |
2013 | { text: "Action", value: "", sortable: false, align: "center" }, | 2013 | { text: "Action", value: "", sortable: false, align: "center" }, |
2014 | ], | 2014 | ], |
2015 | studentsData: [], | 2015 | studentsData: [], |
2016 | parentId: "", | 2016 | parentId: "", |
2017 | editedIndex: -1, | 2017 | editedIndex: -1, |
2018 | parentData: {}, | 2018 | parentData: {}, |
2019 | addStudents: { | 2019 | addStudents: { |
2020 | role: "STUDENT", | 2020 | role: "STUDENT", |
2021 | name: "", | 2021 | name: "", |
2022 | email: "", | 2022 | email: "", |
2023 | date: "", | 2023 | date: "", |
2024 | city: "", | 2024 | city: "", |
2025 | pincode: "", | 2025 | pincode: "", |
2026 | country: "", | 2026 | country: "", |
2027 | permanentAddress: "", | 2027 | permanentAddress: "", |
2028 | presentAddress: "", | 2028 | presentAddress: "", |
2029 | mobile: "", | 2029 | mobile: "", |
2030 | state: "", | 2030 | state: "", |
2031 | gender: "", | 2031 | gender: "", |
2032 | select: "", | 2032 | select: "", |
2033 | selectSection: "", | 2033 | selectSection: "", |
2034 | bloodGroup: "", | 2034 | bloodGroup: "", |
2035 | allergies: "", | 2035 | allergies: "", |
2036 | medicalNotes: "", | 2036 | medicalNotes: "", |
2037 | height: "", | 2037 | height: "", |
2038 | weight: "", | 2038 | weight: "", |
2039 | rollNo: "", | 2039 | rollNo: "", |
2040 | establishmentYear: new Date().getFullYear(), | 2040 | establishmentYear: new Date().getFullYear(), |
2041 | }, | 2041 | }, |
2042 | selectStudents: { | 2042 | selectStudents: { |
2043 | select: "", | 2043 | select: "", |
2044 | selectSection: "", | 2044 | selectSection: "", |
2045 | }, | 2045 | }, |
2046 | editedItem: { | 2046 | editedItem: { |
2047 | role: "STUDENT", | 2047 | role: "STUDENT", |
2048 | name: "", | 2048 | name: "", |
2049 | email: "", | 2049 | email: "", |
2050 | dob: "", | 2050 | dob: "", |
2051 | city: "", | 2051 | city: "", |
2052 | pincode: "", | 2052 | pincode: "", |
2053 | country: "", | 2053 | country: "", |
2054 | permanentAddress: "", | 2054 | permanentAddress: "", |
2055 | presentAddress: "", | 2055 | presentAddress: "", |
2056 | mobile: "", | 2056 | mobile: "", |
2057 | state: "", | 2057 | state: "", |
2058 | gender: "", | 2058 | gender: "", |
2059 | select: "", | 2059 | select: "", |
2060 | selectSection: "", | 2060 | selectSection: "", |
2061 | bloodGroup: "", | 2061 | bloodGroup: "", |
2062 | allergies: "", | 2062 | allergies: "", |
2063 | medicalNotes: "", | 2063 | medicalNotes: "", |
2064 | height: "", | 2064 | height: "", |
2065 | weight: "", | 2065 | weight: "", |
2066 | rollNo: "", | 2066 | rollNo: "", |
2067 | establishmentYear: new Date().getFullYear(), | 2067 | establishmentYear: new Date().getFullYear(), |
2068 | }, | 2068 | }, |
2069 | isFatherCellExists: false, | 2069 | isFatherCellExists: false, |
2070 | }), | 2070 | }), |
2071 | watch: { | 2071 | watch: { |
2072 | menu(val) { | 2072 | menu(val) { |
2073 | val && this.$nextTick(() => (this.$refs.picker.activePicker = "YEAR")); | 2073 | val && this.$nextTick(() => (this.$refs.picker.activePicker = "YEAR")); |
2074 | }, | 2074 | }, |
2075 | menu1(val) { | 2075 | menu1(val) { |
2076 | val && this.$nextTick(() => (this.$refs.picker.activePicker = "YEAR")); | 2076 | val && this.$nextTick(() => (this.$refs.picker.activePicker = "YEAR")); |
2077 | }, | 2077 | }, |
2078 | addStudentDialog: function (val) { | 2078 | addStudentDialog: function (val) { |
2079 | if (!val) { | 2079 | if (!val) { |
2080 | this.parentData = []; | 2080 | this.parentData = []; |
2081 | this.addStudents = []; | 2081 | this.addStudents = []; |
2082 | this.imageName = ""; | 2082 | this.imageName = ""; |
2083 | this.imageFile = ""; | 2083 | this.imageFile = ""; |
2084 | this.imageUrl = ""; | 2084 | this.imageUrl = ""; |
2085 | this.e2 = 1; | ||
2085 | } | 2086 | } |
2086 | }, | 2087 | }, |
2087 | }, | 2088 | }, |
2088 | methods: { | 2089 | methods: { |
2089 | findStudents() { | 2090 | findStudents() { |
2090 | this.showLoader = true; | 2091 | this.showLoader = true; |
2091 | http() | 2092 | http() |
2092 | .get("/getStudentWithClass", { | 2093 | .get("/getStudentWithClass", { |
2093 | params: { | 2094 | params: { |
2094 | classId: this.selectStudents.select, | 2095 | classId: this.selectStudents.select, |
2095 | sectionId: this.selectStudents.selectSection, | 2096 | sectionId: this.selectStudents.selectSection, |
2096 | }, | 2097 | }, |
2097 | }) | 2098 | }) |
2098 | .then((response) => { | 2099 | .then((response) => { |
2099 | this.studentsData = response.data.data; | 2100 | this.studentsData = response.data.data; |
2100 | this.showLoader = false; | 2101 | this.showLoader = false; |
2101 | }) | 2102 | }) |
2102 | .catch((err) => { | 2103 | .catch((err) => { |
2103 | console.log("err====>", err); | 2104 | console.log("err====>", err); |
2104 | this.showLoader = false; | 2105 | this.showLoader = false; |
2105 | }); | 2106 | }); |
2106 | }, | 2107 | }, |
2107 | getSections(_id) { | 2108 | getSections(_id) { |
2108 | var token = this.$store.state.token; | 2109 | var token = this.$store.state.token; |
2109 | this.showLoader = true; | 2110 | this.showLoader = true; |
2110 | http() | 2111 | http() |
2111 | .get( | 2112 | .get( |
2112 | "/getSectionsList", | 2113 | "/getSectionsList", |
2113 | { params: { classId: _id } }, | 2114 | { params: { classId: _id } }, |
2114 | { | 2115 | { |
2115 | headers: { Authorization: "Bearer " + token }, | 2116 | headers: { Authorization: "Bearer " + token }, |
2116 | } | 2117 | } |
2117 | ) | 2118 | ) |
2118 | .then((response) => { | 2119 | .then((response) => { |
2119 | this.addSection = response.data.data; | 2120 | this.addSection = response.data.data; |
2120 | this.showLoader = false; | 2121 | this.showLoader = false; |
2121 | }) | 2122 | }) |
2122 | .catch((err) => { | 2123 | .catch((err) => { |
2123 | this.showLoader = false; | 2124 | this.showLoader = false; |
2124 | }); | 2125 | }); |
2125 | }, | 2126 | }, |
2126 | getSection(_id) { | 2127 | getSection(_id) { |
2127 | var token = this.$store.state.token; | 2128 | var token = this.$store.state.token; |
2128 | this.showLoader = true; | 2129 | this.showLoader = true; |
2129 | http() | 2130 | http() |
2130 | .get( | 2131 | .get( |
2131 | "/getSectionsList", | 2132 | "/getSectionsList", |
2132 | { params: { classId: _id } }, | 2133 | { params: { classId: _id } }, |
2133 | { | 2134 | { |
2134 | headers: { Authorization: "Bearer " + token }, | 2135 | headers: { Authorization: "Bearer " + token }, |
2135 | } | 2136 | } |
2136 | ) | 2137 | ) |
2137 | .then((response) => { | 2138 | .then((response) => { |
2138 | this.addSection = response.data.data; | 2139 | this.addSection = response.data.data; |
2139 | this.showLoader = false; | 2140 | this.showLoader = false; |
2140 | }) | 2141 | }) |
2141 | .catch((err) => { | 2142 | .catch((err) => { |
2142 | this.showLoader = false; | 2143 | this.showLoader = false; |
2143 | }); | 2144 | }); |
2144 | }, | 2145 | }, |
2145 | pickFile() { | 2146 | pickFile() { |
2146 | this.$refs.image.click(); | 2147 | this.$refs.image.click(); |
2147 | }, | 2148 | }, |
2148 | pickEditFile() { | 2149 | pickEditFile() { |
2149 | this.$refs.editDataImage.click(); | 2150 | this.$refs.editDataImage.click(); |
2150 | }, | 2151 | }, |
2151 | dates: function (date) { | 2152 | dates: function (date) { |
2152 | return moment(date).format("MMMM DD, YYYY"); | 2153 | return moment(date).format("MMMM DD, YYYY"); |
2153 | return date; | 2154 | return date; |
2154 | }, | 2155 | }, |
2155 | onFilePicked(e) { | 2156 | onFilePicked(e) { |
2156 | // console.log(e) | 2157 | // console.log(e) |
2157 | const files = e.target.files; | 2158 | const files = e.target.files; |
2158 | this.imageData.upload = e.target.files[0]; | 2159 | this.imageData.upload = e.target.files[0]; |
2159 | if (files[0] !== undefined) { | 2160 | if (files[0] !== undefined) { |
2160 | this.imageName = files[0].name; | 2161 | this.imageName = files[0].name; |
2161 | if (this.imageName.lastIndexOf(".") <= 0) { | 2162 | if (this.imageName.lastIndexOf(".") <= 0) { |
2162 | return; | 2163 | return; |
2163 | } | 2164 | } |
2164 | const fr = new FileReader(); | 2165 | const fr = new FileReader(); |
2165 | fr.readAsDataURL(files[0]); | 2166 | fr.readAsDataURL(files[0]); |
2166 | fr.addEventListener("load", () => { | 2167 | fr.addEventListener("load", () => { |
2167 | this.imageUrl = fr.result; | 2168 | this.imageUrl = fr.result; |
2168 | this.imageFile = files[0]; // this is an image file that can be sent to server... | 2169 | this.imageFile = files[0]; // this is an image file that can be sent to server... |
2169 | this.imageData.imageUrl = URL.createObjectURL(this.imageFile); | 2170 | this.imageData.imageUrl = URL.createObjectURL(this.imageFile); |
2170 | }); | 2171 | }); |
2171 | } else { | 2172 | } else { |
2172 | this.imageName = ""; | 2173 | this.imageName = ""; |
2173 | this.imageFile = ""; | 2174 | this.imageFile = ""; |
2174 | this.imageUrl = ""; | 2175 | this.imageUrl = ""; |
2175 | } | 2176 | } |
2176 | }, | 2177 | }, |
2177 | onEditFilePicked(e) { | 2178 | onEditFilePicked(e) { |
2178 | console.log(e); | 2179 | console.log(e); |
2179 | const files = e.target.files; | 2180 | const files = e.target.files; |
2180 | if (files[0] !== undefined) { | 2181 | if (files[0] !== undefined) { |
2181 | this.editImageName = files[0].name; | 2182 | this.editImageName = files[0].name; |
2182 | console.log("this.editImageName", this.editImageName); | 2183 | console.log("this.editImageName", this.editImageName); |
2183 | 2184 | ||
2184 | if (this.editImageName.lastIndexOf(".") <= 0) { | 2185 | if (this.editImageName.lastIndexOf(".") <= 0) { |
2185 | return; | 2186 | return; |
2186 | } | 2187 | } |
2187 | const fr = new FileReader(); | 2188 | const fr = new FileReader(); |
2188 | fr.readAsDataURL(files[0]); | 2189 | fr.readAsDataURL(files[0]); |
2189 | fr.addEventListener("load", () => { | 2190 | fr.addEventListener("load", () => { |
2190 | this.editImageUrl = fr.result; | 2191 | this.editImageUrl = fr.result; |
2191 | this.editiImageFile = files[0]; // this is an image file that can be sent to server... | 2192 | this.editiImageFile = files[0]; // this is an image file that can be sent to server... |
2192 | }); | 2193 | }); |
2193 | } else { | 2194 | } else { |
2194 | this.editImageName = ""; | 2195 | this.editImageName = ""; |
2195 | this.editiImageFile = ""; | 2196 | this.editiImageFile = ""; |
2196 | } | 2197 | } |
2197 | }, | 2198 | }, |
2198 | editItem(item) { | 2199 | editItem(item) { |
2199 | this.editedIndex = this.studentsData.indexOf(item); | 2200 | this.editedIndex = this.studentsData.indexOf(item); |
2200 | this.editedItem = Object.assign({}, item); | 2201 | this.editedItem = Object.assign({}, item); |
2201 | this.editedItem.fatherName = item.parentId.fatherName; | 2202 | this.editedItem.fatherName = item.parentId.fatherName; |
2202 | this.editedItem.fatherCellNo = item.parentId.fatherCellNo; | 2203 | this.editedItem.fatherCellNo = item.parentId.fatherCellNo; |
2203 | this.editedItem.motherName = item.parentId.motherName; | 2204 | this.editedItem.motherName = item.parentId.motherName; |
2204 | this.editedItem.motherCellNo = item.parentId.motherCellNo; | 2205 | this.editedItem.motherCellNo = item.parentId.motherCellNo; |
2205 | this.editedItem.dob = | 2206 | this.editedItem.dob = |
2206 | this.editedItem.dob != undefined | 2207 | this.editedItem.dob != undefined |
2207 | ? (this.editedItem.dob = this.editedItem.dob.substring(0, 10)) | 2208 | ? (this.editedItem.dob = this.editedItem.dob.substring(0, 10)) |
2208 | : (this.editedItem.dob = ""); | 2209 | : (this.editedItem.dob = ""); |
2209 | this.editStudentDialog = true; | 2210 | this.editStudentDialog = true; |
2210 | }, | 2211 | }, |
2211 | profile(item) { | 2212 | profile(item) { |
2212 | this.editedIndex = this.studentsData.indexOf(item); | 2213 | this.editedIndex = this.studentsData.indexOf(item); |
2213 | this.editedItem = Object.assign({}, item); | 2214 | this.editedItem = Object.assign({}, item); |
2214 | this.editedItem.fatherName = item.parentId.fatherName; | 2215 | this.editedItem.fatherName = item.parentId.fatherName; |
2215 | this.editedItem.fatherCellNo = item.parentId.fatherCellNo; | 2216 | this.editedItem.fatherCellNo = item.parentId.fatherCellNo; |
2216 | this.editedItem.motherName = item.parentId.motherName; | 2217 | this.editedItem.motherName = item.parentId.motherName; |
2217 | this.editedItem.motherCellNo = item.parentId.motherCellNo; | 2218 | this.editedItem.motherCellNo = item.parentId.motherCellNo; |
2218 | 2219 | ||
2219 | this.profileStudentDialog = true; | 2220 | this.profileStudentDialog = true; |
2220 | }, | 2221 | }, |
2221 | deleteItem(item) { | 2222 | deleteItem(item) { |
2222 | let deleteStudent = { | 2223 | let deleteStudent = { |
2223 | studentId: item._id, | 2224 | studentId: item._id, |
2224 | }; | 2225 | }; |
2225 | http() | 2226 | http() |
2226 | .delete( | 2227 | .delete( |
2227 | "/deleteStudent", | 2228 | "/deleteStudent", |
2228 | confirm("Are you sure you want to delete this?") && { | 2229 | confirm("Are you sure you want to delete this?") && { |
2229 | params: deleteStudent, | 2230 | params: deleteStudent, |
2230 | } | 2231 | } |
2231 | ) | 2232 | ) |
2232 | .then((response) => { | 2233 | .then((response) => { |
2233 | this.snackbar = true; | 2234 | this.snackbar = true; |
2234 | this.text = response.data.message; | 2235 | this.text = response.data.message; |
2235 | this.color = "green"; | 2236 | this.color = "green"; |
2236 | this.findStudents(); | 2237 | this.findStudents(); |
2237 | }) | 2238 | }) |
2238 | .catch((error) => { | 2239 | .catch((error) => { |
2239 | this.snackbar = true; | 2240 | this.snackbar = true; |
2240 | this.text = error.response.data.message; | 2241 | this.text = error.response.data.message; |
2241 | this.color = "error"; | 2242 | this.color = "error"; |
2242 | }); | 2243 | }); |
2243 | }, | 2244 | }, |
2244 | close() { | 2245 | close() { |
2245 | this.editStudentDialog = false; | 2246 | this.editStudentDialog = false; |
2246 | }, | 2247 | }, |
2247 | closeStudentProfile() { | 2248 | closeStudentProfile() { |
2248 | this.profileStudentDialog = false; | 2249 | this.profileStudentDialog = false; |
2249 | }, | 2250 | }, |
2250 | copyData() { | 2251 | copyData() { |
2251 | this.addStudents.permanentAddress = this.addStudents.presentAddress; | 2252 | this.addStudents.permanentAddress = this.addStudents.presentAddress; |
2252 | }, | 2253 | }, |
2253 | submit() { | 2254 | submit() { |
2254 | if (this.$refs.form.validate()) { | 2255 | if (this.$refs.form.validate()) { |
2255 | let addStudent = { | 2256 | let addStudent = { |
2256 | parentId: this.parentId, | 2257 | parentId: this.parentId, |
2257 | name: this.addStudents.name, | 2258 | name: this.addStudents.name, |
2258 | email: this.addStudents.email, | 2259 | email: this.addStudents.email, |
2259 | role: this.addStudents.role, | 2260 | role: this.addStudents.role, |
2260 | dob: this.addStudents.date, | 2261 | dob: this.addStudents.date, |
2261 | city: this.addStudents.city, | 2262 | city: this.addStudents.city, |
2262 | pincode: this.addStudents.pincode, | 2263 | pincode: this.addStudents.pincode, |
2263 | country: this.addStudents.country, | 2264 | country: this.addStudents.country, |
2264 | permanentAddress: this.addStudents.permanentAddress, | 2265 | permanentAddress: this.addStudents.permanentAddress, |
2265 | presentAddress: this.addStudents.presentAddress, | 2266 | presentAddress: this.addStudents.presentAddress, |
2266 | mobile: this.addStudents.mobile, | 2267 | mobile: this.addStudents.mobile, |
2267 | state: this.addStudents.state, | 2268 | state: this.addStudents.state, |
2268 | gender: this.addStudents.gender, | 2269 | gender: this.addStudents.gender, |
2269 | establishmentYear: this.addStudents.establishmentYear, | 2270 | establishmentYear: this.addStudents.establishmentYear, |
2270 | classId: this.addStudents.select, | 2271 | classId: this.addStudents.select, |
2271 | sectionId: this.addStudents.selectSection, | 2272 | sectionId: this.addStudents.selectSection, |
2272 | bloodGroup: this.addStudents.bloodGroup, | 2273 | bloodGroup: this.addStudents.bloodGroup, |
2273 | medicalNotes: this.addStudents.medicalNotes, | 2274 | medicalNotes: this.addStudents.medicalNotes, |
2274 | height: this.addStudents.height, | 2275 | height: this.addStudents.height, |
2275 | weight: this.addStudents.weight, | 2276 | weight: this.addStudents.weight, |
2276 | rollNo: this.addStudents.rollNo, | 2277 | rollNo: this.addStudents.rollNo, |
2277 | }; | 2278 | }; |
2278 | if (this.imageUrl) { | 2279 | if (this.imageUrl) { |
2279 | var str = this.imageUrl; | 2280 | var str = this.imageUrl; |
2280 | const [baseUrl, imageUrl] = str.split(/,/); | 2281 | const [baseUrl, imageUrl] = str.split(/,/); |
2281 | addStudent.upload = imageUrl; | 2282 | addStudent.upload = imageUrl; |
2282 | } | 2283 | } |
2283 | this.loading = true; | 2284 | this.loading = true; |
2284 | http() | 2285 | http() |
2285 | .post("/createStudent", addStudent) | 2286 | .post("/createStudent", addStudent) |
2286 | .then((response) => { | 2287 | .then((response) => { |
2287 | this.snackbar = true; | 2288 | this.snackbar = true; |
2288 | this.text = "New Student added successfully"; | 2289 | this.text = "New Student added successfully"; |
2289 | this.color = "green"; | 2290 | this.color = "green"; |
2290 | this.addStudentDialog = false; | 2291 | this.addStudentDialog = false; |
2291 | this.$refs.parentForm.reset(); | 2292 | this.$refs.parentForm.reset(); |
2292 | this.$refs.parentFormLgScr.reset(); | 2293 | this.$refs.parentFormLgScr.reset(); |
2293 | this.$refs.form.reset(); | 2294 | this.$refs.form.reset(); |
2294 | this.e2 = 1; | 2295 | this.e2 = 1; |
2295 | // this.clear(); | 2296 | // this.clear(); |
2296 | // this.clearParents(); | 2297 | // this.clearParents(); |
2297 | this.loading = false; | 2298 | this.loading = false; |
2298 | }) | 2299 | }) |
2299 | .catch((error) => { | 2300 | .catch((error) => { |
2300 | this.snackbar = true; | 2301 | this.snackbar = true; |
2301 | this.text = error.response.data.message; | 2302 | this.text = error.response.data.message; |
2302 | this.color = "error"; | 2303 | this.color = "error"; |
2303 | this.loading = false; | 2304 | this.loading = false; |
2304 | }); | 2305 | }); |
2305 | } | 2306 | } |
2306 | }, | 2307 | }, |
2307 | clear() { | 2308 | clear() { |
2308 | this.$refs.form.reset(); | 2309 | this.$refs.form.reset(); |
2309 | this.imageUrl = ""; | 2310 | this.imageUrl = ""; |
2310 | }, | 2311 | }, |
2311 | clearParents() { | 2312 | clearParents() { |
2312 | this.$refs.parentForm.reset(); | 2313 | this.$refs.parentForm.reset(); |
2313 | }, | 2314 | }, |
2314 | save() { | 2315 | save() { |
2315 | let editStudent = { | 2316 | let editStudent = { |
2316 | studentId: this.editedItem._id, | 2317 | studentId: this.editedItem._id, |
2317 | name: this.editedItem.name, | 2318 | name: this.editedItem.name, |
2318 | email: this.editedItem.email, | 2319 | email: this.editedItem.email, |
2319 | role: this.editedItem.role, | 2320 | role: this.editedItem.role, |
2320 | dob: this.editedItem.dob, | 2321 | dob: this.editedItem.dob, |
2321 | city: this.editedItem.city, | 2322 | city: this.editedItem.city, |
2322 | pincode: this.editedItem.pincode, | 2323 | pincode: this.editedItem.pincode, |
2323 | country: this.editedItem.country, | 2324 | country: this.editedItem.country, |
2324 | permanentAddress: this.editedItem.permanentAddress, | 2325 | permanentAddress: this.editedItem.permanentAddress, |
2325 | presentAddress: this.editedItem.presentAddress, | 2326 | presentAddress: this.editedItem.presentAddress, |
2326 | mobile: this.editedItem.mobile, | 2327 | mobile: this.editedItem.mobile, |
2327 | state: this.editedItem.state, | 2328 | state: this.editedItem.state, |
2328 | gender: this.editedItem.gender, | 2329 | gender: this.editedItem.gender, |
2329 | establishmentYear: this.editedItem.establishmentYear, | 2330 | establishmentYear: this.editedItem.establishmentYear, |
2330 | classId: this.editedItem.select, | 2331 | classId: this.editedItem.select, |
2331 | sectionId: this.editedItem.selectSection, | 2332 | sectionId: this.editedItem.selectSection, |
2332 | bloodGroup: this.editedItem.bloodGroup, | 2333 | bloodGroup: this.editedItem.bloodGroup, |
2333 | medicalNotes: this.editedItem.medicalNotes, | 2334 | medicalNotes: this.editedItem.medicalNotes, |
2334 | height: this.editedItem.height, | 2335 | height: this.editedItem.height, |
2335 | weight: this.editedItem.weight, | 2336 | weight: this.editedItem.weight, |
2336 | rollNo: this.editedItem.rollNo, | 2337 | rollNo: this.editedItem.rollNo, |
2337 | }; | 2338 | }; |
2338 | if (this.editImageUrl) { | 2339 | if (this.editImageUrl) { |
2339 | var str = this.editImageUrl; | 2340 | var str = this.editImageUrl; |
2340 | const [baseUrl, editImageUrl] = str.split(/,/); | 2341 | const [baseUrl, editImageUrl] = str.split(/,/); |
2341 | editStudent.upload = editImageUrl; | 2342 | editStudent.upload = editImageUrl; |
2342 | } | 2343 | } |
2343 | this.editLoading = true; | 2344 | this.editLoading = true; |
2344 | http() | 2345 | http() |
2345 | .put("/updateStudent", editStudent) | 2346 | .put("/updateStudent", editStudent) |
2346 | .then((response) => { | 2347 | .then((response) => { |
2347 | this.snackbar = true; | 2348 | this.snackbar = true; |
2348 | this.text = response.data.message; | 2349 | this.text = response.data.message; |
2349 | this.color = "green"; | 2350 | this.color = "green"; |
2350 | this.imageUrl = ""; | 2351 | this.imageUrl = ""; |
2351 | this.findStudents(); | 2352 | this.findStudents(); |
2352 | this.close(); | 2353 | this.close(); |
2353 | this.editLoading = false; | 2354 | this.editLoading = false; |
2354 | }) | 2355 | }) |
2355 | .catch((error) => { | 2356 | .catch((error) => { |
2356 | this.snackbar = true; | 2357 | this.snackbar = true; |
2357 | this.text = error.response.data.statusText; | 2358 | this.text = error.response.data.statusText; |
2358 | this.color = "error"; | 2359 | this.color = "error"; |
2359 | this.editLoading = false; | 2360 | this.editLoading = false; |
2360 | }); | 2361 | }); |
2361 | }, | 2362 | }, |
2362 | submitParentDetails() { | 2363 | submitParentDetails() { |
2363 | if (this.$refs.parentForm.validate()) { | 2364 | if (this.$refs.parentForm.validate()) { |
2364 | this.parentData.fatherCellNo = this.parentData.fatherCellNo; | 2365 | this.parentData.fatherCellNo = this.parentData.fatherCellNo; |
2365 | this.parentData.motherCellNo = this.parentData.motherCellNo; | 2366 | this.parentData.motherCellNo = this.parentData.motherCellNo; |
2366 | let addparentDetails = { | 2367 | let addparentDetails = { |
2367 | email: this.parentData.email, | 2368 | email: this.parentData.email, |
2368 | fatherName: this.parentData.fatherName, | 2369 | fatherName: this.parentData.fatherName, |
2369 | fatherCellNo: this.parentData.fatherCellNo, | 2370 | fatherCellNo: this.parentData.fatherCellNo, |
2370 | motherName: this.parentData.motherName, | 2371 | motherName: this.parentData.motherName, |
2371 | motherCellNo: this.parentData.motherCellNo, | 2372 | motherCellNo: this.parentData.motherCellNo, |
2372 | fatherProfession: this.parentData.fatherProfession, | 2373 | fatherProfession: this.parentData.fatherProfession, |
2373 | motherProfession: this.parentData.motherProfession, | 2374 | motherProfession: this.parentData.motherProfession, |
2374 | password: this.parentData.password, | 2375 | password: this.parentData.password, |
2375 | role: "PARENT", | 2376 | role: "PARENT", |
2376 | }; | 2377 | }; |
2377 | this.loading = true; | 2378 | this.loading = true; |
2378 | http() | 2379 | http() |
2379 | .post("/createParent", addparentDetails) | 2380 | .post("/createParent", addparentDetails) |
2380 | .then((response) => { | 2381 | .then((response) => { |
2381 | this.parentId = response.data.data.id; | 2382 | this.parentId = response.data.data.id; |
2382 | this.e2 = 2; | 2383 | this.e2 = 2; |
2383 | this.snackbar = true; | 2384 | this.snackbar = true; |
2384 | this.text = response.data.message; | 2385 | this.text = response.data.message; |
2385 | this.color = "green"; | 2386 | this.color = "green"; |
2386 | // this.getStudentList(); | 2387 | // this.getStudentList(); |
2387 | this.clear(); | 2388 | this.clear(); |
2388 | this.loading = false; | 2389 | this.loading = false; |
2389 | }) | 2390 | }) |
2390 | .catch((error) => { | 2391 | .catch((error) => { |
2391 | this.snackbar = true; | 2392 | this.snackbar = true; |
2392 | this.text = error.response.data.message; | 2393 | this.text = error.response.data.message; |
2393 | this.color = "error"; | 2394 | this.color = "error"; |
2394 | if (error.response.data.statusText) { | 2395 | if (error.response.data.statusText) { |
2395 | this.text = error.response.data.statusText; | 2396 | this.text = error.response.data.statusText; |
2396 | } | 2397 | } |
2397 | this.loading = false; | 2398 | this.loading = false; |
2398 | }); | 2399 | }); |
2399 | } | 2400 | } |
2400 | }, | 2401 | }, |
2401 | getParentDetails() { | 2402 | getParentDetails() { |
2402 | if (this.parentData.fatherCellNo.length > 9) { | 2403 | if (this.parentData.fatherCellNo.length > 9) { |
2403 | this.showLoader = true; | 2404 | this.showLoader = true; |
2404 | this.isFatherCellExists = false; | 2405 | this.isFatherCellExists = false; |
2405 | http() | 2406 | http() |
2406 | .get("getParticularParent", { | 2407 | .get("getParticularParent", { |
2407 | params: { fatherCellNo: this.parentData.fatherCellNo }, | 2408 | params: { fatherCellNo: this.parentData.fatherCellNo }, |
2408 | headers: { | 2409 | headers: { |
2409 | Authorization: "Bearer " + this.$store.state.token, | 2410 | Authorization: "Bearer " + this.$store.state.token, |
2410 | }, | 2411 | }, |
2411 | }) | 2412 | }) |
2412 | .then((response) => { | 2413 | .then((response) => { |
2413 | this.showNext = true; | 2414 | this.showNext = true; |
2414 | this.showParent = false; | 2415 | this.showParent = false; |
2415 | this.parentData = response.data.data; | 2416 | this.parentData = response.data.data; |
2416 | this.parentId = response.data.data._id; | 2417 | this.parentId = response.data.data._id; |
2417 | this.showLoader = false; | 2418 | this.showLoader = false; |
2418 | this.isFatherCellExists = true; | 2419 | this.isFatherCellExists = true; |
2419 | }) | 2420 | }) |
2420 | .catch((error) => { | 2421 | .catch((error) => { |
2421 | console.log("err====>", error.response.data.message); | 2422 | console.log("err====>", error.response.data.message); |
2422 | this.text = error.response.data.message; | 2423 | this.text = error.response.data.message; |
2423 | this.snackbar = true; | 2424 | this.snackbar = true; |
2424 | this.color = "error"; | 2425 | this.color = "error"; |
2425 | if (this.text === "Data not found!") { | 2426 | if (this.text === "Data not found!") { |
2426 | this.showNext = false; | 2427 | this.showNext = false; |
2427 | this.showParent = true; | 2428 | this.showParent = true; |
2428 | this.parentData.email = ""; | 2429 | this.parentData.email = ""; |
2429 | this.parentData.fatherName = ""; | 2430 | this.parentData.fatherName = ""; |
2430 | this.parentData.motherName = ""; | 2431 | this.parentData.motherName = ""; |
2431 | this.parentData.motherCellNo = ""; | 2432 | this.parentData.motherCellNo = ""; |
2432 | this.parentData.fatherProfession = ""; | 2433 | this.parentData.fatherProfession = ""; |
2433 | this.parentData.motherProfession = ""; | 2434 | this.parentData.motherProfession = ""; |
2434 | this.parentData.password = ""; | 2435 | this.parentData.password = ""; |
2435 | } | 2436 | } |
2436 | this.showLoader = false; | 2437 | this.showLoader = false; |
2437 | }); | 2438 | }); |
2438 | } | 2439 | } |
2439 | }, | 2440 | }, |
2440 | suspendStudentStatus(status, id) { | 2441 | suspendStudentStatus(status, id) { |
2441 | let suspendStudentData = { | 2442 | let suspendStudentData = { |
2442 | studentId: id, | 2443 | studentId: id, |
2443 | status: status, | 2444 | status: status, |
2444 | }; | 2445 | }; |
2445 | http() | 2446 | http() |
2446 | .put("/suspendStudentAccount", suspendStudentData) | 2447 | .put("/suspendStudentAccount", suspendStudentData) |
2447 | .then((response) => { | 2448 | .then((response) => { |
2448 | this.findStudents(); | 2449 | this.findStudents(); |
2449 | this.text = response.data.message; | 2450 | this.text = response.data.message; |
2450 | this.color = "green"; | 2451 | this.color = "green"; |
2451 | this.snackbar = true; | 2452 | this.snackbar = true; |
2452 | }) | 2453 | }) |
2453 | .catch((error) => { | 2454 | .catch((error) => { |
2454 | this.snackbar = true; | 2455 | this.snackbar = true; |
2455 | this.color = "error"; | 2456 | this.color = "error"; |
2456 | this.text = error.response.data.message; | 2457 | this.text = error.response.data.message; |
2457 | }); | 2458 | }); |
2458 | }, | 2459 | }, |
2459 | displaySearch() { | 2460 | displaySearch() { |
2460 | (this.show = false), (this.showSearch = true); | 2461 | (this.show = false), (this.showSearch = true); |
2461 | }, | 2462 | }, |
2462 | closeSearch() { | 2463 | closeSearch() { |
2463 | this.showSearch = false; | 2464 | this.showSearch = false; |
2464 | this.show = true; | 2465 | this.show = true; |
2465 | this.search = ""; | 2466 | this.search = ""; |
2466 | }, | 2467 | }, |
2467 | }, | 2468 | }, |
2468 | mounted() { | 2469 | mounted() { |
2469 | const getCountryList = countryList(); | 2470 | const getCountryList = countryList(); |
2470 | this.role = this.$store.state.role; | 2471 | this.role = this.$store.state.role; |
2471 | this.countries = getCountryList; | 2472 | this.countries = getCountryList; |
2472 | var token = this.$store.state.token; | 2473 | var token = this.$store.state.token; |
2473 | http() | 2474 | http() |
2474 | .get("/getClassesList", { | 2475 | .get("/getClassesList", { |
2475 | headers: { Authorization: "Bearer " + token }, | 2476 | headers: { Authorization: "Bearer " + token }, |
2476 | }) | 2477 | }) |
2477 | .then((response) => { | 2478 | .then((response) => { |
2478 | this.addclass = response.data.data; | 2479 | this.addclass = response.data.data; |
2479 | }) | 2480 | }) |
2480 | .catch((error) => { | 2481 | .catch((error) => { |
2481 | this.showLoader = false; | 2482 | this.showLoader = false; |
2482 | if (error.response.status === 401) { | 2483 | if (error.response.status === 401) { |
2483 | this.$router.replace({ path: "/" }); | 2484 | this.$router.replace({ path: "/" }); |
2484 | this.$store.dispatch("setToken", null); | 2485 | this.$store.dispatch("setToken", null); |
2485 | this.$store.dispatch("Id", null); | 2486 | this.$store.dispatch("Id", null); |
2486 | this.$store.dispatch("Role", null); | 2487 | this.$store.dispatch("Role", null); |
2487 | } | 2488 | } |
2488 | }); | 2489 | }); |
2489 | }, | 2490 | }, |
2490 | }; | 2491 | }; |
2491 | </script> | 2492 | </script> |
2492 | <style scoped> | 2493 | <style scoped> |
2493 | .active { | 2494 | .active { |
2494 | background-color: gray; | 2495 | background-color: gray; |
2495 | color: white !important; | 2496 | color: white !important; |
2496 | } | 2497 | } |
2497 | .activebtn { | 2498 | .activebtn { |
2498 | color: black !important; | 2499 | color: black !important; |
2499 | } | 2500 | } |
2500 | </style> | 2501 | </style> |