Browse Source

20250427 优化删除

贾小兵 1 month ago
parent
commit
457465cc70

+ 17 - 16
public/assets/js/backend/department/admin.js

@@ -142,22 +142,23 @@ define(['jquery', 'bootstrap', 'backend', 'table', 'form'], function ($, undefin
                             title: '编辑',
                             classname: 'btn btn-success btn-xs btn-magic btn-dialog',
                             url: 'department/admin/edit',
-                        },{
-                            name: 'dispatch',
-                            text: '删除',
-                            icon: 'fa fa-trash',
-                            title: '删除',
-                            classname: 'btn btn-danger btn-xs btn-magic btn-ajax',
-                            url: 'department/admin/del',
-                            confirm: '确定要删除吗?',
-                            success: function (data, ret) {
-                                $(".btn-refresh").trigger("click");
-                            },
-                            error: function (data, ret) {
-                                Layer.alert(ret.msg);
-                                return false;
-                            }
-                        }
+                        },
+                        // {
+                        //     name: 'dispatch',
+                        //     text: '删除',
+                        //     icon: 'fa fa-trash',
+                        //     title: '删除',
+                        //     classname: 'btn btn-danger btn-xs btn-magic btn-ajax',
+                        //     url: 'department/admin/del',
+                        //     confirm: '确定要删除吗?',
+                        //     success: function (data, ret) {
+                        //         $(".btn-refresh").trigger("click");
+                        //     },
+                        //     error: function (data, ret) {
+                        //         Layer.alert(ret.msg);
+                        //         return false;
+                        //     }
+                        // }
                     ],
                     // formatter: function (value, row, index) {
                     //     return Table.api.formatter.operate.call(this, value, row, index);

+ 17 - 16
public/assets/js/backend/department/index.js

@@ -105,22 +105,23 @@ define(['jquery', 'bootstrap', 'backend', 'table', 'form'], function ($, undefin
                                     title: '编辑',
                                     classname: 'btn btn-success btn-xs btn-magic btn-dialog',
                                     url: 'department/index/edit',
-                                },{
-                                    name: 'dispatch',
-                                    text: '删除',
-                                    icon: 'fa fa-trash',
-                                    title: '删除',
-                                    classname: 'btn btn-danger btn-xs btn-magic btn-ajax',
-                                    url: 'department/index/del',
-                                    confirm: '确定要删除吗?',
-                                    success: function (data, ret) {
-                                        $(".btn-refresh").trigger("click");
-                                    },
-                                    error: function (data, ret) {
-                                        Layer.alert(ret.msg);
-                                        return false;
-                                    }
-                                }
+                                },
+                                // {
+                                //     name: 'dispatch',
+                                //     text: '删除',
+                                //     icon: 'fa fa-trash',
+                                //     title: '删除',
+                                //     classname: 'btn btn-danger btn-xs btn-magic btn-ajax',
+                                //     url: 'department/index/del',
+                                //     confirm: '确定要删除吗?',
+                                //     success: function (data, ret) {
+                                //         $(".btn-refresh").trigger("click");
+                                //     },
+                                //     error: function (data, ret) {
+                                //         Layer.alert(ret.msg);
+                                //         return false;
+                                //     }
+                                // }
                                 // {
                                 //     name: 'index',
                                 //     text: __('Employee'),