=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/validation/ValidationRule.java' --- dhis-2/dhis-api/src/main/java/org/hisp/dhis/validation/ValidationRule.java 2012-10-10 12:49:27 +0000 +++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/validation/ValidationRule.java 2012-12-04 17:33:33 +0000 @@ -131,6 +131,10 @@ return "[" + name + "]"; } + // ------------------------------------------------------------------------- + // Logic + // ------------------------------------------------------------------------- + public void clearExpressions() { this.leftSide = null; @@ -148,6 +152,11 @@ groups.remove( validationRuleGroup ); validationRuleGroup.getMembers().remove( this ); } + + public String getDescriptionNameFallback() + { + return description != null && !description.trim().isEmpty() ? description : name; + } // ------------------------------------------------------------------------- // Set and get methods === modified file 'dhis-2/dhis-web/dhis-web-dataentry/src/main/resources/org/hisp/dhis/de/i18n_module.properties' --- dhis-2/dhis-web/dhis-web-dataentry/src/main/resources/org/hisp/dhis/de/i18n_module.properties 2012-11-15 13:29:27 +0000 +++ dhis-2/dhis-web/dhis-web-dataentry/src/main/resources/org/hisp/dhis/de/i18n_module.properties 2012-12-04 17:33:33 +0000 @@ -104,4 +104,6 @@ insert_input_fields_into_the_form=Insert input fields into the form select_data_element=Select data element all_values_for_data_element_must_be_filled=This form requires that all fields for a data element must be filled, please correct this before continuing. -childrens_forms=Childrens forms \ No newline at end of file +childrens_forms=Childrens forms +left_side=Left side +right_side=Right side \ No newline at end of file === modified file 'dhis-2/dhis-web/dhis-web-dataentry/src/main/webapp/dhis-web-dataentry/javascript/form.js' --- dhis-2/dhis-web/dhis-web-dataentry/src/main/webapp/dhis-web-dataentry/javascript/form.js 2012-11-15 16:52:10 +0000 +++ dhis-2/dhis-web/dhis-web-dataentry/src/main/webapp/dhis-web-dataentry/javascript/form.js 2012-12-04 17:33:33 +0000 @@ -1387,7 +1387,7 @@ $( '#validationDiv' ).dialog( { modal: true, title: 'Validation', - width: 870, + width: 920, height: height } ); } === modified file 'dhis-2/dhis-web/dhis-web-dataentry/src/main/webapp/dhis-web-dataentry/validationResult.vm' --- dhis-2/dhis-web/dhis-web-dataentry/src/main/webapp/dhis-web-dataentry/validationResult.vm 2012-10-10 15:51:52 +0000 +++ dhis-2/dhis-web/dhis-web-dataentry/src/main/webapp/dhis-web-dataentry/validationResult.vm 2012-12-04 17:33:33 +0000 @@ -5,13 +5,11 @@ #if( $results.size() > 0) - + - - - - - + + + #set( $mark = false ) #foreach( $result in $results ) @@ -19,13 +17,11 @@ #set ( $leftFormula = $leftsideFormulaMap.get( $id ) ) #set ( $rightFormula = $rightsideFormulaMap.get( $id ) ) - + $!encoder.htmlEncode( $leftFormula ) $encoder.htmlEncode( $i18n.getString( $result.validationRule.operator.mathematicalOperator ) ) $!encoder.htmlEncode( $rightFormula ) - $!encoder.htmlEncode( $result.validationRule.leftSide.description ) $result.leftsideValue $encoder.htmlEncode( $i18n.getString( $result.validationRule.operator.mathematicalOperator ) ) $result.rightsideValue - $!encoder.htmlEncode( $result.validationRule.rightSide.description ) #if( $mark ) #set( $mark = false ) === modified file 'dhis-2/dhis-web/dhis-web-validationrule/src/main/resources/org/hisp/dhis/validationrule/i18n_module.properties' --- dhis-2/dhis-web/dhis-web-validationrule/src/main/resources/org/hisp/dhis/validationrule/i18n_module.properties 2012-09-22 21:59:39 +0000 +++ dhis-2/dhis-web/dhis-web-validationrule/src/main/resources/org/hisp/dhis/validationrule/i18n_module.properties 2012-12-04 17:33:33 +0000 @@ -125,4 +125,5 @@ analysing_please_wait=Analysing data, please wait skip_for_missing_values=Skip for missing values select_parameters=Select parameters -compulsory_pair=Compulsory pair \ No newline at end of file +compulsory_pair=Compulsory pair +visible_in_validation_violations=visible in validation violations \ No newline at end of file === modified file 'dhis-2/dhis-web/dhis-web-validationrule/src/main/webapp/dhis-web-validationrule/addValidationRuleForm.vm' --- dhis-2/dhis-web/dhis-web-validationrule/src/main/webapp/dhis-web-validationrule/addValidationRuleForm.vm 2012-10-17 18:53:29 +0000 +++ dhis-2/dhis-web/dhis-web-validationrule/src/main/webapp/dhis-web-validationrule/addValidationRuleForm.vm 2012-12-04 17:33:33 +0000 @@ -6,11 +6,11 @@ - + - + === modified file 'dhis-2/dhis-web/dhis-web-validationrule/src/main/webapp/dhis-web-validationrule/updateValidationRuleForm.vm' --- dhis-2/dhis-web/dhis-web-validationrule/src/main/webapp/dhis-web-validationrule/updateValidationRuleForm.vm 2012-10-17 18:53:29 +0000 +++ dhis-2/dhis-web/dhis-web-validationrule/src/main/webapp/dhis-web-validationrule/updateValidationRuleForm.vm 2012-12-04 17:33:33 +0000 @@ -16,11 +16,11 @@ - + - +
$i18n.getString( "validation_rule" )$i18n.getString( "validation_rule" ) $i18n.getString( "expression" )$i18n.getString( "description" )$i18n.getString( "value" )$i18n.getString( "operator" )$i18n.getString( "value" )$i18n.getString( "description" )$i18n.getString( "left_side" )$i18n.getString( "operator" )$i18n.getString( "right_side" )
$encoder.htmlEncode( $result.validationRule.name )$encoder.htmlEncode( $result.validationRule.getDescriptionNameFallback() )
$i18n.getString( "details" )
$i18n.getString( "details" )