瀏覽代碼

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

XMLWAN 4 年之前
父節點
當前提交
61e55e6ea2

+ 157 - 0
src/api/common/statistics.js 查看文件

@@ -0,0 +1,157 @@
1
+import request from '@/utils/request'
2
+
3
+export function GetDialysisProcessIndexChartData(params) {
4
+  return request({
5
+    url: '/api/dialysisprocessindex/chart',
6
+    method: 'get',
7
+    params:params,
8
+  })
9
+}
10
+
11
+export function GetDialysisProcessIndexTableData(params) {
12
+  return request({
13
+    url: '/api/dialysisprocessindex/table',
14
+    method: 'get',
15
+    params:params,
16
+  })
17
+}
18
+
19
+
20
+export function GetDialysisWatchChartData(params) {
21
+  return request({
22
+    url: '/api/dialysiswatch/chart',
23
+    method: 'get',
24
+    params:params,
25
+  })
26
+}
27
+
28
+
29
+export function GetDialysisWatchTableData(params) {
30
+  return request({
31
+    url: '/api/dialysiswatch/table',
32
+    method: 'get',
33
+    params:params,
34
+  })
35
+}
36
+
37
+
38
+export function GetDialysisBloodPressureChartData(params) {
39
+  return request({
40
+    url: '/api/dialysisbloodpressure/chart',
41
+    method: 'get',
42
+    params:params,
43
+  })
44
+}
45
+
46
+
47
+export function GetDialysisBloodPressureTableData(params) {
48
+  return request({
49
+    url: '/api/dialysisbloodpressure/table',
50
+    method: 'get',
51
+    params:params,
52
+  })
53
+}
54
+
55
+
56
+
57
+
58
+export function GetDialysisPatientBloodPressureChartData(params) {
59
+  return request({
60
+    url: '/api/patientdialysisbloodpressure/chart',
61
+    method: 'get',
62
+    params:params,
63
+  })
64
+}
65
+
66
+
67
+
68
+
69
+export function GetDialysisWeightChartData(params) {
70
+  return request({
71
+    url: '/api/dialysisweight/chart',
72
+    method: 'get',
73
+    params:params,
74
+  })
75
+}
76
+
77
+
78
+
79
+export function GetDialysisWeightTableData(params) {
80
+  return request({
81
+    url: '/api/dialysisweight/table',
82
+    method: 'get',
83
+    params:params,
84
+  })
85
+}
86
+
87
+
88
+export function GetDialysisPatientWeightChartData(params) {
89
+  return request({
90
+    url: '/api/patientdialysisweight/chart',
91
+    method: 'get',
92
+    params:params,
93
+  })
94
+}
95
+
96
+
97
+
98
+export function GetDoctorWorkloadChartData(params) {
99
+  return request({
100
+    url: '/api/doctorworkload/chart',
101
+    method: 'get',
102
+    params:params,
103
+  })
104
+}
105
+
106
+
107
+
108
+export function GetDoctorWorkloadTableData(params) {
109
+  return request({
110
+    url: '/api/doctorworkload/table',
111
+    method: 'get',
112
+    params:params,
113
+  })
114
+}
115
+
116
+
117
+
118
+export function GetNurseWorkloadChartData(params) {
119
+  return request({
120
+    url: '/api/nurseworkload/chart',
121
+    method: 'get',
122
+    params:params,
123
+  })
124
+}
125
+
126
+
127
+
128
+export function GetNurseWorkloadTableData(params) {
129
+  return request({
130
+    url: '/api/nurseworkload/table',
131
+    method: 'get',
132
+    params:params,
133
+  })
134
+}
135
+
136
+
137
+
138
+export function GetAllAdminUser() {
139
+  return request({
140
+    url: '/api/adminuser/all',
141
+    method: 'get',
142
+  })
143
+}
144
+
145
+export function GetDefalutPatient() {
146
+  return request({
147
+    url: '/api/defalutpatient/get',
148
+    method: 'get',
149
+  })
150
+}
151
+
152
+
153
+
154
+
155
+
156
+
157
+

+ 3 - 0
src/xt_pages/dialysis/details/dialog/AssessmentAfterDislysis.vue 查看文件

