|
|
|
@ -239,6 +239,8 @@ public class CashCollectionServiceImpl implements CashCollectionService { |
|
|
|
if (cashRecord.getGoodsName().equals("金币充值")) { |
|
|
|
if (cashRecord.getPermanentGold() == 0 && cashRecord.getFreeGold() == 0) { |
|
|
|
throw new IllegalArgumentException("金币数量不能为空"); |
|
|
|
}if (cashRecord.getPermanentGold() == 0){ |
|
|
|
throw new IllegalArgumentException("永久金币数量不能为空"); |
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
@ -350,7 +352,13 @@ public class CashCollectionServiceImpl implements CashCollectionService { |
|
|
|
|
|
|
|
|
|
|
|
int rows = cashCollectionMapper.complete(cashRecord); |
|
|
|
String goodsName = cashCollectionMapper.selectGoodsNameByCode(cashRecord.getOrderCode()); |
|
|
|
if (goodsName .equals("金币充值")) { |
|
|
|
|
|
|
|
cashRecord.setOrderCode(cashRecord.getOrderCode().replace("XJ_", "XJCZ_")); |
|
|
|
//修改金币订单 |
|
|
|
cashCollectionMapper.updateGoldOrder(cashRecord); |
|
|
|
} |
|
|
|
return rows > 0 ? "编辑成功" : "编辑失败"; |
|
|
|
} |
|
|
|
|
|
|
|
|