Files
wms1.0/mes/qd/src/main.js

76 lines
2.0 KiB
JavaScript
Raw Normal View History

2022-06-27 19:25:41 +08:00
import Vue from 'vue'
import Cookies from 'js-cookie'
import 'normalize.css/normalize.css'
import Element from 'element-ui'
// 列自适应宽度:https://github.com/legendJaden/AFTableColumn
import AFTableColumn from 'af-table-column'
import 'font-awesome/css/font-awesome.css'
// vue中markdown编辑器
import mavonEditor from 'mavon-editor'
import 'mavon-editor/dist/css/index.css'
// 数据字典
import dict from './components/Dict'
import scroll from 'vue-seamless-scroll'
// 权限指令
import permission from './components/Permission'
import './assets/styles/element-variables.scss'
// global css
import './assets/styles/index.scss'
// 代码高亮
import VueHighlightJS from 'vue-highlightjs'
import 'highlight.js/styles/atom-one-dark.css'
import App from './App'
import store from './store'
import router from './router/routers'
import './assets/icons' // icon
import './router/index' // permission control
import 'echarts-gl'
2023-03-14 15:57:53 +08:00
import { addDateRange, handleTree, parseTime, resetForm, selectDictLabel, selectDictLabels, flexWidth } from '@/utils/nladmin'
import { getValueByCode } from '@/api/system/param'
2022-06-27 19:25:41 +08:00
import 'jquery'
Vue.use(scroll)
Vue.use(AFTableColumn)
Vue.use(VueHighlightJS)
Vue.use(mavonEditor)
Vue.use(permission)
Vue.use(dict)
2022-07-13 14:10:37 +08:00
// 全局设置控件样式https://codeantenna.com/a/0IN5FMJk5h
Element.Table.props.border = { type: Boolean, default: true }
2022-07-16 11:41:46 +08:00
Element.TableColumn.props.align = { type: String, default: 'center' }
2022-06-27 19:25:41 +08:00
Vue.use(Element, {
2022-07-13 14:10:37 +08:00
size: Cookies.get('size') || 'mini' // set element-ui default size
2022-06-27 19:25:41 +08:00
})
Vue.config.productionTip = false
2023-03-14 15:57:53 +08:00
// 全局方法挂载
Vue.prototype.parseTime = parseTime
Vue.prototype.resetForm = resetForm
Vue.prototype.addDateRange = addDateRange
Vue.prototype.selectDictLabel = selectDictLabel
Vue.prototype.selectDictLabels = selectDictLabels
Vue.prototype.handleTree = handleTree
Vue.prototype.getValueByCode = getValueByCode
Vue.prototype.flexWidth = flexWidth
2022-06-27 19:25:41 +08:00
new Vue({
el: '#app',
router,
store,
render: h => h(App)
})