关联关系修改,扫码补齐修改,bug修改

dev_unify
yewj 8 months ago
parent ebecb976e1
commit da5b51268c

@ -82,6 +82,7 @@ public class RelCodeBatchController extends BaseController {
@GetMapping("/udiwms/relCode/batch/filter") @GetMapping("/udiwms/relCode/batch/filter")
public BaseResponse list(RelCodeBatchRequest relCodeBatchRequest, BindingResult bindingResult) { public BaseResponse list(RelCodeBatchRequest relCodeBatchRequest, BindingResult bindingResult) {
String customerId = getCustomerId(); String customerId = getCustomerId();
if (!customerId.equals("110"))
relCodeBatchRequest.setErpId(customerId); relCodeBatchRequest.setErpId(customerId);
List<RelCodeBatchResponse> relCodeBatchResponses = relCodeBatchService.filterList(relCodeBatchRequest); List<RelCodeBatchResponse> relCodeBatchResponses = relCodeBatchService.filterList(relCodeBatchRequest);
PageInfo<RelCodeBatchResponse> pageInfo = new PageInfo<>(relCodeBatchResponses); PageInfo<RelCodeBatchResponse> pageInfo = new PageInfo<>(relCodeBatchResponses);

@ -406,7 +406,8 @@ public class SpsSyncDownloadController {
saveUploadProBusinessData(JSONUtil.toBean(obj, SpsSyncProBusinessDataResponse.class)); saveUploadProBusinessData(JSONUtil.toBean(obj, SpsSyncProBusinessDataResponse.class));
break; break;
case DRUG_DATA_TASK: case DRUG_DATA_TASK:
saveUploadDrugData(JSONUtil.toBean(obj, SpsSyncDrugDataTaskResponse.class)); //不允许内网同步zhi
// saveUploadDrugData(JSONUtil.toBean(obj, SpsSyncDrugDataTaskResponse.class));
break; break;
} }
String taskId = obj.getStr("taskId"); String taskId = obj.getStr("taskId");

@ -105,8 +105,8 @@ public class AlihealthKytSinglerelationResponse extends AlihealthKytCommonParame
// relCodeBatch.setCreateUser(); // relCodeBatch.setCreateUser();
relCodeBatch.setUpdateTime(new Date()); relCodeBatch.setUpdateTime(new Date());
relCodeBatch.setUpdateUser(customerId); relCodeBatch.setUpdateUser(customerId);
relCodeBatch.setUploadFlagUp(1); relCodeBatch.setUploadFlagUp(0);
relCodeBatch.setUploadFlagDown(1); relCodeBatch.setUploadFlagDown(0);
relCodeBatch.setParentCode(null); relCodeBatch.setParentCode(null);
// relCodeBatch.setErpId(); // relCodeBatch.setErpId();

@ -482,7 +482,7 @@ public class RelCodeBatchService extends ServiceImpl<RelCodeBatchMapper, RelCode
relCodeBatch.setUpdateTime(new Date()); relCodeBatch.setUpdateTime(new Date());
relCodeBatch.setUpdateUser(user.getUserName()); relCodeBatch.setUpdateUser(user.getUserName());
relCodeBatch.setErpId(customerId); relCodeBatch.setErpId(customerId);
relCodeBatch.setUploadFlagDown(1); relCodeBatch.setUploadFlagDown(0);
relCodeBatch.setUploadFlagUp(0); relCodeBatch.setUploadFlagUp(0);
//batch下的节点code //batch下的节点code
@ -604,6 +604,7 @@ public class RelCodeBatchService extends ServiceImpl<RelCodeBatchMapper, RelCode
/** /**
* curCode * curCode
* *
*
* @param item * @param item
*/ */
private void updateDrugLevelCount(RelCodeBatch item) { private void updateDrugLevelCount(RelCodeBatch item) {

@ -306,7 +306,7 @@ public class IoCheckInoutService {
isTrue = true; isTrue = true;
} }
} }
if (isTrue) { if (isTrue && codeLostEntity.getId() != null) {
codeLostEntity.setCreateTime(new Date()); codeLostEntity.setCreateTime(new Date());
codeLostService.insertOrUpdate(codeLostEntity); codeLostService.insertOrUpdate(codeLostEntity);
} }

@ -5,7 +5,10 @@ import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.github.pagehelper.PageHelper; import com.github.pagehelper.PageHelper;
import com.glxp.api.req.inout.IoCodeLostRequest; import com.glxp.api.req.inout.IoCodeLostRequest;
import com.glxp.api.res.collect.RelCodeDetailResponse;
import com.glxp.api.res.inout.IoCodeLostResponse; import com.glxp.api.res.inout.IoCodeLostResponse;
import com.glxp.api.service.collect.RelCodeDetailService;
import com.glxp.api.util.MsDateUtil;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
import javax.annotation.Resource; import javax.annotation.Resource;
@ -38,16 +41,31 @@ public class IoCodeLostServiceImpl extends ServiceImpl<IoCodeLostMapper, IoCodeL
return codeLostEntityMapper.selectLost(ioCodeLostRequest); return codeLostEntityMapper.selectLost(ioCodeLostRequest);
} }
@Resource
RelCodeDetailService relCodeDetailService;
@Override @Override
public IoCodeLostEntity findByCode(String code) { public IoCodeLostEntity findByCode(String code) {
List<IoCodeLostEntity> codeLostEntities = codeLostEntityMapper.selectList(new QueryWrapper<IoCodeLostEntity>().eq("code", code).last("limit 1")); RelCodeDetailResponse codeRelEntity = relCodeDetailService.findByCode(code);
if (codeRelEntity != null) {
IoCodeLostEntity udiEntity = new IoCodeLostEntity();
udiEntity.setBatchNo(codeRelEntity.getBatchNo());
udiEntity.setCode(code);
udiEntity.setProduceDate(MsDateUtil.formatDate(codeRelEntity.getMadeDate(), "yyMMdd"));
udiEntity.setExpireDate(MsDateUtil.formatDate(codeRelEntity.getValidateDate(), "yyMMdd"));
return udiEntity;
}
List<IoCodeLostEntity> codeLostEntities = codeLostEntityMapper.selectList(new QueryWrapper<IoCodeLostEntity>().like("code", code).last("limit 1"));
if (CollUtil.isNotEmpty(codeLostEntities)) { if (CollUtil.isNotEmpty(codeLostEntities)) {
return codeLostEntities.get(0); return codeLostEntities.get(0);
} }
return null; return null;
} }
@Override @Override
public int insert(IoCodeLostEntity ioCodeLostEntity) { public int insert(IoCodeLostEntity ioCodeLostEntity) {

@ -23,6 +23,7 @@
AND code = #{code} AND code = #{code}
</if> </if>
</where> </where>
group by ic.id
order by id desc order by id desc
</select> </select>
</mapper> </mapper>

Loading…
Cancel
Save