From 25205ccca8eb128374c75d99af940c04acf5ab0c Mon Sep 17 00:00:00 2001 From: shikha Date: Wed, 12 Feb 2020 16:33:38 +0530 Subject: [PATCH] show school logo and name modification in some pages and done task of global payment --- src/Services/http.js | 11 +- src/components/pageHeader/AppToolbar.vue | 6 +- src/pages/Account/globalPayment.vue | 103 +++++++----- src/pages/Account/invoice.vue | 15 +- src/pages/Account/viewInvoice.vue | 270 ++++++++++++++++++------------- src/pages/Dashboard/dashboard.vue | 34 +++- src/pages/Mark/viewMark.vue | 50 +++--- src/pages/Report/progressCardReport.vue | 80 ++++----- src/pages/Report/studentReport.vue | 18 ++- src/pages/School/school.vue | 2 +- 10 files changed, 320 insertions(+), 269 deletions(-) diff --git a/src/Services/http.js b/src/Services/http.js index 75e8168..d383d1f 100644 --- a/src/Services/http.js +++ b/src/Services/http.js @@ -4,13 +4,18 @@ import store from '@/store/store' const baseDomain = "http://15.206.52.174:8001/v1"; const baseURL = `${baseDomain}`; - +var token = "" +if (store.state.role === "ADMIN") { + token = `${store.state.token}` +} else if (store.state.schoolRole === "SUPERADMIN") { + token = `${store.state.schoolToken}` +} export default () => { return axios.create({ - // baseURL: 'http://192.168.0.105:3002/v1', + // baseURL: 'http://192.168.0.127:3002/v1', baseURL, headers: { - Authorization: `Bearer ${store.state.token}` + Authorization: `Bearer ${token}` } }) } \ No newline at end of file diff --git a/src/components/pageHeader/AppToolbar.vue b/src/components/pageHeader/AppToolbar.vue index 6b07487..0176108 100644 --- a/src/components/pageHeader/AppToolbar.vue +++ b/src/components/pageHeader/AppToolbar.vue @@ -106,7 +106,11 @@ export default { }, getUserData() { http() - .get("/getParticularUserDetail") + .get("/getParticularUserDetail", { + headers: { + Authorization: "Bearer " + this.$store.state.token + } + }) .then(response => { this.userData = response.data.data; }) diff --git a/src/pages/Account/globalPayment.vue b/src/pages/Account/globalPayment.vue index 31ad73a..cb28f8a 100644 --- a/src/pages/Account/globalPayment.vue +++ b/src/pages/Account/globalPayment.vue @@ -94,10 +94,7 @@ style="margin: auto;display:block;margin-bottom:10px !important" > - + @@ -134,7 +131,7 @@ - + - + - - + + -