fix: 降低dayjs版本

* update: docker vesion

* fix: 优化依赖包引入

* fix: 降低dayjs版本
This commit is contained in:
XieYongHong 2024-08-26 18:46:38 +08:00 committed by GitHub
parent b7ae40d5b5
commit 9a80801c14
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
31 changed files with 122 additions and 133 deletions

3
.npmrc
View File

@ -1,2 +1,3 @@
always-auth=true
registry=https://registry.npmjs.org/
# registry=https://registry.npmjs.org/
registry=https://registry.npmmirror.com

View File

@ -1,3 +1,3 @@
#!/usr/bin/env bash
docker build -t registry.cn-shenzhen.aliyuncs.com/jetlinks/jetlinks-ui-vue:2.3.0-SNAPSHOT .
docker push registry.cn-shenzhen.aliyuncs.com/jetlinks/jetlinks-ui-vue:2.3.0-SNAPSHOT
docker build -t registry.cn-shenzhen.aliyuncs.com/jetlinks/jetlinks-ui-vue:2.2.0-SNAPSHOT .
docker push registry.cn-shenzhen.aliyuncs.com/jetlinks/jetlinks-ui-vue:2.2.0-SNAPSHOT

View File

@ -29,13 +29,13 @@
"axios": "^1.2.1",
"colorpicker-v3": "^2.10.2",
"cronstrue": "^2.50.0",
"dayjs": "^1.11.12",
"dayjs": "1.11.11",
"driver.js": "^0.9.8",
"echarts": "^5.4.1",
"event-source-polyfill": "^1.0.31",
"global": "^4.4.0",
"jetlinks-store": "^0.0.3",
"jetlinks-ui-components": "^1.0.47",
"jetlinks-ui-components": "^1.0.48",
"jsencrypt": "^3.3.2",
"less": "^4.1.3",
"less-loader": "^11.1.0",
@ -54,12 +54,12 @@
"markdown-it-task-lists": "^2.1.1",
"markdown-it-toc-done-right": "^4.2.0",
"marked": "^4.2.12",
"moment": "^2.29.4",
"monaco-editor": "^0.50.0",
"nrm": "^1.2.5",
"pinia": "^2.0.28",
"resize-observer-polyfill": "^1.5.1",
"rollup-plugin-copy": "^3.4.0",
"rollup-plugin-visualizer": "^5.12.0",
"rxjs": "^7.8.1",
"unplugin-auto-import": "^0.12.1",
"unplugin-vue-components": "^0.22.12",
@ -81,7 +81,6 @@
"@commitlint/cli": "^17.4.1",
"@commitlint/config-conventional": "^17.4.0",
"@types/lodash-es": "^4.17.6",
"@types/moment": "^2.13.0",
"@types/node": "^18.14.0",
"@vitejs/plugin-vue": "^4.0.0",
"@vuemap/unplugin-resolver": "^1.0.4",

View File

@ -16,6 +16,15 @@ import { storeToRefs } from 'pinia';
import { useSystem } from './store/system';
import {LocalStore} from "@/utils/comm";
import {TOKEN_KEY} from "@/utils/variable";
import dayjs from 'dayjs';
import 'dayjs/locale/zh-cn';
import weekdays from 'dayjs/plugin/weekday'
import localeData from 'dayjs/plugin/localeData'
dayjs.extend(weekdays)
dayjs.extend(localeData)
dayjs.locale('zh-cn');
const system = useSystem();
const {configInfo} = storeToRefs(system);

View File

@ -179,11 +179,11 @@
{{ runningState(index + 1, item._time) }}
</template>
<template v-else>{{
moment(item.time).format('HH:mm:ss')
dayjs(item.time).format('HH:mm:ss')
}}</template>
</template>
<div v-if="!!runningState(index + 1, item._time)">
{{ moment(item.time).format('HH:mm:ss') }}
{{ dayjs(item.time).format('HH:mm:ss') }}
</div>
<j-tooltip placement="top" :title="item.content">
{{ item.content }}
@ -197,7 +197,7 @@
<script setup lang="ts" name="Debug">
import { PropType, Ref } from 'vue';
import { useRuleEditorStore } from '@/store/ruleEditor';
import moment from 'moment';
import dayjs from 'dayjs';
import { getWebSocket } from '@/utils/websocket';
import {useTableWrapper} from "@/components/Metadata/Table/context";
import { onlyMessage } from '@/utils/comm';

View File

@ -5,13 +5,9 @@ import components from './components'
import router from './router'
import './style.less'
import 'ant-design-vue/dist/antd.variable.min.css'
import dayjs from 'dayjs';
import 'dayjs/locale/zh-cn';
import i18n from './i18n'
import 'xgplayer/dist/index.min.css'
import '@/style/global.less'
dayjs.locale('zh-cn');
import i18n from './i18n'
const app = createApp(App)

