Browse Source

上述接口 入口新增

王苗苗 15 giờ trước cách đây
mục cha
commit
8184ae8da4

+ 104 - 0
slibra-admin/src/main/java/com/slibra/web/controller/business/AutoFeedbackController.java

@@ -0,0 +1,104 @@
+package com.slibra.web.controller.business;
+
+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;
+import org.springframework.web.bind.annotation.PostMapping;
+import org.springframework.web.bind.annotation.PutMapping;
+import org.springframework.web.bind.annotation.DeleteMapping;
+import org.springframework.web.bind.annotation.PathVariable;
+import org.springframework.web.bind.annotation.RequestBody;
+import org.springframework.web.bind.annotation.RequestMapping;
+import org.springframework.web.bind.annotation.RestController;
+import com.slibra.common.annotation.Log;
+import com.slibra.common.core.controller.BaseController;
+import com.slibra.common.core.domain.AjaxResult;
+import com.slibra.common.enums.BusinessType;
+import com.slibra.business.domain.AutoFeedback;
+import com.slibra.business.service.IAutoFeedbackService;
+import com.slibra.common.utils.poi.ExcelUtil;
+import com.slibra.common.core.page.TableDataInfo;
+
+/**
+ * 【请填写功能名称】Controller
+ * 
+ * @author slibra
+ * @date 2025-05-09
+ */
+@RestController
+@RequestMapping("/business/feedback")
+public class AutoFeedbackController extends BaseController
+{
+    @Autowired
+    private IAutoFeedbackService autoFeedbackService;
+
+    /**
+     * 查询【请填写功能名称】列表
+     */
+    @PreAuthorize("@ss.hasPermi('business:feedback:list')")
+    @GetMapping("/list")
+    public TableDataInfo list(AutoFeedback autoFeedback)
+    {
+        startPage();
+        List<AutoFeedback> list = autoFeedbackService.selectAutoFeedbackList(autoFeedback);
+        return getDataTable(list);
+    }
+
+    /**
+     * 导出【请填写功能名称】列表
+     */
+    @PreAuthorize("@ss.hasPermi('business:feedback:export')")
+    @Log(title = "【请填写功能名称】", businessType = BusinessType.EXPORT)
+    @PostMapping("/export")
+    public void export(HttpServletResponse response, AutoFeedback autoFeedback)
+    {
+        List<AutoFeedback> list = autoFeedbackService.selectAutoFeedbackList(autoFeedback);
+        ExcelUtil<AutoFeedback> util = new ExcelUtil<AutoFeedback>(AutoFeedback.class);
+        util.exportExcel(response, list, "【请填写功能名称】数据");
+    }
+
+    /**
+     * 获取【请填写功能名称】详细信息
+     */
+    @PreAuthorize("@ss.hasPermi('business:feedback:query')")
+    @GetMapping(value = "/{id}")
+    public AjaxResult getInfo(@PathVariable("id") Long id)
+    {
+        return success(autoFeedbackService.selectAutoFeedbackById(id));
+    }
+
+    /**
+     * 新增【请填写功能名称】
+     */
+    @PreAuthorize("@ss.hasPermi('business:feedback:add')")
+    @Log(title = "【请填写功能名称】", businessType = BusinessType.INSERT)
+    @PostMapping
+    public AjaxResult add(@RequestBody AutoFeedback autoFeedback)
+    {
+        return toAjax(autoFeedbackService.insertAutoFeedback(autoFeedback));
+    }
+
+    /**
+     * 修改【请填写功能名称】
+     */
+    @PreAuthorize("@ss.hasPermi('business:feedback:edit')")
+    @Log(title = "【请填写功能名称】", businessType = BusinessType.UPDATE)
+    @PutMapping
+    public AjaxResult edit(@RequestBody AutoFeedback autoFeedback)
+    {
+        return toAjax(autoFeedbackService.updateAutoFeedback(autoFeedback));
+    }
+
+    /**
+     * 删除【请填写功能名称】
+     */
+    @PreAuthorize("@ss.hasPermi('business:feedback:remove')")
+    @Log(title = "【请填写功能名称】", businessType = BusinessType.DELETE)
+	@DeleteMapping("/{ids}")
+    public AjaxResult remove(@PathVariable Long[] ids)
+    {
+        return toAjax(autoFeedbackService.deleteAutoFeedbackByIds(ids));
+    }
+}

+ 61 - 0
slibra-system/src/main/java/com/slibra/business/service/IAutoFeedbackService.java

