| @@ -96,7 +96,7 @@ public class WxPressBatchController extends BaseController { | |||||
| return new ResultData(list); | return new ResultData(list); | ||||
| } | } | ||||
| @ApiOperation("详情接口") | |||||
| @ApiOperation("删除接口") | |||||
| @PostMapping("delete") | @PostMapping("delete") | ||||
| public ResultData delete(@RequestBody WxPressBatch record) { | public ResultData delete(@RequestBody WxPressBatch record) { | ||||
| if (null == record.getId()) { | if (null == record.getId()) { | ||||
| @@ -145,6 +145,21 @@ public class WxPressBatchController extends BaseController { | |||||
| wxPressBatchService.updateStatus(record); | wxPressBatchService.updateStatus(record); | ||||
| return new ResultData(); | return new ResultData(); | ||||
| } | } | ||||
| @ApiOperation("详情接口") | |||||
| @PostMapping("setRules") | |||||
| public ResultData setRules(@RequestBody WxPressBatch record) { | |||||
| if (null == record.getId()) { | |||||
| return new ResultData(Result.ERROR,"参数错误"); | |||||
| } | |||||
| WxPressBatch record1 = wxPressBatchService.getById(record.getId(), getTenantInfo().getTenantId()); | |||||
| record1.setPromoterLimitRule(record.getPromoterLimitRule()); | |||||
| record1.setPromoterAllowCount(record.getPromoterAllowCount()); | |||||
| record1.setBargainerAllowCount(record1.getBargainerAllowCount()); | |||||
| record1.setBargainerAllowSame(record.getBargainerAllowSame()); | |||||
| wxPressBatchService.saveOrUpdate(record1); | |||||
| return new ResultData(); | |||||
| } | |||||