diff --git a/dl_admin/ruoyi-admin/src/main/java/com/ruoyi/busi/controller/BusiCategoryController.java b/dl_admin/ruoyi-admin/src/main/java/com/ruoyi/busi/controller/BusiCategoryController.java index afba367..4e56316 100644 --- a/dl_admin/ruoyi-admin/src/main/java/com/ruoyi/busi/controller/BusiCategoryController.java +++ b/dl_admin/ruoyi-admin/src/main/java/com/ruoyi/busi/controller/BusiCategoryController.java @@ -56,7 +56,6 @@ public class BusiCategoryController extends BaseController { /** * 获取网站栏目详细信息 */ - @PreAuthorize("@ss.hasPermi('busi:category:query')") @GetMapping(value = "/{id}") public AjaxResult getInfo(@PathVariable("id") String id) { return success(busiCategoryService.getById(id)); @@ -65,7 +64,6 @@ public class BusiCategoryController extends BaseController { /** * 新增网站栏目 */ - @PreAuthorize("@ss.hasPermi('busi:category:add')") @Log(title = "网站栏目", businessType = BusinessType.INSERT) @PostMapping public AjaxResult add(@RequestBody BusiCategory busiCategory) { @@ -75,7 +73,6 @@ public class BusiCategoryController extends BaseController { /** * 修改网站栏目 */ - @PreAuthorize("@ss.hasPermi('busi:category:edit')") @Log(title = "网站栏目", businessType = BusinessType.UPDATE) @PutMapping public AjaxResult edit(@RequestBody BusiCategory busiCategory) { @@ -85,7 +82,6 @@ public class BusiCategoryController extends BaseController { /** * 删除网站栏目 */ - @PreAuthorize("@ss.hasPermi('busi:category:remove')") @Log(title = "网站栏目", businessType = BusinessType.DELETE) @DeleteMapping("/{ids}") public AjaxResult remove(@PathVariable String[] ids) { diff --git a/dl_vue/src/router/index.js b/dl_vue/src/router/index.js index 71907b6..2d998dd 100644 --- a/dl_vue/src/router/index.js +++ b/dl_vue/src/router/index.js @@ -87,6 +87,20 @@ export const constantRoutes = [ meta: { title: '个人中心', icon: 'user' } } ] + }, + { + path: '/category', + component: Layout, + hidden: true, + redirect: 'noredirect', + children: [ + { + path: 'categoryForm', + component: () => import('@/views/busi/category/form/categoryForm'), + name: 'CategoryForm', + meta: { title: '栏目信息' } + } + ] } ] diff --git a/dl_vue/src/views/busi/category/form/categoryForm.vue b/dl_vue/src/views/busi/category/form/categoryForm.vue index bcc8846..c776615 100644 --- a/dl_vue/src/views/busi/category/form/categoryForm.vue +++ b/dl_vue/src/views/busi/category/form/categoryForm.vue @@ -1,60 +1,98 @@ diff --git a/dl_vue/src/views/busi/category/index.vue b/dl_vue/src/views/busi/category/index.vue index 48b7484..9513fe0 100644 --- a/dl_vue/src/views/busi/category/index.vue +++ b/dl_vue/src/views/busi/category/index.vue @@ -14,7 +14,6 @@ 重置 - 新增 - - 修改 - - - 删除 - - - 导出 - - - + + + - + @@ -103,6 +70,8 @@ import { listCategory,delCategory} from "@/api/busi/category"; export default { name: "Category", + components:{}, + dicts: ['category_type'], data() { return { // 遮罩层 @@ -130,15 +99,10 @@ export default { this.loading = true; listCategory(this.queryParams).then(response => { console.log(response) - // this.categoryList = response.data.records; + this.categoryList = response.data; this.loading = false; }); }, - // 取消按钮 - cancel() { - this.open = false; - this.reset(); - }, /** 搜索按钮操作 */ handleQuery() { @@ -149,10 +113,9 @@ export default { this.resetForm("queryForm"); this.handleQuery(); }, - /** 新增按钮操作 */ handleAdd() { - + this.$router.push({path:'/category/categoryForm'}) }, /** 修改按钮操作 */ handleUpdate(row) { @@ -162,7 +125,7 @@ export default { /** 删除按钮操作 */ handleDelete(row) { const ids = row.id || this.ids; - this.$modal.confirm('是否确认删除网站栏目编号为"' + ids + '"的数据项?').then(function() { + this.$modal.confirm('是否确认删除网站栏目"' + row.catgName + '"?').then(function() { return delCategory(ids); }).then(() => { this.getList();