| | |
| | | |
| | | import java.util.List; |
| | | import javax.servlet.http.HttpServletResponse; |
| | | |
| | | import com.ruoyi.common.annotation.AddOrgId; |
| | | import org.springframework.security.access.prepost.PreAuthorize; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.web.bind.annotation.GetMapping; |
| | |
| | | |
| | | /** |
| | | * AI外呼意图Controller |
| | | * |
| | | * |
| | | * @author smartor |
| | | * @date 2023-03-06 |
| | | */ |
| | | @RestController |
| | | @RequestMapping("/smartor/ivrintent") |
| | | public class IvrSceneIntentController extends BaseController |
| | | { |
| | | public class IvrSceneIntentController extends BaseController { |
| | | @Autowired |
| | | private IIvrSceneIntentService ivrSceneIntentService; |
| | | |
| | |
| | | * 查询AI外呼意图列表 |
| | | */ |
| | | //@PreAuthorize("@ss.hasPermi('smartor:ivrintent:list')") |
| | | @PostMapping("/list") |
| | | public TableDataInfo list(@RequestBody IvrSceneIntent ivrSceneIntent) |
| | | { |
| | | @AddOrgId(field = "orgid", paramIndex = 0, campusField = "campusid") |
| | | @PostMapping("list") |
| | | public TableDataInfo list(@RequestBody IvrSceneIntent ivrSceneIntent) { |
| | | startPage(); |
| | | List<IvrSceneIntent> list = ivrSceneIntentService.selectIvrSceneIntentList(ivrSceneIntent); |
| | | return getDataTable(list); |
| | |
| | | //@PreAuthorize("@ss.hasPermi('smartor:ivrintent:export')") |
| | | @Log(title = "AI外呼意图", businessType = BusinessType.EXPORT) |
| | | @PostMapping("/export") |
| | | public void export(HttpServletResponse response, IvrSceneIntent ivrSceneIntent) |
| | | { |
| | | public void export(HttpServletResponse response, IvrSceneIntent ivrSceneIntent) { |
| | | List<IvrSceneIntent> list = ivrSceneIntentService.selectIvrSceneIntentList(ivrSceneIntent); |
| | | ExcelUtil<IvrSceneIntent> util = new ExcelUtil<IvrSceneIntent>(IvrSceneIntent.class); |
| | | util.exportExcel(response, list, "AI外呼意图数据"); |
| | |
| | | */ |
| | | //@PreAuthorize("@ss.hasPermi('smartor:ivrintent:query')") |
| | | @GetMapping(value = "/{sceneintentid}") |
| | | public AjaxResult getInfo(@PathVariable("sceneintentid") Long sceneintentid) |
| | | { |
| | | public AjaxResult getInfo(@PathVariable("sceneintentid") Long sceneintentid) { |
| | | return success(ivrSceneIntentService.selectIvrSceneIntentBySceneintentid(sceneintentid)); |
| | | } |
| | | |
| | |
| | | */ |
| | | //@PreAuthorize("@ss.hasPermi('smartor:ivrintent:add')") |
| | | @Log(title = "AI外呼意图", businessType = BusinessType.INSERT) |
| | | @AddOrgId(field = "orgid", paramIndex = 0, campusField = "campusid") |
| | | @PostMapping("/add") |
| | | public AjaxResult add(@RequestBody IvrSceneIntent ivrSceneIntent) |
| | | { |
| | | public AjaxResult add(@RequestBody IvrSceneIntent ivrSceneIntent) { |
| | | return toAjax(ivrSceneIntentService.insertIvrSceneIntent(ivrSceneIntent)); |
| | | } |
| | | |
| | |
| | | */ |
| | | //@PreAuthorize("@ss.hasPermi('smartor:ivrintent:edit')") |
| | | @Log(title = "AI外呼意图", businessType = BusinessType.UPDATE) |
| | | @AddOrgId(field = "orgid", paramIndex = 0, campusField = "campusid") |
| | | @PostMapping("/edit") |
| | | public AjaxResult edit(@RequestBody IvrSceneIntent ivrSceneIntent) |
| | | { |
| | | public AjaxResult edit(@RequestBody IvrSceneIntent ivrSceneIntent) { |
| | | return toAjax(ivrSceneIntentService.updateIvrSceneIntent(ivrSceneIntent)); |
| | | } |
| | | |
| | |
| | | */ |
| | | //@PreAuthorize("@ss.hasPermi('smartor:ivrintent:remove')") |
| | | @Log(title = "AI外呼意图", businessType = BusinessType.DELETE) |
| | | @GetMapping("/remove/{sceneintentids}") |
| | | public AjaxResult remove(@PathVariable Long[] sceneintentids) |
| | | { |
| | | @GetMapping("/remove/{sceneintentids}") |
| | | public AjaxResult remove(@PathVariable Long[] sceneintentids) { |
| | | return toAjax(ivrSceneIntentService.deleteIvrSceneIntentBySceneintentids(sceneintentids)); |
| | | } |
| | | } |