Bläddra i källkod

Merge branch 'master' of http://git.shengws.com/csx/Vue_New

See999 5 år sedan
förälder
incheckning
062f9d52f0
32 ändrade filer med 3840 tillägg och 1975 borttagningar
  1. 4 4
      config/dev.env.js
  2. 1 1
      config/index.js
  3. 42 23
      package-lock.json
  4. 1 1
      package.json
  5. 14 2
      src/App.vue
  6. 41 22
      src/api/advice.js
  7. 3 4
      src/api/manage.js
  8. 12 0
      src/api/role/role.js
  9. 18 16
      src/router/modules/dialysis.js
  10. 2074 532
      src/store/modules/globalConfig.js
  11. 39 44
      src/store/modules/xt_user.js
  12. 32 7
      src/views/layout/components/Navbar.vue
  13. 1 1
      src/xt_pages/data/components/tableson.vue
  14. 395 398
      src/xt_pages/dialysis/details/assessmentBefore.vue
  15. 657 498
      src/xt_pages/dialysis/details/dialog/AssessmentAfterDislysis.vue
  16. 35 22
      src/xt_pages/dialysis/details/dialog/DoctorAdviceDialog.vue
  17. 3 1
      src/xt_pages/dialysis/details/dialog/adviceDialog/AddGroupAdvice.vue
  18. 23 6
      src/xt_pages/dialysis/details/dialog/adviceDialog/EditGroupAdvice.vue
  19. 52 39
      src/xt_pages/dialysis/details/dialog/assessmentBeforeDislysisDialog.vue
  20. 35 78
      src/xt_pages/dialysis/details/dialog/dialysisPrescriptionDialog.vue
  21. 5 0
      src/xt_pages/dialysis/details/dialog/monitor_dialog.vue
  22. 12 15
      src/xt_pages/management/components/MultipleForm.vue
  23. 20 23
      src/xt_pages/management/components/UserForm.vue
  24. 14 11
      src/xt_pages/management/home.vue
  25. 0 1
      src/xt_pages/role/admin.vue
  26. 16 17
      src/xt_pages/role/components/AdminInfoForm.vue
  27. 2 2
      src/xt_pages/role/components/AdminRoleInfoForm.vue
  28. 60 14
      src/xt_pages/role/components/EditRole.vue
  29. 44 4
      src/xt_pages/role/components/UserManagement.vue
  30. 1 1
      src/xt_pages/sign/index.vue
  31. 161 172
      src/xt_pages/user/dialysisSolution.vue
  32. 23 16
      src/xt_permission.js

+ 4 - 4
config/dev.env.js Visa fil

6
 module.exports = {
6
 module.exports = {
7
   NODE_ENV: '"development"',
7
   NODE_ENV: '"development"',
8
   ENV_CONFIG: '"dev"',
8
   ENV_CONFIG: '"dev"',
9
-  BASE_API:  '"http://new_mobile.xt.api.sgjyun.com"',// //http://api.xt.test.sgjyun.com http://112.74.16.180:9527,////'"http://localhost:9529"',
10
-  // BASE_API:'"http://localhost:9531"',
9
+  BASE_API: '"http://api.xt.test.sgjyun.com"', // //http://api.xt.test.sgjyun.com http://112.74.16.180:9527,////'"http://localhost:9529"',
10
+  //BASE_API:'"http://localhost:9529"',
11
   SSO_HOST: '"http://testsso.sgjyun.com"',
11
   SSO_HOST: '"http://testsso.sgjyun.com"',
12
   SRCM_HOST: '"http://test1.sgjyun.com"',
12
   SRCM_HOST: '"http://test1.sgjyun.com"',
13
   XT_HOST: '"http://xt.test.sgjyun.com"',
13
   XT_HOST: '"http://xt.test.sgjyun.com"',
14
   MIRCO_MALL_HOST: '"http://mall.test.sgjyun.com"',
14
   MIRCO_MALL_HOST: '"http://mall.test.sgjyun.com"',
15
-  CDM_HOST: '"http://cdm.test.sgjyun.com"',
16
-}
15
+  CDM_HOST: '"http://cdm.test.sgjyun.com"'
16
+};

+ 1 - 1
config/index.js Visa fil

20
     // host: 'xt.test.sgjyun.com',
20
     // host: 'xt.test.sgjyun.com',
21
     // host: 'xt.kuyicloud.com',
21
     // host: 'xt.kuyicloud.com',
22
     host: 'xt.test.sgjyun.com',
22
     host: 'xt.test.sgjyun.com',
23
-    // host:'localhost',
23
+    //host:'localhost',
24
     port: 9528, // can be overwritten by process.env.PORT, if port is in use, a free one will be determined
24
     port: 9528, // can be overwritten by process.env.PORT, if port is in use, a free one will be determined
25
     autoOpenBrowser: true,
25
     autoOpenBrowser: true,
26
     errorOverlay: true,
26
     errorOverlay: true,

+ 42 - 23
package-lock.json Visa fil

477
     },
477
     },
478
     "async-validator": {
478
     "async-validator": {
479
       "version": "1.8.5",
479
       "version": "1.8.5",
480
-      "resolved": "https://registry.npm.taobao.org/async-validator/download/async-validator-1.8.5.tgz",
481
-      "integrity": "sha1-3D4I7B/Q3dtn5ghC8CwM0c7G1/A=",
480
+      "resolved": "https://registry.npmjs.org/async-validator/-/async-validator-1.8.5.tgz",
481
+      "integrity": "sha512-tXBM+1m056MAX0E8TL2iCjg8WvSyXu0Zc8LNtYqrVeyoL3+esHRZ4SieE9fKQyyU09uONjnMEjrNBMqT0mbvmA==",
482
       "requires": {
482
       "requires": {
483
         "babel-runtime": "6.x"
483
         "babel-runtime": "6.x"
484
       }
484
       }
3187
     },
3187
     },
3188
     "deepmerge": {
3188
     "deepmerge": {
3189
       "version": "1.5.2",
3189
       "version": "1.5.2",
3190
-      "resolved": "https://registry.npm.taobao.org/deepmerge/download/deepmerge-1.5.2.tgz",
3191
-      "integrity": "sha1-EEmdhohEza1P7ghC34x/bwyVp1M="
3190
+      "resolved": "https://registry.npmjs.org/deepmerge/-/deepmerge-1.5.2.tgz",
3191
+      "integrity": "sha512-95k0GDqvBjZavkuvzx/YqVLv/6YYa17fz6ILMSf7neqQITCPbnfEnQvEgMPNjH4kgobe7+WIL0yJEHku+H3qtQ=="
3192
     },
3192
     },
3193
     "define-properties": {
3193
     "define-properties": {
3194
       "version": "1.1.3",
3194
       "version": "1.1.3",
3515
       "dev": true
3515
       "dev": true
3516
     },
3516
     },
3517
     "element-ui": {
3517
     "element-ui": {
3518
-      "version": "2.12.0",
3519
-      "resolved": "https://registry.npm.taobao.org/element-ui/download/element-ui-2.12.0.tgz",
3520
-      "integrity": "sha1-qJO8Ea5Pfbt+nVQWBvI+ZD8THuQ=",
3518
+      "version": "2.13.0",
3519
+      "resolved": "https://registry.npmjs.org/element-ui/-/element-ui-2.13.0.tgz",
3520
+      "integrity": "sha512-KYsHWsBXYbLELS8cdfvgJTOMSUby3UEjvsPV1V1VmgJ/DdkOAS4z3MiOrPxrT9w2Cc5lZ4eVSQiGhYFR5NVChw==",
3521
       "requires": {
3521
       "requires": {
3522
         "async-validator": "~1.8.1",
3522
         "async-validator": "~1.8.1",
3523
         "babel-helper-vue-jsx-merge-props": "^2.0.0",
3523
         "babel-helper-vue-jsx-merge-props": "^2.0.0",
4740
         "ansi-regex": {
4740
         "ansi-regex": {
4741
           "version": "2.1.1",
4741
           "version": "2.1.1",
4742
           "bundled": true,
4742
           "bundled": true,
4743
-          "dev": true
4743
+          "dev": true,
4744
+          "optional": true
4744
         },
4745
         },
4745
         "aproba": {
4746
         "aproba": {
4746
           "version": "1.2.0",
4747
           "version": "1.2.0",
4763
         "balanced-match": {
4764
         "balanced-match": {
4764
           "version": "1.0.0",
4765
           "version": "1.0.0",
4765
           "bundled": true,
4766
           "bundled": true,
4766
-          "dev": true
4767
+          "dev": true,
4768
+          "optional": true
4767
         },
4769
         },
4768
         "brace-expansion": {
4770
         "brace-expansion": {
4769
           "version": "1.1.11",
4771
           "version": "1.1.11",
4770
           "resolved": false,
4772
           "resolved": false,
4771
           "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==",
4773
           "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==",
4772
           "dev": true,
4774
           "dev": true,
4775
+          "optional": true,
4773
           "requires": {
4776
           "requires": {
4774
             "balanced-match": "^1.0.0",
4777
             "balanced-match": "^1.0.0",
4775
             "concat-map": "0.0.1"
4778
             "concat-map": "0.0.1"
4785
         "code-point-at": {
4788
         "code-point-at": {
4786
           "version": "1.1.0",
4789
           "version": "1.1.0",
4787
           "bundled": true,
4790
           "bundled": true,
4788
-          "dev": true
4791
+          "dev": true,
4792
+          "optional": true
4789
         },
4793
         },
4790
         "concat-map": {
4794
         "concat-map": {
4791
           "version": "0.0.1",
4795
           "version": "0.0.1",
4792
           "resolved": false,
4796
           "resolved": false,
4793
           "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=",
4797
           "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=",
4794
-          "dev": true
4798
+          "dev": true,
4799
+          "optional": true
4795
         },
4800
         },
4796
         "console-control-strings": {
4801
         "console-control-strings": {
4797
           "version": "1.1.0",
4802
           "version": "1.1.0",
4798
           "resolved": false,
4803
           "resolved": false,
4799
           "integrity": "sha1-PXz0Rk22RG6mRL9LOVB/mFEAjo4=",
4804
           "integrity": "sha1-PXz0Rk22RG6mRL9LOVB/mFEAjo4=",
4800
-          "dev": true
4805
+          "dev": true,
4806
+          "optional": true
4801
         },
4807
         },
4802
         "core-util-is": {
4808
         "core-util-is": {
4803
           "version": "1.0.2",
4809
           "version": "1.0.2",
4927
         "inherits": {
4933
         "inherits": {
4928
           "version": "2.0.3",
4934
           "version": "2.0.3",
4929
           "bundled": true,
4935
           "bundled": true,
4930
-          "dev": true
4936
+          "dev": true,
4937
+          "optional": true
4931
         },
4938
         },
4932
         "ini": {
4939
         "ini": {
4933
           "version": "1.3.5",
4940
           "version": "1.3.5",
4941
           "resolved": false,
4948
           "resolved": false,
4942
           "integrity": "sha1-754xOG8DGn8NZDr4L95QxFfvAMs=",
4949
           "integrity": "sha1-754xOG8DGn8NZDr4L95QxFfvAMs=",
4943
           "dev": true,
4950
           "dev": true,
4951
+          "optional": true,
4944
           "requires": {
4952
           "requires": {
4945
             "number-is-nan": "^1.0.0"
4953
             "number-is-nan": "^1.0.0"
4946
           }
4954
           }
4957
           "resolved": false,
4965
           "resolved": false,
4958
           "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==",
4966
           "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==",
4959
           "dev": true,
4967
           "dev": true,
4968
+          "optional": true,
4960
           "requires": {
4969
           "requires": {
4961
             "brace-expansion": "^1.1.7"
4970
             "brace-expansion": "^1.1.7"
4962
           }
4971
           }
4964
         "minimist": {
4973
         "minimist": {
4965
           "version": "0.0.8",
4974
           "version": "0.0.8",
4966
           "bundled": true,
4975
           "bundled": true,
4967
-          "dev": true
4976
+          "dev": true,
4977
+          "optional": true
4968
         },
4978
         },
4969
         "minipass": {
4979
         "minipass": {
4970
           "version": "2.3.5",
4980
           "version": "2.3.5",
4971
           "resolved": false,
4981
           "resolved": false,
4972
           "integrity": "sha512-Gi1W4k059gyRbyVUZQ4mEqLm0YIUiGYfvxhF6SIlk3ui1WVxMTGfGdQ2SInh3PDrRTVvPKgULkpJtT4RH10+VA==",
4982
           "integrity": "sha512-Gi1W4k059gyRbyVUZQ4mEqLm0YIUiGYfvxhF6SIlk3ui1WVxMTGfGdQ2SInh3PDrRTVvPKgULkpJtT4RH10+VA==",
4973
           "dev": true,
4983
           "dev": true,
4984
+          "optional": true,
4974
           "requires": {
4985
           "requires": {
4975
             "safe-buffer": "^5.1.2",
4986
             "safe-buffer": "^5.1.2",
4976
             "yallist": "^3.0.0"
4987
             "yallist": "^3.0.0"
4991
           "resolved": false,
5002
           "resolved": false,
4992
           "integrity": "sha1-MAV0OOrGz3+MR2fzhkjWaX11yQM=",
5003
           "integrity": "sha1-MAV0OOrGz3+MR2fzhkjWaX11yQM=",
4993
           "dev": true,
5004
           "dev": true,
5005
+          "optional": true,
4994
           "requires": {
5006
           "requires": {
4995
             "minimist": "0.0.8"
5007
             "minimist": "0.0.8"
4996
           }
5008
           }
5078
         "number-is-nan": {
5090
         "number-is-nan": {
5079
           "version": "1.0.1",
5091
           "version": "1.0.1",
5080
           "bundled": true,
5092
           "bundled": true,
5081
-          "dev": true
5093
+          "dev": true,
5094
+          "optional": true
5082
         },
5095
         },
5083
         "object-assign": {
5096
         "object-assign": {
5084
           "version": "4.1.1",
5097
           "version": "4.1.1",
5092
           "resolved": false,
5105
           "resolved": false,
5093
           "integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=",
5106
           "integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=",
5094
           "dev": true,
5107
           "dev": true,
5108
+          "optional": true,
5095
           "requires": {
5109
           "requires": {
5096
             "wrappy": "1"
5110
             "wrappy": "1"
5097
           }
5111
           }
5186
         "safe-buffer": {
5200
         "safe-buffer": {
5187
           "version": "5.1.2",
5201
           "version": "5.1.2",
5188
           "bundled": true,
5202
           "bundled": true,
5189
-          "dev": true
5203
+          "dev": true,
5204
+          "optional": true
5190
         },
5205
         },
5191
         "safer-buffer": {
5206
         "safer-buffer": {
5192
           "version": "2.1.2",
5207
           "version": "2.1.2",
5228
           "resolved": false,
5243
           "resolved": false,
5229
           "integrity": "sha1-EYvfW4zcUaKn5w0hHgfisLmxB9M=",
5244
           "integrity": "sha1-EYvfW4zcUaKn5w0hHgfisLmxB9M=",
5230
           "dev": true,
5245
           "dev": true,
5246
+          "optional": true,
5231
           "requires": {
5247
           "requires": {
5232
             "code-point-at": "^1.0.0",
5248
             "code-point-at": "^1.0.0",
5233
             "is-fullwidth-code-point": "^1.0.0",
5249
             "is-fullwidth-code-point": "^1.0.0",
5249
           "resolved": false,
5265
           "resolved": false,
5250
           "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=",
5266
           "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=",
5251
           "dev": true,
5267
           "dev": true,
5268
+          "optional": true,
5252
           "requires": {
5269
           "requires": {
5253
             "ansi-regex": "^2.0.0"
5270
             "ansi-regex": "^2.0.0"
5254
           }
5271
           }
5296
         "wrappy": {
5313
         "wrappy": {
5297
           "version": "1.0.2",
5314
           "version": "1.0.2",
5298
           "bundled": true,
5315
           "bundled": true,
5299
-          "dev": true
5316
+          "dev": true,
5317
+          "optional": true
5300
         },
5318
         },
5301
         "yallist": {
5319
         "yallist": {
5302
           "version": "3.0.3",
5320
           "version": "3.0.3",
5303
           "resolved": false,
5321
           "resolved": false,
5304
           "integrity": "sha512-S+Zk8DEWE6oKpV+vI3qWkaK+jSbIK86pCwe2IF/xwIpQ8jEuxpw9NyaGjmp9+BoJv5FV2piqCDcoCtStppiq2A==",
5322
           "integrity": "sha512-S+Zk8DEWE6oKpV+vI3qWkaK+jSbIK86pCwe2IF/xwIpQ8jEuxpw9NyaGjmp9+BoJv5FV2piqCDcoCtStppiq2A==",
5305
-          "dev": true
5323
+          "dev": true,
5324
+          "optional": true
5306
         }
5325
         }
5307
       }
5326
       }
5308
     },
5327
     },
7924
     },
7943
     },
7925
     "normalize-wheel": {
7944
     "normalize-wheel": {
7926
       "version": "1.0.1",
7945
       "version": "1.0.1",
7927
-      "resolved": "http://registry.npm.taobao.org/normalize-wheel/download/normalize-wheel-1.0.1.tgz",
7946
+      "resolved": "https://registry.npmjs.org/normalize-wheel/-/normalize-wheel-1.0.1.tgz",
7928
       "integrity": "sha1-rsiGr/2wRQcNhWRH32Ls+GFG7EU="
7947
       "integrity": "sha1-rsiGr/2wRQcNhWRH32Ls+GFG7EU="
7929
     },
7948
     },
7930
     "normalize.css": {
7949
     "normalize.css": {
11881
     },
11900
     },
11882
     "resize-observer-polyfill": {
11901
     "resize-observer-polyfill": {
11883
       "version": "1.5.1",
11902
       "version": "1.5.1",
11884
-      "resolved": "http://registry.npm.taobao.org/resize-observer-polyfill/download/resize-observer-polyfill-1.5.1.tgz",
11885
-      "integrity": "sha1-DpAg3T0hAkRY1OvSfiPkAmmBBGQ="
11903
+      "resolved": "https://registry.npmjs.org/resize-observer-polyfill/-/resize-observer-polyfill-1.5.1.tgz",
11904
+      "integrity": "sha512-LwZrotdHOo12nQuZlHEmtuXdqGoOD0OhaxopaNFxWzInpEgaLWoVuAMbTzixuosCx2nEG58ngzW3vxdWoxIgdg=="
11886
     },
11905
     },
11887
     "resolve": {
11906
     "resolve": {
11888
       "version": "1.10.0",
11907
       "version": "1.10.0",
13537
     },
13556
     },
13538
     "throttle-debounce": {
13557
     "throttle-debounce": {
13539
       "version": "1.1.0",
13558
       "version": "1.1.0",
13540
-      "resolved": "http://registry.npm.taobao.org/throttle-debounce/download/throttle-debounce-1.1.0.tgz",
13541
-      "integrity": "sha1-UYU9o3vmihVctugns1FKPEIuic0="
13559
+      "resolved": "https://registry.npmjs.org/throttle-debounce/-/throttle-debounce-1.1.0.tgz",
13560
+      "integrity": "sha512-XH8UiPCQcWNuk2LYePibW/4qL97+ZQ1AN3FNXwZRBNPPowo/NRU5fAlDCSNBJIYCKbioZfuYtMhG4quqoJhVzg=="
13542
     },
13561
     },
13543
     "through": {
13562
     "through": {
13544
       "version": "2.3.8",
13563
       "version": "2.3.8",

+ 1 - 1
package.json Visa fil

46
     "driver.js": "0.5.2",
46
     "driver.js": "0.5.2",
47
     "dropzone": "5.2.0",
47
     "dropzone": "5.2.0",
48
     "echarts": "3.8.5",
48
     "echarts": "3.8.5",
49
-    "element-ui": "^2.12.0",
49
+    "element-ui": "^2.13.0",
50
     "file-saver": "1.3.3",
50
     "file-saver": "1.3.3",
51
     "font-awesome": "4.7.0",
51
     "font-awesome": "4.7.0",
52
     "js-cookie": "2.2.0",
52
     "js-cookie": "2.2.0",

+ 14 - 2
src/App.vue Visa fil

1
 <template>
1
 <template>
2
   <div id="app">
2
   <div id="app">
3
-    <router-view></router-view>
3
+    <router-view  v-if="isRouterAlive"></router-view>
4
   </div>
4
   </div>
5
 </template>
5
 </template>
6
 
6
 
7
 <script>
7
 <script>
8
 export default {
8
 export default {
9
-  name: "App"
9
+  name: "App",
10
+  data () {
11
+    return {
12
+      isRouterAlive: true
13
+    }
14
+  }, methods: {
15
+    reload () {
16
+      this.isRouterAlive = false
17
+      this.$nextTick(function () {
18
+        this.isRouterAlive = true
19
+      })
20
+    }
21
+  }
10
 };
22
 };
11
 </script>
23
 </script>
12
 
24
 

+ 41 - 22
src/api/advice.js Visa fil

14
   })
14
   })
15
 }
15
 }
16
 
16
 
17
-export function CreateDoctorAdvice(id, advice) {
17
+export function CreateDoctorAdvice(id, advice,mode) {
18
   return request({
18
   return request({
19
-    url: '/api/patients/advice/create?id=' + id,
19
+    url: '/api/patients/advice/create?id=' + id+"&mode="+mode,
20
     method: 'post',
20
     method: 'post',
21
-    data: advice
21
+    data: advice,
22
+    headers:{"Permission":3},
23
+
22
   })
24
   })
23
 }
25
 }
24
 
26
 
25
-export function EditDoctorAdvice(patient, id, advice) {
27
+export function EditDoctorAdvice(patient, id, advice,mode) {
26
   return request({
28
   return request({
27
-    url: '/api/patients/advice/edit?id=' + id + '&patient=' + patient,
29
+    url: '/api/patients/advice/edit?id=' + id + '&patient=' + patient+"&mode="+mode,
28
     method: 'Put',
30
     method: 'Put',
29
-    data: advice
31
+    data: advice,
32
+    headers:{"Permission":2},
33
+
30
   })
34
   })
31
 }
35
 }
32
 
36
 
40
   return request({
44
   return request({
41
     url: '/api/patients/advice/exec',
45
     url: '/api/patients/advice/exec',
42
     method: 'Post',
46
     method: 'Post',
43
-    params: params
47
+    params: params,
48
+    headers:{"Permission":2},
49
+
44
   })
50
   })
45
 }
51
 }
46
 export function CheckDoctorAdvice(patient, id,mode) {
52
 export function CheckDoctorAdvice(patient, id,mode) {
53
   return request({
59
   return request({
54
     url: '/api/patients/advice/check',
60
     url: '/api/patients/advice/check',
55
     method: 'Post',
61
     method: 'Post',
56
-    params: params
62
+    params: params,
63
+    headers:{"Permission":2},
64
+
57
   })
65
   })
58
 }
66
 }
59
-export function CheckGroupAdvice(groupno) {
67
+export function CheckGroupAdvice(groupno,mode) {
60
   var params = {
68
   var params = {
61
-    groupno: groupno
69
+    groupno: groupno,
70
+    mode: mode,
62
   }
71
   }
63
   return request({
72
   return request({
64
     url: '/api/patients/advice/checkgroup',
73
     url: '/api/patients/advice/checkgroup',
65
     method: 'Post',
74
     method: 'Post',
66
-    params: params
75
+    params: params,
76
+    headers:{"Permission":2},
77
+
67
   })
78
   })
68
 }
79
 }
69
 
80
 
98
   })
109
   })
99
 }
110
 }
100
 
111
 
101
-export function DeleteDoctorAdvice(id) {
112
+export function DeleteDoctorAdvice(id,mode) {
102
   return request({
113
   return request({
103
-    url: '/api/patients/advice/delete?id=' + id,
104
-    method: 'Delete'
114
+    url: '/api/patients/advice/delete?id=' + id+"&mode="+mode,
115
+    method: 'Delete',
116
+    headers:{"Permission":2},
117
+
105
   })
118
   })
106
 }
119
 }
107
 
120
 
199
   })
212
   })
200
 }
213
 }
