Commit 25efecb8 authored by 罗林杰's avatar 罗林杰

修改退款

parent d81590bb
...@@ -282,9 +282,13 @@ public class StoreGoodsApplyServiceImpl extends ServiceImpl<StoreGoodsApplyRepos ...@@ -282,9 +282,13 @@ public class StoreGoodsApplyServiceImpl extends ServiceImpl<StoreGoodsApplyRepos
} }
//修改子表状态 //修改子表状态
storeGoodsLogServiceImpl.updateStatus(storeGoodsApply); storeGoodsLogServiceImpl.updateStatus(storeGoodsApply);
} } else if("3".equals(storeGoodsApply.getIsReturn())){
if("3".equals(storeGoodsApply.getIsReturn())){
storeGoodsApply.setIsReturn("2"); storeGoodsApply.setIsReturn("2");
} else if ("1".equals(storeGoodsApply.getIsReturn())){
StoreGoodsApply oldStoreGoodsApply = baseMapper.selectById(storeGoodsApply.getBusinessId());
storeGoodsApply.setTotalOutPrice(
oldStoreGoodsApply.getTotalOutPrice().subtract(storeGoodsApply.getTotalOutPrice())
);
} }
int line = baseMapper.updateById(storeGoodsApply); int line = baseMapper.updateById(storeGoodsApply);
......
...@@ -120,6 +120,7 @@ public class StoreGoodsLogServiceImpl extends ServiceImpl<StoreGoodsLogRepositor ...@@ -120,6 +120,7 @@ public class StoreGoodsLogServiceImpl extends ServiceImpl<StoreGoodsLogRepositor
StoreGoodsApply storeGoodsApply = new StoreGoodsApply(); StoreGoodsApply storeGoodsApply = new StoreGoodsApply();
storeGoodsApply.setBusinessId(oldStoreGoodsLog.getApplyId()); storeGoodsApply.setBusinessId(oldStoreGoodsLog.getApplyId());
storeGoodsApply.setIsReturn(storeGoodsLog.getIsReturn()); storeGoodsApply.setIsReturn(storeGoodsLog.getIsReturn());
storeGoodsApply.setTotalOutPrice(storeGoodsLog.getTotalPrice());
storeGoodsApplyServiceImpl.merge(storeGoodsApply); storeGoodsApplyServiceImpl.merge(storeGoodsApply);
oldStoreGoodsLog.setIsReturn("1"); oldStoreGoodsLog.setIsReturn("1");
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment