2024-05-06 14:57:20 +08:00
|
|
|
|
import appTitle from "./CommonInput/app-title.vue";
|
|
|
|
|
import Composite from "./CommonInput/Composite.vue";
|
|
|
|
|
import Compound from "./CommonInput/Compound.vue";
|
|
|
|
|
import ErpEchart from "./CommonInput/ErpEchart.vue";
|
|
|
|
|
import MoreClass from "./CommonInput/MoreClass.vue";
|
|
|
|
|
import MoreScreen from "./CommonInput/MoreScreen.vue";
|
|
|
|
|
import selectbtn from "./CommonInput/selectbtn.vue";
|
|
|
|
|
import TimingModule from "./CommonInput/TimingModule.vue";
|
|
|
|
|
|
|
|
|
|
const componentarr = [
|
|
|
|
|
appTitle,
|
|
|
|
|
Composite,
|
|
|
|
|
Compound,
|
|
|
|
|
ErpEchart,
|
|
|
|
|
MoreClass,
|
|
|
|
|
MoreScreen,
|
|
|
|
|
selectbtn,
|
|
|
|
|
TimingModule,
|
|
|
|
|
];
|
|
|
|
|
|
|
|
|
|
const install = function (Vue) {
|
|
|
|
|
// 判断是否安装
|
|
|
|
|
if (install.installed) return;
|
|
|
|
|
install.installed = true;
|
|
|
|
|
// 遍历并注册全局组件
|
|
|
|
|
componentarr.forEach((component) => Vue.component(component.name, component));
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
// 判断是否是直接引入文件,如果Vue是全局对象自动安装插件
|
|
|
|
|
if (typeof window !== "undefined" && window.Vue) {
|
|
|
|
|
install(window.Vue);
|
|
|
|
|
}
|
|
|
|
|
export default {
|
|
|
|
|
install,
|
|
|
|
|
...componentarr
|
2024-05-06 15:09:08 +08:00
|
|
|
|
}
|
|
|
|
|
|