Browse Source

统计配置开发

XMLWAN 4 years ago
parent
commit
24342831de

+ 13 - 0
src/api/common/common.js View File

@@ -63,6 +63,7 @@ export function getAllInspectionMinor(params) {
63 63
 }
64 64
 
65 65
 export function UpdateConfiguration(id, data) {
66
+  console.log('data', data)
66 67
   return request({
67 68
     url: 'com/api/updateconfiguration?id=' + id,
68 69
     method: 'post',
@@ -130,3 +131,15 @@ export function DeleteCheck(id, params) {
130 131
     params: params
131 132
   })
132 133
 }
134
+
135
+export function getDialysisModeType(startime, endtime) {
136
+  const params = {
137
+    startime: startime,
138
+    endtime: endtime
139
+  }
140
+  return request({
141
+    url: '/com/api/getdialysismodetype',
142
+    method: 'get',
143
+    params: params
144
+  })
145
+}

File diff suppressed because it is too large
+ 1395 - 1410
src/store/modules/globalConfig.js


+ 79 - 21
src/xt_pages/qcd/basicInformationAnalysis.vue View File

@@ -53,27 +53,14 @@
53 53
             <div class="infoOne">
54 54
               <div class="titleBox">
55 55
                 <span class="point"></span>
56
-                <p class="infoTitle">透析总量(100次)</p>
56
+                <p class="infoTitle">透析总量({{total}}次)</p>
57 57
               </div>
58
+            
58 59
               <div class="borderBox">
59
-                <p>HD:64次(64%)</p>
60
-                <el-progress :percentage="70"></el-progress>
61
-                <p>HD:64次(64%)</p>
62
-                <el-progress :percentage="70"></el-progress>
63
-                <p>HD:64次(64%)</p>
64
-                <el-progress :percentage="70"></el-progress>
65
-                <p>HD:64次(64%)</p>
66
-                <el-progress :percentage="70"></el-progress>
67
-                <p>HD:64次(64%)</p>
68
-                <el-progress :percentage="70"></el-progress>
69
-                <p>HD:64次(64%)</p>
70
-                <el-progress :percentage="70"></el-progress>
71
-                <p>HD:64次(64%)</p>
72
-                <el-progress :percentage="70"></el-progress>
73
-                <p>HD:64次(64%)</p>
74
-                <el-progress :percentage="70"></el-progress>
75
-                <p>HD:64次(64%)</p>
60
+               <div v-for="(item,index) in modetype" :key="index">
61
+                <p>{{item.mode_id}}:64次(64%)</p>
76 62
                 <el-progress :percentage="70"></el-progress>
63
+               </div>
77 64
               </div>
78 65
             </div>
79 66
             <div class="infoOne">
@@ -158,10 +145,12 @@
158 145
 
159 146
 
160 147
 <script>
148
+const moment = require('moment')
161 149
 import { GetOICData } from "@/api/qcd";
162 150
 import PieChart from "../qcd/components/BarChart";
163 151
 import { uParseTime } from "@/utils/tools";
164 152
 import BreadCrumb from "@/xt_pages/components/bread-crumb";
153
+import {getDialysisModeType} from "@/api/common/common"
165 154
 export default {
166 155
   name: "dialysisTotal",
167 156
   components: {
@@ -186,10 +175,11 @@ export default {
186 175
         { value: 1, label: "近三个月", state: 1 },
187 176
         { value: 2, label: "近半年", state: 2 },
188 177
         { value: 3, label: "近一年", state: 3 }
189
-      ]
178
+      ],
179
+      modetype:[],
180
+      total:0,
190 181
     };
191 182
   },
