feat:imsUDM界面添加功能修复

This commit is contained in:
zhongzm
2025-04-11 20:52:04 +08:00
parent 84b0ab50f4
commit 72bd9004cc

View File

@@ -27,7 +27,6 @@ import { listTenant } from '@/api/system/tenant';
import { uploadFile } from '@/api/tool/file';
import { getNeViewFile } from '@/api/tool/neFile';
const { t } = useI18n();
/**网元参数 */
let neOtions = ref<Record<string, any>[]>([]);
@@ -37,14 +36,12 @@ let queryParams = reactive({
neId: undefined,
/**移动编号 */
imsi: '',
/**imsi匹配方式 */
imsiMatch: 'fuzzy',
/**租户名 */
tenantName: '',
/**移动号 */
msisdn: '',
/**TAG */
tag: undefined,
tag:undefined,
/**排序字段 */
sortField: 'imsi',
/**排序方式 */
@@ -59,7 +56,6 @@ let queryParams = reactive({
function fnQueryReset() {
queryParams = Object.assign(queryParams, {
imsi: '',
imsiMatch: 'fuzzy',
msisdn: '',
tenantName: '',
tag: undefined,
@@ -148,7 +144,10 @@ let tableColumns = ref<ColumnsType>([
dataIndex: 'tag',
align: 'center',
width: 150,
key: 'tag'
key: 'tag',
customRender: ({ text }: { text: number }) => {
return text === 0 ? 'VoIP' : 'VoLTE';
}
},
{
title: t('common.operate'),
@@ -194,62 +193,6 @@ let tablePagination = reactive({
function fnTableSize({ key }: MenuInfo) {
tableState.size = key as SizeType;
}
/**表格分页、排序、筛选变化时触发操作, 排序方式,取值为 ascend descend */
function fnTableChange(pagination: any, filters: any, sorter: any, extra: any) {
const { field, order } = sorter;
if (order) {
queryParams.sortField = field;
queryParams.sortOrder = order.replace('end', '');
} else {
queryParams.sortOrder = 'asc';
}
fnGetList(1);
}
/**表格多选 */
function fnTableSelectedRowKeys(keys: (string | number)[]) {
tableState.selectedRowKeys = keys;
}
/**对话框对象信息状态类型 */
type ModalStateType = {
/**新增框是否显示 */
openByAdd: boolean;
/**批量删除框是否显示 */
openByBatchDel: boolean;
/**标题 */
title: string;
/**表单数据 */
from: Record<string, any>;
/**批量删除表单数据 */
BatchDelForm: Record<string, any>;
/**确定按钮 loading */
confirmLoading: boolean;
/**更新加载数据按钮 loading */
loadDataLoading: boolean;
};
/**对话框对象信息状态 */
let modalState: ModalStateType = reactive({
openByAdd: false,
openByBatchDel: false,
title: 'UDM签约用户',
from: {
imsi: '',
msisdn: '',
tag: '0',
vni: '',
num: 1,
},
BatchDelForm: {
num: 1,
imsi: '',
},
confirmLoading: false,
loadDataLoading: false,
});
/**表单中多选的OPTION */
const modalStateFromOption = reactive({
ardJson: [
@@ -302,24 +245,188 @@ const modalStateFromOption = reactive({
},
],
});
/**表格分页、排序、筛选变化时触发操作, 排序方式,取值为 ascend descend */
function fnTableChange(pagination: any, filters: any, sorter: any, extra: any) {
const { field, order } = sorter;
if (order) {
queryParams.sortField = field;
queryParams.sortOrder = order.replace('end', '');
} else {
queryParams.sortOrder = 'asc';
}
fnGetList(1);
}
/**表格多选 */
function fnTableSelectedRowKeys(keys: (string | number)[]) {
tableState.selectedRowKeys = keys;
}
/**对话框对象信息状态类型 */
type ModalStateType = {
/**新增框或修改框是否显示 */
openByEdit: boolean;
/**批量新增新增框是否显示 */
openByBatch: boolean;
/**批量新增删除框是否显示 */
openByBatchDel: boolean;
/**标题 */
title: string;
/**表单数据 */
from: Record<string, any>;
/**表单数据 */
BatchDelForm: Record<string, any>;
/**确定按钮 loading */
confirmLoading: boolean;
/**更新加载数据按钮 loading */
loadDataLoading: boolean;
};
/**对话框对象信息状态 */
let modalState: ModalStateType = reactive({
openByEdit: false,
openByBatch: false,
openByBatchDel: false,
title: 'UDM鉴权用户',
from: {
imsi: '',
msisdn: '',
tag: undefined,
vni: '',
num: 1,
},
BatchDelForm: {
num: 1,
imsi: '',
},
confirmLoading: false,
loadDataLoading: false,
});
/**对话框内表单属性和校验规则 */
const modalStateFrom = Form.useForm(
modalState.from,
reactive({
num: [
{
required: true,
message: t('views.neUser.auth.numAdd') + t('common.unableNull'),
},
],
imsi: [
{ required: computed(() => modalState.from.tag === 1), message: 'IMSI' + t('common.unableNull') },
{ min: 15, max: 15, message: t('views.neUser.auth.imsiConfirm') },
],
msisdn: [{ required: true, message: 'MSISDN' + t('common.unableNull') }],
tag: [
{ required: true, message: 'TAG' + t('common.unableNull') }
],
vni: [
{ required: true, message: 'vni' + t('common.unableNull') },
],
// algoIndex: [
// { required: true, message: 'algoIndex' + t('common.unableNull') },
// ],
})
);
function fnTenantNameFocus() {
Promise.allSettled([listTenant({ parentId: 0 })]).then(resArr => {
if (resArr[0].status === 'fulfilled') {
var tenantNameData = resArr[0].value;
if (
tenantNameData.code === RESULT_CODE_SUCCESS &&
Array.isArray(tenantNameData.data)
) {
modalStateFromOption.tenantName = []; //上面置为空数组时会报错 故在此
tenantNameData.data.forEach((item: any) => {
if (item.parentId === '0') {
modalStateFromOption.tenantName.push({
value: item.tenantName,
label: item.tenantName,
});
}
});
}
}
});
}
/**对话框内批量删除表单属性和校验规则 */
const modalStateBatchDelFrom = Form.useForm(
modalState.BatchDelForm,
reactive({
num: [
{
required: true,
message: t('views.neUser.auth.numDel') + t('common.unableNull'),
},
],
imsi: [{ required: true, message: 'IMSI' + t('common.unableNull') }],
})
);
/**
* 对话框弹出显示为 新增或者修改
* @param noticeId 网元id, 不传为新增
*/
function fnModalVisibleByEdit(row?: Record<string, any>) {
if (!row) {
modalStateFrom.resetFields(); //重置表单
modalState.title = t('common.addText') + t('views.neUser.auth.authInfo');
modalState.openByEdit = true;
} else {
if (modalState.confirmLoading) return;
const hide = message.loading(t('common.loading'), 0);
modalState.confirmLoading = true;
const neId = queryParams.neId || '-';
getIMSSub(neId, row.imsi)
.then(res => {
if (res.code === RESULT_CODE_SUCCESS) {
modalState.from = Object.assign(modalState.from, res.data);
modalState.title =
t('common.editText') + t('views.neUser.auth.authInfo');
modalState.openByEdit = true;
} else {
message.error(t('common.getInfoFail'), 2);
}
})
.finally(() => {
hide();
modalState.confirmLoading = false;
});
}
}
/**
* 对话框弹出显示为 批量删除
* @param noticeId 网元id, 不传为新增
*/
function fnModalVisibleByBatch() {
modalStateBatchDelFrom.resetFields(); //重置表单
modalState.title =
t('views.neUser.auth.batchDelText') + t('views.neUser.auth.authInfo');
modalState.openByBatchDel = true;
}
/**
* 对话框弹出确认执行函数
* 进行表达规则校验
*/
function fnModalOk() {
const from = Object.assign({}, toRaw(modalState.from));
console.log(modalState.from)
modalStateFrom
.validate()
.then(e => {
const from = Object.assign({}, toRaw(modalState.from));
modalState.confirmLoading = true;
from.neId = queryParams.neId || '-';
console.log(from)
const result = from.num === 1
? addIMSSub(from)//单条新增
: batchAddIMSSub(from, from.num);//批量新增
? addIMSSub(from)
: batchAddIMSSub(from, from.num);
const hide = message.loading(t('common.loading'), 0);
result
return result
.then((res: any) => {
if (res.code === RESULT_CODE_SUCCESS) {
if (from.num === 1) {
@@ -364,59 +471,80 @@ function fnModalOk() {
});
})
.catch(e => {
console.error(e);
message.error(t('common.errorFields', { num: e.errorFields.length }), 3);
});
}
/**
* 对话框弹出 批量删除确认执行函数
* 进行表达规则校验
*/
function fnBatchDelModalOk() {
modalStateBatchDelFrom
.validate()
.then(e => {
modalState.confirmLoading = true;
const from = toRaw(modalState.BatchDelForm);
const neId = queryParams.neId || '-';
batchDelIMSSub(neId, from.imsi, from.num).then(res => {
if (res.code === RESULT_CODE_SUCCESS) {
const timerS = Math.ceil(+from.num / 1500) + 1;
notification.success({
message: modalState.title,
description: t('common.operateOk'),
duration: timerS,
});
setTimeout(() => {
modalState.openByBatchDel = false;
modalState.confirmLoading = false;
modalStateBatchDelFrom.resetFields();
fnGetList(1);
}, timerS * 1000);
} else {
modalState.confirmLoading = false;
notification.error({
message: modalState.title,
description: res.msg,
duration: 3,
});
}
});
})
.catch(e => {
message.error(t('common.errorFields', { num: e.errorFields.length }), 3);
});
}
/**
* 批量删除对话框弹出关闭执行函数
* 进行表达规则校验
*/
function fnBatchDelModalCancel() {
modalState.openByBatchDel = false;
modalStateBatchDelFrom.resetFields();
}
/**
* 对话框弹出关闭执行函数
* 进行表达规则校验
*/
function fnModalCancel() {
modalState.openByAdd = false;
modalState.openByEdit = false;
modalStateFrom.resetFields();
}
/**对话框内表单属性和校验规则 */
const modalStateFrom = Form.useForm(
modalState.from,
reactive({
num: [
{
required: true,
message: t('views.neUser.sub.numAdd') + t('common.unableNull'),
},
],
imsi: [
{
required: computed(() => modalState.from.tag === '1'),
message: 'IMSI' + t('common.unableNull')
},
{ min: 15, max: 15, message: t('views.neUser.auth.imsiConfirm') },
],
msisdn: [
{ required: true, message: 'MSISDN' + t('common.unableNull') },
],
tag: [
{ required: true, message: 'TAG' + t('common.unableNull') },
],
vni: [
{ required: true, message: 'VNI' + t('common.unableNull') },
],
})
);
/**
* UDM签约用户删除
* UDM鉴权用户删除
* @param imsi 编号imsi
*/
function fnRecordDelete(imsi: string) {
const neId = queryParams.neId;
if (!neId) return;
let imsiMsg = imsi;//单条/批量删除逻辑
let imsiMsg = imsi;
if (imsi === '0') {
imsiMsg = `${tableState.selectedRowKeys[0]}... ${t(
'views.neUser.sub.numDel'
'views.neUser.auth.numDel'
)} ${tableState.selectedRowKeys.length}`;
imsi = tableState.selectedRowKeys.join(',');
}
@@ -424,37 +552,37 @@ function fnRecordDelete(imsi: string) {
Modal.confirm({
title: t('common.tipTitle'),
content: t('views.neUser.auth.delSure', { imsi: imsiMsg }),
onOk() {//删除操作
modalState.loadDataLoading = true;//设置加载状态
const hide = message.loading(t('common.loading'), 0);//显示加载提示
delIMSSub(neId, imsi)//调用删除接口方法
onOk() {
modalState.loadDataLoading = true;
const hide = message.loading(t('common.loading'), 0);
delIMSSub(neId, imsi)
.then(res => {
if (res.code === RESULT_CODE_SUCCESS) {//返回删除成功
if (res.code === RESULT_CODE_SUCCESS) {
const msgContent = t('common.msgSuccess', {
msg: t('common.deleteText'),
});
message.success({//显示成功提示
message.success({
content: `${msgContent} : ${imsiMsg}`,
duration: 3,
});
} else {//删除失败
message.error({//显示错误信息
} else {
message.error({
content: `${res.msg}`,
duration: 3,
});
}
})
.finally(() => {//无论结果固定执行
hide();//隐藏加载提示
fnGetList();//刷新列表数据
modalState.loadDataLoading = false;//重置加载状态
.finally(() => {
hide();
fnGetList();
modalState.loadDataLoading = false;
});
},
});
}
/**
* UDM签约用户导出
* UDM鉴权用户勾选导出
*/
function fnRecordExport(type: string = 'txt') {
const selectLen = tableState.selectedRowKeys.length;
@@ -465,16 +593,10 @@ function fnRecordExport(type: string = 'txt') {
exportIMSSub({ type: type, neId: neId, imsis: tableState.selectedRowKeys })
.then(res => {
if (res.code === RESULT_CODE_SUCCESS) {
message.success({
content: t('common.msgSuccess', { msg: t('common.export') }),
duration: 2,
});
saveAs(res.data, `UDMSub_select_${Date.now()}.${type}`);
message.success(t('common.msgSuccess', { msg: t('common.export') }), 3);
saveAs(res.data, `UDMAuth_select_${Date.now()}.${type}`);
} else {
message.error({
content: `${res.msg}`,
duration: 2,
});
message.error(`${res.msg}`, 3);
}
})
.finally(() => {
@@ -482,37 +604,22 @@ function fnRecordExport(type: string = 'txt') {
});
}
/**列表导出 */
/**列表导出全部数据 */
function fnExportList(type: string) {
const neId = queryParams.neId;
const imsiMatchRule: any = {
prefix: queryParams.imsi ? `${queryParams.imsi}%` : '',
fuzzy: queryParams.imsi ? `%${queryParams.imsi}%` : '',
};
const realImsi = imsiMatchRule[queryParams.imsiMatch] || '';
if (!neId) return;
const key = 'exportSub';
message.loading({ content: t('common.loading'), key });
exportIMSSub({
...queryParams,
imsi: realImsi,
type: type,
}).then(res => {
const hide = message.loading(t('common.loading'), 0);
exportIMSSub(Object.assign({ type: type }, queryParams))
.then(res => {
if (res.code === RESULT_CODE_SUCCESS) {
message.success({
content: t('common.msgSuccess', { msg: t('common.export') }),
key,
duration: 2,
});
saveAs(res.data, `UDMSub_${Date.now()}.${type}`);
message.success(t('common.msgSuccess', { msg: t('common.export') }), 3);
saveAs(res.data, `UDMAuth_${Date.now()}.${type}`);
} else {
message.error({
content: `${res.msg}`,
key,
duration: 2,
});
message.error(`${res.msg}`, 3);
}
})
.finally(() => {
hide();
});
}
@@ -527,13 +634,13 @@ function fnLoadData() {
resetIMSSub(neId).then(res => {
if (res.code === RESULT_CODE_SUCCESS) {
const num = res.data;
const timerS = Math.ceil(+num / 2000) + 3;
const timerS = Math.ceil(+num / 3000) + 3;
notification.success({
message: t('views.neUser.sub.loadData'),
description: t('views.neUser.sub.loadDataTip', { num, timer: timerS }),
message: t('views.neUser.auth.loadData'),
description: t('views.neUser.auth.loadDataTip', { num, timer: timerS }),
duration: timerS,
});
// 延迟20s后关闭loading刷新列表
// 延迟10s后关闭loading刷新列表
setTimeout(() => {
modalState.loadDataLoading = false;
tableState.loading = false; // 表格loading
@@ -574,7 +681,6 @@ function fnGetList(pageNum?: number) {
pageNum: queryParams.pageNum,
pageSize: queryParams.pageSize,
};
listIMSSub({
...queryParams,
imsi: imsiMatchRule[queryParams.imsiMatch],
@@ -632,7 +738,7 @@ function fnModalUploadImportFailReason() {
neType: 'UDM',
neId: neId,
path: '/tmp',
fileName: 'import_udmuser_err_records.txt',
fileName: 'import_authdata_err_records.txt',
})
.then(res => {
if (res.code === RESULT_CODE_SUCCESS) {
@@ -640,7 +746,7 @@ function fnModalUploadImportFailReason() {
const blob = new Blob([res.data], {
type: 'text/plain',
});
saveAs(blob, `import_udmuser_err_records_${Date.now()}.txt`);
saveAs(blob, `import_authdata_err_records_${Date.now()}.txt`);
} else {
message.error(`${res.msg}`, 3);
}
@@ -661,7 +767,7 @@ function fnModalUploadImportOpen() {
/**对话框表格信息导入关闭窗口 */
function fnModalUploadImportClose() {
uploadImportState.open = false;
fnGetList();
fnGetList(1);
}
/**对话框表格信息导入上传 */
@@ -712,126 +818,6 @@ function fnModalUploadImportUpload(file: File) {
});
}
function fnTenantNameFocus() {
Promise.allSettled([listTenant({ parentId: 0 })]).then(resArr => {
if (resArr[0].status === 'fulfilled') {
var tenantNameData = resArr[0].value;
if (
tenantNameData.code === RESULT_CODE_SUCCESS &&
Array.isArray(tenantNameData.data)
) {
modalStateFromOption.tenantName = []; //上面置为空数组时会报错 故在此
tenantNameData.data.forEach((item: any) => {
if (item.parentId === '0') {
modalStateFromOption.tenantName.push({
value: item.tenantName,
label: item.tenantName,
});
}
});
}
}
});
}
/**
* 对话框弹出显示为 新增
*/
function fnModalVisibleByAdd() {
modalState.openByAdd = true;
modalState.title = t('common.addText') + t('views.neUser.sub.subInfo');
modalState.from = {
imsi: '',
msisdn: '',
tag: '0',
vni: '',
num: 1,
};
}
/**
* 对话框弹出显示为 批量删除
*/
function fnModalVisibleByBatch() {
modalState.openByBatchDel = true;
modalState.title = t('views.neUser.auth.batchDelText');
modalState.BatchDelForm = {
num: 1,
imsi: '',
};
}
/**
* 批量删除对话框确认
*/
function fnBatchDelModalOk() {
modalStateBatchDelFrom
.validate()
.then(() => {
modalState.confirmLoading = true;
const hide = message.loading(t('common.loading'), 0);
const neId = queryParams.neId;
if (!neId) return;
batchDelIMSSub(neId, modalState.BatchDelForm.imsi, modalState.BatchDelForm.num)
.then(res => {
if (res.code === RESULT_CODE_SUCCESS) {
const timerS = Math.max(
Math.ceil(modalState.BatchDelForm.num / 500),
`${modalState.BatchDelForm.num}`.length * 5
);
notification.success({
message: modalState.title,
description: t('common.operateOk'),
duration: timerS,
});
setTimeout(() => {
fnGetList(1);
}, timerS * 1000);
} else {
notification.error({
message: modalState.title,
description: res.msg,
duration: 3,
});
}
})
.finally(() => {
hide();
fnBatchDelModalCancel();
modalState.confirmLoading = false;
});
})
.catch(e => {
message.error(t('common.errorFields', { num: e.errorFields.length }), 3);
});
}
/**
* 批量删除对话框取消
*/
function fnBatchDelModalCancel() {
modalState.openByBatchDel = false;
modalStateBatchDelFrom.resetFields();
}
/**批量删除对话框内表单属性和校验规则 */
const modalStateBatchDelFrom = Form.useForm(
modalState.BatchDelForm,
reactive({
imsi: [
{ required: true, message: 'IMSI' + t('common.unableNull') },
{ min: 15, max: 15, message: t('views.neUser.auth.imsiConfirm') },
],
num: [
{
required: true,
message: t('views.neUser.sub.numDel') + t('common.unableNull'),
},
],
})
);
onMounted(() => {
// 获取网元网元列表
useNeInfoStore()
@@ -875,7 +861,7 @@ onMounted(() => {
<a-form :model="queryParams" name="queryParams" layout="horizontal">
<a-row :gutter="16">
<a-col :lg="6" :md="12" :xs="24">
<a-form-item :label="t('views.neUser.sub.neType')" name="neId">
<a-form-item :label="t('views.neUser.auth.neType')" name="neId ">
<a-select
v-model:value="queryParams.neId"
:options="neOtions"
@@ -884,35 +870,36 @@ onMounted(() => {
/>
</a-form-item>
</a-col>
<a-col :lg="10" :md="12" :xs="24">
<a-col :lg="6" :md="12" :xs="24">
<a-form-item label="IMSI" name="imsi">
<a-input
v-model:value="queryParams.imsi"
allow-clear
:maxlength="15"
style="width: 70%"
:placeholder="t('common.inputPlease')"
></a-input>
<a-select
:label="t('views.neUser.sub.imsiMode')"
style="width: 30%"
v-model:value="queryParams.imsiMatch"
v-show="queryParams.imsi"
:options="[
{ label: t('views.neUser.sub.fuzzyMatch'), value: 'fuzzy' },
{ label: t('views.neUser.sub.prefixMatch'), value: 'prefix' },
]"
/>
</a-form-item>
</a-col>
<a-col :lg="8" :md="12" :xs="24">
<a-form-item label="MSISDN" name="msisdn">
<a-input v-model:value="queryParams.msisdn" allow-clear :maxlength="32"
:placeholder="t('common.inputPlease')"></a-input>
</a-form-item>
</a-col>
<a-col :lg="6" :md="12" :xs="24">
<a-form-item label="TAG" name="tag">
<a-select
v-model:value="queryParams.tag"
:options="[
{ label: 'All', value: undefined },
{ label: 'VoIP', value: 0 },
{ label: 'VoLTE', value: 1 }
]"
:placeholder="t('common.selectPlease')"
>
</a-select>
</a-form-item>
</a-col>
<a-col :lg="6" :md="12" :xs="24">
<a-form-item
:label="t('views.neUser.sub.tenantName')"
@@ -925,19 +912,6 @@ onMounted(() => {
></a-auto-complete>
</a-form-item>
</a-col>
<a-col :lg="6" :md="12" :xs="24">
<a-form-item label="TAG" name="tag">
<a-select
v-model:value="queryParams.tag"
:options="[
{ label: 'VoIP', value: '0' },
{ label: 'VoLTE', value: '1' }
]"
:placeholder="t('common.selectPlease')"
allow-clear
/>
</a-form-item>
</a-col>
<a-col :lg="6" :md="12" :xs="24">
<a-form-item>
<a-space :size="8">
@@ -964,7 +938,7 @@ onMounted(() => {
<!-- 插槽-卡片左侧侧 -->
<template #title>
<a-flex wrap="wrap" gap="small">
<a-button type="primary" @click.prevent="fnModalVisibleByAdd">
<a-button type="primary" @click.prevent="fnModalVisibleByEdit()">
<template #icon>
<PlusOutlined />
</template>
@@ -984,7 +958,7 @@ onMounted(() => {
</a-button>
<a-popconfirm
:title="t('views.neUser.sub.loadDataConfirm')"
:title="t('views.neUser.auth.loadDataConfirm')"
:ok-text="t('common.ok')"
:cancel-text="t('common.cancel')"
:disabled="modalState.loadDataLoading"
@@ -996,32 +970,26 @@ onMounted(() => {
:disabled="modalState.loadDataLoading"
:loading="modalState.loadDataLoading"
>
<template #icon>
<SyncOutlined />
</template>
{{ t('views.neUser.sub.loadData') }}
<template #icon><SyncOutlined /></template>
{{ t('views.neUser.auth.loadData') }}
</a-button>
</a-popconfirm>
<a-button type="dashed" @click.prevent="fnModalUploadImportOpen">
<template #icon>
<ImportOutlined />
</template>
{{ t('views.neUser.sub.import') }}
<template #icon><ImportOutlined /></template>
{{ t('views.neUser.auth.import') }}
</a-button>
<a-popconfirm
:title="t('views.neUser.sub.exportConfirm')"
:title="t('views.neUser.auth.exportConfirm')"
placement="topRight"
ok-text="TXT"
ok-type="default"
@confirm="fnExportList('txt')"
>
<a-button type="dashed">
<template #icon>
<ExportOutlined />
</template>
{{ t('views.neUser.sub.export') }}
<template #icon><ExportOutlined /></template>
{{ t('views.neUser.auth.export') }}
</a-button>
</a-popconfirm>
@@ -1032,14 +1000,12 @@ onMounted(() => {
:loading="modalState.loadDataLoading"
@click.prevent="fnRecordDelete('0')"
>
<template #icon>
<DeleteOutlined />
</template>
{{ t('views.neUser.sub.checkDel') }}
<template #icon><DeleteOutlined /></template>
{{ t('views.neUser.auth.checkDel') }}
</a-button>
<a-popconfirm
:title="t('views.neUser.sub.checkExportConfirm')"
:title="t('views.neUser.auth.checkExportConfirm')"
placement="topRight"
ok-text="TXT"
ok-type="default"
@@ -1050,10 +1016,8 @@ onMounted(() => {
type="default"
:disabled="tableState.selectedRowKeys.length <= 0"
>
<template #icon>
<ExportOutlined />
</template>
{{ t('views.neUser.sub.checkExport') }}
<template #icon><ExportOutlined /></template>
{{ t('views.neUser.auth.checkExport') }}
</a-button>
</a-popconfirm>
</a-flex>
@@ -1074,24 +1038,19 @@ onMounted(() => {
<a-tooltip>
<template #title>{{ t('common.reloadText') }}</template>
<a-button type="text" @click.prevent="fnGetList()">
<template #icon>
<ReloadOutlined />
</template>
<template #icon><ReloadOutlined /></template>
</a-button>
</a-tooltip>
<TableColumnsDnd
cache-id="udmSubData"
cache-id="udmAuthData"
:columns="tableColumns"
v-model:columns-dnd="tableColumnsDnd"
>
</TableColumnsDnd>
></TableColumnsDnd>
<a-tooltip placement="topRight">
<template #title>{{ t('common.sizeText') }}</template>
<a-dropdown placement="bottomRight" trigger="click">
<a-button type="text">
<template #icon>
<ColumnHeightOutlined />
</template>
<template #icon><ColumnHeightOutlined /></template>
</a-button>
<template #overlay>
<a-menu
@@ -1125,7 +1084,7 @@ onMounted(() => {
:pagination="tablePagination"
:scroll="{ y: 'calc(100vh - 480px)' }"
@change="fnTableChange"
@resizeColumn="(w: number, col: any) => (col.width = w)"
@resizeColumn="(w:number, col:any) => (col.width = w)"
:row-selection="{
type: 'checkbox',
selectedRowKeys: tableState.selectedRowKeys,
@@ -1133,23 +1092,6 @@ onMounted(() => {
}"
>
<template #bodyCell="{ column, record }">
<template v-if="column.key === 'cnFlag'">
{{
['1', '3'].includes(record.cnType)
? t('views.neUser.sub.enable')
: t('views.neUser.sub.disable')
}}
</template>
<template v-if="column.key === 'epsFlag'">
{{
record.epsFlag === '1'
? t('views.neUser.sub.enable')
: t('views.neUser.sub.disable')
}}
</template>
<template v-if="column.key === 'tag'">
{{ record.tag === '0' || record.tag === 0 ? 'VoIP' : 'VoLTE' }}
</template>
<template v-if="column.key === 'imsi'">
<a-space :size="8" align="center">
<a-tooltip>
@@ -1169,17 +1111,15 @@ onMounted(() => {
</a-table>
</a-card>
<!-- 新增框或修改框-->
<!-- 新增框或修改框 -->
<ProModal
:drag="true"
:width="800"
:destroyOnClose="true"
style="top: 0px"
:body-style="{ maxHeight: '600px', 'overflow-y': 'auto' }"
:keyboard="false"
:mask-closable="false"
:open="modalState.openByAdd"
:title="t('common.addText') + t('views.neUser.sub.subInfo')"
:open="modalState.openByEdit"
:title="modalState.title"
:confirm-loading="modalState.confirmLoading"
@ok="fnModalOk"
@cancel="fnModalCancel"
@@ -1270,8 +1210,8 @@ onMounted(() => {
<a-select
v-model:value="modalState.from.tag"
:options="[
{ label: 'VoIP', value: '0' },
{ label: 'VoLTE', value: '1' }
{ label: 'VoIP', value:0 },
{ label: 'VoLTE', value: 1 }
]"
:placeholder="t('common.selectPlease')"
>
@@ -1293,11 +1233,11 @@ onMounted(() => {
</a-row>
</a-form>
</ProModal>
<!-- 批量删除-->
<!-- 批量删除框 -->
<ProModal
:drag="true"
:destroyOnClose="true"
style="top: 0px"
:keyboard="false"
:mask-closable="false"
:open="modalState.openByBatchDel"
@@ -1315,7 +1255,7 @@ onMounted(() => {
<a-row>
<a-col :lg="24" :md="24" :xs="24">
<a-form-item
:label="t('views.neUser.sub.startIMSI')"
:label="t('views.neUser.auth.startIMSI')"
name="imsi"
v-bind="modalStateBatchDelFrom.validateInfos.imsi"
>
@@ -1327,10 +1267,10 @@ onMounted(() => {
<template #prefix>
<a-tooltip placement="topLeft">
<template #title>
{{ t('views.neUser.sub.imsiTip') }}<br />
{{ t('views.neUser.sub.imsiTip1') }}<br />
{{ t('views.neUser.sub.imsiTip2') }}<br />
{{ t('views.neUser.sub.imsiTip3') }}
{{ t('views.neUser.auth.imsiTip') }}<br />
{{ t('views.neUser.auth.imsiTip1') }}<br />
{{ t('views.neUser.auth.imsiTip2') }}<br />
{{ t('views.neUser.auth.imsiTip3') }}
</template>
<InfoCircleOutlined style="opacity: 0.45; color: inherit" />
</a-tooltip>
@@ -1340,7 +1280,7 @@ onMounted(() => {
</a-col>
<a-col :lg="24" :md="24" :xs="24">
<a-form-item
:label="t('views.neUser.sub.numDel')"
:label="t('views.neUser.auth.numDel')"
name="num"
v-bind="modalStateBatchDelFrom.validateInfos.num"
>