|
@@ -4552,6 +4552,7 @@ func (c *HisApiController) GetSettleAccounts() {
|
4552
|
4552
|
//diagnosisConfig, _ := service.FindDiagnoseById(his.Diagnosis)
|
4553
|
4553
|
|
4554
|
4554
|
diagnosis_ids := strings.Split(his.Diagnosis, ",")
|
|
4555
|
+ patient, _ := service.GetPatientByIDTwo(adminUser.CurrentOrgId, order.PatientId)
|
4555
|
4556
|
|
4556
|
4557
|
//var config []*models.HisXtDiagnoseConfig
|
4557
|
4558
|
var name string
|
|
@@ -4706,6 +4707,46 @@ func (c *HisApiController) GetSettleAccounts() {
|
4706
|
4707
|
printor_admin, _ := service.GetAdminUserInfoByID(adminUser.CurrentOrgId, admin_user_id)
|
4707
|
4708
|
charge_admin, _ := service.GetAdminUserInfoByID(adminUser.CurrentOrgId, order.Creator)
|
4708
|
4709
|
|
|
4710
|
+ patientPrescription, _ := service.FindPatientPrescriptionInfo(adminUser.CurrentOrgId, order.PatientId, order.SettleAccountsDate)
|
|
4711
|
+ adminRole_two, _ := service.GetAdminUserInfoByID(adminUser.CurrentOrgId, patientPrescription.DoctorId)
|
|
4712
|
+
|
|
4713
|
+ roles, _ := service.GetAdminUserInfoByID(adminUser.CurrentOrgId, admin_user_id)
|
|
4714
|
+
|
|
4715
|
+ var doctor_name string
|
|
4716
|
+ if roles.ID == 0 {
|
|
4717
|
+ doctor_name = "管理员"
|
|
4718
|
+ } else {
|
|
4719
|
+ doctor_name = roles.UserName
|
|
4720
|
+ }
|
|
4721
|
+
|
|
4722
|
+ yiliao_leibie := ""
|
|
4723
|
+
|
|
4724
|
+ switch order.MedType {
|
|
4725
|
+ case "11":
|
|
4726
|
+ yiliao_leibie = "普通门诊"
|
|
4727
|
+ break
|
|
4728
|
+ case "12":
|
|
4729
|
+ yiliao_leibie = "门诊挂号"
|
|
4730
|
+ break
|
|
4731
|
+ case "13":
|
|
4732
|
+ yiliao_leibie = "急诊"
|
|
4733
|
+ break
|
|
4734
|
+ case "14":
|
|
4735
|
+ yiliao_leibie = "门诊特殊病"
|
|
4736
|
+ break
|
|
4737
|
+ case "15":
|
|
4738
|
+ yiliao_leibie = "门诊统筹"
|
|
4739
|
+ break
|
|
4740
|
+ case "16":
|
|
4741
|
+ yiliao_leibie = "门诊慢性病"
|
|
4742
|
+ break
|
|
4743
|
+ case "21":
|
|
4744
|
+ yiliao_leibie = "普通住院"
|
|
4745
|
+ break
|
|
4746
|
+ }
|
|
4747
|
+
|
|
4748
|
+ departments, _ := service.GetDepartMentDetail(patientPrescription.Departments)
|
|
4749
|
+
|
4709
|
4750
|
if res.Infcode == 0 {
|
4710
|
4751
|
c.ServeSuccessJSON(map[string]interface{}{
|
4711
|
4752
|
"diagnosis": name,
|
|
@@ -4742,6 +4783,16 @@ func (c *HisApiController) GetSettleAccounts() {
|
4742
|
4783
|
"treatCostTotal": treatCostTotal,
|
4743
|
4784
|
"treatCostSelfTotal": treatCostSelfTotal,
|
4744
|
4785
|
"treatCostPartSelfTotal": treatCostPartSelfTotal,
|
|
4786
|
+ "doctor_code": adminRole_two.DoctorCode,
|
|
4787
|
+ "doctor_name": doctor_name,
|
|
4788
|
+ "health_card_no": order.PsnNo,
|
|
4789
|
+ "department": departments.Name,
|
|
4790
|
+ "yiliao_leibie": yiliao_leibie,
|
|
4791
|
+ "after_money": order.AccountPrice,
|
|
4792
|
+ "patient": patient,
|
|
4793
|
+ "org_name": miConfig.OrgName,
|
|
4794
|
+ "org_code": miConfig.Code,
|
|
4795
|
+ "order_number": order.Number,
|
4745
|
4796
|
})
|
4746
|
4797
|
}
|
4747
|
4798
|
}
|