Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[feature request] ngRest CRUD: display delete button for some entries only based on a condition #1360

Closed
neumannjan opened this issue Jul 21, 2017 · 2 comments
Assignees
Milestone

Comments

@neumannjan
Copy link

There is currently no way to show the delete button in ngRest CRUD for some entries only, based on a condition.

This would be useful when, for example, some entries were tied to other entries in other tables. Currently, the button is either shown or hidden for all entries.

I tried replacing ['delete', true] with something like ['delete', $this->id == 2], but to no avail - when ngRestScopes() is called, values of the Model instance are not populated: $this->id is null, so $this->id == 2 returns false.

@nadar nadar self-assigned this Jul 22, 2017
@nadar nadar added this to the 1.0.0-RC4 milestone Jul 22, 2017
@nadar
Copy link
Member

nadar commented Jul 22, 2017

@kogli good idea, i will add this after the new admin design merge process.

@luya-bot
Copy link

Issue moved to luyadev/luya-module-admin#16

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants