Browse Source

院区系统名称

seimin 1 year ago
parent
commit
f2e89fd8e3
3 changed files with 8 additions and 6 deletions
  1. 2 2
      package.json
  2. 5 3
      src/components/AppHeader.vue
  3. 1 1
      src/main.js

+ 2 - 2
package.json

@@ -3,8 +3,8 @@
3 3
   "version": "0.1.0",
4 4
   "private": true,
5 5
   "scripts": {
6
-    "start": "vue-cli-service serve",
7
-    "build": "vue-cli-service build",
6
+    "start": "set NODE_OPTIONS=--openssl-legacy-provider && vue-cli-service serve",
7
+    "build": "set NODE_OPTIONS=--openssl-legacy-provider && vue-cli-service build",
8 8
     "lint": "vue-cli-service lint",
9 9
     "development": "node ./upload/development.js",
10 10
     "production": "node ./upload/production.js"

+ 5 - 3
src/components/AppHeader.vue

@@ -70,8 +70,8 @@ export default {
70 70
         this.runTime()
71 71
       }, 500)
72 72
     },
73
-    getSysNameAndLogo () {
74
-      get('/auth/getSysNameAndLogo')
73
+    getSysNameAndLogo (hosId) {
74
+      get('/auth/getSysNameAndLogo' + (hosId ? '?hosId=' + hosId : ''))
75 75
         .then((result) => {
76 76
           this.logoTitle = result.largeScreenName || ''
77 77
           this.faviconUrl = location.origin + '/file' + result.favicon || ''
@@ -81,8 +81,10 @@ export default {
81 81
     }
82 82
   },
83 83
   mounted () {
84
+    const loginUser = JSON.parse(localStorage.getItem('user'))
85
+    const hosId = loginUser.user.currentHospital ? loginUser.user.currentHospital.id : ''
84 86
     this.runTime()
85
-    this.getSysNameAndLogo()
87
+    this.getSysNameAndLogo(hosId)
86 88
   },
87 89
   beforeDestroy () {
88 90
     clearTimeout(this.timer)

+ 1 - 1
src/main.js

@@ -14,7 +14,7 @@ Vue.use(fullScreenContainer)
14 14
 Vue.prototype.$moment = moment
15 15
 
16 16
 Vue.config.productionTip = false
17
-console.info('v2.4.6')
17
+console.info('v2.4.7')
18 18
 
19 19
 new Vue({
20 20
   router,