Merge branch 'main' into multi-tenant

This commit is contained in:
lai
2024-10-31 17:34:38 +08:00
62 changed files with 182531 additions and 3511 deletions

View File

@@ -193,7 +193,6 @@ function fnTableSelectedRows(
_: (string | number)[],
rows: Record<string, string>[]
) {
//debugger
tableState.selectedRowKeys = rows.map(item => item.loginId);
// 针对单个登录账号解锁
if (rows.length === 1) {

View File

@@ -139,7 +139,7 @@ let tableColumns: any = [
* 测试主机连接
*/
function fnHostTest(row: Record<string, any>) {
if (tabState.confirmLoading || !row.addr) return;
if (tabState.confirmLoading || !row.addr || !row.port) return;
tabState.confirmLoading = true;
const hide = message.loading(t('common.loading'), 0);
testNeHost(row)
@@ -187,19 +187,19 @@ function fnHostAuthorized(row: Record<string, any>) {
* 表单修改网元类型
*/
function fnNeTypeChange(v: any, data: any) {
const hostsLen = data.hosts.length;
// 网元默认只含22和4100
if (hostsLen === 3 && v !== 'UPF') {
data.hosts.pop();
if (modalState.from.hosts.length === 3) {
modalState.from.hosts.pop();
}
const hostsLen = modalState.from.hosts.length;
// UPF标准版本可支持5002
if (hostsLen === 2 && v === 'UPF') {
data.hosts.push({
modalState.from.hosts.push({
hostId: undefined,
hostType: 'telnet',
groupId: '1',
title: 'Telnet_NE_5002',
addr: '',
addr: modalState.from.ip,
port: 5002,
user: 'admin',
authMode: '0',
@@ -207,6 +207,22 @@ function fnNeTypeChange(v: any, data: any) {
remark: '',
});
}
// UDM可支持6379
if (hostsLen === 2 && v === 'UDM') {
modalState.from.hosts.push({
hostId: undefined,
hostType: 'redis',
groupId: '1',
title: 'REDIS_NE_6379',
addr: modalState.from.ip,
port: 6379,
user: 'udmdb',
authMode: '0',
password: 'helloearth',
dbName: '0',
remark: '',
});
}
}
//打开新增或修改界面

View File

@@ -147,6 +147,9 @@ function fnGetList() {
case 'N3IWF':
state.from.sbi.n3iwf_ip = item.ip;
break;
case 'SMSC':
state.from.sbi.smsc_ip = item.ip;
break;
}
}
}

View File

@@ -71,7 +71,7 @@ onMounted(() => {
<a-input
v-model:value="state.copyright"
allow-clear
:maxlength="40"
:maxlength="128"
:placeholder="t('common.inputPlease')"
></a-input>
</a-form-item>
@@ -101,7 +101,7 @@ onMounted(() => {
<a-typography>
<a-typography-paragraph>
{{ t('views.system.setting.sysCopyrightLimitation') }}
<a-typography-text mark>40</a-typography-text>
<a-typography-text mark>128</a-typography-text>
{{ t('views.system.setting.charMaxLen') }}
</a-typography-paragraph>
</a-typography>

View File

@@ -1,14 +1,11 @@
<script lang="ts" setup>
import { Modal, message } from 'ant-design-vue/lib';
import { onMounted, reactive, toRaw } from 'vue';
import useAppStore from '@/store/modules/app';
import useI18n from '@/hooks/useI18n';
import { listMenu } from '@/api/system/menu';
import { RESULT_CODE_SUCCESS } from '@/constants/result-constants';
import { getConfig, getConfigKey, changeValue } from '@/api/system/config';
const appStore = useAppStore();
const { t, optionsLocale } = useI18n();
import { getConfigKey, changeValue } from '@/api/system/config';
const { t } = useI18n();
type StateType = {
edite: boolean;