From 5d35d950b3f39c7e955527ed412c6d147677985b Mon Sep 17 00:00:00 2001 From: TsMask <340112800@qq.com> Date: Thu, 5 Sep 2024 17:29:12 +0800 Subject: [PATCH 1/3] =?UTF-8?q?feat:=20=E7=BD=91=E5=85=83=E5=8F=82?= =?UTF-8?q?=E6=95=B0=E9=85=8D=E7=BD=AE=E7=89=B9=E6=AE=8ASMF-upfid=E9=80=89?= =?UTF-8?q?=E6=8B=A9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/ne/neConfig/hooks/useConfigArray.ts | 65 +++++++++++++++++++ src/views/ne/neConfig/index.vue | 5 +- 2 files changed, 69 insertions(+), 1 deletion(-) diff --git a/src/views/ne/neConfig/hooks/useConfigArray.ts b/src/views/ne/neConfig/hooks/useConfigArray.ts index da74fd28..988a819c 100644 --- a/src/views/ne/neConfig/hooks/useConfigArray.ts +++ b/src/views/ne/neConfig/hooks/useConfigArray.ts @@ -67,6 +67,22 @@ export default function useConfigArray({ row[v.name] = Object.assign({}, v); } + // 特殊SMF-upfid选择 + if (neTypeSelect.value[0] === 'SMF' && Reflect.has(row, 'upfId')) { + const v = row.upfId.value; + if (typeof v === 'string') { + if (v === '') { + row.upfId.value = []; + } else if (v.includes(';')) { + row.upfId.value = v.split(';'); + } else if (v.includes(',')) { + row.upfId.value = v.split(','); + } else { + row.upfId.value = [v]; + } + } + } + modalState.from = row; modalState.type = 'arrayEdit'; modalState.title = `${treeState.selectNode.paramDisplay} ${from.title}`; @@ -87,6 +103,15 @@ export default function useConfigArray({ /**多列表编辑确认 */ function arrayEditOk(from: Record) { const loc = `${from['index']['value']}`; + + // 特殊SMF-upfid选择 + if (neTypeSelect.value[0] === 'SMF' && Reflect.has(from, 'upfId')) { + const v = from.upfId.value; + if (Array.isArray(v)) { + from.upfId.value = v.join(';'); + } + } + // 遍历提取属性和值 let data: Record = {}; for (const key in from) { @@ -187,6 +212,22 @@ export default function useConfigArray({ row[v.name] = Object.assign({}, v); } + // 特殊SMF-upfid选择 + if (neTypeSelect.value[0] === 'SMF' && Reflect.has(row, 'upfId')) { + const v = row.upfId.value; + if (typeof v === 'string') { + if (v === '') { + row.upfId.value = []; + } else if (v.includes(';')) { + row.upfId.value = v.split(';'); + } else if (v.includes(',')) { + row.upfId.value = v.split(','); + } else { + row.upfId.value = [v]; + } + } + } + modalState.from = row; modalState.type = 'arrayAdd'; modalState.title = `${treeState.selectNode.paramDisplay} ${from.title}`; @@ -197,6 +238,14 @@ export default function useConfigArray({ /**多列表新增单行确认 */ function arrayAddOk(from: Record) { + // 特殊SMF-upfid选择 + if (neTypeSelect.value[0] === 'SMF' && Reflect.has(from, 'upfId')) { + const v = from.upfId.value; + if (Array.isArray(v)) { + from.upfId.value = v.join(';'); + } + } + // 遍历提取属性和值 let data: Record = {}; for (const key in from) { @@ -321,6 +370,22 @@ export default function useConfigArray({ if ('bool' === row.type) { row.value = Boolean(row.value); } + + // 特殊SMF-upfid选择 + if (neTypeSelect.value[0] === 'SMF' && row.name === 'upfId') { + const v = row.value; + if (typeof v === 'string') { + if (v === '') { + row.value = []; + } else if (v.includes(';')) { + row.value = v.split(';'); + } else if (v.includes(',')) { + row.value = v.split(','); + } else { + row.value = [v]; + } + } + } } return ruleFrom; } diff --git a/src/views/ne/neConfig/index.vue b/src/views/ne/neConfig/index.vue index e9ef9ad8..405c85f7 100644 --- a/src/views/ne/neConfig/index.vue +++ b/src/views/ne/neConfig/index.vue @@ -589,7 +589,7 @@ onMounted(() => { @dblclick="listEdit(record)" > { v-model:value="modalState.from[item.name]['value']" :options="smfByUPFIdOptions" :disabled="['read-only', 'read', 'ro'].includes(item.access)" + :token-separators="[',', ';']" + mode="multiple" + :max-tag-count="5" :allow-clear="true" style="width: 100%" > From 147a3ed77bea920b6b1f291ca388cd327cbe51f7 Mon Sep 17 00:00:00 2001 From: TsMask <340112800@qq.com> Date: Thu, 5 Sep 2024 17:30:11 +0800 Subject: [PATCH 2/3] =?UTF-8?q?style:=20=E8=B7=9F=E8=B8=AA=E4=BB=BB?= =?UTF-8?q?=E5=8A=A1=E5=A4=9A=E8=AF=AD=E8=A8=80=E7=BF=BB=E8=AF=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/i18n/locales/en-US.ts | 9 +++++++-- src/i18n/locales/zh-CN.ts | 9 +++++++-- src/views/perfManage/taskManage/index.vue | 4 ++-- src/views/traceManage/task/index.vue | 6 +++--- 4 files changed, 19 insertions(+), 9 deletions(-) diff --git a/src/i18n/locales/en-US.ts b/src/i18n/locales/en-US.ts index 23c04e36..9bd7e61f 100644 --- a/src/i18n/locales/en-US.ts +++ b/src/i18n/locales/en-US.ts @@ -1122,6 +1122,9 @@ export default { trackType: 'Tracing Type', trackTypePlease: 'Please select a tracing type', creater: 'Created by', + textStop: "Stop", + status: 'Status', + time: 'Time', startTime: 'Start Time', endTime: 'End Time', msisdn: 'MSISDN', @@ -1143,14 +1146,16 @@ export default { signalPortTip: 'Port corresponding to the interface', rangePicker: 'Start/End Time', rangePickerPlease: 'Please select the start and end time of the task', - comment: 'Task Description', - commentPlease: 'Task description can be entered', + remark: 'Task Description', + remarkPlease: 'Task description can be entered', addTask: 'Add Task', editTask: 'Modify Task', viewTask: 'View Task', errorTaskInfo: 'Failed to obtain task information', delTask: 'Successfully deleted task {num}', delTaskTip: 'Are you sure to delete the data item with record number {num}?', + stopTask: 'Successful cessation of tasks {num}', + stopTaskTip: 'Confirm stopping the task with record number {num}?', }, }, faultManage: { diff --git a/src/i18n/locales/zh-CN.ts b/src/i18n/locales/zh-CN.ts index 001c19a8..4a918462 100644 --- a/src/i18n/locales/zh-CN.ts +++ b/src/i18n/locales/zh-CN.ts @@ -1122,6 +1122,9 @@ export default { trackType: '跟踪类型', trackTypePlease: '请选择跟踪类型', creater: '创建人', + textStop: "停止", + status: '状态', + time: '时间', startTime: '开始时间', endTime: '结束时间', msisdn: 'MSISDN', @@ -1143,14 +1146,16 @@ export default { signalPortTip: '接口对应的端口', rangePicker: '开始结束时间', rangePickerPlease: '请选择任务时间开始结束时间', - comment: '任务说明', - commentPlease: '可输入任务说明', + remark: '任务说明', + remarkPlease: '可输入任务说明', addTask: '添加任务', editTask: '修改任务', viewTask: '查看任务', errorTaskInfo: '获取任务信息失败', delTask: '成功删除任务 {num}', delTaskTip: '确认删除记录编号为 {num} 的数据项?', + stopTask: '成功停止任务 {num}', + stopTaskTip: '确认停止记录编号为 {num} 的任务?', }, }, faultManage: { diff --git a/src/views/perfManage/taskManage/index.vue b/src/views/perfManage/taskManage/index.vue index 2db44f35..a2be812b 100644 --- a/src/views/perfManage/taskManage/index.vue +++ b/src/views/perfManage/taskManage/index.vue @@ -1128,7 +1128,7 @@ onMounted(() => { { :auto-size="{ minRows: 2, maxRows: 6 }" :maxlength="250" :show-count="true" - :placeholder="t('views.traceManage.task.commentPlease')" + :placeholder="t('views.traceManage.task.remarkPlease')" /> diff --git a/src/views/traceManage/task/index.vue b/src/views/traceManage/task/index.vue index d56dc00f..707c8d5c 100644 --- a/src/views/traceManage/task/index.vue +++ b/src/views/traceManage/task/index.vue @@ -828,7 +828,7 @@ onMounted(() => { > {{ modalState.from.comment }} @@ -1036,7 +1036,7 @@ onMounted(() => { > { :auto-size="{ minRows: 2, maxRows: 6 }" :maxlength="250" :show-count="true" - :placeholder="t('views.traceManage.task.commentPlease')" + :placeholder="t('views.traceManage.task.remarkPlease')" /> From e3f83a0b9863da10526f24ff4b0f4697d158523e Mon Sep 17 00:00:00 2001 From: TsMask <340112800@qq.com> Date: Thu, 5 Sep 2024 17:30:31 +0800 Subject: [PATCH 3/3] =?UTF-8?q?feat:=20=E8=B7=9F=E8=B8=AA=E4=BB=BB?= =?UTF-8?q?=E5=8A=A1=E5=8A=9F=E8=83=BD=E9=A1=B5=E9=9D=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/traceManage/taskHLR.ts | 52 ++ src/views/traceManage/task-hlr/index.vue | 641 +++++++++++++++++++++++ 2 files changed, 693 insertions(+) create mode 100644 src/api/traceManage/taskHLR.ts create mode 100644 src/views/traceManage/task-hlr/index.vue diff --git a/src/api/traceManage/taskHLR.ts b/src/api/traceManage/taskHLR.ts new file mode 100644 index 00000000..4bdb9a88 --- /dev/null +++ b/src/api/traceManage/taskHLR.ts @@ -0,0 +1,52 @@ +import { request } from '@/plugins/http-fetch'; + +/** + * 查询跟踪任务列表 + * @param query 查询参数 + * @returns object + */ +export function listTaskHLR(query: Record) { + return request({ + url: '/trace/task/hlr/list', + method: 'get', + params: query, + }); +} + +/** + * 跟踪任务删除 + * @param ids 任务ID + * @returns object + */ +export function delTaskHLR(ids: string | number) { + return request({ + url: `/trace/task/hlr/${ids}`, + method: 'delete', + }); +} + +/** + * 跟踪任务创建 + * @param data 对象 + * @returns object + */ +export function startTaskHLR(data: Record) { + return request({ + url: '/trace/task/hlr/start', + method: 'post', + data: data, + }); +} + +/** + * 跟踪任务停止 + * @param data 对象 + * @returns object + */ +export function stopTaskHLR(data: Record) { + return request({ + url: '/trace/task/hlr/stop', + method: 'post', + data: data, + }); +} diff --git a/src/views/traceManage/task-hlr/index.vue b/src/views/traceManage/task-hlr/index.vue new file mode 100644 index 00000000..f69713c0 --- /dev/null +++ b/src/views/traceManage/task-hlr/index.vue @@ -0,0 +1,641 @@ + + + + +