|
@@ -594,7 +594,7 @@ func GetAdviceBySyncAdviceId(orgId int64, sync_advice_id int64) (advice models.X
|
594
|
594
|
return
|
595
|
595
|
}
|
596
|
596
|
|
597
|
|
-func GetAdviceBySyncAdviceIdTwo(orgId int64, sync_advice_id int64) (advice models.XtDoctorAdvice, err error) {
|
|
597
|
+func GetAdviceBySyncAdviceIdTwo(orgId int64, sync_advice_id string) (advice models.XtDoctorAdvice, err error) {
|
598
|
598
|
err = readDb.Model(&models.XtDoctorAdvice{}).Where("status = 1 AND user_org_id = ? AND sync_id = ?", orgId, sync_advice_id).First(&advice).Error
|
599
|
599
|
return
|
600
|
600
|
}
|
|
@@ -605,7 +605,7 @@ func HttpGetTfData(id_card_no string, advice_time string) (string, string) {
|
605
|
605
|
|
606
|
606
|
inputData["病人来源"] = "1"
|
607
|
607
|
inputData["身份证号"] = id_card_no
|
608
|
|
- inputData["开嘱时间"] = "2022-07-26 17:41:22"
|
|
608
|
+ inputData["开嘱时间"] = advice_time
|
609
|
609
|
|
610
|
610
|
var inputLog string
|
611
|
611
|
bytesData, err := json.Marshal(inputData)
|
|
@@ -1719,7 +1719,7 @@ func Synctfyz() (err error) {
|
1719
|
1719
|
}
|
1720
|
1720
|
utils.InfoLog("advice:%v", advice)
|
1721
|
1721
|
// 根据同步来的 advice_id 来查询库里是否已经存在
|
1722
|
|
- advice_info, _ := GetAdviceBySyncAdviceIdTwo(org_id, yz.AdviceId)
|
|
1722
|
+ advice_info, _ := GetAdviceBySyncAdviceIdTwo(org_id, strconv.FormatInt(yz.AdviceId,10))
|
1723
|
1723
|
utils.InfoLog("advice_info:%v", advice_info)
|
1724
|
1724
|
if advice_info.ID > 0 {
|
1725
|
1725
|
key := strconv.FormatInt(org_id, 10) + ":" + strconv.FormatInt(temp_patient_id, 10) + ":" + strconv.FormatInt(schedulesTime, 10) + ":doctor_advices"
|