|
@@ -5,6 +5,7 @@ import cn.hnthyy.thmz.entity.jy.ResultVo;
|
|
|
import cn.hnthyy.thmz.entity.yb.DrugTracCodg;
|
|
|
import cn.hnthyy.thmz.entity.yb.SelinfoSold;
|
|
|
import cn.hnthyy.thmz.entity.yb.SelinfoReturn;
|
|
|
+import cn.hnthyy.thmz.entity.yb.SelinfoSoldTotal;
|
|
|
import cn.hnthyy.thmz.mapper.his.yb.SelinfoSoldMapper;
|
|
|
import cn.hnthyy.thmz.service.taobao.TaobaoService;
|
|
|
import com.alibaba.fastjson.JSONArray;
|
|
@@ -57,19 +58,20 @@ public class YbService {
|
|
|
* 3. 医保系统记录关联字段,便于后续查询和审计
|
|
|
* 4. 可通过关联字段查询具体的发药记录和追溯码信息
|
|
|
*
|
|
|
- * @param selInfo 医保销售信息对象,包含关联字段和药品追溯码信息
|
|
|
+ * @param selinfoSoldTotal 医保销售信息对象,包含关联字段和药品追溯码信息
|
|
|
* @return ResultVo 医保接口调用结果
|
|
|
*/
|
|
|
- public ResultVo saleGoodsItem(SelinfoSold selInfo) {
|
|
|
+ public ResultVo saleGoodsItem(SelinfoSoldTotal selinfoSoldTotal) {
|
|
|
ResultVo response = null;
|
|
|
+ SelinfoSold selInfo = selinfoSoldTotal.getSelinfoSold();
|
|
|
|
|
|
// 记录关联字段信息(用于关联发药记录)
|
|
|
// 这些字段用于后续查询发药记录,确保医保记录与发药记录的一一对应
|
|
|
- log.info("医保接口调用 - 关联字段: patientId={}, times={}, receiptNo={}, orderNo={}, chargeItemCode={}, realNo={}",
|
|
|
- selInfo.getPatientId(), selInfo.getTimes(), selInfo.getReceiptNo(),
|
|
|
+ log.info("医保接口调用 - 关联字段: patientId={}, times={}, receiptNo={}, orderNo={}, chargeItemCode={}, realNo={}",
|
|
|
+ selInfo.getPatientId(), selInfo.getTimes(), selInfo.getReceiptNo(),
|
|
|
selInfo.getOrderNo(), selInfo.getChargeItemCode(), selInfo.getRealNo());
|
|
|
|
|
|
- List<DrugTracCodg> drugTracCodgList = selInfo.getDrugtracinfo();
|
|
|
+ List<DrugTracCodg> drugTracCodgList = selinfoSoldTotal.getDrugtracinfo();
|
|
|
if(drugTracCodgList == null || drugTracCodgList.isEmpty()) {
|
|
|
response = new ResultVo(-1, "追溯码不能为空");
|
|
|
return response;
|
|
@@ -205,7 +207,7 @@ public class YbService {
|
|
|
log.info("医保退药接口 - 关联键: {}", associationKey);
|
|
|
|
|
|
// 处理追溯码信息(如果有的话)
|
|
|
- if(drugTracCodgList != null && !drugTracCodgList.isEmpty()) {
|
|
|
+ /*if(drugTracCodgList != null && !drugTracCodgList.isEmpty()) {
|
|
|
String drugTracCodg = drugTracCodgList.get(0).getDrugTracCodg();
|
|
|
String result = taobaoService.sendGet("/queryCodeDetail?codes=" + drugTracCodg);
|
|
|
JSONObject resultJson = JSONObject.parseObject(result);
|
|
@@ -228,7 +230,7 @@ public class YbService {
|
|
|
}
|
|
|
} else {
|
|
|
log.warn("退药操作没有追溯码信息,继续处理");
|
|
|
- }
|
|
|
+ }*/
|
|
|
|
|
|
selinfoReturn.setSelRetnCnt(drugTracCodgList != null ? drugTracCodgList.size() : 0);
|
|
|
String now = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(new Date());
|