| | |
| | | import com.ruoyi.common.enums.BusinessType; |
| | | import com.ruoyi.common.utils.PageUtils; |
| | | import com.ruoyi.common.utils.poi.ExcelUtil; |
| | | import com.smartor.domain.IvrLibaScriptAssortVO; |
| | | import com.smartor.domain.IvrLibaTargetAssort; |
| | | import com.smartor.domain.IvrLibaTargetAssortVO; |
| | | import com.smartor.service.IIvrLibaTargetAssortService; |
| | |
| | | @Api(description = "指标分类") |
| | | @RestController |
| | | @RequestMapping("/smartor/assort") |
| | | public class IvrLibaTargetAssortController extends BaseController |
| | | { |
| | | public class IvrLibaTargetAssortController extends BaseController { |
| | | @Autowired |
| | | private IIvrLibaTargetAssortService ivrLibaTargetAssortService; |
| | | |
| | |
| | | @ApiOperation("查询指标分类列表") |
| | | @PreAuthorize("@ss.hasPermi('system:assort:list')") |
| | | @PostMapping("/selectIvrLibaTargetAssortList") |
| | | public TableDataInfo list(@RequestBody IvrLibaTargetAssort ivrLibaTargetAssort) |
| | | { |
| | | PageUtils.startPageByPost(ivrLibaTargetAssort.getPageNum(),ivrLibaTargetAssort.getPageSize()); |
| | | public TableDataInfo list(@RequestBody IvrLibaTargetAssort ivrLibaTargetAssort) { |
| | | // PageUtils.startPageByPost(ivrLibaTargetAssort.getPageNum(), ivrLibaTargetAssort.getPageSize()); |
| | | List<IvrLibaTargetAssortVO> ivrLibaTargetAssortVOS = ivrLibaTargetAssortService.selectIvrLibaTargetAssortList(ivrLibaTargetAssort); |
| | | return getDataTable(ivrLibaTargetAssortVOS); |
| | | } |
| | |
| | | @PreAuthorize("@ss.hasPermi('system:assort:export')") |
| | | @Log(title = "指标分类", businessType = BusinessType.EXPORT) |
| | | @PostMapping("/export") |
| | | public void export(HttpServletResponse response, IvrLibaTargetAssort ivrLibaTargetAssort) |
| | | { |
| | | public void export(HttpServletResponse response, IvrLibaTargetAssort ivrLibaTargetAssort) { |
| | | List<IvrLibaTargetAssortVO> list = ivrLibaTargetAssortService.selectIvrLibaTargetAssortList(ivrLibaTargetAssort); |
| | | ExcelUtil<IvrLibaTargetAssortVO> util = new ExcelUtil<IvrLibaTargetAssortVO>(IvrLibaTargetAssortVO.class); |
| | | util.exportExcel(response, list, "指标分类数据"); |
| | |
| | | @ApiOperation("获取指标分类详细信息") |
| | | @PreAuthorize("@ss.hasPermi('system:assort:query')") |
| | | @GetMapping(value = "/getInfo/{id}") |
| | | public AjaxResult getInfo(@PathVariable("id") Long id) |
| | | { |
| | | public AjaxResult getInfo(@PathVariable("id") Long id) { |
| | | return success(ivrLibaTargetAssortService.selectIvrLibaTargetAssortById(id)); |
| | | } |
| | | |
| | |
| | | @PreAuthorize("@ss.hasPermi('system:assort:add')") |
| | | @Log(title = "指标分类", businessType = BusinessType.INSERT) |
| | | @PostMapping("/add") |
| | | public AjaxResult add(@RequestBody IvrLibaTargetAssort ivrLibaTargetAssort) |
| | | { |
| | | public AjaxResult add(@RequestBody IvrLibaTargetAssort ivrLibaTargetAssort) { |
| | | return toAjax(ivrLibaTargetAssortService.insertIvrLibaTargetAssort(ivrLibaTargetAssort)); |
| | | } |
| | | |
| | | /** |
| | | * 新增指标分类树 |
| | | */ |
| | | @PreAuthorize("@ss.hasPermi('system:assort:add')") |
| | | @Log(title = "指标分类", businessType = BusinessType.INSERT) |
| | | @ApiOperation("新增指标分类树") |
| | | @PostMapping("/addtree") |
| | | public AjaxResult addtree(@RequestBody IvrLibaTargetAssortVO ivrLibaTargetAssortVO) { |
| | | return toAjax(ivrLibaTargetAssortService.insertIvrLibaTargetAssortTree(ivrLibaTargetAssortVO)); |
| | | } |
| | | |
| | | /** |
| | |
| | | @PreAuthorize("@ss.hasPermi('system:assort:edit')") |
| | | @Log(title = "指标分类", businessType = BusinessType.UPDATE) |
| | | @PostMapping("/edit") |
| | | public AjaxResult edit(@RequestBody IvrLibaTargetAssort ivrLibaTargetAssort) |
| | | { |
| | | public AjaxResult edit(@RequestBody IvrLibaTargetAssort ivrLibaTargetAssort) { |
| | | return toAjax(ivrLibaTargetAssortService.updateIvrLibaTargetAssort(ivrLibaTargetAssort)); |
| | | } |
| | | |
| | |
| | | @PreAuthorize("@ss.hasPermi('system:assort:remove')") |
| | | @Log(title = "指标分类", businessType = BusinessType.DELETE) |
| | | @GetMapping("/remove/{ids}") |
| | | public AjaxResult remove(@PathVariable Long[] ids) |
| | | { |
| | | public AjaxResult remove(@PathVariable Long[] ids) { |
| | | return toAjax(ivrLibaTargetAssortService.deleteIvrLibaTargetAssortByIds(ids)); |
| | | } |
| | | } |