@@ -0,0 +1,61 @@
+package com.slibra.business.service;
+
+import java.util.List;
+import com.slibra.business.domain.AutoFeedback;
+
+/**
+ * 【请填写功能名称】Service接口
+ * 
+ * @author slibra
+ * @date 2025-05-09
+ */
+public interface IAutoFeedbackService 
+{
+    /**
+     * 查询【请填写功能名称】
+     * 
+     * @param id 【请填写功能名称】主键
+     * @return 【请填写功能名称】
+     */
+    public AutoFeedback selectAutoFeedbackById(Long id);
+
+    /**
+     * 查询【请填写功能名称】列表
+     * 
+     * @param autoFeedback 【请填写功能名称】
+     * @return 【请填写功能名称】集合
+     */
+    public List<AutoFeedback> selectAutoFeedbackList(AutoFeedback autoFeedback);
+
+    /**
+     * 新增【请填写功能名称】
+     * 
+     * @param autoFeedback 【请填写功能名称】
+     * @return 结果
+     */
+    public int insertAutoFeedback(AutoFeedback autoFeedback);
+
+    /**
+     * 修改【请填写功能名称】
+     * 
+     * @param autoFeedback 【请填写功能名称】
+     * @return 结果
+     */
+    public int updateAutoFeedback(AutoFeedback autoFeedback);
+
+    /**
+     * 批量删除【请填写功能名称】
+     * 
+     * @param ids 需要删除的【请填写功能名称】主键集合
+     * @return 结果
+     */
+    public int deleteAutoFeedbackByIds(Long[] ids);
+
+    /**
+     * 删除【请填写功能名称】信息
+     * 
+     * @param id 【请填写功能名称】主键
+     * @return 结果
+     */
+    public int deleteAutoFeedbackById(Long id);
+}

+ 94 - 0
slibra-system/src/main/java/com/slibra/business/service/impl/AutoFeedbackServiceImpl.java

@@ -0,0 +1,94 @@
+package com.slibra.business.service.impl;
+
+import java.util.List;
+import com.slibra.common.utils.DateUtils;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+import com.slibra.business.mapper.AutoFeedbackMapper;
+import com.slibra.business.domain.AutoFeedback;
+import com.slibra.business.service.IAutoFeedbackService;
+
+/**
+ * 【请填写功能名称】Service业务层处理
+ * 
+ * @author slibra
+ * @date 2025-05-09
+ */
+@Service
+public class AutoFeedbackServiceImpl implements IAutoFeedbackService 
+{
+    @Autowired
+    private AutoFeedbackMapper autoFeedbackMapper;
+
+    /**
+     * 查询【请填写功能名称】
+     * 
+     * @param id 【请填写功能名称】主键
+     * @return 【请填写功能名称】
+     */
+    @Override
+    public AutoFeedback selectAutoFeedbackById(Long id)
+    {
+        return autoFeedbackMapper.selectAutoFeedbackById(id);
+    }
+
+    /**
+     * 查询【请填写功能名称】列表
+     * 
+     * @param autoFeedback 【请填写功能名称】
+     * @return 【请填写功能名称】
+     */
+    @Override
+    public List<AutoFeedback> selectAutoFeedbackList(AutoFeedback autoFeedback)
+    {
+        return autoFeedbackMapper.selectAutoFeedbackList(autoFeedback);
+    }
+
+    /**
+     * 新增【请填写功能名称】
+     * 
+     * @param autoFeedback 【请填写功能名称】
+     * @return 结果
+     */
+    @Override
+    public int insertAutoFeedback(AutoFeedback autoFeedback)
+    {
+        return autoFeedbackMapper.insertAutoFeedback(autoFeedback);
+    }
+
+    /**
+     * 修改【请填写功能名称】
+     * 
+     * @param autoFeedback 【请填写功能名称】
+     * @return 结果
+     */
+    @Override
+    public int updateAutoFeedback(AutoFeedback autoFeedback)
+    {
+        return autoFeedbackMapper.updateAutoFeedback(autoFeedback);
+    }
+
+    /**
+     * 批量删除【请填写功能名称】
+     * 
+     * @param ids 需要删除的【请填写功能名称】主键
+     * @return 结果
+     */
+    @Override
+    public int deleteAutoFeedbackByIds(Long[] ids)
+    {
+        return autoFeedbackMapper.deleteAutoFeedbackByIds(ids);
+    }
+
+    /**
+     * 删除【请填写功能名称】信息
+     * 
+     * @param id 【请填写功能名称】主键
+     * @return 结果
+     */
+    @Override
+    public int deleteAutoFeedbackById(Long id)
+    {
+        return autoFeedbackMapper.deleteAutoFeedbackById(id);
+    }
+}