|
@@ -797,6 +797,8 @@ func (c *PublicApiController) GetBaiLinExportData() {
|
797
|
797
|
|
798
|
798
|
func (c *HisApiController) GetHisUnChargePatientList() {
|
799
|
799
|
record_date := c.GetString("record_date")
|
|
800
|
+ sch_type, _ := c.GetInt64("sch_type")
|
|
801
|
+
|
800
|
802
|
timeLayout := "2006-01-02"
|
801
|
803
|
loc, _ := time.LoadLocation("Local")
|
802
|
804
|
theTime, err := time.ParseInLocation(timeLayout+" 15:04:05", record_date+" 00:00:00", loc)
|
|
@@ -808,7 +810,7 @@ func (c *HisApiController) GetHisUnChargePatientList() {
|
808
|
810
|
adminInfo := c.GetAdminUserInfo()
|
809
|
811
|
var tempPatients []*service.NewTempPatients
|
810
|
812
|
//tempPatients, _ := service.GetAllChargeHisPatientList(adminInfo.CurrentOrgId, "", recordDateTime)
|
811
|
|
- tempPatients, _ = service.GetNewAllUnChargeHisPatientList(adminInfo.CurrentOrgId, "", recordDateTime)
|
|
813
|
+ tempPatients, _ = service.GetNewAllUnChargeHisPatientList(adminInfo.CurrentOrgId, "", recordDateTime, sch_type)
|
812
|
814
|
var patients []*service.NewTempPatients
|
813
|
815
|
var patients_two []*service.NewTempPatients
|
814
|
816
|
|
|
@@ -6806,6 +6808,26 @@ func (c *HisApiController) GetUploadInfo() {
|
6806
|
6808
|
|
6807
|
6809
|
dec_way := c.GetString("dec_way") //是否使用押金支付bool类型
|
6808
|
6810
|
tmp_decimal := c.GetString("tmp_decimal")
|
|
6811
|
+
|
|
6812
|
+ //last_order, _ := service.GetLastHisOrderThree(c.GetAdminUserInfo().CurrentOrgId)
|
|
6813
|
+ max_order, _ := service.GetLastHisOrderTwo(c.GetAdminUserInfo().CurrentOrgId)
|
|
6814
|
+ count, _ := strconv.ParseInt(max_order.FaPiaoNumber, 10, 64)
|
|
6815
|
+ fmt.Println(count)
|
|
6816
|
+ var zero string
|
|
6817
|
+ number := count + 1
|
|
6818
|
+ if number >= 1000 {
|
|
6819
|
+ zero = "0000" + strconv.FormatInt(number, 10)
|
|
6820
|
+ } else if number >= 10000 {
|
|
6821
|
+ zero = "000" + strconv.FormatInt(number, 10)
|
|
6822
|
+ } else if number >= 100000 {
|
|
6823
|
+ zero = "00" + strconv.FormatInt(number, 10)
|
|
6824
|
+ } else if number >= 1000000 {
|
|
6825
|
+ zero = "0" + strconv.FormatInt(number, 10)
|
|
6826
|
+ } else {
|
|
6827
|
+ zero = strconv.FormatInt(number, 10)
|
|
6828
|
+ }
|
|
6829
|
+ fapiao_number = zero
|
|
6830
|
+
|
6809
|
6831
|
var decimal float64 //本次使用的押金
|
6810
|
6832
|
var errmsg error
|
6811
|
6833
|
tx := service.XTWriteDB().Begin() //开了事务
|
|
@@ -7699,6 +7721,7 @@ func (this *HisApiController) GetHisDayPrescription() {
|
7699
|
7721
|
func (c *HisApiController) GetHisChargePatientList() {
|
7700
|
7722
|
record_date := c.GetString("record_date")
|
7701
|
7723
|
order_status, _ := c.GetInt64("type")
|
|
7724
|
+ sch_type, _ := c.GetInt64("sch_type")
|
7702
|
7725
|
|
7703
|
7726
|
timeLayout := "2006-01-02"
|
7704
|
7727
|
loc, _ := time.LoadLocation("Local")
|
|
@@ -7712,9 +7735,9 @@ func (c *HisApiController) GetHisChargePatientList() {
|
7712
|
7735
|
var tempPatients []*service.NewTempPatients
|
7713
|
7736
|
//tempPatients, _ := service.GetAllChargeHisPatientList(adminInfo.CurrentOrgId, "", recordDateTime)
|
7714
|
7737
|
if order_status != 2 {
|
7715
|
|
- tempPatients, _ = service.GetNewAllUnChargeHisPatientList(adminInfo.CurrentOrgId, "", recordDateTime)
|
|
7738
|
+ tempPatients, _ = service.GetNewAllUnChargeHisPatientList(adminInfo.CurrentOrgId, "", recordDateTime, sch_type)
|
7716
|
7739
|
} else {
|
7717
|
|
- tempPatients, _ = service.GetNewAllChargeHisPatientList(adminInfo.CurrentOrgId, "", recordDateTime)
|
|
7740
|
+ tempPatients, _ = service.GetNewAllChargeHisPatientList(adminInfo.CurrentOrgId, "", recordDateTime, sch_type)
|
7718
|
7741
|
}
|
7719
|
7742
|
|
7720
|
7743
|
var patients []*service.NewTempPatients
|
|
@@ -8876,8 +8899,9 @@ func (c *HisApiController) GetFaPiaoData() {
|
8876
|
8899
|
admin, _ := service.GetAdminUserInfoByID(adminUser.CurrentOrgId, adminUser.AdminUser.Id)
|
8877
|
8900
|
|
8878
|
8901
|
c.ServeSuccessJSON(map[string]interface{}{
|
8879
|
|
- "order_number": order.Number, //业务流水号
|
8880
|
|
- "id_card_no": his.IdCardNo, //社会保障号
|
|
8902
|
+ "order_number": order.Number, //业务流水号
|
|
8903
|
+ "id_card_no": his.IdCardNo, //社会保障号
|
|
8904
|
+ "patient": patient,
|
8881
|
8905
|
"department_name": department.Name, //科室
|
8882
|
8906
|
"number": his.Number, //门诊号
|
8883
|
8907
|
"date": order.SettleAccountsDate, //结算日期
|