diff --git a/src/api/index.js b/src/api/index.js index e5b11052c9eb1333765eb767a7c5677d226f313e..752a13345ff0482410c3a1c8d967e2f1b29f6727 100644 --- a/src/api/index.js +++ b/src/api/index.js @@ -1,4 +1,5 @@ import { request, METHOD } from '@/utils'; +export * from './menu'; export function getUserDetailInfoApi() { return request('/api/v1/detail', METHOD.GET); diff --git a/src/api/menu.js b/src/api/menu.js new file mode 100644 index 0000000000000000000000000000000000000000..2fbd36ca11a954d6eed626faf1aa5f40f270ded2 --- /dev/null +++ b/src/api/menu.js @@ -0,0 +1,13 @@ +import { delReq, getReq, postReq } from '@/utils'; + +export function delMenuApi(id) { + return delReq(`/api/v1/menus/${id}`); +} + +export function getMenuDataApi() { + return getReq('/api/v1/menus'); +} + +export function addMenuApi(data) { + return postReq('/api/v1/menus', data); +} diff --git a/src/components/popconfirm_delete/index.vue b/src/components/popconfirm_delete/index.vue new file mode 100644 index 0000000000000000000000000000000000000000..0704f53f0c1bf0f862be693ce0a241324ced4153 --- /dev/null +++ b/src/components/popconfirm_delete/index.vue @@ -0,0 +1,19 @@ + + + diff --git a/src/components/table/index.vue b/src/components/table/index.vue index c2fca438e877f2b9aa3406f1a34b559fe91cbcc7..13d0db7b14be1950a807ef922a2992c5d19e0686 100644 --- a/src/components/table/index.vue +++ b/src/components/table/index.vue @@ -23,7 +23,7 @@ - + @@ -35,9 +35,23 @@ :visible="addVisible" @close="addDrawerClose" v-if="addBtn" - :maskClosable="addBtn.maskClosable" + :maskClosable="!!addBtn.maskClosable" + :closable="false" + :drawerStyle="drawerStyle" + :bodyStyle="bodyStyle" + :width="addBtn.width" + destroyOnClose > - +
+
+ +
+
+ + + 取消 + 确认 + @@ -45,71 +59,6 @@ diff --git a/src/main.js b/src/main.js index 1f68627dd7264abed6b6c044af4411f20ac19ef7..66f11940e77084417f0a9fbbaf602c4959e0d135 100644 --- a/src/main.js +++ b/src/main.js @@ -34,7 +34,7 @@ const store = new Vuex.Store({ Vue.use(Router); const isAsynRount = store.state.settingModule.asyncRoutes; const options = initRouter(isAsynRount); -const router = new Router(options); +const router = new Router({ mode: 'history', ...options }); //装载vue-i18n控件 如果语言优先级 请直接修改这里localeLang和fallbackLang Vue.use(VueI18n); diff --git a/src/pages/system/view/menu/MenuManagement.vue b/src/pages/system/view/menu/MenuManagement.vue index abef894cb16d424cd43da9c9154a55f107e8a767..ee18afc648b45d6ad5927a8045bc22b6a4aa4176 100644 --- a/src/pages/system/view/menu/MenuManagement.vue +++ b/src/pages/system/view/menu/MenuManagement.vue @@ -1,25 +1,32 @@