9 changed files with 151 additions and 380 deletions
@ -0,0 +1,79 @@ |
|||||
|
package com.epmet.dto; |
||||
|
|
||||
|
import lombok.Data; |
||||
|
|
||||
|
import java.io.Serializable; |
||||
|
|
||||
|
|
||||
|
/** |
||||
|
* |
||||
|
* |
||||
|
* @author generator generator@elink-cn.com |
||||
|
* @since v1.0.0 2022-07-19 |
||||
|
*/ |
||||
|
@Data |
||||
|
public class IcPolicyItemResultDTO implements Serializable { |
||||
|
|
||||
|
private static final long serialVersionUID = 1L; |
||||
|
|
||||
|
/** |
||||
|
* |
||||
|
*/ |
||||
|
private String id; |
||||
|
|
||||
|
/** |
||||
|
* |
||||
|
*/ |
||||
|
private String customerId; |
||||
|
|
||||
|
/** |
||||
|
* house:房屋信息,stat:统计信息 |
||||
|
*/ |
||||
|
private String groupType; |
||||
|
|
||||
|
/** |
||||
|
* 选项名;例如:房屋类型,房屋状态,人均收入 |
||||
|
*/ |
||||
|
private String label; |
||||
|
|
||||
|
/** |
||||
|
* 表名 |
||||
|
*/ |
||||
|
private String tableName; |
||||
|
|
||||
|
/** |
||||
|
* 房屋信息存储列名;统计信息定义好key放在这里 |
||||
|
*/ |
||||
|
private String colKey; |
||||
|
|
||||
|
/** |
||||
|
* |
||||
|
*/ |
||||
|
private String itemType; |
||||
|
|
||||
|
/** |
||||
|
* 排序 |
||||
|
*/ |
||||
|
private Integer sort; |
||||
|
|
||||
|
/** |
||||
|
* 备注 |
||||
|
*/ |
||||
|
private String remark; |
||||
|
|
||||
|
/** |
||||
|
* 值来源;需要接口获取:remote。 |
||||
|
*/ |
||||
|
private String optionSourceType; |
||||
|
|
||||
|
/** |
||||
|
* 动态url; |
||||
|
*/ |
||||
|
private String optionSourceUrl; |
||||
|
|
||||
|
/** |
||||
|
* 动态url的入参;存储json串 |
||||
|
*/ |
||||
|
private String optionSourceParam; |
||||
|
|
||||
|
} |
@ -1,73 +0,0 @@ |
|||||
package com.epmet.controller; |
|
||||
|
|
||||
import com.epmet.commons.tools.aop.NoRepeatSubmit; |
|
||||
import com.epmet.commons.tools.page.PageData; |
|
||||
import com.epmet.commons.tools.utils.ExcelUtils; |
|
||||
import com.epmet.commons.tools.utils.Result; |
|
||||
import com.epmet.commons.tools.validator.AssertUtils; |
|
||||
import com.epmet.commons.tools.validator.ValidatorUtils; |
|
||||
import com.epmet.commons.tools.validator.group.AddGroup; |
|
||||
import com.epmet.commons.tools.validator.group.UpdateGroup; |
|
||||
import com.epmet.commons.tools.validator.group.DefaultGroup; |
|
||||
import com.epmet.dto.IcPolicyCategoryDTO; |
|
||||
import com.epmet.service.IcPolicyCategoryService; |
|
||||
import org.springframework.beans.factory.annotation.Autowired; |
|
||||
import org.springframework.web.bind.annotation.*; |
|
||||
|
|
||||
import javax.servlet.http.HttpServletResponse; |
|
||||
import java.util.List; |
|
||||
import java.util.Map; |
|
||||
|
|
||||
|
|
||||
/** |
|
||||
* 政策匹配资源类型 |
|
||||
* |
|
||||
* @author generator generator@elink-cn.com |
|
||||
* @since v1.0.0 2022-07-18 |
|
||||
*/ |
|
||||
@RestController |
|
||||
@RequestMapping("icPolicyCategory") |
|
||||
public class IcPolicyCategoryController { |
|
||||
|
|
||||
@Autowired |
|
||||
private IcPolicyCategoryService icPolicyCategoryService; |
|
||||
|
|
||||
@RequestMapping("page") |
|
||||
public Result<PageData<IcPolicyCategoryDTO>> page(@RequestParam Map<String, Object> params){ |
|
||||
PageData<IcPolicyCategoryDTO> page = icPolicyCategoryService.page(params); |
|
||||
return new Result<PageData<IcPolicyCategoryDTO>>().ok(page); |
|
||||
} |
|
||||
|
|
||||
@RequestMapping(value = "{id}",method = {RequestMethod.POST,RequestMethod.GET}) |
|
||||
public Result<IcPolicyCategoryDTO> get(@PathVariable("id") String id){ |
|
||||
IcPolicyCategoryDTO data = icPolicyCategoryService.get(id); |
|
||||
return new Result<IcPolicyCategoryDTO>().ok(data); |
|
||||
} |
|
||||
|
|
||||
@NoRepeatSubmit |
|
||||
@PostMapping("save") |
|
||||
public Result save(@RequestBody IcPolicyCategoryDTO dto){ |
|
||||
//效验数据
|
|
||||
ValidatorUtils.validateEntity(dto, AddGroup.class, DefaultGroup.class); |
|
||||
icPolicyCategoryService.save(dto); |
|
||||
return new Result(); |
|
||||
} |
|
||||
|
|
||||
@NoRepeatSubmit |
|
||||
@PostMapping("update") |
|
||||
public Result update(@RequestBody IcPolicyCategoryDTO dto){ |
|
||||
//效验数据
|
|
||||
ValidatorUtils.validateEntity(dto, UpdateGroup.class, DefaultGroup.class); |
|
||||
icPolicyCategoryService.update(dto); |
|
||||
return new Result(); |
|
||||
} |
|
||||
|
|
||||
@PostMapping("delete") |
|
||||
public Result delete(@RequestBody String[] ids){ |
|
||||
//效验数据
|
|
||||
AssertUtils.isArrayEmpty(ids, "id"); |
|
||||
icPolicyCategoryService.delete(ids); |
|
||||
return new Result(); |
|
||||
} |
|
||||
|
|
||||
} |
|
@ -1,70 +0,0 @@ |
|||||
package com.epmet.controller; |
|
||||
|
|
||||
import com.epmet.commons.tools.aop.NoRepeatSubmit; |
|
||||
import com.epmet.commons.tools.page.PageData; |
|
||||
import com.epmet.commons.tools.utils.Result; |
|
||||
import com.epmet.commons.tools.validator.AssertUtils; |
|
||||
import com.epmet.commons.tools.validator.ValidatorUtils; |
|
||||
import com.epmet.commons.tools.validator.group.AddGroup; |
|
||||
import com.epmet.commons.tools.validator.group.DefaultGroup; |
|
||||
import com.epmet.commons.tools.validator.group.UpdateGroup; |
|
||||
import com.epmet.dto.IcPolicyRuleDTO; |
|
||||
import com.epmet.service.IcPolicyRuleService; |
|
||||
import org.springframework.beans.factory.annotation.Autowired; |
|
||||
import org.springframework.web.bind.annotation.*; |
|
||||
|
|
||||
import java.util.Map; |
|
||||
|
|
||||
|
|
||||
/** |
|
||||
* 政策匹配规则 |
|
||||
* |
|
||||
* @author generator generator@elink-cn.com |
|
||||
* @since v1.0.0 2022-07-18 |
|
||||
*/ |
|
||||
@RestController |
|
||||
@RequestMapping("icPolicyRule") |
|
||||
public class IcPolicyRuleController { |
|
||||
|
|
||||
@Autowired |
|
||||
private IcPolicyRuleService icPolicyRuleService; |
|
||||
|
|
||||
@RequestMapping("page") |
|
||||
public Result<PageData<IcPolicyRuleDTO>> page(@RequestParam Map<String, Object> params){ |
|
||||
PageData<IcPolicyRuleDTO> page = icPolicyRuleService.page(params); |
|
||||
return new Result<PageData<IcPolicyRuleDTO>>().ok(page); |
|
||||
} |
|
||||
|
|
||||
@RequestMapping(value = "{id}",method = {RequestMethod.POST,RequestMethod.GET}) |
|
||||
public Result<IcPolicyRuleDTO> get(@PathVariable("id") String id){ |
|
||||
IcPolicyRuleDTO data = icPolicyRuleService.get(id); |
|
||||
return new Result<IcPolicyRuleDTO>().ok(data); |
|
||||
} |
|
||||
|
|
||||
@NoRepeatSubmit |
|
||||
@PostMapping("save") |
|
||||
public Result save(@RequestBody IcPolicyRuleDTO dto){ |
|
||||
//效验数据
|
|
||||
ValidatorUtils.validateEntity(dto, AddGroup.class, DefaultGroup.class); |
|
||||
icPolicyRuleService.save(dto); |
|
||||
return new Result(); |
|
||||
} |
|
||||
|
|
||||
@NoRepeatSubmit |
|
||||
@PostMapping("update") |
|
||||
public Result update(@RequestBody IcPolicyRuleDTO dto){ |
|
||||
//效验数据
|
|
||||
ValidatorUtils.validateEntity(dto, UpdateGroup.class, DefaultGroup.class); |
|
||||
icPolicyRuleService.update(dto); |
|
||||
return new Result(); |
|
||||
} |
|
||||
|
|
||||
@PostMapping("delete") |
|
||||
public Result delete(@RequestBody String[] ids){ |
|
||||
//效验数据
|
|
||||
AssertUtils.isArrayEmpty(ids, "id"); |
|
||||
icPolicyRuleService.delete(ids); |
|
||||
return new Result(); |
|
||||
} |
|
||||
|
|
||||
} |
|
@ -1,70 +0,0 @@ |
|||||
package com.epmet.controller; |
|
||||
|
|
||||
import com.epmet.commons.tools.aop.NoRepeatSubmit; |
|
||||
import com.epmet.commons.tools.page.PageData; |
|
||||
import com.epmet.commons.tools.utils.Result; |
|
||||
import com.epmet.commons.tools.validator.AssertUtils; |
|
||||
import com.epmet.commons.tools.validator.ValidatorUtils; |
|
||||
import com.epmet.commons.tools.validator.group.AddGroup; |
|
||||
import com.epmet.commons.tools.validator.group.UpdateGroup; |
|
||||
import com.epmet.commons.tools.validator.group.DefaultGroup; |
|
||||
import com.epmet.dto.IcPolicyRuleDetailDTO; |
|
||||
import com.epmet.service.IcPolicyRuleDetailService; |
|
||||
import org.springframework.beans.factory.annotation.Autowired; |
|
||||
import org.springframework.web.bind.annotation.*; |
|
||||
|
|
||||
import java.util.Map; |
|
||||
|
|
||||
|
|
||||
/** |
|
||||
* 政策匹配规则明细 |
|
||||
* |
|
||||
* @author generator generator@elink-cn.com |
|
||||
* @since v1.0.0 2022-07-18 |
|
||||
*/ |
|
||||
@RestController |
|
||||
@RequestMapping("icPolicyRuleDetail") |
|
||||
public class IcPolicyRuleDetailController { |
|
||||
|
|
||||
@Autowired |
|
||||
private IcPolicyRuleDetailService icPolicyRuleDetailService; |
|
||||
|
|
||||
@RequestMapping("page") |
|
||||
public Result<PageData<IcPolicyRuleDetailDTO>> page(@RequestParam Map<String, Object> params){ |
|
||||
PageData<IcPolicyRuleDetailDTO> page = icPolicyRuleDetailService.page(params); |
|
||||
return new Result<PageData<IcPolicyRuleDetailDTO>>().ok(page); |
|
||||
} |
|
||||
|
|
||||
@RequestMapping(value = "{id}",method = {RequestMethod.POST,RequestMethod.GET}) |
|
||||
public Result<IcPolicyRuleDetailDTO> get(@PathVariable("id") String id){ |
|
||||
IcPolicyRuleDetailDTO data = icPolicyRuleDetailService.get(id); |
|
||||
return new Result<IcPolicyRuleDetailDTO>().ok(data); |
|
||||
} |
|
||||
|
|
||||
@NoRepeatSubmit |
|
||||
@PostMapping("save") |
|
||||
public Result save(@RequestBody IcPolicyRuleDetailDTO dto){ |
|
||||
//效验数据
|
|
||||
ValidatorUtils.validateEntity(dto, AddGroup.class, DefaultGroup.class); |
|
||||
icPolicyRuleDetailService.save(dto); |
|
||||
return new Result(); |
|
||||
} |
|
||||
|
|
||||
@NoRepeatSubmit |
|
||||
@PostMapping("update") |
|
||||
public Result update(@RequestBody IcPolicyRuleDetailDTO dto){ |
|
||||
//效验数据
|
|
||||
ValidatorUtils.validateEntity(dto, UpdateGroup.class, DefaultGroup.class); |
|
||||
icPolicyRuleDetailService.update(dto); |
|
||||
return new Result(); |
|
||||
} |
|
||||
|
|
||||
@PostMapping("delete") |
|
||||
public Result delete(@RequestBody String[] ids){ |
|
||||
//效验数据
|
|
||||
AssertUtils.isArrayEmpty(ids, "id"); |
|
||||
icPolicyRuleDetailService.delete(ids); |
|
||||
return new Result(); |
|
||||
} |
|
||||
|
|
||||
} |
|
Loading…
Reference in new issue