View File

@ -1,4 +1,4 @@
import moment from "moment";
import dayjs from "dayjs";
import { LocalStore } from "./comm";
import { TOKEN_KEY } from "./variable";
import { SystemConst } from './consts';
@ -11,7 +11,7 @@ import { SystemConst } from './consts';
export const downloadObject = (record: Record<string, any>, fileName: string, format?: string) => {
// 创建隐藏的可下载链接
const ghostLink = document.createElement('a');
ghostLink.download = `${fileName ? '' : record?.name}${fileName}-${moment(new Date()).format(
ghostLink.download = `${fileName ? '' : record?.name}${fileName}-${dayjs(new Date()).format(
format || 'YYYY_MM_DD',
)}.json`;
ghostLink.style.display = 'none';

View File

@ -13,7 +13,7 @@
>
<template #requestTime="slotProps">
{{
moment(slotProps.requestTime).format('YYYY-MM-DD HH:mm:ss')
dayjs(slotProps.requestTime).format('YYYY-MM-DD HH:mm:ss')
}}
</template>
<template #description="slotProps">
@ -82,7 +82,7 @@
</j-descriptions-item>
<j-descriptions-item label="请求时间">
{{
moment(descriptionsData?.requestTime).format(
dayjs(descriptionsData?.requestTime).format(
'YYYY-MM-DD HH:mm:ss',
)
}}
@ -111,9 +111,8 @@
</template>
<script lang="ts" setup name="AccessLog">
import type { ActionsType } from '@/components/Table/index';
import type { AccessLogItem } from '../typings';
import { queryAccess } from '@/api/link/log';
import moment from 'moment';
import dayjs from 'dayjs';
import { modifySearchColumnValue } from '@/utils/comm';
const tableRef = ref<Record<string, any>>({});

View File

@ -27,7 +27,7 @@
</j-tag>
</template>
<template #createTime="slotProps">
{{ moment(slotProps.createTime).format('YYYY-MM-DD HH:mm:ss') }}
{{ dayjs(slotProps.createTime).format('YYYY-MM-DD HH:mm:ss') }}
</template>
<template #server="slotProps">
{{ slotProps.context.server }}
@ -60,7 +60,7 @@
<div>
<span class="mr-10">[{{ descriptionsData?.threadName }}]</span>
<span class="mr-10">{{
moment(descriptionsData?.createTime).format(
dayjs(descriptionsData?.createTime).format(
'YYYY-MM-DD HH:mm:ss',
)
}}</span>
@ -99,7 +99,7 @@
import type { ActionsType } from '@/components/Table/index';
import type { SystemLogItem } from '../typings';
import { querySystem } from '@/api/link/log';
import moment from 'moment';
import dayjs from 'dayjs';
import { modifySearchColumnValue } from '@/utils/comm';

View File

@ -67,7 +67,7 @@
</template>
<template #registerTime="slotProps">
<span>{{
moment(slotProps.registerTime).format('YYYY-MM-DD HH:mm:ss')
dayjs(slotProps.registerTime).format('YYYY-MM-DD HH:mm:ss')
}}</span>
</template>
</j-pro-table>
@ -78,7 +78,7 @@ import {
queryDetailListNoPaging,
queryDetailList,
} from '@/api/device/firmware';
import moment from 'moment';
import dayjs from 'dayjs';
type T = any;
const emit = defineEmits(['update:modelValue', 'change']);

View File

@ -70,7 +70,7 @@
<template #registryTime="slotProps">
{{
slotProps.registryTime
? moment(slotProps.registryTime).format(
? dayjs(slotProps.registryTime).format(
'YYYY-MM-DD HH:mm:ss',
)
: ''
@ -95,7 +95,7 @@ import {
queryDeviceMapping,
saveDeviceMapping,
} from '@/api/device/instance';
import moment from 'moment';
import dayjs from 'dayjs';
import { useInstanceStore } from '@/store/instance';
import { storeToRefs } from 'pinia';
import { onlyMessage } from '@/utils/comm';

View File

@ -70,7 +70,7 @@
<template #registryTime="slotProps">
{{
slotProps.registryTime
? moment(slotProps.registryTime).format(
? dayjs(slotProps.registryTime).format(
'YYYY-MM-DD HH:mm:ss',
)
: ''
@ -121,7 +121,7 @@
</template>
<script setup lang="ts">
import moment from 'moment';
import dayjs from 'dayjs';
import type { ActionsType } from '@/components/Table';
import {
query,
@ -136,7 +136,6 @@ import BindChildDevice from './BindChildDevice/index.vue';
import { usePermissionStore } from '@/store/permission';
import SaveChild from './SaveChild/index.vue';
import { onlyMessage } from '@/utils/comm';
import { cloneDeep } from 'lodash-es';
const instanceStore = useInstanceStore();
const { detail } = storeToRefs(instanceStore);

View File

@ -31,7 +31,7 @@
</div>
<div class="dialog-time">
{{
moment(item.endTime).format(
dayjs(item.endTime).format(
'YYYY-MM-DD HH:mm:ss',
)
}}
@ -50,7 +50,7 @@
</template>
<script lang="ts" setup>
import moment from 'moment';
import dayjs from 'dayjs';
const operationMap = new Map();
operationMap.set('connection', '连接');
@ -168,4 +168,4 @@ const getDetail = (item: any) => {
}
}
}
</style>
</style>

View File

@ -60,21 +60,21 @@
}}</j-descriptions-item>
<j-descriptions-item label="创建时间">{{
instanceStore.current?.createTime
? moment(instanceStore.current?.createTime).format(
? dayjs(instanceStore.current?.createTime).format(
'YYYY-MM-DD HH:mm:ss',
)
: ''
}}</j-descriptions-item>
<j-descriptions-item label="注册时间">{{
instanceStore.current?.registerTime
? moment(instanceStore.current?.registerTime).format(
? dayjs(instanceStore.current?.registerTime).format(
'YYYY-MM-DD HH:mm:ss',
)
: ''
}}</j-descriptions-item>
<j-descriptions-item label="最后上线时间">{{
instanceStore.current?.onlineTime
? moment(instanceStore.current?.onlineTime).format(
? dayjs(instanceStore.current?.onlineTime).format(
'YYYY-MM-DD HH:mm:ss',
)
: ''
@ -124,7 +124,7 @@ import Config from './components/Config/index.vue';
import Tags from './components/Tags/index.vue';
import Relation from './components/Relation/index.vue';
import InkingModal from './components/InklingModal';
import moment from 'moment';
import dayjs from 'dayjs';
import { detail as queryPluginAccessDetail } from '@/api/link/accessConfig';
import { getPluginData } from '@/api/link/plugin';

View File

@ -23,7 +23,7 @@
<template #timestamp="slotProps">
{{
slotProps.timestamp
? moment(slotProps.timestamp).format('YYYY-MM-DD HH:mm:ss')
? dayjs(slotProps.timestamp).format('YYYY-MM-DD HH:mm:ss')
: ''
}}
</template>
@ -50,7 +50,7 @@
import type { ActionsType } from '@/components/Table';
import { queryLog, queryLogsType } from '@/api/device/instance';
import { useInstanceStore } from '@/store/instance';
import moment from 'moment';
import dayjs from 'dayjs';
import { Modal, Textarea } from 'jetlinks-ui-components';
const params = ref<Record<string, any>>({});
@ -149,4 +149,4 @@ const handleSearch = (_params: any) => {
.device-log-search {
padding: 0;
}
</style>
</style>

View File

@ -17,7 +17,7 @@
>
<template #bodyCell="{ column, record }">
<template v-if="column.key === 'timestamp'">
{{ moment(record.timestamp).format('YYYY-MM-DD HH:mm:ss') }}
{{ dayjs(record.timestamp).format('YYYY-MM-DD HH:mm:ss') }}
</template>
<template v-if="column.key === 'value'">
<ValueRender
@ -74,7 +74,7 @@
import { getPropertyData } from '@/api/device/instance';
import { useInstanceStore } from '@/store/instance';
import encodeQuery from '@/utils/encodeQuery';
import moment from 'moment';
import dayjs from 'dayjs';
import { getType } from '../index';
import ValueRender from '../ValueRender.vue';
import JsonViewer from 'vue-json-viewer';
@ -181,7 +181,7 @@ const _download = (record: any) => {
const downNode = document.createElement('a');
downNode.download = `${instanceStore.current.name}-${
_props.data.name
}${moment(new Date().getTime()).format('YYYY-MM-DD-HH-mm-ss')}.txt`;
}${dayjs(new Date().getTime()).format('YYYY-MM-DD-HH-mm-ss')}.txt`;
downNode.style.display = 'none';
//Blob
const blob = new Blob([record.value]);

View File

@ -26,7 +26,7 @@
>
<template #modifyTime="slotProps">
<span>{{
moment(slotProps.modifyTime).format('HHHH-MM-DD HH:mm:ss')
dayjs(slotProps.modifyTime).format('HHHH-MM-DD HH:mm:ss')
}}</span>
</template>
<template #state="slotProps">
@ -42,7 +42,7 @@
<script setup lang="ts">
import StatusLabel from '../StatusLabel.vue';
import { getDeviceList_api } from '@/api/home';
import moment from 'moment';
import dayjs from 'dayjs';
import { onlyMessage } from '@/utils/comm';
import { useI18n } from 'vue-i18n'

View File

@ -23,7 +23,7 @@
<template #registryTime='slotProps'>
{{
slotProps.registryTime
? moment(slotProps.registryTime).format(
? dayjs(slotProps.registryTime).format(
'YYYY-MM-DD HH:mm:ss'
)
: ''
@ -39,7 +39,7 @@
<script setup lang='ts'>
import { queryUnbounded, bind } from '@/api/iot-card/cardManagement'
import moment from 'moment'
import dayjs from 'dayjs'
import { onlyMessage } from '@/utils/comm'
const emit = defineEmits(['change'])

View File

@ -64,14 +64,14 @@
}}</j-descriptions-item>
<j-descriptions-item label="激活日期">{{
detail.activationDate
? moment(detail.activationDate).format(
? dayjs(detail.activationDate).format(
'YYYY-MM-DD HH:mm:ss',
)
: ''
}}</j-descriptions-item>
<j-descriptions-item label="更新时间">{{
detail.updateTime
? moment(detail.updateTime).format(
? dayjs(detail.updateTime).format(
'YYYY-MM-DD HH:mm:ss',
)
: ''
@ -291,14 +291,14 @@
}}</j-descriptions-item>
<j-descriptions-item label="激活日期">{{
detail.activationDate
? moment(detail.activationDate).format(
? dayjs(detail.activationDate).format(
'YYYY-MM-DD HH:mm:ss',
)
: ''
}}</j-descriptions-item>
<j-descriptions-item label="更新时间">{{
detail.updateTime
? moment(detail.updateTime).format(
? dayjs(detail.updateTime).format(
'YYYY-MM-DD HH:mm:ss',
)
: ''
@ -459,7 +459,7 @@
</template>
<script setup lang="ts" name="CardDetail">
import moment from 'moment';
import dayjs from 'dayjs';
import type { CardManagement } from '../typing';
import {
queryDeactivate,
@ -568,16 +568,16 @@ const getData = (start: number, end: number): Promise<{ sortArray: any[] }> => {
*/
const getDataTotal = () => {
const dTime = [
moment(new Date()).subtract(1, 'day').startOf('day').valueOf(),
moment(new Date()).subtract(1, 'day').endOf('day').valueOf(),
dayjs(new Date()).subtract(1, 'day').startOf('day').valueOf(),
dayjs(new Date()).subtract(1, 'day').endOf('day').valueOf(),
];
const mTime = [
moment().startOf('month').valueOf(),
moment().endOf('month').valueOf(),
dayjs().startOf('month').valueOf(),
dayjs().endOf('month').valueOf(),
];
const yTime = [
moment().startOf('year').valueOf(),
moment().endOf('year').valueOf(),
dayjs().startOf('year').valueOf(),
dayjs().endOf('year').valueOf(),
];
getData(dTime[0], dTime[1]).then((resp) => {
dayTotal.value = resp.sortArray
@ -607,8 +607,8 @@ const getEcharts = (data: any) => {
let startTime = data.start;
let endTime = data.end;
if (data.type === 'week' || data.type === 'month') {
startTime = moment(data.start).startOf('days').valueOf();
endTime = moment(data.end).startOf('days').valueOf();
startTime = dayjs(data.start).startOf('days').valueOf();
endTime = dayjs(data.end).startOf('days').valueOf();
}
getData(startTime, endTime).then((resp) => {
flowData.value = resp.sortArray;

View File

@ -26,7 +26,7 @@
</template>
<script setup lang="ts">
import moment from 'moment';
import dayjs from 'dayjs';
import { _export } from '@/api/iot-card/cardManagement';
import { downloadFileByUrl } from '@/utils/utils';
@ -48,7 +48,7 @@ const handleOk = () => {
const url = URL.createObjectURL(blob);
downloadFileByUrl(
url,
`物联卡管理-${moment(new Date()).format(
`物联卡管理-${dayjs(new Date()).format(
'YYYY/MM/DD HH:mm:ss',
)}`,
type.value,

View File

@ -90,7 +90,7 @@
<script setup lang="ts" name='IotCardHome'>
import { getImage, onlyMessage } from '@/utils/comm';
import Guide from '../components/Guide.vue';
import moment from 'moment';
import dayjs from 'dayjs';
import { queryFlow, list } from '@/api/iot-card/home';
import * as echarts from 'echarts';
import { useMenuStore } from '@/store/menu';
@ -201,8 +201,8 @@ const jumpDashboard = () => {
* 获取昨日流量消耗
*/
const getTodayFlow = async () => {
const beginTime = moment().subtract(1, 'days').startOf('day').valueOf();
const endTime = moment().subtract(1, 'days').endOf('day').valueOf();
const beginTime = dayjs().subtract(1, 'days').startOf('day').valueOf();
const endTime = dayjs().subtract(1, 'days').endOf('day').valueOf();
const resp: any = await queryFlow(beginTime, endTime, { orderBy: 'date' });
resp.result.map((item: any) => {
currentSource.value += parseFloat(item.value.toFixed(2));
@ -213,8 +213,8 @@ const getTodayFlow = async () => {
* 获取最近15天流量消耗统计图数据
*/
const get15DaysTrafficConsumption = async () => {
const beginTime = moment().subtract(15, 'days').startOf('day').valueOf();
const endTime = moment().subtract(1, 'days').endOf('day').valueOf();
const beginTime = dayjs().subtract(15, 'days').startOf('day').valueOf();
const endTime = dayjs().subtract(1, 'days').endOf('day').valueOf();
const resp: any = await queryFlow(beginTime, endTime, { orderBy: 'date' });
barChartData.value = resp.result
.map((item: any) => ({

View File

@ -38,7 +38,7 @@
</j-descriptions-item>
<j-descriptions-item label="订单时间">{{
data.createTime
? moment(data.createTime).format('YYYY-MM-DD HH:mm:ss')
? dayjs(data.createTime).format('YYYY-MM-DD HH:mm:ss')
: '-'
}}</j-descriptions-item>
</j-descriptions>
@ -47,7 +47,7 @@
</template>
<script lang="ts" setup>
import moment from 'moment';
import dayjs from 'dayjs';
const emit = defineEmits(['close']);
const props = defineProps({

View File

@ -29,7 +29,7 @@
<template #createTime="slotProps">
{{
slotProps.createTime
? moment(slotProps.createTime).format(
? dayjs(slotProps.createTime).format(
'YYYY-MM-DD HH:mm:ss',
)
: ''
@ -66,7 +66,7 @@
</template>
<script setup lang="ts">
import moment from 'moment';
import dayjs from 'dayjs';
import type { ActionsType } from '@/components/Table';
import { queryRechargeList } from '@/api/iot-card/cardManagement';
import Save from './Save.vue';

View File

@ -20,7 +20,7 @@
<template #time="slotProps">
{{
slotProps.time
? moment(slotProps.time).format('YYYY-MM-DD HH:mm:ss')
? dayjs(slotProps.time).format('YYYY-MM-DD HH:mm:ss')
: ''
}}
</template>
@ -31,7 +31,7 @@
<script setup lang="ts">
import { queryList } from '@/api/iot-card/record';
import moment from 'moment';
import dayjs from 'dayjs';
const params = ref<Record<string, any>>({});

View File

@ -29,7 +29,7 @@
<script setup lang="ts">
import * as echarts from 'echarts';
import moment from 'moment';
import dayjs from 'dayjs';
// const { proxy } = <any>getCurrentInstance();
type Emits = {
@ -41,14 +41,14 @@ const props = defineProps({
title: { type: String, default: '' },
//
chartData: { type: Array, default: () => [] },
});
//
const dimension = ref('week');
const dateRange = ref<any>([
moment().subtract(1, 'week').format('x'),
moment().format('x'),
dayjs().subtract(1, 'week').format('x'),
dayjs().format('x'),
]);
/**
@ -64,7 +64,7 @@ const createChart = () => {
const sData: number[] = props.chartData.map(
(m: any) => m.value && m.value.toFixed(0),
);
const maxY = Math.max.apply(null, sData.length ? sData : [0]);
const options = {
grid: {
@ -136,13 +136,13 @@ const createChart = () => {
},
],
};
myChart.setOption(options);
window.addEventListener('resize', function () {
myChart.resize();
});
});
};
const onChange = ()=>{
@ -173,18 +173,18 @@ watch(
() => dimension.value,
(val) => {
if (val === 'today') {
dateRange.value[0] = moment().startOf('day').format('x');
dateRange.value[0] = dayjs().startOf('day').format('x');
}
if (val === 'week') {
dateRange.value[0] = moment().subtract(1, 'week').format('x');
dateRange.value[0] = dayjs().subtract(1, 'week').format('x');
}
if (val === 'month') {
dateRange.value[0] = moment().subtract(1, 'month').format('x');
dateRange.value[0] = dayjs().subtract(1, 'month').format('x');
}
if (val === 'year') {
dateRange.value[0] = moment().subtract(1, 'year').format('x');
dateRange.value[0] = dayjs().subtract(1, 'year').format('x');
}
dateRange.value[1] = moment().format('x');
dateRange.value[1] = dayjs().format('x');
emits('change', {
time: {
start: dateRange.value[0],

View File

@ -56,7 +56,7 @@ import dashboardApi from '@/api/media/dashboard';
import type { Footer } from '@/views/media/DashBoard/typings';
import encodeQuery from '@/utils/encodeQuery';
import { timestampFormat } from '@/utils/utils';
import moment from 'moment';
import dayjs from 'dayjs';
//
const deviceFooter = ref<Footer[]>([]);
@ -185,10 +185,10 @@ const getPlayCount = async (params: any) => {
params: {
format: format,
time: _time,
from: moment(Number(params.time.start)).format(
from: dayjs(Number(params.time.start)).format(
'YYYY-MM-DD HH:mm:ss',
),
to: moment(Number(params.time.end)).format(
to: dayjs(Number(params.time.end)).format(
'YYYY-MM-DD HH:mm:ss',
),
limit: _limit,

View File

@ -19,7 +19,7 @@
}"
>
<template #notifyTime="slotProps">
{{ moment(slotProps.notifyTime).format('YYYY-MM-DD HH:mm:ss') }}
{{ dayjs(slotProps.notifyTime).format('YYYY-MM-DD HH:mm:ss') }}
</template>
<template #state="slotProps">
<j-space>
@ -49,7 +49,7 @@
<script setup lang="ts">
import configApi from '@/api/notice/config';
import { PropType } from 'vue';
import moment from 'moment';
import dayjs from 'dayjs';
import { Modal } from 'ant-design-vue';
import Record from '../../Template/Log/components/Record.vue'

View File

@ -15,7 +15,7 @@
:params="params"
>
<template #notifyTime="slotProps">
{{ moment(slotProps.notifyTime).format('YYYY-MM-DD HH:mm:ss') }}
{{ dayjs(slotProps.notifyTime).format('YYYY-MM-DD HH:mm:ss') }}
</template>
<template #state="slotProps">
<j-space>
@ -45,7 +45,7 @@
<script setup lang="ts">
import templateApi from '@/api/notice/template';
import { PropType } from 'vue';
import moment from 'moment';
import dayjs from 'dayjs';
import { Modal } from 'jetlinks-ui-components';
import Record from './components/Record.vue'
type Emits = {

View File

@ -87,14 +87,13 @@ import {
} from './utils';
import BaseMenu from '@/views/init-home/data/baseMenu';
import type { AntTreeNodeDropEvent } from 'ant-design-vue/es/tree';
import { cloneDeep } from 'lodash-es';
import { cloneDeep, unionBy } from 'lodash-es';
import { onlyMessage } from '@/utils/comm';
import { USER_CENTER_MENU_CODE, messageSubscribe } from '@/utils/consts';
import { protocolList } from '@/utils/consts';
import { getProviders } from '@/api/data-collect/channel';
import { isNoCommunity } from '@/utils/utils';
import { USER_CENTER_MENU_DATA } from '@/views/init-home/data/baseMenu';
import { unionBy } from 'lodash';
const selectedKeys: any = ref([]);
const treeData = ref<any>([]);

View File

@ -15,6 +15,7 @@ import { JetlinksVueResolver } from './plugin/jetlinks'
import { optimizeDeps } from './plugin/optimize'
import copy from 'rollup-plugin-copy';
import progress from 'vite-plugin-progress'
import { visualizer } from 'rollup-plugin-visualizer'
// https://vitejs.dev/config/
export default defineConfig(({ mode}) => {
@ -85,7 +86,8 @@ export default defineConfig(({ mode}) => {
{src: 'node_modules/@liveqing/liveplayer-v3/dist/component/liveplayer-lib.min.js', dest: 'public/js'},
]
}),
progress()
progress(),
visualizer()
],
server: {
host:'0.0.0.0',

View File

@ -1005,13 +1005,6 @@
resolved "https://registry.npmjs.org/@types/minimist/-/minimist-1.2.5.tgz#ec10755e871497bcd83efe927e43ec46e8c0747e"
integrity sha512-hov8bUuiLiyFPGyFPE1lwWhmzYbirOXQNNo40+y3zow8aFVTeyn3VWL0VFFfdNddA8S4Vf0Tc062rzyNr7Paag==
"@types/moment@^2.13.0":
version "2.13.0"
resolved "https://registry.npmjs.org/@types/moment/-/moment-2.13.0.tgz#604ebd189bc3bc34a1548689404e61a2a4aac896"
integrity sha512-DyuyYGpV6r+4Z1bUznLi/Y7HpGn4iQ4IVcGn8zrr1P4KotKLdH0sbK1TFR6RGyX6B+G8u83wCzL+bpawKU/hdQ==
dependencies:
moment "*"
"@types/node@*":
version "20.14.2"
resolved "https://registry.npmjs.org/@types/node/-/node-20.14.2.tgz#a5f4d2bcb4b6a87bffcaa717718c5a0f208f4a18"
@ -2288,16 +2281,11 @@ dargs@^7.0.0:
resolved "https://registry.npmjs.org/dargs/-/dargs-7.0.0.tgz#04015c41de0bcb69ec84050f3d9be0caf8d6d5cc"
integrity sha512-2iy1EkLdlBzQGvbweYRFxmFath8+K7+AKB0TlhHWkNuH+TmovaMH/Wp7V7R4u7f4SnX3OgLsU9t1NI9ioDnUpg==
dayjs@^1.10.5:
dayjs@1.11.11, dayjs@^1.10.5:
version "1.11.11"
resolved "https://registry.npmjs.org/dayjs/-/dayjs-1.11.11.tgz#dfe0e9d54c5f8b68ccf8ca5f72ac603e7e5ed59e"
integrity sha512-okzr3f11N6WuqYtZSvm+F776mB41wRZMhKP+hc34YdW+KmtYYK9iqvHSwo2k9FEH3fhGXvOPV6yz2IcSrfRUDg==
dayjs@^1.11.12:
version "1.11.12"
resolved "https://registry.npmjs.org/dayjs/-/dayjs-1.11.12.tgz#5245226cc7f40a15bf52e0b99fd2a04669ccac1d"
integrity sha512-Rt2g+nTbLlDWZTwwrIXjy9MeiZmSDI375FvZs72ngxx8PDC6YXOeR3q5LAuPzjZQxhiWdRKac7RKV+YyQYfYIg==
de-indent@^1.0.2:
version "1.0.2"
resolved "https://registry.npmjs.org/de-indent/-/de-indent-1.0.2.tgz#b2038e846dc33baa5796128d0804b455b8c1e21d"
@ -3526,10 +3514,10 @@ jetlinks-store@^0.0.3:
resolved "https://registry.npmjs.org/jetlinks-store/-/jetlinks-store-0.0.3.tgz#7bc3c38c2e2e5d2eee6224f4878ff4d8326c978f"
integrity sha512-AZf/soh1hmmwjBZ00fr1emuMEydeReaI6IBTGByQYhTmK1Zd5pQAxC7WLek2snRAn/HHDgJfVz2hjditKThl6Q==
jetlinks-ui-components@^1.0.47:
version "1.0.47"
resolved "https://registry.npmjs.org/jetlinks-ui-components/-/jetlinks-ui-components-1.0.47.tgz#48c541e35a2fc7832a8e17870a4bf41445d59e8a"
integrity sha512-n9/Rw3xDgDshfyXv+mXUHiS95PmcMffZHz5UFoSp3ZuixWhHqchlNEEDp/DDLh4IcELay87HDF31cjuFPQrZHQ==
jetlinks-ui-components@^1.0.48:
version "1.0.48"
resolved "https://registry.npmjs.org/jetlinks-ui-components/-/jetlinks-ui-components-1.0.48.tgz#f2c5b844cee0fad21cc6c5c9c792fe27439f6e8f"
integrity sha512-tAKplLwXLCo/ofbgrLAvOgjZrjdgbMx+rnf+rvK17vjaTV13gWtn/77UNFzCa3kO4TXGn+FVU6qY6wULZO4U/w==
dependencies:
"@vueuse/core" "^9.12.0"
"@vueuse/router" "^9.13.0"
@ -3537,7 +3525,6 @@ jetlinks-ui-components@^1.0.47:
lodash-es "^4.17.21"
monaco-editor "^0.40.0"
sortablejs "^1.15.0"
vuedraggable "^4.1.0"
jmespath@^0.16.0:
version "0.16.0"
@ -4184,11 +4171,6 @@ mlly@^1.1.0, mlly@^1.7.0:
pkg-types "^1.1.1"
ufo "^1.5.3"
moment@*, moment@^2.29.4:
version "2.30.1"
resolved "https://registry.npmjs.org/moment/-/moment-2.30.1.tgz#f8c91c07b7a786e30c59926df530b4eac96974ae"
integrity sha512-uEmtNhbDOrWPFS+hdjFCBfy9f2YoyzRpwcl+DqpC6taX21FzsTLQVbMV/W7PzNSX6x/bhC1zA3c2UQ5NzH6how==
monaco-editor@^0.40.0:
version "0.40.0"
resolved "https://registry.npmjs.org/monaco-editor/-/monaco-editor-0.40.0.tgz#d10834e15ad50a15ec61fd01892e508464ebe2fe"
@ -4424,7 +4406,7 @@ onetime@^6.0.0:
dependencies:
mimic-fn "^4.0.0"
open@^8.4.2:
open@^8.4.0, open@^8.4.2:
version "8.4.2"
resolved "https://registry.npmjs.org/open/-/open-8.4.2.tgz#5b5ffe2a8f793dcd2aad73e550cb87b59cb084f9"
integrity sha512-7x81NCL719oNbsq/3mh+hVrAWmFuEYUqrq/Iw3kUzH8ReypT9QQ0BLoJS7/G9k6N81XjW4qHWtjWwe/9eLy1EQ==
@ -5027,6 +5009,16 @@ rollup-plugin-copy@^3.4.0:
globby "10.0.1"
is-plain-object "^3.0.0"
rollup-plugin-visualizer@^5.12.0:
version "5.12.0"
resolved "https://registry.npmjs.org/rollup-plugin-visualizer/-/rollup-plugin-visualizer-5.12.0.tgz#661542191ce78ee4f378995297260d0c1efb1302"
integrity sha512-8/NU9jXcHRs7Nnj07PF2o4gjxmm9lXIrZ8r175bT9dK8qoLlvKTwRMArRCMgpMGlq8CTLugRvEmyMeMXIU2pNQ==
dependencies:
open "^8.4.0"
picomatch "^2.3.1"
source-map "^0.7.4"
yargs "^17.5.1"
rollup@^3.27.1:
version "3.29.4"
resolved "https://registry.npmjs.org/rollup/-/rollup-3.29.4.tgz#4d70c0f9834146df8705bfb69a9a19c9e1109981"
@ -5223,11 +5215,6 @@ snake-case@^3.0.4:
dot-case "^3.0.4"
tslib "^2.0.3"
sortablejs@1.14.0:
version "1.14.0"
resolved "https://registry.npmjs.org/sortablejs/-/sortablejs-1.14.0.tgz#6d2e17ccbdb25f464734df621d4f35d4ab35b3d8"
integrity sha512-pBXvQCs5/33fdN1/39pPL0NZF20LeRbLQ5jtnheIPN9JQAaufGjKdWduZn4U7wCtVuzKhmRkI0DFYHYRbB2H1w==
sortablejs@^1.15.0:
version "1.15.2"
resolved "https://registry.npmjs.org/sortablejs/-/sortablejs-1.15.2.tgz#4e9f7bda4718bd1838add9f1866ec77169149809"
@ -5251,6 +5238,11 @@ source-map@^0.6.0, source-map@~0.6.0:
resolved "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz#74722af32e9614e9c287a8d0bbde48b5e2f1a263"
integrity sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==
source-map@^0.7.4:
version "0.7.4"
resolved "https://registry.npmjs.org/source-map/-/source-map-0.7.4.tgz#a9bbe705c9d8846f4e08ff6765acf0f1b0898656"
integrity sha512-l3BikUxvPOcn5E74dZiq5BGsTb5yEwhaTSzccU6t4sDOH8NWJCstKO5QT2CvtFoK6F0saL7p9xHAqHOlCPJygA==
sourcemap-codec@^1.4.8:
version "1.4.8"
resolved "https://registry.npmjs.org/sourcemap-codec/-/sourcemap-codec-1.4.8.tgz#ea804bd94857402e6992d05a38ef1ae35a9ab4c4"
@ -6075,13 +6067,6 @@ vue@^3.2.25, vue@^3.4.5:
"@vue/server-renderer" "3.4.27"
"@vue/shared" "3.4.27"
vuedraggable@^4.1.0:
version "4.1.0"
resolved "https://registry.npmjs.org/vuedraggable/-/vuedraggable-4.1.0.tgz#edece68adb8a4d9e06accff9dfc9040e66852270"
integrity sha512-FU5HCWBmsf20GpP3eudURW3WdWTKIbEIQxh9/8GE806hydR9qZqRRxRE3RjqX7PkuLuMQG/A7n3cfj9rCEchww==
dependencies:
sortablejs "1.14.0"
w3c-keyname@^2.2.4:
version "2.2.8"
resolved "https://registry.npmjs.org/w3c-keyname/-/w3c-keyname-2.2.8.tgz#7b17c8c6883d4e8b86ac8aba79d39e880f8869c5"
@ -6348,7 +6333,7 @@ yargs@^14.2.3:
y18n "^4.0.0"
yargs-parser "^15.0.1"
yargs@^17.0.0:
yargs@^17.0.0, yargs@^17.5.1:
version "17.7.2"
resolved "https://registry.npmjs.org/yargs/-/yargs-17.7.2.tgz#991df39aca675a192b816e1e0363f9d75d2aa269"
integrity sha512-7dSzzRQ++CKnNI/krKnYRV7JKKPUXMEh61soaHKg9mrWEhzFWhFnxPxGl+69cD1Ou63C13NUPCnmIcrvqCuM6w==