201
 
214
 
202
-export function CreateGroupAdvice(id, groupno, advices) {
215
+export function CreateGroupAdvice(id, groupno, advices,mode) {
203
   if (advices.remind > 0) {
216
   if (advices.remind > 0) {
204
     return request({
217
     return request({
205
-      url: '/api/patients/advice/creategroup?id=' + id + '&groupno=' + groupno,
218
+      url: '/api/patients/advice/creategroup?id=' + id + '&groupno=' + groupno+"&mode="+mode,
206
       method: 'post',
219
       method: 'post',
207
-      data: advices
220
+      data: advices,
221
+      headers:{"Permission":2},
222
+
208
     })
223
     })
209
   } else {
224
   } else {
210
     return request({
225
     return request({
211
-      url: '/api/patients/advice/creategroup?id=' + id + '&groupno=' + groupno,
226
+      url: '/api/patients/advice/creategroup?id=' + id + '&groupno=' + groupno+"&mode="+mode,
212
       method: 'post',
227
       method: 'post',
213
-      data: advices
228
+      data: advices,
229
+      headers:{"Permission":2},
230
+
214
     })
231
     })
215
   }
232
   }
216
 }
233
 }
217
-export function DeleteGroupAdvice(groupno) {
234
+export function DeleteGroupAdvice(groupno,mode) {
218
   return request({
235
   return request({
219
-    url: '/api/patients/advice/deletegroup?groupno=' + groupno,
220
-    method: 'delete'
236
+    url: '/api/patients/advice/deletegroup?groupno=' + groupno+"&mode="+mode,
237
+    method: 'delete',
238
+    headers:{"Permission":3},
239
+
221
   })
240
   })
222
 }
241
 }
223
 
242
 

+ 3 - 4
src/api/manage.js Visa fil

150
 }
150
 }
151
 
151
 
152
 export function UpdatePlanInfo(data) {
152
 export function UpdatePlanInfo(data) {
153
+  console.log('data', data)
153
   return request({
154
   return request({
154
     url: '/api/manage/updateplaninfo',
155
     url: '/api/manage/updateplaninfo',
155
     method: 'Post',
156
     method: 'Post',
451
 }
452
 }
452
 
453
 
453
 export function queryInfo(zone, bed, startime, endtime, limit, page) {
454
 export function queryInfo(zone, bed, startime, endtime, limit, page) {
454
-  console.log('开始时间', startime)
455
-  console.log('结束时间', endtime)
456
-  console.log('床位好', bed)
457
   const params = {
455
   const params = {
458
     zone: zone,
456
     zone: zone,
459
     bed: bed,
457
     bed: bed,
462
     limit: limit,
460
     limit: limit,
463
     page: page
461
     page: page
464
   }
462
   }
463
+  console.log('params', params)
465
   return request({
464
   return request({
466
     url: '/api/manage/queryinfo',
465
     url: '/api/manage/queryinfo',
467
     method: 'Get',
466
     method: 'Get',
486
 }
485
 }
487
 
486
 
488
 export function getUserForm(id, limit, page) {
487
 export function getUserForm(id, limit, page) {
489
-  console.log('limit', limit)
490
   const params = {
488
   const params = {
491
     id: id,
489
     id: id,
492
     limit: limit,
490
     limit: limit,
508
 }
506
 }
509
 
507
 
510
 export function getBedForm(id, params) {
508
 export function getBedForm(id, params) {
509
+  console.log('设备-id', id)
511
   return request({
510
   return request({
512
     url: '/api/manage/getbedform?id=' + id,
511
     url: '/api/manage/getbedform?id=' + id,
513
     method: 'get',
512
     method: 'get',

+ 12 - 0
src/api/role/role.js Visa fil

101
   })
101
   })
102
 }
102
 }
103
 
103
 
104
+
105
+
106
+export function getRoleInfo(params) {
107
+  return request({
108
+    url: '/api/role',
109
+    method: 'get',
110
+    params:params
111
+  })
112
+}
113
+
114
+
115
+

+ 18 - 16
src/router/modules/dialysis.js Visa fil

18
         title: '透析记录'
18
         title: '透析记录'
19
       }
19
       }
20
     },
20
     },
21
+    {
22
+      path: '/dialysis/watch',
23
+      component: () => import('@/xt_pages/dialysis/bloodPresssWatch'),
24
+      name: 'watch',
25
+      meta: {
26
+        title: 'watch'
27
+      }
28
+    },
29
+    {
30
+      path: '/dialysis/board',
31
+      component: () => import('@/xt_pages/dialysis/bulletinBoard'),
32
+      name: '数据看板',
33
+      meta: {
34
+        title: '数据看板'
35
+      }
36
+    },
21
     {
37
     {
22
       path: '/dialysis/record/:id',
38
       path: '/dialysis/record/:id',
23
       component: () => import('@/xt_pages/dialysis/dialysisPage'),
39
       component: () => import('@/xt_pages/dialysis/dialysisPage'),
43
 
59
 
44
     // { path: 'advice', component: () => import('@/xt_pages/dialysis/doctorAdvice'), name: 'advice', meta: { title: 'advice' }},
60
     // { path: 'advice', component: () => import('@/xt_pages/dialysis/doctorAdvice'), name: 'advice', meta: { title: 'advice' }},
45
     // { path: 'prepare', component: () => import('@/xt_pages/dialysis/dialysisPrepare'), name: 'prepare', meta: { title: 'prepare' }},
61
     // { path: 'prepare', component: () => import('@/xt_pages/dialysis/dialysisPrepare'), name: 'prepare', meta: { title: 'prepare' }},
46
-    {
47
-      path: '/dialysis/watch',
48
-      component: () => import('@/xt_pages/dialysis/bloodPresssWatch'),
49
-      name: 'watch',
50
-      meta: {
51
-        title: 'watch'
52
-      }
53
-    },
62
+
54
     {
63
     {
55
       path: '/dialysis/details',
64
       path: '/dialysis/details',
56
       component: () => import('@/xt_pages/dialysis/details'),
65
       component: () => import('@/xt_pages/dialysis/details'),
189
         noCache: true
198
         noCache: true
190
       }
199
       }
191
     },
200
     },
192
-    {
193
-      path: '/dialysis/board',
194
-      component: () => import('@/xt_pages/dialysis/bulletinBoard'),
195
-      name: '数据看板',
196
-      meta: {
197
-        title: '数据看板'
198
-      }
199
-    }
201
+
200
   ]
202
   ]
201
 }
203
 }

Filskillnaden har hållits tillbaka eftersom den är för stor
+ 2074 - 532
src/store/modules/globalConfig.js


+ 39 - 44
src/store/modules/xt_user.js Visa fil

1
-import {
2
-  verifyToken,
3
-  modifyAdminInfo
4
-} from '@/api/login/login'
1
+import { modifyAdminInfo, verifyToken } from '@/api/login/login'
5
 // import { mapGetters } from 'vuex'
2
 // import { mapGetters } from 'vuex'
6
 // import { getToken, setToken, removeToken } from '@/utils/auth'
3
 // import { getToken, setToken, removeToken } from '@/utils/auth'
7
-import {
8
-  getAdminUserInfoCache,
9
-  cacheAdminUserInfo,
10
-  removeAdminUserInfoCache
11
-} from '@/utils/admin_info_cache'
4
+import { cacheAdminUserInfo, getAdminUserInfoCache, removeAdminUserInfoCache } from '@/utils/admin_info_cache'
12
 import { getFiledConfigList, setFiledConfigList } from '@/utils/data_config' // getConfigList from sessionStorage
5
 import { getFiledConfigList, setFiledConfigList } from '@/utils/data_config' // getConfigList from sessionStorage
13
 
6
 
14
 const xt_user = {
7
 const xt_user = {
26
       user_type: 0, // 用户类型(1.管理员;2.医生;3.护士;4.运营)
19
       user_type: 0, // 用户类型(1.管理员;2.医生;3.护士;4.运营)
27
       user_title: 0 // 用户职称(1.医士;2.医师;3.住院医师;4.主治医师;5.副主任医师;6.主任医师;7.护士;8.护师;9.主管护师;10.副主任护师;11.主任护师;12.运营专员;13.运营主管)
20
       user_title: 0 // 用户职称(1.医士;2.医师;3.住院医师;4.主治医师;5.副主任医师;6.主任医师;7.护士;8.护师;9.主管护师;10.副主任护师;11.主任护师;12.运营专员;13.运营主管)
28
     },
21
     },
29
-    template_info:{
22
+    template_info: {
30
       id: 0,
23
       id: 0,
31
-      org_id:0,
32
-      template_id:0,
24
+      org_id: 0,
25
+      template_id: 0
33
     },
26
     },
34
 
27
 
35
     org: {
28
     org: {
57
 
50
 
58
     // 示例: ['', '',]
51
     // 示例: ['', '',]
59
     urlfors: [],
52
     urlfors: [],
60
-    fileds:[],
53
+    fileds: []
61
   },
54
   },
62
 
55
 
63
   mutations: {
56
   mutations: {
102
       state.cdm_role_exist = cur_info.cdm_role_exist
95
       state.cdm_role_exist = cur_info.cdm_role_exist
103
       state.mall_role_exist = cur_info.mall_role_exist
96
       state.mall_role_exist = cur_info.mall_role_exist
104
 
97
 
105
-
106
       state.template_info.id = cur_info.template_info.id
98
       state.template_info.id = cur_info.template_info.id
107
       state.template_info.org_id = cur_info.template_info.org_id
99
       state.template_info.org_id = cur_info.template_info.org_id
108
       state.template_info.template_id = cur_info.template_info.template_id
100
       state.template_info.template_id = cur_info.template_info.template_id
109
 
101
 
110
-
111
     },
102
     },
112
 
103
 
113
     SET_FILEDS: (state, payload) => {
104
     SET_FILEDS: (state, payload) => {
114
       state.fileds = payload.fileds
105
       state.fileds = payload.fileds
115
     },
106
     },
116
 
107
 
117
-
118
     SET_URLFORS: (state, payload) => {
108
     SET_URLFORS: (state, payload) => {
119
       state.urlfors = payload.urlfors
109
       state.urlfors = payload.urlfors
120
     },
110
     },
123
       state.user.user_name = payload.user_name
113
       state.user.user_name = payload.user_name
124
       state.user.avatar = payload.avatar
114
       state.user.avatar = payload.avatar
125
     },
115
     },
126
-    MODIFY_ORG_INFO:(state, payload) => {
116
+    MODIFY_ORG_INFO: (state, payload) => {
127
       state.org.org_name = payload.org_name
117
       state.org.org_name = payload.org_name
128
       state.org.org_short_name = payload.org_short_name
118
       state.org.org_short_name = payload.org_short_name
129
     },
119
     },
180
   },
170
   },
181
 
171
 
182
   actions: {
172
   actions: {
183
-    SetScheduleTypeSelected({commit }, schedule_type_selected) {
173
+    SetScheduleTypeSelected({ commit }, schedule_type_selected) {
184
       commit('SET_SCHEDULE_TYPE_SELECTED', schedule_type_selected)
174
       commit('SET_SCHEDULE_TYPE_SELECTED', schedule_type_selected)
185
     },
175
     },
186
     SetZoneSelected({ commit }, zone_selected) {
176
     SetZoneSelected({ commit }, zone_selected) {
187
       commit('SET_ZONE_SELECTED', zone_selected)
177
       commit('SET_ZONE_SELECTED', zone_selected)
188
     },
178
     },
189
     SetSubscibePatients({
179
     SetSubscibePatients({
190
-      commit,
191
-      state
192
-    }) {
180
+                          commit,
181
+                          state
182
+                        }) {
193
       commit('SET_SUBSCIBE_PATIENT')
183
       commit('SET_SUBSCIBE_PATIENT')
194
     },
184
     },
195
 
185
 
196
     VerifyToken({
186
     VerifyToken({
197
-      commit,
198
-      state
199
-    }, token) {
187
+                  commit,
188
+                  state
189
+                }, token) {
200
 
190
 
201
       // console.log('验证 token 之前:token = ' + token)
191
       // console.log('验证 token 之前:token = ' + token)
202
       return new Promise((resolve, reject) => {
192
       return new Promise((resolve, reject) => {
218
             cur_app_id: infoJSON.current_app_id,
208
             cur_app_id: infoJSON.current_app_id,
219
             org: infoJSON.org,
209
             org: infoJSON.org,
220
             subscibe: infoJSON.subscibe,
210
             subscibe: infoJSON.subscibe,
221
-            template_info:infoJSON.template_info,
211
+            template_info: infoJSON.template_info,
222
             scrm_role_exist: infoJSON.scrm_role_exist,
212
             scrm_role_exist: infoJSON.scrm_role_exist,
223
             cdm_role_exist: infoJSON.cdm_role_exist,
213
             cdm_role_exist: infoJSON.cdm_role_exist,
224
             mall_role_exist: infoJSON.mall_role_exist
214
             mall_role_exist: infoJSON.mall_role_exist
228
             urlfors: infoJSON.urlfors
218
             urlfors: infoJSON.urlfors
229
           })
219
           })
230
 
220
 
231
-
232
           resolve(infoJSON.user.user_id)
221
           resolve(infoJSON.user.user_id)
233
         } else {
222
         } else {
234
           verifyToken(token).then(response => {
223
           verifyToken(token).then(response => {
242
                 cur_app_id: data.current_app_id,
231
                 cur_app_id: data.current_app_id,
243
                 org: data.org,
232
                 org: data.org,
244
                 subscibe: data.subscibe,
233
                 subscibe: data.subscibe,
245
-                template_info:data.template_info,
234
+                template_info: data.template_info,
246
                 scrm_role_exist: data.scrm_role_exist,
235
                 scrm_role_exist: data.scrm_role_exist,
247
                 cdm_role_exist: data.cdm_role_exist,
236
                 cdm_role_exist: data.cdm_role_exist,
248
-                mall_role_exist: data.mall_role_exist,
237
+                mall_role_exist: data.mall_role_exist
249
               })
238
               })
250
 
239
 
251
               this.commit('SET_URLFORS', {
240
               this.commit('SET_URLFORS', {
271
       })
260
       })
272
     },
261
     },
273
     ModifyAdminUserInfo({
262
     ModifyAdminUserInfo({
274
-      commit,
275
-      state
276
-    }, params) {
263
+                          commit,
264
+                          state
265
+                        }, params) {
277
       commit('MODIFY_USER_INFO', {
266
       commit('MODIFY_USER_INFO', {
278
         user_name: params.user_name,
267
         user_name: params.user_name,
279
         avatar: params.avatar
268
         avatar: params.avatar
286
           current_app_id: state.app_id,
275
           current_app_id: state.app_id,
287
           urlfors: state.urlfors,
276
           urlfors: state.urlfors,
288
           subscibe: state.subscibe,
277
           subscibe: state.subscibe,
289
-          template_info:state.template_info,
278
+          template_info: state.template_info,
290
           scrm_role_exist: state.scrm_role_exist,
279
           scrm_role_exist: state.scrm_role_exist,
291
           cdm_role_exist: state.cdm_role_exist,
280
           cdm_role_exist: state.cdm_role_exist,
292
-          mall_role_exist: state.mall_role_exist,
281
+          mall_role_exist: state.mall_role_exist
293
         })
282
         })
294
       )
283
       )
295
     },
284
     },
