-
Notifications
You must be signed in to change notification settings - Fork 39
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
Adding support for custom actions per table #244
base: master
Are you sure you want to change the base?
Adding support for custom actions per table #244
Conversation
This pull request introduces 1 alert when merging 4246898 into 2194e43 - view on LGTM.com new alerts:
|
@haffi96 This is cool, thanks. I agree that it's something we need to add. Some initial thoughts:
The Vue and Typescript code looks good.
You're right - this is different to hooks, and definitely has it's own unique purpose. |
haha actions was actually my initial choice too (inspired by flask-admin for myself 🤓 ). Decided against it as i saw that there was already some
👍🏽
Yep, that was intentional as i wasn't sure if waiting for the response of an action to process for multiple rows may be kinda weird. But will experiment with this. I agree, would definitely be nice to have it for multiple rows |
This pull request introduces 1 alert when merging b3dcd1d into 2194e43 - view on LGTM.com new alerts:
|
b3dcd1d
to
87f7968
Compare
Can register multiple actions per table now and also select multiple rows at once. Atm, the admin only sends this -> And as you can see i've struggled abit with the css 😆 Will have another go at better aligning the drop down buttons |
87f7968
to
1e89e74
Compare
@haffi96 Cool, thanks! The UI looks good. I think passing just the row IDs should be OK. |
@sinisaos What do you think about this? I think it could be a really useful feature. |
The tests are just failing because it relies on new features in Piccolo API, which haven't been published to PyPI - we need to prioritise getting them released. |
@dantownsend I also think it's useful and similar to Django admin actions. Can you also merge this as our main bulk actions so that we have proper bulk update and delete via orm method instead of iterating through a single method like we do now. After that I can change the Piccolo Admin code. |
This PR has been marked as stale because it has been open for 30 days with no activity. Are there any blockers, or should this be closed? |
Still valid. |
Hey @dantownsend sorry about the delay. I've done some more work on this last week and implemented your suggestions on the piccolo api PR. Just have some unit tests left to do. But quick question, Is this PR dependent on piccolo-orm/piccolo_api#145 being merged first? |
@haffi96 No, this PR is not dependent on piccolo-orm/piccolo_api#145 . It's a completely different PR that provides a solution for propper bulk actions (delete and update) for Piccolo API and Piccolo Admin. |
This PR has been marked as stale because it has been open for 30 days with no activity. Are there any blockers, or should this be closed? |
For this to work, would need this piccolo-orm/piccolo_api#200. These changes would allow us to send row information to the piccolo_api and run the actions