9b1f26ea by xiaomiao

人员管理模块开发

1 parent b00b06ce
......@@ -2,16 +2,28 @@ module.exports = {
presets: [
// https://github.com/vuejs/vue-cli/tree/master/packages/@vue/babel-preset-app
// '@vue/cli-plugin-babel/preset'
[
"@vue/app",
{
"useBuiltIns": "entry",
polyfills: [
'es6.promise',
'es6.symbol'
{
"plugins": [
[
"import",
{
"libraryName": "vxe-table",
"style": true // 样式是否也按需加载
}
],
[
"@vue/app",
{
"useBuiltIns": "entry",
polyfills: [
'es6.promise',
'es6.symbol'
]
}
]
}
]
]
}
],
'env': {
'development': {
......
......@@ -21,7 +21,8 @@
"vue": "2.6.10",
"vue-awesome": "^4.5.0",
"vue-router": "3.0.2",
"vuex": "3.1.0"
"vuex": "3.1.0",
"xe-utils": "^3.5.7"
},
"devDependencies": {
"@vue/cli-plugin-babel": "4.4.4",
......@@ -42,7 +43,9 @@
"style-resources-loader": "^1.4.1",
"svg-sprite-loader": "4.1.3",
"svgo": "^2.3.1",
"vue-template-compiler": "2.6.10"
"vue-template-compiler": "2.6.10",
"vxe-table": "^3.6.9",
"vxe-table-plugin-element": "^1.11.2"
},
"browserslist": [
"> 1%",
......
import Vue from 'vue'
import XEUtils from 'xe-utils'
import VXETablePluginElement from 'vxe-table-plugin-element'
import {
VXETable,
Icon,
Header,
Column,
Table,
Colgroup,
Input,
Select,
Edit,
Keyboard,
Toolbar,
Tooltip
} from 'vxe-table'
import zhCNLocat from 'vxe-table/lib/locale/lang/zh-CN'
import 'vxe-table-plugin-element/dist/style.css'
// 导入默认的国际化(如果项目中使用多语言,则应该导入到 vue-i18n 中)
VXETable.setup({
i18n: (key, args) => XEUtils.toFormatString(XEUtils.get(zhCNLocat, key), args)
})
Vue.use(Icon)
Vue.use(Header)
Vue.use(Toolbar)
Vue.use(Tooltip)
Vue.use(Column)
Vue.use(Colgroup)
Vue.use(Input)
Vue.use(Edit)
Vue.use(Select)
Vue.use(Keyboard)
Vue.use(Table)
Vue.use(VXETable)
VXETable.use(VXETablePluginElement)
......@@ -10,6 +10,7 @@ import dataV from '@jiaminghi/data-view';
import echarts from "echarts"
import { startLoadingAddCount, endLoadingSubCount } from './utils/requestLoading'
Vue.mixin(mixin)
import './directive/vxe-table'
// 按需引入vue-awesome图标
import Icon from 'vue-awesome/components/Icon';
import 'vue-awesome/icons/chart-bar.js';
......