fix: 网元信息新增OMC配置应该没有telnet
This commit is contained in:
@@ -223,6 +223,12 @@ function fnModalVisibleByEdit(editId: string) {
|
||||
modalState.confirmLoading = false;
|
||||
hide();
|
||||
if (res.code === RESULT_CODE_SUCCESS) {
|
||||
// OMC没有telnet
|
||||
if (res.data.neType === 'OMC') {
|
||||
res.data.hosts = res.data.hosts.filter(
|
||||
(s: any) => s.hostType === 'ssh'
|
||||
);
|
||||
}
|
||||
Object.assign(modalState.from, res.data);
|
||||
modalState.title = t('views.ne.neInfo.editTitle');
|
||||
modalState.visibleByEdit = true;
|
||||
@@ -286,6 +292,10 @@ function fnModalCancel() {
|
||||
*/
|
||||
function fnNeTypeChange(v: any) {
|
||||
const hostsLen = modalState.from.hosts.length;
|
||||
// OMC没有telnet
|
||||
if (hostsLen >= 2 && v === 'OMC') {
|
||||
modalState.from.hosts.splice(1, hostsLen);
|
||||
}
|
||||
// 网元默认只含22和4100
|
||||
if (hostsLen === 3 && v !== 'UPF') {
|
||||
modalState.from.hosts.pop();
|
||||
|
||||
Reference in New Issue
Block a user