192
-  created() {},
193 183
   methods: {
194 184
     changeTime() {},
195 185
     changeEndTime(val) {
@@ -204,8 +194,76 @@ export default {
204 194
     selectLapseTo(state) {
205 195
       this.stateType = state;
206 196
       this.listQuery.state = state;
197
+    },
198
+    getDialysisModeType(startDate,endDate){
199
+      getDialysisModeType(startDate,endDate).then(response=>{
200
+         if(response.data.state == 1){
201
+           var modetype =  response.data.data.modetype
202
+            var total =  response.data.data.total
203
+            console.log("total",total)
204
+            this.total = total
205
+           for(let i=0;i<modetype.length;i++){
206
+             if(modetype[i].mode_id == 1){
207
+               modetype[i].mode_id = "HD"
208
+             }
209
+             if(modetype[i].mode_id == 2){
210
+               modetype[i].mode_id = "HDF"
211
+             }
212
+             if(modetype[i].mode_id == 3){
213
+               modetype[i].mode_id = "HD+HP"
214
+             }
215
+              if(modetype[i].mode_id == 4){
216
+               modetype[i].mode_id = "HP"
217
+             }
218
+              if(modetype[i].mode_id == 5){
219
+               modetype[i].mode_id = "HF"
220
+             }
221
+             if(modetype[i].mode_id == 6){
222
+               modetype[i].mode_id = "SCUF"
223
+             }
224
+             if(modetype[i].mode_id == 7){
225
+               modetype[i].mode_id = "IUF"
226
+             }
227
+              if(modetype[i].mode_id == 8){
228
+               modetype[i].mode_id = "HFHD"
229
+             }
230
+             if(modetype[i].mode_id == 9){
231
+               modetype[i].mode_id = "HFHD+HP"
232
+             }
233
+             if(modetype[i].mode_id == 10){
234
+               modetype[i].mode_id = "PHF"
235
+             }
236
+             if(modetype[i].mode_id == 11){
237
+               modetype[i].mode_id = "HFR"
238
+             }
239
+            if(modetype[i].mode_id == 12){
240
+               modetype[i].mode_id = "HDF+HP"
241
+             }
242
+              if(modetype[i].mode_id == 13){
243
+               modetype[i].mode_id = "HFHD+HP"
244
+             }
245
+              if(modetype[i].mode_id == 14){
246
+               modetype[i].mode_id = "腹水回输"
247
+             }
248
+            if(modetype[i].mode_id == 19){
249
+               modetype[i].mode_id = "IUF+HD"
250
+             }
251
+           }
252
+           this.modetype = modetype
253
+           console.log("modetype",modetype)
254
+           
255
+         }
256
+      })
207 257
     }
208
-  }
258
+  },
259
+  created() {
260
+     //获取本月当前机构的透析模式
261
+      const startDate = moment().subtract('month', 0).format('YYYY-MM') + '-01'
262
+      console.log("开始时间",startDate)
263
+      const endDate = moment(new Date()).format('YYYY-MM-DD')
264
+      console.log("结束时间",endDate)
265
+      this.getDialysisModeType(startDate,endDate)
266
+  },
209 267
 };
210 268
 </script>
211 269
 

+ 13 - 3
src/xt_pages/qcd/checkStatistical.vue View File

@@ -164,6 +164,10 @@ export default {
164 164
            this.editform.id = checkdetail.id
165 165
            this.editform.inspectionMajor = checkdetail.inspection_major
166 166
            this.editform.frequency = checkdetail.inspection_frequency
167
+           if(checkdetail.sort == 0){
168
+             this.editform.sort = ""
169
+             return 
170
+           }
167 171
            this.editform.sort = checkdetail.sort
168 172
          }
169 173
        })
@@ -221,9 +225,15 @@ export default {
221 225
       })
222 226
     },
223 227
     UpdateCheck(formName){
224
-       var sort = this.editform.sort 
225
-       var sorts = parseInt(sort)
226
-       this.editform.sort = sorts
228
+       if(this.editform.sort == ""){
229
+         this.editform.sort = 0
230
+       }
231
+       if(this.editform.sort !=""){
232
+         var sort = this.editform.sort 
233
+         var sorts = parseInt(sort)
234
+         this.editform.sort = sorts
235
+       }
236
+     
227 237
       this.$refs[formName].validate(valid=>{
228 238
         if(valid){
229 239
           UpdateCheck(this.editform.id,this.editform).then(response=>{

+ 15 - 3
src/xt_pages/qcd/statisticalConfiguration.vue View File

@@ -202,6 +202,10 @@ export default {
202 202
            this.editform.inspectionMinor = configurationdetail.inspection_minor
203 203
            this.editform.large_range = configurationdetail.large_range
204 204
            this.editform.min_range = configurationdetail.min_range
205
+           if(configurationdetail.sort == 0){
206
+            this.editform.sort = ""
207
+            return
208
+           }
205 209
            this.editform.sort = configurationdetail.sort
206 210
          }
207 211
       })
@@ -306,9 +310,15 @@ export default {
306 310
       })
307 311
     },
308 312
     EditConfiguration(formName){
309
-       var sorts =  this.editform.sort
310
-       var sort = parseInt(sorts)
311
-       this.editform.sort = sort
313
+       if(this.editform.sort == ""){
314
+         this.editform.sort = 0
315
+       }
316
+       if(this.editform.sort!=""){
317
+        var sorts =  this.editform.sort
318
+        var sort = parseInt(sorts)
319
+        this.editform.sort = sort
320
+       }
321
+     
312 322
       UpdateConfiguration(this.editform.id,this.editform).then(response=>{
313 323
         if(response.data.state == 1){
314 324
          var standard =  response.data.data.standard
@@ -316,6 +326,8 @@ export default {
316 326
          this.$message.success("保存成功")
317 327
          this.editDialog = false
318 328
          this.getConfigurationList()
329
+        }else{
330
+         this.$message.error("检查小项已存在")
319 331
         }
320 332
       })
321 333
     },