296
     ModifyOrgInfo({
285
     ModifyOrgInfo({
297
-      commit,
298
-      state
299
-    }, params) {
286
+                    commit,
287
+                    state
288
+                  }, params) {
300
       commit('MODIFY_ORG_INFO', {
289
       commit('MODIFY_ORG_INFO', {
301
         org_name: params.org_name,
290
         org_name: params.org_name,
302
         org_short_name: params.org_short_name
291
         org_short_name: params.org_short_name
309
           current_app_id: state.app_id,
298
           current_app_id: state.app_id,
310
           urlfors: state.urlfors,
299
           urlfors: state.urlfors,
311
           subscibe: state.subscibe,
300
           subscibe: state.subscibe,
312
-          template_info:state.template_info,
301
+          template_info: state.template_info,
313
           scrm_role_exist: state.scrm_role_exist,
302
           scrm_role_exist: state.scrm_role_exist,
314
           cdm_role_exist: state.cdm_role_exist,
303
           cdm_role_exist: state.cdm_role_exist,
315
           mall_role_exist: state.mall_role_exist
304
           mall_role_exist: state.mall_role_exist
337
     // }
326
     // }
338
     // 登出
327
     // 登出
339
     FrontendLogout({
328
     FrontendLogout({
340
-      commit
341
-    }) {
329
+                     commit
330
+                   }) {
342
       commit('CLEAR_USER_INFO')
331
       commit('CLEAR_USER_INFO')
343
       removeAdminUserInfoCache()
332
       removeAdminUserInfoCache()
344
     }, updateFiledConfigList({ commit }, object) {
333
     }, updateFiledConfigList({ commit }, object) {
346
       var oldFiledList = getFiledConfigList()
335
       var oldFiledList = getFiledConfigList()
347
       var infoJSON = JSON.parse(oldFiledList)
336
       var infoJSON = JSON.parse(oldFiledList)
348
       console.log(object)
337
       console.log(object)
349
-      return new Promise((resolve, reject) =>{
350
-        for (let i = 0; i < infoJSON.length; i++){
351
-          if(infoJSON[i].id == object.id){
338
+      return new Promise((resolve, reject) => {
339
+        for (let i = 0; i < infoJSON.length; i++) {
340
+          if (infoJSON[i].id == object.id) {
352
             infoJSON[i].is_show = object.is_show
341
             infoJSON[i].is_show = object.is_show
353
           }
342
           }
354
         }
343
         }
357
         commit('SET_FILEDS_LIST', infoJSON)
346
         commit('SET_FILEDS_LIST', infoJSON)
358
         resolve()
347
         resolve()
359
       })
348
       })
360
-    },updateAllFiledConfigList({ commit }, object) {
349
+    }, updateAllFiledConfigList({ commit }, object) {
361
       var oldFiledList = getFiledConfigList()
350
       var oldFiledList = getFiledConfigList()
362
       var infoJSON = JSON.parse(oldFiledList)
351
       var infoJSON = JSON.parse(oldFiledList)
363
 
352
 
364
-      return new Promise((resolve, reject) =>{
353
+      return new Promise((resolve, reject) => {
365
         infoJSON = object
354
         infoJSON = object
366
         setFiledConfigList(JSON.stringify(infoJSON))
355
         setFiledConfigList(JSON.stringify(infoJSON))
367
         commit('SET_FILEDS_LIST', infoJSON)
356
         commit('SET_FILEDS_LIST', infoJSON)
368
         resolve()
357
         resolve()
369
       })
358
       })
359
+    }, ModifyAdminUserOrgInfo({ commit, state }, obj) {
360
+        this.commit('SET_CURRENT_INFO',obj)
361
+    },ModifyUrlInfo({ commit, state }, obj) {
362
+      this.commit('SET_URLFORS', obj)
363
+    },ModifyFiled({ commit, state }, obj) {
364
+      commit('SET_FILEDS', obj)
370
     }
365
     }
371
   }
366
   }
372
 }
367
 }

+ 32 - 7
src/views/layout/components/Navbar.vue Visa fil

135
   getOrgs,changeOrg
135
   getOrgs,changeOrg
136
 } from '@/api/config'
136
 } from '@/api/config'
