瀏覽代碼

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

see999 3 年之前
父節點
當前提交
7f0aa1b8b2

+ 12 - 0
src/api/his/his.js 查看文件

@@ -519,6 +519,18 @@ export function refunddetail(params) {
519 519
 
520 520
 
521 521
 
522
+export function getPrivateExpensesOrder(params) {
523
+  return request({
524
+    url: "/api/privateexpensesorder/get",
525
+    method: "get",
526
+    params:params,
527
+  });
528
+}
529
+
530
+
531
+
532
+
533
+
522 534
 
523 535
 
524 536
 

+ 8 - 0
src/api/patient.js 查看文件

@@ -468,3 +468,11 @@ export function getAccessList(params) {
468 468
     params: params
469 469
   })
470 470
 }
471
+
472
+export function getInitDataList(params) {
473
+  return request({
474
+    url: '/api/patient/getinitdatelist',
475
+    method: 'get',
476
+    params: params
477
+  })
478
+}

+ 3 - 0
src/xt_pages/data/druguseTemplate.vue 查看文件

@@ -1818,10 +1818,12 @@
1818 1818
       },
1819 1819
       handleSelect1(){
1820 1820
        this.templateForm.drug_id =  val.id
1821
+       this.templateForm.way = 1
1821 1822
       },
1822 1823
       handleSelect(val){
1823 1824
         console.log("val23232",val)
1824 1825
         this.templateForm.drug_id =  val.id
1826
+        this.templateForm.way = 1
1825 1827
       },
1826 1828
       submitTemplate(formName) {
1827 1829
 
@@ -2379,6 +2381,7 @@
2379 2381
           }).join(',')
2380 2382
           this.templateForm.way = 1
2381 2383
         }
2384
+        this.templateForm.way = 1
2382 2385
         console.log("编辑模板",this.templateForm)
2383 2386
       
2384 2387
         // 编辑创建医嘱模版

+ 4 - 1
src/xt_pages/dialysis/details/dialog/DoctorAdviceDialog.vue 查看文件

@@ -1315,10 +1315,13 @@
1315 1315
 
1316 1316
               if(msg == 2){
1317 1317
                 this.$message.error("库存不足,请入库")
1318
-                return
1318
+                this.execTimeDialogVisible = false
1319
+                return false
1319 1320
               }
1320 1321
               if(msg == 3){
1321 1322
                 this.$message.error("无库存,请入库")
1323
+                this.execTimeDialogVisible = false
1324
+                return false
1322 1325
               }
1323 1326
               
1324 1327
             }

+ 42 - 6
src/xt_pages/outpatientCharges/listPrint.vue 查看文件

@@ -14,8 +14,10 @@
14 14
     </template>
15 15
 
16 16
     <div class='dialysisPage' style="padding-top:40px;">
17
-      <printOne v-if="org_id != 10106" :list="list" :patient="patient" :order="order" :admin="admin"></printOne>
18
-      <printTwo v-if="org_id == 10106" :info="info" :order_infos="order_infos" :p_admin="p_admin" :charge_admin="charge_admin"></printTwo>
17
+      <printOne v-if="org_id != 10106 && this.paramsObj.balance_accounts_type != 2" :list="list" :patient="patient" :order="order" :admin="admin"></printOne>
18
+      <printTwo v-if="org_id == 10106 && this.paramsObj.balance_accounts_type != 2" :info="info" :order_infos="order_infos" :p_admin="p_admin" :charge_admin="charge_admin"></printTwo>
19
+      <!--<printThree v-if="org_id == 0 && this.paramsObj.balance_accounts_type == 2" :info="info" :order_infos="order_infos" :p_admin="p_admin" :charge_admin="charge_admin"></printThree>-->
20
+      <print-three v-if="org_id == 10106 && this.paramsObj.balance_accounts_type == 2" :info="info" :order_infos="order_infos" :p_admin="p_admin" :charge_admin="charge_admin"></print-three>
19 21
     </div>
20 22
   </div>
21 23
 </template>
@@ -23,13 +25,17 @@
23 25
 <script>
24 26
   import printOne from './listTemplate/printOne'
25 27
   import printTwo from './listTemplate/printTwo'
26
-  import { getHisOrderDetail } from '@/api/his/his'
28
+  // import printThree from './listTemplate/printThree'
29
+
30
+  import { getHisOrderDetail,getPrivateExpensesOrder } from '@/api/his/his'
27 31
   import { uParseTime } from '@/utils/tools'
28 32
   import axios from 'axios'
33
+  import PrintThree from './listTemplate/printThree'
29 34
 
30 35
   export default {
31 36
     name: 'listPrint',
32 37
     components: {
38
+      PrintThree,
33 39
       printOne,
34 40
       printTwo
35 41
     },
@@ -42,8 +48,7 @@
42 48
         patient:{},
43 49
         order:{},
44 50
         admin:{},
45
-
46
-
51
+        order_infos:null,
47 52
         info:null,
48 53
         p_admin:{},
49 54
         charge_admin:{},
@@ -54,7 +59,16 @@
54 59
       this.getInfo(this.paramsObj.id)
55 60
       this.org_id = this.$store.getters.xt_user.org_id
56 61
       if(this.org_id == 10106){
57
-        this.getInfo10106(this.paramsObj.id)
62
+        if(this.paramsObj.balance_accounts_type == 2){
63
+
64
+          this.getInfoPrivateExpenses10106(this.paramsObj.id)
65
+
66
+        }else{
67
+          this.getInfo10106(this.paramsObj.id)
68
+
69
+
70
+
71
+        }
58 72
       }
59 73
 
60 74
     },
@@ -204,6 +218,28 @@
204 218
         //     scanStyles: false
205 219
         //   });
206 220
         // }
221
+      },getInfoPrivateExpenses10106(order_id){
222
+        let params = {
223
+          order_id: order_id,
224
+          admin_user_id:this.$store.getters.xt_user.user.id
225
+        }
226
+
227
+        getPrivateExpensesOrder(params).then(response => {
228
+          if (response.data.state == 0) {
229
+            this.$message.error(response.data.msg)
230
+            return false
231
+          } else {
232
+            this.info = response.data.data.info
233
+            this.info['org_name'] = response.data.data.org_name
234
+            this.info['date'] = response.data.data.date
235
+            this.info['number'] = response.data.data.number
236
+            this.info['name'] = response.data.data.name
237
+            this.p_admin = response.data.data.printor_admin
238
+            this.charge_admin = response.data.data.charge_admin
239
+            this.order_infos = response.data.data
240
+          }
241
+        })
242
+
207 243
       },
