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

Document search does not work properly with KNS Attribute Definitions

    Details

    • Type: Bug Fix
    • Status: Closed
    • Priority: Critical
    • Resolution: Fixed
    • Affects Version/s: 2.0.0-rc2
    • Fix Version/s: 2.0.1
    • Component/s: Development
    • Security Level: Public (Public: Anyone can view)
    • Labels:
      None
    • Rice Module:
      KEW
    • Application Requirement:
      KFS
    • KAI Review Status:
      Not Required
    • KTI Review Status:
      Not Required

      Description

      It looks like the document search configuration by the data dictionary is only supporting KRAD control definitions. In the class and method below, when it is translating the attribute definitions into RemotableAbstractControl objects, it is only checking for org.kuali.rice.krad.uif classes. Since the KNS definitions do not extend these classes, this results in all custom KFS fields rendering as text fields (and they seem to be using the short label instead of the full label.)

      org.kuali.rice.krad.service.impl.DataDictionaryRemoteFieldServiceImpl

          protected RemotableAbstractControl.Builder createControl(AttributeDefinition attr) {
              Control control = attr.getControlField();
      
              if (control != null) {
                  if (control instanceof CheckboxControl) {
                      return RemotableCheckbox.Builder.create();
                  } else if (control instanceof CheckboxGroupControl) {
                      return RemotableCheckboxGroup.Builder.create(getValues(attr));
                  } else if (control instanceof HiddenControl) {
                      return RemotableHiddenInput.Builder.create();
                  } else if (control instanceof SelectControl) {
                      RemotableSelect.Builder b = RemotableSelect.Builder.create(getValues(attr));
                      b.setMultiple(((SelectControl) control).isMultiple());
                      b.setSize(((SelectControl) control).getSize());
                  } else if (control instanceof RadioGroupControl) {
                      return RemotableRadioButtonGroup.Builder.create(getValues(attr));
                  } else if (control instanceof TextControl) {
                      final RemotableTextInput.Builder b = RemotableTextInput.Builder.create();
                      b.setSize(((TextControl) control).getSize());
                      return b;
                  } else if (control instanceof UserControl) {
                      final RemotableTextInput.Builder b = RemotableTextInput.Builder.create();
                      b.setSize(((UserControl) control).getSize());
                      return b;
                  } else if (control instanceof GroupControl) {
                      final RemotableTextInput.Builder b = RemotableTextInput.Builder.create();
                      b.setSize(((GroupControl) control).getSize());
                      return b;
                  } else if (control instanceof TextAreaControl) {
                      final RemotableTextarea.Builder b = RemotableTextarea.Builder.create();
                      b.setCols(((TextAreaControl) control).getCols());
                      b.setRows(((TextAreaControl) control).getRows());
                      return b;
                  }
              }
      
              return null;
          }
      

        Attachments

        1. KFS 4.1.1 Testdrive.png
          KFS 4.1.1 Testdrive.png
          101 kB
        2. KFS 5.0.png
          KFS 5.0.png
          81 kB
        3. Kuali Portal Index.png
          Kuali Portal Index.png
          233 kB
        4. PO Search - After.png
          PO Search - After.png
          170 kB
        5. PO search - before.png
          PO search - before.png
          235 kB

          Issue Links

            Activity

            Hide
            jjhanso Jeremy Hanson added a comment -

            I have committed a fix for this. You'll probably have to make a change to FinancialSystemSearchableAttribute to match DataDictionarySearchableAttribute.

            Show
            jjhanso Jeremy Hanson added a comment - I have committed a fix for this. You'll probably have to make a change to FinancialSystemSearchableAttribute to match DataDictionarySearchableAttribute.
            Hide
            jkeller Jonathan Keller added a comment -

            It's looking better. I've effectively commented out the KFS searchable attribute contents.

            The main thing I notice is that the field widths no longer seem to be set. All text fields are the default HTML length. (In fact - it seems to be setting a "size" attribute in the HTML (to zero) instead of a width attribute.

            Show
            jkeller Jonathan Keller added a comment - It's looking better. I've effectively commented out the KFS searchable attribute contents. The main thing I notice is that the field widths no longer seem to be set. All text fields are the default HTML length. (In fact - it seems to be setting a "size" attribute in the HTML (to zero) instead of a width attribute.
            Hide
            jkeller Jonathan Keller added a comment -

            And - it also looks like the auto-creation of the "from - to" on date fields is missing.

            Show
            jkeller Jonathan Keller added a comment - And - it also looks like the auto-creation of the "from - to" on date fields is missing.
            Hide
            jjhanso Jeremy Hanson added a comment -

            I'll create some new jiras for these issues.

            Show
            jjhanso Jeremy Hanson added a comment - I'll create some new jiras for these issues.
            Hide
            jkeller Jonathan Keller added a comment -

            Thanks! The input is working better now. Now - all I need are some documents to test search result with...

            Show
            jkeller Jonathan Keller added a comment - Thanks! The input is working better now. Now - all I need are some documents to test search result with...

              People

              • Assignee:
                jjhanso Jeremy Hanson
                Reporter:
                jkeller Jonathan Keller
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: