dhis2-devs team mailing list archive
-
dhis2-devs team
-
Mailing list archive
-
Message #19334
[Branch ~dhis2-devs-core/dhis2/trunk] Rev 8386: Don't display event flow of single program with registration in dashboard.
------------------------------------------------------------
revno: 8386
committer: Tran Chau <tran.hispvietnam@xxxxxxxxx>
branch nick: dhis2
timestamp: Fri 2012-10-05 14:47:52 +0700
message:
Don't display event flow of single program with registration in dashboard.
modified:
dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/dataEntryForm.vm
dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/javascript/commons.js
dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/javascript/entry.js
dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/programStageInstanceFlow.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-caseentry/src/main/webapp/dhis-web-caseentry/dataEntryForm.vm'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/dataEntryForm.vm 2012-10-05 06:46:22 +0000
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/dataEntryForm.vm 2012-10-05 07:47:52 +0000
@@ -31,7 +31,7 @@
<div id='entryForm' #if($!programStageInstance.executionDate) class='visible' #else class='hidden' #end>
#if( $customDataEntryFormCode )
#parse( "/dhis-web-caseentry/customDataEntryForm.vm" )
- #elseif( $sections.size() > 0 )
+ #elseif( $sections && $sections.size() > 0 )
#parse( "/dhis-web-caseentry/sectionDataEntryForm.vm" )
#else
#parse( "/dhis-web-caseentry/defaultDataEntryForm.vm" )
=== modified file 'dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/javascript/commons.js'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/javascript/commons.js 2012-10-05 06:46:22 +0000
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/javascript/commons.js 2012-10-05 07:47:52 +0000
@@ -1270,10 +1270,11 @@
}, function()
{
showById('programEnrollmentDiv');
- var type = jQuery('#tr_'+programInstanceId).attr('programType');
+ var type = jQuery('#tb_' + programInstanceId).attr('programType');
if(type=='2'){
+ hideById('colorHelpLink');
hideById('programInstanceDiv');
- var programStageInstanceId = jQuery('#tr_'+programInstanceId).attr('programStageInstanceId');
+ var programStageInstanceId = jQuery('.stage-object').attr('id').split('_')[1];
loadDataEntry( programStageInstanceId );
}
else{
=== modified file 'dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/javascript/entry.js'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/javascript/entry.js 2012-10-05 07:22:56 +0000
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/javascript/entry.js 2012-10-05 07:47:52 +0000
@@ -444,7 +444,7 @@
}
}
-function doComplete( isCreateEvent )
+function doComplete()
{
var flag = false;
jQuery("#dataEntryFormDiv input[name='entryfield'],select[name='entryselect']").each(function(){
@@ -494,24 +494,13 @@
var selectedProgram = jQuery('.stage-object-selected');
if( selectedProgram.attr('programType')=='2' || json.response == 'programcompleted' )
{
- selectedProgram.remove();
- hideById('programInstanceDiv');
- if( !isCreateEvent ){
- hideById('entryFormContainer');
- }
var completedRow = jQuery('#td_' + programInstanceId).html();
jQuery('#completedList' ).append('<option value="' + programInstanceId + '">' + getInnerHTML('infor_' + programInstanceId ) + '</option>');
- hideById('tr1_' + programInstanceId );
- hideById('tr2_' + programInstanceId );
}
selection.enable();
hideLoader();
hideById('contentDiv');
- if( isCreateEvent )
- {
- showAddEventForm();
- }
});
}
}
=== modified file 'dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/programStageInstanceFlow.vm'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/programStageInstanceFlow.vm 2012-10-05 04:50:32 +0000
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/programStageInstanceFlow.vm 2012-10-05 07:47:52 +0000
@@ -1,4 +1,4 @@
-<table id='tb_$!programInstance.id' class="stage-container">
+<table id='tb_$!programInstance.id' class="stage-container" programType='$!programInstance.program.type'>
<tr>
<td>
<div class="arrow-left" onclick="moveLeft('flow_$!programInstance.id')"> </div>