dhis2-devs team mailing list archive
-
dhis2-devs team
-
Mailing list archive
-
Message #33076
[Branch ~dhis2-devs-core/dhis2/trunk] Rev 16842: Fix for org unit levels save notification
------------------------------------------------------------
revno: 16842
committer: Lars Helge Overland <larshelge@xxxxxxxxx>
branch nick: dhis2
timestamp: Sun 2014-09-28 22:57:54 +0200
message:
Fix for org unit levels save notification
modified:
dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/css/widgets.css
dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/javascripts/commons.js
dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-organisationunit/src/main/webapp/dhis-web-maintenance-organisationunit/saveOrganisationUnitLevelForm.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-commons-resources/src/main/webapp/dhis-web-commons/css/widgets.css'
--- dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/css/widgets.css 2014-09-22 12:02:33 +0000
+++ dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/css/widgets.css 2014-09-28 20:57:54 +0000
@@ -339,7 +339,7 @@
/* Message field */
/*----------------------------------------------------------------------------*/
-span#message
+#message
{
display: none;
padding: 1em;
@@ -350,7 +350,7 @@
border-radius: 3px;
}
-span#info
+#info
{
display: block;
padding: 1em;
=== modified file 'dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/javascripts/commons.js'
--- dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/javascripts/commons.js 2014-08-29 08:45:54 +0000
+++ dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/javascripts/commons.js 2014-09-28 20:57:54 +0000
@@ -610,10 +610,9 @@
*/
function setMessage( message )
{
- if ( message && message != '' )
+ if ( message )
{
- $( '#message' ).html( message );
- $( '#message' ).show();
+ $( '#message' ).html( message ).show();
}
}
=== modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-organisationunit/src/main/webapp/dhis-web-maintenance-organisationunit/saveOrganisationUnitLevelForm.vm'
--- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-organisationunit/src/main/webapp/dhis-web-maintenance-organisationunit/saveOrganisationUnitLevelForm.vm 2014-06-01 11:31:40 +0000
+++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-organisationunit/src/main/webapp/dhis-web-maintenance-organisationunit/saveOrganisationUnitLevelForm.vm 2014-09-28 20:57:54 +0000
@@ -5,7 +5,7 @@
validation( 'saveOrganisationUnitLevelsForm', function( form ){ form.submit() } );
jQuery.getJSON( '../api/organisationUnitLevels.json?paging=false', function( data ) {
- if ( !data || !data.organisationUnitLevels || !data.organisationUnitLevels ) {
+ if ( !data || !data.organisationUnitLevels || !data.organisationUnitLevels.length ) {
setMessage( 'Organisation unit level is not yet saved, please save' );
}
} );
@@ -39,4 +39,4 @@
</table>
</form>
-<span id="message"></span>
\ No newline at end of file
+<div id="message"></div>
\ No newline at end of file