import type { App } from 'vue'; import * as components from './components'; export * from './components'; export const install = function (app: App) { Object.keys(components).forEach((key) => { const component = components[key]; //console.log('install()🚀 ~ components.forEach ~ item:', key, component); if (component.install) { app.use(component); } }); return app; }; export const getViews = function () { // @ts-ignore return Object.assign({ './src/views/DataCollect/Channel/index.vue': () => import('./DataCollect/Channel/index.vue'), './src/views/DataCollect/Collector/index.vue': () => import('./DataCollect/Collector/index.vue'), './src/views/DataCollect/Dashboard/index.vue': () => import('./DataCollect/Dashboard/index.vue'), './src/views/device/Category/index.vue': () => import('./device/Category/index.vue'), './src/views/device/DashBoard/index.vue': () => import('./device/DashBoard/index.vue'), './src/views/device/Firmware/index.vue': () => import('./device/Firmware/index.vue'), './src/views/device/Instance/index.vue': () => import('./device/Instance/index.vue'), './src/views/device/Product/index.vue': () => import('./device/Product/index.vue'), './src/views/deviceaccess/modbus/index.vue': () => import('./deviceaccess/modbus/index.vue'), './src/views/deviceaccess/modbusitem/index.vue': () => import('./deviceaccess/modbusitem/index.vue'), './src/views/deviceaccess/opcua/index.vue': () => import('./deviceaccess/opcua/index.vue'), './src/views/deviceaccess/opcuaitem/index.vue': () => import('./deviceaccess/opcuaitem/index.vue'), './src/views/link/AccessConfig/index.vue': () => import('./link/AccessConfig/index.vue'), './src/views/link/Certificate/index.vue': () => import('./link/Certificate/index.vue'), './src/views/link/DashBoard/index.vue': () => import('./link/DashBoard/index.vue'), './src/views/link/Plugin/index.vue': () => import('./link/Plugin/index.vue'), './src/views/link/Protocol/index.vue': () => import('./link/Protocol/index.vue'), './src/views/link/Type/index.vue': () => import('./link/Type/index.vue'), './src/views/notice/Config/index.vue': () => import('./notice/Config/index.vue'), './src/views/notice/Template/index.vue': () => import('./notice/Template/index.vue'), './src/views/rule-engine/Alarm/Config/index.vue': () => import('./rule-engine/Alarm/Config/index.vue'), './src/views/rule-engine/Alarm/Configuration/index.vue': () => import('./rule-engine/Alarm/Configuration/index.vue'), './src/views/rule-engine/Alarm/Log/index.vue': () => import('./rule-engine/Alarm/Log/index.vue'), './src/views/rule-engine/DashBoard/index.vue': () => import('./rule-engine/DashBoard/index.vue'), './src/views/rule-engine/Instance/index.vue': () => import('./rule-engine/Instance/index.vue'), './src/views/rule-engine/Scene/index.vue': () => import('./rule-engine/Scene/index.vue'), './src/views/videoCenter/channel/index.vue': () => import('./videoCenter/channel/index.vue'), './src/views/videoCenter/cloudRecord/index.vue': () => import('./videoCenter/cloudRecord/index.vue'), './src/views/videoCenter/gbdevice/index.vue': () => import('./videoCenter/gbdevice/index.vue'), './src/views/videoCenter/mediaGateway/index.vue': () => import('./videoCenter/mediaGateway/index.vue'), './src/views/videoCenter/mediaServer/index.vue': () => import('./videoCenter/mediaServer/index.vue'), './src/views/videoCenter/parentPlatform/index.vue': () => import('./videoCenter/parentPlatform/index.vue'), './src/views/videoCenter/pushVideo/index.vue': () => import('./videoCenter/pushVideo/index.vue'), './src/views/videoCenter/realtimeMonitor/index.vue': () => import('./videoCenter/realtimeMonitor/index.vue'), './src/views/videoCenter/streamProxy/index.vue': () => import('./videoCenter/streamProxy/index.vue'), }); }; export default { install, getViews };