Uploaded image for project: 'Kuali Rice Development'
  1. Kuali Rice Development
  2. KULRICE-5367

Uif Framework - Collections: Delete line should appear if the line is new or always allow deletion is specified on document entry

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 2.5
    • Security Level: Public (Public: Anyone can view)
    • Labels:
      None
    • Rice Module:
      KRAD
    • Sprint:
      Core 2.5.0-m6 Sprint 1, Core 2.5.0-m6 Sprint 2
    • KAI Review Status:
      Not Required
    • KTI Review Status:
      Not Required
    • Story Points:
      3

      Description

      See TO DO in comments

      Collections should allow the delete button for an existing collection record by default if the line is new or
      always allow line deletion is set to true. Currently this flag is set on the MaintenanceDocumentEntry. We should move
      it up to the DocumentEntry and also have the flag that can be set on the CollectionGroup. If not set on the CollectionGroup
      and their is an associated document entry it will default to that. If not set should be false. when set to true if overrides
      the check for new line.

      As a developer I want to configure when a collection line can be deleted with the available options of "never", only newly added items or all items.

        Attachments

          Issue Links

            Activity

            jkneal Jerry Neal (Inactive) created issue -
            jkneal Jerry Neal (Inactive) made changes -
            Field Original Value New Value
            Link This issue relies on KULRICE-5345 [ KULRICE-5345 ]
            jcoltrin Jessica Coltrin (Inactive) made changes -
            Rice Lead sgibson
            Hide
            jcoltrin Jessica Coltrin (Inactive) added a comment -

            double-tagging with 2.0.0-b3 for review.

            Show
            jcoltrin Jessica Coltrin (Inactive) added a comment - double-tagging with 2.0.0-b3 for review.
            jcoltrin Jessica Coltrin (Inactive) made changes -
            Fix Version/s 2.0.0-b3 [ 16375 ]
            jcoltrin Jessica Coltrin (Inactive) made changes -
            Start Date
            Fix Date 2011-12-05 [ set to sprint end date ]
            sgibson Scott Gibson (Inactive) made changes -
            Fix Version/s 2.0.0-b4 [ 16376 ]
            Fix Version/s 2.0.0-b3 [ 16375 ]
            sgibson Scott Gibson (Inactive) made changes -
            Start Date
            Fix Date 2011-12-05 2011-12-19 [ set to sprint end date ]
            sgibson Scott Gibson (Inactive) made changes -
            Fix Version/s 2.1 [ 15812 ]
            Fix Version/s 2.0 [ 14190 ]
            Fix Version/s 2.0.0-b4 [ 16376 ]
            sgibson Scott Gibson (Inactive) made changes -
            Start Date
            Fix Date 2011-12-19 [ set to sprint end date ]
            jcoltrin Jessica Coltrin (Inactive) made changes -
            Fix Version/s 2.2 [ 16411 ]
            Fix Version/s 2.1 [ 15812 ]
            jcoltrin Jessica Coltrin (Inactive) made changes -
            Start Date
            Fix Date [ set to sprint end date ]
            jkneal Jerry Neal (Inactive) made changes -
            Rice Lead sgibson jkneal
            jcoltrin Jessica Coltrin (Inactive) made changes -
            Fix Version/s 2.2-backlog [ 16475 ]
            jcoltrin Jessica Coltrin (Inactive) made changes -
            Start Date
            Fix Date [ set to sprint end date ]
            jcoltrin Jessica Coltrin (Inactive) made changes -
            Fix Version/s 2.2.1 [ 16733 ]
            Fix Version/s 2.2 [ 16411 ]
            Fix Version/s 2.2-backlog [ 16475 ]
            masargen Matt Sargent made changes -
            Link This issue relates to KRRM-144 [ KRRM-144 ]
            jcoltrin Jessica Coltrin (Inactive) made changes -
            Fix Version/s 2.3-backlog [ 16596 ]
            Fix Version/s 2.2.1 [ 16733 ]
            cniesen Claus Niesen made changes -
            Rice Lead jkneal cniesen
            masargen Matt Sargent made changes -
            Component/s Roadmap [ 13903 ]
            spatterson Shem Patterson (Inactive) made changes -
            Workflow custom [ 100698 ] Copy of custom for rice [ 207086 ]
            spatterson Shem Patterson (Inactive) made changes -
            Workflow Copy of custom for rice [ 207086 ] custom [ 216834 ]
            spatterson Shem Patterson (Inactive) made changes -
            Workflow custom [ 216834 ] Rice Workflow [ 226582 ]
            jcoltrin Jessica Coltrin (Inactive) made changes -
            Fix Version/s 2.4 [ 16913 ]
            Fix Version/s 2.4-backlog [ 16596 ]
            Hide
            cniesen Claus Niesen added a comment -

            Can be done by adding the following code:

            <property name="lineActions">
              <list>
                <bean parent="Uif-DeleteLineAction" p:render="@{isAddedCollectionItem(#line)}"/>
                <bean parent="Uif-SaveLineAction"/>
              </list>
            </property>
            

            Is that good enough or is a convenient method needed to toggle between delete button on all rows, new rows, no rows?

            Show
            cniesen Claus Niesen added a comment - Can be done by adding the following code: <property name= "lineActions" > <list> <bean parent= "Uif-DeleteLineAction" p:render= "@{isAddedCollectionItem(#line)}" /> <bean parent= "Uif-SaveLineAction" /> </list> </property> Is that good enough or is a convenient method needed to toggle between delete button on all rows, new rows, no rows?
            jcoltrin Jessica Coltrin (Inactive) made changes -
            Component/s KNS Equivalency [ 13684 ]
            jcoltrin Jessica Coltrin (Inactive) made changes -
            Fix Version/s 2.5 [ 17044 ]
            Fix Version/s 2.4 [ 16913 ]
            jcoltrin Jessica Coltrin (Inactive) made changes -
            Issue Type Task [ 3 ] Improvement [ 4 ]
            cniesen Claus Niesen made changes -
            Original Estimate 2 days, 2 hours [ 64800 ]
            cniesen Claus Niesen made changes -
            Remaining Estimate 2 days, 2 hours [ 64800 ]
            cniesen Claus Niesen made changes -
            Sprint 2.5 KNS Equiv - m6 [ 252 ]
            cniesen Claus Niesen made changes -
            Rank Ranked lower
            cniesen Claus Niesen made changes -
            Sprint 2.5 KNS Equiv - m6 [ 252 ]
            cniesen Claus Niesen made changes -
            Rank Ranked lower
            cniesen Claus Niesen made changes -
            Sprint 2.5 KNS Equiv - m7 [ 254 ]
            cniesen Claus Niesen made changes -
            Rank Ranked higher
            cniesen Claus Niesen made changes -
            Sprint 2.5 KNS Equiv - m7 [ 254 ] 2.5 KNS Equiv - m5 [ 251 ]
            cniesen Claus Niesen made changes -
            Sprint 2.5 KNS Equiv - m4 [ 251 ] 2.5 KNS Equiv - m5 [ 252 ]
            cniesen Claus Niesen made changes -
            Sprint 2.5 KNS Equiv - m5 [ 252 ]
            kbtaylor Kristina Taylor (Inactive) made changes -
            Assignee Kristina Taylor [ kbtaylor ]
            kbtaylor Kristina Taylor (Inactive) made changes -
            Assignee Kristina Taylor [ kbtaylor ] Claus Niesen [ cniesen ]
            Hide
            kbtaylor Kristina Taylor (Inactive) added a comment -

            Claus Niesen, can you check with KFS to see if your solution is appropriate, as Jerry suggested in our meeting?

            Show
            kbtaylor Kristina Taylor (Inactive) added a comment - Claus Niesen , can you check with KFS to see if your solution is appropriate, as Jerry suggested in our meeting?
            kbtaylor Kristina Taylor (Inactive) made changes -
            Labels Blocked
            kbtaylor Kristina Taylor (Inactive) made changes -
            Rank Ranked higher
            Hide
            jksmith James Smith added a comment -

            Claus & Kristina, can I think about this a bit? I think that in screens or transactional documents, we'd always have new records in collections, so moving the flag up to DocumentEntry shouldn't change anything on that side. It sounds as if current maint doc behavior would stay as it is today. If I'm copying a transactional document, I should be clearing out keys so again, the records in the collection should seem "new". So off hand, I think this is okay, but if I could try to think through some other cases and let you know by EOB mountain time today, I'd be grateful.

            Show
            jksmith James Smith added a comment - Claus & Kristina, can I think about this a bit? I think that in screens or transactional documents, we'd always have new records in collections, so moving the flag up to DocumentEntry shouldn't change anything on that side. It sounds as if current maint doc behavior would stay as it is today. If I'm copying a transactional document, I should be clearing out keys so again, the records in the collection should seem "new". So off hand, I think this is okay, but if I could try to think through some other cases and let you know by EOB mountain time today, I'd be grateful.
            Hide
            jksmith James Smith added a comment -

            Added Kevin and Bryan as watchers.

            Kevin pointed out that we have a situation on our transactional documents and we're curious how the framework would approach it. On accounting docs, like the Distribution of Income and Expense, the initiator adds lines and then routes to the fiscal officer. The fiscal officer can then add and delete lines if they are the owner of the account on the line. So at the first route node, would the accounting lines in the collection still be considered "new" and therefore, deleting would be possible? Can we easily turn off deleting if: a) the account on the line is not associated with the fiscal officer, or b) if there's only one accounting line in the group - basically, one item in the collection? Thanks!

            Show
            jksmith James Smith added a comment - Added Kevin and Bryan as watchers. Kevin pointed out that we have a situation on our transactional documents and we're curious how the framework would approach it. On accounting docs, like the Distribution of Income and Expense, the initiator adds lines and then routes to the fiscal officer. The fiscal officer can then add and delete lines if they are the owner of the account on the line. So at the first route node, would the accounting lines in the collection still be considered "new" and therefore, deleting would be possible? Can we easily turn off deleting if: a) the account on the line is not associated with the fiscal officer, or b) if there's only one accounting line in the group - basically, one item in the collection? Thanks!
            Hide
            jkneal Jerry Neal (Inactive) added a comment -

            Hi James,

            Yes this will be possible (and there a few different ways). KIM permissions can be setup to determine view/edit status of a line. So you can setup a permissions for accounting lines. If the user doesn't have the permission the line will become readonly. So you can change the expression on the delete button to:

            <bean parent="Uif-DeleteLineAction" p:render="@

            {isAddedCollectionItem(#line) || !readOnlyLine}

            "/>

            There are various other ways as well. We still support edit modes, and you can create/export any sort of flag or function you need for your expressions.

            Once you guys get around to converting we can add things that you determine would be helpful.

            thanks
            Jerry

            Show
            jkneal Jerry Neal (Inactive) added a comment - Hi James, Yes this will be possible (and there a few different ways). KIM permissions can be setup to determine view/edit status of a line. So you can setup a permissions for accounting lines. If the user doesn't have the permission the line will become readonly. So you can change the expression on the delete button to: <bean parent="Uif-DeleteLineAction" p:render="@ {isAddedCollectionItem(#line) || !readOnlyLine} "/> There are various other ways as well. We still support edit modes, and you can create/export any sort of flag or function you need for your expressions. Once you guys get around to converting we can add things that you determine would be helpful. thanks Jerry
            Hide
            jksmith James Smith added a comment -

            Thanks Jerry. I think one of our biggest targets of analysis will be how best to expose our rich presentation controller logic to the Spring EL, but that's really tangential to this. At this point in time, I don't think the KFS team has any further concerns here. Thanks greatly everyone!

            Show
            jksmith James Smith added a comment - Thanks Jerry. I think one of our biggest targets of analysis will be how best to expose our rich presentation controller logic to the Spring EL, but that's really tangential to this. At this point in time, I don't think the KFS team has any further concerns here. Thanks greatly everyone!
            cniesen Claus Niesen made changes -
            Labels Blocked
            Hide
            cniesen Claus Niesen added a comment - - edited

            ToDo: Check to see if we can document the code snipped somewhere (KRAD User Guide, KRAD Library, ...)

            Show
            cniesen Claus Niesen added a comment - - edited ToDo: Check to see if we can document the code snipped somewhere (KRAD User Guide, KRAD Library, ...) Libary example with AFT KRAD Guide -> Collection Groups -> Like Actions KNS to KRAD Conversion Guide Done
            cniesen Claus Niesen made changes -
            Assignee Claus Niesen [ cniesen ]
            kbtaylor Kristina Taylor (Inactive) made changes -
            Rank Ranked higher
            kbtaylor Kristina Taylor (Inactive) made changes -
            Rank Ranked higher
            kbtaylor Kristina Taylor (Inactive) made changes -
            Rank Ranked higher
            kbtaylor Kristina Taylor (Inactive) made changes -
            Rank Ranked higher
            kbtaylor Kristina Taylor (Inactive) made changes -
            Rank Ranked lower
            cniesen Claus Niesen made changes -
            Description Collections should allow the delete button for an existing collection record by default if the line is new or
            always allow line deletion is set to true. Currently this flag is set on the MaintenanceDocumentEntry. We should move
            it up to the DocumentEntry and also have the flag that can be set on the CollectionGroup. If not set on the CollectionGroup
            and their is an associated document entry it will default to that. If not set should be false. when set to true if overrides
            the check for new line.
            Collections should allow the delete button for an existing collection record by default if the line is new or
            always allow line deletion is set to true. Currently this flag is set on the MaintenanceDocumentEntry. We should move
            it up to the DocumentEntry and also have the flag that can be set on the CollectionGroup. If not set on the CollectionGroup
            and their is an associated document entry it will default to that. If not set should be false. when set to true if overrides
            the check for new line.

            As a developer I want to configure when a collection line can be deleted with the available options of "never", only newly added items or all items.
            cniesen Claus Niesen made changes -
            Original Estimate 2 days, 2 hours [ 64800 ] 30 minutes [ 1800 ]
            Remaining Estimate 2 days, 2 hours [ 64800 ] 30 minutes [ 1800 ]
            cniesen Claus Niesen made changes -
            Description Collections should allow the delete button for an existing collection record by default if the line is new or
            always allow line deletion is set to true. Currently this flag is set on the MaintenanceDocumentEntry. We should move
            it up to the DocumentEntry and also have the flag that can be set on the CollectionGroup. If not set on the CollectionGroup
            and their is an associated document entry it will default to that. If not set should be false. when set to true if overrides
            the check for new line.

            As a developer I want to configure when a collection line can be deleted with the available options of "never", only newly added items or all items.
             *See TO DO in comments*

            Collections should allow the delete button for an existing collection record by default if the line is new or
            always allow line deletion is set to true. Currently this flag is set on the MaintenanceDocumentEntry. We should move
            it up to the DocumentEntry and also have the flag that can be set on the CollectionGroup. If not set on the CollectionGroup
            and their is an associated document entry it will default to that. If not set should be false. when set to true if overrides
            the check for new line.

            As a developer I want to configure when a collection line can be deleted with the available options of "never", only newly added items or all items.
            kbtaylor Kristina Taylor (Inactive) made changes -
            Original Estimate 30 minutes [ 1800 ]
            Remaining Estimate 30 minutes [ 1800 ]
            kbtaylor Kristina Taylor (Inactive) made changes -
            Rank Ranked higher
            kbtaylor Kristina Taylor (Inactive) made changes -
            Story Points 1
            kbtaylor Kristina Taylor (Inactive) made changes -
            Story Points 1 3
            shahess Shannon Hess made changes -
            Assignee Shannon Hess [ shahess ]
            shahess Shannon Hess made changes -
            Sprint Core 2.5.0-m6 Sprint 1 [ 359 ]
            shahess Shannon Hess made changes -
            Rank Ranked lower
            shahess Shannon Hess made changes -
            Status Open [ 1 ] In Progress [ 3 ]
            kbtaylor Kristina Taylor (Inactive) made changes -
            Sprint Core 2.5.0-m6 Sprint 1 [ 359 ] Core 2.5.0-m6 Sprint 1, Core 2.5.0-m6 Sprint 2 [ 359, 371 ]
            kbtaylor Kristina Taylor (Inactive) made changes -
            Rank Ranked higher
            Show
            shahess Shannon Hess added a comment - All TODOs are now done. Library Example: local - http://localhost:8080/krad-dev/kr-krad/kradsampleapp?viewId=Demo-CollectionDeleteLineView env14 - http://env14.rice.kuali.org/kr-krad/kradsampleapp?viewId=Demo-CollectionDeleteLineView AFT - DemoCollectionFeaturesDeleteLineAft Link to tests in CI – https://ci.kuali.org/view/rice/view/2.5/view/list/job/rice-2.5-test-functional-env14-jenkins-krad-sampleapp/lastCompletedBuild/testReport/org.kuali.rice.krad.demo.uif.library.collections/DemoCollectionFeaturesDeleteLineAft/ The KRAD Guide has also been updated - http://site.kuali.org/rice/latest/reference/html/KRAD_Guide.html#d2543e9245
            shahess Shannon Hess logged work - 13/Aug/14 2:51 PM
            • Time Spent:
              5 hours
               
              Created library page, AFT, and update KRAD guide
            shahess Shannon Hess made changes -
            Remaining Estimate 0 minutes [ 0 ]
            Time Spent 5 hours [ 18000 ]
            Worklog Id 98396 [ 98396 ]
            shahess Shannon Hess made changes -
            Status In Progress [ 3 ] Resolved [ 5 ]
            Resolution Fixed [ 1 ]
            masargen Matt Sargent made changes -
            Status Resolved [ 5 ] Closed [ 6 ]

              People

              • Assignee:
                shahess Shannon Hess
                Reporter:
                jkneal Jerry Neal (Inactive)
              • Votes:
                0 Vote for this issue
                Watchers:
                7 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:

                  Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0 minutes
                  0m
                  Logged:
                  Time Spent - 5 hours
                  5h