Port Local Admin Standing Penalties UI to Angular

Bug #1840327 reported by Kyle Huckins
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Evergreen
Fix Released
Wishlist
Unassigned

Bug Description

Port of the Local Administration → Standing Penalty Types UI from Dojo to Angular. This is a grid UI, with features necessary to add and delete new standing penalty types. All names should be read-only when under 100. IDs should be as well, but that should already be the case(they’re non-editable primary keys)

Additionally, we’ll want to implement isReadOnlyOverride() function to fm-editor.component.ts as a field/record-level callback.

Mike Risher (mrisher)
Changed in evergreen:
assignee: nobody → Mike Risher (mrisher)
Revision history for this message
Mike Risher (mrisher) wrote :
Changed in evergreen:
assignee: Mike Risher (mrisher) → nobody
tags: added: pullrequest
Bill Erickson (berick)
Changed in evergreen:
assignee: nobody → Bill Erickson (berick)
Revision history for this message
Bill Erickson (berick) wrote :

Thanks, Mike. Reviewing code and I have some suggestions.

1. For consistency and added flexibility, I suggest making the new isReadonlyOverride function behave the same as the existing isRequiredOverride function. I've pushed a commit w/ sandbox example here that does that:

https://git.evergreen-ils.org/?p=working/Evergreen.git;a=shortlog;h=refs/heads/user/berick/lp1840327-ang-standing-penalties

2. Avoid adding CSS for things like '.red', when you can use bootstrap classes instead (e.g. text-danger).

3. I think this is a good use case for the rowFlairCallback functionality in the grid. It allows you to set icons and tooltip/title text describing the purpose of the "flair". See rowFlairIsEnabled and rowFlairCallback in the Sandbox. Note to set the flair title, it will require an in-template <eg-string /> for i18n support.

Changed in evergreen:
assignee: Bill Erickson (berick) → nobody
status: New → Confirmed
Mike Risher (mrisher)
Changed in evergreen:
assignee: nobody → Mike Risher (mrisher)
Revision history for this message
Mike Risher (mrisher) wrote :

Thanks for the suggestions Bill. I've implemented all 3 and this is ready for another look:

https://git.evergreen-ils.org/?p=working/Evergreen.git;a=commit;h=32f8e25703c3f4c7b370cdaa96d6662441e0518f

Changed in evergreen:
assignee: Mike Risher (mrisher) → nobody
Galen Charlton (gmc)
Changed in evergreen:
importance: Undecided → Wishlist
Revision history for this message
Galen Charlton (gmc) wrote :

Merged to master for inclusion in 3.4. Thanks, Mike!

I did add release notes as well as a follow-up patch to make the following changes:

    * Fixed inabiilty to set the name for a new standing penalty
    * Fixed the 'Delete Selected' action
    * adjust for recId => recordId change to FM record editor
    * remove a bit of copy-and-paste-itis
    * Lint repairs

Changed in evergreen:
status: Confirmed → Fix Committed
milestone: none → 3.4-beta1
Galen Charlton (gmc)
Changed in evergreen:
status: Fix Committed → Fix Released
Revision history for this message
Mike Risher (mrisher) wrote :

2 issues have come to light:

* Double clicking on a row of the table isn't letting you edit
* After adding a new record, the page isn't being refreshed to show you that the new record was successfully added. When manually refreshing the new data does show up, however.

Revision history for this message
Galen Charlton (gmc) wrote :

Thanks for finding these issues, Mike. Could you open a new bug report for them? Follow-ups on a fix-committed or fix-released bug are easy to miss otherwise.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.