Kuali Rice Development
  1. Kuali Rice Development
  2. KULRICE-5286

Uif Framework - support for references to refresh

    Details

    • Type: Task Task
    • Status: Closed Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 2.0.0-m6, 2.0
    • Fix Version/s: 2.5
    • Security Level: Public (Public: Anyone can view)
    • Labels:
      None
    • Similar issues:
      KULRICE-10841Analysis for Uif Framework - support for references to refresh
      KULRICE-5393Uif Framework - Better support for ajax posts and component refresh
      KULRICE-5331UIF Framework - Add support for disabled on input controls
      KULRICE-5368Uif Framework - Add support for enter key
      KULRICE-12558Support for ajax refresh of the view
      KULRICE-7590Support for progressive disclosure and component refresh on content elements
      KULRICE-6754Document the UI Framework - Keyboard Support
      KULRICE-5370Uif Framework - Collections: Support for Total Lines and Grouping
      KULRICE-6841UIF Framework - Introduce the concept of data element attributes
      KULRICE-7583Add support to KRAD attribute field framework for RemotableSelectField.refreshOnChange
    • Rice Module:
      KRAD
    • KRAD Feature Area:
      Lookup
    • Sprint:
      Core 2.5.0-m6 Sprint 1
    • KAI Review Status:
      Not Required
    • KTI Review Status:
      Not Required
    • Include in Release Notes?:
      Yes
    • Story Points:
      5

      Description

      Need support for references to refresh coming from a lookup return. From the UifControllerBase#refresh method we can call the
      view helper service passing the references to refresh which will then do the refresh. This will cover the support needed on maintenance as well.

      In addition, verify we are allowing the references to refresh configuration on the quickfinder widget, and it is getting correctly sent to the lookup and returned.

        Issue Links

          Activity

          Hide
          Eric Westfall added a comment -

          Bulk update of incomplete 2.0.0-b2 issues to just a 2.0 fix version.

          Show
          Eric Westfall added a comment - Bulk update of incomplete 2.0.0-b2 issues to just a 2.0 fix version.
          Hide
          Kristina Taylor (Inactive) added a comment -

          There is code included here but it doesn't seem to be there for JPA. Shelving pending response from Jonathan.

          Show
          Kristina Taylor (Inactive) added a comment - There is code included here but it doesn't seem to be there for JPA. Shelving pending response from Jonathan.
          Hide
          Jerry Neal (Inactive) added a comment -

          I contacted JPA team and linked the related issue they are working on.

          Show
          Jerry Neal (Inactive) added a comment - I contacted JPA team and linked the related issue they are working on.
          Hide
          Kristina Taylor (Inactive) added a comment -

          This still appears to be not converted for JPA. It may be an easy fix though; can we have someone from that team look at it?

          Show
          Kristina Taylor (Inactive) added a comment - This still appears to be not converted for JPA. It may be an easy fix though; can we have someone from that team look at it?
          Hide
          Eric Westfall added a comment -

          There should be a capability for refreshing now on the DataObjectWrapper

          Show
          Eric Westfall added a comment - There should be a capability for refreshing now on the DataObjectWrapper
          Hide
          Kristina Taylor (Inactive) added a comment -

          Even if the capability is there, it's not being used in the right place so we need someone from the JPA team to take a look at this piece of code.

          Show
          Kristina Taylor (Inactive) added a comment - Even if the capability is there, it's not being used in the right place so we need someone from the JPA team to take a look at this piece of code.
          Hide
          Kristina Taylor (Inactive) added a comment -

          I can't seem to get the example I created (Labs -> Kitchen Sink -> Lookups -> Bottom of the page) to work with the current objects, so it will have to probably be changed to different objects. The point for that one is that once you look up something in a lookup, anything in the references to refresh list should be linked in ViewHelperServiceImpl.refreshReference. So once the lookup returns, the linked object should be filled and any fields from that linked object should now display.

          Show
          Kristina Taylor (Inactive) added a comment - I can't seem to get the example I created (Labs -> Kitchen Sink -> Lookups -> Bottom of the page) to work with the current objects, so it will have to probably be changed to different objects. The point for that one is that once you look up something in a lookup, anything in the references to refresh list should be linked in ViewHelperServiceImpl.refreshReference . So once the lookup returns, the linked object should be filled and any fields from that linked object should now display.
          Hide
          Kristina Taylor (Inactive) added a comment -

          I did a more in-depth review of this one. I updated the example to work when this work is complete. Currently, there is a block of code in ViewHelperServiceImpl.refereshReference which prevents any JPA code from erroring out when using the LegacyDataAdapter:

          if (!(parentObject instanceof PersistableBusinessObjectBaseAdapter)) {
              LOG.warn("Could not refresh reference " + referenceObjectName + " off class " + parentObject.getClass().getName() + ". Class not of type PersistableBusinessObject");
              return;
          }
          

          With JPA, the following should be added:

          KRADServiceLocator.getDataObjectService().wrap(parentObject).fetchRelationship(referenceObjectName);
          

          but both methods should be allowed, so the solution here is to detect whether or not we are in legacy mode or not and apply the correct refresh method.

          Show
          Kristina Taylor (Inactive) added a comment - I did a more in-depth review of this one. I updated the example to work when this work is complete. Currently, there is a block of code in ViewHelperServiceImpl.refereshReference which prevents any JPA code from erroring out when using the LegacyDataAdapter : if (!(parentObject instanceof PersistableBusinessObjectBaseAdapter)) { LOG.warn( "Could not refresh reference " + referenceObjectName + " off class " + parentObject.getClass().getName() + ". Class not of type PersistableBusinessObject" ); return ; } With JPA, the following should be added: KRADServiceLocator.getDataObjectService().wrap(parentObject).fetchRelationship(referenceObjectName); but both methods should be allowed, so the solution here is to detect whether or not we are in legacy mode or not and apply the correct refresh method.
          Hide
          Jeff Ruch added a comment -

          Updated refreshReference per Kristina's comment. Tested the example in kitchen sink along with the demo look-ups.

          Show
          Jeff Ruch added a comment - Updated refreshReference per Kristina's comment. Tested the example in kitchen sink along with the demo look-ups.

            People

            • Assignee:
              Jeff Ruch
              Reporter:
              Jerry Neal (Inactive)
            • Votes:
              0 Vote for this issue
              Watchers:
              4 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 - 4 hours
                4h

                  Agile

                    Structure Helper Panel