提交merge1.3
This commit is contained in:
@@ -1,38 +1,10 @@
|
||||
import { createApp } from 'vue';
|
||||
|
||||
<<<<<<< HEAD
|
||||
// 修复 util._extend 已弃用警告(仅在 Node.js 环境中需要)
|
||||
if (typeof process !== 'undefined' && process.versions && process.versions.node) {
|
||||
try {
|
||||
import('util').then(util => {
|
||||
if (!util._extend) {
|
||||
util._extend = function(destination, source) {
|
||||
for (var key in source) {
|
||||
if (source.hasOwnProperty(key)) {
|
||||
destination[key] = source[key];
|
||||
}
|
||||
}
|
||||
return destination;
|
||||
};
|
||||
}
|
||||
});
|
||||
} catch (e) {
|
||||
console.error('util._extend 补丁加载失败:', e);
|
||||
}
|
||||
}
|
||||
|
||||
import Cookies from 'js-cookie'
|
||||
|
||||
import ElementPlus from 'element-plus'
|
||||
import zhCn from 'element-plus/es/locale/lang/zh-cn'
|
||||
import 'element-plus/dist/index.css'
|
||||
=======
|
||||
import Cookies from 'js-cookie';
|
||||
|
||||
// 导入 hiprint 并挂载到全局 window 对象
|
||||
import { hiprint } from 'vue-plugin-hiprint';
|
||||
window.hiprint = hiprint;
|
||||
>>>>>>> v1.3
|
||||
|
||||
import ElementPlus from 'element-plus';
|
||||
import zhCn from 'element-plus/es/locale/lang/zh-cn';
|
||||
@@ -47,13 +19,8 @@ import router from './router';
|
||||
import directive from './directive'; // directive
|
||||
|
||||
// 注册指令
|
||||
<<<<<<< HEAD
|
||||
import plugins from './plugins' // plugins
|
||||
import { download, downloadGet } from '@/utils/request'
|
||||
=======
|
||||
import plugins from './plugins'; // plugins
|
||||
import { download, downloadGet } from '@/utils/request';
|
||||
>>>>>>> v1.3
|
||||
|
||||
// svg图标
|
||||
import 'virtual:svg-icons-register';
|
||||
@@ -108,48 +75,6 @@ if (chrome.webview !== undefined) {
|
||||
}
|
||||
|
||||
// 全局方法挂载
|
||||
<<<<<<< HEAD
|
||||
app.config.globalProperties.useDict = useDict
|
||||
app.config.globalProperties.download = download
|
||||
app.config.globalProperties.downloadGet = downloadGet
|
||||
app.config.globalProperties.parseTime = parseTime
|
||||
app.config.globalProperties.resetForm = resetForm
|
||||
app.config.globalProperties.handleTree = handleTree
|
||||
app.config.globalProperties.addDateRange = addDateRange
|
||||
app.config.globalProperties.selectDictLabel = selectDictLabel
|
||||
app.config.globalProperties.selectDictLabels = selectDictLabels
|
||||
app.config.globalProperties.formatDateStr = formatDateStr
|
||||
|
||||
// 全局挂载请求实例
|
||||
app.config.globalProperties.$http = request
|
||||
// 全局组件挂载
|
||||
app.component('DictTag', DictTag)
|
||||
app.component('Pagination', Pagination)
|
||||
app.component('TreeSelect', TreeSelect)
|
||||
app.component('FileUpload', FileUpload)
|
||||
app.component('ImageUpload', ImageUpload)
|
||||
app.component('ImagePreview', ImagePreview)
|
||||
app.component('RightToolbar', RightToolbar)
|
||||
app.component('Editor', Editor)
|
||||
// 使用element-plus 并且设置全局的大小
|
||||
app.use(ElementPlus, {
|
||||
locale: zhCn,
|
||||
// 支持 large、default、small
|
||||
size: Cookies.get('size') || 'default'
|
||||
})
|
||||
app.use(ElMessage)
|
||||
app.use(registerComponents)
|
||||
app.use(router)
|
||||
app.use(store)
|
||||
app.use(plugins)
|
||||
app.use(elementIcons)
|
||||
app.component('svg-icon', SvgIcon)
|
||||
directive(app)
|
||||
// 全局禁止点击遮罩层关闭弹窗
|
||||
ElDialog.props.closeOnClickModal.default = false;
|
||||
|
||||
app.mount('#app')
|
||||
=======
|
||||
app.config.globalProperties.useDict = useDict;
|
||||
app.config.globalProperties.download = download;
|
||||
app.config.globalProperties.downloadGet = downloadGet;
|
||||
@@ -187,4 +112,3 @@ app.use(ElementPlus, {
|
||||
});
|
||||
|
||||
app.mount('#app');
|
||||
>>>>>>> v1.3
|
||||
|
||||
Reference in New Issue
Block a user