Browse Source

统计配置开发

XMLWAN 4 years ago
parent
commit
b4f2f50160
2 changed files with 49 additions and 14 deletions
  1. 12 0
      src/api/common/common.js
  2. 37 14
      src/xt_pages/qcd/basicInformationAnalysis.vue

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

191
     params: params
191
     params: params
192
   })
192
   })
193
 }
193
 }
194
+
195
+export function getTotalDialysisCount(startime, endtime) {
196
+  const params = {
197
+    startime: startime,
198
+    endtime: endtime
199
+  }
200
+  return request({
201
+    url: '/com/api/gettotaldialysiscount',
202
+    method: 'get',
203
+    params: params
204
+  })
205
+}

+ 37 - 14
src/xt_pages/qcd/basicInformationAnalysis.vue View File

111
                 <p class="infoTitle">年龄统计</p>
111
                 <p class="infoTitle">年龄统计</p>
112
               </div>
112
               </div>
113
               <div class="borderBox">
113
               <div class="borderBox">
114
-                <p>年龄≤20:64人(64%)</p>
115
-                <el-progress :percentage="70"></el-progress>
116
-                <p>20<年龄≤40:64人(64%)</p>
117
-                <el-progress :percentage="70"></el-progress>
118
-                <p>30≤年龄≤40:64人(64%)</p>
119
-                <el-progress :percentage="70"></el-progress>
120
-                <p>其他:64人(64%)</p>
121
-                <el-progress :percentage="70"></el-progress>
114
+                <div v-for="(item,j) in ageCount" :key="j">
115
+                    <span v-if="item.age == 20">
116
+                     <p>年龄≤20:{{item.count}}人({{(item.count/ageTotal*100).toFixed(1)}}%)</p>
117
+                     <el-progress :percentage="(item.count/ageTotal*100).toFixed(1)"></el-progress>
118
+                    </span>
119
+                   <span v-if="item.age == 40">
120
+                      <p>20<年龄≤40:{{item.count}}人({{(item.count/ageTotal*100).toFixed(1)}}%)</p>
121
+                      <el-progress :percentage="(item.count/ageTotal*100).toFixed(1)"></el-progress>
122
+                    </span>
123
+                    <span v-if="item.age == 60">
124
+                      <p>40<年龄≤60:{{item.count}}人({{(item.count/ageTotal*100).toFixed(1)}}%)</p>
125
+                      <el-progress :percentage="(item.count/ageTotal*100).toFixed(1)"></el-progress>
126
+                    </span>
127
+                    <span v-if="item.age == 80">
128
+                     <p>60<年龄≤80:{{item.count}}人({{(item.count/ageTotal*100).toFixed(1)}}%)</p>
129
+                     <el-progress :percentage="(item.count/ageTotal*100).toFixed(1)"></el-progress>
130
+                    </span>
131
+                    <span v-if="item.age ==150">
132
+                      <p>大于80:{{item.count}}人({{(item.count/ageTotal*100).toFixed(1)}}%)</p>
133
+                      <el-progress :percentage="(item.count/ageTotal*100).toFixed(1)"></el-progress>
134
+                    </span>
135
+                </div>
122
               </div>
136
               </div>
123
             </div>
137
             </div>
124
             <div class="infoOne">
138
             <div class="infoOne">
127
                 <p class="infoTitle">透龄统计</p>
141
                 <p class="infoTitle">透龄统计</p>
128
               </div>
142
               </div>
129
               <div class="borderBox1">
143
               <div class="borderBox1">
130
-                <p>透析龄&lt;12:64人(64%)</p>
144
+                <p>透析龄12:64人(64%)</p>
131
                 <el-progress :percentage="70"></el-progress>
145
                 <el-progress :percentage="70"></el-progress>
132
-                <p>12透析龄≤36:64人(64%)</p>
146
+                <p>12<透析龄≤36:64人(64%)</p>
133
                 <el-progress :percentage="70"></el-progress>
147
                 <el-progress :percentage="70"></el-progress>
134
                 <p>36≤透析龄≤60:64人(64%)</p>
148
                 <p>36≤透析龄≤60:64人(64%)</p>
135
                 <el-progress :percentage="70"></el-progress>
149
                 <el-progress :percentage="70"></el-progress>
152
 import PieChart from "../qcd/components/BarChart";
166
 import PieChart from "../qcd/components/BarChart";
153
 import { uParseTime } from "@/utils/tools";
167
 import { uParseTime } from "@/utils/tools";
154
 import BreadCrumb from "@/xt_pages/components/bread-crumb";
168
 import BreadCrumb from "@/xt_pages/components/bread-crumb";
155
-import {getDialysisModeType,getTotalLapseCount,getTotalSexCount,getTotalInfectiousCount,getTotalAgeCount} from "@/api/common/common"
169
+import {getDialysisModeType,getTotalLapseCount,getTotalSexCount,getTotalInfectiousCount,getTotalAgeCount,getTotalDialysisCount} from "@/api/common/common"
156
 export default {
170
 export default {
157
   name: "dialysisTotal",
171
   name: "dialysisTotal",
158
   components: {
172
   components: {
188
       totalGender:0,
202
       totalGender:0,
189
       InfectiousList:[],
203
       InfectiousList:[],
190
       InfectiousTotal:0,
204
       InfectiousTotal:0,
205
+      ageCount:[],
206
+      ageTotal:0,
191
     };
207
     };
192
   },
208
   },
193
   methods: {
209
   methods: {
275
       getTotalLapseCount(startDate,endDate).then(response=>{
291
       getTotalLapseCount(startDate,endDate).then(response=>{
276
          if(response.data.state == 1){
292
          if(response.data.state == 1){
277
           var patients =  response.data.data.patients
293
           var patients =  response.data.data.patients
278
-          
279
           var total = response.data.data.total
294
           var total = response.data.data.total
280
           this.rollOut = total
295
           this.rollOut = total
281
-         
282
           var count = response.data.data.count
296
           var count = response.data.data.count
283
-        
284
           this.patientCount = count
297
           this.patientCount = count
285
           this.RetentionCount = count-total
298
           this.RetentionCount = count-total
286
          }
299
          }
330
       getTotalAgeCount(timeStar,timeEnd).then(response=>{
343
       getTotalAgeCount(timeStar,timeEnd).then(response=>{
331
          if(response.data.state == 1){
344
          if(response.data.state == 1){
332
           var ageCount =  response.data.data.ageCount
345
           var ageCount =  response.data.data.ageCount
346
+          this.ageCount = ageCount
333
           console.log("ageCount",ageCount)
347
           console.log("ageCount",ageCount)
348
+          this.ageTotal =  response.data.data.total
349
+         // var two = response.data.data.two
350
+        //  console.log("two",two)
334
          }
351
          }
335
       })
352
       })
353
+    },
354
+    getTotalDialysisCount(timeStar,timeEnd){
355
+      getTotalDialysisCount(timeStar,timeEnd).then(response=>{
356
+      })
336
     }
357
     }
337
   },
358
   },
338
   created() {
359
   created() {
362
       this.getTotalInfectiousCount(timeStar,timeEnd)
383
       this.getTotalInfectiousCount(timeStar,timeEnd)
363
       //统计年龄
384
       //统计年龄
364
       this.getTotalAgeCount(timeStar,timeEnd)
385
       this.getTotalAgeCount(timeStar,timeEnd)
386
+      //统计透析年龄
387
+      this.getTotalDialysisCount(timeStar,timeEnd)
365
   },
388
   },
366
 };
389
 };
367
 </script>
390
 </script>