Browse Source

Merge branch 'master' of http://git.shengws.com/csx/gdyb

csx 3 years ago
parent
commit
6bdd0574c0

+ 1 - 1
controllers/js/jsyb_controller.go View File

252
 	}
252
 	}
253
 	fmt.Println("2203A的time_stamp=" + respJSON["time_stamp"].(string))
253
 	fmt.Println("2203A的time_stamp=" + respJSON["time_stamp"].(string))
254
 	result, request_log := service.Jsyb2204(respJSON["psn_no"].(string), respJSON["mdtrt_id"].(string), hp, respJSON["chrg_bchno"].(string), respJSON["org_name"].(string),
254
 	result, request_log := service.Jsyb2204(respJSON["psn_no"].(string), respJSON["mdtrt_id"].(string), hp, respJSON["chrg_bchno"].(string), respJSON["org_name"].(string),
255
-		respJSON["doctor"].(string), respJSON["dept"].(string), respJSON["fixmedins_code"].(string), respJSON["dept_code"].(string), respJSON["doctor_id"].(string), respJSON["insuplc_admdvs"].(string), respJSON["mdtrtarea_admvs"].(string), respJSON["diag_code"].(string), respJSON["secret_key"].(string), respJSON["balance_accounts_type"].(string), respJSON["url"].(string), respJSON["ak"].(string), respJSON["new_doctor_name"].(string), respJSON["time_stamp"].(int64))
255
+		respJSON["doctor"].(string), respJSON["dept"].(string), respJSON["fixmedins_code"].(string), respJSON["dept_code"].(string), respJSON["doctor_id"].(string), respJSON["insuplc_admdvs"].(string), respJSON["mdtrtarea_admvs"].(string), respJSON["diag_code"].(string), respJSON["secret_key"].(string), respJSON["balance_accounts_type"].(string), respJSON["url"].(string), respJSON["ak"].(string), respJSON["new_doctor_name"].(string), respJSON["time_stamp"].(string))
256
 
256
 
257
 	var dat map[string]interface{}
257
 	var dat map[string]interface{}
258
 	if err := json.Unmarshal([]byte(result), &dat); err == nil {
258
 	if err := json.Unmarshal([]byte(result), &dat); err == nil {

+ 3 - 7
controllers/sg/his_api_controller.go View File

5264
 
5264
 
5265
 	var res2 ResultSix
5265
 	var res2 ResultSix
5266
 	var resSix10265 ResultSix10265
5266
 	var resSix10265 ResultSix10265
5267
-	var time_stamp int64
5267
+	var time_stamp string
5268
 	if miConfig.InsuplcAdmdvs == "421300" {
5268
 	if miConfig.InsuplcAdmdvs == "421300" {
5269
 		data := make(map[string]interface{})
5269
 		data := make(map[string]interface{})
5270
 		client := &http.Client{}
5270
 		client := &http.Client{}
5354
 			c.ServeFailJSONWithSGJErrorCode(enums.ErrorCodeDataException)
5354
 			c.ServeFailJSONWithSGJErrorCode(enums.ErrorCodeDataException)
5355
 			return
5355
 			return
5356
 		}
5356
 		}
5357
-		fmt.Println("-------")
5358
-		fmt.Println(respJSON["data"])
5359
-		fmt.Println(respJSON["data"].(map[string]interface{})["time_stamp"])
5360
-		//fmt.Println(respJSON["data"].(map[string]interface{})["time_stamp"].(float64))
5361
-		fmt.Println("-------")
5362
 
5357
 
5363
 		//time_stamp = int64(respJSON["data"].(map[string]interface{})["time_stamp"].(float64))
5358
 		//time_stamp = int64(respJSON["data"].(map[string]interface{})["time_stamp"].(float64))
5364
-
5359
+		fmt.Println(respJSON["data"].(map[string]interface{})["time_stamp"].(string))
5360
+		time_stamp = respJSON["data"].(map[string]interface{})["time_stamp"].(string)
5365
 		respJSON = respJSON["data"].(map[string]interface{})["pre"].(map[string]interface{})
5361
 		respJSON = respJSON["data"].(map[string]interface{})["pre"].(map[string]interface{})
5366
 		userJSONBytes, _ := json.Marshal(respJSON)
5362
 		userJSONBytes, _ := json.Marshal(respJSON)
5367
 		fmt.Println("log")
5363
 		fmt.Println("log")

+ 3 - 2
service/jsyb_service.go View File

303
 }
303
 }
304
 
304
 
305
 //  门诊费用明细信息上传
305
 //  门诊费用明细信息上传
306
-func Jsyb2204(psnNo string, mdtrtId string, hisPrescription []*models.HisPrescription, chrg_bchno string, org_name string, doctor string, dept string, fixmedins_code string, dept_code string, doctor_id string, insuplc_admdvs string, mdtrtarea_admvs string, secret_key string, balance_accounts_type string, diag_code string, request_url string, access_key string, new_doctor_name string, time_stamp_2203 int64) (string, string) {
306
+func Jsyb2204(psnNo string, mdtrtId string, hisPrescription []*models.HisPrescription, chrg_bchno string, org_name string, doctor string, dept string, fixmedins_code string, dept_code string, doctor_id string, insuplc_admdvs string, mdtrtarea_admvs string, secret_key string, balance_accounts_type string, diag_code string, request_url string, access_key string, new_doctor_name string, time_stamp_2203 string) (string, string) {
307
 	// 生成签名
307
 	// 生成签名
308
 	timestamp := time.Now().Unix()
308
 	timestamp := time.Now().Unix()
309
 	tempTime := time.Unix(timestamp, 0)
309
 	tempTime := time.Unix(timestamp, 0)
482
 		return "", ""
482
 		return "", ""
483
 	}
483
 	}
484
 	request_url = request_url + "2204"
484
 	request_url = request_url + "2204"
485
-	return HttpRequest(request_url, access_key, secret_key, time_stamp_2203, string(bytesData)), requestLog
485
+	time_stamp, _ := strconv.ParseInt(time_stamp_2203, 10, 64)
486
+	return HttpRequest(request_url, access_key, secret_key, time_stamp, string(bytesData)), requestLog
486
 }
487
 }
487
 
488
 
488
 //  门诊费用明细信息撤销
489
 //  门诊费用明细信息撤销