pet-rescue icon indicating copy to clipboard operation
pet-rescue copied to clipboard

1019 enable staff to update fosterer info

Open Meri-MG opened this issue 1 year ago • 2 comments

🔗 Issue

#1019

✍️ Description

  • Added update and edit action to the FosterersController
  • Added update_fosterers ability to FostererInvitationPolicy for update? and edit? actions(I figured nobody should be seeing the edit form if they don't have permission to perform the update action?)
  • Removed Joined At column from the fosterers table
  • Added email, and phone columns to the table and left action column for the Edit link
  • Moved form errors into the partial

P.S. @kasugaijin I'm unsure why we are advised to use turbo frames here?

📷 Screenshots/Demos

Screenshot 2024-10-10 at 13 03 43 Screenshot 2024-10-09 at 14 17 14

dave

Meri-MG avatar Oct 09 '24 11:10 Meri-MG

@Meri-MG thanks for the PR - it might take me a couple days before I get to review it - busy times. Hopefully someone else can also drop a review.

Please run rails standard:fix to pass the linter

kasugaijin avatar Oct 09 '24 14:10 kasugaijin

@Meri-MG no need to use turbo frames! That was optional. The redirects work fine. We could use a frame to handle it all in the same page without redirects, but that is not necessary.

Could you please update the edit buttons to match those used elsewhere? See the staff FAQ page for example. image

I will do a full review, soon!

kasugaijin avatar Oct 09 '24 22:10 kasugaijin

hello, @kasugaijin , had some busy days and addressed the feedback just now. I reverted the change with the form errors partial. thank you 🙏

Meri-MG avatar Oct 16 '24 07:10 Meri-MG