新增线上客户折扣配置同步到本地

dev
徐杰盟 2023-12-22 10:44:09 +08:00
parent 29a8f59a4c
commit 986df3026b
2 changed files with 12 additions and 2 deletions

View File

@ -3,7 +3,9 @@ package com.cowr.ssjygl.customer.customerdiscount;
import com.cowr.common.Const;
import com.cowr.common.base.BaseService;
import com.cowr.common.view.PageParam;
import com.cowr.common.view.Result;
import com.cowr.model.CustomerDiscount;
import com.cowr.model.Sysuser;
import com.jfinal.kit.StrKit;
import com.jfinal.log.Log;
import com.jfinal.plugin.activerecord.Db;
@ -23,6 +25,14 @@ public class CustomerDiscountService extends BaseService {
private static final Log log = Log.getLog(CustomerDiscountService.class);
public static final CustomerDiscountService me = new CustomerDiscountService();
public Result save(CustomerDiscount model, Sysuser sysuser) {
return super.save(model, sysuser);
}
public Result update(CustomerDiscount model, Sysuser sysuser) {
return super.update(model, sysuser);
}
public Page<Record> findLocal(PageParam pp, String customerId, String customerName, String stm, String etm) {
return find(pp, customerId, customerName, stm, etm);
}

View File

@ -62,7 +62,7 @@ public class CustomerDiscountController extends Controller {
renderJson(Result.failed("当前用户已有折扣正在使用中"));
return;
}
renderJson(CustomerDiscountService.me.save(model));
renderJson(CustomerDiscountService.me.save(model,tokenuser));
}
/**
@ -88,7 +88,7 @@ public class CustomerDiscountController extends Controller {
model.setDel("0");
model.setUpdateUser(tokenuser.getId());
renderJson(CustomerDiscountService.me.update(model));
renderJson(CustomerDiscountService.me.update(model,tokenuser));
}
/**