csx 3 år sedan
förälder
incheckning
566981f357
1 ändrade filer med 1 tillägg och 1 borttagningar
  1. 1 1
      service/bl_service.go

+ 1 - 1
service/bl_service.go Visa fil

@@ -744,7 +744,7 @@ func GetResultDataInsertDB(org_id int64) (result []*CmResult) {
744 744
 					}
745 745
 
746 746
 					var itotal int
747
-					err = readMiddleDb.Model(&models.MiddleInspection{}).Where("org_id = ? and project_id = ? and item_id = ? and record_date = ? and patient_id = ?  and status = 1", org_id, project_id, item_id, record_date, printInfo.PatientId).Find(&inspection).Count(&itotal).Error
747
+					err = readMiddleDb.Model(&models.MiddleInspection{}).Where("org_id = ? and project_id = ? and item_id = ? and record_date = ? and patient_id = ?  and status = 1", org_id, project_id, item_id, record_date.Unix(), printInfo.PatientId).Find(&inspection).Count(&itotal).Error
748 748
 					if itotal <= 0 {
749 749
 						inspection.PatientId = printInfo.PatientId
750 750
 						inspection.OrgId = org_id