mirror of
https://github.com/Syngnat/GoNavi.git
synced 2026-07-06 18:41:42 +08:00
🐛 fix(connection): 修复 IRIS 连接类型保存后回退为 MySQL
- 将 IRIS 纳入前端连接类型白名单与默认端口配置 - 补齐常见数据源类型别名归一化,避免未知别名回退为 MySQL - 增加 IRIS 连接保存、导入、自动 Limit 和表数据清空回归测试 - 补齐前后端 IRIS truncate 支持 Refs #476
This commit is contained in:
@@ -8,8 +8,10 @@ describe('tableDataDangerActions', () => {
|
||||
expect(supportsTableTruncateAction('oceanbase')).toBe(true);
|
||||
expect(supportsTableTruncateAction('postgres')).toBe(true);
|
||||
expect(supportsTableTruncateAction('opengauss')).toBe(true);
|
||||
expect(supportsTableTruncateAction('iris')).toBe(true);
|
||||
expect(supportsTableTruncateAction('custom', 'postgresql')).toBe(true);
|
||||
expect(supportsTableTruncateAction('custom', 'kingbase8')).toBe(true);
|
||||
expect(supportsTableTruncateAction('custom', 'intersystemsiris')).toBe(true);
|
||||
});
|
||||
|
||||
it('rejects truncate for unsupported or document-style backends', () => {
|
||||
|
||||
@@ -41,6 +41,8 @@ const resolveCustomDriverDialect = (driver: string): string => {
|
||||
case 'iris':
|
||||
case 'intersystems':
|
||||
case 'intersystemsiris':
|
||||
case 'inter-systems':
|
||||
case 'inter-systems-iris':
|
||||
return 'iris';
|
||||
default:
|
||||
break;
|
||||
@@ -53,6 +55,7 @@ const resolveCustomDriverDialect = (driver: string): string => {
|
||||
if (normalized.includes('highgo')) return 'highgo';
|
||||
if (normalized.includes('vastbase')) return 'vastbase';
|
||||
if (normalized.includes('sqlite')) return 'sqlite';
|
||||
if (normalized.includes('iris') || normalized.includes('intersystems')) return 'iris';
|
||||
if (normalized.includes('sphinx')) return 'sphinx';
|
||||
if (normalized.includes('diros') || normalized.includes('doris')) return 'diros';
|
||||
if (normalized.includes('starrocks')) return 'starrocks';
|
||||
@@ -79,6 +82,7 @@ export const supportsTableTruncateAction = (type: string, driver?: string): bool
|
||||
case 'vastbase':
|
||||
case 'opengauss':
|
||||
case 'sqlserver':
|
||||
case 'iris':
|
||||
case 'oracle':
|
||||
case 'dameng':
|
||||
case 'clickhouse':
|
||||
|
||||
Reference in New Issue
Block a user