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

Add input validation to UserControl and GroupControl

    Details

    • Type: Bug Fix Bug Fix
    • Status: Open Open
    • Priority: Major Major
    • Resolution: Unresolved
    • Affects Version/s: 2.2.3
    • Fix Version/s: Backlog
    • Component/s: Development
    • Security Level: Public (Public: Anyone can view)
    • Labels:
    • Similar issues:
      KULRICE-10470isEnableAutoQuickfinder not working with UserControl and GroupControl
      KULRICE-12765FilterableLookupCriteriaControl support is broken and causing issues with KIM UserControl and GroupControl
      KULRICE-9395KRAD UserControl not sending valid parameters for Lookup
      KULRICE-12901Input field validation tooltips displays behind bubblepopup
      KULRICE-6732UserControl (Uif-Kim-PersonControl) causes JavaScript Error
      KULRICE-10933Input field validation tooltips displays twice in lightbox
      KULRICE-4848add input stream constructor to ZipXmlDocCollection
      KULRICE-12916Add back option for left label with input fields
      KULRICE-11679Rework input field add ons
      KULRICE-1863Add 'hidden' input type to enumeration in EDocLite.xsd
    • Rice Module:
      KRAD
    • KRAD Feature Area:
      UIF Component
    • Application Requirement:
      Rice
    • KAI Review Status:
      Not Required
    • KTI Review Status:
      Not Required
    • Include in Release Notes?:
      Yes

      Description

      When the user enters the principalName in to a Uif-KimPersonControl the input isn't validated and the personName field (name of person below the control) is not updated. We should add a validation and display an error if the principalName could not be resolved to a principalId (i.e. doesn't exist). We also should populate the personName field if the validation is successful.

      • Open the "Lookup with User Control" view under the "Demo" menu
      • Type "admin" into the "My Principal Name" field and tab out.
        • Notice the "admin, admin" under the input field
      • Click search button
      • Type "user1" into the "My Principal Name" field and press enter key (while never removing focus from the field)
        • Notice the "admin, admin" under the input field is still displayed while the result for "user1" is shown.
        • Expected to see "One, User"

      Same with the Uif-KimGroupControl except that use input is more difficult as there is the group name and the namespace code. How do we want to handle the user input properly? Right now the namespace code can't be entered by the user and therefore defaults to whatever it was previously.

        Issue Links

          Activity

          Hide
          Jonathan Keller added a comment -

          GroupControl: You may want to revisit whether that control is needed. With the KIM change to groups to also be identified by namespace, that control is not as useful. In the one place I know that KFS has a group control, it does not use any rice-provided control, but renders separate namespace and name fields for the document.

          Show
          Jonathan Keller added a comment - GroupControl: You may want to revisit whether that control is needed. With the KIM change to groups to also be identified by namespace, that control is not as useful. In the one place I know that KFS has a group control, it does not use any rice-provided control, but renders separate namespace and name fields for the document.
          Hide
          Jerry Neal (Inactive) added a comment -

          Claus,

          The field query that executes for the principal name should return a not found message if the query did not return any rows. Check out the AttributeQuery object. This is essentially doing validation since it tries to retrieve the person. Is that not working?

          For the group control, I agree with Jonathan we should either consider dropping it, or changing it to use the group id as the field, and display namespace-name under the control.

          Jerry

          Show
          Jerry Neal (Inactive) added a comment - Claus, The field query that executes for the principal name should return a not found message if the query did not return any rows. Check out the AttributeQuery object. This is essentially doing validation since it tries to retrieve the person. Is that not working? For the group control, I agree with Jonathan we should either consider dropping it, or changing it to use the group id as the field, and display namespace-name under the control. Jerry
          Hide
          Claus Niesen added a comment -

          Yes, the user control does display "<label> not found" message to the left. It doesn't highlight the field, display the usual error message, or block the search action like it's done on other fields when doing submit.

          The user control on the People Flow maintenance document allows you to add a member if you type an invalid member but if you type in a non-numeric stop it blocks the add. I think we'd want the user control to function more like the invalid stop case.

          Also when manually entering the principalName in the user control and pressing enter (default form action without triggering blur), the personName needs to be updated which isn't happening.

          BTW, the group control is used on People Flow.

          Show
          Claus Niesen added a comment - Yes, the user control does display "<label> not found" message to the left. It doesn't highlight the field, display the usual error message, or block the search action like it's done on other fields when doing submit. The user control on the People Flow maintenance document allows you to add a member if you type an invalid member but if you type in a non-numeric stop it blocks the add. I think we'd want the user control to function more like the invalid stop case. Also when manually entering the principalName in the user control and pressing enter (default form action without triggering blur), the personName needs to be updated which isn't happening. BTW, the group control is used on People Flow.
          Hide
          Jerry Neal (Inactive) added a comment -

          Claus, the other errors that are happening on size/shape, not actual 'valid' value checks. Personally I think the message is fine, but if you want to try and find someway to highlight the field I think that would be fine as well.

          Show
          Jerry Neal (Inactive) added a comment - Claus, the other errors that are happening on size/shape, not actual 'valid' value checks. Personally I think the message is fine, but if you want to try and find someway to highlight the field I think that would be fine as well.

            People

            • Assignee:
              Unassigned
              Reporter:
              Claus Niesen
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:

                Structure Helper Panel