@@ -846,6 +846,9 @@ export default {
846 846
         : 0;
847 847
 
848 848
       data["is_eat"] = this.form.is_eat ? parseFloat(this.form.is_eat) : 0;
849
+      data["cvc_a"] = this.form.cvc_a ? parseFloat(this.form.cvc_a) : 0;
850
+      data["cvc_v"] = this.form.cvc_v ? parseFloat(this.form.cvc_v) : 0;
851
+
849 852
       console.log("data", data);
850 853
       postAssessmentAfterDislysis(ParamsQuery, data)
851 854
         .then(response => {

+ 453 - 260
src/xt_pages/qcd/indicatorControlAnalysis/bloodPressure.vue 查看文件

@@ -4,33 +4,48 @@
4 4
       <bread-crumb :crumbs="crumbs"></bread-crumb>
5 5
     </div>
6 6
     <div class="app-container">
7
-      <div class="page_bloodPressure">
7
+      <div class="page_process">
8 8
         <new-nav activeName="bloodPressure"></new-nav>
9 9
         <div class="cell clearfix">
10
-          <el-form :inline="true" :model="listQuery">
10
+          <el-form :inline="true">
11 11
             <el-form-item label>
12
-              <el-input v-model.trim="listQuery.search" placeholder="姓名/透析号" style="width:110px"></el-input>
13
-              <el-button type="primary" @click="onSearch" icon="el-icon-search">搜索</el-button>
12
+              <el-autocomplete
13
+                class="checkSearch"
14
+                popper-class="my-autocomplete"
15
+                v-model="search_value"
16
+                :fetch-suggestions="querySearchAsync"
17
+                :trigger-on-focus="false"
18
+                placeholder="请输入病人名字"
19
+                @select="handleSelect"
20
+              >
21
+                <i class="el-icon-search el-input__icon" slot="suffix"></i>
22
+                <template slot-scope="{ item }">
23
+                  <div class="name">{{ item.name }}</div>
24
+                </template>
25
+              </el-autocomplete>
26
+
14 27
             </el-form-item>
15 28
           </el-form>
16
-          <el-select v-model="value" placeholder="请选择" style="width:110px;margin-right:10px">
29
+          <el-select v-model="query.statistics_type" placeholder="请选择" style="width:110px;margin-right:10px" @change="changeProject">
17 30
             <el-option
18 31
               v-for="item in options"
19 32
               :key="item.value"
20
-              :label="item.label"
33
+              :label="item.name"
21 34
               :value="item.value"
35
+
22 36
             ></el-option>
23 37
           </el-select>
24 38
           <label class="title">
25 39
             <span class="name">日期查询</span> :
26 40
           </label>
27 41
           <el-date-picker
28
-            v-model="listQuery.start_time"
42
+            v-model="query.start_time"
29 43
             prefix-icon="el-icon-date"
30 44
             @change="changeTime"
31 45
             :editable="false"
32 46
             style="width: 150px;"
33 47
             type="date"
48
+            :picker-options="pickerOptions"
34 49
             placeholder="选择日期时间"
35 50
             align="right"
36 51
             format="yyyy-MM-dd"
@@ -38,10 +53,11 @@
38 53
           ></el-date-picker>
39 54
           <span class>-</span>
40 55
           <el-date-picker
41
-            v-model="listQuery.end_time"
56
+            v-model="query.end_time"
42 57
             prefix-icon="el-icon-date"
43 58
             @change="changeEndTime"
44 59
             :editable="false"
60
+            :picker-options="pickerOptions"
45 61
             style="width: 150px;"
46 62
             type="date"
47 63
             placeholder="选择日期时间"
@@ -53,39 +69,88 @@
53 69
         <el-container>
54 70
           <div style="width:150px">
55 71
             <div class="tableTitle">患者列表</div>
56
-            <el-table :data="tableData" border style="width: 100%;" height="500" :row-style="{ color: '#303133' }" :header-cell-style="{backgroundColor: 'rgb(245, 247, 250)',color: '#606266'}">
57
-              <el-table-column prop="date" label="日期" width="70"></el-table-column>
58
-              <el-table-column prop="name" label="姓名" width="80"></el-table-column>
72
+            <el-table :data="patientsData" border style="width: 100%;" height="500" :row-style="{ color: '#303133' }"
73
+                      :header-cell-style="{backgroundColor: 'rgb(245, 247, 250)',color: '#606266'}"
74
+                      highlight-current-row
75
+                      @current-change="handleChange">
76
+              <el-table-column prop="dialysis_no" label="透析号" width="80">
77
+                <template slot-scope="scope">{{scope.row.dialysis_no}}</template>
78
+              </el-table-column>
79
+              <el-table-column prop="name" label="姓名" width="80">
80
+                <template slot-scope="scope">{{ scope.row.name }}</template>
81
+              </el-table-column>
59 82
             </el-table>
60 83
           </div>
61 84
           <div style="padding-left:10px;flex:1">
62 85
             <div class="tableTitle">指标趋势</div>
63 86
             <div>
64
-              <line-chart :options="chart"></line-chart>
65
-            </div>
66
-            <div class="cell clearfix" style="margin:0;margin-bottom:10px">
67
-              <div class="tableTitle">统计表</div>
87
+              <line-chart :options="bar"></line-chart>
88
+
68 89
             </div>
90
+            <div class="tableTitle">统计表</div>
69 91
             <div>
70
-              <el-table :data="tableData1" style="width: 100%" border :row-style="{ color: '#303133' }" :header-cell-style="{backgroundColor: 'rgb(245, 247, 250)',color: '#606266'}">
71
-                <el-table-column fixed prop="date" label="日期"></el-table-column>
72
-                <el-table-column prop="name" label="姓名"></el-table-column>
73
-                <el-table-column prop="province" label="省份"></el-table-column>
74
-                <el-table-column prop="city" label="市区"></el-table-column>
75
-                <el-table-column prop="address" label="地址"></el-table-column>
76
-                <el-table-column prop="zip" label="邮编"></el-table-column>
77
-                <el-table-column label="操作" width="100">
92
+              <el-table :data="tableData" style="width: 100%" :height="tableHeight" >
93
+                <el-table-column fixed label="日期" align="center">
94
+                  <template slot-scope="scope">
95
+                    {{scope.row.schedule_date | parseTime("{y}-{m}-{d}") }}
96
+                  </template>
97
+                </el-table-column>
98
+
99
+                <el-table-column label="姓名" align="center">
100
+                  <template slot-scope="scope">
101
+                    {{scope.row.patient.name}}
102
+                  </template>
103
+                </el-table-column>
104
+
105
+                <el-table-column label="状态" align="center">
78 106
                   <template slot-scope="scope">
79
-                    <el-button @click="handleClick(scope.row)" type="text" size="small">查看</el-button>
107
+                    {{scope.row.patient.lapseto == 1 ? '留治':'转出'}}
80 108
                   </template>
81 109
                 </el-table-column>
110
+
111
+                <el-table-column label="透前血压" align="center">
112
+                  <template slot-scope="scope">
113
+                    <div v-if="scope.row.before.systolic_blood_pressure">{{scope.row.before.systolic_blood_pressure}} / {{scope.row.before.diastolic_blood_pressure}}</div>
114
+                  </template>
115
+                </el-table-column>
116
+
117
+                <el-table-column label="透析中最低血压" align="center">
118
+                  <template slot-scope="scope">
119
+                    <div v-if="scope.row.min_monitor.systolic_blood_pressure">{{ scope.row.min_monitor.systolic_blood_pressure}} /{{ scope.row.min_monitor.diastolic_blood_pressure}}</div>
120
+                  </template>
121
+                </el-table-column>
122
+
123
+                <el-table-column label="透析中最高血压" align="center">
124
+                  <template slot-scope="scope">
125
+                    <div v-if="scope.row.max_monitor.systolic_blood_pressure">{{ scope.row.max_monitor.systolic_blood_pressure}} /{{ scope.row.max_monitor.diastolic_blood_pressure}}</div>
126
+
127
+
128
+                  </template>
129
+                </el-table-column>
130
+
131
+                <el-table-column label="透后血压" align="center">
132
+                  <template slot-scope="scope">
133
+                    <div v-if="scope.row.after.systolic_blood_pressure"> {{ scope.row.after.systolic_blood_pressure}} /{{scope.row.after.diastolic_blood_pressure}}</div>
134
+                  </template>
135
+                </el-table-column>
136
+
137
+                <el-table-column fixed="right" label="趋势" align="center">
138
+                  <template slot-scope="scope">
139
+                    <el-button
140
+                      @click.native.prevent="jumpDetail(scope.row.patient.id)"
141
+                      type="text"
142
+                      size="small"
143
+                    >详情</el-button>
144
+                  </template>
145
+                </el-table-column>
146
+
82 147
               </el-table>
83 148
 
84 149
               <el-pagination
85 150
                 align="right"
86 151
                 @size-change="handleSizeChange"
87 152
                 @current-change="handleCurrentChange"
88
-                :current-page="listQuery.page"
153
+                :current-page="query.page"
89 154
                 :page-sizes="[10, 20, 50, 100]"
90 155
                 :page-size="10"
91 156
                 background
@@ -103,264 +168,392 @@
103 168
 
104 169
 
105 170
 <script>
106
-import echarts from "echarts";
107
-import NewNav from "../indicatorControlAnalysis/components/NewNav";
108
-import BreadCrumb from "@/xt_pages/components/bread-crumb";
109
-import LineChart from "../../qcd/components/LineChart";
110
-export default {
111
-  components: {
112
-    LineChart,
113
-    BreadCrumb,
114
-    NewNav
115
-  },
116
-  data() {
117
-    return {
118
-      crumbs: [
119
-        { path: false, name: "科室质控" },
120
-        { path: false, name: "指标评估统计" },
121
-        { path: false, name: "患者血压统计" }
122
-      ],
123
-      listQuery: {
124
-        start_time: "",
125
-        end_time: "",
126
-        page: 1,
127
-        limit: 10
128
-      },
129
-      tableData: [
130
-        {
131
-          date: "2016",
132
-          name: "王小虎"
133
-        },
134
-        {
135
-          date: "2016",
136
-          name: "王小虎"
137
-        },
138
-        {
139
-          date: "2016",
140
-          name: "王小虎"
141
-        },
142
-        {
143
-          date: "2016",
144
-          name: "王小虎"
145
-        },
146
-        {
147
-          date: "2016",
148
-          name: "王小虎"
149
-        },
150
-        {
151
-          date: "2016",
152
-          name: "王小虎"
153
-        },
154
-        {
155
-          date: "2016",
156
-          name: "王小虎"
157
-        },
158
-        {
159
-          date: "2016",
160
-          name: "王小虎"
161
-        },
162
-        {
163
-          date: "2016",
164
-          name: "王小虎"
165
-        },
166
-        {
167
-          date: "2016",
168
-          name: "王小虎"
169
-        },
170
-        {
171
-          date: "2016",
172
-          name: "王小虎"
173
-        },
174
-        {
175
-          date: "2016",
176
-          name: "王小虎"
177
-        }
178
-      ],
179
-      tableData1: [
180
-        {
181
-          date: "2016-05-03",
182
-          name: "王小虎",
183
-          province: "上海",
184
-          city: "普陀区",
185
-          address: "上海市普陀区金沙江路 1518 弄",
186
-          zip: 200333
187
-        },
188
-        {
189
-          date: "2016-05-02",
190
-          name: "王小虎",
191
-          province: "上海",
192
-          city: "普陀区",
193
-          address: "上海市普陀区金沙江路 1518 弄",
194
-          zip: 200333
195
-        },
196
-        {
197
-          date: "2016-05-04",
198
-          name: "王小虎",
199
-          province: "上海",
200
-          city: "普陀区",
201
-          address: "上海市普陀区金沙江路 1518 弄",
202
-          zip: 200333
203
-        },
204
-        {
205
-          date: "2016-05-01",
206
-          name: "王小虎",
207
-          province: "上海",
208
-          city: "普陀区",
209
-          address: "上海市普陀区金沙江路 1518 弄",
210
-          zip: 200333
211
-        },
212
-        {
213
-          date: "2016-05-08",
214
-          name: "王小虎",
215
-          province: "上海",
216
-          city: "普陀区",
217
-          address: "上海市普陀区金沙江路 1518 弄",
218
-          zip: 200333
219
-        },
220
-        {
221
-          date: "2016-05-06",
222
-          name: "王小虎",
223
-          province: "上海",
224
-          city: "普陀区",
225
-          address: "上海市普陀区金沙江路 1518 弄",
226
-          zip: 200333
227
-        },
228
-        {
229
-          date: "2016-05-07",
230
-          name: "王小虎",
231
-          province: "上海",
232
-          city: "普陀区",
233
-          address: "上海市普陀区金沙江路 1518 弄",
234
-          zip: 200333
235
-        },
236
-        {
237
-          date: "2016-05-08",
238
-          name: "王小虎",
239
-          province: "上海",
240
-          city: "普陀区",
241
-          address: "上海市普陀区金沙江路 1518 弄",
242
-          zip: 200333
243
-        },
244
-        {
245
-          date: "2016-05-06",
246
-          name: "王小虎",
247
-          province: "上海",
248
-          city: "普陀区",
249
-          address: "上海市普陀区金沙江路 1518 弄",
250
-          zip: 200333
251
-        },
252
-        {
253
-          date: "2016-05-07",
254
-          name: "王小虎",
255
-          province: "上海",
256
-          city: "普陀区",
257
-          address: "上海市普陀区金沙江路 1518 弄",
258
-          zip: 200333
259
-        }
260
-      ],
261
-      chart: {
262
-        title: {
263
-          text: "ECharts 入门示例"
264
-        },
265
-        tooltip: {},
266
-        legend: {
267
-          data: ["次数"],
268
-          left: 0
171
+  import echarts from 'echarts'
172
+  import NewNav from '../indicatorControlAnalysis/components/NewNav'
173
+  import BreadCrumb from '@/xt_pages/components/bread-crumb'
174
+  import LineChart from '../../qcd/components/LineChart'
175
+  import { getCurrentOrgPatients } from "@/api/common/common";
176
+
177
+
178
+  import {GetDialysisBloodPressureChartData,GetDialysisBloodPressureTableData} from "@/api/common/statistics"
179
+
180
+  import {
181
+    PostSearch
182
+  } from '@/api/patient'
183
+
184
+  import { uParseTime } from "@/utils/tools";
185
+  import { getDataConfig } from "@/utils/data";
186
+
187
+  export default {
188
+    components: {
189
+      LineChart,
190
+      BreadCrumb,
191
+      NewNav
192
+    },
193
+    data() {
194
+      return {
195
+        pickerOptions: {
196
+          disabledDate(time) {
197
+            let threeMonths = new Date(new Date().setFullYear(new Date().getFullYear()-1)).getTime() - 24 * 3600 * 1000;
198
+            return time.getTime() > Date.now() || time.getTime() < threeMonths;;
199
+          }
269 200
         },
270
-        xAxis: {
271
-          data: ["达标", "未达标"]
201
+        patientsData:[],
202
+        tableData: [
203
+        ],
204
+        loading: false,
205
+        search_value: '',
206
+        total: '',
207
+        query: {
208
+          patient_id: '',
209
+          statistics_type: 1,
210
+          start_time: '',
211
+          end_time: '',
212
+          limit: 10,
213
+          page: 1
272 214
         },
273
-        yAxis: {
274
-          axisLabel: {
275
-            formatter: "{value} %"
215
+        options: [
216
+          { value: 1, name: '不限' },
217
+          { value: 2, name: '透前血压' },
218
+          { value: 3, name: '透后血压' },
219
+        ],
220
+        crumbs: [
221
+          { path: false, name: '科室质控' },
222
+          { path: false, name: '指标评估统计' },
223
+          { path: false, name: '透析过程指标统计' }
224
+        ],
225
+        tableData1: [],
226
+        chart: {
227
+          title: {
228
+            text: 'ECharts 入门示例'
276 229
           },
277
-          show: false
278
-        },
279
-        series: [
280
-          {
281
-            name: "次数",
282
-            type: "bar",
283
-            data: ["78.57", "50"],
284
-            barWidth: 30,
285
-            label: {
286
-              normal: {
287
-                show: true,
288
-                position: "top",
289
-                formatter: "{c}次"
290
-              }
230
+          tooltip: {},
231
+          legend: {
232
+            data: [],
233
+            left: 0
234
+          },
235
+          xAxis: {
236
+            data: []
237
+          },
238
+          yAxis: {
239
+            axisLabel: {
240
+              formatter: '{value} %'
291 241
             },
292
-            //配置样式
293
-            itemStyle: {
294
-              //通常情况下:
295
-
296
-              //每个柱子的颜色即为colorList数组里的每一项,如果柱子数目多于colorList的长度,则柱子颜色循环使用该数组
297
-              normal: {
298
-                color: function(params) {
299
-                  //我这边就两个柱子,大体就两个柱子颜色渐变,所以数组只有两个值,多个颜色就多个值
300
-                  var colorList = [
301
-                    ["#A9E0F3", "#9FBDFC"],
302
-
303
-                    ["#FFD7C0", "#FF9994"]
304
-                  ];
305
-
306
-                  var index = params.dataIndex;
307
-                  if (params.dataIndex >= colorList.length) {
308
-                    index = params.dataIndex % colorList.length;
309
-                  }
310
-
311
-                  return new echarts.graphic.LinearGradient(0, 0, 0, 1, [
312
-                    { offset: 0, color: colorList[index][0] },
313
-                    // { offset: 0.5, color: colorList[index][1] },
314
-                    { offset: 1, color: colorList[index][1] }
315
-                  ]);
242
+            show: false
243
+          },
244
+          series: [
245
+            {
246
+              name: '',
247
+              type: 'line',
248
+              data: [],
249
+              barWidth: 30,
250
+              label: {
251
+                normal: {
252
+                  show: true,
253
+                  position: 'top',
254
+                  formatter: '{c}'
255
+                }
256
+              },
257
+              //配置样式
258
+              itemStyle: {
259
+                //通常情况下:
260
+
261
+                //每个柱子的颜色即为colorList数组里的每一项,如果柱子数目多于colorList的长度,则柱子颜色循环使用该数组
262
+                normal: {
263
+                  color: function(params) {
264
+                    //我这边就两个柱子,大体就两个柱子颜色渐变,所以数组只有两个值,多个颜色就多个值
265
+                    var colorList = [
266
+                      ['#A9E0F3', '#9FBDFC'],
267
+
268
+                      ['#FFD7C0', '#FF9994']
269
+                    ]
270
+
271
+                    var index = params.dataIndex
272
+                    if (params.dataIndex >= colorList.length) {
273
+                      index = params.dataIndex % colorList.length
274
+                    }
275
+
276
+                    return new echarts.graphic.LinearGradient(0, 0, 0, 1, [
277
+                      { offset: 0, color: colorList[index][0] },
278
+                      // { offset: 0.5, color: colorList[index][1] },
279
+                      { offset: 1, color: colorList[index][1] }
280
+                    ])
281
+                  },
282
+                  barBorderRadius: [5, 5, 0, 0] //柱状角成椭圆形
316 283
                 },
317
-                barBorderRadius: [5, 5, 0, 0] //柱状角成椭圆形
284
+
285
+                //鼠标悬停时:
286
+                emphasis: {
287
+                  shadowBlur: 10,
288
+                  shadowOffsetX: 0,
289
+                  shadowColor: 'rgba(0, 0, 0, 0.5)'
290
+                }
291
+              }
292
+            }
293
+          ]
294
+        },
295
+        bar: {
296
+          title: {
297
+            text: 'ECharts 入门示例'
298
+          },
299
+          tooltip: {},
300
+          legend: {
301
+            data: [],
302
+            left: 0
303
+          },
304
+          xAxis: {
305
+            data: []
306
+          },
307
+          yAxis: {
308
+            axisLabel: {
309
+              formatter: '{value} %'
310
+            },
311
+            show: false
312
+          },
313
+          series: [
314
+            {
315
+              name: '',
316
+              type: 'bar',
317
+              data: [],
318
+              barWidth: 30,
319
+              label: {
320
+                normal: {
321
+                  show: true,
322
+                  position: 'top',
323
+                  formatter: '{c}次'
324
+                }
318 325
               },
326
+              //配置样式
327
+              itemStyle: {
328
+                //通常情况下:
329
+
330
+                //每个柱子的颜色即为colorList数组里的每一项,如果柱子数目多于colorList的长度,则柱子颜色循环使用该数组
331
+                normal: {
332
+                  color: function(params) {
333
+                    //我这边就两个柱子,大体就两个柱子颜色渐变,所以数组只有两个值,多个颜色就多个值
334
+                    var colorList = [
335
+                      ['#A9E0F3', '#9FBDFC'],
336
+                      ['#FFD7C0', '#FF9994']
337
+                    ]
319 338
 
320
-              //鼠标悬停时:
321
-              emphasis: {
322
-                shadowBlur: 10,
323
-                shadowOffsetX: 0,
324
-                shadowColor: "rgba(0, 0, 0, 0.5)"
339
+                    var index = params.dataIndex
340
+                    if (params.dataIndex >= colorList.length) {
341
+                      index = params.dataIndex % colorList.length
342
+                    }
343
+
344
+                    return new echarts.graphic.LinearGradient(0, 0, 0, 1, [
345
+                      { offset: 0, color: colorList[index][0] },
346
+                      // { offset: 0.5, color: colorList[index][1] },
347
+                      { offset: 1, color: colorList[index][1] }
348
+                    ])
349
+                  },
350
+                  barBorderRadius: [5, 5, 0, 0] //柱状角成椭圆形
351
+                },
352
+
353
+                //鼠标悬停时:
354
+                emphasis: {
355
+                  shadowBlur: 10,
356
+                  shadowOffsetX: 0,
357
+                  shadowColor: 'rgba(0, 0, 0, 0.5)'
358
+                }
325 359
               }
326 360
             }
327
-          }
328
-        ]
361
+          ]
362
+        }
363
+
329 364
       }
330
-    };
331
-  },
332
-  methods: {
333
-    chooseWay(way) {
334
-      this.wayType = way;
335 365
     },
336
-    handleClick(row) {
337
-      console.log(row);
338
-      this.$router.push({
339
-        path: "/qcd/indicatorControlAnalysis/bloodPressureDetails"
340
-      });
366
+    methods: {
367
+      changeProject(val){
368
+        this.query.statistics_type = val
369
+        this.query.page = 1
370
+        this.GetDialysisBloodPressureChartData(this.query)
371
+
372
+      },
373
+      handleChange(val){
374
+        this.query.patient_id = val.id
375
+        this.query.page = 1
376
+        this.GetDialysisBloodPressureTableData(this.query)
377
+        this.GetDialysisBloodPressureChartData(this.query)
378
+      },
379
+      handleSizeChange(limit) {
380
+        this.query.limit = limit;
381
+
382
+      },
383
+      handleCurrentChange(page) {
384
+        this.query.page = page;
385
+
386
+      },
387
+      changeTime(val) {
388
+        var time = this.getTimestamp(val) - this.getTimestamp(this.query.end_time);
389
+        if (time > 0) {
390
+          this.$message.error("结束时间不能小于开始时间");
391
+          this.query.start_time = "";
392
+        } else {
393
+          // this.getDialysisList()
394
+          this.query.page = 1;
395
+          this.GetDialysisBloodPressureChartData(this.query)
396
+          this.GetDialysisBloodPressureTableData(this.query)
397
+
398
+        }
399
+
400
+      },
401
+      changeEndTime(val) {
402
+        var time =
403
+          this.getTimestamp(val) - this.getTimestamp(this.query.start_time);
404
+        if (time < 0) {
405
+          this.$message.error("结束时间不能小于开始时间");
406
+          this.query.end_time = "";
407
+        } else {
408
+          this.query.page = 1;
409
+          this.GetDialysisBloodPressureChartData(this.query)
410
+          this.GetDialysisBloodPressureTableData(this.query)
411
+
412
+        }
413
+      },
414
+      getTimestamp(time) {
415
+        // 把时间日期转成时间戳
416
+        return new Date(time).getTime() / 1000;
417
+      },
418
+      QueryOperaById: function(val) {
419
+        let vascular_access_desc_name = "";
420
+        let vascular_access_desc = getDataConfig(
421
+          "hemodialysis",
422
+          "vascular_access_desc"
423
+        );
424
+        for (let i = 0; i < vascular_access_desc.length; i++) {
425
+          if (vascular_access_desc[i].id == val) {
426
+            vascular_access_desc_name = vascular_access_desc[i].name;
427
+          }
428
+        }
429
+
430
+        return vascular_access_desc_name;
431
+      },
432
+      GetAnticoagulantById: function (val) {
433
+        let anticoagulan_name = ''
434
+        var anticoagulantsConfitTwo = this.$store.getters.anticoagulants_confit
435
+        let anticoagulant = anticoagulantsConfitTwo
436
+        for (let keys in anticoagulant) {
437
+          if (anticoagulant[keys].id == val) {
438
+            anticoagulan_name = anticoagulant[keys].name
439
+          }
440
+        }
441
+        return anticoagulan_name
442
+      },
443
+      getModeName(mode_id){
444
+        return this.$store.getters.treatment_mode[mode_id] != undefined ? this.$store.getters.treatment_mode[mode_id].name: ""
445
+      },
446
+      changeTime() {
447
+
448
+      }, changeEndTime() {
449
+
450
+
451
+      }, GetDialysisBloodPressureTableData(params) {
452
+        this.loading = true
453
+        this.tableData = []
454
+        GetDialysisBloodPressureTableData(params)
455
+          .then(rs => {
456
+            var resp = rs.data
457
+            if (resp.state == 1) {
458
+              this.loading = false
459
+
460
+              for (let i = 0; i < resp.data.data.length; i++) {
461
+                this.tableData.push(resp.data.data[i])
462
+              }
463
+            } else {
464
+              this.loading = false
465
+            }
466
+          })
467
+          .catch(error => {
468
+
469
+          })
470
+      },
471
+      GetDialysisBloodPressureChartData(params) {
472
+        this.bar.xAxis.data = []
473
+        this.bar.series[0].data = []
474
+        GetDialysisBloodPressureChartData(params)
475
+          .then(rs => {
476
+            var resp = rs.data
477
+            if (resp.state == 1) {
478
+                for (let i = 0; i < resp.data.data.length; i++) {
479
+                  this.bar.xAxis.data.push(resp.data.data[i].name)
480
+                  this.bar.series[0].data.push(resp.data.data[i].total)
481
+              }
482
+            } else {
483
+            }
484
+          })
485
+          .catch(error => {
486
+          })
487
+      },
488
+      handleSelect(val) {
489
+        this.query.patient_id = val.id
490
+        this.query.page = 1
491
+        this.GetDialysisBloodPressureChartData(this.query)
492
+        this.GetDialysisBloodPressureTableData(this.query)
493
+
494
+      },
495
+      querySearchAsync(keyword, cb) {
496
+        let key = ''
497
+        if (keyword != undefined) {
498
+          key = keyword
499
+        }
500
+        let searchArray = []
501
+        PostSearch(key).then(response => {
502
+          if (response.data.state == 1) {
503
+            searchArray = response.data.data.patient
504
+            cb(searchArray)
505
+          } else {
506
+            cb([])
507
+          }
508
+        })
509
+      },
510
+      chooseWay(way) {
511
+        this.wayType = way
512
+      }, getCurrentOrgPatients(){
513
+        getCurrentOrgPatients().then(response=>{
514
+          if(response.data.state == 1){
515
+            var patients = response.data.data.patients
516
+            this.patientsData = patients
517
+          }
518
+        })
519
+      },
520
+    }, created() {
521
+      var date = new Date()
522
+      var year = date.getFullYear() //获取完整的年份(4位)
523
+      var month = date.getMonth() + 1 < 10 ? '0' + (date.getMonth() + 1).toString() : date.getMonth() + 1 //获取当前月份(0-11,0代表1月)
524
+      var day = date.getDate() < 0 ? '0' + date.getDate().toString() : date.getDate() //获取当前日(1-31)
525
+      var last_month = date.getMonth() < 10 ? '0' + date.getMonth().toString() : date.getMonth() //获取当前月份(0-11,0代表1月)
526
+      this.query.patient_id = 0
527
+      this.query.end_time = year + '-' + month + '-' + day
528
+      this.query.start_time = year + '-' + last_month + '-' + day
529
+      this.query.statistics_type = 1
530
+      this.GetDialysisBloodPressureChartData(this.query)
531
+      this.GetDialysisBloodPressureTableData(this.query)
532
+      this.getCurrentOrgPatients()
533
+
534
+
341 535
     }
342 536
   }
343
-};
344 537
 </script>
345 538
 
346 539
 <style lang="scss" scoped>
347
-.tableTitle {
348
-  font-size: 16px;
349
-  color: #000;
350
-  font-weight: bold;
351
-  margin-bottom: 10px;
352
-}
540
+  .tableTitle {
541
+    font-size: 16px;
542
+    color: #000;
543
+    font-weight: bold;
544
+    margin-bottom: 10px;
545
+  }
353 546
 </style>
354 547
 <style lang="scss">
355
-.page_bloodPressure {
548
+  .page_process {
549
+
356 550
   .el-button--medium {
357 551
     padding: 10px 8px;
358 552
   }
553
+
359 554
   .el-form-item {
360 555
     margin-bottom: 0;
361 556
   }
362
-  .cell {
363
-    text-align: center;
557
+
364 558
   }
365
-}
366 559
 </style>

+ 503 - 247
src/xt_pages/qcd/indicatorControlAnalysis/monitor.vue 查看文件

@@ -4,33 +4,48 @@
4 4
       <bread-crumb :crumbs="crumbs"></bread-crumb>
5 5
     </div>
6 6
     <div class="app-container">
7
-      <div class="page_monitor">
7
+      <div class="page_process">
8 8
         <new-nav activeName="monitor"></new-nav>
9 9
         <div class="cell clearfix">
10
-          <el-form :inline="true" :model="listQuery">
10
+          <el-form :inline="true">
11 11
             <el-form-item label>
12
-              <el-input v-model.trim="listQuery.search" placeholder="姓名/透析号" style="width:110px"></el-input>
13
-              <el-button type="primary" @click="onSearch" icon="el-icon-search">搜索</el-button>
12
+              <el-autocomplete
13
+                class="checkSearch"
14
+                popper-class="my-autocomplete"
15
+                v-model="search_value"
16
+                :fetch-suggestions="querySearchAsync"
17
+                :trigger-on-focus="false"
18
+                placeholder="请输入病人名字"
19
+                @select="handleSelect"
20
+              >
21
+                <i class="el-icon-search el-input__icon" slot="suffix"></i>
22
+                <template slot-scope="{ item }">
23
+                  <div class="name">{{ item.name }}</div>
24
+                </template>
25
+              </el-autocomplete>
26
+
14 27
             </el-form-item>
15 28
           </el-form>
16
-          <el-select v-model="value" placeholder="请选择" style="width:110px;margin-right:10px">
29
+          <el-select v-model="query.statistics_type" placeholder="请选择" style="width:110px;margin-right:10px" @change="changeProject">
17 30
             <el-option
18 31
               v-for="item in options"
19 32
               :key="item.value"
20
-              :label="item.label"
33
+              :label="item.name"
21 34
               :value="item.value"
35
+
22 36
             ></el-option>
23 37
           </el-select>
24 38
           <label class="title">
25 39
             <span class="name">日期查询</span> :
26 40
           </label>
27 41
           <el-date-picker
28
-            v-model="listQuery.start_time"
42
+            v-model="query.start_time"
29 43
             prefix-icon="el-icon-date"
30 44
             @change="changeTime"
31 45
             :editable="false"
32 46
             style="width: 150px;"
33 47
             type="date"
48
+            :picker-options="pickerOptions"
34 49
             placeholder="选择日期时间"
35 50
             align="right"
36 51
             format="yyyy-MM-dd"
@@ -38,10 +53,11 @@
38 53
           ></el-date-picker>
39 54
           <span class>-</span>
40 55
           <el-date-picker
41
-            v-model="listQuery.end_time"
56
+            v-model="query.end_time"
42 57
             prefix-icon="el-icon-date"
43 58
             @change="changeEndTime"
44 59
             :editable="false"
60
+            :picker-options="pickerOptions"
45 61
             style="width: 150px;"
46 62
             type="date"
47 63
             placeholder="选择日期时间"
@@ -53,9 +69,16 @@
53 69
         <el-container>
54 70
           <div style="width:150px">
55 71
             <div class="tableTitle">患者列表</div>
56
-            <el-table :data="tableData" border style="width: 100%;" height="500" :row-style="{ color: '#303133' }" :header-cell-style="{backgroundColor: 'rgb(245, 247, 250)',color: '#606266'}">
57
-              <el-table-column prop="date" label="日期" width="70"></el-table-column>
58
-              <el-table-column prop="name" label="姓名" width="80"></el-table-column>
72
+            <el-table :data="patientsData" border style="width: 100%;" height="500" :row-style="{ color: '#303133' }"
73
+                      :header-cell-style="{backgroundColor: 'rgb(245, 247, 250)',color: '#606266'}"
74
+                      highlight-current-row
75
+                      @current-change="handleChange">
76
+              <el-table-column prop="dialysis_no" label="透析号" width="80">
77
+                <template slot-scope="scope">{{scope.row.dialysis_no}}</template>
78
+              </el-table-column>
79
+              <el-table-column prop="name" label="姓名" width="80">
80
+                <template slot-scope="scope">{{ scope.row.name }}</template>
81
+              </el-table-column>
59 82
             </el-table>
60 83
           </div>
61 84
           <div style="padding-left:10px;flex:1">
@@ -65,20 +88,96 @@
65 88
             </div>
66 89
             <div class="tableTitle">统计表</div>
67 90
             <div>
68
-              <el-table :data="tableData1" style="width: 100%" border :row-style="{ color: '#303133' }" :header-cell-style="{backgroundColor: 'rgb(245, 247, 250)',color: '#606266'}">
69
-                <el-table-column fixed prop="date" label="日期"></el-table-column>
70
-                <el-table-column prop="name" label="姓名"></el-table-column>
71
-                <el-table-column prop="province" label="省份"></el-table-column>
72
-                <el-table-column prop="city" label="市区"></el-table-column>
73
-                <el-table-column prop="address" label="地址"></el-table-column>
74
-                <el-table-column prop="zip" label="邮编"></el-table-column>
91
+              <el-table :data="tableData" style="width: 100%" :height="tableHeight" v-loading="loading">
92
+                <el-table-column fixed label="监测时间" align="center">
93
+                  <template slot-scope="scope">
94
+                    <!--{{getTime(scope.row.operate_time)}}-->
95
+                    {{scope.row.operate_time | parseTime("{y}-{m}-{d} {h}:{i}") }}
96
+
97
+                  </template>
98
+                </el-table-column>
99
+
100
+                <el-table-column label="收缩压" align="center">
101
+                  <template slot-scope="scope">
102
+                    {{scope.row.systolic_blood_pressure?scope.row.systolic_blood_pressure:''}}
103
+                  </template>
104
+                </el-table-column>
105
+
106
+                <el-table-column label="舒张压" align="center">
107
+                  <template slot-scope="scope">
108
+                    {{scope.row.diastolic_blood_pressure?scope.row.diastolic_blood_pressure:''}}
109
+                  </template>
110
+                </el-table-column>
111
+
112
+                <el-table-column label="脉搏" align="center">
113
+                  <template slot-scope="scope">
114
+                    {{scope.row.pulse_frequency?scope.row.pulse_frequency:''}}
115
+                  </template>
116
+                </el-table-column>
117
+
118
+                <el-table-column label="呼吸" align="center">
119
+                  <template slot-scope="scope">
120
+                    {{scope.row.breathing_rate?scope.row.breathing_rate:''}}
121
+                  </template>
122
+                </el-table-column>
123
+
124
+                <el-table-column label="体温" align="center">
125
+                  <template slot-scope="scope">
126
+                    {{ scope.row.temperature?scope.row.temperature:''}}
127
+                  </template>
128
+                </el-table-column>
129
+
130
+                <el-table-column label="血流量" align="center">
131
+                  <template slot-scope="scope">
132
+                    {{ scope.row.blood_flow_volume?scope.row.blood_flow_volume:''}}
133
+                  </template>
134
+                </el-table-column>
135
+
136
+                <el-table-column label="静脉压" align="center">
137
+                  <template slot-scope="scope">
138
+                    {{ scope.row.venous_pressure?scope.row.venous_pressure:''}}
139
+                  </template>
140
+                </el-table-column>
141
+
142
+
143
+                <el-table-column label="动脉压" align="center">
144
+                  <template slot-scope="scope">
145
+                    {{ scope.row.arterial_pressure?scope.row.arterial_pressure:''}}
146
+
147
+                  </template>
148
+                </el-table-column>
149
+
150
+                <el-table-column label="跨膜压" align="center">
151
+                  <template slot-scope="scope">
152
+                    {{ scope.row.transmembrane_pressure?scope.row.transmembrane_pressure:''}}
153
+                  </template>
154
+                </el-table-column>
155
+
156
+
157
+                <el-table-column label="透析液温度" align="center">
158
+                  <template slot-scope="scope">
159
+                    {{ scope.row.dialysate_temperature?scope.row.dialysate_temperature:''}}
160
+                  </template>
161
+                </el-table-column>
162
+
163
+                <el-table-column label="超滤率" align="center">
164
+                  <template slot-scope="scope">
165
+                    {{ scope.row.ultrafiltration_rate?scope.row.ultrafiltration_rate:''}}
166
+                  </template>
167
+                </el-table-column>
168
+
169
+                <el-table-column label="超滤量" align="center">
170
+                  <template slot-scope="scope">
171
+                    {{ scope.row.ultrafiltration_volume?scope.row.ultrafiltration_volume:''}}
172
+                  </template>
173
+                </el-table-column>
75 174
               </el-table>
76 175
 
77 176
               <el-pagination
78 177
                 align="right"
79 178
                 @size-change="handleSizeChange"
80 179
                 @current-change="handleCurrentChange"
81
-                :current-page="listQuery.page"
180
+                :current-page="query.page"
82 181
                 :page-sizes="[10, 20, 50, 100]"
83 182
                 :page-size="10"
84 183
                 background
@@ -96,255 +195,412 @@
96 195
 
97 196
 
98 197
 <script>
99
-import echarts from "echarts";
100
-import NewNav from "../indicatorControlAnalysis/components/NewNav";
101
-import BreadCrumb from "@/xt_pages/components/bread-crumb";
102
-import LineChart from "../../qcd/components/LineChart";
103
-export default {
104
-  components: {
105
-    LineChart,
106
-    BreadCrumb,
107
-    NewNav
108
-  },
109
-  data() {
110
-    return {
111
-      crumbs: [
112
-        { path: false, name: "科室质控" },
113
-        { path: false, name: "指标评估统计" },
114
-        { path: false, name: "透析监测信息统计" }
115
-      ],
116
-      listQuery: {
117
-        start_time: "",
118
-        end_time: "",
119
-        page: 1,
120
-        limit: 10
121
-      },
122
-      tableData: [
123
-        {
124
-          date: "2016",
125
-          name: "王小虎"
126
-        },
127
-        {
128
-          date: "2016",
129
-          name: "王小虎"
130
-        },
131
-        {
132
-          date: "2016",
133
-          name: "王小虎"
134
-        },
135
-        {
136
-          date: "2016",
137
-          name: "王小虎"
138
-        },
139
-        {
140
-          date: "2016",
141
-          name: "王小虎"
142
-        },
143
-        {
144
-          date: "2016",
145
-          name: "王小虎"
146
-        },
147
-        {
148
-          date: "2016",
149
-          name: "王小虎"
150
-        },
151
-        {
152
-          date: "2016",
153
-          name: "王小虎"
154
-        },
155
-        {
156
-          date: "2016",
157
-          name: "王小虎"
158
-        },
159
-        {
160
-          date: "2016",
161
-          name: "王小虎"
162
-        },
163
-        {
164
-          date: "2016",
165
-          name: "王小虎"
166
-        },
167
-        {
168
-          date: "2016",
169
-          name: "王小虎"
170
-        }
171
-      ],
172
-      tableData1: [
173
-        {
174
-          date: "2016-05-03",
175
-          name: "王小虎",
176
-          province: "上海",
177
-          city: "普陀区",
178
-          address: "上海市普陀区金沙江路 1518 弄",
179
-          zip: 200333
180
-        },
181
-        {
182
-          date: "2016-05-02",
183
-          name: "王小虎",
184
-          province: "上海",
185
-          city: "普陀区",
186
-          address: "上海市普陀区金沙江路 1518 弄",
187
-          zip: 200333
188
-        },
189
-        {
190
-          date: "2016-05-04",
191
-          name: "王小虎",
192
-          province: "上海",
193
-          city: "普陀区",
194
-          address: "上海市普陀区金沙江路 1518 弄",
195
-          zip: 200333
196
-        },
197
-        {
198
-          date: "2016-05-01",
199
-          name: "王小虎",
200
-          province: "上海",
201
-          city: "普陀区",
202
-          address: "上海市普陀区金沙江路 1518 弄",
203
-          zip: 200333
204
-        },
205
-        {
206
-          date: "2016-05-08",
207
-          name: "王小虎",
208
-          province: "上海",
209
-          city: "普陀区",
210
-          address: "上海市普陀区金沙江路 1518 弄",
211
-          zip: 200333
212
-        },
213
-        {
214
-          date: "2016-05-06",
215
-          name: "王小虎",
216
-          province: "上海",
217
-          city: "普陀区",
218
-          address: "上海市普陀区金沙江路 1518 弄",
219
-          zip: 200333
220
-        },
221
-        {
222
-          date: "2016-05-07",
223
-          name: "王小虎",
224
-          province: "上海",
225
-          city: "普陀区",
226
-          address: "上海市普陀区金沙江路 1518 弄",
227
-          zip: 200333
228
-        },
229
-        {
230
-          date: "2016-05-08",
231
-          name: "王小虎",
232
-          province: "上海",
233
-          city: "普陀区",
234
-          address: "上海市普陀区金沙江路 1518 弄",
235
-          zip: 200333
236
-        },
237
-        {
238
-          date: "2016-05-06",
239
-          name: "王小虎",
240
-          province: "上海",
241
-          city: "普陀区",
242
-          address: "上海市普陀区金沙江路 1518 弄",
243
-          zip: 200333
244
-        },
245
-        {
246
-          date: "2016-05-07",
247
-          name: "王小虎",
248
-          province: "上海",
249
-          city: "普陀区",
250
-          address: "上海市普陀区金沙江路 1518 弄",
251
-          zip: 200333
252
-        }
253
-      ],
254
-      chart: {
255
-        title: {
256
-          text: "ECharts 入门示例"
257
-        },
258
-        tooltip: {},
259
-        legend: {
260
-          data: ["次数"],
261
-          left: 0
198
+  import echarts from 'echarts'
199
+  import NewNav from '../indicatorControlAnalysis/components/NewNav'
200
+  import BreadCrumb from '@/xt_pages/components/bread-crumb'
201
+  import LineChart from '../../qcd/components/LineChart'
202
+  import { getCurrentOrgPatients } from "@/api/common/common";
203
+  import {
204
+    GetDefalutPatient,
205
+    GetDialysisWatchChartData,
206
+    GetDialysisWatchTableData
207
+  } from '@/api/common/statistics'
208
+
209
+
210
+  import {
211
+    PostSearch
212
+  } from '@/api/patient'
213
+
214
+  import { uParseTime } from "@/utils/tools";
215
+  import { getDataConfig } from "@/utils/data";
216
+
217
+  export default {
218
+    components: {
219
+      LineChart,
220
+      BreadCrumb,
221
+      NewNav
222
+    },
223
+    data() {
224
+      return {
225
+        pickerOptions: {
226
+          disabledDate(time) {
227
+            let threeMonths = new Date(new Date().setFullYear(new Date().getFullYear()-1)).getTime() - 24 * 3600 * 1000;
228
+            return time.getTime() > Date.now() || time.getTime() < threeMonths;;
229
+          }
262 230
         },
263
-        xAxis: {
264
-          data: ["达标", "未达标"]
231
+        patientsData:[],
232
+        tableData: [
233
+        ],
234
+        loading: false,
235
+        search_value: '',
236
+        total: '',
237
+        query: {
238
+          patient_id: '',
239
+          statistics_type: 1,
240
+          start_time: '',
241
+          end_time: '',
242
+          limit: 10,
243
+          page: 1
265 244
         },
266
-        yAxis: {
267
-          axisLabel: {
268
-            formatter: "{value} %"
245
+        options: [
246
+          { value: 1, name: '收缩压' },
247
+          { value: 2, name: '舒张压' },
248
+          { value: 3, name: '脉搏' },
249
+          { value: 4, name: '呼吸' },
250
+          { value: 5, name: '体温' },
251
+          { value: 6, name: '血流量' },
252
+          { value: 7, name: '静脉压' },
253
+          { value: 8, name: '动脉压' },
254
+          { value: 9, name: '跨膜压' },
255
+          { value: 10, name: '透析液温度' },
256
+          { value: 11, name: '超滤率' },
257
+          { value: 12, name: '超滤量' },
258
+        ],
259
+        crumbs: [
260
+          { path: false, name: '科室质控' },
261
+          { path: false, name: '指标评估统计' },
262
+          { path: false, name: '透析过程指标统计' }
263
+        ],
264
+        tableData: [],
265
+        tableData1: [],
266
+        chart: {
267
+          title: {
268
+            text: 'ECharts 入门示例'
269 269
           },
270
-          show: false
271
-        },
272
-        series: [
273
-          {
274
-            name: "次数",
275
-            type: "line",
276
-            data: ["78.57", "50"],
277
-            barWidth: 30,
278
-            label: {
279
-              normal: {
280
-                show: true,
281
-                position: "top",
282
-                formatter: "{c}次"
283
-              }
270
+          tooltip: {},
271
+          legend: {
272
+            data: [],
273
+            left: 0
274
+          },
275
+          xAxis: {
276
+            data: []
277
+          },
278
+          yAxis: {
279
+            axisLabel: {
280
+              formatter: '{value} %'
284 281
             },
285
-            //配置样式
286
-            itemStyle: {
287
-              //通常情况下:
288
-
289
-              //每个柱子的颜色即为colorList数组里的每一项,如果柱子数目多于colorList的长度,则柱子颜色循环使用该数组
290
-              normal: {
291
-                color: function(params) {
292
-                  //我这边就两个柱子,大体就两个柱子颜色渐变,所以数组只有两个值,多个颜色就多个值
293
-                  var colorList = [
294
-                    ["#A9E0F3", "#9FBDFC"],
295
-
296
-                    ["#FFD7C0", "#FF9994"]
297
-                  ];
298
-
299
-                  var index = params.dataIndex;
300
-                  if (params.dataIndex >= colorList.length) {
301
-                    index = params.dataIndex % colorList.length;
302
-                  }
303
-
304
-                  return new echarts.graphic.LinearGradient(0, 0, 0, 1, [
305
-                    { offset: 0, color: colorList[index][0] },
306
-                    // { offset: 0.5, color: colorList[index][1] },
307
-                    { offset: 1, color: colorList[index][1] }
308
-                  ]);
282
+            show: false
283
+          },
284
+          series: [
285
+            {
286
+              name: '',
287
+              type: 'line',
288
+              data: [],
289
+              barWidth: 30,
290
+              label: {
291
+                normal: {
292
+                  show: true,
293
+                  position: 'top',
294
+                  formatter: '{c}'
295
+                }
296
+              },
297
+              //配置样式
298
+              itemStyle: {
299
+                //通常情况下:
300
+
301
+                //每个柱子的颜色即为colorList数组里的每一项,如果柱子数目多于colorList的长度,则柱子颜色循环使用该数组
302
+                normal: {
303
+                  color: function(params) {
304
+                    //我这边就两个柱子,大体就两个柱子颜色渐变,所以数组只有两个值,多个颜色就多个值
305
+                    var colorList = [
306
+                      ['#A9E0F3', '#9FBDFC'],
307
+
308
+                      ['#FFD7C0', '#FF9994']
309
+                    ]
310
+
311
+                    var index = params.dataIndex
312
+                    if (params.dataIndex >= colorList.length) {
313
+                      index = params.dataIndex % colorList.length
314
+                    }
315
+
316
+                    return new echarts.graphic.LinearGradient(0, 0, 0, 1, [
317
+                      { offset: 0, color: colorList[index][0] },
318
+                      // { offset: 0.5, color: colorList[index][1] },
319
+                      { offset: 1, color: colorList[index][1] }
320
+                    ])
321
+                  },
322
+                  barBorderRadius: [5, 5, 0, 0] //柱状角成椭圆形
309 323
                 },
310
-                barBorderRadius: [5, 5, 0, 0] //柱状角成椭圆形
324
+
325
+                //鼠标悬停时:
326
+                emphasis: {
327
+                  shadowBlur: 10,
328
+                  shadowOffsetX: 0,
329
+                  shadowColor: 'rgba(0, 0, 0, 0.5)'
330
+                }
331
+              }
332
+            }
333
+          ]
334
+        },
335
+        bar: {
336
+          title: {
337
+            text: 'ECharts 入门示例'
338
+          },
339
+          tooltip: {},
340
+          legend: {
341
+            data: [],
342
+            left: 0
343
+          },
344
+          xAxis: {
345
+            data: []
346
+          },
347
+          yAxis: {
348
+            axisLabel: {
349
+              formatter: '{value} %'
350
+            },
351
+            show: false
352
+          },
353
+          series: [
354
+            {
355
+              name: '',
356
+              type: 'bar',
357
+              data: [],
358
+              barWidth: 30,
359
+              label: {
360
+                normal: {
361
+                  show: true,
362
+                  position: 'top',
363
+                  formatter: '{c}次'
364
+                }
311 365
               },
366
+              //配置样式
367
+              itemStyle: {
368
+                //通常情况下:
369
+
370
+                //每个柱子的颜色即为colorList数组里的每一项,如果柱子数目多于colorList的长度,则柱子颜色循环使用该数组
371
+                normal: {
372
+                  color: function(params) {
373
+                    //我这边就两个柱子,大体就两个柱子颜色渐变,所以数组只有两个值,多个颜色就多个值
374
+                    var colorList = [
375
+                      ['#A9E0F3', '#9FBDFC'],
376
+                      ['#FFD7C0', '#FF9994']
377
+                    ]
378
+
379
+                    var index = params.dataIndex
380
+                    if (params.dataIndex >= colorList.length) {
381
+                      index = params.dataIndex % colorList.length
382
+                    }
312 383
 
313
-              //鼠标悬停时:
314
-              emphasis: {
315
-                shadowBlur: 10,
316
-                shadowOffsetX: 0,
317
-                shadowColor: "rgba(0, 0, 0, 0.5)"
384
+                    return new echarts.graphic.LinearGradient(0, 0, 0, 1, [
385
+                      { offset: 0, color: colorList[index][0] },
386
+                      // { offset: 0.5, color: colorList[index][1] },
387
+                      { offset: 1, color: colorList[index][1] }
388
+                    ])
389
+                  },
390
+                  barBorderRadius: [5, 5, 0, 0] //柱状角成椭圆形
391
+                },
392
+
393
+                //鼠标悬停时:
394
+                emphasis: {
395
+                  shadowBlur: 10,
396
+                  shadowOffsetX: 0,
397
+                  shadowColor: 'rgba(0, 0, 0, 0.5)'
398
+                }
318 399
               }
319 400
             }
320
-          }
321
-        ]
401
+          ]
402
+        }
403
+
322 404
       }
323
-    };
324
-  },
325
-  methods: {
326
-    chooseWay(way) {
327
-      this.wayType = way;
405
+    },
406
+    methods: {
407
+      changeProject(val){
408
+        this.query.statistics_type = val
409
+        this.query.page = 1
410
+        this.GetDialysisWatchChartData(this.query)
411
+
412
+      },
413
+      handleChange(val){
414
+        this.query.patient_id = val.id
415
+        this.query.page = 1
416
+        this.GetDialysisWatchTableData(this.query)
417
+        this.GetDialysisWatchChartData(this.query)
418
+      },
419
+      handleSizeChange(limit) {
420
+        this.query.limit = limit;
421
+
422
+      },
423
+      handleCurrentChange(page) {
424
+        this.query.page = page;
425
+
426
+      },
427
+      changeTime(val) {
428
+        var time = this.getTimestamp(val) - this.getTimestamp(this.query.end_time);
429
+        if (time > 0) {
430
+          this.$message.error("结束时间不能小于开始时间");
431
+          this.query.start_time = "";
432
+        } else {
433
+          // this.getDialysisList()
434
+          this.query.page = 1;
435
+          this.GetDialysisWatchChartData(this.query)
436
+          this.GetDialysisWatchTableData(this.query)
437
+
438
+        }
439
+
440
+      },
441
+      changeEndTime(val) {
442
+        var time =
443
+          this.getTimestamp(val) - this.getTimestamp(this.query.start_time);
444
+        if (time < 0) {
445
+          this.$message.error("结束时间不能小于开始时间");
446
+          this.query.end_time = "";
447
+        } else {
448
+          this.query.page = 1;
449
+          this.GetDialysisWatchChartData(this.query)
450
+          this.GetDialysisWatchTableData(this.query)
451
+
452
+        }
453
+      },
454
+      getTimestamp(time) {
455
+        // 把时间日期转成时间戳
456
+        return new Date(time).getTime() / 1000;
457
+      },
458
+      QueryOperaById: function(val) {
459
+        let vascular_access_desc_name = "";
460
+        let vascular_access_desc = getDataConfig(
461
+          "hemodialysis",
462
+          "vascular_access_desc"
463
+        );
464
+        for (let i = 0; i < vascular_access_desc.length; i++) {
465
+          if (vascular_access_desc[i].id == val) {
466
+            vascular_access_desc_name = vascular_access_desc[i].name;
467
+          }
468
+        }
469
+
470
+        return vascular_access_desc_name;
471
+      },
472
+      GetAnticoagulantById: function (val) {
473
+        let anticoagulan_name = ''
474
+        var anticoagulantsConfitTwo = this.$store.getters.anticoagulants_confit
475
+        let anticoagulant = anticoagulantsConfitTwo
476
+        for (let keys in anticoagulant) {
477
+          if (anticoagulant[keys].id == val) {
478
+            anticoagulan_name = anticoagulant[keys].name
479
+          }
480
+        }
481
+        return anticoagulan_name
482
+      },
483
+      getModeName(mode_id){
484
+        return this.$store.getters.treatment_mode[mode_id] != undefined ? this.$store.getters.treatment_mode[mode_id].name: ""
485
+      },
486
+      changeTime() {
487
+
488
+      }, changeEndTime() {
489
+
490
+
491
+      }, GetDialysisWatchTableData(params) {
492
+        this.loading = true
493
+        this.tableData = []
494
+        GetDialysisWatchTableData(params)
495
+          .then(rs => {
496
+            var resp = rs.data
497
+            if (resp.state == 1) {
498
+              this.loading = false
499
+              for (let i = 0; i < resp.data.data.length; i++) {
500
+                this.tableData.push(resp.data.data[i])
501
+              }
502
+            } else {
503
+              this.loading = false
504
+            }
505
+          })
506
+          .catch(error => {
507
+          })
508
+      },
509
+      GetDialysisWatchChartData(params) {
510
+        this.chart.xAxis.data = []
511
+        this.chart.series[0].data = []
512
+        this.bar.xAxis.data = []
513
+        this.bar.series[0].data = []
514
+        GetDialysisWatchChartData(params)
515
+          .then(rs => {
516
+            var resp = rs.data
517
+            if (resp.state == 1) {
518
+              if (this.query.statistics_type != 9 && this.query.statistics_type != 10) {
519
+                for (let i = 0; i < resp.data.data.length; i++) {
520
+                  this.chart.xAxis.data.push(resp.data.data[i].date)
521
+                  this.chart.series[0].data.push(resp.data.data[i].value)
522
+                }
523
+              } else {
524
+                for (let i = 0; i < resp.data.data.length; i++) {
525
+                  this.bar.xAxis.data.push(resp.data.data[i].name)
526
+                  this.bar.series[0].data.push(resp.data.data[i].total)
527
+                }
528
+              }
529
+            } else {
530
+            }
531
+          })
532
+          .catch(error => {
533
+          })
534
+      },
535
+      handleSelect(val) {
536
+        this.query.patient_id = val.id
537
+        this.query.page = 1
538
+        this.GetDialysisWatchTableData(this.query)
539
+        this.GetDialysisWatchChartData(this.query)
540
+
541
+      },
542
+      querySearchAsync(keyword, cb) {
543
+        let key = ''
544
+        if (keyword != undefined) {
545
+          key = keyword
546
+        }
547
+        let searchArray = []
548
+        PostSearch(key).then(response => {
549
+          if (response.data.state == 1) {
550
+            searchArray = response.data.data.patient
551
+            cb(searchArray)
552
+          } else {
553
+            cb([])
554
+          }
555
+        })
556
+      },
557
+      chooseWay(way) {
558
+        this.wayType = way
559
+      }, getCurrentOrgPatients(){
560
+        getCurrentOrgPatients().then(response=>{
561
+          if(response.data.state == 1){
562
+            var patients = response.data.data.patients
563
+            this.patientsData = patients
564
+          }
565
+        })
566
+      },
567
+    }, created() {
568
+      var date = new Date()
569
+      var year = date.getFullYear() //获取完整的年份(4位)
570
+      var month = date.getMonth() + 1 < 10 ? '0' + (date.getMonth() + 1).toString() : date.getMonth() + 1 //获取当前月份(0-11,0代表1月)
571
+      var day = date.getDate() < 0 ? '0' + date.getDate().toString() : date.getDate() //获取当前日(1-31)
572
+      var last_month = date.getMonth() < 10 ? '0' + date.getMonth().toString() : date.getMonth() //获取当前月份(0-11,0代表1月)
573
+      this.query.patient_id = 0
574
+      this.query.end_time = year + '-' + month + '-' + day
575
+      this.query.start_time = year + '-' + last_month + '-' + day
576
+      this.query.statistics_type = 1
577
+      this.GetDialysisWatchChartData(this.query)
578
+      this.GetDialysisWatchTableData(this.query)
579
+      this.getCurrentOrgPatients()
580
+
581
+
328 582
     }
329 583
   }
330
-};
331 584
 </script>
332 585
 
333 586
 <style lang="scss" scoped>
334
-.tableTitle {
335
-  font-size: 16px;
336
-  color: #000;
337
-  font-weight: bold;
338
-  margin-bottom: 10px;
339
-}
587
+  .tableTitle {
588
+    font-size: 16px;
589
+    color: #000;
590
+    font-weight: bold;
591
+    margin-bottom: 10px;
592
+  }
340 593
 </style>
341 594
 <style lang="scss">
342
-.page_monitor {
595
+  .page_process {
596
+
343 597
   .el-button--medium {
344 598
     padding: 10px 8px;
345 599
   }
600
+
346 601
   .el-form-item {
347 602
     margin-bottom: 0;
348 603
   }
349
-}
604
+
605
+  }
350 606
 </style>

+ 578 - 247
src/xt_pages/qcd/indicatorControlAnalysis/process.vue 查看文件

@@ -7,30 +7,45 @@
7 7
       <div class="page_process">
8 8
         <new-nav activeName="process"></new-nav>
9 9
         <div class="cell clearfix">
10
-          <el-form :inline="true" :model="listQuery">
10
+          <el-form :inline="true">
11 11
             <el-form-item label>
12
-              <el-input v-model.trim="listQuery.search" placeholder="姓名/透析号" style="width:110px"></el-input>
13
-              <el-button type="primary" @click="onSearch" icon="el-icon-search">搜索</el-button>
12
+              <el-autocomplete
13
+                class="checkSearch"
14
+                popper-class="my-autocomplete"
15
+                v-model="search_value"
16
+                :fetch-suggestions="querySearchAsync"
17
+                :trigger-on-focus="false"
18
+                placeholder="请输入病人名字"
19
+                @select="handleSelect"
20
+              >
21
+                <i class="el-icon-search el-input__icon" slot="suffix"></i>
22
+                <template slot-scope="{ item }">
23
+                  <div class="name">{{ item.name }}</div>
24
+                </template>
25
+              </el-autocomplete>
26
+
14 27
             </el-form-item>
15 28
           </el-form>
16
-          <el-select v-model="value" placeholder="请选择" style="width:110px;margin-right:10px">
29
+          <el-select v-model="query.statistics_type" placeholder="请选择" style="width:110px;margin-right:10px" @change="changeProject">
17 30
             <el-option
18 31
               v-for="item in options"
19 32
               :key="item.value"
20
-              :label="item.label"
33
+              :label="item.name"
21 34
               :value="item.value"
35
+
22 36
             ></el-option>
23 37
           </el-select>
24 38
           <label class="title">
25 39
             <span class="name">日期查询</span> :
26 40
           </label>
27 41
           <el-date-picker
28
-            v-model="listQuery.start_time"
42
+            v-model="query.start_time"
29 43
             prefix-icon="el-icon-date"
30 44
             @change="changeTime"
31 45
             :editable="false"
32 46
             style="width: 150px;"
33 47
             type="date"
48
+            :picker-options="pickerOptions"
34 49
             placeholder="选择日期时间"
35 50
             align="right"
36 51
             format="yyyy-MM-dd"
@@ -38,10 +53,11 @@
38 53
           ></el-date-picker>
39 54
           <span class>-</span>
40 55
           <el-date-picker
41
-            v-model="listQuery.end_time"
56
+            v-model="query.end_time"
42 57
             prefix-icon="el-icon-date"
43 58
             @change="changeEndTime"
44 59
             :editable="false"
60
+            :picker-options="pickerOptions"
45 61
             style="width: 150px;"
46 62
             type="date"
47 63
             placeholder="选择日期时间"
@@ -53,32 +69,181 @@
53 69
         <el-container>
54 70
           <div style="width:150px">
55 71
             <div class="tableTitle">患者列表</div>
56
-            <el-table :data="tableData" border style="width: 100%;" height="500" :row-style="{ color: '#303133' }" :header-cell-style="{backgroundColor: 'rgb(245, 247, 250)',color: '#606266'}">
57
-              <el-table-column prop="date" label="日期" width="70"></el-table-column>
58
-              <el-table-column prop="name" label="姓名" width="80"></el-table-column>
72
+            <el-table :data="patientsData" border style="width: 100%;" height="500" :row-style="{ color: '#303133' }"
73
+                      :header-cell-style="{backgroundColor: 'rgb(245, 247, 250)',color: '#606266'}"
74
+                      highlight-current-row
75
+                      @current-change="handleChange">
76
+              <el-table-column prop="dialysis_no" label="透析号" width="80">
77
+                <template slot-scope="scope">{{scope.row.dialysis_no}}</template>
78
+              </el-table-column>
79
+              <el-table-column prop="name" label="姓名" width="80">
80
+                <template slot-scope="scope">{{ scope.row.name }}</template>
81
+              </el-table-column>
59 82
             </el-table>
60 83
           </div>
61 84
           <div style="padding-left:10px;flex:1">
62 85
             <div class="tableTitle">指标趋势</div>
63 86
             <div>
64
-              <line-chart :options="chart"></line-chart>
87
+              <line-chart :options="chart" v-if="query.statistics_type != 9 && query.statistics_type != 10"></line-chart>
88
+              <line-chart :options="bar" v-if="query.statistics_type == 9 || query.statistics_type == 10"></line-chart>
89
+
65 90
             </div>
66 91
             <div class="tableTitle">统计表</div>
67 92
             <div>
68
-              <el-table :data="tableData1" style="width: 100%" border :row-style="{ color: '#303133' }" :header-cell-style="{backgroundColor: 'rgb(245, 247, 250)',color: '#606266'}">
69
-                <el-table-column fixed prop="date" label="日期"></el-table-column>
70
-                <el-table-column prop="name" label="姓名"></el-table-column>
71
-                <el-table-column prop="province" label="省份"></el-table-column>
72
-                <el-table-column prop="city" label="市区"></el-table-column>
73
-                <el-table-column prop="address" label="地址"></el-table-column>
74
-                <el-table-column prop="zip" label="邮编"></el-table-column>
93
+              <el-table :data="tableData"  :height="tableHeight"   v-loading="loading">
94
+                <el-table-column  fixed label="透析日期" align="center">
95
+                  <template slot-scope="scope">
96
+                    {{scope.row.schedule_date | parseTime("{y}-{m}-{d}") }}
97
+                    <!--{{getTime(scope.row.schedule_date)}}-->
98
+                  </template>
99
+                </el-table-column>
100
+
101
+                <el-table-column label="姓名" align="center">
102
+                  <template slot-scope="scope">
103
+                    {{scope.row.patient.name}}
104
+                  </template>
105
+                </el-table-column>
106
+
107
+                <el-table-column label="透析机号" align="center">
108
+                  <template slot-scope="scope">
109
+                    {{scope.row.device_number.number}}
110
+                  </template>
111
+                </el-table-column>
112
+
113
+                <el-table-column label="干体重" align="center">
114
+                  <template slot-scope="scope">
115
+                    {{scope.row.predialysis_evaluation.dry_weight?scope.row.predialysis_evaluation.dry_weight:''}}
116
+                  </template>
117
+                </el-table-column>
118
+
119
+                <el-table-column label="透前体重" align="center">
120
+                  <template slot-scope="scope">
121
+                    {{ scope.row.predialysis_evaluation.weight_before?scope.row.predialysis_evaluation.weight_before:''}}
122
+
123
+                  </template>
124
+                </el-table-column>
125
+
126
+                <el-table-column label="透后体重" align="center">
127
+                  <template slot-scope="scope">
128
+                    {{ scope.row.assessment_after_dislysis.weight_after ? scope.row.assessment_after_dislysis.weight_after :''}}
129
+
130
+                  </template>
131
+                </el-table-column>
132
+
133
+                <el-table-column label="目标超滤量" align="center">
134
+                  <template slot-scope="scope">
135
+                    {{ scope.row.prescription.target_ultrafiltration ? scope.row.prescription.target_ultrafiltration : ''}}
136
+
137
+                  </template>
138
+                </el-table-column>
139
+
140
+                <el-table-column label="实际超滤量" align="center">
141
+                  <template slot-scope="scope">
142
+                    {{ scope.row.assessment_after_dislysis.actual_ultrafiltration ?  scope.row.assessment_after_dislysis.actual_ultrafiltration :''}}
143
+
144
+                  </template>
145
+                </el-table-column>
146
+
147
+
148
+                <el-table-column label="透前血压" align="center">
149
+                  <template slot-scope="scope">
150
+                    <div v-if="scope.row.predialysis_evaluation.systolic_blood_pressure && scope.row.predialysis_evaluation.diastolic_blood_pressure">{{ scope.row.predialysis_evaluation.systolic_blood_pressure}} / {{ scope.row.predialysis_evaluation.diastolic_blood_pressure}}</div>
151
+
152
+
153
+                  </template>
154
+                </el-table-column>
155
+
156
+                <el-table-column label="透后血压" align="center">
157
+                  <template slot-scope="scope">
158
+                    <div v-if="scope.row.assessment_after_dislysis.systolic_blood_pressure&&scope.row.assessment_after_dislysis.diastolic_blood_pressure">{{ scope.row.assessment_after_dislysis.systolic_blood_pressure}} / {{ scope.row.assessment_after_dislysis.diastolic_blood_pressure}}</div>
159
+
160
+
161
+                  </template>
162
+                </el-table-column>
163
+
164
+
165
+                <el-table-column label="透前脉率" align="center">
166
+                  <template slot-scope="scope">
167
+                    {{ scope.row.predialysis_evaluation.pulse_frequency?scope.row.predialysis_evaluation.pulse_frequency:''}}
168
+
169
+                  </template>
170
+                </el-table-column>
171
+
172
+                <el-table-column label="透后脉率" align="center">
173
+                  <template slot-scope="scope">
174
+                    {{ scope.row.assessment_after_dislysis.pulse_frequency?scope.row.assessment_after_dislysis.pulse_frequency:''}}
175
+
176
+                  </template>
177
+                </el-table-column>
178
+
179
+
180
+                <el-table-column label="透析模式" align="center">
181
+                  <template slot-scope="scope">
182
+                    {{ getModeName(scope.row.prescription.mode_id)}}
183
+                  </template>
184
+                </el-table-column>
185
+
186
+
187
+                <el-table-column label="透析器" align="center">
188
+                  <template slot-scope="scope">
189
+                    {{ scope.row.prescription.dialyzer_perfusion_apparatus}}
190
+                  </template>
191
+                </el-table-column>
192
+
193
+
194
+                <el-table-column label="钾" align="center">
195
+                  <template slot-scope="scope">
196
+                    {{ scope.row.prescription.kalium?scope.row.prescription.kalium:""}}
197
+
198
+                  </template>
199
+                </el-table-column>
200
+
201
+
202
+
203
+                <el-table-column label="钠" align="center">
204
+                  <template slot-scope="scope">
205
+                    {{ scope.row.prescription.sodium?scope.row.prescription.sodium:""}}
206
+
207
+                  </template>
208
+                </el-table-column>
209
+
210
+
211
+                <el-table-column label="钙" align="center">
212
+                  <template slot-scope="scope">
213
+                    {{ scope.row.prescription.calcium?scope.row.prescription.calcium:""}}
214
+
215
+                  </template>
216
+                </el-table-column>
217
+
218
+
219
+                <el-table-column label="透析时长" align="center">
220
+                  <template slot-scope="scope">
221
+                    {{ scope.row.prescription.dialysis_duration_hour?scope.row.prescription.dialysis_duration_hour+'小时':""}}
222
+                    {{ scope.row.prescription.dialysis_duration_minute?scope.row.prescription.dialysis_duration_minute+'分钟':''}}
223
+                  </template>
224
+
225
+                </el-table-column>
226
+
227
+                <el-table-column label="血管通路" align="center">
228
+                  <template slot-scope="scope">
229
+                    {{ QueryOperaById(scope.row.predialysis_evaluation.blood_access_part_opera_id)}}
230
+                  </template>
231
+                </el-table-column>
232
+
233
+
234
+                <el-table-column label="抗凝剂" align="center">
235
+                  <template slot-scope="scope">
236
+                    {{GetAnticoagulantById( scope.row.prescription.anticoagulant)}}
237
+                  </template>
238
+                </el-table-column>
239
+
75 240
               </el-table>
76 241
 
77 242
               <el-pagination
78 243
                 align="right"
79 244
                 @size-change="handleSizeChange"
80 245
                 @current-change="handleCurrentChange"
81
-                :current-page="listQuery.page"
246
+                :current-page="query.page"
82 247
                 :page-sizes="[10, 20, 50, 100]"
83 248
                 :page-size="10"
84 249
                 background
@@ -96,255 +261,421 @@
96 261
 
97 262
 
98 263
 <script>
99
-import echarts from "echarts";
100
-import NewNav from "../indicatorControlAnalysis/components/NewNav";
101
-import BreadCrumb from "@/xt_pages/components/bread-crumb";
102
-import LineChart from "../../qcd/components/LineChart";
103
-export default {
104
-  components: {
105
-    LineChart,
106
-    BreadCrumb,
107
-    NewNav
108
-  },
109
-  data() {
110
-    return {
111
-      crumbs: [
112
-        { path: false, name: "科室质控" },
113
-        { path: false, name: "指标评估统计" },
114
-        { path: false, name: "透析过程指标统计" }
115
-      ],
116
-      listQuery: {
117
-        start_time: "",
118
-        end_time: "",
119
-        page: 1,
120
-        limit: 10
121
-      },
122
-      tableData: [
123
-        {
124
-          date: "2016",
125
-          name: "王小虎"
126
-        },
127
-        {
128
-          date: "2016",
129
-          name: "王小虎"
130
-        },
131
-        {
132
-          date: "2016",
133
-          name: "王小虎"
134
-        },
135
-        {
136
-          date: "2016",
137
-          name: "王小虎"
138
-        },
139
-        {
140
-          date: "2016",
141
-          name: "王小虎"
142
-        },
143
-        {
144
-          date: "2016",
145
-          name: "王小虎"
146
-        },
147
-        {
148
-          date: "2016",
149
-          name: "王小虎"
150
-        },
151
-        {
152
-          date: "2016",
153
-          name: "王小虎"
154
-        },
155
-        {
156
-          date: "2016",
157
-          name: "王小虎"
158
-        },
159
-        {
160
-          date: "2016",
161
-          name: "王小虎"
162
-        },
163
-        {
164
-          date: "2016",
165
-          name: "王小虎"
166
-        },
167
-        {
168
-          date: "2016",
169
-          name: "王小虎"
170
-        }
171
-      ],
172
-      tableData1: [
173
-        {
174
-          date: "2016-05-03",
175
-          name: "王小虎",
176
-          province: "上海",
177
-          city: "普陀区",
178
-          address: "上海市普陀区金沙江路 1518 弄",
179
-          zip: 200333
180
-        },
181
-        {
182
-          date: "2016-05-02",
183
-          name: "王小虎",
184
-          province: "上海",
185
-          city: "普陀区",
186
-          address: "上海市普陀区金沙江路 1518 弄",
187
-          zip: 200333
188
-        },
189
-        {
190
-          date: "2016-05-04",
191
-          name: "王小虎",
192
-          province: "上海",
193
-          city: "普陀区",
194
-          address: "上海市普陀区金沙江路 1518 弄",
195
-          zip: 200333
196
-        },
197
-        {
198
-          date: "2016-05-01",
199
-          name: "王小虎",
200
-          province: "上海",
201
-          city: "普陀区",
202
-          address: "上海市普陀区金沙江路 1518 弄",
203
-          zip: 200333
204
-        },
205
-        {
206
-          date: "2016-05-08",
207
-          name: "王小虎",
208
-          province: "上海",
209
-          city: "普陀区",
210
-          address: "上海市普陀区金沙江路 1518 弄",
211
-          zip: 200333
212
-        },
213
-        {
214
-          date: "2016-05-06",
215
-          name: "王小虎",
216
-          province: "上海",
217
-          city: "普陀区",
218
-          address: "上海市普陀区金沙江路 1518 弄",
219
-          zip: 200333
220
-        },
221
-        {
222
-          date: "2016-05-07",
223
-          name: "王小虎",
224
-          province: "上海",
225
-          city: "普陀区",
226
-          address: "上海市普陀区金沙江路 1518 弄",
227
-          zip: 200333
228
-        },
229
-        {
230
-          date: "2016-05-08",
231
-          name: "王小虎",
232
-          province: "上海",
233
-          city: "普陀区",
234
-          address: "上海市普陀区金沙江路 1518 弄",
235
-          zip: 200333
236
-        },
237
-        {
238
-          date: "2016-05-06",
239
-          name: "王小虎",
240
-          province: "上海",
241
-          city: "普陀区",
242
-          address: "上海市普陀区金沙江路 1518 弄",
243
-          zip: 200333
244
-        },
245
-        {
246
-          date: "2016-05-07",
247
-          name: "王小虎",
248
-          province: "上海",
249
-          city: "普陀区",
250
-          address: "上海市普陀区金沙江路 1518 弄",
251
-          zip: 200333
252
-        }
253
-      ],
254
-      chart: {
255
-        title: {
256
-          text: "ECharts 入门示例"
257
-        },
258
-        tooltip: {},
259
-        legend: {
260
-          data: ["次数"],
261
-          left: 0
264
+  import echarts from 'echarts'
265
+  import NewNav from '../indicatorControlAnalysis/components/NewNav'
266
+  import BreadCrumb from '@/xt_pages/components/bread-crumb'
267
+  import LineChart from '../../qcd/components/LineChart'
268
+  import { getCurrentOrgPatients } from "@/api/common/common";
269
+  import {
270
+    GetDefalutPatient,
271
+    GetDialysisProcessIndexChartData,
272
+    GetDialysisProcessIndexTableData
273
+  } from '@/api/common/statistics'
274
+
275
+
276
+
277
+  import {
278
+    PostSearch
279
+  } from '@/api/patient'
280
+
281
+  import { uParseTime } from "@/utils/tools";
282
+  import { getDataConfig } from "@/utils/data";
283
+
284
+  export default {
285
+    components: {
286
+      LineChart,
287
+      BreadCrumb,
288
+      NewNav
289
+    },
290
+    data() {
291
+      return {
292
+        pickerOptions: {
293
+          disabledDate(time) {
294
+            let threeMonths = new Date(new Date().setFullYear(new Date().getFullYear()-1)).getTime() - 24 * 3600 * 1000;
295
+            return time.getTime() > Date.now() || time.getTime() < threeMonths;;
296
+          }
262 297
         },
263
-        xAxis: {
264
-          data: ["达标", "未达标"]
298
+        patientsData:[],
299
+        tableData: [
300
+        ],
301
+        loading: false,
302
+        search_value: '',
303
+        total: '',
304
+        query: {
305
+          patient_id: '',
306
+          statistics_type: 1,
307
+          start_time: '',
308
+          end_time: '',
309
+          limit: 10,
310
+          page: 1
265 311
         },
266
-        yAxis: {
267
-          axisLabel: {
268
-            formatter: "{value} %"
312
+        options: [
313
+          { value: 1, name: '透前体重' },
314
+          { value: 2, name: '透后体重' },
315
+          { value: 3, name: '透前收缩压' },
316
+          { value: 4, name: '透前舒张压' },
317
+          { value: 5, name: '透前脉率' },
318
+          { value: 6, name: '透后收缩压' },
319
+          { value: 7, name: '透后舒张压' },
320
+          { value: 8, name: '透后脉率' },
321
+          { value: 9, name: '透析方式' },
322
+          { value: 10, name: '抗凝剂' }
323
+        ],
324
+        crumbs: [
325
+          { path: false, name: '科室质控' },
326
+          { path: false, name: '指标评估统计' },
327
+          { path: false, name: '透析过程指标统计' }
328
+        ],
329
+        tableData: [],
330
+        tableData1: [],
331
+        chart: {
332
+          title: {
333
+            text: 'ECharts 入门示例'
269 334
           },
270
-          show: false
271
-        },
272
-        series: [
273
-          {
274
-            name: "次数",
275
-            type: "line",
276
-            data: ["78.57", "50"],
277
-            barWidth: 30,
278
-            label: {
279
-              normal: {
280
-                show: true,
281
-                position: "top",
282
-                formatter: "{c}次"
283
-              }
335
+          tooltip: {},
336
+          legend: {
337
+            data: [],
338
+            left: 0
339
+          },
340
+          xAxis: {
341
+            data: []
342
+          },
343
+          yAxis: {
344
+            axisLabel: {
345
+              formatter: '{value} %'
284 346
             },
285
-            //配置样式
286
-            itemStyle: {
287
-              //通常情况下:
288
-
289
-              //每个柱子的颜色即为colorList数组里的每一项,如果柱子数目多于colorList的长度,则柱子颜色循环使用该数组
290
-              normal: {
291
-                color: function(params) {
292
-                  //我这边就两个柱子,大体就两个柱子颜色渐变,所以数组只有两个值,多个颜色就多个值
293
-                  var colorList = [
294
-                    ["#A9E0F3", "#9FBDFC"],
295
-
296
-                    ["#FFD7C0", "#FF9994"]
297
-                  ];
298
-
299
-                  var index = params.dataIndex;
300
-                  if (params.dataIndex >= colorList.length) {
301
-                    index = params.dataIndex % colorList.length;
302
-                  }
303
-
304
-                  return new echarts.graphic.LinearGradient(0, 0, 0, 1, [
305
-                    { offset: 0, color: colorList[index][0] },
306
-                    // { offset: 0.5, color: colorList[index][1] },
307
-                    { offset: 1, color: colorList[index][1] }
308
-                  ]);
347
+            show: false
348
+          },
349
+          series: [
350
+            {
351
+              name: '',
352
+              type: 'line',
353
+              data: [],
354
+              barWidth: 30,
355
+              label: {
356
+                normal: {
357
+                  show: true,
358
+                  position: 'top',
359
+                  formatter: '{c}'
360
+                }
361
+              },
362
+              //配置样式
363
+              itemStyle: {
364
+                //通常情况下:
365
+
366
+                //每个柱子的颜色即为colorList数组里的每一项,如果柱子数目多于colorList的长度,则柱子颜色循环使用该数组
367
+                normal: {
368
+                  color: function(params) {
369
+                    //我这边就两个柱子,大体就两个柱子颜色渐变,所以数组只有两个值,多个颜色就多个值
370
+                    var colorList = [
371
+                      ['#A9E0F3', '#9FBDFC'],
372
+
373
+                      ['#FFD7C0', '#FF9994']
374
+                    ]
375
+
376
+                    var index = params.dataIndex
377
+                    if (params.dataIndex >= colorList.length) {
378
+                      index = params.dataIndex % colorList.length
379
+                    }
380
+
381
+                    return new echarts.graphic.LinearGradient(0, 0, 0, 1, [
382
+                      { offset: 0, color: colorList[index][0] },
383
+                      // { offset: 0.5, color: colorList[index][1] },
384
+                      { offset: 1, color: colorList[index][1] }
385
+                    ])
386
+                  },
387
+                  barBorderRadius: [5, 5, 0, 0] //柱状角成椭圆形
309 388
                 },
310
-                barBorderRadius: [5, 5, 0, 0] //柱状角成椭圆形
389
+
390
+                //鼠标悬停时:
391
+                emphasis: {
392
+                  shadowBlur: 10,
393
+                  shadowOffsetX: 0,
394
+                  shadowColor: 'rgba(0, 0, 0, 0.5)'
395
+                }
396
+              }
397
+            }
398
+          ]
399
+        },
400
+        bar: {
401
+          title: {
402
+            text: 'ECharts 入门示例'
403
+          },
404
+          tooltip: {},
405
+          legend: {
406
+            data: [],
407
+            left: 0
408
+          },
409
+          xAxis: {
410
+            data: []
411
+          },
412
+          yAxis: {
413
+            axisLabel: {
414
+              formatter: '{value} %'
415
+            },
416
+            show: false
417
+          },
418
+          series: [
419
+            {
420
+              name: '',
421
+              type: 'bar',
422
+              data: [],
423
+              barWidth: 30,
424
+              label: {
425
+                normal: {
426
+                  show: true,
427
+                  position: 'top',
428
+                  formatter: '{c}次'
429
+                }
311 430
               },
431
+              //配置样式
432
+              itemStyle: {
433
+                //通常情况下:
434
+
435
+                //每个柱子的颜色即为colorList数组里的每一项,如果柱子数目多于colorList的长度,则柱子颜色循环使用该数组
436
+                normal: {
437
+                  color: function(params) {
438
+                    //我这边就两个柱子,大体就两个柱子颜色渐变,所以数组只有两个值,多个颜色就多个值
439
+                    var colorList = [
440
+                      ['#A9E0F3', '#9FBDFC'],
441
+                      ['#FFD7C0', '#FF9994']
442
+                    ]
312 443
 
313
-              //鼠标悬停时:
314
-              emphasis: {
315
-                shadowBlur: 10,
316
-                shadowOffsetX: 0,
317
-                shadowColor: "rgba(0, 0, 0, 0.5)"
444
+                    var index = params.dataIndex
445
+                    if (params.dataIndex >= colorList.length) {
446
+                      index = params.dataIndex % colorList.length
447
+                    }
448
+
449
+                    return new echarts.graphic.LinearGradient(0, 0, 0, 1, [
450
+                      { offset: 0, color: colorList[index][0] },
451
+                      // { offset: 0.5, color: colorList[index][1] },
452
+                      { offset: 1, color: colorList[index][1] }
453
+                    ])
454
+                  },
455
+                  barBorderRadius: [5, 5, 0, 0] //柱状角成椭圆形
456
+                },
457
+
458
+                //鼠标悬停时:
459
+                emphasis: {
460
+                  shadowBlur: 10,
461
+                  shadowOffsetX: 0,
462
+                  shadowColor: 'rgba(0, 0, 0, 0.5)'
463
+                }
318 464
               }
319 465
             }
320
-          }
321
-        ]
466
+          ]
467
+        }
468
+
322 469
       }
323
-    };
324
-  },
325
-  methods: {
326
-    chooseWay(way) {
327
-      this.wayType = way;
470
+    },
471
+    methods: {
472
+      jumpDetail(patient_id){
473
+        this.$router.push("/dqc/bloodpressure/detail?id="+patient_id)
474
+
475
+      },
476
+      changeProject(val){
477
+        this.query.statistics_type = val
478
+        this.query.page = 1
479
+        this.GetDialysisProcessIndexChartData(this.query)
480
+        // this.GetDialysisProcessIndexTableData(this.query)
481
+
482
+      },
483
+      handleChange(val){
484
+        this.query.patient_id = val.id
485
+        this.query.page = 1
486
+        this.GetDialysisProcessIndexTableData(this.query)
487
+        this.GetDialysisProcessIndexChartData(this.query)
488
+      },
489
+      handleSizeChange(limit) {
490
+        this.query.limit = limit;
491
+
492
+      },
493
+      handleCurrentChange(page) {
494
+        this.query.page = page;
495
+
496
+      },
497
+      changeTime(val) {
498
+        var time = this.getTimestamp(val) - this.getTimestamp(this.query.end_time);
499
+        if (time > 0) {
500
+          this.$message.error("结束时间不能小于开始时间");
501
+          this.query.start_time = "";
502
+        } else {
503
+          // this.getDialysisList()
504
+          this.query.page = 1;
505
+          this.GetDialysisProcessIndexChartData(this.query)
506
+          this.GetDialysisProcessIndexTableData(this.query)
507
+
508
+        }
509
+
510
+      },
511
+      changeEndTime(val) {
512
+        var time =
513
+          this.getTimestamp(val) - this.getTimestamp(this.query.start_time);
514
+        if (time < 0) {
515
+          this.$message.error("结束时间不能小于开始时间");
516
+          this.query.end_time = "";
517
+        } else {
518
+          this.query.page = 1;
519
+          this.GetDialysisProcessIndexChartData(this.query)
520
+          this.GetDialysisProcessIndexTableData(this.query)
521
+
522
+        }
523
+      },
524
+      getTimestamp(time) {
525
+        // 把时间日期转成时间戳
526
+        return new Date(time).getTime() / 1000;
527
+      },
528
+      QueryOperaById: function(val) {
529
+        let vascular_access_desc_name = "";
530
+        let vascular_access_desc = getDataConfig(
531
+          "hemodialysis",
532
+          "vascular_access_desc"
533
+        );
534
+        for (let i = 0; i < vascular_access_desc.length; i++) {
535
+          if (vascular_access_desc[i].id == val) {
536
+            vascular_access_desc_name = vascular_access_desc[i].name;
537
+          }
538
+        }
539
+
540
+        return vascular_access_desc_name;
541
+      },
542
+      GetAnticoagulantById: function (val) {
543
+        let anticoagulan_name = ''
544
+        var anticoagulantsConfitTwo = this.$store.getters.anticoagulants_confit
545
+        let anticoagulant = anticoagulantsConfitTwo
546
+        for (let keys in anticoagulant) {
547
+          if (anticoagulant[keys].id == val) {
548
+            anticoagulan_name = anticoagulant[keys].name
549
+          }
550
+        }
551
+        return anticoagulan_name
552
+      },
553
+      getModeName(mode_id){
554
+        return this.$store.getters.treatment_mode[mode_id] != undefined ? this.$store.getters.treatment_mode[mode_id].name: ""
555
+      },
556
+      changeTime() {
557
+
558
+      }, changeEndTime() {
559
+
560
+
561
+      }, GetDialysisProcessIndexTableData(params) {
562
+        this.loading = true
563
+        this.tableData = []
564
+        GetDialysisProcessIndexTableData(params)
565
+          .then(rs => {
566
+            var resp = rs.data
567
+            if (resp.state == 1) {
568
+              this.loading = false
569
+
570
+              for (let i = 0; i < resp.data.data.length; i++) {
571
+                this.tableData.push(resp.data.data[i])
572
+              }
573
+            } else {
574
+              this.loading = false
575
+            }
576
+          })
577
+          .catch(error => {
578
+
579
+          })
580
+      },
581
+      GetDialysisProcessIndexChartData(params) {
582
+        this.chart.xAxis.data = []
583
+        this.chart.series[0].data = []
584
+        this.bar.xAxis.data = []
585
+        this.bar.series[0].data = []
586
+        GetDialysisProcessIndexChartData(params)
587
+          .then(rs => {
588
+            var resp = rs.data
589
+            if (resp.state == 1) {
590
+              if (this.query.statistics_type != 9 && this.query.statistics_type != 10) {
591
+                for (let i = 0; i < resp.data.data.length; i++) {
592
+                  this.chart.xAxis.data.push(resp.data.data[i].date)
593
+                  this.chart.series[0].data.push(resp.data.data[i].value)
594
+                }
595
+              } else {
596
+                console.log("1111111")
597
+                console.log(this.query.statistics_type)
598
+
599
+                for (let i = 0; i < resp.data.data.length; i++) {
600
+                  this.bar.xAxis.data.push(resp.data.data[i].name)
601
+                  this.bar.series[0].data.push(resp.data.data[i].total)
602
+                }
603
+              }
604
+            } else {
605
+            }
606
+          })
607
+          .catch(error => {
608
+          })
609
+      },
610
+      handleSelect(val) {
611
+        this.query.patient_id = val.id
612
+        this.query.page = 1
613
+        this.GetDialysisProcessIndexChartData(this.query)
614
+        this.GetDialysisProcessIndexTableData(this.query)
615
+
616
+      },
617
+      querySearchAsync(keyword, cb) {
618
+        let key = ''
619
+        if (keyword != undefined) {
620
+          key = keyword
621
+        }
622
+        let searchArray = []
623
+        PostSearch(key).then(response => {
624
+          if (response.data.state == 1) {
625
+            searchArray = response.data.data.patient
626
+            cb(searchArray)
627
+          } else {
628
+            cb([])
629
+          }
630
+        })
631
+      },
632
+      chooseWay(way) {
633
+        this.wayType = way
634
+      }, getCurrentOrgPatients(){
635
+        getCurrentOrgPatients().then(response=>{
636
+          if(response.data.state == 1){
637
+            var patients = response.data.data.patients
638
+            this.patientsData = patients
639
+          }
640
+        })
641
+      },
642
+    }, created() {
643
+      var date = new Date()
644
+      var year = date.getFullYear() //获取完整的年份(4位)
645
+      var month = date.getMonth() + 1 < 10 ? '0' + (date.getMonth() + 1).toString() : date.getMonth() + 1 //获取当前月份(0-11,0代表1月)
646
+      var day = date.getDate() < 0 ? '0' + date.getDate().toString() : date.getDate() //获取当前日(1-31)
647
+      var last_month = date.getMonth() < 10 ? '0' + date.getMonth().toString() : date.getMonth() //获取当前月份(0-11,0代表1月)
648
+      this.query.patient_id = 0
649
+      this.query.end_time = year + '-' + month + '-' + day
650
+      this.query.start_time = year + '-' + last_month + '-' + day
651
+      this.query.statistics_type = 1
652
+      this.GetDialysisProcessIndexChartData(this.query)
653
+      this.GetDialysisProcessIndexTableData(this.query)
654
+      this.getCurrentOrgPatients()
655
+
656
+
328 657
     }
329 658
   }
330
-};
331 659
 </script>
332 660
 
333 661
 <style lang="scss" scoped>
334
-.tableTitle {
335
-  font-size: 16px;
336
-  color: #000;
337
-  font-weight: bold;
338
-  margin-bottom: 10px;
339
-}
662
+  .tableTitle {
663
+    font-size: 16px;
664
+    color: #000;
665
+    font-weight: bold;
666
+    margin-bottom: 10px;
667
+  }
340 668
 </style>
341 669
 <style lang="scss">
342
-.page_process {
670
+  .page_process {
671
+
343 672
   .el-button--medium {
344 673
     padding: 10px 8px;
345 674
   }
675
+
346 676
   .el-form-item {
347 677
     margin-bottom: 0;
348 678
   }
349
-}
679
+
680
+  }
350 681
 </style>

+ 463 - 257
src/xt_pages/qcd/indicatorControlAnalysis/weight.vue 查看文件

@@ -4,33 +4,48 @@
4 4
       <bread-crumb :crumbs="crumbs"></bread-crumb>
5 5
     </div>
6 6
     <div class="app-container">
7
-      <div class="page_weight">
7
+      <div class="page_process">
8 8
         <new-nav activeName="weight"></new-nav>
9 9
         <div class="cell clearfix">
10
-          <el-form :inline="true" :model="listQuery">
10
+          <el-form :inline="true">
11 11
             <el-form-item label>
12
-              <el-input v-model.trim="listQuery.search" placeholder="姓名/透析号" style="width:110px"></el-input>
13
-              <el-button type="primary" @click="onSearch" icon="el-icon-search">搜索</el-button>
12
+              <el-autocomplete
13
+                class="checkSearch"
14
+                popper-class="my-autocomplete"
15
+                v-model="search_value"
16
+                :fetch-suggestions="querySearchAsync"
17
+                :trigger-on-focus="false"
18
+                placeholder="请输入病人名字"
19
+                @select="handleSelect"
20
+              >
21
+                <i class="el-icon-search el-input__icon" slot="suffix"></i>
22
+                <template slot-scope="{ item }">
23
+                  <div class="name">{{ item.name }}</div>
24
+                </template>
25
+              </el-autocomplete>
26
+
14 27
             </el-form-item>
15 28
           </el-form>
16
-          <el-select v-model="value" placeholder="请选择" style="width:110px;margin-right:10px">
29
+          <el-select v-model="query.statistics_type" placeholder="请选择" style="width:110px;margin-right:10px" @change="changeProject">
17 30
             <el-option
18 31
               v-for="item in options"
19 32
               :key="item.value"
20
-              :label="item.label"
33
+              :label="item.name"
21 34
               :value="item.value"
35
+
22 36
             ></el-option>
23 37
           </el-select>
24 38
           <label class="title">
25 39
             <span class="name">日期查询</span> :
26 40
           </label>
27 41
           <el-date-picker
28
-            v-model="listQuery.start_time"
42
+            v-model="query.start_time"
29 43
             prefix-icon="el-icon-date"
30 44
             @change="changeTime"
31 45
             :editable="false"
32 46
             style="width: 150px;"
33 47
             type="date"
48
+            :picker-options="pickerOptions"
34 49
             placeholder="选择日期时间"
35 50
             align="right"
36 51
             format="yyyy-MM-dd"
@@ -38,10 +53,11 @@
38 53
           ></el-date-picker>
39 54
           <span class>-</span>
40 55
           <el-date-picker
41
-            v-model="listQuery.end_time"
56
+            v-model="query.end_time"
42 57
             prefix-icon="el-icon-date"
43 58
             @change="changeEndTime"
44 59
             :editable="false"
60
+            :picker-options="pickerOptions"
45 61
             style="width: 150px;"
46 62
             type="date"
47 63
             placeholder="选择日期时间"
@@ -53,37 +69,99 @@
53 69
         <el-container>
54 70
           <div style="width:150px">
55 71
             <div class="tableTitle">患者列表</div>
56
-            <el-table :data="tableData" border style="width: 100%;" height="500">
57
-              <el-table-column prop="date" label="日期" width="70"></el-table-column>
58
-              <el-table-column prop="name" label="姓名" width="80"></el-table-column>
72
+            <el-table :data="patientsData" border style="width: 100%;" height="500" :row-style="{ color: '#303133' }"
73
+                      :header-cell-style="{backgroundColor: 'rgb(245, 247, 250)',color: '#606266'}"
74
+                      highlight-current-row
75
+                      @current-change="handleChange">
76
+              <el-table-column prop="dialysis_no" label="透析号" width="80">
77
+                <template slot-scope="scope">{{scope.row.dialysis_no}}</template>
78
+              </el-table-column>
79
+              <el-table-column prop="name" label="姓名" width="80">
80
+                <template slot-scope="scope">{{ scope.row.name }}</template>
81
+              </el-table-column>
59 82
             </el-table>
60 83
           </div>
61 84
           <div style="padding-left:10px;flex:1">
62 85
             <div class="tableTitle">指标趋势</div>
63 86
             <div>
64
-              <line-chart :options="chart"></line-chart>
87
+              <line-chart :options="bar"></line-chart>
88
+
65 89
             </div>
66 90
             <div class="tableTitle">统计表</div>
67 91
             <div>
68
-              <el-table :data="tableData1" style="width: 100%" border>
69
-                <el-table-column fixed prop="date" label="日期"></el-table-column>
70
-                <el-table-column prop="name" label="姓名"></el-table-column>
71
-                <el-table-column prop="province" label="省份"></el-table-column>
72
-                <el-table-column prop="city" label="市区"></el-table-column>
73
-                <el-table-column prop="address" label="地址"></el-table-column>
74
-                <el-table-column prop="zip" label="邮编"></el-table-column>
75
-                <el-table-column label="操作" width="100">
92
+
93
+              <el-table :data="tableData" style="width: 100%" :height="tableHeight" >
94
+                <el-table-column fixed label="日期" align="center">
95
+                  <template slot-scope="scope">
96
+                    {{scope.row.assessment_date | parseTime("{y}-{m}-{d}") }}
97
+                  </template>
98
+                </el-table-column>
99
+
100
+                <el-table-column label="姓名" align="center">
101
+                  <template slot-scope="scope">
102
+                    {{scope.row.patient.name}}
103
+                  </template>
104
+                </el-table-column>
105
+
106
+                <el-table-column label="干体重" align="center">
107
+                  <template slot-scope="scope">
108
+                    {{scope.row.dry_weight?scope.row.dry_weight:''}}
109
+
110
+                    <!--{{// scope.row.patient.lapseto == 1 ? '留治':'转出'}}-->
111
+                  </template>
112
+                </el-table-column>
113
+
114
+                <el-table-column label="前次透后体重" align="center">
115
+                  <template slot-scope="scope">
116
+                    {{scope.row.last_after_weight?scope.row.last_after_weight:''}}
117
+
118
+                    <!--<div v-if="scope.row.before.systolic_blood_pressure">{{scope.row.before.systolic_blood_pressure}} / {{scope.row.before.diastolic_blood_pressure}}</div>-->
119
+                  </template>
120
+                </el-table-column>
121
+
122
+                <el-table-column label="透前体重" align="center">
123
+                  <template slot-scope="scope">
124
+                    {{scope.row.weight_before?scope.row.weight_before:''}}
125
+
126
+                    <!--<div v-if="scope.row.min_monitor.systolic_blood_pressure">{{ scope.row.min_monitor.systolic_blood_pressure}} /{{ scope.row.min_monitor.diastolic_blood_pressure}}</div>-->
127
+                  </template>
128
+                </el-table-column>
129
+
130
+                <el-table-column label="透后体重" align="center">
76 131
                   <template slot-scope="scope">
77
-                    <el-button @click="handleClick(scope.row)" type="text" size="small">查看</el-button>
132
+                    <!--<div v-if="scope.row.max_monitor.systolic_blood_pressure">{{ scope.row.max_monitor.systolic_blood_pressure}} /{{ scope.row.max_monitor.diastolic_blood_pressure}}</div>-->
133
+                    {{scope.row.after.weight_after?scope.row.after.weight_after:''}}
134
+
135
+
78 136
                   </template>
79 137
                 </el-table-column>
138
+
139
+                <el-table-column label="体重增加" align="center">
140
+                  <template slot-scope="scope">
141
+                    <div v-if="scope.row.weight_before && scope.row.last_after_weight">{{scope.row.weight_before - scope.row.last_after_weight}}</div>
142
+
143
+                    <!--{{scope.row.weight_before - scope.row.last_after_weight}}-->
144
+                    <!--<div v-if="scope.row.after.systolic_blood_pressure"> {{ scope.row.after.systolic_blood_pressure}} /{{scope.row.after.diastolic_blood_pressure}}</div>-->
145
+                  </template>
146
+                </el-table-column>
147
+
148
+                <el-table-column fixed="right" label="趋势" align="center">
149
+                  <template slot-scope="scope">
150
+                    <el-button
151
+                      @click.native.prevent="jumpDetail(scope.row.patient_id)"
152
+                      type="text"
153
+                      size="small"
154
+                    >详情</el-button>
155
+                  </template>
156
+                </el-table-column>
157
+
80 158
               </el-table>
81 159
 
82 160
               <el-pagination
83 161
                 align="right"
84 162
                 @size-change="handleSizeChange"
85 163
                 @current-change="handleCurrentChange"
86
-                :current-page="listQuery.page"
164
+                :current-page="query.page"
87 165
                 :page-sizes="[10, 20, 50, 100]"
88 166
                 :page-size="10"
89 167
                 background
@@ -101,264 +179,392 @@
101 179
 
102 180
 
103 181
 <script>
104
-import echarts from "echarts";
105
-import NewNav from "../indicatorControlAnalysis/components/NewNav";
106
-import BreadCrumb from "@/xt_pages/components/bread-crumb";
107
-import LineChart from "../../qcd/components/LineChart";
108
-export default {
109
-  components: {
110
-    LineChart,
111
-    BreadCrumb,
112
-    NewNav
113
-  },
114
-  data() {
115
-    return {
116
-      crumbs: [
117
-        { path: false, name: "科室质控" },
118
-        { path: false, name: "指标评估统计" },
119
-        { path: false, name: "患者血压统计" }
120
-      ],
121
-      listQuery: {
122
-        start_time: "",
123
-        end_time: "",
124
-        page: 1,
125
-        limit: 10
126
-      },
127
-      tableData: [
128
-        {
129
-          date: "2016",
130
-          name: "王小虎"
131
-        },
132
-        {
133
-          date: "2016",
134
-          name: "王小虎"
135
-        },
136
-        {
137
-          date: "2016",
138
-          name: "王小虎"
139
-        },
140
-        {
141
-          date: "2016",
142
-          name: "王小虎"
143
-        },
144
-        {
145
-          date: "2016",
146
-          name: "王小虎"
147
-        },
148
-        {
149
-          date: "2016",
150
-          name: "王小虎"
151
-        },
152
-        {
153
-          date: "2016",
154
-          name: "王小虎"
155
-        },
156
-        {
157
-          date: "2016",
158
-          name: "王小虎"
159
-        },
160
-        {
161
-          date: "2016",
162
-          name: "王小虎"
163
-        },
164
-        {
165
-          date: "2016",
166
-          name: "王小虎"
167
-        },
168
-        {
169
-          date: "2016",
170
-          name: "王小虎"
171
-        },
172
-        {
173
-          date: "2016",
174
-          name: "王小虎"
175
-        }
176
-      ],
177
-      tableData1: [
178
-        {
179
-          date: "2016-05-03",
180
-          name: "王小虎",
181
-          province: "上海",
182
-          city: "普陀区",
183
-          address: "上海市普陀区金沙江路 1518 弄",
184
-          zip: 200333
185
-        },
186
-        {
187
-          date: "2016-05-02",
188
-          name: "王小虎",
189
-          province: "上海",
190
-          city: "普陀区",
191
-          address: "上海市普陀区金沙江路 1518 弄",
192
-          zip: 200333
193
-        },
194
-        {
195
-          date: "2016-05-04",
196
-          name: "王小虎",
197
-          province: "上海",
198
-          city: "普陀区",
199
-          address: "上海市普陀区金沙江路 1518 弄",
200
-          zip: 200333
201
-        },
202
-        {
203
-          date: "2016-05-01",
204
-          name: "王小虎",
205
-          province: "上海",
206
-          city: "普陀区",
207
-          address: "上海市普陀区金沙江路 1518 弄",
208
-          zip: 200333
209
-        },
210
-        {
211
-          date: "2016-05-08",
212
-          name: "王小虎",
213
-          province: "上海",
214
-          city: "普陀区",
215
-          address: "上海市普陀区金沙江路 1518 弄",
216
-          zip: 200333
217
-        },
218
-        {
219
-          date: "2016-05-06",
220
-          name: "王小虎",
221
-          province: "上海",
222
-          city: "普陀区",
223
-          address: "上海市普陀区金沙江路 1518 弄",
224
-          zip: 200333
225
-        },
226
-        {
227
-          date: "2016-05-07",
228
-          name: "王小虎",
229
-          province: "上海",
230
-          city: "普陀区",
231
-          address: "上海市普陀区金沙江路 1518 弄",
232
-          zip: 200333
233
-        },
234
-        {
235
-          date: "2016-05-08",
236
-          name: "王小虎",
237
-          province: "上海",
238
-          city: "普陀区",
239
-          address: "上海市普陀区金沙江路 1518 弄",
240
-          zip: 200333
241
-        },
242
-        {
243
-          date: "2016-05-06",
244
-          name: "王小虎",
245
-          province: "上海",
246
-          city: "普陀区",
247
-          address: "上海市普陀区金沙江路 1518 弄",
248
-          zip: 200333
249
-        },
250
-        {
251
-          date: "2016-05-07",
252
-          name: "王小虎",
253
-          province: "上海",
254
-          city: "普陀区",
255
-          address: "上海市普陀区金沙江路 1518 弄",
256
-          zip: 200333
257
-        }
258
-      ],
259
-      chart: {
260
-        title: {
261
-          text: "ECharts 入门示例"
262
-        },
263
-        tooltip: {},
264
-        legend: {
265
-          data: ["次数"],
266
-          left: 0
182
+  import echarts from 'echarts'
183
+  import NewNav from '../indicatorControlAnalysis/components/NewNav'
184
+  import BreadCrumb from '@/xt_pages/components/bread-crumb'
185
+  import LineChart from '../../qcd/components/LineChart'
186
+  import { getCurrentOrgPatients } from "@/api/common/common";
187
+  import {GetDialysisWeightChartData,GetDialysisWeightTableData} from "@/api/common/statistics"
188
+
189
+  import {
190
+    PostSearch
191
+  } from '@/api/patient'
192
+
193
+  import { uParseTime } from "@/utils/tools";
194
+  import { getDataConfig } from "@/utils/data";
195
+
196
+  export default {
197
+    components: {
198
+      LineChart,
199
+      BreadCrumb,
200
+      NewNav
201
+    },
202
+    data() {
203
+      return {
204
+        pickerOptions: {
205
+          disabledDate(time) {
206
+            let threeMonths = new Date(new Date().setFullYear(new Date().getFullYear()-1)).getTime() - 24 * 3600 * 1000;
207
+            return time.getTime() > Date.now() || time.getTime() < threeMonths;;
208
+          }
267 209
         },
268
-        xAxis: {
269
-          data: ["达标", "未达标"]
210
+        patientsData:[],
211
+        tableData: [
212
+        ],
213
+        loading: false,
214
+        search_value: '',
215
+        total: '',
216
+        query: {
217
+          patient_id: '',
218
+          statistics_type: 1,
219
+          start_time: '',
220
+          end_time: '',
221
+          limit: 10,
222
+          page: 1
270 223
         },
271
-        yAxis: {
272
-          axisLabel: {
273
-            formatter: "{value} %"
224
+        options: [
225
+          { value: 1, name: '干体重' },
226
+          { value: 2, name: '透前体重' },
227
+          { value: 3, name: '体重增加' },
228
+          { value: 4, name: '透后体重' },
229
+        ],
230
+        crumbs: [
231
+          { path: false, name: '科室质控' },
232
+          { path: false, name: '指标评估统计' },
233
+          { path: false, name: '透析过程指标统计' }
234
+        ],
235
+        tableData1: [],
236
+        chart: {
237
+          title: {
238
+            text: 'ECharts 入门示例'
274 239
           },
275
-          show: false
276
-        },
277
-        series: [
278
-          {
279
-            name: "次数",
280
-            type: "bar",
281
-            data: ["78.57", "50"],
282
-            barWidth: 30,
283
-            label: {
284
-              normal: {
285
-                show: true,
286
-                position: "top",
287
-                formatter: "{c}次"
288
-              }
240
+          tooltip: {},
241
+          legend: {
242
+            data: [],
243
+            left: 0
244
+          },
245
+          xAxis: {
246
+            data: []
247
+          },
248
+          yAxis: {
249
+            axisLabel: {
250
+              formatter: '{value} %'
289 251
             },
290
-            //配置样式
291
-            itemStyle: {
292
-              //通常情况下:
293
-
294
-              //每个柱子的颜色即为colorList数组里的每一项,如果柱子数目多于colorList的长度,则柱子颜色循环使用该数组
295
-              normal: {
296
-                color: function(params) {
297
-                  //我这边就两个柱子,大体就两个柱子颜色渐变,所以数组只有两个值,多个颜色就多个值
298
-                  var colorList = [
299
-                    ["#A9E0F3", "#9FBDFC"],
300
-
301
-                    ["#FFD7C0", "#FF9994"]
302
-                  ];
303
-
304
-                  var index = params.dataIndex;
305
-                  if (params.dataIndex >= colorList.length) {
306
-                    index = params.dataIndex % colorList.length;
307
-                  }
308
-
309
-                  return new echarts.graphic.LinearGradient(0, 0, 0, 1, [
310
-                    { offset: 0, color: colorList[index][0] },
311
-                    // { offset: 0.5, color: colorList[index][1] },
312
-                    { offset: 1, color: colorList[index][1] }
313
-                  ]);
252
+            show: false
253
+          },
254
+          series: [
255
+            {
256
+              name: '',
257
+              type: 'line',
258
+              data: [],
259
+              barWidth: 30,
260
+              label: {
261
+                normal: {
262
+                  show: true,
263
+                  position: 'top',
264
+                  formatter: '{c}'
265
+                }
266
+              },
267
+              //配置样式
268
+              itemStyle: {
269
+                //通常情况下:
270
+
271
+                //每个柱子的颜色即为colorList数组里的每一项,如果柱子数目多于colorList的长度,则柱子颜色循环使用该数组
272
+                normal: {
273
+                  color: function(params) {
274
+                    //我这边就两个柱子,大体就两个柱子颜色渐变,所以数组只有两个值,多个颜色就多个值
275
+                    var colorList = [
276
+                      ['#A9E0F3', '#9FBDFC'],
277
+
278
+                      ['#FFD7C0', '#FF9994']
279
+                    ]
280
+
281
+                    var index = params.dataIndex
282
+                    if (params.dataIndex >= colorList.length) {
283
+                      index = params.dataIndex % colorList.length
284
+                    }
285
+
286
+                    return new echarts.graphic.LinearGradient(0, 0, 0, 1, [
287
+                      { offset: 0, color: colorList[index][0] },
288
+                      // { offset: 0.5, color: colorList[index][1] },
289
+                      { offset: 1, color: colorList[index][1] }
290
+                    ])
291
+                  },
292
+                  barBorderRadius: [5, 5, 0, 0] //柱状角成椭圆形
314 293
                 },
315
-                barBorderRadius: [5, 5, 0, 0] //柱状角成椭圆形
294
+
295
+                //鼠标悬停时:
296
+                emphasis: {
297
+                  shadowBlur: 10,
298
+                  shadowOffsetX: 0,
299
+                  shadowColor: 'rgba(0, 0, 0, 0.5)'
300
+                }
301
+              }
302
+            }
303
+          ]
304
+        },
305
+        bar: {
306
+          title: {
307
+            text: 'ECharts 入门示例'
308
+          },
309
+          tooltip: {},
310
+          legend: {
311
+            data: [],
312
+            left: 0
313
+          },
314
+          xAxis: {
315
+            data: []
316
+          },
317
+          yAxis: {
318
+            axisLabel: {
319
+              formatter: '{value} %'
320
+            },
321
+            show: false
322
+          },
323
+          series: [
324
+            {
325
+              name: '',
326
+              type: 'bar',
327
+              data: [],
328
+              barWidth: 30,
329
+              label: {
330
+                normal: {
331
+                  show: true,
332
+                  position: 'top',
333
+                  formatter: '{c}次'
334
+                }
316 335
               },
336
+              //配置样式
337
+              itemStyle: {
338
+                //通常情况下:
339
+
340
+                //每个柱子的颜色即为colorList数组里的每一项,如果柱子数目多于colorList的长度,则柱子颜色循环使用该数组
341
+                normal: {
342
+                  color: function(params) {
343
+                    //我这边就两个柱子,大体就两个柱子颜色渐变,所以数组只有两个值,多个颜色就多个值
344
+                    var colorList = [
345
+                      ['#A9E0F3', '#9FBDFC'],
346
+                      ['#FFD7C0', '#FF9994']
347
+                    ]
348
+
349
+                    var index = params.dataIndex
350
+                    if (params.dataIndex >= colorList.length) {
351
+                      index = params.dataIndex % colorList.length
352
+                    }
317 353
 
318
-              //鼠标悬停时:
319
-              emphasis: {
320
-                shadowBlur: 10,
321
-                shadowOffsetX: 0,
322
-                shadowColor: "rgba(0, 0, 0, 0.5)"
354
+                    return new echarts.graphic.LinearGradient(0, 0, 0, 1, [
355
+                      { offset: 0, color: colorList[index][0] },
356
+                      // { offset: 0.5, color: colorList[index][1] },
357
+                      { offset: 1, color: colorList[index][1] }
358
+                    ])
359
+                  },
360
+                  barBorderRadius: [5, 5, 0, 0] //柱状角成椭圆形
361
+                },
362
+
363
+                //鼠标悬停时:
364
+                emphasis: {
365
+
366
+                  shadowBlur: 10,
367
+                  shadowOffsetX: 0,
368
+                  shadowColor: 'rgba(0, 0, 0, 0.5)'
369
+                }
323 370
               }
324 371
             }
325
-          }
326
-        ]
372
+          ]
373
+        }
374
+
327 375
       }
328
-    };
329
-  },
330
-  methods: {
331
-    chooseWay(way) {
332
-      this.wayType = way;
333 376
     },
334
-    handleClick(row) {
335
-      console.log(row);
336
-      this.$router.push({
337
-        path: "/qcd/indicatorControlAnalysis/weightDetails"
338
-      });
377
+    methods: {
378
+      changeProject(val){
379
+        this.query.statistics_type = val
380
+        this.query.page = 1
381
+        this.GetDialysisWeightChartData(this.query)
382
+
383
+      },
384
+      handleChange(val){
385
+        this.query.patient_id = val.id
386
+        this.query.page = 1
387
+        this.GetDialysisWeightTableData(this.query)
388
+        this.GetDialysisWeightChartData(this.query)
389
+      },
390
+      handleSizeChange(limit) {
391
+        this.query.limit = limit;
392
+
393
+      },
394
+      handleCurrentChange(page) {
395
+        this.query.page = page;
396
+
397
+      },
398
+      changeTime(val) {
399
+        var time = this.getTimestamp(val) - this.getTimestamp(this.query.end_time);
400
+        if (time > 0) {
401
+          this.$message.error("结束时间不能小于开始时间");
402
+          this.query.start_time = "";
403
+        } else {
404
+          // this.getDialysisList()
405
+          this.query.page = 1;
406
+          this.GetDialysisWeightChartData(this.query)
407
+          this.GetDialysisWeightTableData(this.query)
408
+
409
+        }
410
+
411
+      },
412
+      changeEndTime(val) {
413
+        var time =
414
+          this.getTimestamp(val) - this.getTimestamp(this.query.start_time);
415
+        if (time < 0) {
416
+          this.$message.error("结束时间不能小于开始时间");
417
+          this.query.end_time = "";
418
+        } else {
419
+          this.query.page = 1;
420
+          this.GetDialysisWeightChartData(this.query)
421
+          this.GetDialysisWeightTableData(this.query)
422
+
423
+        }
424
+      },
425
+      getTimestamp(time) {
426
+        // 把时间日期转成时间戳
427
+        return new Date(time).getTime() / 1000;
428
+      },
429
+      QueryOperaById: function(val) {
430
+        let vascular_access_desc_name = "";
431
+        let vascular_access_desc = getDataConfig(
432
+          "hemodialysis",
433
+          "vascular_access_desc"
434
+        );
435
+        for (let i = 0; i < vascular_access_desc.length; i++) {
436
+          if (vascular_access_desc[i].id == val) {
437
+            vascular_access_desc_name = vascular_access_desc[i].name;
438
+          }
439
+        }
440
+
441
+        return vascular_access_desc_name;
442
+      },
443
+      GetAnticoagulantById: function (val) {
444
+        let anticoagulan_name = ''
445
+        var anticoagulantsConfitTwo = this.$store.getters.anticoagulants_confit
446
+        let anticoagulant = anticoagulantsConfitTwo
447
+        for (let keys in anticoagulant) {
448
+          if (anticoagulant[keys].id == val) {
449
+            anticoagulan_name = anticoagulant[keys].name
450
+          }
451
+        }
452
+        return anticoagulan_name
453
+      },
454
+      getModeName(mode_id){
455
+        return this.$store.getters.treatment_mode[mode_id] != undefined ? this.$store.getters.treatment_mode[mode_id].name: ""
456
+      },
457
+      changeTime() {
458
+
459
+      }, changeEndTime() {
460
+
461
+
462
+      }, GetDialysisWeightTableData(params) {
463
+        this.loading = true
464
+        this.tableData = []
465
+        GetDialysisWeightTableData(params)
466
+          .then(rs => {
467
+            var resp = rs.data
468
+            if (resp.state == 1) {
469
+              this.loading = false
470
+
471
+              for (let i = 0; i < resp.data.data.length; i++) {
472
+                this.tableData.push(resp.data.data[i])
473
+              }
474
+            } else {
475
+              this.loading = false
476
+            }
477
+          })
478
+          .catch(error => {
479
+
480
+          })
481
+      },
482
+      GetDialysisWeightChartData(params) {
483
+        this.bar.xAxis.data = []
484
+        this.bar.series[0].data = []
485
+        GetDialysisWeightChartData(params)
486
+          .then(rs => {
487
+            var resp = rs.data
488
+            if (resp.state == 1) {
489
+              for (let i = 0; i < resp.data.data.length; i++) {
490
+                this.bar.xAxis.data.push(resp.data.data[i].name)
491
+                this.bar.series[0].data.push(resp.data.data[i].total)
492
+              }
493
+            } else {
494
+            }
495
+          })
496
+          .catch(error => {
497
+          })
498
+      },
499
+      handleSelect(val) {
500
+        this.query.patient_id = val.id
501
+        this.query.page = 1
502
+        this.GetDialysisWeightChartData(this.query)
503
+        this.GetDialysisWeightTableData(this.query)
504
+
505
+      },
506
+      querySearchAsync(keyword, cb) {
507
+        let key = ''
508
+        if (keyword != undefined) {
509
+          key = keyword
510
+        }
511
+        let searchArray = []
512
+        PostSearch(key).then(response => {
513
+          if (response.data.state == 1) {
514
+            searchArray = response.data.data.patient
515
+            cb(searchArray)
516
+          } else {
517
+            cb([])
518
+          }
519
+        })
520
+      },
521
+      chooseWay(way) {
522
+        this.wayType = way
523
+      }, getCurrentOrgPatients(){
524
+        getCurrentOrgPatients().then(response=>{
525
+          if(response.data.state == 1){
526
+            var patients = response.data.data.patients
527
+            this.patientsData = patients
528
+          }
529
+        })
530
+      },
531
+    }, created() {
532
+      var date = new Date()
533
+      var year = date.getFullYear() //获取完整的年份(4位)
534
+      var month = date.getMonth() + 1 < 10 ? '0' + (date.getMonth() + 1).toString() : date.getMonth() + 1 //获取当前月份(0-11,0代表1月)
535
+      var day = date.getDate() < 0 ? '0' + date.getDate().toString() : date.getDate() //获取当前日(1-31)
536
+      var last_month = date.getMonth() < 10 ? '0' + date.getMonth().toString() : date.getMonth() //获取当前月份(0-11,0代表1月)
537
+      this.query.patient_id = 0
538
+      this.query.end_time = year + '-' + month + '-' + day
539
+      this.query.start_time = year + '-' + last_month + '-' + day
540
+      this.query.statistics_type = 1
541
+      this.GetDialysisWeightChartData(this.query)
542
+      this.GetDialysisWeightTableData(this.query)
543
+      this.getCurrentOrgPatients()
544
+
545
+
339 546
     }
340 547
   }
341
-};
342 548
 </script>
343 549
 
344 550
 <style lang="scss" scoped>
345
-.tableTitle {
346
-  font-size: 16px;
347
-  color: #000;
348
-  font-weight: bold;
349
-  margin-bottom: 10px;
350
-}
551
+  .tableTitle {
552
+    font-size: 16px;
553
+    color: #000;
554
+    font-weight: bold;
555
+    margin-bottom: 10px;
556
+  }
351 557
 </style>
352 558
 <style lang="scss">
353
-.page_weight {
559
+  .page_process {
560
+
354 561
   .el-button--medium {
355 562
     padding: 10px 8px;
356 563
   }
564
+
357 565
   .el-form-item {
358 566
     margin-bottom: 0;
359 567
   }
360
-  .cell {
361
-    text-align: center;
568
+
362 569
   }
363
-}
364 570
 </style>

+ 0 - 1
src/xt_pages/workforce/template.vue 查看文件

@@ -121,7 +121,6 @@
121 121
           <template-table :editable="true" :device_numbers="device_numbers" :template="first_template"
122 122
                           :patients="patients"></template-table>
123 123
         </el-tab-pane>
124
-        
125 124
 
126 125
         <el-tab-pane name="second" :disabled="template_mode.mode != 2">
127 126
           <span slot="label"> 第二周 </span>