dhis2-devs team mailing list archive
-
dhis2-devs team
-
Mailing list archive
-
Message #13010
[Branch ~dhis2-devs-core/dhis2/trunk] Rev 4091: ajax-loader plugin in data elimination
------------------------------------------------------------
revno: 4091
committer: Morten Olav Hansen <mortenoh@xxxxxxxxx>
branch nick: dhis2
timestamp: Thu 2011-07-07 13:02:27 +0300
message:
ajax-loader plugin in data elimination
modified:
dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/webapp/dhis-web-maintenance-dataadmin/duplicateDataEliminationForm.vm
dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/webapp/dhis-web-maintenance-dataadmin/javascript/duplicateDataElimination.js
--
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-maintenance/dhis-web-maintenance-dataadmin/src/main/webapp/dhis-web-maintenance-dataadmin/duplicateDataEliminationForm.vm'
--- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/webapp/dhis-web-maintenance-dataadmin/duplicateDataEliminationForm.vm 2011-03-28 15:28:36 +0000
+++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/webapp/dhis-web-maintenance-dataadmin/duplicateDataEliminationForm.vm 2011-07-07 10:02:27 +0000
@@ -10,10 +10,8 @@
<h3>$i18n.getString( "duplicate_data_elimination" ) #openHelp( "duplicateDataElimination" )</h3>
-<div>
- <label>$i18n.getString( "filter" ):</label><br/>
- <input type="text" style="width:294px" onkeyup="filterList( this.value, 'operandList' )"/><br/>
- <select id="operandList" size="6" style="width:400px" onclick="operandSelected()"></select>
+<div style="width: 450px;">
+ <select id="operandList" name="operandList" multiple="multiple" style="height: 150px; width: 100%;"></select>
</div>
<br/>
=== modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/webapp/dhis-web-maintenance-dataadmin/javascript/duplicateDataElimination.js'
--- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/webapp/dhis-web-maintenance-dataadmin/javascript/duplicateDataElimination.js 2010-06-30 08:17:25 +0000
+++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/webapp/dhis-web-maintenance-dataadmin/javascript/duplicateDataElimination.js 2011-07-07 10:02:27 +0000
@@ -3,21 +3,20 @@
var operandToKeep = 0;
function initLists()
-{
- $.getJSON(
- "../dhis-web-commons-ajax-json/getOperands.action",
- {},
- function( json )
- {
- var operands = json.operands;
-
- for ( var i = 0; i < operands.length; i++ )
- {
- $( "#operandList" ).append( "<option value='" +
- operands[i].operandId + "'>" + operands[i].operandName + "</option>" );
- }
+{
+ $("#operandList").dhisAjaxSelect({
+ source: "../dhis-web-commons-ajax-json/getOperands.action",
+ iterator: "operands",
+ handler: function(item) {
+ var option = jQuery("<option />");
+ option.text( item.operandName );
+ option.attr( "value", item.operandId );
+
+ return option;
}
- );
+ });
+
+ $("#operandList").bind('click', operandSelected);
}
function operandSelected()