File tree Expand file tree Collapse file tree 2 files changed +4
-9
lines changed Expand file tree Collapse file tree 2 files changed +4
-9
lines changed Original file line number Diff line number Diff line change @@ -302,10 +302,7 @@ function getDBActionsColumn({
302
302
render : ( { row} ) => {
303
303
const menuItems : ( DropdownMenuItem | DropdownMenuItem [ ] ) [ ] = [ ] ;
304
304
305
- const databaseId = row . UserAttributes ?. database_id ;
306
- const databaseName = row . Name ;
307
-
308
- if ( clusterName && isEditDBAvailable ) {
305
+ if ( isEditDBAvailable ) {
309
306
menuItems . push ( {
310
307
text : i18n ( 'edit' ) ,
311
308
iconStart : < Pencil /> ,
@@ -317,15 +314,14 @@ function getDBActionsColumn({
317
314
} ,
318
315
} ) ;
319
316
}
320
- if ( clusterName && isDeleteDBAvailable && databaseName && databaseId ) {
317
+ if ( isDeleteDBAvailable ) {
321
318
menuItems . push ( {
322
319
text : i18n ( 'remove' ) ,
323
320
iconStart : < TrashBin /> ,
324
321
action : ( ) => {
325
322
uiFactory . onDeleteDB ?.( {
326
323
clusterName,
327
- databaseId,
328
- databaseName,
324
+ databaseData : row ,
329
325
} ) ;
330
326
} ,
331
327
className : b ( 'remove-db' ) ,
Original file line number Diff line number Diff line change @@ -21,6 +21,5 @@ export type HandleEditDB = (params: {
21
21
22
22
export type HandleDeleteDB = ( params : {
23
23
clusterName : string ;
24
- databaseName : string ;
25
- databaseId : string ;
24
+ databaseData : PreparedTenant ;
26
25
} ) => Promise < boolean > ;
You can’t perform that action at this time.
0 commit comments