137
 export default {
137
 export default {
138
+  inject:['reload'],
138
   data() {
139
   data() {
139
     return {
140
     return {
140
       orgs:[],
141
       orgs:[],
165
       }
166
       }
166
       changeOrg(params).then(response => {
167
       changeOrg(params).then(response => {
167
         if (response.data.state === 1) {
168
         if (response.data.state === 1) {
168
-          window.location.reload()
169
+          // window.location.reload()
169
 
170
 
170
           this.$message.success('切换成功')
171
           this.$message.success('切换成功')
171
           let data = response.data.data
172
           let data = response.data.data
172
           this.org_id = data.org.id
173
           this.org_id = data.org.id
173
           this.org_name = data.org.org_name
174
           this.org_name = data.org.org_name
174
 
175
 
175
-          this.commit('SET_CURRENT_INFO', {
176
+          this.$store.dispatch("ModifyAdminUserOrgInfo", {
176
             user: data.user,
177
             user: data.user,
177
             cur_org_id: data.current_org_id,
178
             cur_org_id: data.current_org_id,
178
             cur_app_id: data.current_app_id,
179
             cur_app_id: data.current_app_id,
179
             org: data.org,
180
             org: data.org,
180
             subscibe: data.subscibe,
181
             subscibe: data.subscibe,
181
             template_info:data.template_info,
182
             template_info:data.template_info,
182
-          })
183
+          });
183
 
184
 
184
-          this.commit('SET_URLFORS', {
185
+          this.$store.dispatch("ModifyUrlInfo", {
185
             urlfors: data.urlfors
186
             urlfors: data.urlfors
186
-          })
187
 
187
 
188
-          this.commit('SET_FILEDS', {
188
+          });
189
+
190
+          this.$store.dispatch("ModifyFiled", {
189
             fileds: data.fileds
191
             fileds: data.fileds
190
-          })
192
+
193
+
194
+          });
195
+
196
+
197
+
198
+
191
           setFiledConfigList(JSON.stringify(data.fileds))
199
           setFiledConfigList(JSON.stringify(data.fileds))
192
           cacheAdminUserInfo(JSON.stringify(data))
200
           cacheAdminUserInfo(JSON.stringify(data))
193
 
201
 
194
 
202
 
203
+          this.$store.dispatch('xt_GenerateRoutes', this.$store.getters.current_role_urls).then(() => {
204
+            this.$store.dispatch('VerifyConfigList').then(() => {
205
+              // alert('token 验证成功')
206
+              // console.log(this.$store.getters.xt_permission.addRouters)
207
+              this.$router.addRoutes(this.$store.getters.xt_permission.addRouters) // 动态添加可访问路由表
208
+              //        next({ ...to, replace: true }) // hack方法 确保addRoutes已完成 ,set the replace: true so the navigation will not leave a history record
209
+              // this.$router.replace({ path: '/' })
210
+              // window.location.reload()
211
+              // this.$router.go(0)
212
+              this.reload()
213
+            })
214
+          })
215
+
216
+
217
+
218
+
219
+
195
         }else{
220
         }else{
196
           this.$message.success(response.data.msg)
221
           this.$message.success(response.data.msg)
197
         }
222
         }

+ 1 - 1
src/xt_pages/data/components/tableson.vue Visa fil

78
             <el-form-item label="排序" prop="order">
78
             <el-form-item label="排序" prop="order">
79
               <el-input
79
               <el-input
80
                 type="age"
80
                 type="age"
81
-                v-model="temp.order"
81
+                v-model.number="temp.order"
82
                 placeholder="请输入排序值,数值越大,排序越靠前"
82
                 placeholder="请输入排序值,数值越大,排序越靠前"
83
               ></el-input>
83
               ></el-input>
84
             </el-form-item>
84
             </el-form-item>

Filskillnaden har hållits tillbaka eftersom den är för stor
+ 395 - 398
src/xt_pages/dialysis/details/assessmentBefore.vue


Filskillnaden har hållits tillbaka eftersom den är för stor
+ 657 - 498
src/xt_pages/dialysis/details/dialog/AssessmentAfterDislysis.vue


+ 35 - 22
src/xt_pages/dialysis/details/dialog/DoctorAdviceDialog.vue Visa fil

9
     >
9
     >
10
       <div class="txsj" v-show="showAdvicePanel">
10
       <div class="txsj" v-show="showAdvicePanel">
11
         <el-button round @click="openGroupFrom" :loading="deleLoading"
11
         <el-button round @click="openGroupFrom" :loading="deleLoading"
12
-                   v-if="this.$store.getters.xt_user.user.user_type == 1 || this.$store.getters.xt_user.user.user_type == 2">
12
+                   >
13
           新增医嘱
13
           新增医嘱
14
         </el-button>
14
         </el-button>
15
         <el-button round @click="openGroupFrom" :loading="deleLoading"
15
         <el-button round @click="openGroupFrom" :loading="deleLoading"
16
-                   v-if="this.$store.getters.xt_user.user.user_type == 3" disabled>新增医嘱
16
+                   disabled>新增医嘱
17
         </el-button>
17
         </el-button>
18
 
18
 
19
 
19
 
20
-        <el-button v-if="currentRow != null && this.$store.getters.xt_user.user.user_type == 3" round
20
+        <el-button v-if="currentRow != null" round
21
                    @click="execAdvice" :loading="deleLoading">执行医嘱
21
                    @click="execAdvice" :loading="deleLoading">执行医嘱
22
         </el-button>
22
         </el-button>
23
         <el-button v-else disabled round @click="execAdvice" :loading="deleLoading">执行医嘱</el-button>
23
         <el-button v-else disabled round @click="execAdvice" :loading="deleLoading">执行医嘱</el-button>
24
 
24
 
25
-        <el-button v-if="currentRow != null && this.$store.getters.xt_user.user.user_type == 3" round
25
+        <el-button v-if="currentRow != null" round
26
                    @click="checkAdvice" :loading="deleLoading">医嘱核对
26
                    @click="checkAdvice" :loading="deleLoading">医嘱核对
27
         </el-button>
27
         </el-button>
28
         <el-button v-else disabled round @click="checkAdvice" :loading="deleLoading">医嘱核对</el-button>
28
         <el-button v-else disabled round @click="checkAdvice" :loading="deleLoading">医嘱核对</el-button>
29
 
29
 
30
         <el-button
30
         <el-button
31
-          v-if="groupSelectRow != null&& (this.$store.getters.xt_user.user.user_type == 1  || this.$store.getters.xt_user.user.user_type == 2)"
31
+          v-if="groupSelectRow != null"
32
           round @click="openEditGroupAdvice" :loading="deleLoading">修改医嘱
32
           round @click="openEditGroupAdvice" :loading="deleLoading">修改医嘱
33
         </el-button>
33
         </el-button>
34
         <el-button v-else disabled round @click="openEditGroupAdvice" :loading="deleLoading">修改医嘱</el-button>
34
         <el-button v-else disabled round @click="openEditGroupAdvice" :loading="deleLoading">修改医嘱</el-button>
35
 
35
 
36
 
36
 
37
         <el-button
37
         <el-button
38
-          v-if="groupSelectRow != null&& (this.$store.getters.xt_user.user.user_type == 1  || this.$store.getters.xt_user.user.user_type == 2)"
38
+          v-if="groupSelectRow != null"
39
           round @click="openDeleteGroupAdvice" :loading="deleLoading">删除医嘱
39
           round @click="openDeleteGroupAdvice" :loading="deleLoading">删除医嘱
40
         </el-button>
40
         </el-button>
41
         <el-button v-else disabled round @click="openDeleteGroupAdvice" :loading="deleLoading">删除医嘱</el-button>
41
         <el-button v-else disabled round @click="openDeleteGroupAdvice" :loading="deleLoading">删除医嘱</el-button>
61
 
61
 
62
         </el-table-column>
62
         </el-table-column>
63
         <el-table-column prop="advice_name" min-width="50px" label="医嘱内容" align="center"
63
         <el-table-column prop="advice_name" min-width="50px" label="医嘱内容" align="center"
64
-                         v-if="(this.$store.getters.xt_user.user.user_type == 1 || this.$store.getters.xt_user.user.user_type == 2)">
64
+                         >
65
           <template slot-scope="scope">
65
           <template slot-scope="scope">
66
 
66
 
67
             <el-dropdown trigger="click" v-if="scope.row.parent_id == 0 ">
67
             <el-dropdown trigger="click" v-if="scope.row.parent_id == 0 ">
89
           </template>
89
           </template>
90
         </el-table-column>
90
         </el-table-column>
91
 
91
 
92
-        <el-table-column prop="advice_name" min-width="50px" label="医嘱内容" align="center"
93
-                         v-else>
94
-          <template slot-scope="scope">
95
-            <span v-if="scope.row.parent_id == 0 " class="el-dropdown-link">{{getAdviceContent(scope.row,1)}}</span>
96
-            <span v-if="scope.row.parent_id > 0 "
97
-                  class="el-dropdown-link">&emsp;{{getAdviceContent(scope.row,2)}}</span>
98
-          </template>
99
-        </el-table-column>
92
+        <!--<el-table-column prop="advice_name" min-width="50px" label="医嘱内容" align="center"-->
93
+                         <!--v-else>-->
94
+          <!--<template slot-scope="scope">-->
95
+            <!--<span v-if="scope.row.parent_id == 0 " class="el-dropdown-link">{{getAdviceContent(scope.row,1)}}</span>-->
96
+            <!--<span v-if="scope.row.parent_id > 0 "-->
97
+                  <!--class="el-dropdown-link">&emsp;{{getAdviceContent(scope.row,2)}}</span>-->
98
+          <!--</template>-->
99
+        <!--</el-table-column>-->
100
 
100
 
101
         <el-table-column prop="execution_time" align="center" min-width="30px" label="执行时间">
101
         <el-table-column prop="execution_time" align="center" min-width="30px" label="执行时间">
102
           <template slot-scope="scope">
102
           <template slot-scope="scope">
436
           this.$message.error('没有选择患者')
436
           this.$message.error('没有选择患者')
437
           return false
437
           return false
438
         }
438
         }
439
-        EditDoctorAdvice(this.patient.id, this.form.id, this.form).then(response => {
439
+        console.log(this.form)
440
+        let mode = "2"
441
+        if(this.form.advice_doctor != this.$store.getters.xt_user.user.id){
442
+           mode = "3"
443
+        }
444
+        EditDoctorAdvice(this.patient.id, this.form.id, this.form,mode).then(response => {
440
           if (response.data.state == 0) {
445
           if (response.data.state == 0) {
441
             this.$message.error(response.data.msg)
446
             this.$message.error(response.data.msg)
442
             return false
447
             return false
668
           return false
673
           return false
669
         }
674
         }
670
         this.exceLoading = true
675
         this.exceLoading = true
676
+        let mode = "6"
671
 
677
 
672
-        ExecDoctorAdvice(this.patient.id, this.currentRow.id, this.execTime).then(response => {
678
+        ExecDoctorAdvice(this.patient.id, this.currentRow.id, this.execTime,mode).then(response => {
673
           if (response.data.state == 0) {
679
           if (response.data.state == 0) {
674
-            this.$message.error('执行失败!')
680
+            this.$message.error(response.data.msg)
675
             this.exceLoading = false
681
             this.exceLoading = false
676
             return false
682
             return false
677
           } else {
683
           } else {
722
           this.$message.error('没有选择患者')
728
           this.$message.error('没有选择患者')
723
           return false
729
           return false
724
         }
730
         }
731
+        let mode ="1"
725
 
732
 
726
-        CreateDoctorAdvice(this.patient.id, this.form).then(response => {
733
+        CreateDoctorAdvice(this.patient.id, this.form,mode).then(response => {
727
           this.loading = false
734
           this.loading = false
728
           if (response.data.state == 0) {
735
           if (response.data.state == 0) {
729
             this.$message.error(response.data.msg)
736
             this.$message.error(response.data.msg)
1021
           cancelButtonText: '取消',
1028
           cancelButtonText: '取消',
1022
           type: 'warning'
1029
           type: 'warning'
1023
         }).then(() => {
1030
         }).then(() => {
1024
-          DeleteGroupAdvice(groupno).then(response => {
1031
+          let mode ="4"
1032
+          if(this.currentRow.advice_doctor != this.$store.getters.xt_user.user.id){
1033
+            mode = "5"
1034
+          }
1035
+          DeleteGroupAdvice(groupno,mode).then(response => {
1025
             if (response.data.state == 0) {
1036
             if (response.data.state == 0) {
1026
               this.$message.error(response.data.msg)
1037
               this.$message.error(response.data.msg)
1027
               return false
1038
               return false
1054
           type: 'warning'
1065
           type: 'warning'
1055
         }).then(() => {
1066
         }).then(() => {
1056
           this.deleLoading = true
1067
           this.deleLoading = true
1057
-          DeleteDoctorAdvice(this.currentRow.id).then(response => {
1068
+          let mode = "4"
1069
+          DeleteDoctorAdvice(this.currentRow.id,mode).then(response => {
1058
             this.deleLoading = false
1070
             this.deleLoading = false
1059
             if (response.data.state == 0) {
1071
             if (response.data.state == 0) {
1060
               this.$message.error(response.data.msg)
1072
               this.$message.error(response.data.msg)
1087
           type: 'warning'
1099
           type: 'warning'
1088
         }).then(() => {
1100
         }).then(() => {
1089
           this.deleLoading = true
1101
           this.deleLoading = true
1090
-          DeleteDoctorAdvice(this.currentRow.id).then(response => {
1102
+          let mode ="4"
1103
+          DeleteDoctorAdvice(this.currentRow.id,mode).then(response => {
1091
             this.deleLoading = false
1104
             this.deleLoading = false
1092
             if (response.data.state == 0) {
1105
             if (response.data.state == 0) {
1093
               this.$message.error(response.data.msg)
1106
               this.$message.error(response.data.msg)

+ 3 - 1
src/xt_pages/dialysis/details/dialog/adviceDialog/AddGroupAdvice.vue Visa fil

674
             adviceNames.unshift(this.groupForm.adviceNames[index]);
674
             adviceNames.unshift(this.groupForm.adviceNames[index]);
675
           }
675
           }
676
           submitForm.adviceNames = adviceNames;
676
           submitForm.adviceNames = adviceNames;
677
-          CreateGroupAdvice(this.patientID, 0, submitForm).then(response => {
677
+          let mode = "1"
678
+
679
+          CreateGroupAdvice(this.patientID, 0, submitForm,mode).then(response => {
678
             if (response.data.state == 0) {
680
             if (response.data.state == 0) {
679
               this.$message.error(response.data.msg);
681
               this.$message.error(response.data.msg);
680
               return false;
682
               return false;

+ 23 - 6
src/xt_pages/dialysis/details/dialog/adviceDialog/EditGroupAdvice.vue Visa fil

594
         }
594
         }
595
         console.log(this.groupSelectRow)
595
         console.log(this.groupSelectRow)
596
         var content = ''
596
         var content = ''
597
+
597
         if (this.groupSelectRow.children.length > 0) {
598
         if (this.groupSelectRow.children.length > 0) {
598
           content = '确认删除此医嘱内容,包括它的子药?'
599
           content = '确认删除此医嘱内容,包括它的子药?'
599
         } else {
600
         } else {
607
           cancelButtonText: '取消',
608
           cancelButtonText: '取消',
608
           type: 'warning'
609
           type: 'warning'
609
         }).then(() => {
610
         }).then(() => {
610
-          DeleteDoctorAdvice(this.groupSelectRow.id).then(response => {
611
+          let mode = "4"
612
+          if (this.groupSelectRow.advice_doctor != this.$store.getters.xt_user.user.id){
613
+             mode = "5"
614
+          }
615
+          DeleteDoctorAdvice(this.groupSelectRow.id,mode).then(response => {
611
             if (response.data.state == 0) {
616
             if (response.data.state == 0) {
612
               this.$message.error(response.data.msg)
617
               this.$message.error(response.data.msg)
613
               return false
618
               return false
700
                 parent_id: _this.groupSelectRow.parent_id,
705
                 parent_id: _this.groupSelectRow.parent_id,
701
                 groupno: _this.groupForm.groupno
706
                 groupno: _this.groupForm.groupno
702
               }
707
               }
703
-              EditDoctorAdvice(this.patientID, this.groupSelectRow.id, submitForm).then(response => {
708
+              let mode = "2"
709
+              if (this.groupSelectRow.advice_doctor != this.$store.getters.xt_user.user.id){
710
+                mode = "3"
711
+              }
712
+
713
+              EditDoctorAdvice(this.patientID, this.groupSelectRow.id, submitForm,mode).then(response => {
704
                 if (response.data.state == 0) {
714
                 if (response.data.state == 0) {
705
                   this.$message.error(response.data.msg)
715
                   this.$message.error(response.data.msg)
706
                   return false
716
                   return false
799
                   parent_id: _this.groupSelectRow.id,
809
                   parent_id: _this.groupSelectRow.id,
800
                   groupno: _this.groupForm.groupno
810
                   groupno: _this.groupForm.groupno
801
                 }
811
                 }
812
+                let mode = "1"
802
 
813
 
803
-                CreateDoctorAdvice(this.patientID, submitForm).then(response => {
814
+                CreateDoctorAdvice(this.patientID, submitForm,mode).then(response => {
804
                   if (response.data.state == 0) {
815
                   if (response.data.state == 0) {
805
                     this.$message.error(response.data.msg)
816
                     this.$message.error(response.data.msg)
806
                     return false
817
                     return false
871
                   remark: _this.groupForm.remark,
882
                   remark: _this.groupForm.remark,
872
                   parent_id: 0
883
                   parent_id: 0
873
                 }
884
                 }
874
-                CreateGroupAdvice(_this.patientID, _this.groupForm.groupno, _this.submitGroupForm).then(response => {
885
+                let mode = "1"
886
+
887
+                CreateGroupAdvice(_this.patientID, _this.groupForm.groupno, _this.submitGroupForm, mode).then(response => {
875
                   if (response.data.state == 0) {
888
                   if (response.data.state == 0) {
876
                     _this.$message.error(response.data.msg)
889
                     _this.$message.error(response.data.msg)
877
                     return false
890
                     return false
1371
           }
1384
           }
1372
           this.submitGroupForm.adviceNames.unshift(item)
1385
           this.submitGroupForm.adviceNames.unshift(item)
1373
         }
1386
         }
1387
+        let mode = "1"
1388
+
1374
 
1389
 
1375
-        CreateGroupAdvice(this.patientID, this.groupForm.groupno, this.submitGroupForm).then(response => {
1390
+        CreateGroupAdvice(this.patientID, this.groupForm.groupno, this.submitGroupForm,mode).then(response => {
1376
           if (response.data.state == 0) {
1391
           if (response.data.state == 0) {
1377
             this.$message.error(response.data.msg)
1392
             this.$message.error(response.data.msg)
1378
             return false
1393
             return false
1537
 
1552
 
1538
                 _this.submitGroupForm.adviceNames.push(item)
1553
                 _this.submitGroupForm.adviceNames.push(item)
1539
               }
1554
               }
1555
+              let mode = "1"
1556
+
1540
 
1557
 
1541
-              CreateGroupAdvice(_this.patientID, _this.groupForm.groupno, _this.submitGroupForm).then(response => {
1558
+              CreateGroupAdvice(_this.patientID, _this.groupForm.groupno, _this.submitGroupForm,mode).then(response => {
1542
                 if (response.data.state == 0) {
1559
                 if (response.data.state == 0) {
1543
                   _this.$message.error(response.data.msg)
1560
                   _this.$message.error(response.data.msg)
1544
                   return false
1561
                   return false

+ 52 - 39
src/xt_pages/dialysis/details/dialog/assessmentBeforeDislysisDialog.vue Visa fil

161
             </el-form-item>
161
             </el-form-item>
162
           </el-col>
162
           </el-col>
163
           <el-col :span="8">
163
           <el-col :span="8">
164
-            <el-form-item label="血管通路操作: " v-if="isShow('血管通路操作')">
164
+            <el-form-item label="血管通路: " v-if="isShow('血管通路')">
165
               <el-select v-model="assessmentBeforeDislysis.blood_access_part_opera_id">
165
               <el-select v-model="assessmentBeforeDislysis.blood_access_part_opera_id">
166
                 <el-option :key="0" label="请选择" :value="0"></el-option>
166
                 <el-option :key="0" label="请选择" :value="0"></el-option>
167
 
167
 
215
             </el-form-item>
215
             </el-form-item>
216
           </el-col>
216
           </el-col>
217
 
217
 
218
-          <el-col :span="8" v-if="isShow('血管通路(内瘘)')">
219
-            <el-form-item label="血管通路(内瘘):">
220
-              <div>
221
-                <el-input v-model="assessmentBeforeDislysis.blood_access_internal_fistula"
222
-                          @focus="showInnerDialog('9')"></el-input>
223
-              </div>
224
-            </el-form-item>
225
-          </el-col>
218
+<!--          <el-col :span="8" v-if="isShow('血管通路(内瘘)')">-->
219
+<!--            <el-form-item label="血管通路(内瘘):">-->
220
+<!--              <div>-->
221
+<!--                <el-input v-model="assessmentBeforeDislysis.blood_access_internal_fistula"-->
222
+<!--                          @focus="showInnerDialog('9')"></el-input>-->
223
+<!--              </div>-->
224
+<!--            </el-form-item>-->
225
+<!--          </el-col>-->
226
 
226
 
227
           <el-col :span="8">
227
           <el-col :span="8">
228
             <el-form-item label="血管通路(内瘘)其他:" v-if="isShow('血管通路(内瘘)其他')">
228
             <el-form-item label="血管通路(内瘘)其他:" v-if="isShow('血管通路(内瘘)其他')">
276
           </el-col>
276
           </el-col>
277
 
277
 
278
 
278
 
279
-          <el-col :span="8">
279
+<!--          <el-col :span="8">-->
280
 
280
 
281
-            <el-form-item label="位置: " v-if="isShow('位置')">
282
-              <el-select v-model="assessmentBeforeDislysis.venous_catheterization_part">
283
-                <el-option :key="0" label="请选择" :value="0"></el-option>
281
+<!--            <el-form-item label="位置: " v-if="isShow('位置')">-->
282
+<!--              <el-select v-model="assessmentBeforeDislysis.venous_catheterization_part">-->
283
+<!--                <el-option :key="0" label="请选择" :value="0"></el-option>-->
284
 
284
 
285
-                <el-option v-for="item in this.$store.getters.venous_catheterization_part" :label="item.name"
286
-                           :value="item.id"
287
-                           :key="item.id"></el-option>
288
-              </el-select>
289
-            </el-form-item>
290
-          </el-col>
285
+<!--                <el-option v-for="item in this.$store.getters.venous_catheterization_part" :label="item.name"-->
286
+<!--                           :value="item.id"-->
287
+<!--                           :key="item.id"></el-option>-->
288
+<!--              </el-select>-->
289
+<!--            </el-form-item>-->
290
+<!--          </el-col>-->
291
 
291
 
292
           <el-col :span="8">
292
           <el-col :span="8">
293
             <el-form-item label="其他位置:" v-if="isShow('其他位置')">
293
             <el-form-item label="其他位置:" v-if="isShow('其他位置')">
296
           </el-col>
296
           </el-col>
297
 
297
 
298
 
298
 
299
-          <el-col :span="8" v-if="isShow('中心静脉导管')">
300
-            <el-form-item label="中心静脉导管:">
301
-              <div>
302
-                <el-input v-model="assessmentBeforeDislysis.ductus_arantii" @focus="showInnerDialog('10')"></el-input>
303
-              </div>
304
-            </el-form-item>
305
-          </el-col>
299
+<!--          <el-col :span="8" v-if="isShow('导管')">-->
300
+<!--            <el-form-item label="导管:">-->
301
+<!--              <div>-->
302
+<!--                <el-input v-model="assessmentBeforeDislysis.ductus_arantii" @focus="showInnerDialog('10')"></el-input>-->
303
+<!--              </div>-->
304
+<!--            </el-form-item>-->
305
+<!--          </el-col>-->
306
 
306
 
307
 
307
 
308
           <el-col :span="8" v-if="isShow('其他中心静脉导管')">
308
           <el-col :span="8" v-if="isShow('其他中心静脉导管')">
390
 
390
 
391
           <el-row :gutter="20"> -->
391
           <el-row :gutter="20"> -->
392
           <!--<el-col :span="8">-->
392
           <!--<el-col :span="8">-->
393
-            <!--<el-form-item label="穿刺方法: " v-if="isShow('穿刺方法')">-->
393
+          <!--<el-form-item label="穿刺方法: " v-if="isShow('穿刺方法')">-->
394
 
394
 
395
-              <!--<el-select v-model="assessmentBeforeDislysis.puncture_method">-->
396
-                <!--<el-option :key="0" label="请选择" :value="0"></el-option>-->
395
+          <!--<el-select v-model="assessmentBeforeDislysis.puncture_method">-->
396
+          <!--<el-option :key="0" label="请选择" :value="0"></el-option>-->
397
 
397
 
398
-                <!--<el-option v-for="item in puncture_method" :label="item.name" :value="item.name"-->
399
-                           <!--:key="item.id"></el-option>-->
400
-              <!--</el-select>-->
398
+          <!--<el-option v-for="item in puncture_method" :label="item.name" :value="item.name"-->
399
+          <!--:key="item.id"></el-option>-->
400
+          <!--</el-select>-->
401
 
401
 
402
-            <!--</el-form-item>-->
402
+          <!--</el-form-item>-->
403
           <!--</el-col>-->
403
           <!--</el-col>-->
404
 
404
 
405
         </el-row>
405
         </el-row>
594
         if (this.predialysis_evaluation.id == 0){
594
         if (this.predialysis_evaluation.id == 0){
595
           if (this.lastDryWeightDislysis != null){
595
           if (this.lastDryWeightDislysis != null){
596
             this.weight_adjust.weight = this.lastDryWeightDislysis.dry_weight
596
             this.weight_adjust.weight = this.lastDryWeightDislysis.dry_weight
597
-             this.assessmentBeforeDislysis.dry_weight = this.lastDryWeightDislysis.dry_weight
597
+            this.assessmentBeforeDislysis.dry_weight = this.lastDryWeightDislysis.dry_weight
598
 
598
 
599
           }else{
599
           }else{
600
             if(this.lastPredialysisEvaluation != null){
600
             if(this.lastPredialysisEvaluation != null){
761
         const ParamsQuery = this.assessmentBeforeDislysis
761
         const ParamsQuery = this.assessmentBeforeDislysis
762
         ParamsQuery['patient'] = this.patient.id
762
         ParamsQuery['patient'] = this.patient.id
763
         ParamsQuery['record_date'] = this.record_date
763
         ParamsQuery['record_date'] = this.record_date
764
-        ParamsQuery['mode'] = 1
764
+        ParamsQuery['mode'] = "1"
765
+
765
         console.log(this.predialysis_evaluation)
766
         console.log(this.predialysis_evaluation)
766
-        if (this.predialysis_evaluation.creator > 0){
767
-          ParamsQuery['mode'] = 2
768
-          if(this.predialysis_evaluation.creator != this.$store.getters.xt_user.user.id){
769
-            ParamsQuery['mode'] = 3
767
+
768
+        if(this.predialysis_evaluation.id == 0){
769
+          ParamsQuery['mode'] = "1"
770
+
771
+        }else{
772
+          if (this.predialysis_evaluation.creater == 0){
773
+            ParamsQuery['mode'] = "1"
774
+          }else{
775
+            ParamsQuery['mode'] = "2"
776
+            if (this.predialysis_evaluation.creater != this.$store.getters.xt_user.user.id){
777
+              ParamsQuery['mode'] = "3"
778
+            }
779
+
770
           }
780
           }
781
+
782
+
771
         }
783
         }
772
 
784
 
773
         postAssessmentBeforeDislysis(ParamsQuery).then(response => {
785
         postAssessmentBeforeDislysis(ParamsQuery).then(response => {
810
           dry_weight: this.weight_adjust.weight,
822
           dry_weight: this.weight_adjust.weight,
811
           remark: this.weight_adjust.remark,
823
           remark: this.weight_adjust.remark,
812
           doctor_id: this.weight_adjust.doctor,
824
           doctor_id: this.weight_adjust.doctor,
825
+          mode : "1",
813
         };
826
         };
814
         CreateDryWeight(params).then(response => {
827
         CreateDryWeight(params).then(response => {
815
           if (response.data.state == 0) {
828
           if (response.data.state == 0) {

+ 35 - 78
src/xt_pages/dialysis/details/dialog/dialysisPrescriptionDialog.vue Visa fil

838
           no_anticoagulant_weichi: '0',
838
           no_anticoagulant_weichi: '0',
839
           no_anticoagulant_zongliang: '0',
839
           no_anticoagulant_zongliang: '0',
840
 
840
 
841
-
842
-          creater:0,
841
+          creater: 0
843
 
842
 
844
         },
843
         },
845
 
844
 
1000
 
999
 
1001
             console.log(this.prescription)
1000
             console.log(this.prescription)
1002
 
1001
 
1003
-            if(this.prescription.creater <= 0){
1002
+            if (this.prescription.creater <= 0) {
1004
               mode = 1
1003
               mode = 1
1005
-            }else {
1004
+            } else {
1006
               mode = 2
1005
               mode = 2
1007
             }
1006
             }
1008
 
1007
 
1009
-
1010
             postPrescription(ParamsQuery).then(response => {
1008
             postPrescription(ParamsQuery).then(response => {
1011
               if (response.data.state == 0) {
1009
               if (response.data.state == 0) {
1012
                 this.$message.error(response.data.msg)
1010
                 this.$message.error(response.data.msg)
1119
             ParamsQuery['record_date'] = this.record_date
1117
             ParamsQuery['record_date'] = this.record_date
1120
             console.log(this.prescription)
1118
             console.log(this.prescription)
1121
 
1119
 
1122
-            if(this.prescription.creater <= 0){
1120
+            if (this.prescription.creater <= 0) {
1123
               mode = 1
1121
               mode = 1
1124
-            }else {
1122
+            } else {
1125
               mode = 2
1123
               mode = 2
1126
             }
1124
             }
1127
 
1125
 
1128
-
1129
             postPrescription(ParamsQuery).then(response => {
1126
             postPrescription(ParamsQuery).then(response => {
1130
               if (response.data.state == 0) {
1127
               if (response.data.state == 0) {
1131
                 this.$message.error(response.data.msg)
1128
                 this.$message.error(response.data.msg)
1263
             const ParamsQuery = this.dialysisPrescription
1260
             const ParamsQuery = this.dialysisPrescription
1264
             ParamsQuery['patient'] = this.patient.id
1261
             ParamsQuery['patient'] = this.patient.id
1265
             ParamsQuery['record_date'] = this.record_date
1262
             ParamsQuery['record_date'] = this.record_date
1266
-            console.log(this.prescription)
1267
-
1268
-            if(this.prescription.creater <= 0){
1269
-              mode = 1
1270
-            }else {
1271
-              mode = 2
1272
-            }
1273
-
1263
+            ParamsQuery['mode'] = '1'
1274
 
1264
 
1275
             postPrescription(ParamsQuery).then(response => {
1265
             postPrescription(ParamsQuery).then(response => {
1276
               if (response.data.state == 0) {
1266
               if (response.data.state == 0) {
1308
               const ParamsQuery = this.dialysisPrescription
1298
               const ParamsQuery = this.dialysisPrescription
1309
               ParamsQuery['patient'] = this.patient.id
1299
               ParamsQuery['patient'] = this.patient.id
1310
               ParamsQuery['record_date'] = this.record_date
1300
               ParamsQuery['record_date'] = this.record_date
1311
-              console.log(this.prescription)
1312
-
1313
-              if(this.prescription.creater <= 0){
1314
-                mode = 1
1315
-              }else {
1316
-                mode = 2
1317
-              }
1318
-
1301
+              ParamsQuery['mode'] = '1'
1319
 
1302
 
1320
               postPrescription(ParamsQuery).then(response => {
1303
               postPrescription(ParamsQuery).then(response => {
1321
                 if (response.data.state == 0) {
1304
                 if (response.data.state == 0) {
1369
               const ParamsQuery = this.dialysisPrescription
1352
               const ParamsQuery = this.dialysisPrescription
1370
               ParamsQuery['patient'] = this.patient.id
1353
               ParamsQuery['patient'] = this.patient.id
1371
               ParamsQuery['record_date'] = this.record_date
1354
               ParamsQuery['record_date'] = this.record_date
1372
-              console.log(this.prescription)
1373
-
1374
-              if(this.prescription.creater <= 0){
1375
-                mode = 1
1376
-              }else {
1377
-                mode = 2
1378
-              }
1379
-
1355
+              ParamsQuery['mode'] = '1'
1380
 
1356
 
1381
               postPrescription(ParamsQuery).then(response => {
1357
               postPrescription(ParamsQuery).then(response => {
1382
                 if (response.data.state == 0) {
1358
                 if (response.data.state == 0) {
1411
               ParamsQuery['record_date'] = this.record_date
1387
               ParamsQuery['record_date'] = this.record_date
1412
               console.log(this.prescription)
1388
               console.log(this.prescription)
1413
 
1389
 
1414
-              if(this.prescription.creater <= 0){
1390
+              if (this.prescription.creater <= 0) {
1415
                 mode = 1
1391
                 mode = 1
1416
-              }else {
1392
+              } else {
1417
                 mode = 2
1393
                 mode = 2
1418
               }
1394
               }
1419
 
1395
 
1420
-
1421
               postPrescription(ParamsQuery).then(response => {
1396
               postPrescription(ParamsQuery).then(response => {
1422
                 if (response.data.state == 0) {
1397
                 if (response.data.state == 0) {
1423
                   this.$message.error(response.data.msg)
1398
                   this.$message.error(response.data.msg)
1453
               const ParamsQuery = this.dialysisPrescription
1428
               const ParamsQuery = this.dialysisPrescription
1454
               ParamsQuery['patient'] = this.patient.id
1429
               ParamsQuery['patient'] = this.patient.id
1455
               ParamsQuery['record_date'] = this.record_date
1430
               ParamsQuery['record_date'] = this.record_date
1456
-              console.log(this.prescription)
1457
-
1458
-              if(this.prescription.creater <= 0){
1459
-                mode = 1
1460
-              }else {
1461
-                mode = 2
1462
-              }
1463
-
1431
+              ParamsQuery['mode'] = '1'
1464
 
1432
 
1465
               postPrescription(ParamsQuery).then(response => {
1433
               postPrescription(ParamsQuery).then(response => {
1466
                 if (response.data.state == 0) {
1434
                 if (response.data.state == 0) {
1498
                 const ParamsQuery = this.dialysisPrescription
1466
                 const ParamsQuery = this.dialysisPrescription
1499
                 ParamsQuery['patient'] = this.patient.id
1467
                 ParamsQuery['patient'] = this.patient.id
1500
                 ParamsQuery['record_date'] = this.record_date
1468
                 ParamsQuery['record_date'] = this.record_date
1501
-                console.log(this.prescription)
1502
-
1503
-                if(this.prescription.creater <= 0){
1504
-                  mode = 1
1505
-                }else {
1506
-                  mode = 2
1507
-                }
1508
-
1469
+                ParamsQuery['mode'] = '1'
1509
 
1470
 
1510
                 postPrescription(ParamsQuery).then(response => {
1471
                 postPrescription(ParamsQuery).then(response => {
1511
                   if (response.data.state == 0) {
1472
                   if (response.data.state == 0) {
1559
                 const ParamsQuery = this.dialysisPrescription
1520
                 const ParamsQuery = this.dialysisPrescription
1560
                 ParamsQuery['patient'] = this.patient.id
1521
                 ParamsQuery['patient'] = this.patient.id
1561
                 ParamsQuery['record_date'] = this.record_date
1522
                 ParamsQuery['record_date'] = this.record_date
1562
-                console.log(this.prescription)
1563
-
1564
-                if(this.prescription.creater <= 0){
1565
-                  mode = 1
1566
-                }else {
1567
-                  mode = 2
1568
-                }
1569
-
1523
+                ParamsQuery['mode'] = '1'
1570
 
1524
 
1571
                 postPrescription(ParamsQuery).then(response => {
1525
                 postPrescription(ParamsQuery).then(response => {
1572
                   if (response.data.state == 0) {
1526
                   if (response.data.state == 0) {
1599
                 const ParamsQuery = this.dialysisPrescription
1553
                 const ParamsQuery = this.dialysisPrescription
1600
                 ParamsQuery['patient'] = this.patient.id
1554
                 ParamsQuery['patient'] = this.patient.id
1601
                 ParamsQuery['record_date'] = this.record_date
1555
                 ParamsQuery['record_date'] = this.record_date
1602
-                console.log(this.prescription)
1603
-
1604
-                if(this.prescription.creater <= 0){
1605
-                  mode = 1
1606
-                }else {
1607
-                  mode = 2
1608
-                }
1556
+                ParamsQuery['mode'] = '1'
1609
 
1557
 
1610
 
1558
 
1611
                 postPrescription(ParamsQuery).then(response => {
1559
                 postPrescription(ParamsQuery).then(response => {
1641
             const ParamsQuery = this.dialysisPrescription
1589
             const ParamsQuery = this.dialysisPrescription
1642
             ParamsQuery['patient'] = this.patient.id
1590
             ParamsQuery['patient'] = this.patient.id
1643
             ParamsQuery['record_date'] = this.record_date
1591
             ParamsQuery['record_date'] = this.record_date
1644
-            console.log(this.prescription)
1592
+            ParamsQuery['mode'] = "2"
1645
 
1593
 
1646
-            if(this.prescription.creater <= 0){
1647
-              mode = 1
1648
-            }else {
1649
-              mode = 2
1594
+            if (this.$store.getters.xt_user.user.id  != this.dialysisPrescription.creater){
1595
+              ParamsQuery['mode'] = "3"
1650
             }
1596
             }
1651
 
1597
 
1652
-
1653
             postPrescription(ParamsQuery).then(response => {
1598
             postPrescription(ParamsQuery).then(response => {
1654
               if (response.data.state == 0) {
1599
               if (response.data.state == 0) {
1655
                 this.$message.error(response.data.msg)
1600
                 this.$message.error(response.data.msg)
1701
             const ParamsQuery = this.dialysisPrescription
1646
             const ParamsQuery = this.dialysisPrescription
1702
             ParamsQuery['patient'] = this.patient.id
1647
             ParamsQuery['patient'] = this.patient.id
1703
             ParamsQuery['record_date'] = this.record_date
1648
             ParamsQuery['record_date'] = this.record_date
1649
+            ParamsQuery['mode'] = "1"
1650
+
1704
             postSoulution(ParamsQuery).then(response => {
1651
             postSoulution(ParamsQuery).then(response => {
1705
               if (response.data.state == 0) {
1652
               if (response.data.state == 0) {
1706
                 this.$message.error(response.data.msg)
1653
                 this.$message.error(response.data.msg)
1742
               const ParamsQuery = this.dialysisPrescription
1689
               const ParamsQuery = this.dialysisPrescription
1743
               ParamsQuery['patient'] = this.patient.id
1690
               ParamsQuery['patient'] = this.patient.id
1744
               ParamsQuery['record_date'] = this.record_date
1691
               ParamsQuery['record_date'] = this.record_date
1692
+              ParamsQuery['mode'] = "1"
1693
+
1745
               postSoulution(ParamsQuery).then(response => {
1694
               postSoulution(ParamsQuery).then(response => {
1746
                 if (response.data.state == 0) {
1695
                 if (response.data.state == 0) {
1747
                   this.$message.error(response.data.msg)
1696
                   this.$message.error(response.data.msg)
1802
               ParamsQuery['record_date'] = this.record_date
1751
               ParamsQuery['record_date'] = this.record_date
1803
               console.log(this.prescription)
1752
               console.log(this.prescription)
1804
 
1753
 
1805
-              if(this.prescription.creater <= 0){
1806
-                mode = 1
1807
-              }else {
1808
-                mode = 2
1809
-              }
1754
+              ParamsQuery['mode'] = "1"
1810
 
1755
 
1811
 
1756
 
1812
               postPrescription(ParamsQuery).then(response => {
1757
               postPrescription(ParamsQuery).then(response => {
1839
               const ParamsQuery = this.dialysisPrescription
1784
               const ParamsQuery = this.dialysisPrescription
1840
               ParamsQuery['patient'] = this.patient.id
1785
               ParamsQuery['patient'] = this.patient.id
1841
               ParamsQuery['record_date'] = this.record_date
1786
               ParamsQuery['record_date'] = this.record_date
1787
+              ParamsQuery['mode'] = "1"
1788
+
1842
               postSoulution(ParamsQuery).then(response => {
1789
               postSoulution(ParamsQuery).then(response => {
1843
                 if (response.data.state == 0) {
1790
                 if (response.data.state == 0) {
1844
                   this.$message.error(response.data.msg)
1791
                   this.$message.error(response.data.msg)
1879
               const ParamsQuery = this.dialysisPrescription
1826
               const ParamsQuery = this.dialysisPrescription
1880
               ParamsQuery['patient'] = this.patient.id
1827
               ParamsQuery['patient'] = this.patient.id
1881
               ParamsQuery['record_date'] = this.record_date
1828
               ParamsQuery['record_date'] = this.record_date
1829
+              ParamsQuery['mode'] = "1"
1830
+
1882
               postSoulution(ParamsQuery).then(response => {
1831
               postSoulution(ParamsQuery).then(response => {
1883
                 if (response.data.state == 0) {
1832
                 if (response.data.state == 0) {
1884
                   this.$message.error(response.data.msg)
1833
                   this.$message.error(response.data.msg)
1920
                 const ParamsQuery = this.dialysisPrescription
1869
                 const ParamsQuery = this.dialysisPrescription
1921
                 ParamsQuery['patient'] = this.patient.id
1870
                 ParamsQuery['patient'] = this.patient.id
1922
                 ParamsQuery['record_date'] = this.record_date
1871
                 ParamsQuery['record_date'] = this.record_date
1872
+                ParamsQuery['mode'] = "1"
1873
+
1923
                 postSoulution(ParamsQuery).then(response => {
1874
                 postSoulution(ParamsQuery).then(response => {
1924
                   if (response.data.state == 0) {
1875
                   if (response.data.state == 0) {
1925
                     this.$message.error(response.data.msg)
1876
                     this.$message.error(response.data.msg)
1956
                   advice_doctor: this.waitUploadAdvices[0].advice_doctor,
1907
                   advice_doctor: this.waitUploadAdvices[0].advice_doctor,
1957
                   advice_type: this.waitUploadAdvices[0].advice_type,
1908
                   advice_type: this.waitUploadAdvices[0].advice_type,
1958
                   parent_id: this.patient_id,
1909
                   parent_id: this.patient_id,
1959
-                  start_time: uParseTime(this.$route.query.date, '{y}-{m}-{d}'),
1910
+                  start_time: uParseTime(this.$route.query.date, '{y}-{m}-{d} {h}{i}'),
1960
                   remark: ''
1911
                   remark: ''
1961
                 }
1912
                 }
1962
                 CreateGroupAdvice(this.$route.query.patient_id, 0, params).then(rs => {
1913
                 CreateGroupAdvice(this.$route.query.patient_id, 0, params).then(rs => {
1977
                 const ParamsQuery = this.dialysisPrescription
1928
                 const ParamsQuery = this.dialysisPrescription
1978
                 ParamsQuery['patient'] = this.patient.id
1929
                 ParamsQuery['patient'] = this.patient.id
1979
                 ParamsQuery['record_date'] = this.record_date
1930
                 ParamsQuery['record_date'] = this.record_date
1931
+                ParamsQuery['mode'] = "1"
1932
+
1980
                 postSoulution(ParamsQuery).then(response => {
1933
                 postSoulution(ParamsQuery).then(response => {
1981
                   if (response.data.state == 0) {
1934
                   if (response.data.state == 0) {
1982
                     this.$message.error(response.data.msg)
1935
                     this.$message.error(response.data.msg)
2013
                 const ParamsQuery = this.dialysisPrescription
1966
                 const ParamsQuery = this.dialysisPrescription
2014
                 ParamsQuery['patient'] = this.patient.id
1967
                 ParamsQuery['patient'] = this.patient.id
2015
                 ParamsQuery['record_date'] = this.record_date
1968
                 ParamsQuery['record_date'] = this.record_date
1969
+                ParamsQuery['mode'] = "1"
1970
+
2016
                 postSoulution(ParamsQuery).then(response => {
1971
                 postSoulution(ParamsQuery).then(response => {
2017
                   if (response.data.state == 0) {
1972
                   if (response.data.state == 0) {
2018
                     this.$message.error(response.data.msg)
1973
                     this.$message.error(response.data.msg)
2051
             const ParamsQuery = this.dialysisPrescription
2006
             const ParamsQuery = this.dialysisPrescription
2052
             ParamsQuery['patient'] = this.patient.id
2007
             ParamsQuery['patient'] = this.patient.id
2053
             ParamsQuery['record_date'] = this.record_date
2008
             ParamsQuery['record_date'] = this.record_date
2009
+            ParamsQuery['mode'] = "1"
2010
+
2054
             postSoulution(ParamsQuery).then(response => {
2011
             postSoulution(ParamsQuery).then(response => {
2055
               if (response.data.state == 0) {
2012
               if (response.data.state == 0) {
2056
                 this.$message.error(response.data.msg)
2013
                 this.$message.error(response.data.msg)

+ 5 - 0
src/xt_pages/dialysis/details/dialog/monitor_dialog.vue Visa fil

1052
         type: "warning"
1052
         type: "warning"
1053
       })
1053
       })
1054
         .then(() => {
1054
         .then(() => {
1055
+          let mode = "4"
1056
+          // if(this.table_current_row)
1057
+
1058
+
1055
           const params = {
1059
           const params = {
1056
             patient_id: this.patient_id,
1060
             patient_id: this.patient_id,
1057
             record_id: this.table_current_row.id
1061
             record_id: this.table_current_row.id
1062
+
1058
           };
1063
           };
1059
 
1064
 
1060
           postDelMonitorInfo(params).then(response => {
1065
           postDelMonitorInfo(params).then(response => {

+ 12 - 15
src/xt_pages/management/components/MultipleForm.vue Visa fil

6
       width="95%"
6
       width="95%"
7
       center
7
       center
8
     >
8
     >
9
-      <el-form style="height:100%">
9
+      <el-form style="height: 100%;">
10
         <el-row :gutter="20">
10
         <el-row :gutter="20">
11
           <el-col :span="4">
11
           <el-col :span="4">
12
             <el-form-item label="透析分区:">
12
             <el-form-item label="透析分区:">
13
-              <el-select style="width:110px" v-model="form.zone">
13
+              <el-select style="width: 110px;" v-model="form.zone">
14
                 <el-option
14
                 <el-option
15
                   v-for="item in this.DeviceType"
15
                   v-for="item in this.DeviceType"
16
                   :key="item.id"
16
                   :key="item.id"
22
           </el-col>
22
           </el-col>
23
           <el-col :span="4">
23
           <el-col :span="4">
24
             <el-form-item label="机号:">
24
             <el-form-item label="机号:">
25
-              <el-select style="width:110px" v-model="form.device_number">
25
+              <el-select style="width: 110px;" v-model="form.device_number">
26
                 <el-option
26
                 <el-option
27
                   v-for="item in this.Numbers"
27
                   v-for="item in this.Numbers"
28
                   :key="item.id"
28
                   :key="item.id"
34
           </el-col>
34
           </el-col>
35
           <el-col :span="4">
35
           <el-col :span="4">
36
             <el-form-item label="设备类型:">
36
             <el-form-item label="设备类型:">
37
-              <el-select style="width:110px" v-model="form.device_type">
37
+              <el-select style="width: 110px;" v-model="form.device_type">
38
                 <el-option
38
                 <el-option
39
                   v-for="item in this.EquitmentType"
39
                   v-for="item in this.EquitmentType"
40
                   :key="item.id"
40
                   :key="item.id"
46
           </el-col>
46
           </el-col>
47
           <el-col :span="4">
47
           <el-col :span="4">
48
             <el-form-item label="设备型号:">
48
             <el-form-item label="设备型号:">
49
-              <el-select style="width:110px" v-model="form.device_model">
49
+              <el-select style="width: 110px;" v-model="form.device_model">
50
                 <el-option
50
                 <el-option
51
                   v-for="item in this.EquitmentName"
51
                   v-for="item in this.EquitmentName"
52
                   :key="item.id"
52
                   :key="item.id"
58
           </el-col>
58
           </el-col>
59
           <el-col :span="4">
59
           <el-col :span="4">
60
             <el-form-item label="使用年限:">
60
             <el-form-item label="使用年限:">
61
-              <el-select style="width:110px" v-model="form.user_year">
61
+              <el-select style="width: 110px;" v-model="form.user_year">
62
                 <el-option
62
                 <el-option
63
                   v-for="item in this.userYear"
63
                   v-for="item in this.userYear"
64
                   :key="item.id"
64
                   :key="item.id"
122
         <el-table
122
         <el-table
123
           :data="tableData"
123
           :data="tableData"
124
           border
124
           border
125
-          style="width:100%"
126
-          height="80%"
125
+          style="width: 100%;"
126
+          height="330"
127
           :row-style="{ color: '#303133' }"
127
           :row-style="{ color: '#303133' }"
128
           :header-cell-style="{
128
           :header-cell-style="{
129
             backgroundColor: 'rgb(245, 247, 250)',
129
             backgroundColor: 'rgb(245, 247, 250)',
184
             width="100"
184
             width="100"
185
             align="center"
185
             align="center"
186
           >
186
           >
187
-            <template slot-scope="scope">{{ scope.row.unit_type }}</template>
187
+            <template slot-scope="scope">{{ scope.row.device_mode }}</template>
188
           </el-table-column>
188
           </el-table-column>
189
           <el-table-column
189
           <el-table-column
190
             prop="address"
190
             prop="address"
328
       DeviceType: [{ id: 0, name: "不限" }],
328
       DeviceType: [{ id: 0, name: "不限" }],
329
       Numbers: [{ id: 0, number: "不限" }],
329
       Numbers: [{ id: 0, number: "不限" }],
330
       EquitmentName: [{ id: 0, equitment_name: "全部" }],
330
       EquitmentName: [{ id: 0, equitment_name: "全部" }],
331
-      runOptions: [
332
-        { value: "1", label: "正常" },
333
-        { value: "2", label: "故障" }
334
-      ]
331
+      runOptions: [{ value: "1", label: "正常" }, { value: "2", label: "故障" }]
335
     };
332
     };
336
   },
333
   },
337
   methods: {
334
   methods: {
384
       getComprehensive(params).then(response => {
381
       getComprehensive(params).then(response => {
385
         if (response.data.state === 1) {
382
         if (response.data.state === 1) {
386
           var macher = response.data.data.macher;
383
           var macher = response.data.data.macher;
387
-          console.log("设备型号5555", macher);
384
+
388
           for (let index = 0; index < macher.length; index++) {
385
           for (let index = 0; index < macher.length; index++) {
389
             if (macher[index].device_type === 1) {
386
             if (macher[index].device_type === 1) {
390
               macher[index].device_type = "透析机";
387
               macher[index].device_type = "透析机";
428
       getTotalCount().then(response => {
425
       getTotalCount().then(response => {
429
         if (response.data.state === 1) {
426
         if (response.data.state === 1) {
430
           var total = response.data.data.total;
427
           var total = response.data.data.total;
431
-          // console.log('total ========', total)
428
+
432
           this.failure_times = total;
429
           this.failure_times = total;
433
         }
430
         }
434
       });
431
       });

+ 20 - 23
src/xt_pages/management/components/UserForm.vue Visa fil

1002
       limit: 10,
1002
       limit: 10,
1003
       page: 1,
1003
       page: 1,
1004
       total: 0,
1004
       total: 0,
1005
+      value: "",
1005
       classType: [
1006
       classType: [
1006
         { id: 1, name: "上午" },
1007
         { id: 1, name: "上午" },
1007
         { id: 2, name: "下午" },
1008
         { id: 2, name: "下午" },
1066
         { id: 8, name: "50%冰醋酸" },
1067
         { id: 8, name: "50%冰醋酸" },
1067
         { id: 9, name: "5%次氯酸钠" }
1068
         { id: 9, name: "5%次氯酸钠" }
1068
       ],
1069
       ],
1069
-      runOption: [
1070
-        { id: 1, name: "正常" },
1071
-        { id: 2, name: "故障" }
1072
-      ],
1073
-      runOptions: [
1074
-        { id: 1, name: "达标" },
1075
-        { id: 2, name: "未达标" }
1076
-      ],
1070
+      runOption: [{ id: 1, name: "正常" }, { id: 2, name: "故障" }],
1071
+      runOptions: [{ id: 1, name: "达标" }, { id: 2, name: "未达标" }],
1077
       faultPhase: [
1072
       faultPhase: [
1078
         { id: 1, name: "开机启动" },
1073
         { id: 1, name: "开机启动" },
1079
         { id: 2, name: "自检" },
1074
         { id: 2, name: "自检" },
1081
         { id: 4, name: "治疗" },
1076
         { id: 4, name: "治疗" },
1082
         { id: 5, name: "消毒" }
1077
         { id: 5, name: "消毒" }
1083
       ],
1078
       ],
1084
-      Disinfectant: [
1085
-        { id: 1, name: "有" },
1086
-        { id: 2, name: "无" }
1087
-      ],
1088
-      potency: [
1089
-        { id: 1, name: "达标" },
1090
-        { id: 2, name: "未达标" }
1091
-      ],
1079
+      Disinfectant: [{ id: 1, name: "有" }, { id: 2, name: "无" }],
1080
+      potency: [{ id: 1, name: "达标" }, { id: 2, name: "未达标" }],
1092
       disinfection: [
1081
       disinfection: [
1093
         { id: 1, name: "已消毒" },
1082
         { id: 1, name: "已消毒" },
1094
         { id: 2, name: "未消毒" },
1083
         { id: 2, name: "未消毒" },
1153
         germ_number: "", // 数量
1142
         germ_number: "", // 数量
1154
         clean: "", // 清洁
1143
         clean: "", // 清洁
1155
         sign_name: "", // 签名
1144
         sign_name: "", // 签名
1156
-        patient_id: ""
1145
+        patient_id: "",
1146
+        equiment_id: ""
1157
       },
1147
       },
1158
       hiddenShow: false,
1148
       hiddenShow: false,
1159
       searchArray: [],
1149
       searchArray: [],
1438
     },
1428
     },
1439
     handleSizeChange(limit) {
1429
     handleSizeChange(limit) {
1440
       this.limit = limit;
1430
       this.limit = limit;
1441
-      this.queryInfo();
1431
+      //this.queryInfo();
1432
+      this.getUserForm(this.value);
1442
     },
1433
     },
1443
     handleCurrentChange(page) {
1434
     handleCurrentChange(page) {
1444
       this.page = page;
1435
       this.page = page;
1445
-      this.queryInfo();
1436
+      // this.queryInfo();
1437
+      this.getUserForm(this.value);
1446
     },
1438
     },
1447
     getTime(time) {
1439
     getTime(time) {
1448
       return uParseTime(time, "{y}-{m}-{d}");
1440
       return uParseTime(time, "{y}-{m}-{d}");
1474
       EditUser(id, patientid).then(response => {
1466
       EditUser(id, patientid).then(response => {
1475
         if (response.data.state === 1) {
1467
         if (response.data.state === 1) {
1476
           var device = response.data.data.device;
1468
           var device = response.data.data.device;
1477
-          // console.log('device', device)
1469
+          console.log("device", device);
1478
           var patients = response.data.data.patients;
1470
           var patients = response.data.data.patients;
1479
           // console.log('patients', patients)
1471
           // console.log('patients', patients)
1480
           // eslint-disable-next-line no-sequences
1472
           // eslint-disable-next-line no-sequences
1485
             ));
1477
             ));
1486
           this.userform.patient_id = device.patient_id;
1478
           this.userform.patient_id = device.patient_id;
1487
           this.userform.classtype = device.class;
1479
           this.userform.classtype = device.class;
1488
-          this.userform.zone = device.zone;
1480
+          this.userform.zone = device.zone_id;
1489
           this.userform.bed_number = device.bed_number;
1481
           this.userform.bed_number = device.bed_number;
1490
           this.userform.contagion = device.contagion;
1482
           this.userform.contagion = device.contagion;
1491
           this.userform.patient_name = patients.name;
1483
           this.userform.patient_name = patients.name;
1531
           // )
1523
           // )
1532
           this.userform.starttime = this.updateTimes(device.disinfec_startime);
1524
           this.userform.starttime = this.updateTimes(device.disinfec_startime);
1533
           this.userform.endtime = this.updateTimes(device.disinfec_endtime);
1525
           this.userform.endtime = this.updateTimes(device.disinfec_endtime);
1526
+          this.userform.equiment_id = device.equiment_id;
1534
           if (device.dialysis_checked === 1) {
1527
           if (device.dialysis_checked === 1) {
1535
             this.userform.dialysis_checked = true;
1528
             this.userform.dialysis_checked = true;
1536
           }
1529
           }
1701
       ).then(response => {
1694
       ).then(response => {
1702
         if (response.data.state === 1) {
1695
         if (response.data.state === 1) {
1703
           var information = response.data.data.infor;
1696
           var information = response.data.data.infor;
1697
+          console.log("information", information);
1704
           for (let index = 0; index < information.length; index++) {
1698
           for (let index = 0; index < information.length; index++) {
1705
             if (information[index].class === 0) {
1699
             if (information[index].class === 0) {
1706
               information[index].class = "";
1700
               information[index].class = "";
2231
             // this.form.bed = information[index].bed_number
2225
             // this.form.bed = information[index].bed_number
2232
           }
2226
           }
2233
           var total = response.data.data.total;
2227
           var total = response.data.data.total;
2228
+          console.log("total", total);
2234
           this.tableData = information;
2229
           this.tableData = information;
2235
           this.total = total;
2230
           this.total = total;
2236
         }
2231
         }
2242
           var addmacher = response.data.data.addmacher;
2237
           var addmacher = response.data.data.addmacher;
2243
           console.log("addmacher=============", addmacher);
2238
           console.log("addmacher=============", addmacher);
2244
           var number = response.data.data.number;
2239
           var number = response.data.data.number;
2245
-          // console.log('number', number)
2246
-          this.form.zone = addmacher.zone_id;
2240
+          console.log("number", number);
2241
+          //改动
2242
+          this.form.zone = number[0].zone_id;
2247
           this.form.bed = addmacher.bed_id;
2243
           this.form.bed = addmacher.bed_id;
2248
 
2244
 
2249
           var bed = [{ id: 0, number: "全部" }];
2245
           var bed = [{ id: 0, number: "全部" }];
2360
       console.log("newvalue是什么", newvalue);
2356
       console.log("newvalue是什么", newvalue);
2361
       this.getUserForm(newvalue);
2357
       this.getUserForm(newvalue);
2362
       this.getBedForm(newvalue);
2358
       this.getBedForm(newvalue);
2359
+      this.value = newvalue;
2363
     }
2360
     }
2364
   }
2361
   }
2365
 };
2362
 };

+ 14 - 11
src/xt_pages/management/home.vue Visa fil

493
                                         </el-select>
493
                                         </el-select>
494
                                      </el-form-item>
494
                                      </el-form-item>
495
                                 </el-col>
495
                                 </el-col>
496
-                                 <el-col :span="7">      
496
+                                 <el-col :span="7">
497
                                     <el-form-item label="使用年限(年):">
497
                                     <el-form-item label="使用年限(年):">
498
                                       <el-input style="width:150px" v-model="form.user_year" :disabled="disableFour"></el-input>
498
                                       <el-input style="width:150px" v-model="form.user_year" :disabled="disableFour"></el-input>
499
                                     </el-form-item>
499
                                     </el-form-item>
2685
                 this.$refs.singleTable.setCurrentRow(this.tableDatatwo[i])
2685
                 this.$refs.singleTable.setCurrentRow(this.tableDatatwo[i])
2686
                 break
2686
                 break
2687
               }
2687
               }
2688
-              
2688
+
2689
             }
2689
             }
2690
             // this.$refs.singleTable.setCurrentRow(this.tableDatatwo[this.tabIndex])
2690
             // this.$refs.singleTable.setCurrentRow(this.tableDatatwo[this.tabIndex])
2691
           }
2691
           }
3004
                       //   this.$forceUpdate()
3004
                       //   this.$forceUpdate()
3005
                     }
3005
                     }
3006
                   }
3006
                   }
3007
-  
3007
+
3008
                   this.tableDatatwo[i] = addmacher
3008
                   this.tableDatatwo[i] = addmacher
3009
                   // this.$refs.singleTable.setCurrentRow(this.tableDatatwo[i])
3009
                   // this.$refs.singleTable.setCurrentRow(this.tableDatatwo[i])
3010
                 }
3010
                 }
3013
               // this.getAllSubregion()
3013
               // this.getAllSubregion()
3014
               this.$refs.singleTable.setCurrentRow(addmacher)
3014
               this.$refs.singleTable.setCurrentRow(addmacher)
3015
               this.$forceUpdate()
3015
               this.$forceUpdate()
3016
+            }else{
3017
+             this.$message.error("修改失败");
3016
             }
3018
             }
3017
           })
3019
           })
3018
         })
3020
         })
3059
                       //   this.$forceUpdate()
3061
                       //   this.$forceUpdate()
3060
                       }
3062
                       }
3061
                     }
3063
                     }
3062
-  
3064
+
3063
                     this.tableDatatwo[i] = addmacher
3065
                     this.tableDatatwo[i] = addmacher
3064
                   // this.$refs.singleTable.setCurrentRow(this.tableDatatwo[i])
3066
                   // this.$refs.singleTable.setCurrentRow(this.tableDatatwo[i])
3065
                   }
3067
                   }
3103
                       //   this.$forceUpdate()
3105
                       //   this.$forceUpdate()
3104
                     }
3106
                     }
3105
                   }
3107
                   }
3106
-  
3108
+
3107
                   this.tableDatatwo[i] = addmacher
3109
                   this.tableDatatwo[i] = addmacher
3108
                   // this.$refs.singleTable.setCurrentRow(this.tableDatatwo[i])
3110
                   // this.$refs.singleTable.setCurrentRow(this.tableDatatwo[i])
3109
                 }
3111
                 }
3449
             this.machineform.machine_disinfectant = plan.machine_disinfectant
3451
             this.machineform.machine_disinfectant = plan.machine_disinfectant
3450
             this.machineform.disinfectant_way = plan.disinfectan_way
3452
             this.machineform.disinfectant_way = plan.disinfectan_way
3451
             this.machineform.disinfectant = plan.disinfectant
3453
             this.machineform.disinfectant = plan.disinfectant
3452
-            this.getPatientDetail(this.unitType, this.$route.query.bedid)
3454
+           // this.getPatientDetail(this.unitType, this.$route.query.bedid)
3453
           }
3455
           }
3454
         })
3456
         })
3455
       },
3457
       },
3457
         var devicetype = this.machineform.device_type
3459
         var devicetype = this.machineform.device_type
3458
         var devicetypes = parseInt(devicetype)
3460
         var devicetypes = parseInt(devicetype)
3459
         this.machineform.device_type = devicetypes
3461
         this.machineform.device_type = devicetypes
3460
-  
3462
+
3461
         if (this.machineform.disinfec_time === '') {
3463
         if (this.machineform.disinfec_time === '') {
3462
           this.machineform.disinfec_time = ''
3464
           this.machineform.disinfec_time = ''
3463
         }
3465
         }
3466
           var disinfectime = parseInt(disinfectimes)
3468
           var disinfectime = parseInt(disinfectimes)
3467
           this.machineform.disinfec_time = disinfectime
3469
           this.machineform.disinfec_time = disinfectime
3468
         }
3470
         }
3469
-  
3471
+
3470
         var times = this.machineform.time
3472
         var times = this.machineform.time
3471
         var time = parseInt(times)
3473
         var time = parseInt(times)
3472
         this.machineform.time = time
3474
         this.machineform.time = time
3874
         getUserRegister(id).then(response => {
3876
         getUserRegister(id).then(response => {
3875
           if (response.data.state === 1) {
3877
           if (response.data.state === 1) {
3876
             var information = response.data.data.information
3878
             var information = response.data.data.information
3877
-            // console.log('产讯使用登记', information)
3879
+             console.log('产讯使用登记', information)
3878
             // eslint-disable-next-line no-unused-vars
3880
             // eslint-disable-next-line no-unused-vars
3879
             var role = response.data.data.role
3881
             var role = response.data.data.role
3880
             // console.log('role', role)
3882
             // console.log('role', role)
3936
             this.userform.machine_run = information.machine_run
3938
             this.userform.machine_run = information.machine_run
3937
             this.userform.fluid_path = information.fluid_path
3939
             this.userform.fluid_path = information.fluid_path
3938
             this.userform.disinfectant = information.disinfectant
3940
             this.userform.disinfectant = information.disinfectant
3939
-            this.userform.disinfectant = information.disinfection_status
3941
+            this.userform.disinfection_status = information.disinfection_status
3940
             this.userform.disinfection_residue = information.disinfection_residue
3942
             this.userform.disinfection_residue = information.disinfection_residue
3941
             this.userform.longtime = information.long_time
3943
             this.userform.longtime = information.long_time
3942
             this.userform.starttime = this.updateTimes(information.disinfec_startime)
3944
             this.userform.starttime = this.updateTimes(information.disinfec_startime)
4386
             }
4388
             }
4387
 
4389
 
4388
             var timeDataThree = response.data.data.timeDataThree
4390
             var timeDataThree = response.data.data.timeDataThree
4389
-            console.log('timeDataThree', timeDataThree)
4391
+            //console.log('timeDataThree', timeDataThree)
4390
             if (timeDataThree.length === 0) {
4392
             if (timeDataThree.length === 0) {
4391
               this.warnShowThree = true
4393
               this.warnShowThree = true
4392
             }
4394
             }
4410
       getAllMode() {
4412
       getAllMode() {
4411
         getAllMode().then(response => {
4413
         getAllMode().then(response => {
4412
           var mode = response.data.data.mode
4414
           var mode = response.data.data.mode
4415
+
4413
           this.deviceMode = mode
4416
           this.deviceMode = mode
4414
         })
4417
         })
4415
       },
4418
       },

+ 0 - 1
src/xt_pages/role/admin.vue Visa fil

176
   },
176
   },
177
   created: function() {
177
   created: function() {
178
     this.local_user_id = this.$store.getters.xt_user.user.id
178
     this.local_user_id = this.$store.getters.xt_user.user.id
179
-    this.local_user_id = 597
180
     let page = 1
179
     let page = 1
181
     this.getRoles(page)
180
     this.getRoles(page)
182
     adminMainView()
181
     adminMainView()

+ 16 - 17
src/xt_pages/role/components/AdminInfoForm.vue Visa fil

177
                   }
177
                   }
178
                 }
178
                 }
179
 
179
 
180
-
181
-
182
-
183
-
184
-
185
-
186
-                // if (this.roles.length > 0) {
187
-                //   this.form.role = this.roles[0].id;
188
-                //   console.log("国庆快乐",this.form.role)
189
-                // }
190
               } else {
180
               } else {
191
                 this.$message.error(resp.msg)
181
                 this.$message.error(resp.msg)
192
               }
182
               }
228
                 this.form.intro = admin.intro
218
                 this.form.intro = admin.intro
229
                 this.form.user_title_name = admin.user_title_name
219
                 this.form.user_title_name = admin.user_title_name
230
 
220
 
231
-
221
+                this.isSubSuperAdmin = resp.data.isSubSuperAdmin
222
+                this.org = resp.data.org
232
 
223
 
233
                 //如果当前用户是超级管理员而且编辑自己的信息
224
                 //如果当前用户是超级管理员而且编辑自己的信息
234
-                if(this.isSubSuperAdmin || this.admin_id == org.creator){
235
-                  for (let i =0 ; i < this.roles.length; i++){
236
-                    if(this.roles[i].is_system == 1 && this.roles[i].role_name == "子管理员"){
225
+
226
+                if(!this.isSubSuperAdmin) {
227
+                  if (this.form.id == org.creator) {
228
+                    for (let i = 0; i < this.roles.length; i++) {
229
+                      if (this.roles[i].is_system == 1 && this.roles[i].name == "子管理员") {
230
+                        this.roles.splice(i, 1)
231
+                        i--
232
+                      }
233
+                    }
234
+                  }
235
+                }else{
236
+                  for (let i = 0; i < this.roles.length; i++) {
237
+                    if (this.roles[i].is_system == 1 && this.roles[i].name == "子管理员") {
237
                       this.roles.splice(i, 1)
238
                       this.roles.splice(i, 1)
238
                       i--
239
                       i--
239
                     }
240
                     }
240
                   }
241
                   }
241
-                }
242
-
243
-
244
 
242
 
243
+                }
245
 
244
 
246
               } else {
245
               } else {
247
                 this.$message.error('该用户不存在')
246
                 this.$message.error('该用户不存在')

+ 2 - 2
src/xt_pages/role/components/AdminRoleInfoForm.vue Visa fil

129
           return
129
           return
130
         }
130
         }
131
         let local_user_id = this.$store.getters.xt_user.user.id
131
         let local_user_id = this.$store.getters.xt_user.user.id
132
-        local_user_id = 597
133
         this.form.id = this.admin_id
132
         this.form.id = this.admin_id
134
         this.formTitle = '编辑用户'
133
         this.formTitle = '编辑用户'
135
         getModifyAdminInitData(this.form.id)
134
         getModifyAdminInitData(this.form.id)
206
                     }, 500)
205
                     }, 500)
207
 
206
 
208
                     this.$emit('did-edit-admin')
207
                     this.$emit('did-edit-admin')
208
+                    this.$refs.form.resetFields();
209
 
209
 
210
                   } else {
210
                   } else {
211
                     this.$message.error(resp.msg)
211
                     this.$message.error(resp.msg)
231
                   this.loading = false
231
                   this.loading = false
232
                   var resp = rs.data
232
                   var resp = rs.data
233
                   if (resp.state === 1) {
233
                   if (resp.state === 1) {
234
-                   console.log("11111111")
235
                     this.$emit('did-edit-admin')
234
                     this.$emit('did-edit-admin')
235
+                    this.$refs.form.resetFields();
236
 
236
 
237
                   } else {
237
                   } else {
238
                     this.$message.error(resp.msg)
238
                     this.$message.error(resp.msg)

+ 60 - 14
src/xt_pages/role/components/EditRole.vue Visa fil

121
 </template>
121
 </template>
122
 
122
 
123
 <script>
123
 <script>
124
-  import { addRole, AddUserRole, getStaffsList, modifyRole } from '@/api/role/role'
124
+  import { addRole, AddUserRole, getStaffsList, modifyRole,getRoleInfo } from '@/api/role/role'
125
   import { addAdmin, getAddAdminInitData, getModifyAdminInitData, modifyAdmin } from '@/api/role/admin'
125
   import { addAdmin, getAddAdminInitData, getModifyAdminInitData, modifyAdmin } from '@/api/role/admin'
126
 
126
 
127
   export default {
127
   export default {
146
       }
146
       }
147
 
147
 
148
       return {
148
       return {
149
+        org:null,
149
         submitLoading:false,
150
         submitLoading:false,
150
         loading:true,
151
         loading:true,
152
+        local_user_id:0,
151
         form: {
153
         form: {
152
           id: 0,
154
           id: 0,
153
           name: '',
155
           name: '',
253
 
255
 
254
       },
256
       },
255
       change(val) {
257
       change(val) {
256
-
257
         if (this.checkedCities.length == this.admin_user.length) {
258
         if (this.checkedCities.length == this.admin_user.length) {
258
-
259
           this.checkAll = true
259
           this.checkAll = true
260
         } else {
260
         } else {
261
           this.checkAll = false
261
           this.checkAll = false
262
-
263
         }
262
         }
264
-
265
-      }
266
-
267
-      ,
263
+      },
268
       GetAllStaff: function() {
264
       GetAllStaff: function() {
269
         getStaffsList()
265
         getStaffsList()
270
           .then(rs => {
266
           .then(rs => {
271
             var resp = rs.data
267
             var resp = rs.data
272
             if (resp.state === 1) {
268
             if (resp.state === 1) {
273
               this.admin_user = resp.data.admins
269
               this.admin_user = resp.data.admins
270
+              this.org = resp.data.org
271
+              this.isSubSuperAdmin = resp.data.isSubSuperAdmin;
272
+
274
               for (let i = 0; i < this.admin_user.length; i++) {
273
               for (let i = 0; i < this.admin_user.length; i++) {
275
                 if (this.admin_user[i].role_ids.length > 0) {
274
                 if (this.admin_user[i].role_ids.length > 0) {
276
                   let isExist = -1
275
                   let isExist = -1
283
                   }
282
                   }
284
                 }
283
                 }
285
               }
284
               }
285
+              console.log(this.admin_user)
286
+
287
+
286
               for (let i = 0; i < this.admin_user.length; i++) {
288
               for (let i = 0; i < this.admin_user.length; i++) {
287
-                if (this.admin_user[i].user_id == resp.data.org.creator) {
289
+                if (this.isSubSuperAdmin) { //如果当前用户是子管理员,则将管理员剔除到待添加员工列表
290
+                  console.log(this.admin_user[i].user_id)
291
+                  console.log(this.org.creator)
288
 
292
 
289
-                  this.admin_user.splice(i, 1)
290
-                  i = i - 1
293
+                  if (this.admin_user[i].user_id == this.org.creator) {
294
+                    this.admin_user.splice(i, 1);
295
+                    i = i - 1;
296
+                  } else {
297
+                    if (this.admin_user[i].is_sub_admin && this.admin_user[i].user_id != this.local_user_id) {
298
+                      this.admin_user.splice(i, 1);
299
+                      i = i - 1;
300
+                    }
301
+                  }
302
+                } else { //如果当前用户是超级管理员,而且当前编辑角色是子管理员的话,需要将超级管理员剔除到待添加员工列表
303
+                  if (this.role.name == "子管理员" && this.role.is_system == 1) {
304
+                    if (this.admin_user[i].user_id == this.org.creator) {
305
+                      this.admin_user.splice(i, 1);
306
+                      i = i - 1;
307
+                    }
308
+                  }
291
                 }
309
                 }
292
               }
310
               }
311
+
312
+
313
+
293
               this.loading = false
314
               this.loading = false
294
 
315
 
295
             } else {
316
             } else {
321
         this.admin_user = []
342
         this.admin_user = []
322
         this.is_check_admin_user = []
343
         this.is_check_admin_user = []
323
         this.checkedCities = []
344
         this.checkedCities = []
324
-        this.GetAllStaff()
325
-      },
326
-      hide() {
345
+        this.local_user_id = this.$store.getters.xt_user.user.id
346
+
347
+        this.getRoleInfo(role_id)
348
+      },getRoleInfo(id){
349
+        let params = {
350
+          role_id: id
351
+        }
352
+        getRoleInfo(params)
353
+          .then(rs => {
354
+            var resp = rs.data
355
+            if (resp.state === 1) {
356
+              this.role = resp.data.role
357
+              this.loading = true
358
+              this.GetAllStaff()
359
+
360
+
361
+            } else {
362
+              this.$message.error(resp.msg)
363
+
364
+            }
365
+          })
366
+          .catch(err => {
367
+            this.$message.error(err)
368
+          })
369
+
370
+
371
+
372
+      }, hide() {
327
         this.clear()
373
         this.clear()
328
         this.visible = false
374
         this.visible = false
329
       },
375
       },

+ 44 - 4
src/xt_pages/role/components/UserManagement.vue Visa fil

38
           <template slot-scope="scope" style="text-align: center">
38
           <template slot-scope="scope" style="text-align: center">
39
             <el-tooltip class="item" effect="dark" content="编辑" placement="top">
39
             <el-tooltip class="item" effect="dark" content="编辑" placement="top">
40
               <el-button  type="primary" icon="el-icon-edit-outline" size="small"
40
               <el-button  type="primary" icon="el-icon-edit-outline" size="small"
41
-                         v-if="org.creator != scope.row.user_id && (scope.row.user_id != local_user_id) && !scope.row.is_sub_super_admin"
41
+                         v-if="isShow(scope.row.is_sub_super_admin,scope.row.user_id)"
42
                          @click="openForm(scope.row.user_id, role_id)" ></el-button>
42
                          @click="openForm(scope.row.user_id, role_id)" ></el-button>
43
             </el-tooltip>
43
             </el-tooltip>
44
 
44
 
52
                 type="danger"
52
                 type="danger"
53
                 size="small"
53
                 size="small"
54
                 icon="el-icon-delete"
54
                 icon="el-icon-delete"
55
-                v-if="scope.row.status == 1 && org.creator != scope.row.user_id && (scope.row.user_id != local_user_id) && !scope.row.is_sub_super_admin"
55
+                v-if="scope.row.status == 1 && isShowDel(scope.row.is_sub_super_admin, scope.row.user_id) "
56
                 @click="disableAdminAction(scope.row)"
56
                 @click="disableAdminAction(scope.row)"
57
               ></el-button>
57
               ></el-button>
58
             </el-tooltip>
58
             </el-tooltip>
67
                 size="small"
67
                 size="small"
68
                 type="info"
68
                 type="info"
69
                 icon="el-icon-refresh"
69
                 icon="el-icon-refresh"
70
-                v-if="scope.row.status == 0 && org.creator != scope.row.user_id  && (scope.row.user_id != local_user_id ) && !scope.row.is_sub_super_admin"
70
+                v-if="scope.row.status == 0 && isShowDel(scope.row.is_sub_super_admin, scope.row.user_id)"
71
                 @click="recoverAdminAction(scope.row)"
71
                 @click="recoverAdminAction(scope.row)"
72
               ></el-button>
72
               ></el-button>
73
             </el-tooltip>
73
             </el-tooltip>
100
         local_user_id: 0,
100
         local_user_id: 0,
101
         org:null,
101
         org:null,
102
         loading:false,
102
         loading:false,
103
+        isSubSuperAdmin:false,
103
 
104
 
104
       }
105
       }
105
     },
106
     },
106
     methods: {
107
     methods: {
108
+      isShowDel:function(is_sub_admin,user_id){
109
+        if(this.isSubSuperAdmin){ //子管理员
110
+          if(is_sub_admin){ //当前操作的用户是否为子管理员
111
+            return false
112
+          }else{
113
+            if(this.org.creator != user_id){
114
+              return true
115
+            }else{
116
+              return false
117
+            }
118
+          }
119
+        }else{ //超级管理员
120
+          if(this.org.creator == user_id){
121
+            return false
122
+          }else{
123
+            return true
124
+          }
125
+        }
126
+      },
127
+      isShow:function(is_sub_admin,user_id){
128
+        if (!this.isSubSuperAdmin){
129
+          return true
130
+        }else {
131
+          if (is_sub_admin) {
132
+            if (user_id == this.local_user_id) {
133
+              return true
134
+            }else{
135
+              return false
136
+            }
137
+          } else {
138
+            if (user_id != this.org.creator) {
139
+              return true
140
+            } else {
141
+              return false
142
+            }
143
+          }
144
+        }
145
+      },
146
+
107
       didModifyAdmin(){
147
       didModifyAdmin(){
108
         this.GetAllStaff()
148
         this.GetAllStaff()
109
         this.$refs["admininfoform"].close();
149
         this.$refs["admininfoform"].close();
184
           if (response.data.state === 1) {
224
           if (response.data.state === 1) {
185
             this.admin_user = response.data.data.admins
225
             this.admin_user = response.data.data.admins
186
             this.org = response.data.data.org
226
             this.org = response.data.data.org
227
+            this.isSubSuperAdmin = response.data.data.isSubSuperAdmin
187
 
228
 
188
             for (let i = 0; i < this.admin_user.length; i++) {
229
             for (let i = 0; i < this.admin_user.length; i++) {
189
               if (this.admin_user[i].role_ids.length > 0) {
230
               if (this.admin_user[i].role_ids.length > 0) {
213
         this.role_id = role_id
254
         this.role_id = role_id
214
         this.admin_user = []
255
         this.admin_user = []
215
         this.local_user_id = this.$store.getters.xt_user.user.id
256
         this.local_user_id = this.$store.getters.xt_user.user.id
216
-        this.local_user_id = 597
217
         this.GetAllStaff()
257
         this.GetAllStaff()
218
       }
258
       }
219
     }
259
     }

+ 1 - 1
src/xt_pages/sign/index.vue Visa fil

154
         id: '',
154
         id: '',
155
         weight_before: '', // 透前体重
155
         weight_before: '', // 透前体重
156
         temperature: '', // 体温
156
         temperature: '', // 体温
157
-        pulse_frequency: '', // 脉搏
157
+        pulse_frequency: '',
158
         breathing_rate: '', // 呼吸频率
158
         breathing_rate: '', // 呼吸频率
159
         dry_weight: '', // 干体重
159
         dry_weight: '', // 干体重
160
         systolic_blood_pressure: '', // 收缩压
160
         systolic_blood_pressure: '', // 收缩压

+ 161 - 172
src/xt_pages/user/dialysisSolution.vue Visa fil

1
 <template>
1
 <template>
2
   <div class="patient-container">
2
   <div class="patient-container">
3
-   <patient-sidebar :id="patientID" defaultActive="2-1"></patient-sidebar>
4
-   <div class="patient-app-container app-container">
5
-    <div class="Total">
6
-      <!-- <div class="plan" >透析计划</div> -->
7
-      <!-- <table-title title="长期透析处方"></table-title> -->
8
-      <div class="sum">
9
-        <!-- <span>透析总频率:<el-input :value="totalrate" disabled style="width:180px"></el-input></span> -->
10
-        <el-button type="primary" size="small" icon="el-icon-plus"  @click="openNew" :disabled="$store.getters.xt_user.subscibe.state==3?true:false">新增透析处方</el-button>
3
+    <patient-sidebar :id="patientID" defaultActive="2-1"></patient-sidebar>
4
+    <div class="patient-app-container app-container">
5
+      <div class="Total">
6
+        <!-- <div class="plan" >透析计划</div> -->
7
+        <!-- <table-title title="长期透析处方"></table-title> -->
8
+        <div class="sum">
9
+          <!-- <span>透析总频率:<el-input :value="totalrate" disabled style="width:180px"></el-input></span> -->
10
+          <el-button type="primary" size="small" icon="el-icon-plus" @click="openNew"
11
+                     :disabled="$store.getters.xt_user.subscibe.state==3?true:false">新增透析处方
12
+          </el-button>
13
+        </div>
11
       </div>
14
       </div>
12
-    </div>
13
-    <el-table ref="solutionTable" :data="tableData" border fit highlight-current-row
14
-     @current-change="tableCurrentChange" :header-cell-style="{
15
+      <el-table ref="solutionTable" :data="tableData" border fit highlight-current-row
16
+                @current-change="tableCurrentChange" :header-cell-style="{
15
                   backgroundColor: 'rgb(245, 247, 250)',
17
                   backgroundColor: 'rgb(245, 247, 250)',
16
                   color: '#606266'
18
                   color: '#606266'
17
                 }"
19
                 }"
18
                 :row-style="{ color: '#303133' }"
20
                 :row-style="{ color: '#303133' }"
19
-     style="width: 100%">
20
-      <el-table-column
21
-        type="index"
22
-        align="center"
23
-        label="序号"
24
-        width="60">
25
-      </el-table-column>
26
-       <el-table-column
27
-        prop="mode_name"
28
-        align="center"
29
-        label="透析模式"
30
-        min-width="50">
31
-        <template slot-scope="scope" >
32
-          {{modeOptions[scope.row.mode_id].name}}
33
-        </template>
34
-      </el-table-column>
35
-       <el-table-column
36
-        prop="dialysis_duration"
37
-        align="center"
38
-        label="透析时长"
39
-        min-width="50">
40
-        <template slot-scope="scope" >
41
-          {{scope.row.dialysis_duration_hour}} 小时 {{scope.row.dialysis_duration_minute}} 分钟
42
-        </template>
43
-      </el-table-column>
44
-      <!-- <el-table-column
45
-        prop="period"
46
-        label="频率"
47
-        align="center"
48
-        min-width="50">
49
-        <template slot-scope="scope" >
50
-            <span v-if="scope.row.parent_id === 0" >{{scope.row.period}}{{scope.row.times}}</span>
51
-            <span v-else >--</span>
52
-        </template>
53
-      </el-table-column> -->
54
-      <!-- <el-table-column
55
-        prop="name"
56
-        label="处方名"
57
-        align="center"
58
-        min-width="50">
59
-        <template slot-scope="scope" >
60
-            <span >{{scope.row.name}}{{scope.row.sub_name}}</span>
61
-        </template>
62
-      </el-table-column> -->
63
-      <el-table-column
64
-        prop="doctor"
65
-        label="医生"
66
-        align="center"
67
-        min-width="110">
68
-        <template slot-scope="scope" >
69
-            <span >{{getAdminUserName(scope.row.registrars_id)}}</span>
70
-        </template>
71
-
72
-     </el-table-column>
21
+                style="width: 100%">
22
+        <el-table-column
23
+          type="index"
24
+          align="center"
25
+          label="序号"
26
+          width="60">
27
+        </el-table-column>
28
+        <el-table-column
29
+          prop="mode_name"
30
+          align="center"
31
+          label="透析模式"
32
+          min-width="50">
33
+          <template slot-scope="scope">
34
+            {{modeOptions[scope.row.mode_id].name}}
35
+          </template>
36
+        </el-table-column>
37
+        <el-table-column
38
+          prop="dialysis_duration"
39
+          align="center"
40
+          label="透析时长"
41
+          min-width="50">
42
+          <template slot-scope="scope">
43
+            {{scope.row.dialysis_duration_hour}} 小时 {{scope.row.dialysis_duration_minute}} 分钟
44
+          </template>
45
+        </el-table-column>
46
+        <!-- <el-table-column
47
+          prop="period"
48
+          label="频率"
49
+          align="center"
50
+          min-width="50">
51
+          <template slot-scope="scope" >
52
+              <span v-if="scope.row.parent_id === 0" >{{scope.row.period}}{{scope.row.times}}</span>
53
+              <span v-else >--</span>
54
+          </template>
55
+        </el-table-column> -->
56
+        <!-- <el-table-column
57
+          prop="name"
58
+          label="处方名"
59
+          align="center"
60
+          min-width="50">
61
+          <template slot-scope="scope" >
62
+              <span >{{scope.row.name}}{{scope.row.sub_name}}</span>
63
+          </template>
64
+        </el-table-column> -->
65
+        <el-table-column
66
+          prop="doctor"
67
+          label="医生"
68
+          align="center"
69
+          min-width="110">
70
+          <template slot-scope="scope">
71
+            <span>{{getAdminUserName(scope.row.registrars_id)}}</span>
72
+          </template>
73
+
74
+        </el-table-column>
73
 
75
 
74
         <el-table-column
76
         <el-table-column
75
           prop="updated_time"
77
           prop="updated_time"
189
             </el-form-item>
191
             </el-form-item>
190
           </el-col>
192
           </el-col>
191
           <!--<el-col :span="8" v-if="isShows('目标超滤量')&&this.$store.getters.xt_user.template_info.template_id == 6">-->
193
           <!--<el-col :span="8" v-if="isShows('目标超滤量')&&this.$store.getters.xt_user.template_info.template_id == 6">-->
192
-            <!--<el-form-item label="目标超滤量(ml) : ">-->
193
-              <!--<el-input v-model="addPlan.target_ultrafiltration" type="number"></el-input>-->
194
-            <!--</el-form-item>-->
194
+          <!--<el-form-item label="目标超滤量(ml) : ">-->
195
+          <!--<el-input v-model="addPlan.target_ultrafiltration" type="number"></el-input>-->
196
+          <!--</el-form-item>-->
195
           <!--</el-col>-->
197
           <!--</el-col>-->
196
 
198
 
197
           <!--<el-col :span="8" v-if="isShows('目标超滤量')&&this.$store.getters.xt_user.template_info.template_id != 6">-->
199
           <!--<el-col :span="8" v-if="isShows('目标超滤量')&&this.$store.getters.xt_user.template_info.template_id != 6">-->
198
-            <!--<el-form-item label="目标超滤量(L) : ">-->
199
-              <!--<el-input v-model="addPlan.target_ultrafiltration" type="number"></el-input>-->
200
-            <!--</el-form-item>-->
200
+          <!--<el-form-item label="目标超滤量(L) : ">-->
201
+          <!--<el-input v-model="addPlan.target_ultrafiltration" type="number"></el-input>-->
202
+          <!--</el-form-item>-->
201
           <!--</el-col>-->
203
           <!--</el-col>-->
202
 
204
 
203
 
205
 
204
           <el-col :span="8" v-if="isShows('透析液配方')">
206
           <el-col :span="8" v-if="isShows('透析液配方')">
205
-            <el-form-item label="透析液配方:" >
207
+            <el-form-item label="透析液配方:">
206
               <el-select v-model="addPlan.dialysate_formulation">
208
               <el-select v-model="addPlan.dialysate_formulation">
207
                 <el-option v-for="item in dialysate_formulation" :label="item.name" :key="item.id"
209
                 <el-option v-for="item in dialysate_formulation" :label="item.name" :key="item.id"
208
                            :value="item.id"></el-option>
210
                            :value="item.id"></el-option>
259
             </el-form-item>
261
             </el-form-item>
260
           </el-col>
262
           </el-col>
261
           <el-col :span="8" v-if="anticoagulant.gaijiliang != -1&&isShows('钙剂量')">
263
           <el-col :span="8" v-if="anticoagulant.gaijiliang != -1&&isShows('钙剂量')">
262
-            <el-form-item  :label="'钙剂量('+anticoagulant.gaimingcheng_unit+'): '"  prop="anticoagulant_gaijiliang">
264
+            <el-form-item :label="'钙剂量('+anticoagulant.gaimingcheng_unit+'): '" prop="anticoagulant_gaijiliang">
263
               <el-input v-model="addPlan.anticoagulant_gaijiliang" :disabled="anticoagulant.gaijiliang==1?false:true"
265
               <el-input v-model="addPlan.anticoagulant_gaijiliang" :disabled="anticoagulant.gaijiliang==1?false:true"
264
                         placeholder="钙剂量"></el-input>
266
                         placeholder="钙剂量"></el-input>
265
             </el-form-item>
267
             </el-form-item>
359
 
361
 
360
 
362
 
361
           <el-col :span="8">
363
           <el-col :span="8">
362
-            <el-form-item label="置换液:" v-if="isShows('置换液')&&this.$store.getters.xt_user.template_info.template_id != 6">
364
+            <el-form-item label="置换液:"
365
+                          v-if="isShows('置换液')&&this.$store.getters.xt_user.template_info.template_id != 6">
363
               <el-select v-model="addPlan.displace_liqui_part" placeholder="请选择">
366
               <el-select v-model="addPlan.displace_liqui_part" placeholder="请选择">
364
                 <el-option :key="0" label="请选择" :value="0"></el-option>
367
                 <el-option :key="0" label="请选择" :value="0"></el-option>
365
                 <el-option v-for="(option, index) in displace_liqui_part_option" :key="index"
368
                 <el-option v-for="(option, index) in displace_liqui_part_option" :key="index"
368
             </el-form-item>
371
             </el-form-item>
369
 
372
 
370
 
373
 
371
-            <el-form-item label="置换方式:" v-if="isShows('置换液')&&this.$store.getters.xt_user.template_info.template_id == 6">
374
+            <el-form-item label="置换方式:"
375
+                          v-if="isShows('置换液')&&this.$store.getters.xt_user.template_info.template_id == 6">
372
               <el-select v-model="addPlan.displace_liqui_part" placeholder="请选择">
376
               <el-select v-model="addPlan.displace_liqui_part" placeholder="请选择">
373
                 <el-option :key="0" label="请选择" :value="0"></el-option>
377
                 <el-option :key="0" label="请选择" :value="0"></el-option>
374
                 <el-option v-for="(option, index) in displace_liqui_part_option" :key="index"
378
                 <el-option v-for="(option, index) in displace_liqui_part_option" :key="index"
454
     fetchPatientDialysisSolutions
458
     fetchPatientDialysisSolutions
455
   } from '@/api/patient'
459
   } from '@/api/patient'
456
 
460
 
457
-  import {
458
-    getSystemPrescription,
459
-  } from '@/api/config'
460
-
461
-
462
-
461
+  import { getSystemPrescription } from '@/api/config'
463
 
462
 
464
   import { calculateAnticoagulantZL, uParseTime } from '@/utils/tools'
463
   import { calculateAnticoagulantZL, uParseTime } from '@/utils/tools'
465
   import store from '@/store'
464
   import store from '@/store'
537
           id: 0,
536
           id: 0,
538
           mode: '',
537
           mode: '',
539
           mode_name: '',
538
           mode_name: '',
539
+          registrars_id: 0,
540
           dialyzer: '',
540
           dialyzer: '',
541
           dialysis_duration: '',
541
           dialysis_duration: '',
542
           dialysis_duration_hour: '',
542
           dialysis_duration_hour: '',
564
           dialysate_temperature: '',
564
           dialysate_temperature: '',
565
           conductivity: '',
565
           conductivity: '',
566
           doctor: '',
566
           doctor: '',
567
-          dialysate_formulation:'',
567
+          dialysate_formulation: '',
568
           remark: '',
568
           remark: '',
569
-          target_ktv:'',
570
-          target_ultrafiltration:'',
569
+          target_ktv: '',
570
+          target_ultrafiltration: '',
571
           dialyzer_perfusion_apparatus: '',
571
           dialyzer_perfusion_apparatus: '',
572
           body_fluid: '',
572
           body_fluid: '',
573
           body_fluid_other: '',
573
           body_fluid_other: '',
576
           displace_liqui_part: '',
576
           displace_liqui_part: '',
577
           displace_liqui_value: '',
577
           displace_liqui_value: '',
578
           ultrafiltration: '',
578
           ultrafiltration: '',
579
-          blood_access: '',
579
+          blood_access: ''
580
         },
580
         },
581
         childPlan: {
581
         childPlan: {
582
           mode: '',
582
           mode: '',
701
       }
701
       }
702
     },
702
     },
703
     watch: {
703
     watch: {
704
-      "addPlan.dialysis_duration":function(){
705
-        this.addPlan.anticoagulant_zongliang=calculateAnticoagulantZL(1,
704
+      'addPlan.dialysis_duration': function() {
705
+        this.addPlan.anticoagulant_zongliang = calculateAnticoagulantZL(1,
706
           this.addPlan.anticoagulant_shouji,
706
           this.addPlan.anticoagulant_shouji,
707
           this.addPlan.dialysis_duration,
707
           this.addPlan.dialysis_duration,
708
           this.addPlan.anticoagulant_weichi
708
           this.addPlan.anticoagulant_weichi
709
-        );
709
+        )
710
       },
710
       },
711
-      "addPlan.anticoagulant_shouji":function(){
712
-        this.addPlan.anticoagulant_zongliang=calculateAnticoagulantZL(1,
711
+      'addPlan.anticoagulant_shouji': function() {
712
+        this.addPlan.anticoagulant_zongliang = calculateAnticoagulantZL(1,
713
           this.addPlan.anticoagulant_shouji,
713
           this.addPlan.anticoagulant_shouji,
714
           this.addPlan.dialysis_duration,
714
           this.addPlan.dialysis_duration,
715
           this.addPlan.anticoagulant_weichi
715
           this.addPlan.anticoagulant_weichi
716
-        );
716
+        )
717
       },
717
       },
718
-      "addPlan.anticoagulant_weichi":function(){
719
-        this.addPlan.anticoagulant_zongliang=calculateAnticoagulantZL(1,
718
+      'addPlan.anticoagulant_weichi': function() {
719
+        this.addPlan.anticoagulant_zongliang = calculateAnticoagulantZL(1,
720
           this.addPlan.anticoagulant_shouji,
720
           this.addPlan.anticoagulant_shouji,
721
           this.addPlan.dialysis_duration,
721
           this.addPlan.dialysis_duration,
722
           this.addPlan.anticoagulant_weichi
722
           this.addPlan.anticoagulant_weichi
723
-        );
723
+        )
724
       }
724
       }
725
     },
725
     },
726
     components: {
726
     components: {
966
       submitEditSolution(formName) {
966
       submitEditSolution(formName) {
967
         this.$refs[formName].validate(valid => {
967
         this.$refs[formName].validate(valid => {
968
           if (valid) {
968
           if (valid) {
969
-            editPatientDialysisSolution(this.patientID, this.addPlan.id, this.addPlan).then(response => {
969
+
970
+            let mode = '2'
971
+
972
+            if (this.addPlan.registrars_id != this.$store.getters.xt_user.user.id) {
973
+              mode = '3'
974
+            }
975
+
976
+            editPatientDialysisSolution(this.patientID, this.addPlan.id, this.addPlan, mode).then(response => {
970
               if (response.data.state == 0) {
977
               if (response.data.state == 0) {
971
                 this.$message.error(response.data.msg)
978
                 this.$message.error(response.data.msg)
972
                 return false
979
                 return false
1002
         this.addPlan.anticoagulant_zongliang = this.addPlan.anticoagulant_zongliang.toString()
1009
         this.addPlan.anticoagulant_zongliang = this.addPlan.anticoagulant_zongliang.toString()
1003
         this.$refs[formName].validate(valid => {
1010
         this.$refs[formName].validate(valid => {
1004
           if (valid) {
1011
           if (valid) {
1005
-            createPatientDialysisSolution(this.patientID, this.addPlan).then(response => {
1012
+            let mode = '1'
1013
+            createPatientDialysisSolution(this.patientID, this.addPlan, mode).then(response => {
1006
               if (response.data.state == 0) {
1014
               if (response.data.state == 0) {
1007
                 this.$message.error(response.data.msg)
1015
                 this.$message.error(response.data.msg)
1008
                 return false
1016
                 return false
1050
         this.addPlan.dialysis_duration = '' + row.dialysis_duration
1058
         this.addPlan.dialysis_duration = '' + row.dialysis_duration
1051
         this.addPlan.dialysis_duration_hour = '' + row.dialysis_duration_hour
1059
         this.addPlan.dialysis_duration_hour = '' + row.dialysis_duration_hour
1052
         this.addPlan.dialysis_duration_minute = '' + row.dialysis_duration_minute
1060
         this.addPlan.dialysis_duration_minute = '' + row.dialysis_duration_minute
1053
-        this.addPlan.hemodialysis_machine = row.hemodialysis_machine + '';
1054
-        this.addPlan.perfusion_apparatus = row.perfusion_apparatus + '';
1055
-        this.addPlan.blood_flow_volume = row.blood_flow_volume.toString();
1056
-        this.addPlan.anticoagulant = row.anticoagulant;
1057
-        this.addPlan.replacement_total = row.replacement_total;
1058
-
1059
-        this.addPlan.target_ktv = row.target_ktv.toString();
1060
-        this.addPlan.target_ultrafiltration = row.target_ultrafiltration.toString();
1061
-
1062
-
1063
-        this.addPlan.anticoagulant_shouji = row.anticoagulant_shouji.toString();
1064
-        this.addPlan.anticoagulant_weichi = row.anticoagulant_weichi.toString();
1065
-        this.addPlan.anticoagulant_zongliang = row.anticoagulant_zongliang.toString();
1066
-        this.addPlan.anticoagulant_gaimingcheng = row.anticoagulant_gaimingcheng.toString();
1067
-        this.addPlan.anticoagulant_gaijiliang = row.anticoagulant_gaijiliang.toString();
1068
-        this.addPlan.kalium = row.kalium.toString();
1069
-        this.addPlan.sodium = row.sodium.toString();
1070
-        this.addPlan.calcium = row.calcium.toString();
1071
-        this.addPlan.bicarbonate = row.bicarbonate.toString();
1072
-        this.addPlan.glucose = row.glucose.toString();
1073
-        this.addPlan.dialysate_flow = row.dialysate_flow.toString();
1074
-        this.addPlan.dialysate_temperature = row.dialysate_temperature.toString();
1075
-        this.addPlan.conductivity = row.conductivity.toString();
1076
-        this.addPlan.remark = row.remark;
1077
-
1078
-
1079
-        this.addPlan.dialyzer_perfusion_apparatus = row.dialyzer_perfusion_apparatus.toString();
1061
+        this.addPlan.hemodialysis_machine = row.hemodialysis_machine + ''
1062
+        this.addPlan.perfusion_apparatus = row.perfusion_apparatus + ''
1063
+        this.addPlan.blood_flow_volume = row.blood_flow_volume.toString()
1064
+        this.addPlan.anticoagulant = row.anticoagulant
1065
+        this.addPlan.replacement_total = row.replacement_total
1066
+
1067
+        this.addPlan.target_ktv = row.target_ktv.toString()
1068
+        this.addPlan.target_ultrafiltration = row.target_ultrafiltration.toString()
1069
+
1070
+        this.addPlan.anticoagulant_shouji = row.anticoagulant_shouji.toString()
1071
+        this.addPlan.anticoagulant_weichi = row.anticoagulant_weichi.toString()
1072
+        this.addPlan.anticoagulant_zongliang = row.anticoagulant_zongliang.toString()
1073
+        this.addPlan.anticoagulant_gaimingcheng = row.anticoagulant_gaimingcheng.toString()
1074
+        this.addPlan.anticoagulant_gaijiliang = row.anticoagulant_gaijiliang.toString()
1075
+        this.addPlan.kalium = row.kalium.toString()
1076
+        this.addPlan.sodium = row.sodium.toString()
1077
+        this.addPlan.calcium = row.calcium.toString()
1078
+        this.addPlan.bicarbonate = row.bicarbonate.toString()
1079
+        this.addPlan.glucose = row.glucose.toString()
1080
+        this.addPlan.dialysate_flow = row.dialysate_flow.toString()
1081
+        this.addPlan.dialysate_temperature = row.dialysate_temperature.toString()
1082
+        this.addPlan.conductivity = row.conductivity.toString()
1083
+        this.addPlan.remark = row.remark
1084
+
1085
+        this.addPlan.dialyzer_perfusion_apparatus = row.dialyzer_perfusion_apparatus.toString()
1080
         this.addPlan.body_fluid = row.body_fluid
1086
         this.addPlan.body_fluid = row.body_fluid
1081
-        this.addPlan.body_fluid_other = row.body_fluid_other.toString();
1082
-        this.addPlan.special_medicine = row.special_medicine;
1083
-        this.addPlan.special_medicine_other = row.special_medicine_other.toString();
1084
-        this.addPlan.displace_liqui_part = row.displace_liqui_part;
1085
-        this.addPlan.displace_liqui_value = row.displace_liqui_value.toString();
1086
-        this.addPlan.ultrafiltration = row.ultrafiltration.toString();
1087
-        this.addPlan.blood_access = row.blood_access;
1087
+        this.addPlan.body_fluid_other = row.body_fluid_other.toString()
1088
+        this.addPlan.special_medicine = row.special_medicine
1089
+        this.addPlan.special_medicine_other = row.special_medicine_other.toString()
1090
+        this.addPlan.displace_liqui_part = row.displace_liqui_part
1091
+        this.addPlan.displace_liqui_value = row.displace_liqui_value.toString()
1092
+        this.addPlan.ultrafiltration = row.ultrafiltration.toString()
1093
+        this.addPlan.blood_access = row.blood_access
1088
 
1094
 
1095
+        this.addPlan.registrars_id = row.registrars_id
1089
 
1096
 
1090
         this.dialogVisible = true
1097
         this.dialogVisible = true
1091
         this.isEdit = true
1098
         this.isEdit = true
1115
           doctor: '',
1122
           doctor: '',
1116
           first_dialysis: '',
1123
           first_dialysis: '',
1117
 
1124
 
1118
-
1119
-
1120
           dialyzer: '',
1125
           dialyzer: '',
1121
-          dialysate_formulation:'',
1126
+          dialysate_formulation: '',
1122
           hemodialysis_machine: '',
1127
           hemodialysis_machine: '',
1123
           perfusion_apparatus: '',
1128
           perfusion_apparatus: '',
1124
           blood_flow_volume: '',
1129
           blood_flow_volume: '',
1142
           dialysate_temperature: '',
1147
           dialysate_temperature: '',
1143
           conductivity: '',
1148
           conductivity: '',
1144
           remark: '',
1149
           remark: '',
1145
-          target_ktv:'',
1146
-          target_ultrafiltration:'',
1150
+          target_ktv: '',
1151
+          target_ultrafiltration: '',
1147
           dialyzer_perfusion_apparatus: '',
1152
           dialyzer_perfusion_apparatus: '',
1148
           body_fluid: '',
1153
           body_fluid: '',
1149
           body_fluid_other: '',
1154
           body_fluid_other: '',
1154
           ultrafiltration: '',
1159
           ultrafiltration: '',
1155
           blood_access: '',
1160
           blood_access: '',
1156
 
1161
 
1157
-
1158
-
1159
-
1160
-
1161
-
1162
-
1163
-
1164
-
1165
           dialysis_duration: '3.30',
1162
           dialysis_duration: '3.30',
1166
           dialysis_duration_hour: '3',
1163
           dialysis_duration_hour: '3',
1167
           dialysis_duration_minute: '30'
1164
           dialysis_duration_minute: '30'
1258
           id: thismode
1255
           id: thismode
1259
         }
1256
         }
1260
 
1257
 
1261
-
1262
-
1263
         getSystemPrescription(params).then(response => {
1258
         getSystemPrescription(params).then(response => {
1264
           if (response.data.state == 1) {
1259
           if (response.data.state == 1) {
1265
-            if(response.data.data.prescription.id > 0) {
1260
+            if (response.data.data.prescription.id > 0) {
1266
               for (const key in  response.data.data.prescription) {
1261
               for (const key in  response.data.data.prescription) {
1267
                 //因为el-input特性整数类型或者浮点数类型需要转换成字符串,所以加上toString()
1262
                 //因为el-input特性整数类型或者浮点数类型需要转换成字符串,所以加上toString()
1268
                 this.$set(this.addPlan, key, response.data.data.prescription[key].toString())
1263
                 this.$set(this.addPlan, key, response.data.data.prescription[key].toString())
1269
               }
1264
               }
1270
 
1265
 
1271
               //因为el-select特性,整数类型不能转字符串,所以额外处理这些数据
1266
               //因为el-select特性,整数类型不能转字符串,所以额外处理这些数据
1272
-              this.$set(this.addPlan, "dialysate_formulation", response.data.data.prescription['dialysate_formulation'])
1273
-              this.$set(this.addPlan, "anticoagulant", response.data.data.prescription['anticoagulant'])
1274
-              this.$set(this.addPlan, "body_fluid", response.data.data.prescription['body_fluid'])
1275
-              this.$set(this.addPlan, "special_medicine", response.data.data.prescription['special_medicine'])
1276
-              this.$set(this.addPlan, "displace_liqui_part", response.data.data.prescription['displace_liqui_part'])
1277
-              this.$set(this.addPlan, "blood_access", response.data.data.prescription['blood_access'])
1278
-
1279
-
1267
+              this.$set(this.addPlan, 'dialysate_formulation', response.data.data.prescription['dialysate_formulation'])
1268
+              this.$set(this.addPlan, 'anticoagulant', response.data.data.prescription['anticoagulant'])
1269
+              this.$set(this.addPlan, 'body_fluid', response.data.data.prescription['body_fluid'])
1270
+              this.$set(this.addPlan, 'special_medicine', response.data.data.prescription['special_medicine'])
1271
+              this.$set(this.addPlan, 'displace_liqui_part', response.data.data.prescription['displace_liqui_part'])
1272
+              this.$set(this.addPlan, 'blood_access', response.data.data.prescription['blood_access'])
1280
 
1273
 
1281
               this.dialysisTimeShow = new Date(2018, 1, 1, this.addPlan.dialysis_duration_hour, this.addPlan.dialysis_duration_minute)
1274
               this.dialysisTimeShow = new Date(2018, 1, 1, this.addPlan.dialysis_duration_hour, this.addPlan.dialysis_duration_minute)
1282
 
1275
 
1283
-            }else{
1276
+            } else {
1284
               var tempAddPlan = {
1277
               var tempAddPlan = {
1285
                 id: 0,
1278
                 id: 0,
1286
                 dialyzer: '',
1279
                 dialyzer: '',
1288
                 dialysis_duration_hour: '',
1281
                 dialysis_duration_hour: '',
1289
                 dialysis_duration_minute: '',
1282
                 dialysis_duration_minute: '',
1290
                 hemodialysis_machine: '',
1283
                 hemodialysis_machine: '',
1291
-                dialysate_formulation:'',
1284
+                dialysate_formulation: '',
1292
                 perfusion_apparatus: '',
1285
                 perfusion_apparatus: '',
1293
                 blood_flow_volume: '',
1286
                 blood_flow_volume: '',
1294
                 dewater: '',
1287
                 dewater: '',
1329
                 this.addPlan[key] = tempAddPlan[key]
1322
                 this.addPlan[key] = tempAddPlan[key]
1330
               }
1323
               }
1331
 
1324
 
1332
-
1333
             }
1325
             }
1334
           }
1326
           }
1335
         })
1327
         })
1385
     },
1377
     },
1386
     created() {
1378
     created() {
1387
 
1379
 
1388
-
1389
-
1390
       const id = this.$route.params && this.$route.params.id
1380
       const id = this.$route.params && this.$route.params.id
1391
       this.patientID = parseInt(id)
1381
       this.patientID = parseInt(id)
1392
       if (isNaN(this.patientID) || this.patientID <= 0) {
1382
       if (isNaN(this.patientID) || this.patientID <= 0) {
1413
       this.displace_liqui_part_option = this.$store.getters.displace_liqui
1403
       this.displace_liqui_part_option = this.$store.getters.displace_liqui
1414
       this.blood_access_option = this.$store.getters.blood_access
1404
       this.blood_access_option = this.$store.getters.blood_access
1415
 
1405
 
1416
-
1417
-
1418
       this.queryParams.id = this.patientID
1406
       this.queryParams.id = this.patientID
1419
       // this.fetchAllDoctorAndNurse();
1407
       // this.fetchAllDoctorAndNurse();
1420
       this.fetchAllAdminUsers()
1408
       this.fetchAllAdminUsers()
1475
   }
1463
   }
1476
 </style>
1464
 </style>
1477
 <style>
1465
 <style>
1478
-.el-table td,
1479
-.el-table th.is-leaf,
1480
-.el-table--border,
1481
-.el-table--group {
1482
-  border-color: #d0d3da;
1483
-}
1484
-.el-table--border::after,
1485
-.el-table--group::after,
1486
-.el-table::before {
1487
-  background-color: #d0d3da;
1488
-}
1466
+  .el-table td,
1467
+  .el-table th.is-leaf,
1468
+  .el-table--border,
1469
+  .el-table--group {
1470
+    border-color: #d0d3da;
1471
+  }
1472
+
1473
+  .el-table--border::after,
1474
+  .el-table--group::after,
1475
+  .el-table::before {
1476
+    background-color: #d0d3da;
1477
+  }
1489
 </style>
1478
 </style>

+ 23 - 16
src/xt_permission.js Visa fil

1
-import router from "./router";
2
-import store from "./store";
3
-import NProgress from "nprogress"; // progress bar
4
-import "nprogress/nprogress.css"; // progress bar style
1
+import router from './router'
2
+import store from './store'
3
+import NProgress from 'nprogress' // progress bar
4
+import 'nprogress/nprogress.css' // progress bar style
5
 
5
 
6
-NProgress.configure({ showSpinner: false }); // NProgress Configuration
6
+NProgress.configure({
7
+  showSpinner: false
8
+}) // NProgress Configuration
7
 
9
 
8
-const loginWhiteList = ["/token/verify", "/401", "/404"]; // 登录验证白名单
9
-const permissionWhiteList = loginWhiteList.concat(["/"]); // 权限验证白名单
10
+const loginWhiteList = ['/token/verify', '/401', '/404'] // 登录验证白名单
11
+const permissionWhiteList = loginWhiteList.concat(['/']) // 权限验证白名单
10
 
12
 
11
 router.beforeEach((to, from, next) => {
13
 router.beforeEach((to, from, next) => {
12
   // 线上注释
14
   // 线上注释
25
   // return
27
   // return
26
   // 线上注释
28
   // 线上注释
27
 
29
 
28
-  NProgress.start();
30
+  NProgress.start()
29
   // console.log(store.getters.current_role_urls.indexOf(to.path))
31
   // console.log(store.getters.current_role_urls.indexOf(to.path))
30
   // alert('path:' + to.path)
32
   // alert('path:' + to.path)
31
   // 如果 url 带有 lt (login_token)参数,则跳转到验证 token 时等待的页面
33
   // 如果 url 带有 lt (login_token)参数,则跳转到验证 token 时等待的页面
32
   if (to.query.lt != null && to.query.lt.length > 0) {
34
   if (to.query.lt != null && to.query.lt.length > 0) {
33
     // alert('will go to verify token: ' + to.query.lt)
35
     // alert('will go to verify token: ' + to.query.lt)
34
-    next({ path: "/token/verify", query: { token: to.query.lt } });
36
+    next({
37
+      path: '/token/verify',
38
+      query: {
39
+        token: to.query.lt
40
+      }
41
+    })
35
 
42
 
36
     // 否则 如果没有 user 信息,则前往 sso 登录
43
     // 否则 如果没有 user 信息,则前往 sso 登录
37
   } else if (store.getters.xt_user.user.id === 0) {
44
   } else if (store.getters.xt_user.user.id === 0) {
38
     if (loginWhiteList.indexOf(to.path) !== -1) {
45
     if (loginWhiteList.indexOf(to.path) !== -1) {
39
       // alert('登录白名单内,跳过登录')
46
       // alert('登录白名单内,跳过登录')
40
-      next();
47
+      next()
41
     } else {
48
     } else {
42
       // alert('前往登录')
49
       // alert('前往登录')
43
-      window.location.href = process.env.BASE_API + "/login"; // sso 地址
50
+      window.location.href = process.env.BASE_API + '/login' // sso 地址
44
     }
51
     }
45
 
52
 
46
     // 否则 如果当前 url 不需要验证访问权限,则通过
53
     // 否则 如果当前 url 不需要验证访问权限,则通过
47
   } else if (permissionWhiteList.indexOf(to.path) !== -1) {
54
   } else if (permissionWhiteList.indexOf(to.path) !== -1) {
48
     // alert('权限验证白名单内,直接进入')
55
     // alert('权限验证白名单内,直接进入')
49
-    next();
56
+    next()
50
 
57
 
51
     // 否则 如果拥有当前 url 的权限,则通过
58
     // 否则 如果拥有当前 url 的权限,则通过
52
     // } else if (store.getters.current_role_urls.indexOf(to.path) !== -1) {
59
     // } else if (store.getters.current_role_urls.indexOf(to.path) !== -1) {
58
     // console.log(store.getters.current_role_urls)
65
     // console.log(store.getters.current_role_urls)
59
     // console.log(store.getters.current_role_urls.indexOf(to.path))
66
     // console.log(store.getters.current_role_urls.indexOf(to.path))
60
     // alert('401')
67
     // alert('401')
61
-    next();
68
+    next()
62
     // next({ path: '/404' })
69
     // next({ path: '/404' })
63
   }
70
   }
64
-});
71
+})
65
 
72
 
66
 router.afterEach(() => {
73
 router.afterEach(() => {
67
-  NProgress.done();
68
-});
74
+  NProgress.done()
75
+})