208 244
       getInfo10106(order_id) {
209 245
         if (this.$store.getters.xt_user.org_id == 3877 || this.$store.getters.xt_user.org_id == 9919 || this.$store.getters.xt_user.org_id == 4  || this.$store.getters.xt_user.org_id == 9538 || this.$store.getters.xt_user.org_id == 9671 ||  this.$store.getters.xt_user.org_id == 9674 || this.$store.getters.xt_user.org_id == 10106 || this.$store.getters.xt_user.org_id == 9990 ) {

+ 300 - 0
src/xt_pages/outpatientCharges/listTemplate/printThree.vue 查看文件

@@ -0,0 +1,300 @@
1
+<template>
2
+    <div id="statement-print" class="statement-print">
3
+        <div class="statementTitle" style="margin-top:20px;" >医保费用明细清单</div>
4
+        <!--<div class="statementTitle" style="margin-top:20px;" v-if="info.insutype == '390'">医保费用明细清单</div>-->
5
+
6
+        <div style="display:flex">
7
+            <div style="width:70%">医疗机构名称:{{info.org_name}}</div>
8
+            <!--<div style="width:30%" v-if="info.hosp_lv == '1'">医院等级:三级特等</div>-->
9
+            <!--<div style="width:30%" v-if="info.hosp_lv == '2'">医院等级:三级甲等</div>-->
10
+            <!--<div style="width:30%" v-if="info.hosp_lv == '3'">医院等级:三级乙等</div>-->
11
+            <!--<div style="width:30%" v-if="info.hosp_lv == '4'">医院等级:三级丙等</div>-->
12
+            <!--<div style="width:30%" v-if="info.hosp_lv == '5'">医院等级:二级甲等</div>-->
13
+            <!--<div style="width:30%" v-if="info.hosp_lv == '6'">医院等级:二级乙等</div>-->
14
+            <!--<div style="width:30%" v-if="info.hosp_lv == '7'">医院等级:二级丙等</div>-->
15
+            <!--<div style="width:30%" v-if="info.hosp_lv == '8'">医院等级:一级甲等</div>-->
16
+            <!--<div style="width:30%" v-if="info.hosp_lv == '9'">医院等级:一级乙等</div>-->
17
+            <!--<div style="width:30%" v-if="info.hosp_lv == '10'">医院等级:一级丙等</div>-->
18
+            <!--<div style="width:30%" v-if="info.hosp_lv == '11'">医院等级:无等级</div>-->
19
+
20
+        </div>
21
+        <div style="display:flex;justify-content: space-between;border-bottom:1px solid #000;padding-bottom:10px;">
22
+            <div style="flex:1;">单据编码:{{info.number}}</div>
23
+            <div style="width:33%">就诊时间:{{getTime(info.date)}}</div>
24
+            <div>金额单位:元</div>
25
+        </div>
26
+        <div style="display:flex">
27
+            <div style="width:50%">姓名:{{info.name}}</div>
28
+            <!--<div style="width:50%">个人电脑号:{{info.psn_no}}</div>-->
29
+        </div>
30
+        <div style="display:flex">
31
+            <div style="width:50%">社保卡号</div>
32
+            <div style="width:50%">诊断:慢性肾脏病5期</div>
33
+        </div>
34
+        <!--<div style="display:flex">-->
35
+            <!--<div style="width:50%" v-if="info.psn_type == '11'">人员类别:在职</div>-->
36
+            <!--<div style="width:50%" v-if="info.psn_type == '1101'">人员类别:职工在职</div>-->
37
+            <!--<div style="width:50%" v-if="info.psn_type == '1102'">人员类别:公务员在职</div>-->
38
+            <!--<div style="width:50%" v-if="info.psn_type == '1103'">人员类别:灵活就业人员在职</div>-->
39
+            <!--<div style="width:50%" v-if="info.psn_type == '1160'">人员类别:地方其他扩展人员</div>-->
40
+            <!--<div style="width:50%" v-if="info.psn_type == '12'">人员类别:退休人员</div>-->
41
+            <!--<div style="width:50%" v-if="info.psn_type == '1201'">人员类别:职工退休</div>-->
42
+            <!--<div style="width:50%" v-if="info.psn_type == '1202'">人员类别:公务员退休</div>-->
43
+            <!--<div style="width:50%" v-if="info.psn_type == '1203'">人员类别:灵活就业人员退休</div>-->
44
+            <!--<div style="width:50%" v-if="info.psn_type == '1260'">人员类别:地方其他扩展人员</div>-->
45
+            <!--<div style="width:50%" v-if="info.psn_type == '13'">人员类别:离休</div>-->
46
+            <!--<div style="width:50%" v-if="info.psn_type == '1300'">人员类别:离休人员</div>-->
47
+            <!--<div style="width:50%" v-if="info.psn_type == '1360'">人员类别:地方其他扩展人员</div>-->
48
+            <!--<div style="width:50%" v-if="info.psn_type == '14'">人员类别:居民(未成年)</div>-->
49
+            <!--<div style="width:50%" v-if="info.psn_type == '1401'">人员类别:新生儿</div>-->
50
+            <!--<div style="width:50%" v-if="info.psn_type == '1402'">人员类别:学龄前儿童</div>-->
51
+            <!--<div style="width:50%" v-if="info.psn_type == '1403'">人员类别:中小学生</div>-->
52
+            <!--<div style="width:50%" v-if="info.psn_type == '1404'">人员类别:大学生</div>-->
53
+            <!--<div style="width:50%" v-if="info.psn_type == '1405'">人员类别:未成年(未入学)</div>-->
54
+            <!--<div style="width:50%" v-if="info.psn_type == '15'">人员类别:居民(成年)</div>-->
55
+            <!--<div style="width:50%" v-if="info.psn_type == '1501'">人员类别:普通居民(成年)</div>-->
56
+            <!--<div style="width:50%" v-if="info.psn_type == '1560'">人员类别:地方其他扩展身份</div>-->
57
+            <!--<div style="width:50%" v-if="info.psn_type == '16'">人员类别:居民(老年)</div>-->
58
+
59
+
60
+            <!--<div style="width:50%">待遇类别:</div>-->
61
+        <!--</div>-->
62
+        <div style="display:flex;padding:10px 0;border-top:1px solid #000;border-bottom:1px solid #000;">
63
+            <div style="width:20%;text-align:center;">医保编码</div>
64
+            <div style="width:20%;text-align:center;">项目名称</div>
65
+            <div style="width:10%;text-align:center;">单价</div>
66
+            <div style="width:10%;text-align:center;">数量</div>
67
+            <div style="width:10%;text-align:center;">金额</div>
68
+            <div style="width:10%;text-align:center;">先行自付金额</div>
69
+            <div style="width:10%;text-align:center;">自费</div>
70
+            <div style="width:10%;text-align:center;">自费比例</div>
71
+        </div>
72
+        <div v-for="(newItem,index) in Object.keys(obj)" :key="index">
73
+            <div v-if="Object.values(obj)[index].length > 0"  style="border-bottom:1px solid #000;padding:10px 0;">
74
+                <span v-if="Object.keys(obj)[index] == 'med_chrgitm_type01'">床位费<span>小记:{{ price01 }}</span></span>
75
+                <span v-if="Object.keys(obj)[index] == 'med_chrgitm_type03'">检查费<span>小记:{{ price03 }}</span></span>
76
+                <span v-if="Object.keys(obj)[index] == 'med_chrgitm_type04'">化验费<span>小记:{{ price04 }}</span></span>
77
+                <span v-if="Object.keys(obj)[index] == 'med_chrgitm_type05'">治疗费<span>小记:{{ price05 }}</span></span>
78
+                <span v-if="Object.keys(obj)[index] == 'med_chrgitm_type06'">手术费<span>小记:{{ price06 }}</span></span>
79
+                <span v-if="Object.keys(obj)[index] == 'med_chrgitm_type08'">材料费<span>小记:{{ price08 }}</span></span>
80
+                <span v-if="Object.keys(obj)[index] == 'med_chrgitm_type09'">西药费<span>小记:{{ price09 }}</span></span>
81
+                <span v-if="Object.keys(obj)[index] == 'med_chrgitm_type11'">中成费<span>小记:{{ price11 }}</span></span>
82
+                <span v-if="Object.keys(obj)[index] == 'med_chrgitm_type14'">其他费<span>小记:{{ price14 }}</span></span>
83
+            </div>
84
+            <div>
85
+                <div v-if="Object.values(obj)[index].length > 0" v-for="(item,itemIndex) in Object.values(obj)[index]" :key="itemIndex" style="border-bottom:1px solid #000;padding:10px 0;display:flex;" >
86
+                    <div style="width:20%;text-align:center;" v-if="item.advice_id > 0">{{ item.advice.drug.medical_insurance_number }}</div>
87
+                    <div style="width:20%;text-align:center;" v-if="item.project_id > 0">{{item.project.type == 2?item.project.project.medical_code: item.project.good_info.medical_insurance_number}}</div>
88
+                    <div style="width:20%;text-align:center;" v-if="item.advice_id > 0">{{item.advice.drug.drug_name}}</div>
89
+                    <div style="width:20%;text-align:center;" v-if="item.project_id > 0">{{item.project.type == 2?item.project.project.project_name:item.project.good_info.good_name}}</div>
90
+
91
+                    <div style="width:10%;text-align:center;">{{item.pric}}</div>
92
+                    <div style="width:10%;text-align:center;">{{item.cnt}}</div>
93
+                    <div style="width:10%;text-align:center;">{{item.det_item_fee_sumamt}}</div>
94
+                    <div style="width:10%;text-align:center;">{{item.preselfpay_amt}}</div>
95
+                    <div style="width:10%;text-align:center;">{{item.fulamt_ownpay_amt}}</div>
96
+                    <div style="width:10%;text-align:center;">{{item.selfpay_prop}}</div>
97
+                </div>
98
+            </div>
99
+        </div>
100
+
101
+        <div style="display:flex;border-bottom:1px solid #000;padding:20px 0 10px;">
102
+            <div style="width:70%;">合计:</div>
103
+            <div style="width:10%;text-align:center;">{{info.medfee_sumamt}}</div>
104
+            <div style="width:20%;"></div>
105
+        </div>
106
+        <div>医保基金支付金额:{{''}}</div>
107
+        <div>个人现金支付金额:{{info.medfee_sumamt}}</div>
108
+        <div>其中</div>
109
+        <div style="display:flex;border-bottom:1px solid #000;padding-bottom:10px;">
110
+            <div>个人自付:</div>
111
+            <div>其中:1.乙类自付 {{''}}</div>
112
+            <div style="margin-left:20px;">2.自费 {{info.medfee_sumamt}}</div>
113
+        </div>
114
+        <div style="display:flex;padding-top:10px;">
115
+            <div style="width:33%">参保人签名:</div>
116
+            <div style="width:33%">审核人:</div>
117
+            <div style="width:33%">医院盖章:</div>
118
+        </div>
119
+
120
+    </div>
121
+    <!-- <div>
122
+        123
123
+    <div v-for='(item,index) in Object.values(obj)' :key="index">
124
+        <div>{{Object.keys(obj)[index]}}</div>
125
+        <div v-for="it in Object.values(obj)[index]">{{ it.name }}</div>
126
+    </div>
127
+    </div> -->
128
+</template>
129
+<script>
130
+  import {uParseTime} from '@/utils/tools'
131
+  export default {
132
+    props: {
133
+      info: {
134
+        type: Object,
135
+        default: function () {
136
+          return {}
137
+        }
138
+      },
139
+      order_infos: {
140
+        type: Object,
141
+        default: function () {
142
+          return {}
143
+        }
144
+      },
145
+      p_admin: {
146
+        type: Object,
147
+        default: function () {
148
+          return {}
149
+        }
150
+      }, charge_admin: {
151
+        type: Object,
152
+        default: function () {
153
+          return {}
154
+        }
155
+      }
156
+    },
157
+    data(){
158
+      return{
159
+        obj:{},
160
+        price01: 0,
161
+        price03: 0,
162
+        price04: 0,
163
+        price05: 0,
164
+        price06: 0,
165
+        price08: 0,
166
+        price09: 0,
167
+        price11: 0,
168
+        price14: 0,
169
+      }
170
+    },
171
+    created(){
172
+      // let obj = {
173
+      //     med_chrgitm_type01:[{name:1,age:2},{name:'张三',age:41}],
174
+      //     med_chrgitm_type03:[{name:3,age:4}],
175
+      //     med_chrgitm_type04:[{name:5,age:6}],
176
+      // }
177
+      // this.obj = obj
178
+      // console.log(1111,Object.values(obj))
179
+      // obj.map(item => {
180
+      //     console.log(111,item)
181
+
182
+
183
+      // })
184
+    },
185
+    methods: {
186
+      getTime(val) {
187
+        if (val < 0) {
188
+          return ""
189
+        }
190
+        if (val == "") {
191
+          return ""
192
+        } else {
193
+          return uParseTime(val, '{y}-{m}-{d}')
194
+        }
195
+      },
196
+      getNowTime: function () {
197
+        let dateTime
198
+        let yy = new Date().getFullYear()
199
+        let mm = new Date().getMonth() + 1
200
+        let dd = new Date().getDate()
201
+        let hh = new Date().getHours()
202
+        let mf = new Date().getMinutes() < 10 ? '0' + new Date().getMinutes()
203
+          :
204
+          new Date().getMinutes()
205
+        let ss = new Date().getSeconds() < 10 ? '0' + new Date().getSeconds()
206
+          :
207
+          new Date().getSeconds()
208
+        dateTime = yy + '-' + mm + '-' + dd + ' ' + hh + ':' + mf + ':' + ss
209
+        return dateTime
210
+      },
211
+
212
+    },
213
+    watch:{
214
+      "order_infos.order_infos":{
215
+        handler(newVal){
216
+          let obj = {
217
+            'med_chrgitm_type01':[],
218
+            'med_chrgitm_type03':[],
219
+            'med_chrgitm_type04':[],
220
+            'med_chrgitm_type05':[],
221
+            'med_chrgitm_type06':[],
222
+            'med_chrgitm_type08':[],
223
+            'med_chrgitm_type09':[],
224
+            'med_chrgitm_type11':[],
225
+            'med_chrgitm_type14':[],
226
+          }
227
+
228
+          newVal.map(item => {
229
+
230
+            if(item.med_chrgitm_type == '01'){
231
+              obj.med_chrgitm_type01.push(item)
232
+              this.price01 += item.det_item_fee_sumamt
233
+            }else if(item.med_chrgitm_type == '03'){
234
+              obj.med_chrgitm_type03.push(item)
235
+              this.price03 += item.det_item_fee_sumamt
236
+            }else if(item.med_chrgitm_type == '04'){
237
+              obj.med_chrgitm_type04.push(item)
238
+              this.price04 += item.det_item_fee_sumamt
239
+            }else if(item.med_chrgitm_type == '05'){
240
+              obj.med_chrgitm_type05.push(item)
241
+              this.price05 += item.det_item_fee_sumamt
242
+            }else if(item.med_chrgitm_type == '06'){
243
+              obj.med_chrgitm_type06.push(item)
244
+              this.price06 += item.det_item_fee_sumamt
245
+            }else if(item.med_chrgitm_type == '08'){
246
+              obj.med_chrgitm_type08.push(item)
247
+              this.price08 += item.det_item_fee_sumamt
248
+            }else if(item.med_chrgitm_type == '09'){
249
+              obj.med_chrgitm_type09.push(item)
250
+              this.price09 += item.det_item_fee_sumamt
251
+            }else if(item.med_chrgitm_type == '11'){
252
+              obj.med_chrgitm_type11.push(item)
253
+              this.price11 += item.det_item_fee_sumamt
254
+            }else if(item.med_chrgitm_type == '14'){
255
+              obj.med_chrgitm_type14.push(item)
256
+              this.price14 += item.det_item_fee_sumamt
257
+            }
258
+
259
+          })
260
+          this.obj = obj
261
+          console.log('this.obj',this.obj)
262
+        },
263
+        deep:true
264
+      }
265
+    }
266
+  }
267
+
268
+
269
+
270
+</script>
271
+
272
+
273
+<style lang="scss" scoped>
274
+    #statement-print{
275
+        width: 800px;
276
+        margin: 0 auto;
277
+    }
278
+    .statement-print {
279
+        -webkit-box-shadow: 0 1px 4px rgba(0, 0, 0, 0.27), 0 0 60px rgba(0, 0, 0, 0.06) inset;
280
+        -moz-box-shadow: 0 1px 4px rgba(0, 0, 0, 0.27), 0 0 40px rgba(0, 0, 0, 0.06) inset;
281
+        box-shadow: 0 1px 4px rgba(0, 0, 0, 0.27), 0 0 40px rgba(0, 0, 0, 0.06) inset;
282
+        margin-bottom: 20px;
283
+        padding: 20px 10px;
284
+    }
285
+
286
+    .statementTitle {
287
+        font-size: 22px;
288
+        text-align: center;
289
+        margin-bottom: 10px;
290
+    }
291
+
292
+    .statementTable {
293
+        width: 100%;
294
+        text-align: center;
295
+        border-collapse: collapse;
296
+        line-height: 40px;
297
+        font-size: 14px;
298
+        border-color: #000;
299
+    }
300
+</style>

+ 2 - 2
src/xt_pages/outpatientCharges/listTemplate/printTwo.vue 查看文件

@@ -1,7 +1,7 @@
1 1
 <template>
2 2
   <div id="statement-print" class="statement-print">
3
-    <div class="statementTitle" style="margin-top:20px;" v-if="info.insutype == '310'">医保费用明细清单</div>
4
-    <div class="statementTitle" style="margin-top:20px;" v-if="info.insutype == '390'">医保费用明细清单</div>
3
+    <div class="statementTitle" style="margin-top:20px;" >医保费用明细清单</div>
4
+    <!--<div class="statementTitle" style="margin-top:20px;" v-if="info.insutype == '390'">医保费用明细清单</div>-->
5 5
 
6 6
     <div style="display:flex">
7 7
       <div style="width:70%">医疗机构名称:{{info.fixmedins_name}}</div>

+ 5 - 1
src/xt_pages/outpatientCharges/summaryDetail.vue 查看文件

@@ -173,7 +173,8 @@ export default {
173 173
           listVisible:false,
174 174
           allListVisible:false,
175 175
           paramsObj:{
176
-            id:this.$route.query.id
176
+            id:this.$route.query.id,
177
+            balance_accounts_type:0
177 178
           },
178 179
             crumbs: [
179 180
                 { path: false, name: '门诊收费' },
@@ -213,10 +214,13 @@ export default {
213 214
       open(val){
214 215
         if(val == 1){
215 216
           this.paramsObj.id == this.$route.query.id
217
+          this.paramsObj.balance_accounts_type = this.hisPatientInfo.balance_accounts_type
216 218
           this.listVisible = true
217 219
 
218 220
         }else if(val == 2){
219 221
           this.paramsObj.id == this.$route.query.id
222
+          this.paramsObj.balance_accounts_type = this.hisPatientInfo.balance_accounts_type
223
+
220 224
           this.allListVisible = true
221 225
         }
222 226
       },

+ 7 - 5
src/xt_pages/outpatientDoctorStation/components/deskPrescription.vue 查看文件

@@ -2700,7 +2700,7 @@
2700 2700
                   delivery_way: temp2[b].delivery_way,
2701 2701
                   execution_frequency: temp2[b].execution_frequency,
2702 2702
                   number_days: temp2[b].number_days.toString(),
2703
-                  total: 1,
2703
+                  total:  temp2[b].cus_total,
2704 2704
                   price: temp2[b].price,
2705 2705
                   remark: '',
2706 2706
                   medical_code: temp2[b].medical_code,
@@ -2752,6 +2752,7 @@
2752 2752
                 number_days: project[i].number_days,
2753 2753
                 price: project[i].price,
2754 2754
                 medical_code: project[i].medical_code,
2755
+                cus_total:1,
2755 2756
                 unit: project[i].unit,
2756 2757
                 type: 2,
2757 2758
                 total:project[i].total
@@ -2771,6 +2772,7 @@
2771 2772
                 delivery_way: '',
2772 2773
                 execution_frequency: '',
2773 2774
                 number_days: 1,
2775
+                cus_total:1,
2774 2776
                 price: good_info[i].packing_price,
2775 2777
                 medical_code: good_info[i].medical_insurance_number,
2776 2778
                 unit: this.getGoodUnit(good_info[i].good_unit),
@@ -2864,7 +2866,7 @@
2864 2866
                   delivery_way: project[i].project.delivery_way,
2865 2867
                   execution_frequency: project[i].project.execution_frequency,
2866 2868
                   number_days: project[i].project.number_days,
2867
-                  total: project[i].number,
2869
+                  cus_total:project[i].number,
2868 2870
                   price: project[i].project.price,
2869 2871
                   remark: '',
2870 2872
                   medical_code: project[i].project.medical_code,
@@ -2885,15 +2887,15 @@
2885 2887
                   delivery_way: '',
2886 2888
                   execution_frequency: '',
2887 2889
                   number_days: '',
2888
-                  total: project[i].number,
2890
+                  cus_total: project[i].number,
2889 2891
                   price: project[i].good_info.retail_price,
2890 2892
                   remark: '',
2891 2893
                   medical_code: project[i].good_info.medical_insurance_number,
2892 2894
                   unit: project[i].good_info.unit,
2893 2895
                   type: project[i].type
2894 2896
                 }
2895
-                if (obj.total == 0 || obj.total == undefined) {
2896
-                  obj.total = 1
2897
+                if (obj.cus_total == 0 || obj.cus_total == undefined) {
2898
+                  obj.cus_total = 1
2897 2899
                 }
2898 2900
                 this.teamList.push(obj)
2899 2901
 

+ 5 - 5
src/xt_pages/stock/cancelStockOrder.vue 查看文件

@@ -148,8 +148,8 @@
148 148
         <el-pagination
149 149
           @size-change="handleSizeChange"
150 150
           @current-change="handleCurrentChange"
151
-          :page-sizes="[10, 50, 100]"
152
-          :page-size="10"
151
+          :page-sizes="[5,10, 50, 100]"
152
+          :page-size="5"
153 153
           background
154 154
           style="margin-top:20px;float: right"
155 155
           layout="total, sizes, prev, pager, next, jumper"
@@ -296,7 +296,7 @@ export default {
296 296
       searchKey: "",
297 297
       type: 1,
298 298
       page: 1,
299
-      limit: 10,
299
+      limit: 5,
300 300
       checked: false,
301 301
       total: 0,
302 302
       pageTotal: 0,
@@ -480,7 +480,7 @@ export default {
480 480
         ids: idStr
481 481
       };
482 482
 
483
-      this.$confirm("确认删除出库退库单记录?", "删除出库退库单记录", {
483
+      this.$confirm("确认删除退库单记录?", "删除退库单记录", {
484 484
         confirmButtonText: "确定",
485 485
         cancelButtonText: "取消",
486 486
         type: "warning"
@@ -539,7 +539,7 @@ export default {
539 539
       const params = {
540 540
         ids: idStr
541 541
       };
542
-      this.$confirm("确认删除出库退库单记录?", "删除出库退库单记录", {
542
+      this.$confirm("确认删除退库单记录?", "删除退库单记录", {
543 543
         confirmButtonText: "确定",
544 544
         cancelButtonText: "取消",
545 545
         type: "warning"

+ 3 - 0
src/xt_pages/stock/cancelStockOrderAdd.vue 查看文件

@@ -589,6 +589,9 @@ export default {
589 589
               if(msg == 4){
590 590
                this.$message.error("该批次退库数量大于入库数量")
591 591
              }
592
+             if(msg == 5){
593
+              this.$message.error("该批次退库数量大于入库数量")
594
+             }
592 595
              if(msg == 3){
593 596
                this.$notify({
594 597
                 title: "成功",

+ 4 - 1
src/xt_pages/stock/cancelStockOrderEdit.vue 查看文件

@@ -545,7 +545,10 @@
545 545
                 if(msg == 2){
546 546
                   this.$message.error("退库数量大于出库数量")
547 547
                 }
548
-                  if(msg == 4){
548
+                if(msg == 4){
549
+                  this.$message.error("该批次退库数量大于入库数量")
550
+                }
551
+                 if(msg == 5){
549 552
                   this.$message.error("该批次退库数量大于入库数量")
550 553
                 }
551 554
                 if(msg == 3){

+ 3 - 3
src/xt_pages/stock/drugs/cancelDrugStockOrder.vue 查看文件

@@ -147,8 +147,8 @@
147 147
       <el-pagination
148 148
         @size-change="handleSizeChange"
149 149
         @current-change="handleCurrentChange"
150
-        :page-sizes="[10, 50, 100]"
151
-        :page-size="10"
150
+        :page-sizes="[5,10, 15, 100]"
151
+        :page-size="5"
152 152
         background
153 153
         style="margin-top:20px;float: right;margin-bottom:10px;"
154 154
         layout="total, sizes, prev, pager, next, jumper"
@@ -547,7 +547,7 @@ export default {
547 547
       const params = {
548 548
         ids: idStr
549 549
       };
550
-      this.$confirm("确认删除出库退库单记录?", "删除出库退库单记录", {
550
+      this.$confirm("确认删除退库单记录?", "删除退库单记录", {
551 551
         confirmButtonText: "确定",
552 552
         cancelButtonText: "取消",
553 553
         type: "warning"

+ 1 - 1
src/xt_pages/stock/drugs/cancelDrugStockOrderAdd.vue 查看文件

@@ -635,7 +635,7 @@ export default {
635 635
                 this.$router.back(-1);
636 636
               }
637 637
               if(response.data.data.msg == 2){
638
-                this.$message.error("退库数量大于库数量")
638
+                this.$message.error("退库数量大于库数量")
639 639
               }
640 640
             }
641 641
           });

+ 74 - 49
src/xt_pages/stock/drugs/drugStockOutOrder.vue 查看文件

@@ -525,7 +525,8 @@ export default {
525 525
       outList:[],
526 526
       userListOne:[],
527 527
       exportList:[],
528
-      batchNumberList:[]
528
+      batchNumberList:[],
529
+      drugFlowList:[],
529 530
     };
530 531
   },
531 532
   methods: {
@@ -954,16 +955,13 @@ export default {
954 955
           var list =  response.data.data.list
955 956
           console.log("list2323232",list)
956 957
           var outList = response.data.data.outList
957
-          // for(let i=0;i<outList.length;i++){
958
-          //     //如果都是最大单位,把最数量转为最小数量
959
-          //    if(outList[i].count_unit == outList[i].max_unit){
960
-          //       outList[i].count = outList[i].min_number * outList[i].count 
961
-          //    }
962
-          // }
963 958
           this.outList = outList
964 959
          console.log("outList222",outList)
965 960
          this.manufacturerList = response.data.data.manufacturerList
966 961
          this.dealerList = response.data.data.dealerList
962
+         var drugFlowList = response.data.data.drugFlowList
963
+         this.drugFlowList = drugFlowList
964
+         console.log("23232323232323",drugFlowList)
967 965
          for(let i=0;i<list.length;i++){
968 966
            if(list[i].batch_number == "0" || list[i].batch_number == 0){
969 967
               list[i].batch_number = ""
@@ -1081,57 +1079,84 @@ export default {
1081 1079
          return str + min_str
1082 1080
       },
1083 1081
       getTotalCountOne(id,min_number,max_unit,min_unit){
1084
-       
1085
-        for(let i=0;i<this.outList.length;i++){
1086
-          if(this.outList[i].count_unit == this.outList[i].max_unit){
1087
-            this.outList[i].total_count = this.outList[i].count * this.outList[i].min_number
1088
-          }
1089
-
1090
-         if(this.outList[i].count_unit == this.outList[i].min_unit){
1091
-            this.outList[i].total_count = this.outList[i].count
1082
+        var arr = []
1083
+        for(let i=0;i<this.drugFlowList.length;i++){
1084
+          if(id == this.drugFlowList[i].drug_id){
1085
+             arr.push(this.drugFlowList[i])
1092 1086
           }
1093
-       
1094 1087
         }
1095
-        console.log("我的",this.outList)
1096
-          let dataInfo = {};
1097
-          this.outList.forEach((item, index) => {
1098
-            let { drug_id } = item;
1099
-            if (!dataInfo[drug_id]) {
1100
-              dataInfo[drug_id] = {
1101
-                drug_id,
1102
-                child: [],
1103
-                total:0,
1104
-              };
1105
-            }
1106
-          });
1107
-        let list = Object.values(dataInfo);
1108
-        console.log("drug_id22222",list)
1109
-        for(let i=0;i<list.length;i++){
1110
-          for(let j=0;j<this.outList.length;j++){
1111
-            if(list[i].drug_id == this.outList[j].drug_id){
1112
-              list[i].child.push(this.outList[j])
1113
-            }
1088
+        var total = 0
1089
+        for(let i=0;i<arr.length;i++){
1090
+          if(arr[i].max_unit == max_unit){
1091
+             arr[i].count = arr[i].count * arr[i].min_number
1114 1092
           }
1093
+          if(arr[i].max_unit == min_unit){
1094
+            arr[i].count = arr[i].count
1095
+          }
1096
+          total += arr[i].count
1115 1097
         }
1116
-       var total = 0
1117
-       for(let i=0;i<list.length;i++){
1118
-        for(let j=0;j<list[i].child.length;j++){
1119
-           if(id == list[i].child[j].drug_id){
1120
-             total+= list[i].child[j].total_count
1121
-           }
1122
-        }
1123
-       }
1098
+
1099
+        var str = ""
1100
+        var min_str = ""
1101
+        
1102
+        str = parseInt(total/min_number)+ max_unit
1103
+        min_str =  total%min_number + min_unit
1104
+
1105
+        return str + min_str 
1106
+
1107
+      },
1108
+    //   getTotalCountOne(id,min_number,max_unit,min_unit){
1109
+       
1110
+    //     for(let i=0;i<this.outList.length;i++){
1111
+    //       if(this.outList[i].count_unit == this.outList[i].max_unit){
1112
+    //         this.outList[i].total_count = this.outList[i].count * this.outList[i].min_number
1113
+    //       }
1114
+
1115
+    //      if(this.outList[i].count_unit == this.outList[i].min_unit){
1116
+    //         this.outList[i].total_count = this.outList[i].count
1117
+    //       }
1118
+       
1119
+    //     }
1120
+    //     console.log("我的",this.outList)
1121
+    //       let dataInfo = {};
1122
+    //       this.outList.forEach((item, index) => {
1123
+    //         let { drug_id } = item;
1124
+    //         if (!dataInfo[drug_id]) {
1125
+    //           dataInfo[drug_id] = {
1126
+    //             drug_id,
1127
+    //             child: [],
1128
+    //             total:0,
1129
+    //           };
1130
+    //         }
1131
+    //       });
1132
+    //     let list = Object.values(dataInfo);
1133
+    //     console.log("drug_id22222",list)
1134
+    //     for(let i=0;i<list.length;i++){
1135
+    //       for(let j=0;j<this.outList.length;j++){
1136
+    //         if(list[i].drug_id == this.outList[j].drug_id){
1137
+    //           list[i].child.push(this.outList[j])
1138
+    //         }
1139
+    //       }
1140
+    //     }
1141
+    //    var total = 0
1142
+    //    for(let i=0;i<list.length;i++){
1143
+    //     for(let j=0;j<list[i].child.length;j++){
1144
+    //        if(id == list[i].child[j].drug_id){
1145
+    //          total+= list[i].child[j].total_count
1146
+    //        }
1147
+    //     }
1148
+    //    }
1124 1149
       
1125
-      var str = ""
1126
-      var min_str = ""
1150
+    //   var str = ""
1151
+    //   var min_str = ""
1127 1152
       
1128
-      str = parseInt(total/min_number)+ max_unit
1129
-      min_str =  total%min_number + min_unit
1153
+    //   str = parseInt(total/min_number)+ max_unit
1154
+    //   min_str =  total%min_number + min_unit
1130 1155
 
1131
-     return str + min_str
1156
+    //  return str + min_str
1132 1157
       
1133 1158
        
1134
-     },
1159
+    //  },
1135 1160
       getAllPrice(drug_id,price,min_price){
1136 1161
          var strprice = 0
1137 1162
          var minstrprice = 0

+ 11 - 2
src/xt_pages/stock/drugs/drugStockOutOrderAdd.vue 查看文件

@@ -131,7 +131,7 @@
131 131
                         v-for="(item,index) in numberList"
132 132
                         :key="index"
133 133
                         :label="item.batch_number"
134
-                        :value="item.batch_number">
134
+                        :value="item.id">
135 135
                       </el-option>
136 136
                     </el-select>
137 137
                   </el-form-item>
@@ -448,6 +448,7 @@ export default {
448 448
       tempObj["number"] = ""
449 449
       tempObj["batch_number"] = ""
450 450
       tempObj["max_unit"] = ""
451
+      tempObj["warehouse_info_id"] = 0
451 452
       this.recordInfo.recordData.push(tempObj);
452 453
     },
453 454
     handleDelete: function(index, row) {
@@ -566,12 +567,19 @@ export default {
566 567
                   this.recordInfo.recordData[i].dealer = this.dealerList[z].id
567 568
               }
568 569
             }
570
+
571
+            for(let y=0;y<this.numberList.length;y++){
572
+              if(this.recordInfo.recordData[i].batch_number == this.numberList[y].id){
573
+                this.recordInfo.recordData[i].batch_number = this.numberList[y].batch_number
574
+                this.recordInfo.recordData[i].warehouse_info_id = this.numberList[y].id
575
+              }
576
+            }
569 577
           }
570 578
           const params = {
571 579
             stockOut: this.recordInfo.recordData
572 580
           };
573 581
           console.log("params222222",params)
574
-         
582
+        
575 583
           postDrugWarehouseOut(
576 584
             params,
577 585
             this.warehouse_out_time,
@@ -740,6 +748,7 @@ export default {
740 748
     tempObj["min_number"] = ""
741 749
     tempObj["dealer"] = ""
742 750
     tempObj["number"] = ""
751
+    tempObj["warehouse_info_id"] = 0
743 752
     this.recordInfo.recordData.push(tempObj);
744 753
     this.GetConfigInfo();
745 754
     this.propForm.goodUnit = this.$store.getters.good_unit;

+ 14 - 2
src/xt_pages/stock/drugs/drugStockOutOrderEdit.vue 查看文件

@@ -100,7 +100,7 @@
100 100
                         v-for="(item,index) in numberList"
101 101
                         :key="index"
102 102
                         :label="item.batch_number"
103
-                        :value="item.batch_number">
103
+                        :value="item.id">
104 104
                       </el-option>
105 105
                     </el-select>
106 106
                   </el-form-item>
@@ -451,6 +451,7 @@
451 451
         tempObj['count_unit'] = ""
452 452
         tempObj['dealer'] = 0
453 453
         tempObj['manufacturer'] = 0
454
+        tempObj['warehouse_info_id'] = 0
454 455
         this.recordInfo.recordData.push(tempObj)
455 456
       }, handleDelete: function(index, row) {
456 457
         if(this.drug_show == true){
@@ -574,12 +575,23 @@
574 575
                     this.recordInfo.recordData[i].dealer = this.dealerList[z].id
575 576
                  }
576 577
                }
578
+               
579
+               for(let y=0;y<this.numberList.length;y++){
580
+                  if(this.recordInfo.recordData[i].batch_number == this.numberList[y].id){
581
+                     this.recordInfo.recordData[i].batch_number = this.numberList[y].batch_number
582
+                     this.recordInfo.recordData[i].warehouse_info_id =  this.numberList[y].id
583
+                  }
584
+                  if(this.recordInfo.recordData[i].batch_number == this.numberList[y].batch_number){
585
+                     this.recordInfo.recordData[i].warehouse_info_id =  this.numberList[y].id
586
+                  }
587
+               }
588
+
577 589
             }
578 590
             const params = {
579 591
               'stockOut': this.recordInfo.recordData
580 592
             }
581 593
             console.log("params----",params)
582
-           
594
+            
583 595
             editDrugWarehouseoutInfo(params, this.warehouse_out_time, this.$route.query.id, this.$route.query.type, this.form.manufacturer, this.form.dealer).then(response => {
584 596
               if (response.data.state == 0) {
585 597
                 this.$message.error(response.data.msg)

+ 1 - 1
src/xt_pages/stock/stockBatchNumber.vue 查看文件

@@ -150,7 +150,7 @@
150 150
       return {
151 151
         crumbs: [
152 152
           { path: false, name: '库存管理' },
153
-          { path: '/stock/drugs/stock/query', name: '药品库存查询' },
153
+          { path: '/stock/drugs/stock/query', name: '耗材库存查询' },
154 154
           { path:'/drugstock/in/drugstockflow',name:'库存流水'}
155 155
         ],
156 156
         keywords: '',

+ 6 - 6
src/xt_pages/user/components/PatientSidebar.vue 查看文件

@@ -102,10 +102,10 @@ export default {
102 102
               name: '1-2',
103 103
               label: '病程管理'
104 104
             },
105
-            // {
106
-            //   name: '1-9',
107
-            //   label: '阶段小结'
108
-            // },
105
+            {
106
+              name: '1-9',
107
+              label: '阶段小结'
108
+            },
109 109
             {
110 110
               name: '1-3',
111 111
               label: '检验检查'
@@ -188,7 +188,7 @@ export default {
188 188
       }else if (name == '1-8'){
189 189
         this.$router.push({path:'/patients/patients/'+this.id+'/inspectionInfectious'})
190 190
       }else if (name == '1-9'){
191
-        this.$router.push({path:'/patients/patients/'+6092+'/templateSummary'})
191
+        this.$router.push({path:'/patients/patients/'+2448+'/templateSummary'})
192 192
       }
193 193
     },
194 194
     changePatient(value) {
@@ -334,7 +334,7 @@ export default {
334 334
           path: '/patients/patient/' + this.id + '/proeducation'
335 335
         })
336 336
       }else if (patientKey == '1-9'){
337
-        this.$router.push({path:'/patients/patients/'+this.id+'/templateSummary'})
337
+        this.$router.push({path:'/patients/patients/'+2448+'/templateSummary'})
338 338
       }
339 339
     
340 340
      }else{

+ 16 - 5
src/xt_pages/user/doctorAdvice.vue 查看文件

@@ -2235,7 +2235,8 @@ export default {
2235 2235
               this.adviceForm.advice_name = arr[0]
2236 2236
           }
2237 2237
 
2238
-       
2238
+          console.log("2323223",this.adviceForm)
2239
+        
2239 2240
           EditNewDoctorAdvice(
2240 2241
             this.patientID,
2241 2242
             this.adviceForm.id,
@@ -4059,6 +4060,7 @@ export default {
4059 4060
           this.nameForm.advice_name = arr[0]
4060 4061
        }
4061 4062
       console.log("医嘱2222",this.nameForm)
4063
+     
4062 4064
       var _this = this;
4063 4065
       this.$refs[formName].validate(valid => {
4064 4066
         if (valid) {
@@ -4453,6 +4455,7 @@ export default {
4453 4455
                   type: "",
4454 4456
                   custom_id: "",
4455 4457
                   drug_specs: [],
4458
+                  drug_id:"",
4456 4459
                 }
4457 4460
 
4458 4461
                 medicalList[i].drug_name = medicalList[i].drug_name + "(自备药)"
@@ -4465,6 +4468,7 @@ export default {
4465 4468
                 obj.type = 2
4466 4469
                 obj.custom_id = this.rand(10000000, 99999999)
4467 4470
                 obj.drug_specs = medicalList[i].drug_specs
4471
+                obj.drug_id = medicalList[i].id
4468 4472
                 this.all_drug.push(obj)
4469 4473
               }
4470 4474
             }
@@ -4489,6 +4493,7 @@ export default {
4489 4493
                   type: "",
4490 4494
                   custom_id: "",
4491 4495
                   drug_specs: [],
4496
+                  drug_id:"",
4492 4497
                 }
4493 4498
 
4494 4499
                 obj.drug_name = base_drug_list[i].drug_name
@@ -4500,6 +4505,7 @@ export default {
4500 4505
                 obj.type = 1
4501 4506
                 obj.custom_id = this.rand(10000000, 99999999)
4502 4507
                 obj.drug_specs = base_drug_list[i].drug_specs
4508
+                obj.drug_id = base_drug_list[i].id
4503 4509
                 this.all_drug.push(obj)
4504 4510
               }
4505 4511
             }
@@ -4613,11 +4619,16 @@ export default {
4613 4619
         cb(results);
4614 4620
       },
4615 4621
 
4616
-      handleSelect1(){
4617
-
4622
+      handleSelect1(val){
4623
+        this.drug_id = val.drug_id
4624
+        
4618 4625
       },
4619
-      handleSelect(){
4620
-
4626
+      handleSelect(val){
4627
+        this.src_type = 1
4628
+        this.drug_id = val.drug_id
4629
+        this.nameForm.drug_id = val.drug_id
4630
+        this.nameForm.way = 1
4631
+        this.nameForm.drug_name_id = val.drug_id
4621 4632
       }
4622 4633
   },
4623 4634
   watch: {

+ 164 - 246
src/xt_pages/user/templateSummary.vue 查看文件

@@ -44,17 +44,17 @@
44 44
                 <el-table-column type="selection" width="40" align="center"></el-table-column>
45 45
                 <el-table-column label="阶段小结名称" align="center">
46 46
                   <template slot-scope="scope">
47
-                    {{ scope.row.title}}
47
+                    <!-- {{ scope.row.title}} -->
48 48
                   </template>
49 49
                 </el-table-column>
50 50
                 <el-table-column label="记录时间" align="center">
51 51
                   <template slot-scope="scope">
52
-                    {{ recordTime(scope.row.record_time) }}
52
+                    <!-- {{ recordTime(scope.row.record_time) }} -->
53 53
                   </template>
54 54
                 </el-table-column>
55 55
                 <el-table-column label="记录医生" align="center">
56 56
                   <template slot-scope="scope">
57
-                    {{ doctorName(scope.row.recorder) }}
57
+                    <!-- {{ doctorName(scope.row.recorder) }} -->
58 58
                   </template>
59 59
                 </el-table-column>
60 60
               </el-table>
@@ -76,36 +76,55 @@
76 76
         <div>
77 77
           <div class="new_record_form">
78 78
             <div class="cell clearfix">
79
-              <label class="title"><span class="name">阶段小结时间</span> : </label>
80 79
               <el-form>
80
+                <el-row :gutter="24">
81
+                  <el-col :span="20">
82
+                    <el-form-item label="阶段小结名称:">
83
+                      <el-input v-model="form.title"></el-input>
84
+                    </el-form-item>
85
+                  </el-col>
86
+                </el-row>
81 87
                  <el-row :gutter="24">
82 88
                   <el-col :span="8">
83
-                    <el-form-item>
89
+                    <el-form-item label="阶段小结时间:">
84 90
                         <el-date-picker
85
-                            v-model="value"
91
+                            v-model="form.start_year"
86 92
                             type="year"
93
+                            value-format="yyyy-MM-dd"
87 94
                             placeholder="选择年">
88 95
                         </el-date-picker>
89 96
                     </el-form-item> 
90 97
                   </el-col>
91 98
                   <el-col :span="8">
92 99
                     <el-form-item>
93
-                      <el-radio-group v-model="radio">
100
+                      <el-radio-group v-model="form.radio">
94 101
                         <el-radio :label="1" >月份</el-radio>
95 102
                         <el-radio :label="2" >季度</el-radio>
96 103
                      </el-radio-group>
97 104
                     </el-form-item> 
98 105
                   </el-col>
99
-                  <el-col :span="8">
106
+                  <el-col :span="8" v-if="form.radio == 1">
100 107
                     <el-form-item>
101 108
                       <el-date-picker
102
-                        v-model="value"
109
+                        value-format="MM"
110
+                        v-model="form.start_month"
103 111
                         type="month"
104 112
                         placeholder="选择月">
105 113
                       </el-date-picker>
106 114
                     </el-form-item> 
107 115
                   </el-col>
108
-                   
116
+                  <el-col :span="8" v-if="form.radio == 2">
117
+                    <el-form-item>
118
+                       <el-select v-model="form.quarter" placeholder="请选择">
119
+                        <el-option
120
+                          v-for="item in timeType"
121
+                          :key="item.id"
122
+                          :label="item.name"
123
+                          :value="item.id">
124
+                        </el-option>
125
+                      </el-select>
126
+                    </el-form-item> 
127
+                  </el-col> 
109 128
                  </el-row>  
110 129
                 
111 130
               </el-form>
@@ -117,46 +136,52 @@
117 136
                   <el-row :gutter="24">
118 137
                     <el-col :span="8">
119 138
                      <el-form-item label="干体重">
120
-                      <el-input></el-input>
139
+                      <el-input v-model="form.dry_weight"></el-input>
121 140
                      </el-form-item>  
122 141
                     </el-col>
123 142
                     <el-col :span="8">
124 143
                      <el-form-item label="共透析(次)">
125
-                      <el-input></el-input>
144
+                      <el-input v-model="form.dialysis_count"></el-input>
126 145
                      </el-form-item>  
127 146
                     </el-col>
128 147
                     <el-col :span="8">
129 148
                      <el-form-item label="HD(次)">
130
-                      <el-input></el-input>
149
+                      <el-input v-model="form.hd_count"></el-input>
131 150
                      </el-form-item>  
132 151
                     </el-col>
133 152
                   </el-row>
134 153
                   <el-row :gutter="24">
135 154
                     <el-col :span="8">
136 155
                      <el-form-item label="HDF(次)">
137
-                      <el-input></el-input>
156
+                      <el-input v-model="form.hdf_count"></el-input>
138 157
                      </el-form-item>  
139 158
                     </el-col>
140 159
                     <el-col :span="8">
141 160
                      <el-form-item label="HP(次)">
142
-                      <el-input></el-input>
161
+                      <el-input v-model="form.hp_count"></el-input>
143 162
                      </el-form-item>  
144 163
                     </el-col>
145 164
                     <el-col :span="8">
146 165
                      <el-form-item label="其他(次)">
147
-                      <el-input></el-input>
166
+                      <el-input v-model="form.other_count"></el-input>
148 167
                      </el-form-item>  
149 168
                     </el-col>
150 169
                   </el-row>
151 170
                    <el-row :gutter="24">
152 171
                     <el-col :span="8">
153 172
                      <el-form-item label="透析器">
154
-                      <el-input></el-input>
173
+                      <el-input v-model="form.dialzer_apparatus"></el-input>
155 174
                      </el-form-item>  
156 175
                     </el-col>
176
+                    <el-col :span="8">
177
+                      <el-form-item label="灌流器">
178
+                        <el-input v-model="form.perfusion_apparatus"></el-input>
179
+                      </el-form-item>  
180
+                    </el-col>
181
+
157 182
                     <el-col :span="8">
158 183
                      <el-form-item label="抗凝剂">
159
-                      <el-input></el-input>
184
+                      <el-input v-model="form.anticoagulant"></el-input>
160 185
                      </el-form-item>  
161 186
                     </el-col>
162 187
                   </el-row>
@@ -164,17 +189,17 @@
164 189
                    <el-row :gutter="24">
165 190
                     <el-col :span="8">
166 191
                      <el-form-item label="钾">
167
-                      <el-input></el-input>
192
+                      <el-input v-model="form.kalium"></el-input>
168 193
                      </el-form-item>  
169 194
                     </el-col>
170 195
                     <el-col :span="8">
171 196
                      <el-form-item label="钙">
172
-                      <el-input></el-input>
197
+                      <el-input v-model="form.autunite"></el-input>
173 198
                      </el-form-item>  
174 199
                     </el-col>
175 200
                     <el-col :span="8">
176 201
                      <el-form-item label="钠">
177
-                      <el-input></el-input>
202
+                      <el-input v-model="form.natrium"></el-input>
178 203
                      </el-form-item>  
179 204
                     </el-col>
180 205
                   </el-row>
@@ -182,43 +207,43 @@
182 207
                    <el-row :gutter="24">
183 208
                     <el-col :span="8">
184 209
                      <el-form-item label="时">
185
-                      <el-input></el-input>
210
+                      <el-input v-model="form.hour"></el-input>
186 211
                      </el-form-item>  
187 212
                     </el-col>
188 213
                     <el-col :span="8">
189 214
                      <el-form-item label="分">
190
-                      <el-input></el-input>
215
+                      <el-input v-model="form.minute"></el-input>
191 216
                      </el-form-item>  
192 217
                     </el-col>
193 218
                   </el-row>
194 219
                   <el-row :gutter="24">
195 220
                     <el-col :span="8">
196 221
                      <el-form-item label="透前体重(kg)">
197
-                      <el-input></el-input>
222
+                      <el-input v-model="form.befor_weight"></el-input>
198 223
                      </el-form-item>  
199 224
                     </el-col>
200 225
                     <el-col :span="8">
201 226
                      <el-form-item label="透后体重(kg)">
202
-                      <el-input></el-input>
227
+                      <el-input v-model="form.after_weight"></el-input>
203 228
                      </el-form-item>  
204 229
                     </el-col>
205 230
                   </el-row>
206 231
                    <el-row :gutter="24">
207 232
                     <el-col :span="8">
208 233
                      <el-form-item label="透前血压(mmHg)">
209
-                      <el-input></el-input>
234
+                      <el-input v-model="form.befor_pressure"></el-input>
210 235
                      </el-form-item>  
211 236
                     </el-col>
212 237
                     <el-col :span="8">
213 238
                      <el-form-item label="透后血压(mmHg)">
214
-                      <el-input></el-input>
239
+                      <el-input v-model="form.after_pressure"></el-input>
215 240
                      </el-form-item>  
216 241
                     </el-col>
217 242
                   </el-row>
218 243
                  
219 244
                   <el-row>
220 245
                     <label class="title"><span class="name">阶段小结总结</span> : </label>
221
-                     <el-select v-model="value" placeholder="请选择">
246
+                     <el-select v-model="form.template_summary_id" placeholder="请选择">
222 247
                         <el-option
223 248
                         v-for="item in options"
224 249
                         :key="item.value"
@@ -226,11 +251,11 @@
226 251
                         :value="item.value">
227 252
                         </el-option>
228 253
                      </el-select>
229
-                     <el-input tyep="text"></el-input>
254
+                     <el-input tyep="text" v-model="form.template_summary_content"></el-input>
230 255
                   </el-row>
231 256
                   <el-row>
232 257
                     <label class="title"><span class="name">阶段小结个体化透析方案</span> : </label>
233
-                     <el-select v-model="value" placeholder="请选择">
258
+                     <el-select v-model="form.template_plan_id" placeholder="请选择">
234 259
                         <el-option
235 260
                         v-for="item in options"
236 261
                         :key="item.value"
@@ -238,11 +263,11 @@
238 263
                         :value="item.value">
239 264
                         </el-option>
240 265
                      </el-select>
241
-                     <el-input tyep="text"></el-input>
266
+                     <el-input tyep="text" v-model="form.template_plan_content"></el-input>
242 267
                   </el-row>
243 268
                   <el-row>
244 269
                     <label class="title"><span class="name">阶段小结化验结果</span> : </label>
245
-                     <el-select v-model="value" placeholder="请选择">
270
+                     <el-select v-model="form.template_inspection_id" placeholder="请选择">
246 271
                         <el-option
247 272
                         v-for="item in options"
248 273
                         :key="item.value"
@@ -250,12 +275,12 @@
250 275
                         :value="item.value">
251 276
                         </el-option>
252 277
                      </el-select>
253
-                     <el-input tyep="text"></el-input>
278
+                     <el-input tyep="text" v-model="form.template_inspection_content"></el-input>
254 279
                   </el-row>
255 280
                   <el-row>
256 281
                     <el-col :span="8">
257 282
                       <el-form-item label="记录医生">
258
-                        <el-select v-model="value" placeholder="请选择">
283
+                        <el-select v-model="form.admin_user_id" placeholder="请选择">
259 284
                             <el-option
260 285
                             v-for="item in options"
261 286
                             :key="item.value"
@@ -268,7 +293,7 @@
268 293
                     <el-col :span="8">
269 294
                       <el-form-item label="记录时间">
270 295
                          <el-date-picker
271
-                            v-model="value1"
296
+                            v-model="form.record_time"
272 297
                             type="datetime"
273 298
                             placeholder="选择日期时间">
274 299
                         </el-date-picker>
@@ -282,8 +307,7 @@
282 307
           
283 308
             <div style="text-align: right; padding-right: 0px; padding-top: 10px; padding-bottom: 10px;">
284 309
               <el-button @click="show_dialog = false">取消</el-button>
285
-              <el-button :disabled="$store.getters.xt_user.subscibe.state==3?true:false" type="primary"
286
-                         @click="createAction" :loading="uploading_new_record">保存
310
+              <el-button type="primary" @click="createAction">保存
287 311
               </el-button>
288 312
             </div>
289 313
           </div>
@@ -291,50 +315,7 @@
291 315
       </el-dialog>
292 316
 
293 317
 
294
-      <el-dialog title="修改病程记录" width="50%" top="5vh" :visible.sync="show_edit_dialog">
295
-        <div>
296
-          <div class="new_record_form">
297
-            <div class="cell clearfix">
298
-              <label class="title"><span class="name">病程日期</span> : </label>
299
-              <el-date-picker v-model="edit_course_of_disease_time" prefix-icon="el-icon-date" :editable="false"
300
-                              style="width: 200px;"
301
-                              type="datetime"
302
-                              placeholder="选择日期时间" align="right" format="yyyy-MM-dd HH:mm"
303
-                              value-format="yyyy-MM-dd HH:mm"></el-date-picker>
304
-
305
-              <label class="title"><span class="name">日常病程</span> : </label>
306
-              <el-select v-model="select_template" placeholder="可选择病程模板" @change="didEditSelectTemplate">
307
-                <el-option v-for="(option, index) in templates" :key="index" :label="option.title"
308
-                           :value="option.content"></el-option>
309
-              </el-select>
310
-            </div>
311
-
312
-
313
-            <div class="cell clearfix" style="margin-top: 10px">
314
-              <label class="title"><span class="name">病程标题</span> : </label>
315
-              <el-input v-model="edit_title" style="width: 420px"></el-input>
316
-            </div>
317
-
318
-            <div class="textarea_panel">
319
-              <!--<el-input v-model="edit_new_content" type="textarea" rows="6" resize="none"></el-input>-->
320
-              <keep-alive>
321
-                <editor ref="edit_neditor"
322
-                        id="edit_editor"
323
-                        style="width: 600px"
324
-                        v-bind:r_content="edit_new_content">
325
-                </editor>
326
-              </keep-alive>
327
-            </div>
328
-
329
-            <div style="text-align: right; padding-right: 0px; padding-top: 10px; padding-bottom: 10px;">
330
-              <el-button @click="show_edit_dialog = false">取消</el-button>
331
-              <el-button :disabled="$store.getters.xt_user.subscibe.state==3?true:false" type="primary"
332
-                         @click="modifyAction" :loading="uploading_new_record">保存
333
-              </el-button>
334
-            </div>
335
-          </div>
336
-        </div>
337
-      </el-dialog>
318
+  
338 319
     </div>
339 320
   </div>
340 321
 
@@ -345,16 +326,11 @@
345 326
   import PatientSidebar from './components/PatientSidebar'
346 327
   import Editor from '@/components/Editor'
347 328
 
348
-  import {
349
-    createCourseOfDiseaseRecord,
350
-    deleteCourseOfDiseaseRecords,
351
-    getCourseOfDiseaseRecords,
352
-    modifyCourseOfDiseaseRecord,
353
-    GetCoursePrintData
354
-  } from '@/api/patient'
329
+  import { getInitDataList } from '@/api/patient'
355 330
   import { parseTime } from '@/utils'
356 331
   import BreadCrumb from '@/xt_pages/components/bread-crumb'
357
-
332
+  import { uParseTime } from '@/utils/tools'
333
+  const moment = require('moment')
358 334
   export default {
359 335
     name: 'templateSummary',
360 336
     components: {
@@ -386,8 +362,50 @@
386 362
         table_current_index: -1,
387 363
         edit_current_id: 0,
388 364
         edit_title: '',
389
-        radio:1,
390
-        value:''
365
+        value:'',
366
+        form:{
367
+          title:"",
368
+          start_year:new Date(),
369
+          start_month:new Date(),
370
+          radio:1,
371
+          quarter:1,
372
+          dry_weight:"",
373
+          dialysis_count:"",
374
+          hd_count:"",
375
+          hdf_count:"",
376
+          hp_count:"",
377
+          other_count:"",
378
+          dialzer_apparatus:"",
379
+          perfusion_apparatus:"",
380
+          anticoagulant:"",
381
+          kalium:"",
382
+          autunite:"",
383
+          natrium:"",
384
+          houer:"",
385
+          minute:"",
386
+          befor_weight:"",
387
+          after_weight:"",
388
+          befor_pressure:"",
389
+          after_pressure:"",
390
+          template_summary_id:"",
391
+          template_summary_content:"",
392
+          template_plan_id:"",
393
+          template_summary_content:"",
394
+          template_inspection_id:"",
395
+          template_inspection_content:"",
396
+          admin_user_id:"",
397
+          record_time:"",
398
+          patient_id:"",
399
+          start_time:"",
400
+          end_time:"",
401
+        },
402
+        timeType:[
403
+          {id:1,name:"第一季度"},
404
+          {id:2,name:"第二季度"},
405
+          {id:3,name:"第三季度"},
406
+          {id:4,name:"第四季度"},
407
+        ],
408
+        options:[],
391 409
       }
392 410
     },
393 411
     created() {
@@ -423,179 +441,79 @@
423 441
         (nowMonth < 10 ? '0' + nowMonth : nowMonth) +
424 442
         '-' +
425 443
         (nowDay < 10 ? '0' + nowDay : nowDay)
426
-
427
-      this.requestCourseRecords()
428
-
444
+      this.getlist()
429 445
     },
430 446
     methods: {
431
-      requestCourseRecords: function() {
432
-        this.loading = true
433
-        getCourseOfDiseaseRecords(this.patient_id, this.start_time, this.end_time).then(rs => {
434
-          this.loading = false
435
-          var resp = rs.data
436
-          if (resp.state == 1) {
437
-            this.current_select_record = null
438
-            this.records = resp.data.records
439
-            this.doctors = resp.data.doctors
440
-
441
-          } else {
442
-            this.$message.error(resp.msg)
443
-          }
444
-        }).catch(error => {
445
-          this.loading = false
446
-          this.$message.error(error)
447
-        })
447
+      getTime(val) {
448
+         if(val < 0){
449
+           return ""
450
+         }
451
+         if(val == ""){
452
+          return ""
453
+         }else {
454
+          return uParseTime(val, '{y}-{m}-{d}')
455
+         }
448 456
       },
457
+      showEdit(){
449 458
 
450
-      didChangeCurrentRecord: function(record) {
451
-        this.current_select_record = record
452 459
       },
453
-      recordTime: function(timestamp) {
454
-        var time = new Date(timestamp * 1000)
455
-        return parseTime(time, '{y}-{m}-{d} {h}:{m}')
460
+      deleteAction(){
461
+
456 462
       },
457
-      doctorName: function(doctor_id) {
458
-        for (let index = 0; index < this.doctors.length; index++) {
459
-          const doctor = this.doctors[index]
460
-          if (doctor.id == doctor_id) {
461
-            return doctor.name
462
-          }
463
-        }
464
-        return ''
463
+      onRowClick(){
464
+
465 465
       },
466
-      modifyAction: function() {
466
+      createAction(){
467 467
 
468
-        this.edit_new_content = this.$refs.edit_neditor.content
469
-        if (this.edit_new_content.length == 0) {
470
-          this.$message.error('请填写病程内容')
471
-          return
472
-        }
473
-        this.uploading_new_record = true
474
-        modifyCourseOfDiseaseRecord(this.patient_id, this.edit_new_content, this.edit_course_of_disease_time, this.edit_current_id, this.edit_title).then(rs => {
475
-          this.uploading_new_record = false
476
-          var resp = rs.data
477
-          if (resp.state == 1) {
478
-            this.records[this.table_current_index].content = resp.data.record.content
479
-            this.records[this.table_current_index].record_time = resp.data.record.record_time
480
-            this.records[this.table_current_index].recorder = resp.data.record.recorder
481
-            this.records[this.table_current_index].title = resp.data.record.title
482
-
483
-            this.show_edit_dialog = false
484
-            this.edit_new_content = ''
485
-            this.table_current_index = -1
486
-
487
-          } else {
488
-            this.table_current_index = -1
489
-            this.$message.error(resp.msg)
490
-          }
491
-
492
-        }).catch(error => {
493
-          this.table_current_index = -1
494
-          this.uploading_new_record = false
495
-          this.$message.error(error)
496
-        })
468
+      },
469
+      didChangeCurrentRecord(){
497 470
 
498 471
       },
472
+      startTimeChange(){
499 473
 
500
-      createAction: function() {
501
-        this.new_content = this.$refs.editor.content
502
-        if (this.new_content.length == 0) {
503
-          this.$message.error('请填写病程内容')
504
-          return
505
-        }
506
-        this.uploading_new_record = true
507
-        
508
-        createCourseOfDiseaseRecord(this.patient_id, this.new_content, this.course_of_disease_time, this.title).then(rs => {
509
-          this.uploading_new_record = false
510
-          var resp = rs.data
511
-          if (resp.state == 1) {
512
-            this.records.unshift(resp.data.record)
513
-            // this.$refs.record_table.setCurrentRow()
514
-            // this.$refs.record_table.setCurrentRow(this.records[0])
515
-            // this.current_select_record = this.records[0]
516
-            this.show_dialog = false
517
-            this.new_content = ''
518
-            this.title = ''
519
-
520
-          } else {
521
-            this.$message.error(resp.msg)
522
-          }
523
-
524
-        }).catch(error => {
525
-          this.uploading_new_record = false
526
-          this.$message.error(error)
527
-        })
528 474
       },
529
-      didSelectTemplate: function(templateContent) {
530
-        this.new_content = this.new_content.length > 0 ? (this.new_content + templateContent) : templateContent
475
+      endTimeChange(){
531 476
 
532
-      }, didEditSelectTemplate: function(templateContent) {
533
-        this.edit_new_content = this.edit_new_content.length > 0 ? (this.edit_new_content + templateContent) : templateContent
534 477
       },
478
+      print(){
535 479
 
536
-      didSelectionChange: function(selectRows) {
537
-        this.selectingRows = selectRows
538 480
       },
539
-      deleteAction: function() {
540
-        if (this.selectingRows.length == 0) {
541
-          return
542
-        }
543
-        var ids = []
544
-        for (let index = 0; index < this.selectingRows.length; index++) {
545
-          const row = this.selectingRows[index]
546
-          ids.push(row.id)
481
+      getQuarter(year,quarter){
482
+        var start_time = ""
483
+        if(quarter == 1){
484
+           
547 485
         }
548
-        var ids_str = ids.join(',')
549
-        this.loading = true
550
-        deleteCourseOfDiseaseRecords(this.patient_id, ids_str).then(rs => {
551
-          var resp = rs.data
552
-          if (resp.state == 1) {
553
-            for (let id_index = 0; id_index < ids.length; id_index++) {
554
-              for (let record_index = 0; record_index < this.records.length; record_index++) {
555
-                if (ids[id_index] == this.records[record_index].id) {
556
-                  this.records.splice(record_index, 1)
557
-                  break
558
-                }
559
-              }
560
-            }
561
-            this.selectingRows = []
562
-            this.$message.success('已删除')
563
-
564
-          } else {
565
-            this.$message.error(resp.msg)
566
-          }
567
-          this.loading = false
568
-        }).catch(err => {
569
-          this.loading = false
570
-          this.$message.error(err)
571
-        })
572
-      }, startTimeChange(val) {
573
-        this.requestCourseRecords()
574
-      }, endTimeChange(val) {
575
-        this.requestCourseRecords()
576
-      }, showEdit() {
577
-        if (this.table_current_index == -1) {
578
-          this.$message.error('请选择要修改的病程内容')
579
-          return
580
-        }
581
-        this.show_edit_dialog = true
582
-        this.edit_course_of_disease_time = this.recordTime(this.records[this.table_current_index].record_time)
583
-        this.edit_new_content = this.records[this.table_current_index].content
584
-        this.edit_current_id = this.records[this.table_current_index].id
585
-        this.edit_title = this.records[this.table_current_index].title
586
-        this.$refs.record_table.setCurrentRow(null)
587
-
588
-      }, tableRow({ row, rowIndex }) {
589
-        // 把每一行的索引放进row
590
-        row.index = rowIndex
591
-      }, onRowClick(row, event, column) {
592
-        this.table_current_index = row.index
593
-      },print(){
594
-        if (this.table_current_index == -1) {
595
-          this.$message.error('请选择要打印的病程')
596
-          return
486
+
487
+        // DateTime dt = new DateTime();
488
+        // switch (quarter)
489
+        // {
490
+        //     case "第一季度":
491
+        //         dt = new DateTime(year, 1, 1);
492
+        //         break;
493
+        //     case "第二季度":
494
+        //         dt = new DateTime(year, 4, 1);         
495
+        //         break;
496
+        //     case "第三季度":
497
+        //         dt = new DateTime(year, 7, 1);           
498
+        //         break;
499
+        //     case "第四季度":
500
+        //         dt = new DateTime(year, 10, 1);             
501
+        //         break;
502
+
503
+        // }
504
+
505
+      },
506
+      getlist(){
507
+        var params={
508
+        start_year:this.getTime(this.form.start_year),
509
+        start_month:this.getTime(this.form.start_month),
510
+        quarter:this.form.quarter,
597 511
         }
598
-        this.$router.push({ path: "/course/print?id="+this.records[this.table_current_index].id});
512
+        console.log("param222222",params)
513
+        console.log(moment(moment(2020 + '-01-01').toDate()).quarter(2).format("YYYY-MM-DD"))
514
+      getInitDataList(params).then(response=>{
515
+
516
+      })
599 517
       }
600 518
     }
601 519
   }