Pārlūkot izejas kodu

功能权限模块

DESKTOP-SVI9JE1\muzen 1 gadu atpakaļ
vecāks
revīzija
888df17e4c
1 mainītis faili ar 5 papildinājumiem un 5 dzēšanām
  1. 5 5
      src/views/device/function/index.vue

+ 5 - 5
src/views/device/function/index.vue

@@ -53,7 +53,7 @@
 </template>
 
 <script>
-import { functionList, functionAdd, functionEdit } from "@/api/device/function";
+import { list, create, edit } from "@/api/device/function";
 export default {
   dicts: ["sys_normal_disable"],
   data() {
@@ -96,7 +96,7 @@ export default {
     // 权限列表
     getList() {
       this.loading = true;
-      functionList({ isDelete: 0 }).then((res) => {
+      list({ isDelete: 0 }).then((res) => {
         if (res.code === 0) {
           this.tableData = res.data;
           this.loading = false;
@@ -129,7 +129,7 @@ export default {
         if (valid) {
           if (this.form.id) {
             // 编辑
-            functionEdit(this.form).then((res) => {
+            edit(this.form).then((res) => {
               if (res.code === 0) {
                 this.$message.success("修改成功!");
                 this.dialogVisible = false;
@@ -138,7 +138,7 @@ export default {
             });
           } else {
             // 新增
-            functionAdd(this.form).then((res) => {
+            create(this.form).then((res) => {
               if (res.code === 0) {
                 this.$message.success("创建成功!");
                 this.dialogVisible = false;
@@ -156,7 +156,7 @@ export default {
     getDelete(row) {
       this.form = row;
       this.form.isDelete = 1;
-      functionEdit(this.form).then((res) => {
+      edit(this.form).then((res) => {
         if (res.code === 0) {
           this.$message.success("已删除!");
           this.getList();