Commit acb6c9e2b20d8a920e0a8ccc2ea29d23c1125152

Authored by Shikha Mishra
1 parent 461ae23300

issues solved related to bugs

... ... @@ -116,6 +116,7 @@ const adminMenu = [
116 116 { name: 'salaryTemplate', title: 'Salary Template', component: 'Salary Template', action: '', },
117 117 { name: 'hourlyTemplate', title: 'Hourly Template', component: 'Hourly Template', action: '', },
118 118 { name: 'manageSalary', title: 'Manage Salary', component: 'Manage Salary', action: '', },
  119 + { name: 'makePayment', title: 'Make Payment', component: 'Make Payment', action: '', },
119 120 ]
120 121 },
121 122 {
... ... @@ -210,33 +211,46 @@ const adminMenu = [
210 211 ];
211 212  
212 213 const libraryMenu = [{
213   - title: 'Library',
214   - group: 'Library',
215   - component: 'Library',
216   - icon: '/static/schoolIcons/Library.png',
217   - items: [
218   - { name: 'libraryMember', title: ' Library Member', component: 'libraryMember', action: '', },
219   - { name: 'Books', title: 'Books', component: 'Books', action: '', },
220   - { name: 'Issue', title: ' Issue', component: 'Issue', action: '', },
221   - { name: 'eBooks', title: 'E-Books', component: 'eBooks', action: '', }
  214 + title: 'Dashboard',
  215 + name: 'Dashboard',
  216 + icon: '/static/icon/dashboard.png',
  217 + },
  218 + {
  219 + title: 'Library',
  220 + group: 'Library',
  221 + component: 'Library',
  222 + icon: '/static/icon/library.png',
  223 + items: [
  224 + { name: 'LibraryMember', title: ' Library Member', component: 'Library Member', action: '', },
  225 + { name: 'Books', title: 'Books', component: 'Books', action: '', },
  226 + { name: 'Issue', title: ' Issue', component: 'Issue', action: '', },
  227 + { name: 'E-Books', title: 'E-Books', component: 'E-Books', action: '', }
222 228  
223   - ]
224   -}];
  229 + ]
  230 + },
  231 +];
225 232  
226 233 const accountMenu = [{
227   - title: 'Account',
228   - group: 'Account',
229   - component: 'Account',
230   - icon: '/static/schoolIcons/Account.png',
231   - items: [
232   - { name: 'feeTypes', title: 'Fee Types', component: 'feeTypes', action: '', },
233   - { name: 'Invoice', title: 'Invoice', component: 'Invoice', action: '', },
234   - { name: 'paymentHistory', title: 'Payment History', component: 'paymentHistory', action: '', },
235   - { name: 'Expense', title: 'Expense', component: 'Expense', action: '', },
236   - { name: 'Income', title: 'Income', component: 'Income', action: '', },
237   - { name: 'GlobalPayment', title: 'Global Payment', component: 'GlobalPayment', action: '', }
238   - ]
239   -}];
  234 + title: 'Dashboard',
  235 + name: 'Dashboard',
  236 + icon: '/static/icon/dashboard.png',
  237 + },
  238 +
  239 + {
  240 + title: 'Account',
  241 + group: 'Account',
  242 + component: 'Account',
  243 + icon: '/static/icon/accounts.png',
  244 + items: [
  245 + { name: 'feeTypes', title: 'Fee Types', component: 'Fee Types', action: '', },
  246 + { name: 'Invoice', title: 'Invoice', component: 'Invoice', action: '', },
  247 + { name: 'PaymentHistory', title: 'Payment History', component: 'Payment History', action: '', },
  248 + { name: 'Expense', title: 'Expense', component: 'Expense', action: '', },
  249 + { name: 'Income', title: 'Income', component: 'Income', action: '', },
  250 + { name: 'GlobalPayment', title: 'Global Payment', component: 'Global Payment', action: '', }
  251 + ]
  252 + },
  253 +];
