Browse Source

库存调拨修改

28169 2 years ago
parent
commit
51f100643a

+ 34 - 27
controllers/mobile_api_controllers/dialysis_api_controller.go View File

@@ -786,30 +786,30 @@ func (c *DialysisAPIController) PostDoubleCheck() {
786 786
 		firstCheckDate = firstCheckDateUnix.Unix()
787 787
 	}
788 788
 
789
-	if adminUserInfo.Org.Id == 10340 {
790
-
791
-		list, _ := service.GetRoleList(adminUserInfo.Org.Id, modifier)
792
-		_, check := service.FindDoubleCheckByReordDate(id, recordDate.Unix(), adminUserInfo.Org.Id)
793
-		if check.ID == 0 {
794
-			if employee_number != list.JobNumber {
795
-				c.ServeSuccessJSON(map[string]interface{}{
796
-					"doubleCheck": check,
797
-					"msg":         "2",
798
-				})
799
-				return
800
-			}
801
-		}
802
-		if check.ID > 0 {
803
-			if employee_number != list.JobNumber {
804
-				c.ServeSuccessJSON(map[string]interface{}{
805
-					"doubleCheck": check,
806
-					"msg":         "2",
807
-				})
808
-				return
809
-			}
810
-		}
811
-
812
-	}
789
+	//if adminUserInfo.Org.Id == 10340 {
790
+	//
791
+	//	list, _ := service.GetRoleList(adminUserInfo.Org.Id, modifier)
792
+	//	_, check := service.FindDoubleCheckByReordDate(id, recordDate.Unix(), adminUserInfo.Org.Id)
793
+	//	if check.ID == 0 {
794
+	//		if employee_number != list.JobNumber {
795
+	//			c.ServeSuccessJSON(map[string]interface{}{
796
+	//				"doubleCheck": check,
797
+	//				"msg":         "2",
798
+	//			})
799
+	//			return
800
+	//		}
801
+	//	}
802
+	//	if check.ID > 0 {
803
+	//		if employee_number != list.JobNumber {
804
+	//			c.ServeSuccessJSON(map[string]interface{}{
805
+	//				"doubleCheck": check,
806
+	//				"msg":         "2",
807
+	//			})
808
+	//			return
809
+	//		}
810
+	//	}
811
+	//
812
+	//}
813 813
 
