refactor: unavailableActions to sql collection and view collection (#6765)

* refactor: unavailableActions to sql collection and view collection

* fix: unavailableActions
This commit is contained in:
Katherine 2025-04-24 20:09:42 +08:00 committed by GitHub
parent 24376fd3dd
commit e2e4c69941
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 3 additions and 3 deletions

View File

@ -26,7 +26,7 @@ export class ViewCollection extends Collection {
return [];
}
return ['create', 'update', 'destroy'];
return ['create', 'update', 'destroy', 'importXlsx', 'destroyMany', 'updateMany'];
}
protected sequelizeModelOptions(): any {

View File

@ -34,7 +34,7 @@ export class PluginActionImportClient extends Plugin {
skipScopeCheck: true,
},
},
useVisible: () => useActionAvailable('import'),
useVisible: () => useActionAvailable('importXlsx'),
};
const tableActionInitializers = this.app.schemaInitializerManager.get('table:configureActions');

View File

@ -42,7 +42,7 @@ export class SQLCollection extends Collection {
}
unavailableActions(): Array<string> {
return ['create', 'update', 'destroy'];
return ['create', 'update', 'destroy', 'importXlsx', 'destroyMany', 'updateMany'];
}
public collectionSchema() {