Преглед на файлове

[A端][修复]:更新卡券时不能更改价格

release_toaliyun_real
hupeng преди 8 години
родител
ревизия
21a1ed3e98
променени са 1 файла, в които са добавени 9 реда и са изтрити 0 реда
  1. +9
    -0
      mallinkAdmin/src/main/java/com/iformall/controller/WxCouponController.java

+ 9
- 0
mallinkAdmin/src/main/java/com/iformall/controller/WxCouponController.java Целия файл

@@ -137,6 +137,15 @@ public class WxCouponController extends BaseController {
if (wxCoupon.getId() == null) { if (wxCoupon.getId() == null) {
return new ResultData(ResultData.ERROR, "缺少id"); return new ResultData(ResultData.ERROR, "缺少id");
} }
if (StringUtils.isNotEmpty(wxCoupon.getSalePriceStr())) {
wxCoupon.setSalePrice((int) (Double.parseDouble(wxCoupon.getSalePriceStr()) * 100));
}
if (StringUtils.isNotEmpty(wxCoupon.getUsePriceStr())) {
wxCoupon.setUsePrice((int) (Double.parseDouble(wxCoupon.getUsePriceStr()) * 100));
}
if (StringUtils.isNotEmpty(wxCoupon.getPriceStr())) {
wxCoupon.setPrice((int) (Double.parseDouble(wxCoupon.getPriceStr()) * 100));
}
if (StringUtils.isNotBlank(wxCoupon.getBusiness())) { if (StringUtils.isNotBlank(wxCoupon.getBusiness())) {
String[] arys = wxCoupon.getBusiness().split(","); String[] arys = wxCoupon.getBusiness().split(",");
wxCoupon.setBusiness(JSON.toJSONString(arys)); wxCoupon.setBusiness(JSON.toJSONString(arys));


Зареждане…
Отказ
Запис