Details

    • Type: Bug Fix Bug Fix
    • Status: Closed Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 2.0.0-m7
    • Fix Version/s: 2.0.0-m8, 2.0
    • Component/s: Data Dictionary
    • Security Level: Public (Public: Anyone can view)
    • Labels:
      None
    • Similar issues:
      KULRICE-5400Case/When statement does not execute RequiredConstraint (SimpleConstraint) DictionaryValidatoinServiceImpl
      KULRICE-3045User lookup workaround for case when name field is not rendered
      KULRICE-176Implement the copy feature for Maintenance documents
      KULRICE-5398Implement proper thread-safe lazy initialization for WorkflowDocumentFactory
      KULRICE-1744Implement proper Super User support in EDocLite
      KULRICE-2708document operation screen auth not implemented properly
      KULRICE-2966view attachment permission not implemented or at least not properly
      KULRICE-5349LookupForm does not serialize properly
      KULRICE-9505Implement proper support for serialization of maintenance document data in the krad-data framework
      KULRICE-5753Make sure that max results and start index are implemented properly from the DocumentLookupCriteria.
    • Rice Module:
      KRAD
    • Application Requirement:
      Rice
    • KAI Review Status:
      Not Required
    • KTI Review Status:
      Not Required

      Description

      Still having trouble with case constraint not working in M7
      when you get a chance... can you explain the address example?
      :
      <bean id="Address-street2" parent="Address-street2-parentBean" />
      <bean id="Address-street2-parentBean" abstract="true"
      parent="AttributeDefinition">
      <property name="name" value="street2" />
      <property name="shortLabel" value="street2" />
      <property name="summary" value="Street Address Line 2" />
      <property name="label" value="Street 2" />
      <property name="description" value="Street Address Line 2" />
      <property name="minLength" value="1" />
      <property name="maxLength" value="40" />
      <property name="validationPattern">
      <bean parent="AnyCharacterValidationPattern" />
      </property>
      <property name="control">
      <bean parent="TextControlDefinition" p:size="40" />
      </property>
      <property name="caseConstraint">
      <bean parent="CaseConstraint">
      <property name="caseSensitive" value="false"/>
      <property name="fieldPath" value="country"/>
      <property name="whenConstraint">
      <list>
      <bean parent="WhenConstraint">
      <property name="value" value="CN"/>
      <property name="valuePath" value="street1"/>
      <property name="constraint">
      <bean parent="SimpleConstraint">
      <property name="required" value="true"/>
      </bean>
      </property>
      </bean>
      </list>
      </property>
      </bean>
      </property>
      </bean>

      Confusing things:
      (1) Case is on the Street2 field but it is for street1?

      (2) valuePath points to street1 ... I thought that was supposed to be how you could point to another field's value for comparison instead of a hard coded value not the field to which the simple constraint gets applied to?!?!?

      The simple constraint should be applied to the field you have the case constraint on (i.e. see confusing thing #1)
      This is what I'm trying to do...
      #1. define a generic case constraint bean
      <bean id="AtpInfo.required.when.state.is.official" parent="CaseConstraint">
      <property name="operator" value="EQUALS" />
      <property name="fieldPath" value="stateKey" />
      <property name="caseSensitive" value="true" />
      <property name="whenConstraint">
      <list>
      <bean parent="WhenConstraint">
      <property name="values">
      <list>
      <value>kuali.atp.state.Official</value>
      </list>
      </property>
      <property name="constraint">
      <bean parent="RequiredConstraint" />
      </property>
      </bean>
      </list>
      </property>
      </bean>
      [8/17/2011 6:17:04 PM] Norman Wright:

      #2 Apply it to the fields that are required when the state matches
      <bean id="AtpInfo.startDate" parent="AtpInfo.startDate-parent"/>
      <bean id="AtpInfo.startDate-parent" abstract="true" parent="AtpInfo.startDate-generated">
      <!-- insert any overrides to the generated attribute definitions here -->
      <property name="caseConstraint">
      <ref bean="AtpInfo.required.when.state.is.official"/>
      </property>
      </bean>

      Will Gomes: Hi Norm can you file a bug on this, it doesn't appear that CaseConstraint was implemented properly
      Norman Wright: ok
      }

        Issue Links

          Activity

          Hide
          Norm Wright added a comment -

          If you want I can rework that address unit test setup so it works the way (I think) the case/when is supposed to work?

          Show
          Norm Wright added a comment - If you want I can rework that address unit test setup so it works the way (I think) the case/when is supposed to work?
          Hide
          Rice-CI User (Inactive) added a comment -

          Integrated in rice-trunk-nightly #167 (See http://ci.rice.kuali.org/job/rice-trunk-nightly/167/)
          KULRICE-5553 Fix so when constraint field path is evaluated correctly when processing case constraint. Update test to reflect fix.

          Show
          Rice-CI User (Inactive) added a comment - Integrated in rice-trunk-nightly #167 (See http://ci.rice.kuali.org/job/rice-trunk-nightly/167/ ) KULRICE-5553 Fix so when constraint field path is evaluated correctly when processing case constraint. Update test to reflect fix.
          Hide
          Jessica Coltrin (Inactive) added a comment -

          Closing since these items are now in the release notes.

          Show
          Jessica Coltrin (Inactive) added a comment - Closing since these items are now in the release notes.

            People

            • Assignee:
              Will Gomes (Inactive)
              Reporter:
              Norm Wright
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Structure Helper Panel