dhis2-devs team mailing list archive
-
dhis2-devs team
-
Mailing list archive
-
Message #39516
[Branch ~dhis2-devs-core/dhis2/trunk] Rev 20010: fixes for type => valueType conversion in light module
------------------------------------------------------------
revno: 20010
committer: Morten Olav Hansen <mortenoh@xxxxxxxxx>
branch nick: dhis2
timestamp: Mon 2015-09-07 10:03:40 +0700
message:
fixes for type => valueType conversion in light module
modified:
dhis-2/dhis-web/dhis-web-light/src/main/webapp/dhis-web-light/dataEntrySection.vm
--
lp:dhis2
https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk
Your team DHIS 2 developers is subscribed to branch lp:dhis2.
To unsubscribe from this branch go to https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk/+edit-subscription
=== modified file 'dhis-2/dhis-web/dhis-web-light/src/main/webapp/dhis-web-light/dataEntrySection.vm'
--- dhis-2/dhis-web/dhis-web-light/src/main/webapp/dhis-web-light/dataEntrySection.vm 2014-01-23 14:09:55 +0000
+++ dhis-2/dhis-web/dhis-web-light/src/main/webapp/dhis-web-light/dataEntrySection.vm 2015-09-07 03:03:40 +0000
@@ -66,27 +66,27 @@
<br /><span style="color: #990000;">$typeViolation</span>
#end
- #if( $dataElement.type == "string" )
+ #if( $dataElement.valueType == "TEXT" )
<input type="text" maxlength="255" size="24" name="$key" value="$!dataValues.get($key)" />
- #elseif( $dataElement.type == "bool" )
+ #elseif( $dataElement.valueType == "bool" )
<select name="$key" style="width: 100%;">
<option value="">[ No Value ]</option>
<option value="true" #if($!dataValues.get($key) == "true")selected="selected"#end>Yes</option>
<option value="false" #if($!dataValues.get($key) == "false")selected="selected"#end>No</option>
</select>
- #elseif( $dataElement.type == "date" )
+ #elseif( $dataElement.valueType == "DATE" )
<input type="date" maxlength="255" size="24" name="$key" value="$!dataValues.get($key)" />
- #elseif( $dataElement.type == "int" && $dataElement.numberType == "number" )
- <input type="text" maxlength="255" size="24" name="$key" value="$!dataValues.get($key)" />
- #elseif( $dataElement.type == "int" && $dataElement.numberType == "int" )
- <input type="text" maxlength="255" size="24" name="$key" value="$!dataValues.get($key)" />
- #elseif( $dataElement.type == "int" && $dataElement.numberType == "posInt" )
- <input type="text" maxlength="255" size="24" name="$key" value="$!dataValues.get($key)" />
- #elseif( $dataElement.type == "int" && $dataElement.numberType == "negInt" )
- <input type="text" maxlength="255" size="24" name="$key" value="$!dataValues.get($key)" />
- #elseif( $dataElement.type == "int" && $dataElement.numberType == "zeroPositiveInt" )
- <input type="text" maxlength="255" size="24" name="$key" value="$!dataValues.get($key)" />
- #elseif($dataElement.type=="trueOnly")
+ #elseif( $dataElement.valueType == "NUMBER" )
+ <input type="text" maxlength="255" size="24" name="$key" value="$!dataValues.get($key)" />
+ #elseif( $dataElement.valueType == "INTEGER" )
+ <input type="text" maxlength="255" size="24" name="$key" value="$!dataValues.get($key)" />
+ #elseif( $dataElement.valueType == "INTEGER_POSITIVE" )
+ <input type="text" maxlength="255" size="24" name="$key" value="$!dataValues.get($key)" />
+ #elseif( $dataElement.valueType == "INTEGER_NEGATIVE" )
+ <input type="text" maxlength="255" size="24" name="$key" value="$!dataValues.get($key)" />
+ #elseif( $dataElement.valueType == "INTEGER_ZERO_OR_POSITIVE" )
+ <input type="text" maxlength="255" size="24" name="$key" value="$!dataValues.get($key)" />
+ #elseif($dataElement.valueType=="TRUE_ONLY")
<input name="$key" type="checkbox" #if($!dataValues.get($key) == "on" ) checked #end/>
#end
#end