fix: CDR/UE数据空关闭loading

This commit is contained in:
TsMask
2025-02-27 15:31:58 +08:00
parent 6b81ea000b
commit 82d328e974
8 changed files with 67 additions and 55 deletions

View File

@@ -298,7 +298,7 @@ function fnGetList(pageNum?: number) {
}
listMMEDataUE(toRaw(queryParams)).then(res => {
if (res.code === RESULT_CODE_SUCCESS) {
if (res.code === RESULT_CODE_SUCCESS && Array.isArray(res.data.rows)) {
// 取消勾选
if (tableState.selectedRowKeys.length > 0) {
tableState.selectedRowKeys = [];
@@ -474,18 +474,21 @@ onMounted(() => {
useNeInfoStore()
.fnNelist()
.then(res => {
if (res.code === RESULT_CODE_SUCCESS) {
if (res.data.length > 0) {
let arr: Record<string, any>[] = [];
res.data.forEach((v: any) => {
if (v.neType === 'MME') {
arr.push({ value: v.neId, label: v.neName });
}
});
neOtions.value = arr;
if (arr.length > 0) {
queryParams.neId = arr[0].value;
if (res.code === RESULT_CODE_SUCCESS && Array.isArray(res.data)) {
let arr: Record<string, any>[] = [];
res.data.forEach((v: any) => {
if (v.neType === 'MME') {
arr.push({ value: v.neId, label: v.neName });
}
});
neOtions.value = arr;
if (arr.length > 0) {
queryParams.neId = arr[0].value;
} else {
message.warning({
content: t('common.noData'),
duration: 2,
});
}
} else {
message.warning({
@@ -569,7 +572,7 @@ onBeforeUnmount(() => {
:label="t('views.dashboard.cdr.time')"
name="queryRangePicker"
>
<a-range-picker
<a-range-picker
v-model:value="queryRangePicker"
:presets="rangePickerPresets"
:bordered="true"