Browse Source

fix database deletion rule

Signed-off-by: ruiyi.jiang <ruiyi.jiang@zilliz.com>
ruiyi.jiang 1 year ago
parent
commit
2ab857dc5b

+ 1 - 1
client/src/i18n/cn/database.ts

@@ -7,7 +7,7 @@ const databaseTrans = {
   databaseName: 'Database Name',
   confirmDatabase: 'Confirm Password',
   deleteTip:
-    'Please select at least one item to drop and default_db can not be dropped.',
+  'Please select at least one item to drop and the default database can not be dropped.',
 };
 
 export default databaseTrans;

+ 1 - 1
client/src/i18n/en/database.ts

@@ -7,7 +7,7 @@ const databaseTrans = {
   databaseName: 'Database Name',
   confirmDatabase: 'Confirm Password',
   deleteTip:
-    'Please select at least one item to drop and default_db can not be dropped.',
+    'Please select at least one item to drop and the default database can not be dropped.',
 };
 
 export default databaseTrans;

+ 1 - 1
client/src/pages/database/Database.tsx

@@ -96,7 +96,7 @@ const Database = () => {
       label: '',
       disabled: () =>
         selectedDatabase.length === 0 ||
-        selectedDatabase.findIndex(v => v.name === 'root') > -1,
+        selectedDatabase.findIndex(v => v.name === 'default') > -1,
       disabledTooltip: dbTrans('deleteTip'),
 
       icon: 'delete',