diff --git a/src/App.vue b/src/App.vue index 1a4c900..96dfa59 100644 --- a/src/App.vue +++ b/src/App.vue @@ -9,6 +9,7 @@ diff --git a/src/api/bms/brand.js b/src/api/bms/brand.js deleted file mode 100644 index 1fa46ec..0000000 --- a/src/api/bms/brand.js +++ /dev/null @@ -1,60 +0,0 @@ -import request from '@/utils/request' -const brandApi = { - add: '/bms/brand/add', - get: '/bms/brand/get', - update: '/bms/brand/update', - del: '/bms/brand/delete', - page: '/bms/brand/page', - list: '/bms/brand/listByCategory', - updateStatus: '/bms/brand/updateStatus' -} - -export function brandAdd (params) { - return request({ - url: brandApi.add, - method: 'post', - data: params - }) -} -export function brandGet (params) { - return request({ - url: brandApi.get, - method: 'post', - data: params - }) -} -export function brandUpdate (params) { - return request({ - url: brandApi.update, - method: 'post', - data: params - }) -} -export function brandDelete (params) { - return request({ - url: brandApi.del, - method: 'post', - data: params - }) -} -export function brandPage (params) { - return request({ - url: brandApi.page, - method: 'post', - data: params - }) -} -export function brandList (params) { - return request({ - url: brandApi.list, - method: 'post', - data: params - }) -} -export function brandUpdateStatus (params) { - return request({ - url: brandApi.updateStatus, - method: 'post', - data: params - }) -} diff --git a/src/api/bms/businessModel.js b/src/api/bms/businessModel.js deleted file mode 100644 index 799152f..0000000 --- a/src/api/bms/businessModel.js +++ /dev/null @@ -1,45 +0,0 @@ -import request from '@/utils/request' -const businessModelApi = { - add: '/bms/businessModel/save', - get: '/bms/businessModel/get', - update: '/bms/businessModel/update', - del: '/bms/businessModel/delete', - page: '/bms/businessModel/page', - list: '/bms/businessModel/list' -} - -export function add (params) { - return request({ - url: businessModelApi.add, - method: 'post', - data: params - }) -} -export function get (params) { - return request({ - url: businessModelApi.get, - method: 'post', - data: params - }) -} -export function update (params) { - return request({ - url: businessModelApi.update, - method: 'post', - data: params - }) -} -export function del (params) { - return request({ - url: businessModelApi.del, - method: 'post', - data: params - }) -} -export function list (params) { - return request({ - url: businessModelApi.list, - method: 'post', - data: params - }) -} diff --git a/src/api/bms/catalog.js b/src/api/bms/catalog.js deleted file mode 100644 index 106712a..0000000 --- a/src/api/bms/catalog.js +++ /dev/null @@ -1,44 +0,0 @@ -import request from '@/utils/request' -const catalogApi = { - add: '/bms/catalog/add', - update: '/bms/catalog/update', - del: '/bms/catalog/delete', - page: '/bms/catalog/page', - get: '/bms/catalog/get' -} - -export function catalogAdd (params) { - return request({ - url: catalogApi.add, - method: 'post', - data: params - }) -} -export function catalogUpdate (params) { - return request({ - url: catalogApi.update, - method: 'post', - data: params - }) -} -export function catalogDel (params) { - return request({ - url: catalogApi.del, - method: 'post', - data: params - }) -} -export function catalogPage (params) { - return request({ - url: catalogApi.page, - method: 'post', - data: params - }) -} -export function catalogGet (params) { - return request({ - url: catalogApi.get, - method: 'post', - data: params - }) -} diff --git a/src/api/bms/category.js b/src/api/bms/category.js deleted file mode 100644 index 817fe3c..0000000 --- a/src/api/bms/category.js +++ /dev/null @@ -1,60 +0,0 @@ -import request from '@/utils/request' - -const api = { - listStoreCategory: '/bms/category/listStoreCategory', - add: '/bms/category/add', - update: '/bms/category/update', - delete: '/bms/category/delete', - page: '/bms/category/pageCategory', - get: '/bms/category/get', - updateStatus: '/bms/category/updateStatus' -} -export function listStoreCategory (params) { - return request({ - url: api.listStoreCategory, - method: 'post', - data: params - }) -} -export function addCategory (params) { - return request({ - url: api.add, - method: 'post', - data: params - }) -} -export function updateCategory (params) { - return request({ - url: api.update, - method: 'post', - data: params - }) -} -export function deleteCategory (params) { - return request({ - url: api.delete, - method: 'post', - data: params - }) -} -export function pageCategory (params) { - return request({ - url: api.page, - method: 'post', - data: params - }) -} -export function getCategory (params) { - return request({ - url: api.get, - method: 'post', - data: params - }) -} -export function updateStatusCategory (params) { - return request({ - url: api.updateStatus, - method: 'post', - data: params - }) -} diff --git a/src/api/bms/corporation.js b/src/api/bms/corporation.js deleted file mode 100644 index 8e7b3df..0000000 --- a/src/api/bms/corporation.js +++ /dev/null @@ -1,60 +0,0 @@ -import request from '@/utils/request' - -const CorporationApi = { - add: '/bms/corporation/add', - get: '/bms/corporation/get', - update: '/bms/corporation/update', - del: '/bms/corporation/delete', - page: '/bms/corporation/page', - list: '/bms/corporation/list', - updateStatus: '/bms/corporation/updateStatus' -} -export function corporationAdd (params) { - return request({ - url: CorporationApi.add, - method: 'post', - data: params - }) -} -export function corporationPage (params) { - return request({ - url: CorporationApi.page, - method: 'post', - data: params - }) -} -export function corporationUpdate (params) { - return request({ - url: CorporationApi.update, - method: 'post', - data: params - }) -} -export function corporationDelete (params) { - return request({ - url: CorporationApi.del, - method: 'post', - data: params - }) -} -export function corporationList (params) { - return request({ - url: CorporationApi.list, - method: 'post', - data: params - }) -} -export function corporationGet (params) { - return request({ - url: CorporationApi.get, - method: 'post', - data: params - }) -} -export function updateStatus (params) { - return request({ - url: CorporationApi.updateStatus, - method: 'post', - data: params - }) -} diff --git a/src/api/bms/deliverMethod.js b/src/api/bms/deliverMethod.js deleted file mode 100644 index 5e24f3d..0000000 --- a/src/api/bms/deliverMethod.js +++ /dev/null @@ -1,11 +0,0 @@ -import request from '@/utils/request' -const deliverMethodApi = { - list: '/bms/deliverMethod/list' -} -export function listDeliverMethod (params) { - return request({ - url: deliverMethodApi.list, - method: 'post', - data: params - }) -} diff --git a/src/api/bms/division.js b/src/api/bms/division.js deleted file mode 100644 index 53ac6e9..0000000 --- a/src/api/bms/division.js +++ /dev/null @@ -1,44 +0,0 @@ -import request from '@/utils/request' - -const divisionApi = { - add: '/bms/division/save', - get: '/bms/division/get', - update: '/bms/division/update', - del: '/bms/division/delete', - listDivision: '/bms/division/listByParentCode' -} -export function divisionAdd (params) { - return request({ - url: divisionApi.add, - method: 'post', - data: params - }) -} -export function divisionGet (params) { - return request({ - url: divisionApi.get, - method: 'post', - data: params - }) -} -export function divisionUpdate (params) { - return request({ - url: divisionApi.update, - method: 'post', - data: params - }) -} -export function divisionDelete (params) { - return request({ - url: divisionApi.del, - method: 'post', - data: params - }) -} -export function listDivision (params) { - return request({ - url: divisionApi.listDivision, - method: 'post', - data: params - }) -} diff --git a/src/api/bms/mall.js b/src/api/bms/mall.js deleted file mode 100644 index 4d7824d..0000000 --- a/src/api/bms/mall.js +++ /dev/null @@ -1,78 +0,0 @@ -import request from '@/utils/request' - -const api = { - add: '/bms/mall/save', - get: '/bms/mall/get', - update: '/bms/mall/update', - del: '/bms/mall/delete', - page: '/bms/mall/page', - list: '/bms/mall/list', - updateStatus: '/bms/mall/updateStatus', - corporationList: '/bms/corporation/list', - listByUserType: '/bms/mall/listByUserType' -} -export function add (params) { - return request({ - url: api.add, - method: 'post', - data: params - }) -} -export function get (params) { - return request({ - url: api.get, - method: 'post', - data: params - }) -} -export function update (params) { - return request({ - url: api.update, - method: 'post', - data: params - }) -} -export function del (params) { - return request({ - url: api.del, - method: 'post', - data: params - }) -} -export function page (params) { - return request({ - url: api.page, - method: 'post', - data: params - }) -} -export function list (params) { - return request({ - url: api.list, - method: 'post', - data: params - }) -} -export function updateStatus (params) { - return request({ - url: api.updateStatus, - method: 'post', - data: params - }) -} - -export function corporationList (params) { - return request({ - url: api.corporationList, - method: 'post', - data: params - }) -} - -export function listByUserType (params) { - return request({ - url: api.listByUserType, - method: 'post', - data: params - }) -} diff --git a/src/api/bms/org.js b/src/api/bms/org.js deleted file mode 100644 index 36ada2f..0000000 --- a/src/api/bms/org.js +++ /dev/null @@ -1,20 +0,0 @@ -import request from '@/utils/request' - -const orgApi = { - orgTreeGet: '/bms/org/getOrgTree', - orgByUserType: '/bms/org/getByUserType' -} -export function orgTreeGet (params) { - return request({ - url: orgApi.orgTreeGet, - method: 'post', - data: params - }) -} -export function orgByUserType (params) { - return request({ - url: orgApi.orgByUserType, - method: 'post', - data: params - }) -} diff --git a/src/api/bms/payMethod.js b/src/api/bms/payMethod.js deleted file mode 100644 index 775a3fd..0000000 --- a/src/api/bms/payMethod.js +++ /dev/null @@ -1,52 +0,0 @@ -import request from '@/utils/request' -const payMethodApi = { - add: '/bms/storePayMethod/add', - get: '/bms/storePayMethod/getById', - update: '/bms/storePayMethod/update', - del: '/bms/storePayMethod/delete', - list: '/bms/storePayMethod/list', - page: '/bms/storePayMethod/page' -} - -export function storePayMethodAdd (params) { - return request({ - url: payMethodApi.add, - method: 'post', - data: params - }) -} -export function storePayMethodPage (params) { - return request({ - url: payMethodApi.page, - method: 'post', - data: params - }) -} -export function storePayMethodGet (params) { - return request({ - url: payMethodApi.get, - method: 'post', - data: params - }) -} -export function storePayMethodUpdate (params) { - return request({ - url: payMethodApi.update, - method: 'post', - data: params - }) -} -export function storePayMethodDelete (params) { - return request({ - url: payMethodApi.del, - method: 'post', - data: params - }) -} -export function storePayMethodList (params) { - return request({ - url: payMethodApi.list, - method: 'post', - data: params - }) -} diff --git a/src/api/bms/settlementAccount.js b/src/api/bms/settlementAccount.js deleted file mode 100644 index 97e1f53..0000000 --- a/src/api/bms/settlementAccount.js +++ /dev/null @@ -1,52 +0,0 @@ -import request from '@/utils/request' -const settlementAccountApi = { - add: '/bms/storeSettlementAccount/add', - get: '/bms/storeSettlementAccount/getById', - update: '/bms/storeSettlementAccount/update', - del: '/bms/storeSettlementAccount/delete', - list: '/bms/storeSettlementAccount/list', - page: '/bms/storeSettlementAccount/page' -} - -export function settlementAccountAdd (params) { - return request({ - url: settlementAccountApi.add, - method: 'post', - data: params - }) -} -export function settlementAccountPage (params) { - return request({ - url: settlementAccountApi.page, - method: 'post', - data: params - }) -} -export function settlementAccountGet (params) { - return request({ - url: settlementAccountApi.get, - method: 'post', - data: params - }) -} -export function settlementAccountUpdate (params) { - return request({ - url: settlementAccountApi.update, - method: 'post', - data: params - }) -} -export function settlementAccountDelete (params) { - return request({ - url: settlementAccountApi.del, - method: 'post', - data: params - }) -} -export function settlementAccountList (params) { - return request({ - url: settlementAccountApi.list, - method: 'post', - data: params - }) -} diff --git a/src/api/bms/store.js b/src/api/bms/store.js deleted file mode 100644 index afc38f5..0000000 --- a/src/api/bms/store.js +++ /dev/null @@ -1,60 +0,0 @@ -import request from '@/utils/request' - -const api = { - add: '/bms/store/add', - get: '/bms/store/get', - update: '/bms/store/update', - del: '/bms/store/delete', - page: '/bms/store/page', - list: '/bms/store/list', - updateStatus: '/bms/store/updateStatus' -} -export function storeAdd (params) { - return request({ - url: api.add, - method: 'post', - data: params - }) -} -export function storeGet (params) { - return request({ - url: api.get, - method: 'post', - data: params - }) -} -export function storeUpdate (params) { - return request({ - url: api.update, - method: 'post', - data: params - }) -} -export function storeDel (params) { - return request({ - url: api.del, - method: 'post', - data: params - }) -} -export function storePage (params) { - return request({ - url: api.page, - method: 'post', - data: params - }) -} -export function storeList (params) { - return request({ - url: api.list, - method: 'post', - data: params - }) -} -export function storeUpdateStatus (params) { - return request({ - url: api.updateStatus, - method: 'post', - data: params - }) -} diff --git a/src/api/customer/customer.js b/src/api/customer/customer.js deleted file mode 100644 index 41cbab4..0000000 --- a/src/api/customer/customer.js +++ /dev/null @@ -1,78 +0,0 @@ -import request from '@/utils/request' -const customerApi = { - page: '/customer/customer/pageByNameAndMobile', - del: '/customer/customer/delete', - add: '/customer/customer/add', - update: '/customer/customer/update', - get: '/customer/customer/getById', - updateStatus: '/customer/customer/updateStatus', - getCategoryList: '/customer/customerCategory/listCategoryByName', - listCustomer: '/customer/customer/listByNameAndMobile' -} - -export function customerAdd (params) { - return request({ - url: customerApi.add, - method: 'post', - data: params - }) -} -export function customerGet (params) { - return request({ - url: customerApi.get, - method: 'post', - data: params - }) -} -export function customerUpdate (params) { - return request({ - url: customerApi.update, - method: 'post', - data: params - }) -} -export function customerDelete (params) { - return request({ - url: customerApi.del, - method: 'post', - data: params - }) -} -export function customerPage (params) { - return request({ - url: customerApi.page, - method: 'post', - data: params - }) -} -export function customerUpdateStatus (params) { - return request({ - url: customerApi.updateStatus, - method: 'post', - data: params - }) -} -export function categoryTypeList (params) { - return request({ - url: customerApi.getCategoryList, - method: 'post', - data: params - }) -} -export const genderMap = { - 'MALE': '男', - 'FEMALE': '女' -} -export const deliverTypeMap = { - 'SELF': '自提', - 'LOGISTICS': '发物流', - 'DESIGNATED_PLACE': '送指定点', - 'AUTO_CAR': '送车' -} -export function listCustomer (params) { - return request({ - url: customerApi.listCustomer, - method: 'post', - data: params - }) -} diff --git a/src/api/dashboard/dashboard.js b/src/api/dashboard/dashboard.js deleted file mode 100644 index 99807db..0000000 --- a/src/api/dashboard/dashboard.js +++ /dev/null @@ -1,12 +0,0 @@ -import request from '@/utils/request' -const dashboardApi = { - get: '/security/dashboard/data' -} - -export function dashboardGet (params) { - return request({ - url: dashboardApi.get, - method: 'post', - data: params - }) -} diff --git a/src/api/file/file.js b/src/api/file/file.js deleted file mode 100644 index 1cac0ba..0000000 --- a/src/api/file/file.js +++ /dev/null @@ -1,14 +0,0 @@ -import { axios } from '@/utils/request' -const fileApi = { - add: '/file/file/add', - del: '/file/file/delete', - get: '/file/file/get', - upload: '/file/file/uploadFile' -} -export function fileUpload (formData) { - return axios.post(fileApi.upload, formData, { - headers: { - 'Content-Type': 'application/x-www-form-urlencoded' - } - }) -} diff --git a/src/api/gms/goods.js b/src/api/gms/goods.js deleted file mode 100644 index 8f8ee28..0000000 --- a/src/api/gms/goods.js +++ /dev/null @@ -1,100 +0,0 @@ -import request from '@/utils/request' -const goodsApi = { - add: '/gms/goods/save', - get: '/gms/goods/getGoodsById', - update: '/gms/goods/update', - del: '/gms/goods/delete', - page: '/gms/goods/page', - list: '/gms/goods/list', - updateStatus: '/gms/goods/updateGoodsStatus', - checkGoodsCode: '/gms/goods/checkGoodsGoodsCodeUnique', - checkGoodsBarCode: '/gms/goods/checkGoodsGoodsBarCodeUnique', - goodsCount: '/gms/goods/countGoodsInfo', - detail: '/gms/goods/get', - listByStoreId: '/gms/goods/listByStoreId' -} - -export function goodsAdd (params) { - return request({ - url: goodsApi.add, - method: 'post', - data: params - }) -} -export function goodsGet (params) { - return request({ - url: goodsApi.get, - method: 'post', - data: params - }) -} -export function goodsUpdate (params) { - return request({ - url: goodsApi.update, - method: 'post', - data: params - }) -} -export function goodsDelete (params) { - return request({ - url: goodsApi.del, - method: 'post', - data: params - }) -} -export function goodsPage (params) { - return request({ - url: goodsApi.page, - method: 'post', - data: params - }) -} -export function goodsList (params) { - return request({ - url: goodsApi.list, - method: 'post', - data: params - }) -} -export function goodsUpdateStatus (params) { - return request({ - url: goodsApi.updateStatus, - method: 'post', - data: params - }) -} -export function goodsCheckGoodsCode (params) { - return request({ - url: goodsApi.checkGoodsCode, - method: 'post', - data: params - }) -} -export function goodsCheckGoodsBarCode (params) { - return request({ - url: goodsApi.checkGoodsBarCode, - method: 'post', - data: params - }) -} -export function goodsCount (params) { - return request({ - url: goodsApi.goodsCount, - method: 'post', - data: params - }) -} -export function goodsDetail (params) { - return request({ - url: goodsApi.detail, - method: 'post', - data: params - }) -} -export function getGoodsListByStoreId (params) { - return request({ - url: goodsApi.listByStoreId, - method: 'post', - data: params - }) -} diff --git a/src/api/gms/goodsCategory.js b/src/api/gms/goodsCategory.js deleted file mode 100644 index 86ae1de..0000000 --- a/src/api/gms/goodsCategory.js +++ /dev/null @@ -1,52 +0,0 @@ -import request from '@/utils/request' -const goodsCategoryApi = { - add: '/gms/goodsCategory/save', - get: '/gms/goodsCategory/get', - update: '/gms/goodsCategory/update', - del: '/gms/goodsCategory/delete', - list: '/gms/goodsCategory/listGoodsCategory', - updateStatus: '/gms/goodsCategory/updategoodsCategoryStatus' -} - -export function goodsCategoryAdd (params) { - return request({ - url: goodsCategoryApi.add, - method: 'post', - data: params - }) -} -export function goodsCategoryGet (params) { - return request({ - url: goodsCategoryApi.get, - method: 'post', - data: params - }) -} -export function goodsCategoryUpdate (params) { - return request({ - url: goodsCategoryApi.update, - method: 'post', - data: params - }) -} -export function goodsCategoryDelete (params) { - return request({ - url: goodsCategoryApi.del, - method: 'post', - data: params - }) -} -export function goodsCategoryList (params) { - return request({ - url: goodsCategoryApi.list, - method: 'post', - data: params - }) -} -export function goodsCategoryUpdateStatus (params) { - return request({ - url: goodsCategoryApi.updateStatus, - method: 'post', - data: params - }) -} diff --git a/src/api/gms/goodsStock.js b/src/api/gms/goodsStock.js deleted file mode 100644 index f3319d7..0000000 --- a/src/api/gms/goodsStock.js +++ /dev/null @@ -1,19 +0,0 @@ -import request from '@/utils/request' -const skuApi = { - page: '/gms/goods/pageGoodsStock', - exportExcel: '/gms/goods/exportGoodsStock' -} -export function pageGoodsStock (params) { - return request({ - url: skuApi.page, - method: 'post', - data: params - }) -} -export function exportStockExcel (params) { - return request({ - url: skuApi.exportExcel, - method: 'post', - data: params - }) -} diff --git a/src/api/gms/goodsUnit.js b/src/api/gms/goodsUnit.js deleted file mode 100644 index 8497df1..0000000 --- a/src/api/gms/goodsUnit.js +++ /dev/null @@ -1,60 +0,0 @@ -import request from '@/utils/request' -const goodsUnitApi = { - add: '/gms/goodsUnit/save', - get: '/gms/goodsUnit/get', - update: '/gms/goodsUnit/update', - del: '/gms/goodsUnit/delete', - page: '/gms/goodsUnit/page', - list: '/gms/goodsUnit/list', - updateStatus: '/gms/goodsUnit/updategoodsUnitStatus' -} - -export function goodsUnitAdd (params) { - return request({ - url: goodsUnitApi.add, - method: 'post', - data: params - }) -} -export function goodsUnitGet (params) { - return request({ - url: goodsUnitApi.get, - method: 'post', - data: params - }) -} -export function goodsUnitUpdate (params) { - return request({ - url: goodsUnitApi.update, - method: 'post', - data: params - }) -} -export function goodsUnitDelete (params) { - return request({ - url: goodsUnitApi.del, - method: 'post', - data: params - }) -} -export function goodsUnitPage (params) { - return request({ - url: goodsUnitApi.page, - method: 'post', - data: params - }) -} -export function goodsUnitList (params) { - return request({ - url: goodsUnitApi.list, - method: 'post', - data: params - }) -} -export function goodsUnitUpdateStatus (params) { - return request({ - url: goodsUnitApi.updateStatus, - method: 'post', - data: params - }) -} diff --git a/src/api/gms/salesProp.js b/src/api/gms/salesProp.js deleted file mode 100644 index 0a6f2b5..0000000 --- a/src/api/gms/salesProp.js +++ /dev/null @@ -1,52 +0,0 @@ -import request from '@/utils/request' -const salesPropApi = { - add: '/gms/salesProp/add', - get: '/gms/salesProp/get', - update: '/gms/salesProp/update', - del: '/gms/salesProp/delete', - page: '/gms/salesProp/page', - list: '/gms/salesProp/list' -} - -export function salesPropAdd (params) { - return request({ - url: salesPropApi.add, - method: 'post', - data: params - }) -} -export function salesPropGet (params) { - return request({ - url: salesPropApi.get, - method: 'post', - data: params - }) -} -export function salesPropUpdate (params) { - return request({ - url: salesPropApi.update, - method: 'post', - data: params - }) -} -export function salesPropDelete (params) { - return request({ - url: salesPropApi.del, - method: 'post', - data: params - }) -} -export function salesPropPage (params) { - return request({ - url: salesPropApi.page, - method: 'post', - data: params - }) -} -export function salesPropList (params) { - return request({ - url: salesPropApi.list, - method: 'post', - data: params - }) -} diff --git a/src/api/gms/salesPropValue.js b/src/api/gms/salesPropValue.js deleted file mode 100644 index 86f77c1..0000000 --- a/src/api/gms/salesPropValue.js +++ /dev/null @@ -1,52 +0,0 @@ -import request from '@/utils/request' -const salesPropValueApi = { - add: '/gms/salesPropValue/add', - get: '/gms/salesPropValue/get', - update: '/gms/salesPropValue/update', - del: '/gms/salesPropValue/delete', - page: '/gms/salesPropValue/page', - list: '/gms/salesPropValue/list' -} - -export function salesPropValueAdd (params) { - return request({ - url: salesPropValueApi.add, - method: 'post', - data: params - }) -} -export function salesPropValueGet (params) { - return request({ - url: salesPropValueApi.get, - method: 'post', - data: params - }) -} -export function salesPropValueUpdate (params) { - return request({ - url: salesPropValueApi.update, - method: 'post', - data: params - }) -} -export function salesPropValueDelete (params) { - return request({ - url: salesPropValueApi.del, - method: 'post', - data: params - }) -} -export function salesPropValuePage (params) { - return request({ - url: salesPropValueApi.page, - method: 'post', - data: params - }) -} -export function salesPropValueList (params) { - return request({ - url: salesPropValueApi.list, - method: 'post', - data: params - }) -} diff --git a/src/api/gms/sku.js b/src/api/gms/sku.js deleted file mode 100644 index 30b07bb..0000000 --- a/src/api/gms/sku.js +++ /dev/null @@ -1,84 +0,0 @@ -import request from '@/utils/request' -const skuApi = { - add: '/gms/sku/save', - get: '/gms/sku/get', - update: '/gms/sku/update', - del: '/gms/sku/delete', - page: '/gms/sku/page', - list: '/gms/sku/list', - getJsonSkuList: '/gms/sku/getJsonSkuListByParams', - getSalesPropForAdm: '/gms/sku/getSalesPropForAdm', - getSkuBySalesProp: '/gms/sku/getSkuBySalesProp', - getPropForAdm: '/gms/sku/getPropForAdm' -} - -export function skuAdd (params) { - return request({ - url: skuApi.add, - method: 'post', - data: params - }) -} -export function skuGet (params) { - return request({ - url: skuApi.get, - method: 'post', - data: params - }) -} -export function skuUpdate (params) { - return request({ - url: skuApi.update, - method: 'post', - data: params - }) -} -export function skuDelete (params) { - return request({ - url: skuApi.del, - method: 'post', - data: params - }) -} -export function skuPage (params) { - return request({ - url: skuApi.page, - method: 'post', - data: params - }) -} -export function skuList (params) { - return request({ - url: skuApi.list, - method: 'post', - data: params - }) -} -export function skuGetJsonSkuList (params) { - return request({ - url: skuApi.getJsonSkuList, - method: 'post', - data: params - }) -} -export function getSalesPropForAdm (params) { - return request({ - url: skuApi.getSalesPropForAdm, - method: 'post', - data: params - }) -} -export function getSkuBySalesProp (params) { - return request({ - url: skuApi.getSkuBySalesProp, - method: 'post', - data: params - }) -} -export function getPropForAdm (params) { - return request({ - url: skuApi.getPropForAdm, - method: 'post', - data: params - }) -} diff --git a/src/api/gms/skuStockChangeRecord.js b/src/api/gms/skuStockChangeRecord.js deleted file mode 100644 index 0232239..0000000 --- a/src/api/gms/skuStockChangeRecord.js +++ /dev/null @@ -1,36 +0,0 @@ -import request from '@/utils/request' -const skuStockChangeRecordApi = { - page: '/gms/skuStockChangeRecord/page', - get: '/gms/skuStockChangeRecord/get', - change: '/gms/skuStockChangeRecord/outOrInSkuStockChangeRecord', - cancel: '/gms/skuStockChangeRecord/cancelStockChangeRecord' -} - -export function skuStockChangeRecordPage (params) { - return request({ - url: skuStockChangeRecordApi.page, - method: 'post', - data: params - }) -} -export function skuStockChangeRecordGet (params) { - return request({ - url: skuStockChangeRecordApi.get, - method: 'post', - data: params - }) -} -export function skuStockChangeRecordChange (params) { - return request({ - url: skuStockChangeRecordApi.change, - method: 'post', - data: params - }) -} -export function skuStockChangeRecordCancel (params) { - return request({ - url: skuStockChangeRecordApi.cancel, - method: 'post', - data: params - }) -} diff --git a/src/api/gms/warehouse.js b/src/api/gms/warehouse.js deleted file mode 100644 index 332bb89..0000000 --- a/src/api/gms/warehouse.js +++ /dev/null @@ -1,19 +0,0 @@ -import request from '@/utils/request' -const skuApi = { - listWarehouse: '/gms/warehouse/listByParams', - findWarehouseListByStoreId: '/gms/warehouse/findWarehouseListByStoreId' -} -export function listWarehouse (params) { - return request({ - url: skuApi.listWarehouse, - method: 'post', - data: params - }) -} -export function listWarehouseByStoreId (params) { - return request({ - url: skuApi.findWarehouseListByStoreId, - method: 'post', - data: params - }) -} diff --git a/src/api/login.js b/src/api/login.js index 01285ec..ea04781 100644 --- a/src/api/login.js +++ b/src/api/login.js @@ -1,7 +1,7 @@ import request from '@/utils/request' const userApi = { - Login: '/login', + Login: '/auth/login', Logout: '/auth/logout', ForgePassword: '/auth/forge-password', Register: '/auth/register', diff --git a/src/api/oms/salesOrder.js b/src/api/oms/salesOrder.js deleted file mode 100644 index 0b31773..0000000 --- a/src/api/oms/salesOrder.js +++ /dev/null @@ -1,46 +0,0 @@ -import request from '@/utils/request' -const salesOrderApi = { - page: '/oms/order/page', - get: '/oms/order/get', - salesOrderLinePage: '/oms/order/findSalesOrderLinePageBySalesOrderId', - exportSalesOrder: '/oms/order/exportSalesOrder', - createOrder: '/oms/order/createOrder' -} - -export function salesOrderPage (params) { - return request({ - url: salesOrderApi.page, - method: 'post', - data: params - }) -} -export function salesOrderGet (params) { - return request({ - url: salesOrderApi.get, - method: 'post', - data: params - }) -} -export function salesOrderLinePage (params) { - return request({ - url: salesOrderApi.salesOrderLinePage, - method: 'post', - data: params - }) -} -export function exportSalesOrder (params) { - var result = request({ - url: salesOrderApi.exportSalesOrder, - method: 'post', - data: params - }) - return result -} -export function createOrder (params) { - var result = request({ - url: salesOrderApi.createOrder, - method: 'post', - data: params - }) - return result -} diff --git a/src/api/purchase/purchase.js b/src/api/purchase/purchase.js deleted file mode 100644 index 736ba92..0000000 --- a/src/api/purchase/purchase.js +++ /dev/null @@ -1,28 +0,0 @@ -import request from '@/utils/request' -const purchaseApi = { - page: '/purchase/purchaseOrder/pageByParams', - get: '/purchase/purchaseOrder/get', - purchaseOrderLinePage: '/purchase/purchaseOrder/findPurchaseOrderLineParamsByOrderId' -} - -export function purchaseOrderPage (params) { - return request({ - url: purchaseApi.page, - method: 'post', - data: params - }) -} -export function purchaseOrderGet (params) { - return request({ - url: purchaseApi.get, - method: 'post', - data: params - }) -} -export function purchaseOrderLinePage (params) { - return request({ - url: purchaseApi.purchaseOrderLinePage, - method: 'post', - data: params - }) -} diff --git a/src/api/security/accessToken.js b/src/api/security/accessToken.js deleted file mode 100644 index 6db44d0..0000000 --- a/src/api/security/accessToken.js +++ /dev/null @@ -1,12 +0,0 @@ -import request from '@/utils/request' -const accessTokenApi = { - get: '/security/accessToken/get' -} - -export function get (params) { - return request({ - url: accessTokenApi.get, - method: 'post', - data: params - }) -} diff --git a/src/api/security/app.js b/src/api/security/app.js deleted file mode 100644 index ce4d13a..0000000 --- a/src/api/security/app.js +++ /dev/null @@ -1,67 +0,0 @@ -import request from '@/utils/request' -const appApi = { - add: '/security/app/save', - get: '/security/app/get', - update: '/security/app/update', - del: '/security/app/delete', - page: '/security/app/page', - updateStatus: '/security/app/updateStatus', - refresh: '/security/app/refreshAccessSecret' -} - -export function appAdd (params) { - return request({ - url: appApi.add, - method: 'post', - data: params - }) -} -export function appGet (params) { - return request({ - url: appApi.get, - method: 'post', - data: params - }) -} -export function appUpdate (params) { - return request({ - url: appApi.update, - method: 'post', - data: params - }) -} -export function appDelete (params) { - return request({ - url: appApi.del, - method: 'post', - data: params - }) -} -export function appPage (params) { - return request({ - url: appApi.page, - method: 'post', - data: params - }) -} -export function appUpdateStatus (params) { - return request({ - url: appApi.updateStatus, - method: 'post', - data: params - }) -} -export function refreshAccessSecret (params) { - return request({ - url: appApi.refresh, - method: 'post', - data: params - }) -} -export const appTypeMap = { - 'ANDROID_APP': 'Android APP', - 'A8_POS': 'POS A8版', - 'IOS_APP': 'iPhone APP', - 'OPENAPI': '开放接口', - 'ADMIN': '管理后台' -} diff --git a/src/api/security/appVersion.js b/src/api/security/appVersion.js deleted file mode 100644 index 9220752..0000000 --- a/src/api/security/appVersion.js +++ /dev/null @@ -1,52 +0,0 @@ -import request from '@/utils/request' -const appVersionApi = { - add: '/security/appVersion/save', - update: '/security/appVersion/update', - del: '/security/appVersion/delete', - page: '/security/appVersion/page', - updateMustUpgrade: '/security/appVersion/updateMustUpgrade', - get: '/security/appVersion/getAppVersionById' -} - -export function appVersionAdd (params) { - return request({ - url: appVersionApi.add, - method: 'post', - data: params - }) -} -export function appVersionUpdate (params) { - return request({ - url: appVersionApi.update, - method: 'post', - data: params - }) -} -export function appVersionDelete (params) { - return request({ - url: appVersionApi.del, - method: 'post', - data: params - }) -} -export function appVersionPage (params) { - return request({ - url: appVersionApi.page, - method: 'post', - data: params - }) -} -export function updateMustUpgrade (params) { - return request({ - url: appVersionApi.updateMustUpgrade, - method: 'post', - data: params - }) -} -export function appVersionGet (params) { - return request({ - url: appVersionApi.get, - method: 'post', - data: params - }) -} diff --git a/src/api/security/cmsArticle.js b/src/api/security/cmsArticle.js deleted file mode 100644 index 62d0f8d..0000000 --- a/src/api/security/cmsArticle.js +++ /dev/null @@ -1,64 +0,0 @@ -import request from '@/utils/request' -const cmsArticleApi = { - add: '/security/cmsArticle/add', - get: '/security/cmsArticle/get', - update: '/security/cmsArticle/update', - del: '/security/cmsArticle/delete', - page: '/security/cmsArticle/page', - updateStatus: '/security/cmsArticle/updateStatus', - listByCode: '/security/cmsArticle/listByCode' -} - -export function cmsArticleAdd (params) { - return request({ - url: cmsArticleApi.add, - method: 'post', - data: params - }) -} -export function cmsArticleGet (params) { - return request({ - url: cmsArticleApi.get, - method: 'post', - data: params - }) -} -export function cmsArticleUpdate (params) { - return request({ - url: cmsArticleApi.update, - method: 'post', - data: params - }) -} -export function cmsArticleDelete (params) { - return request({ - url: cmsArticleApi.del, - method: 'post', - data: params - }) -} -export function cmsArticlePage (params) { - return request({ - url: cmsArticleApi.page, - method: 'post', - data: params - }) -} -export function cmsArticleUpdateStatus (params) { - return request({ - url: cmsArticleApi.updateStatus, - method: 'post', - data: params - }) -} -export function listByCode (params) { - return request({ - url: cmsArticleApi.listByCode, - method: 'post', - data: params - }) -} -export const articleTypeMap = { - 0: '固化', - 1: '自定义' -} diff --git a/src/api/security/deviceInfo.js b/src/api/security/deviceInfo.js deleted file mode 100644 index 4fbbd52..0000000 --- a/src/api/security/deviceInfo.js +++ /dev/null @@ -1,12 +0,0 @@ -import request from '@/utils/request' -const deviceInfoApi = { - page: '/security/deviceInfo/page' -} - -export function page (params) { - return request({ - url: deviceInfoApi.page, - method: 'post', - data: params - }) -} diff --git a/src/api/security/function.js b/src/api/security/function.js deleted file mode 100644 index b9248b3..0000000 --- a/src/api/security/function.js +++ /dev/null @@ -1,52 +0,0 @@ -import request from '@/utils/request' - -const api = { - add: '/security/function/add', - update: '/security/function/update', - del: '/security/function/delete', - page: '/security/function/page', - get: '/security/function/get', - functionCodeMap: '/security/function/getFunctionCodeMap' -} -export function functionAdd (params) { - return request({ - url: api.add, - method: 'post', - data: params - }) -} -export function functionUpdate (params) { - return request({ - url: api.update, - method: 'post', - data: params - }) -} -export function functionDel (params) { - return request({ - url: api.del, - method: 'post', - data: params - }) -} -export function functionPage (params) { - return request({ - url: api.page, - method: 'post', - data: params - }) -} -export function functionGet (params) { - return request({ - url: api.get, - method: 'post', - data: params - }) -} -export function functionCodeMap (params) { - return request({ - url: api.functionCodeMap, - method: 'post', - data: params - }) -} diff --git a/src/api/security/functionCategory.js b/src/api/security/functionCategory.js deleted file mode 100644 index e73318b..0000000 --- a/src/api/security/functionCategory.js +++ /dev/null @@ -1,44 +0,0 @@ -import request from '@/utils/request' -const functionCategoryApi = { - add: '/security/functionCategory/add', - update: '/security/functionCategory/update', - del: '/security/functionCategory/delete', - page: '/security/functionCategory/page', - get: '/security/functionCategory/get' -} - -export function functionCategoryAdd (params) { - return request({ - url: functionCategoryApi.add, - method: 'post', - data: params - }) -} -export function functionCategoryUpdate (params) { - return request({ - url: functionCategoryApi.update, - method: 'post', - data: params - }) -} -export function functionCategoryDel (params) { - return request({ - url: functionCategoryApi.del, - method: 'post', - data: params - }) -} -export function functionCategoryPage (params) { - return request({ - url: functionCategoryApi.page, - method: 'post', - data: params - }) -} -export function functionCategoryGet (params) { - return request({ - url: functionCategoryApi.get, - method: 'post', - data: params - }) -} diff --git a/src/api/security/functionResource.js b/src/api/security/functionResource.js deleted file mode 100644 index 685c698..0000000 --- a/src/api/security/functionResource.js +++ /dev/null @@ -1,21 +0,0 @@ -import request from '@/utils/request' - -const functionResourceApi = { - add: '/security/functionResource/add', - del: '/security/functionResource/delete' -} - -export function functionResourceAdd (params) { - return request({ - url: functionResourceApi.add, - method: 'post', - data: params - }) -} -export function functionResourceDelete (params) { - return request({ - url: functionResourceApi.del, - method: 'post', - data: params - }) -} diff --git a/src/api/security/menu.js b/src/api/security/menu.js new file mode 100644 index 0000000..709bf2a --- /dev/null +++ b/src/api/security/menu.js @@ -0,0 +1,53 @@ +import request from '@/utils/request' + +const menuApi = { + add: 'sys/menu/add', + get: 'sys/menu/get', + update: 'sys/menu/update', + del: 'sys/menu/delete', + updateStatus: 'sys/menu/updateStatus', + list: 'sys/menu/listByParentId' +} + +export function menuAdd (params) { + return request({ + url: menuApi.add, + method: 'post', + data: params + }) +} +export function menuGet (params) { + return request({ + url: menuApi.get, + method: 'post', + data: params + }) +} +export function menuUpdate (params) { + return request({ + url: menuApi.update, + method: 'post', + data: params + }) +} +export function menuDelete (params) { + return request({ + url: menuApi.del, + method: 'post', + data: params + }) +} +export function menuList (params) { + return request({ + url: menuApi.list, + method: 'post', + data: params + }) +} +export function menuUpdateStatus (params) { + return request({ + url: menuApi.updateStatus, + method: 'post', + data: params + }) +} diff --git a/src/api/security/message.js b/src/api/security/message.js deleted file mode 100644 index 4ba8c55..0000000 --- a/src/api/security/message.js +++ /dev/null @@ -1,44 +0,0 @@ -import request from '@/utils/request' -const messageApi = { - add: '/security/message/save', - get: '/security/message/get', - update: '/security/message/update', - del: '/security/message/delete', - page: '/security/message/page' -} - -export function messageAdd (params) { - return request({ - url: messageApi.add, - method: 'post', - data: params - }) -} -export function messageGet (params) { - return request({ - url: messageApi.get, - method: 'post', - data: params - }) -} -export function messageUpdate (params) { - return request({ - url: messageApi.update, - method: 'post', - data: params - }) -} -export function messageDelete (params) { - return request({ - url: messageApi.del, - method: 'post', - data: params - }) -} -export function messagePage (params) { - return request({ - url: messageApi.page, - method: 'post', - data: params - }) -} diff --git a/src/api/security/redis.js b/src/api/security/redis.js deleted file mode 100644 index 22efbc5..0000000 --- a/src/api/security/redis.js +++ /dev/null @@ -1,21 +0,0 @@ -import request from '@/utils/request' -const redisManageApi = { - page: '/security/redisManage/page', - deleteByParams: '/security/redisManage/delete' -} - -export function page (params) { - return request({ - url: redisManageApi.page, - method: 'post', - data: params - }) -} - -export function deleteByParams (params) { - return request({ - url: redisManageApi.deleteByParams, - method: 'post', - data: params - }) -} diff --git a/src/api/security/resource.js b/src/api/security/resource.js deleted file mode 100644 index 7d40bcd..0000000 --- a/src/api/security/resource.js +++ /dev/null @@ -1,92 +0,0 @@ -import request from '@/utils/request' - -const resourceApi = { - add: '/security/resource/add', - get: '/security/resource/get', - update: '/security/resource/update', - del: '/security/resource/delete', - updateStatus: '/security/resource/updateStatus', - list: '/security/resource/listByParentId', - listByUser: '/security/url/listByUser', - listAllResource: '/security/resource/listAllResource', - resourceByRoleId: '/security/resource/listAllResourceByRoleId', - listResourceByUser: '/security/resource/listResourceByLoginUser', - resourceByFunctionId: '/security/resource/listAllResourceByFunctionId' -} - -export function resourceAdd (params) { - return request({ - url: resourceApi.add, - method: 'post', - data: params - }) -} -export function resourceGet (params) { - return request({ - url: resourceApi.get, - method: 'post', - data: params - }) -} -export function resourceUpdate (params) { - return request({ - url: resourceApi.update, - method: 'post', - data: params - }) -} -export function resourceDelete (params) { - return request({ - url: resourceApi.del, - method: 'post', - data: params - }) -} -export function resourceList (params) { - return request({ - url: resourceApi.list, - method: 'post', - data: params - }) -} -export function resourceListByUser (params) { - return request({ - url: resourceApi.listByUser, - method: 'post', - data: params - }) -} -export function resourceAll () { - return request({ - url: resourceApi.listAllResource, - method: 'post' - }) -} -export function resourceUpdateStatus (params) { - return request({ - url: resourceApi.updateStatus, - method: 'post', - data: params - }) -} -export function resourceByRoleId (params) { - return request({ - url: resourceApi.resourceByRoleId, - method: 'post', - data: params - }) -} -export function listResourceByUser (params) { - return request({ - url: resourceApi.listResourceByUser, - method: 'post', - data: params - }) -} -export function resourceByFunctionId (params) { - return request({ - url: resourceApi.resourceByFunctionId, - method: 'post', - data: params - }) -} diff --git a/src/api/security/role.js b/src/api/security/role.js index a54673d..037d981 100644 --- a/src/api/security/role.js +++ b/src/api/security/role.js @@ -1,13 +1,12 @@ import request from '@/utils/request' const roleApi = { - add: '/security/role/add', - get: '/security/role/get', - update: '/security/role/update', - del: '/security/role/delete', - page: '/security/role/page', - updateStatus: '/security/role/updateStatus', - rolesByUserId: '/security/role/listAllRoleByUserId' + add: '/sys/role/add', + get: '/sys/role/getById', + update: '/sys/role/update', + del: '/sys/role/delete', + page: '/sys/role/page', + updateStatus: '/sys/role/updateStatus' } export function roleAdd (params) { @@ -52,10 +51,3 @@ export function roleUpdateStatus (params) { data: params }) } -export function rolesByUserId (params) { - return request({ - url: roleApi.rolesByUserId, - method: 'post', - data: params - }) -} diff --git a/src/api/security/roleResource.js b/src/api/security/roleResource.js deleted file mode 100644 index 4efc967..0000000 --- a/src/api/security/roleResource.js +++ /dev/null @@ -1,21 +0,0 @@ -import request from '@/utils/request' - -const roleResourceApi = { - add: '/security/roleResource/add', - del: '/security/roleResource/delete' -} - -export function roleResourceAdd (params) { - return request({ - url: roleResourceApi.add, - method: 'post', - data: params - }) -} -export function roleResourceDelete (params) { - return request({ - url: roleResourceApi.del, - method: 'post', - data: params - }) -} diff --git a/src/api/security/user.js b/src/api/security/user.js index 21c2f8e..7ef02bc 100644 --- a/src/api/security/user.js +++ b/src/api/security/user.js @@ -2,22 +2,18 @@ import request from '@/utils/request' const userApi = { login: '/login', - logout: '/security/user/logout', - add: '/security/user/add', - get: '/security/user/getById', - update: '/security/user/update', - del: '/security/user/delete', - page: '/security/user/page', - updateEnabled: '/security/user/updateEnabled', - getListByOrgId: '/security/user/getListByOrgId', - getUserInfo: '/security/user/get' + logout: '/logout', + add: '/sys/user/add', + get: '/sys/user/get', + update: '/sys/user/update', + del: '/sys/user/delete', + page: '/sys/user/page', + updateEnabled: '/sys/user/updateEnabled', + getInfo: '/sys/user/getInfo' } const userPasswordApi = { - set: '/security/user/password/set', - update: '/security/user/password/update', - send: '/security/user/sendSecuritycode', - setById: '/security/user/password/setByUserId' + update: '/sys/user/passwordUpdate', } export function userLogin (params) { @@ -63,6 +59,20 @@ export function userPage (params) { data: params }) } +export function userLogout (params) { + // return request({ + // url: userApi.logout, + // method: 'post', + // data: params + // }) +} +export function getInfo (params) { + return request({ + url: userApi.getInfo, + method: 'post', + data: params + }) +} export function userUpdateEnabled (params) { return request({ url: userApi.updateEnabled, @@ -70,30 +80,9 @@ export function userUpdateEnabled (params) { data: params }) } -export function userPasswordSet (params) { +export function passwordUpdate (params) { return request({ - url: userPasswordApi.set, - method: 'post', - data: params - }) -} -export function userPasswordSetById (params) { - return request({ - url: userPasswordApi.setById, - method: 'post', - data: params - }) -} -export function getListByOrgId (params) { - return request({ - url: userApi.getListByOrgId, - method: 'post', - data: params - }) -} -export function getUserInfo (params) { - return request({ - url: userApi.getUserInfo, + url: userPasswordApi.update, method: 'post', data: params }) diff --git a/src/api/security/userFeedBack.js b/src/api/security/userFeedBack.js deleted file mode 100644 index 6234795..0000000 --- a/src/api/security/userFeedBack.js +++ /dev/null @@ -1,20 +0,0 @@ -import request from '@/utils/request' -const userFeedBackApi = { - page: '/security/user/feedback/pageUserFeedBack', - handleFeedBack: '/security/user/feedback/handleFeedBack' -} - -export function UserFeedBackPage (params) { - return request({ - url: userFeedBackApi.page, - method: 'post', - data: params - }) -} -export function handleFeedBack (params) { - return request({ - url: userFeedBackApi.handleFeedBack, - method: 'post', - data: params - }) -} diff --git a/src/api/security/userRole.js b/src/api/security/userRole.js deleted file mode 100644 index 75bae92..0000000 --- a/src/api/security/userRole.js +++ /dev/null @@ -1,21 +0,0 @@ -import request from '@/utils/request' - -const userRoleApi = { - add: '/security/userRole/add', - del: '/security/userRole/delete' -} - -export function userRoleAdd (params) { - return request({ - url: userRoleApi.add, - method: 'post', - data: params - }) -} -export function userRoleDelete (params) { - return request({ - url: userRoleApi.del, - method: 'post', - data: params - }) -} diff --git a/src/api/supplier/supplier.js b/src/api/supplier/supplier.js deleted file mode 100644 index bc4c294..0000000 --- a/src/api/supplier/supplier.js +++ /dev/null @@ -1,60 +0,0 @@ -import request from '@/utils/request' -const supplierApi = { - add: '/supplier/supplier/add', - get: '/supplier/supplier/getById', - update: '/supplier/supplier/update', - del: '/supplier/supplier/delete', - page: '/supplier/supplier/pageByParams', - updateStatus: '/supplier/supplier/updateStatus', - list: '/supplier/supplier/listSupplierByParams' -} - -export function supplierAdd (params) { - return request({ - url: supplierApi.add, - method: 'post', - data: params - }) -} -export function supplierGet (params) { - return request({ - url: supplierApi.get, - method: 'post', - data: params - }) -} -export function supplierUpdate (params) { - return request({ - url: supplierApi.update, - method: 'post', - data: params - }) -} -export function supplierDelete (params) { - return request({ - url: supplierApi.del, - method: 'post', - data: params - }) -} -export function supplierPage (params) { - return request({ - url: supplierApi.page, - method: 'post', - data: params - }) -} -export function supplierUpdateStatus (params) { - return request({ - url: supplierApi.updateStatus, - method: 'post', - data: params - }) -} -export function supplierList (params) { - return request({ - url: supplierApi.list, - method: 'post', - data: params - }) -} diff --git a/src/components/AvatarList/Item.vue b/src/components/AvatarList/Item.vue deleted file mode 100644 index 26e149e..0000000 --- a/src/components/AvatarList/Item.vue +++ /dev/null @@ -1,46 +0,0 @@ - - - {{ tips }} - - - - - - diff --git a/src/components/AvatarList/List.vue b/src/components/AvatarList/List.vue deleted file mode 100644 index 446ceeb..0000000 --- a/src/components/AvatarList/List.vue +++ /dev/null @@ -1,99 +0,0 @@ - - - diff --git a/src/components/Charts/MiniBar.vue b/src/components/Charts/MiniBar.vue index b5292f4..beac404 100644 --- a/src/components/Charts/MiniBar.vue +++ b/src/components/Charts/MiniBar.vue @@ -10,20 +10,43 @@ diff --git a/src/components/CountDown/index.js b/src/components/CountDown/index.js deleted file mode 100644 index 35e954f..0000000 --- a/src/components/CountDown/index.js +++ /dev/null @@ -1,3 +0,0 @@ -import CountDown from './CountDown' - -export default CountDown diff --git a/src/components/CountDown/index.md b/src/components/CountDown/index.md deleted file mode 100644 index fd46809..0000000 --- a/src/components/CountDown/index.md +++ /dev/null @@ -1,34 +0,0 @@ -# CountDown 倒计时 - -倒计时组件。 - - - -引用方式: - -```javascript -import CountDown from '@/components/CountDown/CountDown' - -export default { - components: { - CountDown - } -} -``` - - - -## 代码演示 [demo](https://pro.loacg.com/test/home) - -```html - -``` - - - -## API - -| 参数 | 说明 | 类型 | 默认值 | -|----------|------------------------------------------|-------------|-------| -| target | 目标时间 | Date | - | -| onEnd | 倒计时结束回调 | funtion | -| diff --git a/src/components/DescriptionList/DescriptionList.vue b/src/components/DescriptionList/DescriptionList.vue deleted file mode 100644 index 7f98fec..0000000 --- a/src/components/DescriptionList/DescriptionList.vue +++ /dev/null @@ -1,153 +0,0 @@ - - - {{ title }} - - - - - - - - - diff --git a/src/components/DescriptionList/index.js b/src/components/DescriptionList/index.js deleted file mode 100644 index 7aed83d..0000000 --- a/src/components/DescriptionList/index.js +++ /dev/null @@ -1,2 +0,0 @@ -import DescriptionList from './DescriptionList' -export default DescriptionList diff --git a/src/components/Editor/QuillEditor.vue b/src/components/Editor/QuillEditor.vue index 9e43a91..9a041e5 100644 --- a/src/components/Editor/QuillEditor.vue +++ b/src/components/Editor/QuillEditor.vue @@ -9,6 +9,7 @@ @ready="onEditorReady($event)" @change="onEditorChange($event)"> + diff --git a/src/components/Editor/WangEditor.vue b/src/components/Editor/WangEditor.vue index 5f50c26..d9c71c7 100644 --- a/src/components/Editor/WangEditor.vue +++ b/src/components/Editor/WangEditor.vue @@ -1,10 +1,11 @@ - + + + - diff --git a/src/components/Exception/ExceptionPage.vue b/src/components/Exception/ExceptionPage.vue deleted file mode 100644 index 132e346..0000000 --- a/src/components/Exception/ExceptionPage.vue +++ /dev/null @@ -1,130 +0,0 @@ - - - - - - - - {{ config[type].title }} - {{ config[type].desc }} - - 返回首页 - - - - - - - diff --git a/src/components/Exception/index.js b/src/components/Exception/index.js deleted file mode 100644 index dda91be..0000000 --- a/src/components/Exception/index.js +++ /dev/null @@ -1,2 +0,0 @@ -import ExceptionPage from './ExceptionPage.vue' -export default ExceptionPage diff --git a/src/components/Exception/type.js b/src/components/Exception/type.js deleted file mode 100644 index 39bc6be..0000000 --- a/src/components/Exception/type.js +++ /dev/null @@ -1,28 +0,0 @@ -const types = { - 401: { - title: '401', - desc: '未登录或登录超时' - }, - 403: { - img: 'https://gw.alipayobjects.com/zos/rmsportal/wZcnGqRDyhPOEYFcZDnb.svg', - title: '403', - desc: '抱歉,你无权访问该页面' - }, - 404: { - img: 'https://gw.alipayobjects.com/zos/rmsportal/KpnpchXsobRgLElEozzI.svg', - title: '404', - desc: '抱歉,你访问的页面不存在或仍在开发中' - }, - 500: { - img: 'https://gw.alipayobjects.com/zos/rmsportal/RVRUAYdCGeYNBWoKiIwB.svg', - title: '500', - desc: '抱歉,服务器出错了' - }, - 503: { - img: 'https://gw.alipayobjects.com/zos/rmsportal/RVRUAYdCGeYNBWoKiIwB.svg', - title: '503', - desc: '抱歉,服务器出错了' - } -} - -export default types diff --git a/src/components/GlobalFooter/GlobalFooter.vue b/src/components/GlobalFooter/GlobalFooter.vue deleted file mode 100644 index 5db47d4..0000000 --- a/src/components/GlobalFooter/GlobalFooter.vue +++ /dev/null @@ -1,42 +0,0 @@ - - - - - - - diff --git a/src/components/GlobalFooter/index.js b/src/components/GlobalFooter/index.js deleted file mode 100644 index 832e0bd..0000000 --- a/src/components/GlobalFooter/index.js +++ /dev/null @@ -1,2 +0,0 @@ -import GlobalFooter from './GlobalFooter' -export default GlobalFooter diff --git a/src/components/GlobalFooter/index.vue b/src/components/GlobalFooter/index.vue index 28f0c3f..d7e0125 100644 --- a/src/components/GlobalFooter/index.vue +++ b/src/components/GlobalFooter/index.vue @@ -2,7 +2,7 @@ - TCC 西安研发中心出品 + tcc出品 diff --git a/src/components/GlobalHeader/AvatarDropdown.vue b/src/components/GlobalHeader/AvatarDropdown.vue index 36714da..73e202e 100644 --- a/src/components/GlobalHeader/AvatarDropdown.vue +++ b/src/components/GlobalHeader/AvatarDropdown.vue @@ -1,14 +1,18 @@ - + - {{ currentUser.username }} + {{ currentUser.name }} - - + + + + 个人中心 + + - 修改密码 + 个人设置 @@ -24,11 +28,10 @@ - - diff --git a/src/components/GlobalHeader/RightContent.vue b/src/components/GlobalHeader/RightContent.vue index 8354c22..5d0bb80 100644 --- a/src/components/GlobalHeader/RightContent.vue +++ b/src/components/GlobalHeader/RightContent.vue @@ -1,8 +1,7 @@ - + - @@ -14,8 +13,7 @@ export default { name: 'RightContent', components: { AvatarDropdown, - SelectLang, - PasswordForm: () => import('@/components/PasswordForm') + SelectLang }, props: { prefixCls: { @@ -45,17 +43,16 @@ export default { wrpCls () { return { 'ant-pro-global-header-index-right': true, - [`ant-pro-global-header-index-${this.isMobile || !this.topMenu ? 'light' : this.theme}`]: true + [`ant-pro-global-header-index-${(this.isMobile || !this.topMenu) ? 'light' : this.theme}`]: true } } }, - created () { - this.currentUser = this.$store.getters.userInfo || { username: '***' } - }, - methods: { - handlePassword () { - this.$refs.password.show(this.currentUser.userId) - } + mounted () { + setTimeout(() => { + this.currentUser = { + name: 'Serati Ma' + } + }, 1500) } } diff --git a/src/components/GlobalHeader/index.js b/src/components/GlobalHeader/index.js deleted file mode 100644 index 0807c87..0000000 --- a/src/components/GlobalHeader/index.js +++ /dev/null @@ -1,2 +0,0 @@ -import GlobalHeader from './GlobalHeader' -export default GlobalHeader diff --git a/src/components/IconSelector/IconSelector.vue b/src/components/IconSelector/IconSelector.vue index 7fd5238..810d297 100644 --- a/src/components/IconSelector/IconSelector.vue +++ b/src/components/IconSelector/IconSelector.vue @@ -22,9 +22,9 @@ export default { type: String, default: 'ant-pro-icon-selector' }, + // eslint-disable-next-line value: { - type: String, - default: '' + type: String } }, data () { @@ -59,21 +59,28 @@ export default { } } + diff --git a/src/components/IconSelector/IconSelectorView.vue b/src/components/IconSelector/IconSelectorView.vue deleted file mode 100644 index fe9640e..0000000 --- a/src/components/IconSelector/IconSelectorView.vue +++ /dev/null @@ -1,47 +0,0 @@ - - - - - - - - diff --git a/src/components/IconSelector/icons.js b/src/components/IconSelector/icons.js index ce90fcc..920f464 100644 --- a/src/components/IconSelector/icons.js +++ b/src/components/IconSelector/icons.js @@ -16,7 +16,7 @@ export default [ { key: 'editor', title: '编辑类图标', - icons: ['edit', 'form', 'copy', 'scissor', 'delete', 'snippets', 'diff', 'highlight', 'align-center', 'align-left', 'align-right', 'bg-colors', 'bold', 'italic', 'underline', 'strikethrough', 'redo', 'undo', 'zoom-in', 'zoom-out', 'font-colors', 'font-size', 'line-height', 'column-height', 'dash', 'small-dash', 'sort-ascending', 'sort-descending', 'drag', 'ordered-list', 'radius-setting'] + icons: ['edit', 'form', 'copy', 'scissor', 'delete', 'snippets', 'diff', 'highlight', 'align-center', 'align-left', 'align-right', 'bg-colors', 'bold', 'italic', 'underline', 'strikethrough', 'redo', 'undo', 'zoom-in', 'zoom-out', 'font-colors', 'font-size', 'line-height', 'colum-height', 'dash', 'small-dash', 'sort-ascending', 'sort-descending', 'drag', 'ordered-list', 'radius-setting'] }, { key: 'data', @@ -26,7 +26,7 @@ export default [ { key: 'brand_logo', title: '网站通用图标', - icons: ['lock', 'unlock', 'bars', 'book', 'calendar', 'cloud', 'cloud-download', 'code', 'copy', 'credit-card', 'delete', 'desktop', 'download', 'ellipsis', 'file', 'file-text', 'file-unknown', 'file-pdf', 'file-word', 'file-excel', 'file-jpg', 'file-ppt', 'file-markdown', 'file-add', 'folder', 'folder-open', 'folder-add', 'hdd', 'frown', 'meh', 'smile', 'inbox', 'laptop', 'appstore', 'link', 'mail', 'mobile', 'notification', 'paper-clip', 'picture', 'poweroff', 'reload', 'search', 'setting', 'share-alt', 'shopping-cart', 'tablet', 'tag', 'tags', 'to-top', 'upload', 'user', 'video-camera', 'home', 'loading', 'loading-3-quarters', 'cloud-upload', 'star', 'heart', 'environment', 'eye', 'camera', 'save', 'team', 'solution', 'phone', 'filter', 'exception', 'export', 'customer-service', 'qrcode', 'scan', 'like', 'dislike', 'message', 'pay-circle', 'calculator', 'pushpin', 'bulb', 'select', 'switcher', 'rocket', 'bell', 'disconnect', 'database', 'compass', 'barcode', 'hourglass', 'key', 'flag', 'layout', 'printer', 'sound', 'usb', 'skin', 'tool', 'sync', 'wifi', 'car', 'schedule', 'user-add', 'user-delete', 'usergroup-add', 'usergroup-delete', 'man', 'woman', 'shop', 'gift', 'idcard', 'medicine-box', 'red-envelope', 'coffee', 'copyright', 'trademark', 'safety', 'wallet', 'bank', 'trophy', 'contacts', 'global', 'shake', 'api', 'fork', 'dashboard', 'table', 'profile', 'alert', 'audit', 'branches', 'build', 'border', 'crown', 'experiment', 'fire', 'money-collect', 'property-safety', 'read', 'reconciliation', 'rest', 'security-scan', 'insurance', 'interaction', 'safety-certificate', 'project', 'thunderbolt', 'block', 'cluster', 'deployment-unit', 'dollar', 'euro', 'pound', 'file-done', 'file-exclamation', 'file-protect', 'file-search', 'file-sync', 'gateway', 'gold', 'robot', 'shopping'] + icons: ['lock', 'unlock', 'bars', 'book', 'calendar', 'cloud', 'cloud-download', 'code', 'copy', 'credit-card', 'delete', 'desktop', 'download', 'ellipsis', 'file', 'file-text', 'file-unknown', 'file-pdf', 'file-word', 'file-excel', 'file-jpg', 'file-ppt', 'file-markdown', 'file-add', 'folder', 'folder-open', 'folder-add', 'hdd', 'frown', 'meh', 'smile', 'inbox', 'laptop', 'appstore', 'link', 'mail', 'mobile', 'notification', 'paper-clip', 'picture', 'poweroff', 'reload', 'search', 'setting', 'share-alt', 'shopping-cart', 'tablet', 'tag', 'tags', 'to-top', 'upload', 'user', 'video-camera', 'home', 'loading', 'loading-3-quarters', 'cloud-upload', 'star', 'heart', 'environment', 'eye', 'camera', 'save', 'team', 'solution', 'phone', 'filter', 'exception', 'export', 'customer-service', 'qrcode', 'scan', 'like', 'dislike', 'message', 'pay-circle', 'calculator', 'pushpin', 'bulb', 'select', 'switcher', 'rocket', 'bell', 'disconnect', 'database', 'compass', 'barcode', 'hourglass', 'key', 'flag', 'layout', 'printer', 'sound', 'usb', 'skin', 'tool', 'sync', 'wifi', 'car', 'schedule', 'user-add', 'user-delete', 'usergroup-add', 'usergroup-delete', 'man', 'woman', 'shop', 'gift', 'idcard', 'medicine-box', 'red-envelope', 'coffee', 'copyright', 'trademark', 'safety', 'wallet', 'bank', 'trophy', 'contacts', 'global', 'shake', 'api', 'fork', 'dashboard', 'table', 'profile', 'alert', 'audit', 'branches', 'build', 'border', 'crown', 'experiment', 'fire', 'money-collect', 'property-safety', 'read', 'reconciliation', 'rest', 'security-scan', 'insurance', 'interation', 'safety-certificate', 'project', 'thunderbolt', 'block', 'cluster', 'deployment-unit', 'dollar', 'euro', 'pound', 'file-done', 'file-exclamation', 'file-protect', 'file-search', 'file-sync', 'gateway', 'gold', 'robot', 'shopping'] }, { key: 'application', diff --git a/src/components/ImageUpload/index.vue b/src/components/ImageUpload/index.vue deleted file mode 100644 index 73d404a..0000000 --- a/src/components/ImageUpload/index.vue +++ /dev/null @@ -1,151 +0,0 @@ - - - - - - 上传文件 - - - - - - - - - diff --git a/src/components/Menu/SideMenu.vue b/src/components/Menu/SideMenu.vue deleted file mode 100644 index 62fb01d..0000000 --- a/src/components/Menu/SideMenu.vue +++ /dev/null @@ -1,61 +0,0 @@ - - - - - - - - - diff --git a/src/components/Menu/index.js b/src/components/Menu/index.js deleted file mode 100644 index 4348509..0000000 --- a/src/components/Menu/index.js +++ /dev/null @@ -1,2 +0,0 @@ -import SMenu from './menu' -export default SMenu diff --git a/src/components/Menu/menu.js b/src/components/Menu/menu.js deleted file mode 100644 index 2b3f7a2..0000000 --- a/src/components/Menu/menu.js +++ /dev/null @@ -1,177 +0,0 @@ -import Menu from 'ant-design-vue/es/menu' -import Icon from 'ant-design-vue/es/icon' - -export default { - name: 'SMenu', - props: { - menu: { - type: Array, - required: true - }, - theme: { - type: String, - required: false, - default: 'dark' - }, - mode: { - type: String, - required: false, - default: 'inline' - }, - collapsed: { - type: Boolean, - required: false, - default: false - } - }, - data () { - return { - openKeys: [], - selectedKeys: [], - cachedOpenKeys: [] - } - }, - computed: { - rootSubmenuKeys: vm => { - const keys = [] - vm.menu.forEach(item => keys.push(item.path)) - return keys - } - }, - mounted () { - this.updateMenu() - }, - watch: { - collapsed (val) { - if (val) { - this.cachedOpenKeys = this.openKeys.concat() - this.openKeys = [] - } else { - this.openKeys = this.cachedOpenKeys - } - }, - $route: function () { - this.updateMenu() - } - }, - methods: { - // select menu item - onOpenChange (openKeys) { - // 在水平模式下时执行,并且不再执行后续 - if (this.mode === 'horizontal') { - this.openKeys = openKeys - return - } - // 非水平模式时 - const latestOpenKey = openKeys.find(key => !this.openKeys.includes(key)) - if (!this.rootSubmenuKeys.includes(latestOpenKey)) { - this.openKeys = openKeys - } else { - this.openKeys = latestOpenKey ? [latestOpenKey] : [] - } - }, - onSelect ({ item, key, selectedKeys }) { - this.selectedKeys = selectedKeys - this.$emit('select', { item, key, selectedKeys }) - }, - updateMenu () { - const routes = this.$route.matched.concat() - const { hidden } = this.$route.meta - if (routes.length >= 3 && hidden) { - routes.pop() - this.selectedKeys = [routes[routes.length - 1].path] - } else { - this.selectedKeys = [routes.pop().path] - } - const openKeys = [] - if (this.mode === 'inline') { - routes.forEach(item => { - openKeys.push(item.path) - }) - } - - this.collapsed ? (this.cachedOpenKeys = openKeys) : (this.openKeys = openKeys) - }, - - // render - renderItem (menu) { - if (!menu.hidden) { - return menu.children && !menu.hideChildrenInMenu ? this.renderSubMenu(menu) : this.renderMenuItem(menu) - } - return null - }, - renderMenuItem (menu) { - const target = menu.meta.target || null - const CustomTag = target && 'a' || 'router-link' - const props = { to: { name: menu.name } } - const attrs = { href: menu.path, target: menu.meta.target } - - if (menu.children && menu.hideChildrenInMenu) { - // 把有子菜单的 并且 父菜单是要隐藏子菜单的 - // 都给子菜单增加一个 hidden 属性 - // 用来给刷新页面时, selectedKeys 做控制用 - menu.children.forEach(item => { - item.meta = Object.assign(item.meta, { hidden: true }) - }) - } - - return ( - - - {this.renderIcon(menu.meta.icon)} - {menu.meta.title} - - - ) - }, - renderSubMenu (menu) { - const itemArr = [] - if (!menu.hideChildrenInMenu) { - menu.children.forEach(item => itemArr.push(this.renderItem(item))) - } - return ( - - - {this.renderIcon(menu.meta.icon)} - {menu.meta.title} - - {itemArr} - - ) - }, - renderIcon (icon) { - if (icon === 'none' || icon === undefined) { - return null - } - const props = {} - typeof (icon) === 'object' ? props.component = icon : props.type = icon - return ( - - ) - } - }, - - render () { - const dynamicProps = { - props: { - mode: this.mode, - theme: this.theme, - openKeys: this.openKeys, - selectedKeys: this.selectedKeys - }, - on: { - openChange: this.onOpenChange, - select: this.onSelect - } - } - - const menuTree = this.menu.map(item => { - if (item.hidden) { - return null - } - return this.renderItem(item) - }) - - return ({menuTree}) - } -} diff --git a/src/components/Menu/menu.render.js b/src/components/Menu/menu.render.js deleted file mode 100644 index 011639f..0000000 --- a/src/components/Menu/menu.render.js +++ /dev/null @@ -1,156 +0,0 @@ -import Menu from 'ant-design-vue/es/menu' -import Icon from 'ant-design-vue/es/icon' - -const { Item, SubMenu } = Menu - -export default { - name: 'SMenu', - props: { - menu: { - type: Array, - required: true - }, - theme: { - type: String, - required: false, - default: 'dark' - }, - mode: { - type: String, - required: false, - default: 'inline' - }, - collapsed: { - type: Boolean, - required: false, - default: false - } - }, - data () { - return { - openKeys: [], - selectedKeys: [], - cachedOpenKeys: [] - } - }, - computed: { - rootSubmenuKeys: vm => { - const keys = [] - vm.menu.forEach(item => keys.push(item.path)) - return keys - } - }, - created () { - this.updateMenu() - }, - watch: { - collapsed (val) { - if (val) { - this.cachedOpenKeys = this.openKeys.concat() - this.openKeys = [] - } else { - this.openKeys = this.cachedOpenKeys - } - }, - $route: function () { - this.updateMenu() - } - }, - methods: { - renderIcon: function (h, icon) { - if (icon === 'none' || icon === undefined) { - return null - } - const props = {} - typeof (icon) === 'object' ? props.component = icon : props.type = icon - return h(Icon, { props: { ...props } }) - }, - renderMenuItem: function (h, menu, pIndex, index) { - const target = menu.meta.target || null - return h(Item, { key: menu.path ? menu.path : 'item_' + pIndex + '_' + index }, [ - h('router-link', { attrs: { to: { name: menu.name }, target: target } }, [ - this.renderIcon(h, menu.meta.icon), - h('span', [menu.meta.title]) - ]) - ]) - }, - renderSubMenu: function (h, menu, pIndex, index) { - const this2_ = this - const subItem = [h('span', { slot: 'title' }, [this.renderIcon(h, menu.meta.icon), h('span', [menu.meta.title])])] - const itemArr = [] - const pIndex_ = pIndex + '_' + index - console.log('menu', menu) - if (!menu.hideChildrenInMenu) { - menu.children.forEach(function (item, i) { - itemArr.push(this2_.renderItem(h, item, pIndex_, i)) - }) - } - return h(SubMenu, { key: menu.path ? menu.path : 'submenu_' + pIndex + '_' + index }, subItem.concat(itemArr)) - }, - renderItem: function (h, menu, pIndex, index) { - if (!menu.hidden) { - return menu.children && !menu.hideChildrenInMenu - ? this.renderSubMenu(h, menu, pIndex, index) - : this.renderMenuItem(h, menu, pIndex, index) - } - }, - renderMenu: function (h, menuTree) { - const this2_ = this - const menuArr = [] - menuTree.forEach(function (menu, i) { - if (!menu.hidden) { - menuArr.push(this2_.renderItem(h, menu, '0', i)) - } - }) - return menuArr - }, - onOpenChange (openKeys) { - const latestOpenKey = openKeys.find(key => !this.openKeys.includes(key)) - if (!this.rootSubmenuKeys.includes(latestOpenKey)) { - this.openKeys = openKeys - } else { - this.openKeys = latestOpenKey ? [latestOpenKey] : [] - } - }, - updateMenu () { - const routes = this.$route.matched.concat() - - if (routes.length >= 4 && this.$route.meta.hidden) { - routes.pop() - this.selectedKeys = [routes[2].path] - } else { - this.selectedKeys = [routes.pop().path] - } - - const openKeys = [] - if (this.mode === 'inline') { - routes.forEach(item => { - openKeys.push(item.path) - }) - } - - this.collapsed ? (this.cachedOpenKeys = openKeys) : (this.openKeys = openKeys) - } - }, - render (h) { - return h( - Menu, - { - props: { - theme: this.$props.theme, - mode: this.$props.mode, - openKeys: this.openKeys, - selectedKeys: this.selectedKeys - }, - on: { - openChange: this.onOpenChange, - select: obj => { - this.selectedKeys = obj.selectedKeys - this.$emit('select', obj) - } - } - }, - this.renderMenu(h, this.menu) - ) - } -} diff --git a/src/components/PageHeader/PageHeader.vue b/src/components/PageHeader/PageHeader.vue deleted file mode 100644 index 80e686e..0000000 --- a/src/components/PageHeader/PageHeader.vue +++ /dev/null @@ -1,202 +0,0 @@ - - - - - - - - - {{ title }} - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/src/components/PageHeader/index.js b/src/components/PageHeader/index.js deleted file mode 100644 index ec1078c..0000000 --- a/src/components/PageHeader/index.js +++ /dev/null @@ -1,2 +0,0 @@ -import PageHeader from './PageHeader' -export default PageHeader diff --git a/src/components/PasswordForm/index.vue b/src/components/PasswordForm/index.vue deleted file mode 100644 index d82e8e2..0000000 --- a/src/components/PasswordForm/index.vue +++ /dev/null @@ -1,102 +0,0 @@ - - - - - - - - - - - - - - - - - - - - 取消 - 保存 - - - - - diff --git a/src/components/Result/Result.vue b/src/components/Result/Result.vue deleted file mode 100644 index 99f7f19..0000000 --- a/src/components/Result/Result.vue +++ /dev/null @@ -1,109 +0,0 @@ - - - - - - - - {{ title }} - - - - - {{ description }} - - - - - - - - - - - - - - diff --git a/src/components/Result/index.js b/src/components/Result/index.js deleted file mode 100644 index 51cb3b2..0000000 --- a/src/components/Result/index.js +++ /dev/null @@ -1,2 +0,0 @@ -import Result from './Result.vue' -export default Result diff --git a/src/components/SelectLang/index.jsx b/src/components/SelectLang/index.jsx index 6115d8d..b587427 100644 --- a/src/components/SelectLang/index.jsx +++ b/src/components/SelectLang/index.jsx @@ -4,15 +4,19 @@ import { Icon, Menu, Dropdown } from 'ant-design-vue' import { i18nRender } from '@/locales' import i18nMixin from '@/store/i18n-mixin' -const locales = ['zh-CN', 'en-US'] +const locales = ['zh-CN', 'zh-TW', 'en-US', 'pt-BR'] const languageLabels = { 'zh-CN': '简体中文', - 'en-US': 'English' + 'zh-TW': '繁体中文', + 'en-US': 'English', + 'pt-BR': 'Português' } // eslint-disable-next-line const languageIcons = { 'zh-CN': '🇨🇳', - 'en-US': '🇺🇸' + 'zh-TW': '🇭🇰', + 'en-US': '🇺🇸', + 'pt-BR': '🇧🇷' } const SelectLang = { diff --git a/src/components/SettingDrawer/SettingDrawer.vue b/src/components/SettingDrawer/SettingDrawer.vue index 9b2c83f..a21e96c 100644 --- a/src/components/SettingDrawer/SettingDrawer.vue +++ b/src/components/SettingDrawer/SettingDrawer.vue @@ -176,7 +176,6 @@ import config from '@/config/defaultSettings' import { updateTheme, updateColorWeak, colorList } from './settingConfig' export default { - name: 'SettingDrawer', components: { SettingItem }, @@ -270,17 +269,22 @@ export default { diff --git a/src/components/tools/DetailList.vue b/src/components/tools/DetailList.vue deleted file mode 100644 index 6745a08..0000000 --- a/src/components/tools/DetailList.vue +++ /dev/null @@ -1,5 +0,0 @@ - diff --git a/src/components/tools/LangSelect.vue b/src/components/tools/LangSelect.vue deleted file mode 100644 index 283f356..0000000 --- a/src/components/tools/LangSelect.vue +++ /dev/null @@ -1,46 +0,0 @@ - - - - - - - - - 🇨🇳 简体中文 - - - - - 🇭🇰 繁体中文 - - - - - 🇬🇧 English - - - - - 🇧🇷 Português - - - - - - - diff --git a/src/components/tools/Logo.vue b/src/components/tools/Logo.vue deleted file mode 100644 index 16d2090..0000000 --- a/src/components/tools/Logo.vue +++ /dev/null @@ -1,31 +0,0 @@ - - - - - {{ title }} - - - - - diff --git a/src/components/tools/UserMenu.vue b/src/components/tools/UserMenu.vue deleted file mode 100644 index ac867cd..0000000 --- a/src/components/tools/UserMenu.vue +++ /dev/null @@ -1,81 +0,0 @@ - - - - - - - - - - - - - {{ nickname }} - - - - - - 个人中心 - - - - - - 账户设置 - - - - - 测试 - - - - - - 退出登录 - - - - - - - - - diff --git a/src/components/tools/index.js b/src/components/tools/index.js deleted file mode 100644 index e69de29..0000000 diff --git a/src/config/router.config.js b/src/config/router.config.js index a59010a..6e96a91 100644 --- a/src/config/router.config.js +++ b/src/config/router.config.js @@ -31,56 +31,34 @@ export const asyncRouterMap = [ } ] }, - // brand + // 权限管理 { - path: '/brand', - name: 'brand', - redirect: '/brand/list', + path: '/security', + name: 'security', + redirect: '/security/user', component: RouteView, - meta: { title: '基础配置', keepAlive: true, icon: bxAnaalyse, permission: [ 'brand' ] }, + meta: { title: '系统设置', keepAlive: true, icon: bxAnaalyse, permission: [ 'security' ] }, children: [ { - path: '/brand/list', - name: 'BrandList', - component: () => import('@/views/brand/BrandList'), - meta: { title: '品牌管理', keepAlive: true, permission: [ 'brand' ] } + path: '/security/user', + name: 'SecurityUser', + component: () => import('@/views/security/user/UserList'), + meta: { title: '用户管理', keepAlive: true, permission: [ 'security' ] } + }, + { + path: '/security/role', + name: 'SecurityRole', + component: () => import('@/views/security/role/RoleList'), + meta: { title: '角色管理', keepAlive: true } + }, + { + path: '/security/resource', + name: 'SecurityResource', + component: () => import('@/views/security/resource/ResourceTree'), + meta: { title: '菜单管理', keepAlive: true } } ] }, - // 权限管理 - // { - // path: '/security', - // name: 'security', - // redirect: '/security/user', - // component: RouteView, - // meta: { title: '系统设置', keepAlive: true, icon: bxAnaalyse, permission: [ 'security' ] }, - // children: [ - // { - // path: '/security/user', - // name: 'SecurityUser', - // component: () => import('@/views/security/UserList'), - // meta: { title: '用户管理', keepAlive: true, permission: [ 'security' ] } - // }, - // { - // path: '/security/role', - // name: 'SecurityRole', - // component: () => import('@/views/security/Role'), - // meta: { title: '角色管理', keepAlive: true } - // }, - // { - // path: '/security/system', - // name: 'SecuritySystem', - // component: () => import('@/views/security/System'), - // meta: { title: '系统角色管理', keepAlive: true } - // }, - // { - // path: '/security/list/permission', - // name: 'SecurityPermission', - // component: () => import('@/views/security/Permission'), - // meta: { title: '权限列表', keepAlive: true } - // } - // ] - // }, // forms { path: '/form', @@ -88,12 +66,12 @@ export const asyncRouterMap = [ component: RouteView, meta: { title: '表单页', icon: 'form', permission: [ 'form' ] }, children: [ - // { - // path: '/form/base-form', - // name: 'BaseForm', - // component: () => import('@/views/form/basicForm/index'), - // meta: { title: '基础表单', keepAlive: true, permission: [ 'form' ] } - // }, + { + path: '/form/base-form', + name: 'BaseForm', + component: () => import('@/views/form/basicForm/Index'), + meta: { title: '基础表单', keepAlive: true, permission: [ 'form' ] } + }, { path: '/form/step-form', name: 'StepForm', @@ -173,12 +151,12 @@ export const asyncRouterMap = [ redirect: '/profile/basic', meta: { title: '详情页', icon: 'profile', permission: [ 'profile' ] }, children: [ - // { - // path: '/profile/basic', - // name: 'ProfileBasic', - // component: () => import('@/views/profile/basic/index'), - // meta: { title: '基础详情页', permission: [ 'profile' ] } - // }, + { + path: '/profile/basic', + name: 'ProfileBasic', + component: () => import('@/views/profile/basic/Index'), + meta: { title: '基础详情页', permission: [ 'profile' ] } + }, { path: '/profile/advanced', name: 'ProfileAdvanced', @@ -245,12 +223,12 @@ export const asyncRouterMap = [ name: 'account', meta: { title: '个人页', icon: 'user', keepAlive: true, permission: [ 'user' ] }, children: [ - // { - // path: '/account/center', - // name: 'center', - // component: () => import('@/views/account/center/Index'), - // meta: { title: '个人中心', keepAlive: true, permission: [ 'user' ] } - // }, + { + path: '/account/center', + name: 'center', + component: () => import('@/views/account/center/Index'), + meta: { title: '个人中心', keepAlive: true, permission: [ 'user' ] } + }, { path: '/account/settings', name: 'settings', @@ -373,7 +351,17 @@ export const constantRouterMap = [ { path: 'login', name: 'login', - component: () => import('@/views/security/user/UserLogin') + component: () => import(/* webpackChunkName: "user" */ '@/views/user/Login') + }, + { + path: 'register', + name: 'register', + component: () => import(/* webpackChunkName: "user" */ '@/views/user/Register') + }, + { + path: 'register-result', + name: 'registerResult', + component: () => import(/* webpackChunkName: "user" */ '@/views/user/RegisterResult') }, { path: 'recover', @@ -382,20 +370,6 @@ export const constantRouterMap = [ } ] }, - { - path: '/brand', - component: BasicLayout, - redirect: '/brand/list', - meta: { title: '品牌管理' }, - children: [ - { - path: 'detail/:id', - name: 'BrandDetail', - component: () => import('@/views/brand/BrandDetail'), - meta: { title: '品牌详情', keepAlive: true, permission: [ 'brand' ] } - } - ] - }, { path: '/404', component: () => import(/* webpackChunkName: "fail" */ '@/views/exception/404') diff --git a/src/core/bootstrap.js b/src/core/bootstrap.js index d0a572a..6588bde 100644 --- a/src/core/bootstrap.js +++ b/src/core/bootstrap.js @@ -1,22 +1,20 @@ import store from '@/store' import storage from 'store' import { - LOGIN_TOKEN, - USER_INFO, + ACCESS_TOKEN, APP_LANGUAGE, TOGGLE_CONTENT_WIDTH, TOGGLE_FIXED_HEADER, - TOGGLE_FIXED_SIDEBAR, - TOGGLE_HIDE_HEADER, - TOGGLE_LAYOUT, - TOGGLE_NAV_THEME, - TOGGLE_WEAK, - TOGGLE_COLOR, - TOGGLE_MULTI_TAB + TOGGLE_FIXED_SIDEBAR, TOGGLE_HIDE_HEADER, + TOGGLE_LAYOUT, TOGGLE_NAV_THEME, TOGGLE_WEAK, + TOGGLE_COLOR, TOGGLE_MULTI_TAB } from '@/store/mutation-types' +// import { printANSI } from '@/utils/screenLog' import defaultSettings from '@/config/defaultSettings' export default function Initializer () { + // printANSI() // 请自行移除该行. please remove this line + store.commit(TOGGLE_LAYOUT, storage.get(TOGGLE_LAYOUT, defaultSettings.layout)) store.commit(TOGGLE_FIXED_HEADER, storage.get(TOGGLE_FIXED_HEADER, defaultSettings.fixedHeader)) store.commit(TOGGLE_FIXED_SIDEBAR, storage.get(TOGGLE_FIXED_SIDEBAR, defaultSettings.fixSiderbar)) @@ -26,7 +24,8 @@ export default function Initializer () { store.commit(TOGGLE_WEAK, storage.get(TOGGLE_WEAK, defaultSettings.colorWeak)) store.commit(TOGGLE_COLOR, storage.get(TOGGLE_COLOR, defaultSettings.primaryColor)) store.commit(TOGGLE_MULTI_TAB, storage.get(TOGGLE_MULTI_TAB, defaultSettings.multiTab)) - store.commit('SET_LOGIN_TOKEN', storage.get(LOGIN_TOKEN)) - store.commit('SET_USER_INFO', storage.get(USER_INFO)) + store.commit('SET_TOKEN', storage.get(ACCESS_TOKEN)) + store.dispatch('setLang', storage.get(APP_LANGUAGE, 'en-US')) + // last step } diff --git a/src/core/lazy_use.js b/src/core/lazy_use.js index 6ef5725..c06e94a 100644 --- a/src/core/lazy_use.js +++ b/src/core/lazy_use.js @@ -19,6 +19,7 @@ import { Table, Tabs, Icon, + Badge, Popover, Dropdown, List, @@ -34,17 +35,16 @@ import { Divider, DatePicker, TimePicker, + Upload, Progress, + Skeleton, Popconfirm, PageHeader, Result, + Statistic, Descriptions, message, - notification, - FormModel, - Tree, - TreeSelect, - Collapse + notification } from 'ant-design-vue' import Viser from 'viser-vue' @@ -73,6 +73,7 @@ Vue.use(Modal) Vue.use(Table) Vue.use(Tabs) Vue.use(Icon) +Vue.use(Badge) Vue.use(Popover) Vue.use(Dropdown) Vue.use(List) @@ -88,15 +89,14 @@ Vue.use(Tag) Vue.use(Divider) Vue.use(DatePicker) Vue.use(TimePicker) +Vue.use(Upload) Vue.use(Progress) +Vue.use(Skeleton) Vue.use(Popconfirm) Vue.use(PageHeader) Vue.use(Result) +Vue.use(Statistic) Vue.use(Descriptions) -Vue.use(FormModel) -Vue.use(Tree) -Vue.use(TreeSelect) -Vue.use(Collapse) Vue.prototype.$confirm = Modal.confirm Vue.prototype.$message = message diff --git a/src/core/use.js b/src/core/use.js index e5dc657..ba2eca2 100644 --- a/src/core/use.js +++ b/src/core/use.js @@ -7,21 +7,21 @@ import VueCropper from 'vue-cropper' import 'ant-design-vue/dist/antd.less' // ext library -// import VueClipboard from 'vue-clipboard2' -// import MultiTab from '@/components/MultiTab' +import VueClipboard from 'vue-clipboard2' +import MultiTab from '@/components/MultiTab' import PageLoading from '@/components/PageLoading' -// import PermissionHelper from '@/utils/helper/permission' +import PermissionHelper from '@/utils/helper/permission' // import '@/components/use' -// import './directives/action' +import './directives/action' VueClipboard.config.autoSetContainer = true Vue.use(Antd) Vue.use(Viser) -// Vue.use(MultiTab) +Vue.use(MultiTab) Vue.use(PageLoading) -// Vue.use(VueClipboard) -// Vue.use(PermissionHelper) +Vue.use(VueClipboard) +Vue.use(PermissionHelper) Vue.use(VueCropper) process.env.NODE_ENV !== 'production' && console.warn('[antd-pro] WARNING: Antd now use fulled imported.') diff --git a/src/global.less b/src/global.less index 8613467..8d3699f 100644 --- a/src/global.less +++ b/src/global.less @@ -33,9 +33,6 @@ ol { .ant-btn + .ant-btn { margin-left: 8px; } -.ant-btn-right{ - float: right; -} // 数据列表 样式 .table-alert { margin-bottom: 16px; @@ -93,9 +90,6 @@ ol { } } } -.ant-drawer-body{ - padding-bottom: 53px; -} .draw-button-container { position: absolute; right: 0; @@ -104,7 +98,7 @@ ol { border-top: 1px solid #e9e9e9; padding: 10px 16px; background: #fff; - z-index: 1000; + z-index: 1; text-align: right; &.align-center { text-align: center; diff --git a/src/layouts/BasicLayout.vue b/src/layouts/BasicLayout.vue index 67679aa..99d09f6 100644 --- a/src/layouts/BasicLayout.vue +++ b/src/layouts/BasicLayout.vue @@ -11,9 +11,11 @@ :i18nRender="i18nRender" v-bind="settings" > + + @@ -22,20 +24,25 @@ diff --git a/src/views/brand/BrandList.vue b/src/views/brand/BrandList.vue deleted file mode 100644 index 7bd553b..0000000 --- a/src/views/brand/BrandList.vue +++ /dev/null @@ -1,173 +0,0 @@ - - - - - - - - - - - - - - - 全部 - {{item}} - - - - - 查询 - {queryParam = {}, handleFefresh()}">重置 - - - 新增 - - - - - - {{record.createdAt | moment}} - - - - - 修改 - - handleDelete(record)"> - 删除 - - - 跳转详情 - - 弹框详情 - - - - - - - - - diff --git a/src/views/brand/modules/BrandDetail.vue b/src/views/brand/modules/BrandDetail.vue deleted file mode 100644 index 1b7081c..0000000 --- a/src/views/brand/modules/BrandDetail.vue +++ /dev/null @@ -1,48 +0,0 @@ - - - - {{ model.name }} - {{ model.code }} - {{ model.createdAt | moment('YYYY-MM-DD') }} - {{ model.updatedAt }} - {{ model.status | statusFilter }} - {{ model.sortOrder }} - - - - - diff --git a/src/views/brand/modules/CreateForm.vue b/src/views/brand/modules/CreateForm.vue deleted file mode 100644 index 55903b2..0000000 --- a/src/views/brand/modules/CreateForm.vue +++ /dev/null @@ -1,83 +0,0 @@ - - - - 取消 - 保存 - - - - - - - - - - diff --git a/src/views/dashboard/Analysis.vue b/src/views/dashboard/Analysis.vue deleted file mode 100644 index cd20183..0000000 --- a/src/views/dashboard/Analysis.vue +++ /dev/null @@ -1,417 +0,0 @@ - - - - - - - - - - - 周同比 - 12% - - - 日同比 - 11% - - - 日均销售额¥ 234.56 - - - - - - - - - - - 日访问量 {{ '1234' | NumberFormat }} - - - - - - - - - - - 转化率 60% - - - - - - - - - - - - - 同周比 - 12% - - - 日环比 - 80% - - - - - - - - - - - - 今日 - 本周 - 本月 - 本年 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 操作一 - - - 操作二 - - - - - - - - 搜索用户数 - - - - - - - - - - - - - - 人均搜索次数 - - - - - - - - - - - - - - - - {{ text }}% - - - - - - - - - - - - - - - - 操作一 - - - 操作二 - - - - - - - 全部渠道 - 线上 - 门店 - - - - - 销售额 - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/src/views/dashboard/Monitor.vue b/src/views/dashboard/Monitor.vue deleted file mode 100644 index 2b9c6c1..0000000 --- a/src/views/dashboard/Monitor.vue +++ /dev/null @@ -1,15 +0,0 @@ - - - Monitor - - - - - - diff --git a/src/views/dashboard/TestWork.vue b/src/views/dashboard/TestWork.vue deleted file mode 100644 index ae80f93..0000000 --- a/src/views/dashboard/TestWork.vue +++ /dev/null @@ -1,117 +0,0 @@ - - - 本页面内容均为测试功能,暂不提供稳定性保证 - - - 多标签组件测试功能 - 关闭当前页 - 打开 任务列表 - - - - - - - - - - - visible = !visible" style="margin-right: 16px;">修改当前 Tab 名称 - - - visible2 = false" okText="确定" cancelText="取消"> - - - 页面 KEY 是由页面的路由 path 决定的 - 如果要修改某一个页面标题,该页面必须已经被打开在 Tab 栏 - 后期可以考虑优化到编程式 Tab 栏,就可以没有这种限制 - - - - - - - - - - - visible2 = !visible2">修改某一个 Tab 名称 - - - - - 全局遮罩测试 - 打开遮罩(5s 自动关闭) - 打开遮罩(自定义提示语) - - - - - - - diff --git a/src/views/login/index.vue b/src/views/login/index.vue deleted file mode 100644 index 3127309..0000000 --- a/src/views/login/index.vue +++ /dev/null @@ -1,77 +0,0 @@ - - - - 安全培训系统登录 - - - - - - - - - - - - 忘记密码 - 登 录 - - - - - - - - \ No newline at end of file diff --git a/src/views/security/maps/icons.js b/src/views/security/maps/icons.js deleted file mode 100644 index 6699a56..0000000 --- a/src/views/security/maps/icons.js +++ /dev/null @@ -1,17 +0,0 @@ -export const filledIcons = [{ - type: 'home' -}, { - type: 'account-book' -}, { - type: 'alert' -}, { - type: 'api' -}, { - type: 'appstore' -}, { - type: 'bell' -}, { - type: 'cloud' -}, { - type: 'edit' -}] diff --git a/src/views/security/maps/map.js b/src/views/security/maps/map.js index 5c06b43..d270ca6 100644 --- a/src/views/security/maps/map.js +++ b/src/views/security/maps/map.js @@ -1,6 +1,5 @@ export const typeMap = { 'CORPORATION': '公司', 'MALL': '门店', - 'STORE': '店长', - 'STAFF': '店员' + 'STORE': '店铺' } diff --git a/src/views/security/resource/FunctionResource.vue b/src/views/security/resource/FunctionResource.vue deleted file mode 100644 index ecbfc52..0000000 --- a/src/views/security/resource/FunctionResource.vue +++ /dev/null @@ -1,138 +0,0 @@ - - - - - - - - - - - - {{ item.name }} - - - - - - - - - - - - - - - - - - diff --git a/src/views/security/resource/ResourceTree.vue b/src/views/security/resource/ResourceTree.vue index 8087737..46fb64a 100644 --- a/src/views/security/resource/ResourceTree.vue +++ b/src/views/security/resource/ResourceTree.vue @@ -1,129 +1,186 @@ - - - - - - - - - - + + + + - - - - - - 新增根菜单 - 新增下级菜单 - 删除当前菜单 - 刷新缓存 - - - - - + + + + + 编辑 + + + + + 更多 + + + + 详情 + + + 禁用 + + + 删除 + + + + + - + + diff --git a/src/views/security/resource/modules/CreateForm.vue b/src/views/security/resource/modules/CreateForm.vue deleted file mode 100644 index 63d52fe..0000000 --- a/src/views/security/resource/modules/CreateForm.vue +++ /dev/null @@ -1,151 +0,0 @@ - - - - - - - - - - - - - - - - - {{ i.label }} - - - - - - - - - - - 启用 - 停用 - - - - - - - 保存 - 取消 - - - - - - - diff --git a/src/views/security/resource/modules/OrgModal.vue b/src/views/security/resource/modules/OrgModal.vue new file mode 100644 index 0000000..d83955c --- /dev/null +++ b/src/views/security/resource/modules/OrgModal.vue @@ -0,0 +1,100 @@ + + + + + + + + + + + + + + + + + + diff --git a/src/views/security/resource/modules/RoleModal.vue b/src/views/security/resource/modules/RoleModal.vue new file mode 100644 index 0000000..37bcd2a --- /dev/null +++ b/src/views/security/resource/modules/RoleModal.vue @@ -0,0 +1,147 @@ + + + + + + + Finished + + This is a description. + + + + + + + + + + diff --git a/src/views/security/role/RoleList.vue b/src/views/security/role/RoleList.vue index f239caf..5901776 100644 --- a/src/views/security/role/RoleList.vue +++ b/src/views/security/role/RoleList.vue @@ -1,75 +1,56 @@ - - - - - - - - - - - - - - - - - - - 全部 - {{ item }} - - - - - 查询 - {queryParam = {}, handleRefresh()}">重置 - - - 新增 - - - - - - {{ record.createdAt | moment }} - - - - - 修改 - - handleDelete(record)"> - 删除 - - - 详情 - - - - - - + + + + + + + + + + + + + 全部 + {{ item }} + + + + + 查询 + {queryParam = {}, handleFefresh()}">重置 + + + 新增 + + + + + + {{record.createdAt | moment}} + + + + + 修改 + + handleDelete(record)"> + 删除 + + + 详情 + + + + + diff --git a/src/views/security/role/RoleResource.vue b/src/views/security/role/RoleResource.vue deleted file mode 100644 index 5056d46..0000000 --- a/src/views/security/role/RoleResource.vue +++ /dev/null @@ -1,138 +0,0 @@ - - - - - - - - - - - - {{ item.name }} - - - - - - - - - - - - - - - - - - diff --git a/src/views/security/role/modules/CreateForm.vue b/src/views/security/role/modules/CreateForm.vue index 89aed8f..e6ce643 100644 --- a/src/views/security/role/modules/CreateForm.vue +++ b/src/views/security/role/modules/CreateForm.vue @@ -1,27 +1,6 @@ - + - - - - - - - @@ -31,8 +10,8 @@ - - + + @@ -40,13 +19,12 @@ 取消 保存 - - + diff --git a/src/views/security/role/modules/RoleDetail.vue b/src/views/security/role/modules/RoleDetail.vue index 4ea1c36..28a7e89 100644 --- a/src/views/security/role/modules/RoleDetail.vue +++ b/src/views/security/role/modules/RoleDetail.vue @@ -9,7 +9,7 @@ {{ model.name }} {{ model.description }} {{ model.createdAt | moment }} - {{ model.updatedAt | moment }} + {{ model.updatedAt | moment }} diff --git a/src/views/security/user/UserList.vue b/src/views/security/user/UserList.vue index 9c13366..1d7379a 100644 --- a/src/views/security/user/UserList.vue +++ b/src/views/security/user/UserList.vue @@ -6,48 +6,34 @@ - + - - - - - - + 全部 {{ item }} - 查询 - {queryParam = {}, handleRefresh()}">重置 - 新增 + 查询 + {queryParam = {}, handleFefresh()}">重置 + + + 新增 @@ -57,15 +43,11 @@ 详情 - 修改密码 - - 分配角色 + 修改密码 - - @@ -75,28 +57,21 @@ import { userPage, userUpdateEnabled } from '@/api/security/user' import { STable } from '@/components' import CreateForm from './modules/CreateForm' import UserDetail from './modules/UserDetail' -import UserRole from './modules/UserRole' -import OrgTree from './modules/OrgTree' -import PasswordForm from '@/components/PasswordForm' import { statusMap } from '@/views/status/statusMap' -import { orgTreeGet } from '@/api/bms/org' export default { name: 'UserList', components: { STable, CreateForm, - UserDetail, - UserRole, - PasswordForm, - OrgTree + UserDetail }, data () { return { - isShowOrg: false, statusMap: statusMap, - orgData: [], - queryParam: { realName: '', enabled: '', orgId: '' }, + queryParam: { realName: '', enabled: '' }, + selectedRowKeys: [], // 选中行的key 出选择框时需要配置 + selectedRows: [], // 选中行的数据 columns: [ { title: '名称', width: 40, dataIndex: 'realName', key: 'realName' }, { title: '手机号', width: 40, dataIndex: 'mobile', key: 'mobile' }, @@ -117,17 +92,26 @@ export default { } ], loadData: parameter => { - return userPage(Object.assign(parameter, this.queryParam)) + const enabled = this.queryParam.enabled + const queryParam = { + realName: this.queryParam.realName, + enabled: enabled === '1' ? true : enabled === '0' ? false : '' + } + return userPage(Object.assign(parameter, queryParam)) .then(res => { - const data = res.data - data.entities.forEach((item) => { - item.status = item.status === 1 - }) - return data + return res.data }) } } }, + computed: { + rowSelection () { + return { + selectedRowKeys: this.selectedRowKeys, + onChange: this.onSelectChange + } + } + }, methods: { // 修改状态 updateStatus (id, status) { @@ -143,10 +127,6 @@ export default { this.$refs.table.refresh() }) }, - // 分配角色 - handleRole (userId) { - this.$refs.role.show(userId) - }, // 增 handleCreate () { this.$refs.modal.add() @@ -163,20 +143,14 @@ export default { handleDetail (id) { this.$refs.detail.show(id) }, - handlePassword (id) { - this.$refs.password.show(id) - }, - handleRefresh () { + handleFefresh () { this.$refs.table.refresh(true) }, - loadOrg () { - orgTreeGet({ treeLevel: 'MALL' }).then(data => { - this.orgData = data.data - }) + // 选择行 + onSelectChange (selectedRowKeys, selectedRows) { + this.selectedRowKeys = selectedRowKeys + this.selectedRows = selectedRows } - }, - mounted () { - this.loadOrg() } } diff --git a/src/views/security/user/UserLogin.vue b/src/views/security/user/UserLogin.vue deleted file mode 100644 index 62ae41e..0000000 --- a/src/views/security/user/UserLogin.vue +++ /dev/null @@ -1,80 +0,0 @@ - - - - - - - - - - - - - - - 登录 - - - - - - - - diff --git a/src/views/security/user/modules/CreateForm.vue b/src/views/security/user/modules/CreateForm.vue index df6ba08..3de5390 100644 --- a/src/views/security/user/modules/CreateForm.vue +++ b/src/views/security/user/modules/CreateForm.vue @@ -17,33 +17,6 @@ - - - - - - 公司管理员 - - - 门店管理员 - - - 店长 - - - 店员 - - - - - - - - - - - - @@ -57,35 +30,28 @@ 取消 保存 - - - diff --git a/src/views/security/user/modules/UserDetail.vue b/src/views/security/user/modules/UserDetail.vue index 1a7c87e..851792f 100644 --- a/src/views/security/user/modules/UserDetail.vue +++ b/src/views/security/user/modules/UserDetail.vue @@ -9,11 +9,11 @@ {{ model.username }} {{ model.realName }} {{ model.createdAt | moment }} - {{ model.updatedAt | moment }} + {{ model.updatedAt | moment }} {{ model.enabled | statusFilter }} {{ model.mobile }} {{ model.orgName }} - {{ model.type | typeFilter }} + {{ model.type | typeFilter}} {{ model.address }} {{ model.email }} @@ -23,7 +23,7 @@ - diff --git a/src/views/user/Login.vue b/src/views/user/Login.vue index d31d98a..fdf88b0 100644 --- a/src/views/user/Login.vue +++ b/src/views/user/Login.vue @@ -7,68 +7,33 @@ :form="form" @submit="handleSubmit" > - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + 自动登录 确定 - - - 其他登录方式 - - - - - - - - - - 注册账户 - - -
页面 KEY 是由页面的路由 path 决定的
path
如果要修改某一个页面标题,该页面必须已经被打开在 Tab 栏
后期可以考虑优化到编程式 Tab 栏,就可以没有这种限制