demand: 客户账单查询-cpu飙升问题定位解决
committer: heyu
This commit is contained in:
parent
c31f16e48d
commit
3af3a3d37c
@ -157,32 +157,32 @@ public class EmisWaybillServiceImpl extends EmisBaseService implements IEmisWayb
|
||||
* @param emisWaybillSave
|
||||
*/
|
||||
private void saveOrUpdateWaybillOther(EmisWaybill emisWaybillSave) {
|
||||
if (emisWaybillSave == null || emisWaybillSave.getId() == null) {
|
||||
return;
|
||||
}
|
||||
|
||||
String salesSupport = emisWaybillSave.getSalesSupport();
|
||||
String billCode = emisWaybillSave.getBillCode();
|
||||
Long waybillId = emisWaybillSave.getId();
|
||||
|
||||
// 查询是否已存在
|
||||
EmisWaybillOther existing = emisWaybillOtherMapper.selectEmisWaybillOtherByWaybillId(waybillId);
|
||||
|
||||
if (existing != null) {
|
||||
// 更新
|
||||
existing.setSalesSupport(salesSupport);
|
||||
existing.setBillCode(billCode);
|
||||
existing.preUpdate();
|
||||
emisWaybillOtherMapper.updateEmisWaybillOther(existing);
|
||||
} else {
|
||||
// 新增
|
||||
EmisWaybillOther waybillOtherEntity = new EmisWaybillOther();
|
||||
waybillOtherEntity.setWaybillId(waybillId);
|
||||
waybillOtherEntity.setBillCode(billCode);
|
||||
waybillOtherEntity.setSalesSupport(salesSupport);
|
||||
waybillOtherEntity.preInsert();
|
||||
emisWaybillOtherMapper.insertEmisWaybillOther(waybillOtherEntity);
|
||||
}
|
||||
// if (emisWaybillSave == null || emisWaybillSave.getId() == null) {
|
||||
// return;
|
||||
// }
|
||||
//
|
||||
// String salesSupport = emisWaybillSave.getSalesSupport();
|
||||
// String billCode = emisWaybillSave.getBillCode();
|
||||
// Long waybillId = emisWaybillSave.getId();
|
||||
//
|
||||
// // 查询是否已存在
|
||||
// EmisWaybillOther existing = emisWaybillOtherMapper.selectEmisWaybillOtherByWaybillId(waybillId);
|
||||
//
|
||||
// if (existing != null) {
|
||||
// // 更新
|
||||
// existing.setSalesSupport(salesSupport);
|
||||
// existing.setBillCode(billCode);
|
||||
// existing.preUpdate();
|
||||
// emisWaybillOtherMapper.updateEmisWaybillOther(existing);
|
||||
// } else {
|
||||
// // 新增
|
||||
// EmisWaybillOther waybillOtherEntity = new EmisWaybillOther();
|
||||
// waybillOtherEntity.setWaybillId(waybillId);
|
||||
// waybillOtherEntity.setBillCode(billCode);
|
||||
// waybillOtherEntity.setSalesSupport(salesSupport);
|
||||
// waybillOtherEntity.preInsert();
|
||||
// emisWaybillOtherMapper.insertEmisWaybillOther(waybillOtherEntity);
|
||||
// }
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Loading…
Reference in New Issue
Block a user