Browse Source
Merge pull request #19704 from abpframework/hot-fix-extensible-table-actions
Angular (Hot Fix) - Actions Button Dropdown Error
pull/19705/head
Masum ULU
2 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with
6 additions and
2 deletions
-
npm/ng-packs/packages/components/extensible/src/lib/components/extensible-table/extensible-table.component.ts
|
|
|
@ -206,8 +206,12 @@ export class ExtensibleTableComponent<R = any> implements OnChanges { |
|
|
|
}); |
|
|
|
} |
|
|
|
|
|
|
|
hasAvailableActions(index, row): boolean { |
|
|
|
hasAvailableActions(index, data): boolean { |
|
|
|
const { permission, visible } = this.actionList.get(index).value; |
|
|
|
return this.permissionService.getGrantedPolicy(permission) && visible(row); |
|
|
|
let isActionAvailable = this.permissionService.getGrantedPolicy(permission); |
|
|
|
if (data && data.record) { |
|
|
|
isActionAvailable &&= visible(data); |
|
|
|
} |
|
|
|
return isActionAvailable; |
|
|
|
} |
|
|
|
} |
|
|
|
|