814 814
 	doubleCheck := models.DoubleCheck{
815 815
 		UserOrgId:                  adminUserInfo.Org.Id,
@@ -1462,7 +1462,8 @@ func (c *DialysisAPIController) PostDialysisPrescription() {
1462 1462
 	start_sodium := c.GetString("start_sodium")
1463 1463
 	sodium_curve := c.GetString("sodium_curve")
1464 1464
 	treatment_remark := c.GetString("treatment_remark")
1465
-
1465
+	dialysis_fluid_flow := c.GetString("dialysis_fluid_flow")
1466
+	sodium_bicarbonate_flow := c.GetString("sodium_bicarbonate_flow")
1466 1467
 	appRole, _ := service.FindAdminRoleTypeById(adminUserInfo.Org.Id, adminUserInfo.AdminUser.Id, adminUserInfo.App.Id)
1467 1468
 
1468 1469
 	//template, _ := service.GetOrgInfoTemplate(adminUserInfo.Org.Id)
@@ -1593,6 +1594,8 @@ func (c *DialysisAPIController) PostDialysisPrescription() {
1593 1594
 		SodiumCurve:                sodium_curve,
1594 1595
 		TreatmentRemark:            treatment_remark,
1595 1596
 		PrescriptionSodium:         prescription_sodium,
1597
+		DialysisFluidFlow:          dialysis_fluid_flow,
1598
+		SodiumBicarbonateFlow:      sodium_bicarbonate_flow,
1596 1599
 	}
1597 1600
 
1598 1601
 	//查询最近透析准备表里是否存在 透析器 灌流器
@@ -3009,6 +3012,8 @@ func (c *DialysisAPIController) PostSolution() {
3009 3012
 	dry_water_hour := c.GetString("dry_water_hour")
3010 3013
 	water_machine := c.GetString("water_machine")
3011 3014
 	dialysis_remark := c.GetString("dialysis_remark")
3015
+	dialysis_fluid_flow := c.GetString("dialysis_fluid_flow")
3016
+	sodium_bicarbonate_flow := c.GetString("sodium_bicarbonate_flow")
3012 3017
 	if mode_id > 0 {
3013 3018
 
3014 3019
 		var str string
@@ -3137,6 +3142,8 @@ func (c *DialysisAPIController) PostSolution() {
3137 3142
 		StartSodium:                start_sodium,
3138 3143
 		SodiumCurve:                sodium_curve,
3139 3144
 		TreatmentRemark:            treatment_remark,
3145
+		DialysisFluidFlow:          dialysis_fluid_flow,
3146
+		SodiumBicarbonateFlow:      sodium_bicarbonate_flow,
3140 3147
 	}
3141 3148
 
3142 3149
 	_, dialysisPrescription := service.FindDialysisPrescriptionByReordDate(id, recordDate.Unix(), adminUserInfo.Org.Id)
@@ -3241,6 +3248,8 @@ func (c *DialysisAPIController) PostSolution() {
3241 3248
 		StartSodium:                start_sodium,
3242 3249
 		SodiumCurve:                sodium_curve,
3243 3250
 		TreatmentRemark:            treatment_remark,
3251
+		SodiumBicarbonateFlow:      sodium_bicarbonate_flow,
3252
+		DialysisFluidFlow:          dialysis_fluid_flow,
3244 3253
 	}
3245 3254
 
3246 3255
 	//针对河间咸的
@@ -6350,7 +6359,6 @@ func (c *DialysisAPIController) CreateOtherStockOutInfo() {
6350 6359
 	for _, item := range beforePrepares {
6351 6360
 		storeConfig, _ := service.GetAllStoreHouseConfig(adminInfo.Org.Id)
6352 6361
 		warehouse, _ := service.FindFirstWarehousingInfoByStockTwo(item.GoodId, item.GoodTypeId, storeConfig.StorehouseOutInfo)
6353
-
6354 6362
 		if item.Count > warehouse.Count {
6355 6363
 			goodObj, _ := service.GetGoodInformationByGoodId(item.GoodId)
6356 6364
 			c.ServeSuccessJSON(map[string]interface{}{
@@ -6360,7 +6368,6 @@ func (c *DialysisAPIController) CreateOtherStockOutInfo() {
6360 6368
 			})
6361 6369
 			return
6362 6370
 		}
6363
-
6364 6371
 	}
6365 6372
 
6366 6373
 	//出库逻辑

+ 2 - 0
models/dialysis.go View File

@@ -759,6 +759,7 @@ type MonitoringRecord struct {
759 759
 	BloodMonitor                float64 `gorm:"column:blood_monitor" json:"blood_monitor" form:"blood_monitor"`
760 760
 	HeparinAmount               float64 `gorm:"column:heparin_amount" json:"heparin_amount" form:"heparin_amount"`
761 761
 	Dehydration                 float64 `gorm:"column:dehydration" json:"dehydration" form:"dehydration"`
762
+	FilterPressure              string  `gorm:"column:filter_pressure" json:"filter_pressure" form:"filter_pressure"`
762 763
 }
763 764
 
764 765
 func (MonitoringRecord) TableName() string {
@@ -1101,6 +1102,7 @@ type DialysisBeforePrepareGoods struct {
1101 1102
 	StorehouseId      int64  `gorm:"column:storehouse_id" json:"storehouse_id" form:"storehouse_id"`
1102 1103
 	PatientId         int64  `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
1103 1104
 	OrderId           int64  `gorm:"column:order_id" json:"order_id" form:"order_id"`
1105
+	NewCount          int64  `gorm:"column:new_count" json:"new_count" form:"new_count"`
1104 1106
 }
1105 1107
 
1106 1108
 type NewDialysisBeforePrepareGoods struct {

+ 2 - 0
service/print_data_service/schedule_dialysis/print_schedule_dialysis_models.go View File

@@ -103,6 +103,7 @@ type DialysisOrderVM struct {
103 103
 	SchedualType   int64           `gorm:"column:schedual_type" json:"schedual_type"`
104 104
 	WashpipeNurse  int64           `gorm:"column:washpipe_nurse" json:"washpipe_nurse" form:"washpipe_nurse"`
105 105
 	UserOrgId      int64           `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
106
+	QualityNurseId int64           `gorm:"column:quality_nurse_id" json:"quality_nurse_id" form:"quality_nurse_id"`
106 107
 }
107 108
 
108 109
 func (DialysisOrderVM) TableName() string {
@@ -554,6 +555,7 @@ type MonitoringRecordVM struct {
554 555
 	BloodMonitor                float64 `gorm:"column:blood_monitor" json:"blood_monitor" form:"blood_monitor"`
555 556
 	BloodPressureMonitoringSite int64   `gorm:"column:blood_pressure_monitoring_site" json:"blood_pressure_monitoring_site" form:"blood_pressure_monitoring_site"`
556 557
 	UserOrgId                   int64   `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
558
+	FilterPressure              string  `gorm:"column:filter_pressure" json:"filter_pressure" form:"filter_pressure"`
557 559
 }
558 560
 
559 561
 func (MonitoringRecordVM) TableName() string {

+ 1 - 1
service/warhouse_service.go View File

@@ -7445,7 +7445,7 @@ func ConsumablesDeliveryTotal(orgID int64, patient_id int64, record_time int64,
7445 7445
 		}
7446 7446
 
7447 7447
 	}
7448
-	fmt.Println("goods_yc2323323223323223232323232332wode", goods_yc)
7448
+
7449 7449
 	if len(goods_yc) > 0 {
7450 7450
 		for _, good_yc := range goods_yc {
7451 7451
 			out, _ := FindStockOutByIsSys(orgID, 1, record_time)