liusheng
2024-01-30 7ae67ba965ea680407ae21fedbd035d43ce8c313
ruoyi-admin/src/main/java/com/ruoyi/web/controller/smartor/IvrScenecategoryController.java
@@ -1,7 +1,8 @@
package com.smartor.controller;
package com.ruoyi.web.controller.smartor;
import java.util.List;
import javax.servlet.http.HttpServletResponse;
import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
@@ -23,14 +24,13 @@
/**
 * AI服务场景管理分类Controller
 *
 *
 * @author smartor
 * @date 2023-03-06
 */
@RestController
@RequestMapping("/smartor/ivrscenecategory")
public class IvrScenecategoryController extends BaseController
{
public class IvrScenecategoryController extends BaseController {
    @Autowired
    private IIvrScenecategoryService ivrScenecategoryService;
@@ -38,9 +38,8 @@
     * 查询AI服务场景管理分类列表
     */
    @PreAuthorize("@ss.hasPermi('smartor:ivrscenecategory:list')")
    @GetMapping("/list")
    public TableDataInfo list(IvrScenecategory ivrScenecategory)
    {
    @PostMapping("/list")
    public TableDataInfo list(@RequestBody IvrScenecategory ivrScenecategory) {
        startPage();
        List<IvrScenecategory> list = ivrScenecategoryService.selectIvrScenecategoryList(ivrScenecategory);
        return getDataTable(list);
@@ -52,8 +51,7 @@
    @PreAuthorize("@ss.hasPermi('smartor:ivrscenecategory:export')")
    @Log(title = "AI服务场景管理分类", businessType = BusinessType.EXPORT)
    @PostMapping("/export")
    public void export(HttpServletResponse response, IvrScenecategory ivrScenecategory)
    {
    public void export(HttpServletResponse response, IvrScenecategory ivrScenecategory) {
        List<IvrScenecategory> list = ivrScenecategoryService.selectIvrScenecategoryList(ivrScenecategory);
        ExcelUtil<IvrScenecategory> util = new ExcelUtil<IvrScenecategory>(IvrScenecategory.class);
        util.exportExcel(response, list, "AI服务场景管理分类数据");
@@ -64,8 +62,7 @@
     */
    @PreAuthorize("@ss.hasPermi('smartor:ivrscenecategory:query')")
    @GetMapping(value = "/{scenecatid}")
    public AjaxResult getInfo(@PathVariable("scenecatid") Long scenecatid)
    {
    public AjaxResult getInfo(@PathVariable("scenecatid") Long scenecatid) {
        return success(ivrScenecategoryService.selectIvrScenecategoryByScenecatid(scenecatid));
    }
@@ -74,9 +71,8 @@
     */
    @PreAuthorize("@ss.hasPermi('smartor:ivrscenecategory:add')")
    @Log(title = "AI服务场景管理分类", businessType = BusinessType.INSERT)
    @PostMapping
    public AjaxResult add(@RequestBody IvrScenecategory ivrScenecategory)
    {
    @PostMapping("/add")
    public AjaxResult add(@RequestBody IvrScenecategory ivrScenecategory) {
        return toAjax(ivrScenecategoryService.insertIvrScenecategory(ivrScenecategory));
    }
@@ -85,9 +81,8 @@
     */
    @PreAuthorize("@ss.hasPermi('smartor:ivrscenecategory:edit')")
    @Log(title = "AI服务场景管理分类", businessType = BusinessType.UPDATE)
    @PutMapping
    public AjaxResult edit(@RequestBody IvrScenecategory ivrScenecategory)
    {
    @PostMapping("/edit")
    public AjaxResult edit(@RequestBody IvrScenecategory ivrScenecategory) {
        return toAjax(ivrScenecategoryService.updateIvrScenecategory(ivrScenecategory));
    }
@@ -96,9 +91,8 @@
     */
    @PreAuthorize("@ss.hasPermi('smartor:ivrscenecategory:remove')")
    @Log(title = "AI服务场景管理分类", businessType = BusinessType.DELETE)
   @DeleteMapping("/{scenecatids}")
    public AjaxResult remove(@PathVariable Long[] scenecatids)
    {
    @GetMapping("/remove/{scenecatids}")
    public AjaxResult remove(@PathVariable Long[] scenecatids) {
        return toAjax(ivrScenecategoryService.deleteIvrScenecategoryByScenecatids(scenecatids));
    }
}