From 7f5fef0c8b89902a0e2de71db58755c2ea5ebfb6 Mon Sep 17 00:00:00 2001
From: lai <371757574@qq.com>
Date: Wed, 8 Nov 2023 17:53:58 +0800
Subject: [PATCH] =?UTF-8?q?UDM=E7=AD=BE=E7=BA=A6=E7=94=A8=E6=88=B7?=
=?UTF-8?q?=E5=9B=BD=E9=99=85=E5=8C=96?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/i18n/locales/en-US.ts | 14 ++
src/i18n/locales/zh-CN.ts | 14 ++
src/views/neUser/auth/index.vue | 11 --
src/views/neUser/sub/index.vue | 317 +++++++++++++++-----------------
4 files changed, 173 insertions(+), 183 deletions(-)
diff --git a/src/i18n/locales/en-US.ts b/src/i18n/locales/en-US.ts
index 2d5f10e1..23eba03a 100644
--- a/src/i18n/locales/en-US.ts
+++ b/src/i18n/locales/en-US.ts
@@ -233,6 +233,7 @@ export default {
noListData:'No network element list data yet',
},
sub: {
+ subInfo:' Subscription Info',
neTypePlease: 'Query network element type',
neType: 'UDM Type',
export: 'Export',
@@ -242,7 +243,20 @@ export default {
loadData: 'LoadData',
loadDataTip: 'Successfully obtained updated data: {num} items. The system is updating the data internally. Please do not click repeatedly to obtain updates!!!',
num: 'Number of deletions',
+ batchAddText: 'Batch Add ',
+ batchDelText: 'Batch Del ',
startIMSI: 'Start IMSI',
+ msisdnTip:'Parameter maximum length: {msg}',
+ arfbTip:'Restricted area template. In the restricted area specified by the template, the UE is not allowed to communicate with the network.',
+ sarTip:'Service area restriction template defines the allowed areas in which the UE can communicate with the network; defines the disallowed areas in which the UE and the network are not allowed to initiate Service Request or SM signaling to obtain user services.',
+ micoTip:'Signed MICO business flag',
+ rfspTip:'RFSP index, in NG-RAN, the index of a specific RRM configuration, the parameter is between 0 and 127',
+ epsFlagTip:'Whether to enable 4G EPS service, 0=disable, 1=enable',
+ contextIdTip:'To sign up for the APN context ID, you must select it from the APN Context list.',
+ staticIpTip:'Specify the static IP address used by mobile phone users when surfing the Internet. If it is "-", it means using a dynamic IP address.',
+ epsOdbTip:"ODB (Operator-Determined Barring) operator-determined blocking, that is, the user's business ability to access the EPS network is determined by the operator. Selected --- the corresponding service is allowed Unselected --- the corresponding service is prohibited",
+ hplmnOdbTip:"HPLMN-ODB blocking determined by the home operator, that is, the user's service ability to access the EPS network is determined by the user's home operator. Selected --- the corresponding service is allowed Unselected -- the corresponding service is prohibited",
+ ardTip:'The access control flag (Access-Restriction-Data) can be used to distinguish 2G/3G/LTE users, which facilitates differentiated services for different types of users when 2G/3G/LTE networks coexist.',
},
base5G: {
neTypePlease: 'Query network element type',
diff --git a/src/i18n/locales/zh-CN.ts b/src/i18n/locales/zh-CN.ts
index ca7313f6..152a813b 100644
--- a/src/i18n/locales/zh-CN.ts
+++ b/src/i18n/locales/zh-CN.ts
@@ -233,6 +233,7 @@ export default {
noListData:'暂无网元列表数据',
},
sub: {
+ subInfo:'签约信息',
neTypePlease: '查询网元类型',
neType: 'UDM网元类型',
export: '导出',
@@ -242,7 +243,20 @@ export default {
loadData: '更新数据',
loadDataTip: '成功获取更新数据:{num}条,系统内部进行数据更新,请勿重复点击获取更新!!!',
num: '删除个数',
+ batchAddText: '批量新增',
+ batchDelText: '批量删除',
startIMSI: '起始IMSI',
+ msisdnTip:'参数最大长度{msg}',
+ arfbTip:'限制区域模板,在模板指定的限制区域中,UE 不允许与网络通信',
+ sarTip:'服务区域限制模板,定义允许的区域,UE在这些区域中可以和网络通信;定义不允许的区,UE和网络在这些区域中,不允许发起Service Request 或 SM信令来获取用户服务',
+ micoTip:'签约的MICO业务标志位',
+ rfspTip:'RFSP 索引,在 NG-RAN中,特定RRM配置的索引,参数介于0到127之间',
+ epsFlagTip:'是否开启4G EPS 服务,0=不开启,1=开启',
+ contextIdTip:'签约APN 上下文ID,必须从APN Context list 中选择',
+ staticIpTip:'指定手机用户上网时使用的静态IP地址,为"-"时表示使用动态IP地址',
+ epsOdbTip:'ODB(Operator-Determined Barring)运营商决定的闭锁,即用户接入EPS网络的业务能力由运营商决定.选中 ---对应服务被允许 未选 --- 对应服务被禁止',
+ hplmnOdbTip:'HPLMN-ODB归属运营商决定的闭锁,即用户接入EPS网络的业务能力由用户归宿运营商决定.选中 --- 对应服务被允许 未选 -- 对应服务被禁止',
+ ardTip:'接入控制标志(Access-Restriction-Data),可用于区分2G/3G/LTE用户,便于为2G/3G/LTE网络共存时,对不同类型用户进行区分服务',
},
base5G: {
neTypePlease: '查询网元类型',
diff --git a/src/views/neUser/auth/index.vue b/src/views/neUser/auth/index.vue
index 5f28aec1..5f3a15d5 100644
--- a/src/views/neUser/auth/index.vue
+++ b/src/views/neUser/auth/index.vue
@@ -970,7 +970,6 @@ onMounted(() => {
v-model:value="modalState.from.imsi"
:disabled="modalState.from.id != ''"
allow-clear
- placeholder="请输入IMSI"
>
@@ -986,7 +985,6 @@ onMounted(() => {
@@ -1000,7 +998,6 @@ onMounted(() => {
@@ -1017,7 +1014,6 @@ onMounted(() => {
@@ -1032,7 +1028,6 @@ onMounted(() => {
@@ -1066,7 +1061,6 @@ onMounted(() => {
@@ -1079,7 +1073,6 @@ onMounted(() => {
>
@@ -1096,7 +1089,6 @@ onMounted(() => {
@@ -1109,7 +1101,6 @@ onMounted(() => {
@@ -1126,7 +1117,6 @@ onMounted(() => {
@@ -1140,7 +1130,6 @@ onMounted(() => {
diff --git a/src/views/neUser/sub/index.vue b/src/views/neUser/sub/index.vue
index 4b0b501e..dd5a23ed 100644
--- a/src/views/neUser/sub/index.vue
+++ b/src/views/neUser/sub/index.vue
@@ -250,7 +250,7 @@ let modalState: ModalStateType = reactive({
hplmnOdb: [3, 4],
ard: [1, 7],
epstpl: 'def_eps',
- contextId: '1',
+ contextId: '010200000000',
apnContext: '',
staticIp: '-',
},
@@ -273,7 +273,7 @@ let modalState: ModalStateType = reactive({
hplmnOdb: [3, 4],
ard: [1, 7],
epstpl: 'def_eps',
- contextId: '1',
+ contextId: '010200000000',
apnContext: '',
staticIp: '-',
},
@@ -347,11 +347,13 @@ function PrefixZero(num: any, n: any) {
function fnModalVisibleByBatch(batchFlag?: number) {
if (batchFlag) {
modalStateBatchFrom.resetFields(); //重置表单
- modalState.title = '批量添加签约信息';
+ modalState.title =
+ t('views.neUser.sub.batchAddText') + t('views.neUser.sub.subInfo');
modalState.visibleByBatch = true;
} else {
modalStateBatchFrom.resetFields(); //重置表单
- modalState.title = '批量删除签约信息';
+ modalState.title =
+ t('views.neUser.sub.batchDelText') + t('views.neUser.sub.subInfo');
modalState.visibleByBatchDel = true;
}
}
@@ -363,50 +365,54 @@ function fnModalVisibleByBatch(batchFlag?: number) {
function fnModalVisibleByEdit(imsi?: string) {
if (!imsi) {
modalStateFrom.resetFields();
- modalState.title = '添加签约信息';
+ modalState.title = t('common.addText') + t('views.neUser.sub.subInfo');
modalState.visibleByEdit = true;
} else {
if (modalState.confirmLoading) return;
const hide = message.loading(t('common.loading'), 0);
modalState.confirmLoading = true;
const neID = queryParams.neId || '-';
- getSub(neID, imsi).then(res => {
- modalState.confirmLoading = false;
- hide();
- if (res.code === RESULT_CODE_SUCCESS) {
- let ardAll = parseInt(res.data.ard).toString(2).padStart(8, '0');
- let hplAll = parseInt(res.data.hplmnOdb).toString(2).padStart(8, '0');
- let odbAll = parseInt(res.data.epsOdb).toString(2).padStart(9, '0');
- const ardArray: any[] = [];
- const hplmnArray: any[] = [];
- const epsOdbArray: any[] = [];
- for (let i = 0; i < ardAll.length; i++) {
- if (PrefixZero(ardAll, ardAll.length).charAt(i) === '1') {
- ardArray.push(i);
+ getSub(neID, imsi)
+ .then(res => {
+ if (res.code === RESULT_CODE_SUCCESS) {
+ let ardAll = parseInt(res.data.ard).toString(2).padStart(8, '0');
+ let hplAll = parseInt(res.data.hplmnOdb).toString(2).padStart(8, '0');
+ let odbAll = parseInt(res.data.epsOdb).toString(2).padStart(9, '0');
+ const ardArray: any[] = [];
+ const hplmnArray: any[] = [];
+ const epsOdbArray: any[] = [];
+ for (let i = 0; i < ardAll.length; i++) {
+ if (PrefixZero(ardAll, ardAll.length).charAt(i) === '1') {
+ ardArray.push(i);
+ }
}
- }
- for (let i = 0; i < hplAll.length; i++) {
- if (PrefixZero(hplAll, hplAll.length).charAt(i) === '1') {
- hplmnArray.push(i);
+ for (let i = 0; i < hplAll.length; i++) {
+ if (PrefixZero(hplAll, hplAll.length).charAt(i) === '1') {
+ hplmnArray.push(i);
+ }
}
- }
- for (let i = 0; i < odbAll.length; i++) {
- if (PrefixZero(odbAll, odbAll.length).charAt(i) === '1') {
- epsOdbArray.push(i);
+ for (let i = 0; i < odbAll.length; i++) {
+ if (PrefixZero(odbAll, odbAll.length).charAt(i) === '1') {
+ epsOdbArray.push(i);
+ }
}
- }
- res.data.ard = ardArray;
- res.data.hplmnOdb = hplmnArray;
- res.data.epsOdb = epsOdbArray;
+ res.data.ard = ardArray;
+ res.data.hplmnOdb = hplmnArray;
+ res.data.epsOdb = epsOdbArray;
- modalState.from = Object.assign(modalState.from, res.data);
- modalState.title = '修改签约信息';
- modalState.visibleByEdit = true;
- } else {
- message.error(`获取签约信息失败`, 2);
- }
- });
+ modalState.from = Object.assign(modalState.from, res.data);
+ modalState.title =
+ t('common.editText') + t('views.neUser.sub.subInfo');
+ modalState.visibleByEdit = true;
+ } else {
+ message.error(t('common.getInfoFail'), 2);
+ }
+ })
+ .finally(() => {
+ hide();
+ modalState.confirmLoading = false;
+ });
}
}
@@ -414,9 +420,16 @@ function fnModalVisibleByEdit(imsi?: string) {
const modalStateFrom = Form.useForm(
modalState.from,
reactive({
- imsi: [{ required: true, message: 'IMSI不能为空' }],
- staticIp: [{ required: true, message: '静态IP不能为空' }],
- smData: [{ required: true, message: 'Subscribed SM Data不能为空' }],
+ imsi: [{ required: true, message: 'IMSI' + t('common.unableNull') }],
+ staticIp: [
+ { required: true, message: 'static ip' + t('common.unableNull') },
+ ],
+ smData: [
+ {
+ required: true,
+ message: 'Subscribed SM Data' + t('common.unableNull'),
+ },
+ ],
})
);
@@ -489,11 +502,23 @@ function fnModalOk() {
const modalStateBatchFrom = Form.useForm(
modalState.BatchForm,
reactive({
- num: [{ required: true, message: '放号数不能为空' }],
- imsi: [{ required: true, message: 'IMSI不能为空' }],
- msisdn: [{ required: true, message: 'MSISDN不能为空' }],
- staticIp: [{ required: true, message: '静态IP不能为空' }],
- smData: [{ required: true, message: 'Subscribed SM Data不能为空' }],
+ num: [
+ {
+ required: true,
+ message: t('views.neUser.sub.num') + t('common.unableNull'),
+ },
+ ],
+ imsi: [{ required: true, message: 'IMSI' + t('common.unableNull') }],
+ msisdn: [{ required: true, message: 'MSISDN' + t('common.unableNull') }],
+ staticIp: [
+ { required: true, message: 'static ip' + t('common.unableNull') },
+ ],
+ smData: [
+ {
+ required: true,
+ message: 'Subscribed SM Data' + t('common.unableNull'),
+ },
+ ],
})
);
@@ -567,8 +592,13 @@ function fnBatchModalOk() {
const modalStateBatchDelFrom = Form.useForm(
modalState.BatchDelForm,
reactive({
- num: [{ required: true, message: '放号数不能为空' }],
- imsi: [{ required: true, message: 'IMSI不能为空' }],
+ num: [
+ {
+ required: true,
+ message: t('views.neUser.sub.num') + t('common.unableNull'),
+ },
+ ],
+ imsi: [{ required: true, message: 'IMSI' + t('common.unableNull') }],
})
);
@@ -654,14 +684,14 @@ function fnRecordDelete(imsi: string) {
if (!neID) return;
Modal.confirm({
title: t('common.tipTitle'),
- content: `确认删除IMSI编号为: ${imsi} 的签约用户嘛?`,
+ content: t('views.neUser.auth.delSure', { imsi: imsi }),
onOk() {
const key = 'delSub';
message.loading({ content: t('common.loading'), key });
delSub(neID, imsi).then(res => {
if (res.code === RESULT_CODE_SUCCESS) {
message.success({
- content: `删除成功`,
+ content: t('common.msgSuccess', { msg: t('common.deleteText') }),
key,
duration: 2,
});
@@ -690,7 +720,7 @@ function fnExportList(type: string) {
}).then(res => {
if (res.code === RESULT_CODE_SUCCESS) {
message.success({
- content: `已完成导出`,
+ content: t('common.msgSuccess', { msg: t('common.export') }),
key,
duration: 2,
});
@@ -728,7 +758,7 @@ function fnLoadData() {
}, 3000);
} else {
message.error({
- content: `获取数据失败`,
+ content: t('common.getInfoFail'),
duration: 3,
});
}
@@ -766,7 +796,7 @@ type ModalUploadImportStateType = {
/**对话框表格信息导入对象信息状态 */
let uploadImportState: ModalUploadImportStateType = reactive({
visible: false,
- title: '数据导入',
+ title: t('components.UploadModal.uploadTitle'),
loading: false,
msg: '',
});
@@ -790,16 +820,16 @@ function fnModalUploadImportUpload(file: File) {
formData.append('file', file);
const neID = queryParams.neId;
if (!neID) {
- return Promise.reject('未知网元');
+ return Promise.reject('Unknown network element');
}
- const hide = message.loading('正在上传...', 0);
+ const hide = message.loading(t('common.loading'), 0);
uploadImportState.loading = true;
importSubData(neID, formData)
.then(res => {
uploadImportState.msg = res.msg;
})
.catch((err: { code: number; msg: string }) => {
- message.error(`上传失败 ${err.msg}`);
+ message.error(` ${err.msg}`);
})
.finally(() => {
hide();
@@ -827,7 +857,7 @@ onMounted(() => {
}
} else {
message.warning({
- content: `暂无网元列表数据`,
+ content: t('views.neUser.auth.noListData'),
duration: 2,
});
}
@@ -861,20 +891,12 @@ onMounted(() => {
-
+
-
+
@@ -1089,17 +1111,11 @@ onMounted(() => {
name="imsi"
v-bind="modalStateFrom.validateInfos.imsi"
>
-
+
- SUPI=MCC+MNC+MSIN MCC=移动国家号码, 由三位数字组成
- MNC=移动网络号,由两位数字组成
- MSIN=移动客户识别码,采用等长10位数字构成
+ {{ t('views.neUser.auth.imsiTip') }}
@@ -1113,14 +1129,12 @@ onMounted(() => {
name="msisdn"
v-bind="modalStateFrom.validateInfos.msisdn"
>
-
+
- 参数最大长度32
+
+ {{ t('views.neUser.sub.msisdnTip', { msg: '32' }) }}
+
@@ -1163,7 +1177,9 @@ onMounted(() => {
- 参数最大长度为16
+
+ {{ t('views.neUser.sub.msisdnTip', { msg: '16' }) }}
+
@@ -1176,7 +1192,7 @@ onMounted(() => {
- 限制区域模板,在模板指定的限制区域中,UE 不允许与网络通信
+ {{ t('views.neUser.sub.arfbTip') }}
@@ -1196,10 +1212,7 @@ onMounted(() => {
- 服务区域限制模板,定义允许的区域,UE
- 在这些区域中可以和网络通信;定义不允许的区,UE
- 和网络在这些区域中,不允许发起Service Request 或 SM
- 信令来获取用户服务
+ {{ t('views.neUser.sub.sarTip') }}
@@ -1209,7 +1222,7 @@ onMounted(() => {
-
+
Enable
Disable
@@ -1226,7 +1239,7 @@ onMounted(() => {
- RFSP 索引,在 NG-RAN中,特定RRM配置的索引,参数介于0到127之间
+ {{ t('views.neUser.sub.rfspTip') }}
@@ -1253,7 +1266,9 @@ onMounted(() => {
- 参数最大长度为128
+
+ {{ t('views.neUser.sub.msisdnTip', { msg: '128' }) }}
+
@@ -1263,7 +1278,7 @@ onMounted(() => {
-
+
Enable
Disable
@@ -1278,7 +1293,9 @@ onMounted(() => {
- 参数最大长度为128
+
+ {{ t('views.neUser.sub.msisdnTip', { msg: '128' }) }}
+
@@ -1288,7 +1305,7 @@ onMounted(() => {
-
+
Enable
Disable
@@ -1305,12 +1322,10 @@ onMounted(() => {
name="epstpl"
v-bind="modalStateFrom.validateInfos.epstpl"
>
-
-
+
+
@@ -1321,12 +1336,8 @@ onMounted(() => {
name="contextId"
v-bind="modalStateFrom.validateInfos.contextId"
>
-
-
+
+
@@ -1340,15 +1351,11 @@ onMounted(() => {
v-bind="modalStateFrom.validateInfos.staticIp"
name="staticIp"
>
-
+
- 指定手机用户上网时使用的静态IP地址,为"-"时表示使用动态IP地址
+ {{ t('views.neUser.sub.staticIpTip') }}
@@ -1363,9 +1370,7 @@ onMounted(() => {
name="epsOdb"
v-bind="modalStateFrom.validateInfos.epsOdb"
>
-
+
{
-
+
@@ -1396,25 +1397,14 @@ onMounted(() => {
-
+
-
-
-
- 指定手机用户上网时使用的静态IP地址,为"-"时表示使用动态IP地址
-
-
-
-
@@ -1448,7 +1438,6 @@ onMounted(() => {
>
@@ -1461,17 +1450,11 @@ onMounted(() => {
name="imsi"
v-bind="modalStateBatchFrom.validateInfos.imsi"
>
-
+
- SUPI=MCC+MNC+MSIN MCC=移动国家号码, 由三位数字组成
- MNC=移动网络号,由两位数字组成
- MSIN=移动客户识别码,采用等长10位数字构成
+ {{ t('views.neUser.auth.imsiTip') }}
@@ -1485,14 +1468,12 @@ onMounted(() => {
name="msisdn"
v-bind="modalStateBatchFrom.validateInfos.msisdn"
>
-
+
- 参数最大长度32
+
+ {{ t('views.neUser.sub.msisdnTip', { msg: '32' }) }}
+
@@ -1531,7 +1512,9 @@ onMounted(() => {
- 参数最大长度为16
+
+ {{ t('views.neUser.sub.msisdnTip', { msg: '16' }) }}
+
@@ -1545,7 +1528,7 @@ onMounted(() => {
- 限制区域模板,在模板指定的限制区域中,UE 不允许与网络通信
+ {{ t('views.neUser.sub.arfbTip') }}
@@ -1565,10 +1548,7 @@ onMounted(() => {
- 服务区域限制模板,定义允许的区域,UE
- 在这些区域中可以和网络通信;定义不允许的区,UE
- 和网络在这些区域中,不允许发起Service Request 或 SM
- 信令来获取用户服务
+ {{ t('views.neUser.sub.sarTip') }}
@@ -1582,7 +1562,7 @@ onMounted(() => {
- RFSP 索引,在 NG-RAN中,特定RRM配置的索引,参数介于0到127之间
+ {{ t('views.neUser.sub.rfspTip') }}
@@ -1595,7 +1575,7 @@ onMounted(() => {
-
+
Enable
Disable
@@ -1622,7 +1602,9 @@ onMounted(() => {
- 参数最大长度为128
+
+ {{ t('views.neUser.sub.msisdnTip', { msg: '128' }) }}
+
@@ -1632,7 +1614,7 @@ onMounted(() => {
-
+
Enable
Disable
@@ -1645,11 +1627,10 @@ onMounted(() => {
-
+
@@ -1657,11 +1638,10 @@ onMounted(() => {
-
+
@@ -1678,12 +1658,11 @@ onMounted(() => {
- 指定手机用户上网时使用的静态IP地址,为"-"时表示使用动态IP地址
+ {{ t('views.neUser.sub.staticIpTip') }}
@@ -1695,13 +1674,12 @@ onMounted(() => {
@@ -1711,14 +1689,13 @@ onMounted(() => {
@@ -1728,13 +1705,12 @@ onMounted(() => {
@@ -1776,9 +1752,7 @@ onMounted(() => {
- SUPI=MCC+MNC+MSIN MCC=移动国家号码, 由三位数字组成
- MNC=移动网络号,由两位数字组成
- MSIN=移动客户识别码,采用等长10位数字构成
+ {{ t('views.neUser.auth.imsiTip') }}
@@ -1794,7 +1768,6 @@ onMounted(() => {
>