dhis2-devs team mailing list archive
-
dhis2-devs team
-
Mailing list archive
-
Message #02179
[Branch ~dhis2-devs-core/dhis2/trunk] Rev 748: some more updates in data locking
------------------------------------------------------------
revno: 748
committer: brajesh2murari@xxxxxxxxx
branch nick: trunk
timestamp: Sun 2009-09-20 22:57:54 +0530
message:
some more updates in data locking
added:
dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/commons/action/GetPeriodsForLockAction.java
dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/webapp/dhis-web-maintenance-dataadmin/noResponseInFrame.vm
modified:
dhis-2/dhis-web/dhis-web-commons/src/main/resources/META-INF/dhis/beans.xml
dhis-2/dhis-web/dhis-web-commons/src/main/resources/dhis-web-commons.xml
dhis-2/dhis-web/dhis-web-commons/src/main/resources/i18n_global.properties
dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/java/org/hisp/dhis/dataadmin/action/lock/GetDataSetsForLockAction.java
dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/resources/META-INF/dhis/beans.xml
dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/resources/org/hisp/dhis/dataadmin/i18n_module.properties
dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/resources/struts.xml
dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/webapp/dhis-web-maintenance-dataadmin/javascript/associations.js
dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/webapp/dhis-web-maintenance-dataadmin/javascript/locking.js
dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/webapp/dhis-web-maintenance-dataadmin/javascript/oust.js
dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/webapp/dhis-web-maintenance-dataadmin/lockingForm.vm
dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/webapp/dhis-web-maintenance-dataadmin/selectionedTreeInFrame.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.
=== added file 'dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/commons/action/GetPeriodsForLockAction.java'
--- dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/commons/action/GetPeriodsForLockAction.java 1970-01-01 00:00:00 +0000
+++ dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/commons/action/GetPeriodsForLockAction.java 2009-09-20 17:27:54 +0000
@@ -0,0 +1,105 @@
+/**
+ *
+ */
+package org.hisp.dhis.commons.action;
+
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.Collections;
+import java.util.Date;
+import java.util.List;
+
+import org.hisp.dhis.i18n.I18nFormat;
+import org.hisp.dhis.period.Period;
+import org.hisp.dhis.period.PeriodService;
+import org.hisp.dhis.period.PeriodType;
+import org.hisp.dhis.period.comparator.PeriodComparator;
+
+import com.opensymphony.xwork2.Action;
+
+/**
+ * @author scott
+ *
+ */
+public class GetPeriodsForLockAction implements Action
+{
+ private final static String ALL = "ALL";
+
+ // -------------------------------------------------------------------------
+ // Dependencies
+ // -------------------------------------------------------------------------
+
+ private PeriodService periodService;
+
+ public void setPeriodService( PeriodService periodService )
+ {
+ this.periodService = periodService;
+ }
+
+ private I18nFormat format;
+
+ public void setFormat( I18nFormat format )
+ {
+ this.format = format;
+ }
+
+ // -------------------------------------------------------------------------
+ // Input & output
+ // -------------------------------------------------------------------------
+
+ private String name;
+
+ public void setName( String name )
+ {
+ this.name = name;
+ }
+
+ private List<Period> periods = new ArrayList<Period>();
+
+ public List<Period> getPeriods()
+ {
+ return periods;
+ }
+
+ // -------------------------------------------------------------------------
+ // Action implementation
+ // -------------------------------------------------------------------------
+
+ public String execute()
+ throws Exception
+ {
+ if ( name == null || name.equals( ALL ) )
+ {
+ Collection<PeriodType> periodTypes = periodService.getAllPeriodTypes();
+
+ for ( PeriodType type : periodTypes )
+ {
+ periods.addAll( periodService.getPeriodsByPeriodType( type ) );
+ }
+ }
+ else
+ {
+ PeriodType periodType = periodService.getPeriodTypeByName( name );
+
+ ArrayList<Period> allPeriodsOfSelectedPeriodType = new ArrayList<Period>( periodService.getPeriodsByPeriodType( periodType ) );
+
+ for ( Period p : allPeriodsOfSelectedPeriodType )
+ {
+ if(!(p.getStartDate().compareTo( new Date() ) > 0 ))
+ {
+ periods.add(p);
+ }
+ }
+ }
+
+ for ( Period period : periods )
+ {
+ period.setName( format.formatPeriod( period ) );
+ }
+
+ Collections.sort( periods, new PeriodComparator() );
+
+ return SUCCESS;
+ }
+}
+
=== modified file 'dhis-2/dhis-web/dhis-web-commons/src/main/resources/META-INF/dhis/beans.xml'
--- dhis-2/dhis-web/dhis-web-commons/src/main/resources/META-INF/dhis/beans.xml 2009-09-10 13:17:59 +0000
+++ dhis-2/dhis-web/dhis-web-commons/src/main/resources/META-INF/dhis/beans.xml 2009-09-20 17:27:54 +0000
@@ -637,6 +637,13 @@
<property name="periodService"
ref="org.hisp.dhis.period.PeriodService"/>
</bean>
+
+ <bean id="org.hisp.dhis.commons.action.GetPeriodsForLockAction"
+ class="org.hisp.dhis.commons.action.GetPeriodsForLockAction"
+ scope="prototype">
+ <property name="periodService"
+ ref="org.hisp.dhis.period.PeriodService"/>
+ </bean>
<bean id="org.hisp.dhis.commons.action.NoAction"
class="org.hisp.dhis.commons.action.NoAction"/>
=== modified file 'dhis-2/dhis-web/dhis-web-commons/src/main/resources/dhis-web-commons.xml'
--- dhis-2/dhis-web/dhis-web-commons/src/main/resources/dhis-web-commons.xml 2009-09-14 16:00:37 +0000
+++ dhis-2/dhis-web/dhis-web-commons/src/main/resources/dhis-web-commons.xml 2009-09-20 17:27:54 +0000
@@ -298,6 +298,11 @@
<result name="success" type="velocity">/dhis-web-commons/ajax/responsePeriod.vm</result>
<param name="onExceptionReturn">plainTextError</param>
</action>
+
+ <action name="getPeriodsForLock" class="org.hisp.dhis.commons.action.GetPeriodsForLockAction">
+ <result name="success" type="velocity">/dhis-web-commons/ajax/responsePeriod.vm</result>
+ <param name="onExceptionReturn">plainTextError</param>
+ </action>
</package>
=== modified file 'dhis-2/dhis-web/dhis-web-commons/src/main/resources/i18n_global.properties'
--- dhis-2/dhis-web/dhis-web-commons/src/main/resources/i18n_global.properties 2009-09-14 03:19:36 +0000
+++ dhis-2/dhis-web/dhis-web-commons/src/main/resources/i18n_global.properties 2009-09-20 17:27:54 +0000
@@ -55,8 +55,11 @@
dhis-web-dataentry-national = Linelisting Data Entry
dhis-web-validationrule-local-in = Validation Analysis
dhis-web-mapping = GIS
+dhis-web-vn-report = Excel Reports
+dhis-web-survey = Survey
dhis-web-chr-form = Child Health Record
dhis-web-excel-reporting = Excel Reports
+dhis-web-mobile = Mobile Import
#-- Common --------------------------------------------------------------------#
=== modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/java/org/hisp/dhis/dataadmin/action/lock/GetDataSetsForLockAction.java'
--- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/java/org/hisp/dhis/dataadmin/action/lock/GetDataSetsForLockAction.java 2009-09-14 16:13:49 +0000
+++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/java/org/hisp/dhis/dataadmin/action/lock/GetDataSetsForLockAction.java 2009-09-20 17:27:54 +0000
@@ -33,6 +33,7 @@
import org.hisp.dhis.datalock.DataSetLockService;
import org.hisp.dhis.dataset.DataSet;
import org.hisp.dhis.dataset.DataSetService;
+import org.hisp.dhis.oust.manager.SelectionTreeManager;
import org.hisp.dhis.period.Period;
import org.hisp.dhis.period.PeriodService;
@@ -69,6 +70,13 @@
{
this.dataSetLockService = dataSetLockService;
}
+
+ private SelectionTreeManager selectionTreeManager;
+
+ public void setSelectionTreeManager( SelectionTreeManager selectionTreeManager )
+ {
+ this.selectionTreeManager = selectionTreeManager;
+ }
// -------------------------------------------------------------------------
// Input/output
@@ -103,9 +111,19 @@
{
if ( dataSetLockService.getDataSetLockByDataSetAndPeriod( dataSet, period ) != null )
{
- dataSet.setLocked( true );
- dataSetService.updateDataSet( dataSet );
- dataSets.add( dataSet );
+ if( dataSetLockService.getDataSetLockByDataSetAndPeriod( dataSet, period ).getSources() != null )
+ {
+ dataSet.setLocked( true );
+ dataSetService.updateDataSet( dataSet );
+ dataSets.add( dataSet );
+ }
+ else
+ {
+ dataSetLockService.deleteDataSetLock( dataSetLockService.getDataSetLockByDataSetAndPeriod( dataSet, period ) );
+ dataSet.setLocked( false );
+ dataSetService.updateDataSet( dataSet );
+ dataSets.add( dataSet );
+ }
}
else
{
@@ -114,6 +132,8 @@
dataSets.add( dataSet );
}
}
+ //selectionTreeManager.clearLockOnSelectedOrganisationUnits();
+ // selectionTreeManager.clearSelectedOrganisationUnits();
}
return SUCCESS;
}
=== modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/resources/META-INF/dhis/beans.xml'
--- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/resources/META-INF/dhis/beans.xml 2009-09-17 16:08:23 +0000
+++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/resources/META-INF/dhis/beans.xml 2009-09-20 17:27:54 +0000
@@ -11,7 +11,8 @@
scope="prototype">
<property name="dataSetService" ref="org.hisp.dhis.dataset.DataSetService"/>
<property name="periodService" ref="org.hisp.dhis.period.PeriodService"/>
- <property name="dataSetLockService" ref="org.hisp.dhis.datalock.DataSetLockService"/>
+ <property name="dataSetLockService" ref="org.hisp.dhis.datalock.DataSetLockService"/>
+ <property name="selectionTreeManager" ref="org.hisp.dhis.oust.manager.SelectionTreeManager"/>
</bean>
<bean
=== modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/resources/org/hisp/dhis/dataadmin/i18n_module.properties'
--- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/resources/org/hisp/dhis/dataadmin/i18n_module.properties 2009-09-15 03:50:33 +0000
+++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/resources/org/hisp/dhis/dataadmin/i18n_module.properties 2009-09-20 17:27:54 +0000
@@ -1,13 +1,14 @@
-apply_lock_on_all = Apply Lock On All
-remove_all = Remove All Lock
+apply_lock_on_all = Apply Locks On All
+remove_all = Remove All Locks
select_all_at_level = Lock At Level
unselect_all_at_level = Unlock At Level
data_locking_form = Data Locking Form
data_locking = Data Locking
locked_datasets = Locked Data Sets
unlocked_datasets = Unlocked Data Sets
-organisation_units_lock = Organization Units [ Orange Colour = Unlocked ][ Green Colour = Locked ]
+organisation_units_lock = Organization Units [ Black = Unassigned ][ Orange = Assigned,Unlocked ][ Green = Assigned,Locked ]
save = Save
+cancel = Cancel
data_administration = Data Administration
period_type = Period Type
available_periods = Available Periods
@@ -79,7 +80,6 @@
request_returned_in = Request returned in
query_took = Query took
number_of_queries_executed = Number of queries executed
-period_type = Period type
no_data_found = No data found
browse = Browse
back = Back
=== modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/resources/struts.xml'
--- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/resources/struts.xml 2009-09-17 16:08:23 +0000
+++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/resources/struts.xml 2009-09-20 17:27:54 +0000
@@ -13,6 +13,14 @@
</action>
<!-- Locking -->
+
+ <action name="emptyOrgunitSetupAssociationsTree"
+ class="org.hisp.dhis.commons.action.NoAction">
+ <result name="success" type="velocity">
+ /dhis-web-maintenance-dataadmin/noResponseInFrame.vm</result>
+ <param name="javascripts">
+ javascript/oust.js,javascript/associations.js,javascript/locking.js</param>
+ </action>
<action name="displayLockingForm"
class="org.hisp.dhis.dataadmin.action.lock.GetNumberOfLevelsAction">
@@ -71,7 +79,7 @@
class="org.hisp.dhis.dataadmin.action.NoAction">
<result name="success" type="velocity">
/dhis-web-maintenance-dataadmin/selectionedTreeInFrame.vm</result>
- <param name="javascripts">javascript/oust.js,javascript/dataElementsList.js,javascript/associations.js</param>
+ <param name="javascripts">javascript/oust.js,javascript/locking.js,javascript/dataElementsList.js,javascript/associations.js</param>
</action>
<!-- Maintenance -->
=== modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/webapp/dhis-web-maintenance-dataadmin/javascript/associations.js'
--- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/webapp/dhis-web-maintenance-dataadmin/javascript/associations.js 2009-09-10 13:17:59 +0000
+++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/webapp/dhis-web-maintenance-dataadmin/javascript/associations.js 2009-09-20 17:27:54 +0000
@@ -36,6 +36,6 @@
{
hideMessage();
- document.getElementById( "submitButton" ).disabled = false;
+ document.getElementById( "submitButton" ).disabled = false;
}
}
=== modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/webapp/dhis-web-maintenance-dataadmin/javascript/locking.js'
--- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/webapp/dhis-web-maintenance-dataadmin/javascript/locking.js 2009-09-15 03:50:33 +0000
+++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/webapp/dhis-web-maintenance-dataadmin/javascript/locking.js 2009-09-20 17:27:54 +0000
@@ -3,7 +3,7 @@
var periodTypeId = periodTypeList.options[ periodTypeList.selectedIndex ].value;
if ( periodTypeId != null ) {
- var url = "../dhis-web-commons-ajax/getPeriods.action?name=" + periodTypeId;
+ var url = "../dhis-web-commons-ajax/getPeriodsForLock.action?name=" + periodTypeId;
$.ajax({
url: url,
cache: false,
@@ -49,13 +49,10 @@
else {
$('#lockedDataSets').append("<option value="+$(this).find('id').text()+">" +$(this).find('name').text()+ "</option>");
}
- });
+ });
document.getElementById( "unlockedDataSets" ).disabled = false;
document.getElementById( "lockedDataSets" ).disabled = false;
- document.getElementById( "submitButton1" ).disabled = false;
- document.getElementById( "submitButton2" ).disabled = false;
- document.getElementById( "submitButton3" ).disabled = false;
- document.getElementById( "submitButton4" ).disabled = false;
+ LoadEmptyOrgUnitTree();
}
});
}
@@ -73,7 +70,8 @@
}
}
-function LoadOrgUnitTree() {
+function LoadOrgUnitTree() {
+ desableLockOptionButtons();
var periodList = document.getElementById( "periodId" );
var periodId = periodList.options[ periodList.selectedIndex ].value;
var lockedDataSetList = document.getElementById('lockedDataSets');
@@ -81,14 +79,77 @@
iframeForOUTree.location.href='orgunitWiseSetupAssociationsTree.action?selectedLockedDataSetId=' + selectedLockedDataSetId + '&periodId=' + periodId;
}
+
+function LoadEmptyOrgUnitTree(){
+ desableLockOptionButtons();
+ iframeForOUTree.location.href='emptyOrgunitSetupAssociationsTree.action';
+}
+
+function enableLockOptionButtons(){
+ parent.document.getElementById( "submitButton1" ).disabled = false;
+ parent.document.getElementById( "submitButton2" ).disabled = false;
+ parent.document.getElementById( "submitButton3" ).disabled = false;
+ parent.document.getElementById( "submitButton4" ).disabled = false;
+ parent.document.getElementById( "levelList" ).disabled = false;
+ //document.getElementById( "submitButton" ).disabled = false;
+ //document.getElementById( "submitButton5" ).disabled = false;
+}
+
+function desableLockOptionButtons(){
+ parent.document.getElementById( "submitButton1" ).disabled = true;
+ parent.document.getElementById( "submitButton2" ).disabled = true;
+ parent.document.getElementById( "submitButton3" ).disabled = true;
+ parent.document.getElementById( "submitButton4" ).disabled = true;
+ parent.document.getElementById( "levelList" ).disabled = true;
+ //document.getElementById( "submitButton" ).disabled = true;
+ //document.getElementById( "submitButton5" ).disabled = true;
+}
+
+function desableLockOptionButtonsForApplyLockOnAll(){
+ parent.document.getElementById( "submitButton2" ).disabled = true;
+ parent.document.getElementById( "submitButton3" ).disabled = true;
+ parent.document.getElementById( "submitButton4" ).disabled = true;
+ parent.document.getElementById( "levelList" ).disabled = true;
+ //document.getElementById( "submitButton" ).disabled = true;
+ //document.getElementById( "submitButton5" ).disabled = true;
+}
+
+function desableLockOptionButtonsForRemoveAllLocks(){
+ parent.document.getElementById( "submitButton1" ).disabled = true;
+ parent.document.getElementById( "submitButton3" ).disabled = true;
+ parent.document.getElementById( "submitButton4" ).disabled = true;
+ parent.document.getElementById( "levelList" ).disabled = true;
+ //document.getElementById( "submitButton" ).disabled = true;
+ //document.getElementById( "submitButton5" ).disabled = true;
+}
+
+function desableLockOptionButtonsForLockAtLevel(){
+ parent.document.getElementById( "submitButton1" ).disabled = true;
+ parent.document.getElementById( "submitButton2" ).disabled = true;
+ parent.document.getElementById( "submitButton4" ).disabled = true;
+ parent.document.getElementById( "levelList" ).disabled = true;
+ //document.getElementById( "submitButton" ).disabled = true;
+ //document.getElementById( "submitButton5" ).disabled = true;
+}
+
+function desableLockOptionButtonsForUnlockAtLevel(){
+ parent.document.getElementById( "submitButton1" ).disabled = true;
+ parent.document.getElementById( "submitButton2" ).disabled = true;
+ parent.document.getElementById( "submitButton3" ).disabled = true;
+ parent.document.getElementById( "levelList" ).disabled = true;
+ //document.getElementById( "submitButton" ).disabled = true;
+ //document.getElementById( "submitButton5" ).disabled = true;
+}
-function ApplyAll() {
+function ApplyAll(){
+ desableLockOptionButtonsForApplyLockOnAll();
var lockedDataSetList = document.getElementById('lockedDataSets');
var selectedLockedDataSetId = lockedDataSetList.options[ lockedDataSetList.selectedIndex ].value;
iframeForOUTree.location.href ='selectAll.action?selectedLockedDataSetId=' + selectedLockedDataSetId;
}
-function RemoveAll() {
+function RemoveAll(){
+ desableLockOptionButtonsForRemoveAllLocks();
var periodList = document.getElementById( "periodId" );
var periodId = periodList.options[ periodList.selectedIndex ].value;
var lockedDataSetList = document.getElementById('lockedDataSets');
@@ -96,7 +157,8 @@
iframeForOUTree.location.href='unselectAll.action?selectedLockedDataSetId=' + selectedLockedDataSetId + '&periodId=' + periodId;
}
-function lockAllAtLevel() {
+function lockAllAtLevel(){
+ desableLockOptionButtonsForLockAtLevel();
var periodList = document.getElementById( "periodId" );
var periodId = periodList.options[ periodList.selectedIndex ].value;
var list = document.getElementById( 'levelList' );
@@ -106,7 +168,8 @@
iframeForOUTree.location.href ='selectLevel.action?level=' + level + '&selectedLockedDataSetId=' + selectedLockedDataSetId + '&periodId=' + periodId;
}
-function unLockAllAtLevel() {
+function unLockAllAtLevel(){
+ desableLockOptionButtonsForUnlockAtLevel();
var periodList = document.getElementById( "periodId" );
var periodId = periodList.options[ periodList.selectedIndex ].value;
var list = document.getElementById( 'levelList' );
@@ -116,14 +179,14 @@
iframeForOUTree.location.href = 'unselectLevel.action?level=' + level + '&selectedLockedDataSetId=' + selectedLockedDataSetId + '&periodId=' + periodId;
}
-function updateDataSetsOrgunitwise() {
+function updateDataSetsOrgunitwise(){
if ( validateLocking() ) {
selectAllById( "unlockedDataSets" );
document.getElementById( "lockingForm" ).submit();
}
}
-function validateLocking() {
+function validateLocking(){
if ( getListValue( "periodTypeId" ) == "null" ) {
setMessage( i18n_select_a_period_type );
return false;
=== modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/webapp/dhis-web-maintenance-dataadmin/javascript/oust.js'
--- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/webapp/dhis-web-maintenance-dataadmin/javascript/oust.js 2009-09-15 03:50:33 +0000
+++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/webapp/dhis-web-maintenance-dataadmin/javascript/oust.js 2009-09-20 17:27:54 +0000
@@ -113,6 +113,7 @@
var treeTag = document.getElementById( 'selectionTree' );
setLoadingMessage( treeTag );
var children = treeTag.getElementsByTagName( 'ul' );
+
if ( children.length > 0 )
{
treeTag.removeChild( children[0] );
@@ -169,7 +170,7 @@
}
clearLoadingMessage( treeTag );
-
+ enableLockOptionButtons();
}
function createChildren( parentTag, parentElement ){
@@ -234,7 +235,7 @@
}
else{
toggleTag.appendChild( toggleImg );
- }
+ }
}
function setVisible( tag, visible ){
=== modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/webapp/dhis-web-maintenance-dataadmin/lockingForm.vm'
--- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/webapp/dhis-web-maintenance-dataadmin/lockingForm.vm 2009-09-15 03:50:33 +0000
+++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/webapp/dhis-web-maintenance-dataadmin/lockingForm.vm 2009-09-20 17:27:54 +0000
@@ -83,7 +83,7 @@
<input type="button" id="submitButton1" value="$i18n.getString( "apply_lock_on_all" )" onclick="ApplyAll()" style="width:12em" disabled="true">
<input type="button" id="submitButton2" value="$i18n.getString( "remove_all" )" onclick="RemoveAll()" style="width:12em" disabled="true">
<input type="button" id="submitButton3" value="$i18n.getString( "select_all_at_level" )" onclick="lockAllAtLevel()" style="width:12em" disabled="true">
- <select id="levelList" id="levelList" name="levelList" style="width:12em">
+ <select id="levelList" name="levelList" style="width:12em" disabled="true">
#foreach( $level in $levels )
<option value="$level.level" #if ( $selectLevel == $level.level )selected="selcted"#end>$encoder.htmlEncode( $level.name )</option>
#end
=== added file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/webapp/dhis-web-maintenance-dataadmin/noResponseInFrame.vm'
=== modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/webapp/dhis-web-maintenance-dataadmin/selectionedTreeInFrame.vm'
--- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/webapp/dhis-web-maintenance-dataadmin/selectionedTreeInFrame.vm 2009-09-15 03:50:33 +0000
+++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataadmin/src/main/webapp/dhis-web-maintenance-dataadmin/selectionedTreeInFrame.vm 2009-09-20 17:27:54 +0000
@@ -41,10 +41,11 @@
selectionTreeSelection.setOnSelectFunction( treeClicked );
selectionTreeSelection.setListenerFunction( selectCompleted );
selectionTree.buildSelectionTree();
+
</script>
<script type="text/javascript">
var i18n_loading = '$encoder.jsEncode( $i18n.getString( "loading" ) )';
- </script>
+ </script>
</td>
</tr>
@@ -54,7 +55,7 @@
<tr>
<td>
<input type="button" id="submitButton" value="$i18n.getString( 'save' )" style="width:15em" onclick="parent.updateDataSetsOrgunitwise()">
- <input type="button" id="submitButton5" value="$i18n.getString( 'cancel' )" style="width:15em" onclick="parent.cancilSelection()">
+ <input type="button" id="submitButton5" value="$i18n.getString( 'cancel' )" style="width:15em" onclick="parent.cancilSelection()">
</td>
<td colspan="2"></td>
</tr>