240 254  
241 255 const schoolMenu = [
242 256 // { header: 'Apps' },
... ...
src/components/pageHeader/AppDrawer.vue
... ... @@ -130,6 +130,200 @@
130 130 <!-- </a> -->
131 131 </v-list-tile>
132 132 </template>
  133 + <template v-for="(item, i) in menuAccount" v-if="role === 'ACCOUNTANT'">
  134 + <!-- {{menus}} -->
  135 + <!--group with subitems-->
  136 + <v-list-group
  137 + v-if="item.items"
  138 + :key="item.name"
  139 + :group="item.group"
  140 + no-action="no-action"
  141 + >
  142 + <v-list-tile slot="activator" ripple="ripple">
  143 + <v-list-tile-action v-if="item.icon">
  144 + <img :src="item.icon" width="22" alt="icons" />
  145 + </v-list-tile-action>
  146 + <v-list-tile-content>
  147 + <v-list-tile-title>{{ item.title }}</v-list-tile-title>
  148 + </v-list-tile-content>
  149 + </v-list-tile>
  150 + <template v-for="(subItem, i) in item.items">
  151 + <!--sub group-->
  152 + <v-list-group
  153 + v-if="subItem.items"
  154 + :key="subItem.name"
  155 + :group="subItem.group"
  156 + sub-group="sub-group"
  157 + >
  158 + <v-list-tile slot="activator" ripple="ripple">
  159 + <v-list-tile-content>
  160 + <v-list-tile-title>{{ subItem.title }}</v-list-tile-title>
  161 + </v-list-tile-content>
  162 + </v-list-tile>
  163 + <v-list-tile
  164 + v-for="(grand, i) in subItem.children"
  165 + :key="i"
  166 + :to="genChildTarget(item, grand)"
  167 + :href="grand.href"
  168 + ripple="ripple"
  169 + >
  170 + <v-list-tile-content>
  171 + <v-list-tile-title>{{ grand.title }}</v-list-tile-title>
  172 + </v-list-tile-content>
  173 + </v-list-tile>
  174 + </v-list-group>
  175 + <!--child item-->
  176 + <v-list-tile
  177 + v-else
  178 + :key="i"
  179 + :to="genChildTarget(item, subItem)"
  180 + :href="subItem.href"
  181 + :disabled="subItem.disabled"
  182 + :target="subItem.target"
  183 + ripple="ripple"
  184 + >
  185 + <v-list-tile-action v-if="subItem.action">
  186 + <img
  187 + width="30"
  188 + :src="subItem.action"
  189 + :class="[subItem.actionClass || 'success--text']"
  190 + />
  191 + </v-list-tile-action>
  192 + <v-list-tile-content>
  193 + <v-list-tile-title class="body-2">
  194 + <span>{{ subItem.title }}</span>
  195 + </v-list-tile-title>
  196 + </v-list-tile-content>
  197 + <!-- <v-circle class="white--text pa-0 circle-pill" v-if="subItem.badge" color="red" disabled="disabled">{{ subItem.badge }}</v-circle> -->
  198 + </v-list-tile>
  199 + </template>
  200 + </v-list-group>
  201 + <v-subheader v-else-if="item.header" :key="i">{{ item.header }}</v-subheader>
  202 + <v-divider v-else-if="item.divider" :key="i"></v-divider>
  203 + <!--top-level link-->
  204 + <v-list-tile
  205 + v-else
  206 + ripple="ripple"
  207 + :disabled="item.disabled"
  208 + :target="item.target"
  209 + rel="noopener"
  210 + :key="item.name"
  211 + :to="!item.href ? { name: item.name } : null"
  212 + :href="item.href"
  213 + >
  214 + <!-- <a :href="item.path"> -->
  215 + <v-list-tile-action v-if="item.icon">
  216 + <img :src="item.icon" width="22" alt="icons" />
  217 + </v-list-tile-action>
  218 + <v-list-tile-content class="pt-2">
  219 + <v-list-tile-title>{{ item.title }}</v-list-tile-title>
  220 + </v-list-tile-content>
  221 + <!-- <v-circle class="white--text pa-0 chip--x-small" v-if="item.badge" :color="item.color || 'primary'" disabled="disabled">{{ item.badge }}</v-circle> -->
  222 + <v-list-tile-action v-if="item.subAction">
  223 + <!-- <v-icon class="success--text">{{ item.subAction }}</v-icon> -->
  224 + <!-- <img :src="item.icon" width="40" alt="icons" /> -->
  225 + </v-list-tile-action>
  226 + <!-- <v-circle class="caption blue lighten-2 white--text mx-0" v-else-if="item.chip" label="label" small="small">{{ item.chip }}</v-circle> -->
  227 + <!-- </a> -->
  228 + </v-list-tile>
  229 + </template>
  230 + <template v-for="(item, i) in menuLibrarian" v-if="role === 'LIBRARIAN'">
  231 + <!-- {{menus}} -->
  232 + <!--group with subitems-->
  233 + <v-list-group
  234 + v-if="item.items"
  235 + :key="item.name"
  236 + :group="item.group"
  237 + no-action="no-action"
  238 + >
  239 + <v-list-tile slot="activator" ripple="ripple">
  240 + <v-list-tile-action v-if="item.icon">
  241 + <img :src="item.icon" width="22" alt="icons" />
  242 + </v-list-tile-action>
  243 + <v-list-tile-content>
  244 + <v-list-tile-title>{{ item.title }}</v-list-tile-title>
  245 + </v-list-tile-content>
  246 + </v-list-tile>
  247 + <template v-for="(subItem, i) in item.items">
  248 + <!--sub group-->
  249 + <v-list-group
  250 + v-if="subItem.items"
  251 + :key="subItem.name"
  252 + :group="subItem.group"
  253 + sub-group="sub-group"
  254 + >
  255 + <v-list-tile slot="activator" ripple="ripple">
  256 + <v-list-tile-content>
  257 + <v-list-tile-title>{{ subItem.title }}</v-list-tile-title>
  258 + </v-list-tile-content>
  259 + </v-list-tile>
  260 + <v-list-tile
  261 + v-for="(grand, i) in subItem.children"
  262 + :key="i"
  263 + :to="genChildTarget(item, grand)"
  264 + :href="grand.href"
  265 + ripple="ripple"
  266 + >
  267 + <v-list-tile-content>
  268 + <v-list-tile-title>{{ grand.title }}</v-list-tile-title>
  269 + </v-list-tile-content>
  270 + </v-list-tile>
  271 + </v-list-group>
  272 + <!--child item-->
  273 + <v-list-tile
  274 + v-else
  275 + :key="i"
  276 + :to="genChildTarget(item, subItem)"
  277 + :href="subItem.href"
  278 + :disabled="subItem.disabled"
  279 + :target="subItem.target"
  280 + ripple="ripple"
  281 + >
  282 + <v-list-tile-action v-if="subItem.action">
  283 + <img
  284 + width="30"
  285 + :src="subItem.action"
  286 + :class="[subItem.actionClass || 'success--text']"
  287 + />
  288 + </v-list-tile-action>
  289 + <v-list-tile-content>
  290 + <v-list-tile-title class="body-2">
  291 + <span>{{ subItem.title }}</span>
  292 + </v-list-tile-title>
  293 + </v-list-tile-content>
  294 + <!-- <v-circle class="white--text pa-0 circle-pill" v-if="subItem.badge" color="red" disabled="disabled">{{ subItem.badge }}</v-circle> -->
  295 + </v-list-tile>
  296 + </template>
  297 + </v-list-group>
  298 + <v-subheader v-else-if="item.header" :key="i">{{ item.header }}</v-subheader>
  299 + <v-divider v-else-if="item.divider" :key="i"></v-divider>
  300 + <!--top-level link-->
  301 + <v-list-tile
  302 + v-else
  303 + ripple="ripple"
  304 + :disabled="item.disabled"
  305 + :target="item.target"
  306 + rel="noopener"
  307 + :key="item.name"
  308 + :to="!item.href ? { name: item.name } : null"
  309 + :href="item.href"
  310 + >
  311 + <!-- <a :href="item.path"> -->
  312 + <v-list-tile-action v-if="item.icon">
  313 + <img :src="item.icon" width="22" alt="icons" />
  314 + </v-list-tile-action>
  315 + <v-list-tile-content class="pt-2">
  316 + <v-list-tile-title>{{ item.title }}</v-list-tile-title>
  317 + </v-list-tile-content>
  318 + <!-- <v-circle class="white--text pa-0 chip--x-small" v-if="item.badge" :color="item.color || 'primary'" disabled="disabled">{{ item.badge }}</v-circle> -->
  319 + <v-list-tile-action v-if="item.subAction">
  320 + <!-- <v-icon class="success--text">{{ item.subAction }}</v-icon> -->
  321 + <!-- <img :src="item.icon" width="40" alt="icons" /> -->
  322 + </v-list-tile-action>
  323 + <!-- <v-circle class="caption blue lighten-2 white--text mx-0" v-else-if="item.chip" label="label" small="small">{{ item.chip }}</v-circle> -->
  324 + <!-- </a> -->
  325 + </v-list-tile>
  326 + </template>
133 327 <template v-for="(item, i) in menuSchool" v-if="schoolRole === 'SUPERADMIN'">
134 328 <!-- {{menus}} -->
135 329 <!--group with subitems-->
... ... @@ -348,6 +542,8 @@ export default {
348 542 menus: [],
349 543 menuSchool: [],
350 544 menuTeacher: [],
  545 + menuAccount: [],
  546 + menuLibrarian: [],
351 547 schoolRole: "",
352 548 role: "",
353 549 scrollSettings: {
... ... @@ -372,6 +568,8 @@ export default {
372 568 this.menus = menu.adminMenu;
373 569 this.menuSchool = menu.schoolMenu;
374 570 this.menuTeacher = menu.teacherMenu;
  571 + this.menuAccount = menu.accountMenu;
  572 + this.menuLibrarian = menu.libraryMenu
375 573 // console.log("this.$route.name", this.$route.name);
376 574 // if (this.$route.name === "School") {
377 575 // localStorage.setItem("SchoolName", this.$route.name);
... ... @@ -424,7 +622,10 @@ export default {
424 622 this.token = this.$store.schoolToken;
425 623 } if (this.$store.state.role === "TEACHER") {
426 624 this.token = this.$store.state.token;
427   - // console.log("token",this.token);
  625 + }if (this.$store.state.role === "ACCOUNTANT") {
  626 + this.token = this.$store.state.token;
  627 + }if (this.$store.state.role === "LIBRARIAN") {
  628 + this.token = this.$store.state.token;
428 629 }
429 630 }
430 631 };
... ...
... ... @@ -31,6 +31,20 @@ export default [{
31 31 this.$store.dispatch('setSchoolToken', null)
32 32 this.$store.dispatch('setSchoolRole', null)
33 33 this.$router.replace({ path: '/' });
  34 + } else if (this.$store.state.role === "ACCOUNTANT") {
  35 + this.$store.dispatch('setToken', null)
  36 + this.$store.dispatch('Id', null)
  37 + this.$store.dispatch('Role', null)
  38 + this.$store.dispatch('setSchoolToken', null)
  39 + this.$store.dispatch('setSchoolRole', null)
  40 + this.$router.replace({ path: '/' });
  41 + } else if (this.$store.state.role === "LIBRARIAN") {
  42 + this.$store.dispatch('setToken', null)
  43 + this.$store.dispatch('Id', null)
  44 + this.$store.dispatch('Role', null)
  45 + this.$store.dispatch('setSchoolToken', null)
  46 + this.$store.dispatch('setSchoolRole', null)
  47 + this.$router.replace({ path: '/' });
34 48 }
35 49 }
36 50 },
... ...
src/pages/Account/feeTypes.vue
... ... @@ -421,6 +421,7 @@ export default {
421 421 this.text = response.data.message;
422 422 this.color = "green";
423 423 this.getFeeTypeList();
  424 + this.editFeeTypeDialog = false;
424 425 this.close();
425 426 })
426 427 .catch(error => {
... ...
src/pages/Account/paymentHistory.vue
1 1 <template>
2 2 <v-container fluid class="body-color">
3   - <!-- ****** PAYMENT HOISTORY TABLE ****** -->
  3 + <!-- ****** Edit Payment History ****** -->
  4 + <v-dialog v-model="editPaymentDialog" max-width="400px">
  5 + <v-card flat class="card-style pa-2" dark>
  6 + <v-layout>
  7 + <v-flex xs12>
  8 + <label class="title text-xs-center">Edit Payment History</label>
  9 + <v-icon size="24" class="right" @click="editPaymentDialog = false">cancel</v-icon>
  10 + </v-flex>
  11 + </v-layout>
  12 + <v-form ref="form">
  13 + <v-container fluid>
  14 + <v-flex xs12 sm12>
  15 + <v-layout>
  16 + <v-flex xs3 class="pt-4 subheading">
  17 + <label class="right">Amount:</label>
  18 + </v-flex>
  19 + <v-flex xs8 sm7 class="ml-3">
  20 + <v-text-field
  21 + v-model="editedItem.totalPaidAmount"
  22 + placeholder="please fill this field"
  23 + ></v-text-field>
  24 + </v-flex>
  25 + </v-layout>
  26 + </v-flex>
  27 + <v-flex xs12 sm12>
  28 + <v-layout>
  29 + <v-flex xs3 class="pt-4 subheading">
  30 + <label class="right">Method:</label>
  31 + </v-flex>
  32 + <v-flex xs8 sm7 class="ml-3">
  33 + <v-select
  34 + :items="paymentMethod"
  35 + v-model="editedItem.paymentMethod"
  36 + label="please fill this field"
  37 + required
  38 + ></v-select>
  39 + </v-flex>
  40 + </v-layout>
  41 + </v-flex>
  42 + <v-layout>
  43 + <v-flex xs12>
  44 + <v-layout>
  45 + <v-spacer></v-spacer>
  46 + <v-btn round dark @click="save" class="add-button">Update Payment History</v-btn>
  47 + <v-spacer></v-spacer>
  48 + </v-layout>
  49 + </v-flex>
  50 + </v-layout>
  51 + </v-container>
  52 + </v-form>
  53 + </v-card>
  54 + </v-dialog>
  55 +
  56 + <!-- ****** PAYMENT HISTORY TABLE ****** -->
4 57 <v-toolbar color="transparent" flat>
5 58 <v-spacer></v-spacer>
6 59 <v-card-title class="body-1" v-show="show">
... ... @@ -25,37 +78,37 @@
25 78 >
26 79 <template slot="items" slot-scope="props">
27 80 <tr class="tr">
28   - <td class="td td-row ">{{ props.index + 1 }}</td>
29   - <!-- <td class="td td-row text-xs-center">{{ props.item.studentId.name }}</td> -->
  81 + <td class="td td-row">{{ props.index + 1 }}</td>
  82 + <td class="td td-row text-xs-center">{{ props.item.studentId.name }}</td>
30 83 <td class="td td-row text-xs-center">{{ props.item.classId.classNum }}</td>
31   - <td class="td td-row text-xs-center">{{ props.item.feeType[0].feeTypeName }}</td>
  84 + <td class="td td-row text-xs-center">{{ props.item.feeType.feeTypeName }}</td>
32 85 <td class="td td-row text-xs-center">{{ props.item.paymentMethod }}</td>
33 86 <td class="td td-row text-xs-center">{{ props.item.totalPaidAmount }}</td>
34 87 <td class="td td-row text-xs-center">{{ dates(props.item.date) }}</td>
35   - <!-- <td class="text-xs-center">
36   - <span>
37   - <v-tooltip top>
38   - <img
39   - slot="activator"
40   - style="cursor:pointer; width:20px; height:18px; "
41   - class="mr-5"
42   - @click="editItem(props.item)"
43   - src="/static/icon/edit1.png"
44   - />
45   - <span>Edit</span>
46   - </v-tooltip>
47   - <v-tooltip top>
48   - <img
49   - slot="activator"
50   - style="cursor:pointer;width:20px; height:20px; "
51   - class="mr-5"
52   - @click="deleteItem(props.item)"
53   - src="/static/icon/delete1.png"
54   - />
55   - <span>Delete</span>
56   - </v-tooltip>
57   - </span>
58   - </td>-->
  88 + <td class="td td-row text-xs-center">
  89 + <span>
  90 + <v-tooltip top>
  91 + <img
  92 + slot="activator"
  93 + style="cursor:pointer; width:20px; height:18px; "
  94 + class="mr-5"
  95 + @click="editItem(props.item)"
  96 + src="/static/icon/edit1.png"
  97 + />
  98 + <span>Edit</span>
  99 + </v-tooltip>
  100 + <v-tooltip top>
  101 + <img
  102 + slot="activator"
  103 + style="cursor:pointer;width:20px; height:20px; "
  104 + class="mr-5"
  105 + @click="deleteItem(props.item)"
  106 + src="/static/icon/delete1.png"
  107 + />
  108 + <span>Delete</span>
  109 + </v-tooltip>
  110 + </span>
  111 + </td>
59 112 </tr>
60 113 </template>
61 114 <v-alert
... ... @@ -77,6 +130,7 @@ import moment from &quot;moment&quot;;
77 130  
78 131 export default {
79 132 data: () => ({
  133 + snackbar: false,
80 134 showLoader: false,
81 135 search: "",
82 136 show: true,
... ... @@ -84,6 +138,7 @@ export default {
84 138 pagination: {
85 139 rowsPerPage: 10
86 140 },
  141 + paymentMethod: ["Cash", "Cheque"],
87 142 headers: [
88 143 {
89 144 text: "No",
... ... @@ -91,12 +146,12 @@ export default {
91 146 sortable: false,
92 147 value: "No"
93 148 },
94   - // {
95   - // text: "Student",
96   - // value: "student",
97   - // sortable: false,
98   - // align: "center"
99   - // },
  149 + {
  150 + text: "Student",
  151 + value: "name",
  152 + sortable: false,
  153 + align: "center"
  154 + },
100 155 { text: "Class", value: "class", sortable: false, align: "center" },
101 156 {
102 157 text: "Fee Type",
... ... @@ -121,13 +176,51 @@ export default {
121 176 value: "date",
122 177 sortable: false,
123 178 align: "center"
124   - }
125   - // { text: "Action", value: "", sortable: false, align: "center" }
  179 + },
  180 + { text: "Action", value: "", sortable: false, align: "center" }
126 181 ],
127 182 paymentHistory: [],
128   - addPaymentHistoryDialog: ""
  183 + addPaymentHistoryDialog: "",
  184 + editPaymentDialog: false,
  185 + editedItem: {}
129 186 }),
130 187 methods: {
  188 + editItem(item) {
  189 + this.editedIndex = this.paymentHistory.indexOf(item);
  190 + this.editedItem = Object.assign({}, item);
  191 + this.editPaymentDialog = true;
  192 + },
  193 + deleteItem(item) {
  194 + let deleteGrade = {
  195 + invoiceId: item._id,
  196 + feeTypeId: item.feeType._id,
  197 + };
  198 + http()
  199 + .put(
  200 + "/deleteFeeType",
  201 + confirm("Are you sure you want to delete this?") &&
  202 + deleteGrade,
  203 + {
  204 + headers: {
  205 + Authorization: "Bearer " + this.token
  206 + }
  207 + }
  208 + )
  209 + .then(response => {
  210 + this.snackbar = true;
  211 + // this.text = "Successfully Delete Salary ";
  212 + this.text = response.data.message;
  213 + this.color = "green";
  214 + this.getPaymentHistory();
  215 + })
  216 + .catch(error => {
  217 + console.log("error", error);
  218 + this.snackbar = true;
  219 + this.text = error.response.data.message;
  220 + this.color = "red";
  221 + });
  222 + },
  223 +
131 224 dates: function(date) {
132 225 return moment(date).format("MMMM DD, YYYY");
133 226 },
... ... @@ -135,7 +228,7 @@ export default {
135 228 this.showLoader = true;
136 229 var token = this.$store.state.token;
137 230 http()
138   - .get("/getInvoicesList", {
  231 + .get("/getPaymentHistory", {
139 232 params: {
140 233 paymentStatus: "FULLY_PAID",
141 234 schoolId: this.$store.state.schoolId
... ... @@ -156,6 +249,32 @@ export default {
156 249 }
157 250 });
158 251 },
  252 + save() {
  253 + var updatePayment = {
  254 + invoiceId: this.editedItem._id,
  255 + feeTypeId: this.editedItem.feeType._id,
  256 + paidAmount: this.editedItem.totalPaidAmount,
  257 + paymentMethod: this.editedItem.paymentMethod
  258 + };
  259 + http()
  260 + .put("/updateFeeType", updatePayment, {
  261 + headers: {
  262 + Authorization: "Bearer " + this.token
  263 + }
  264 + })
  265 + .then(response => {
  266 + this.getPaymentHistory();
  267 + this.snackbar = true;
  268 + this.text = response.data.message;
  269 + this.color = "green";
  270 + this.editPaymentDialog = false;
  271 + })
  272 + .catch(error => {
  273 + console.log("error", error);
  274 + this.snackbar = true;
  275 + this.color = "red";
  276 + });
  277 + },
159 278 displaySearch() {
160 279 (this.show = false), (this.showSearch = true);
161 280 },
... ... @@ -164,31 +283,10 @@ export default {
164 283 this.show = true;
165 284 this.search = "";
166 285 }
167   - // getRole() {
168   - // this.showLoader = true;
169   - // var token = this.$store.state.token;
170   - // http()
171   - // .get("/getRolesList", {
172   - // headers: { Authorization: "Bearer " + token }
173   - // })
174   - // .then(response => {
175   - // this.userRole = response.data.data;
176   - // this.showLoader = false;
177   - // // console.log("UserList=====>",this.desserts)
178   - // })
179   - // .catch(error => {
180   - // this.showLoader = false;
181   - // if (error.response.status === 401) {
182   - // this.$router.replace({ path: "/" });
183   - // this.$store.dispatch("setToken", null);
184   - // this.$store.dispatch("Id", null);
185   - // }
186   - // });
187   - // }
188 286 },
189 287 mounted() {
  288 + this.token = this.$store.state.token;
190 289 this.getPaymentHistory();
191   - // this.getRole();
192 290 }
193 291 };
194 292 </script>
195 293 \ No newline at end of file
... ...
src/pages/Dashboard/dashboard.vue
... ... @@ -146,16 +146,16 @@
146 146 </v-flex>
147 147 <v-flex xs12 sm12 md9 lg9>
148 148 <div id="chart">
149   - <div v-if="this.series">
150   - <apexchart
151   - type="bar"
152   - height="250"
153   - style="max-width: 800px !important"
154   - :options="chartOptions"
155   - :series="series"
156   - v-show="true"
157   - ></apexchart>
158   - </div>
  149 + <div v-if="this.series">
  150 + <apexchart
  151 + type="bar"
  152 + height="250"
  153 + style="max-width: 800px !important"
  154 + :options="chartOptions"
  155 + :series="series"
  156 + v-show="true"
  157 + ></apexchart>
  158 + </div>
159 159 </div>
160 160 </v-flex>
161 161 </v-layout>
... ... @@ -448,6 +448,10 @@ export default {
448 448 this.token = this.$store.state.schoolToken;
449 449 } else if (this.$store.state.role === "TEACHER") {
450 450 this.token = this.$store.state.token;
  451 + } else if (this.$store.state.role === "ACCOUNTANT") {
  452 + this.token = this.$store.state.token;
  453 + } else if (this.$store.state.role === "LIBRARIAN") {
  454 + this.token = this.$store.state.token;
451 455 }
452 456 // console.log("role", this.$store.state.schoolRole,"tt",this.$store.state.schoolToken);
453 457 // this.getData();
... ...
src/pages/Report/studentReport.vue
... ... @@ -193,7 +193,11 @@
193 193 </v-layout>
194 194 <v-layout>
195 195 <v-flex xs12 sm12 md12 class="text-xs-center">
196   - <img :src="userData.schoolLogoUrl" width="140" alt="logo" />
  196 + <!-- <img :src="userData.schoolLogoUrl" width="140" alt="logo" /> -->
  197 + <v-avatar>
  198 + <img :src="userData.schoolLogoUrl" v-if="userData.schoolLogoUrl" />
  199 + <img src="/static/schoolIcons/INTRACK_White.png" v-else-if="!userData.schoolLogoUrl" />
  200 + </v-avatar>
197 201 <p class="title">{{ userData.name }}</p>
198 202 <p>{{ userData.address }}</p>
199 203 </v-flex>
... ...
src/router/paths.js
... ... @@ -340,6 +340,16 @@ export default [{
340 340 )
341 341 },
342 342 {
  343 + path: '/makePayment',
  344 + meta: {},
  345 + name: 'Make Payment',
  346 + props: (route) => ({ type: route.query.type }),
  347 + component: () =>
  348 + import (
  349 + `@/pages/Payroll/makePayment.vue`
  350 + )
  351 + },
  352 + {
343 353 path: '/AttendenceUser',
344 354 meta: {},
345 355 name: 'User Attendence',
... ... @@ -508,6 +518,18 @@ export default [{
508 518 )
509 519 },
510 520 {
  521 + path: '/viewPaymentInvoice/:viewPaymentInvoiceId',
  522 + meta: {},
  523 + name: 'View Payment Invoice',
  524 + props: (route) => ({ type: route.query.type }),
  525 + component: () =>
  526 + import (
  527 + /* webpackChunkName: "routes" */
  528 + /* webpackMode: "lazy-once" */
  529 + `@/pages/Account/viewPaymentInvoice.vue`
  530 + )
  531 + },
  532 + {
511 533 path: '/globalPayment',
512 534 meta: {},
513 535 name: 'Global Payment',
... ...