|
@@ -202,21 +202,39 @@
|
202
|
202
|
</template>
|
203
|
203
|
</van-cell>
|
204
|
204
|
|
205
|
|
- <van-field
|
206
|
|
- label="慢性病"
|
207
|
|
- v-model="patientForm.slowDisease"
|
208
|
|
- right-icon="arrow"
|
209
|
|
- readonly
|
210
|
|
- placeholder="请选择"
|
211
|
|
- @click="show12 = true"
|
212
|
|
- />
|
213
|
|
- <van-popup
|
214
|
|
- v-model="show12"
|
215
|
|
- position="bottom"
|
216
|
|
- :style="{ height: '30%' }"
|
217
|
|
- >
|
218
|
|
- <van-picker :columns="checkDisease" @change="onChangeFive" />
|
219
|
|
- </van-popup>
|
|
205
|
+ <van-cell>
|
|
206
|
+ <!-- 使用 title 插槽来自定义标题 -->
|
|
207
|
+ <template slot="title">
|
|
208
|
+ <span class="custom-title2">慢性病</span>
|
|
209
|
+ <div style="width:60%;margin-left:2rem">
|
|
210
|
+ <van-checkbox-group v-model="resultFour">
|
|
211
|
+ <van-checkbox name="1" shape="square">血透</van-checkbox>
|
|
212
|
+ <van-checkbox name="2" shape="square">腹透</van-checkbox>
|
|
213
|
+ <van-checkbox name="3" shape="square">移植</van-checkbox>
|
|
214
|
+ <van-checkbox name="4" shape="square">高血压</van-checkbox>
|
|
215
|
+ <van-checkbox name="5" shape="square">糖尿病</van-checkbox>
|
|
216
|
+ <van-checkbox name="6" shape="square">慢性肾病</van-checkbox>
|
|
217
|
+ <van-checkbox name="7" shape="square">其他</van-checkbox>
|
|
218
|
+ </van-checkbox-group>
|
|
219
|
+ </div>
|
|
220
|
+ </template>
|
|
221
|
+ </van-cell>
|
|
222
|
+
|
|
223
|
+ <!-- <van-field-->
|
|
224
|
+ <!-- label="慢性病"-->
|
|
225
|
+ <!-- v-model="patientForm.slowDisease"-->
|
|
226
|
+ <!-- right-icon="arrow"-->
|
|
227
|
+ <!-- readonly-->
|
|
228
|
+ <!-- placeholder="请选择"-->
|
|
229
|
+ <!-- @click="show12 = true"-->
|
|
230
|
+ <!-- />-->
|
|
231
|
+ <!-- <van-popup-->
|
|
232
|
+ <!-- v-model="show12"-->
|
|
233
|
+ <!-- position="bottom"-->
|
|
234
|
+ <!-- :style="{ height: '30%' }"-->
|
|
235
|
+ <!-- >-->
|
|
236
|
+ <!-- <van-picker :columns="checkDisease" @change="onChangeFive" />-->
|
|
237
|
+ <!-- </van-popup>-->
|
220
|
238
|
</div>
|
221
|
239
|
</div>
|
222
|
240
|
|
|
@@ -282,7 +300,10 @@ import {
|
282
|
300
|
GenerateDialysisNo,
|
283
|
301
|
GetIllnessList,
|
284
|
302
|
savePatient,
|
285
|
|
- GetPatientInfo
|
|
303
|
+ GetPatientInfo,
|
|
304
|
+ getBloodPatientInfo,
|
|
305
|
+ getSlowPatientInfo,
|
|
306
|
+ getMemberPatientInfo
|
286
|
307
|
} from "@/api/patient/patient";
|
287
|
308
|
import { isCardNo, checkMobile, getFileExtension } from "@/utils/tools";
|
288
|
309
|
import { getToken } from "@/api/qiniu";
|
|
@@ -309,7 +330,7 @@ export default {
|
309
|
330
|
idCard: "",
|
310
|
331
|
birthday: "",
|
311
|
332
|
tel: "",
|
312
|
|
- result: ["1"],
|
|
333
|
+ result: [],
|
313
|
334
|
resultTwo: [],
|
314
|
335
|
resultThree: [],
|
315
|
336
|
resultFour: [],
|
|
@@ -327,7 +348,15 @@ export default {
|
327
|
348
|
columns3: ["门诊", "住院"],
|
328
|
349
|
columns4: ["留治", "转出"],
|
329
|
350
|
contagionList: ["乙肝", "丙肝", "艾滋病", "肺结核", "梅毒"],
|
330
|
|
- checkDisease: ["慢性病", "神经病", "抑郁症"],
|
|
351
|
+ checkDisease: [
|
|
352
|
+ "血透",
|
|
353
|
+ "腹透",
|
|
354
|
+ "移植",
|
|
355
|
+ "高血压",
|
|
356
|
+ "糖尿病",
|
|
357
|
+ "慢性肾病",
|
|
358
|
+ "其他"
|
|
359
|
+ ],
|
331
|
360
|
treatmentMethod: [
|
332
|
361
|
"西医治疗",
|
333
|
362
|
"中医治疗",
|
|
@@ -440,6 +469,43 @@ export default {
|
440
|
469
|
this.show2 = false;
|
441
|
470
|
},
|
442
|
471
|
changeMode(val) {
|
|
472
|
+ alert(val);
|
|
473
|
+ if (val == 1) {
|
|
474
|
+ getBloodPatientInfo(this.patientForm.phone).then(response => {
|
|
475
|
+ if (response.data.state === 1) {
|
|
476
|
+ var msg = response.data.data.msg;
|
|
477
|
+ console.log("患者不存在");
|
|
478
|
+ } else {
|
|
479
|
+ this.$toast("血透患者已存在");
|
|
480
|
+ return false;
|
|
481
|
+ }
|
|
482
|
+ });
|
|
483
|
+ }
|
|
484
|
+
|
|
485
|
+ if (val == 2) {
|
|
486
|
+ getSlowPatientInfo(this.patientForm.phone).then(response => {
|
|
487
|
+ if (response.data.state === 1) {
|
|
488
|
+ var msg = response.data.data.msg;
|
|
489
|
+ console.log("患者不存在");
|
|
490
|
+ } else {
|
|
491
|
+ this.$toast("慢病患者已存在");
|
|
492
|
+ return false;
|
|
493
|
+ }
|
|
494
|
+ });
|
|
495
|
+ }
|
|
496
|
+
|
|
497
|
+ if (val == 3) {
|
|
498
|
+ getMemberPatientInfo(this.patientForm.phone).then(response => {
|
|
499
|
+ if (response.data.state === 1) {
|
|
500
|
+ var msg = response.data.data.msg;
|
|
501
|
+ console.log("会员不存在");
|
|
502
|
+ } else {
|
|
503
|
+ this.$toast("会员已存在");
|
|
504
|
+ return false;
|
|
505
|
+ }
|
|
506
|
+ });
|
|
507
|
+ }
|
|
508
|
+
|
443
|
509
|
if (this.result.indexOf("1") != -1) {
|
444
|
510
|
this.bloodShow = true;
|
445
|
511
|
this.slowShow = false;
|
|
@@ -502,7 +568,6 @@ export default {
|
502
|
568
|
this.slowShow = false;
|
503
|
569
|
this.memberShow = false;
|
504
|
570
|
}
|
505
|
|
- GetPatientInfo(this.patientForm.phone).then(response => {});
|
506
|
571
|
},
|
507
|
572
|
|
508
|
573
|
generatedialysisno() {
|
|
@@ -569,14 +634,34 @@ export default {
|
569
|
634
|
this.$toast("患者标签不能为空");
|
570
|
635
|
return false;
|
571
|
636
|
}
|
572
|
|
- if (this.patientForm.dialysis === "") {
|
|
637
|
+ if (this.patientForm.dialysis === "" && this.result.indexOf("1") != -1) {
|
573
|
638
|
this.$toast("透析号不能为空");
|
574
|
639
|
return false;
|
575
|
640
|
}
|
576
|
|
- if (this.patientForm.patientsoure === "") {
|
|
641
|
+ if (
|
|
642
|
+ this.patientForm.patientsoure === "" &&
|
|
643
|
+ this.result.indexOf("1") != -1
|
|
644
|
+ ) {
|
577
|
645
|
this.$toast("患者来源不能为空");
|
578
|
646
|
return false;
|
579
|
647
|
}
|
|
648
|
+
|
|
649
|
+ for (let i = 0; i < this.result.length; i++) {
|
|
650
|
+ console.log("判断成立马", this.result[i]);
|
|
651
|
+ if (this.result[i] == 1) {
|
|
652
|
+ this.patientForm.bloodPatient = 1;
|
|
653
|
+ }
|
|
654
|
+ if (this.result[i] == 2) {
|
|
655
|
+ this.patientForm.slowPatient = 1;
|
|
656
|
+ }
|
|
657
|
+ if (this.result[i] == 3) {
|
|
658
|
+ this.patientForm.memberPatient = 1;
|
|
659
|
+ }
|
|
660
|
+ }
|
|
661
|
+
|
|
662
|
+ if (this.patientForm.patientsoure === "") {
|
|
663
|
+ this.patientForm.patientsoure = 0;
|
|
664
|
+ }
|
580
|
665
|
if (this.patientForm.patientsoure !== "") {
|
581
|
666
|
if (this.patientForm.patientsoure === "门诊") {
|
582
|
667
|
this.patientForm.patientsoure = 1;
|
|
@@ -585,10 +670,15 @@ export default {
|
585
|
670
|
this.patientForm.patientsoure = 2;
|
586
|
671
|
}
|
587
|
672
|
}
|
588
|
|
- if (this.patientForm.lapseto === "") {
|
|
673
|
+ if (this.patientForm.lapseto === "" && this.result.indexOf("1") != -1) {
|
589
|
674
|
this.$toast("留置状态不能为空");
|
590
|
675
|
return false;
|
591
|
676
|
}
|
|
677
|
+
|
|
678
|
+ if (this.patientForm.lapseto === "") {
|
|
679
|
+ this.patientForm.lapseto = 0;
|
|
680
|
+ }
|
|
681
|
+
|
592
|
682
|
if (this.patientForm.lapseto !== "") {
|
593
|
683
|
if (this.patientForm.lapseto === "留治") {
|
594
|
684
|
this.patientForm.lapseto = 1;
|
|
@@ -597,37 +687,11 @@ export default {
|
597
|
687
|
this.patientForm.lapseto = 2;
|
598
|
688
|
}
|
599
|
689
|
}
|
600
|
|
- if (this.resultTwo.length === 0) {
|
|
690
|
+ if (this.resultTwo.length === 0 && this.result.indexOf("1") != -1) {
|
601
|
691
|
this.$toast("传染病不能为空");
|
602
|
692
|
return false;
|
603
|
693
|
}
|
604
|
694
|
|
605
|
|
- for (let i = 0; i < this.result.length; i++) {
|
606
|
|
- if (this.result[i] == 1) {
|
607
|
|
- this.patientForm.bloodPatient = 1;
|
608
|
|
- }
|
609
|
|
- if (this.result[i] == 2) {
|
610
|
|
- this.patientForm.slowPatients = 1;
|
611
|
|
- }
|
612
|
|
- if (this.result[i] == 3) {
|
613
|
|
- this.patientForm.memberPatient = 1;
|
614
|
|
- }
|
615
|
|
- }
|
616
|
|
-
|
617
|
|
- if (this.patientForm.slowDisease === "") {
|
618
|
|
- this.patientForm.slowDisease = 0;
|
619
|
|
- }
|
620
|
|
-
|
621
|
|
- if (this.patientForm.slowDisease === "慢性病") {
|
622
|
|
- this.patientForm.slowDisease = 1;
|
623
|
|
- }
|
624
|
|
- if (this.patientForm.slowDisease === "神经病") {
|
625
|
|
- this.patientForm.slowDisease = 2;
|
626
|
|
- }
|
627
|
|
- if (this.patientForm.slowDisease === "抑郁症") {
|
628
|
|
- this.patientForm.slowDisease = 3;
|
629
|
|
- }
|
630
|
|
-
|
631
|
695
|
console.log("治疗方式", this.patientForm.treatmentMethod);
|
632
|
696
|
|
633
|
697
|
if (this.patientForm.treatmentMethod === undefined) {
|
|
@@ -682,7 +746,7 @@ export default {
|
682
|
746
|
avatar: this.patientForm.avatar,
|
683
|
747
|
requipmentId: this.patientForm.requipmentId, // 慢病信息
|
684
|
748
|
resultThree: this.resultThree,
|
685
|
|
- slowDisease: this.patientForm.slowDisease,
|
|
749
|
+ resultFour: this.resultFour,
|
686
|
750
|
patientType: this.patientForm.patient_type,
|
687
|
751
|
memberFistDate: this.patientForm.memberFistDate,
|
688
|
752
|
treatmentMethod: this.patientForm.treatmentMethod
|
|
@@ -701,8 +765,6 @@ export default {
|
701
|
765
|
checkMobile() {
|
702
|
766
|
if (!checkMobile(this.patientForm.phone)) {
|
703
|
767
|
this.$toast("请填写正确的手机号");
|
704
|
|
- } else {
|
705
|
|
- callback();
|
706
|
768
|
}
|
707
|
769
|
},
|
708
|
770
|
checkIdCardNo() {
|