dhis2-devs team mailing list archive
-
dhis2-devs team
-
Mailing list archive
-
Message #20454
[Branch ~dhis2-devs-core/dhis2/trunk] Rev 9336: Minor fix for statistical program report ui.
------------------------------------------------------------
revno: 9336
committer: Tran Chau <tran.hispvietnam@xxxxxxxxx>
branch nick: dhis2
timestamp: Mon 2012-12-17 15:43:52 +0700
message:
Minor fix for statistical program report ui.
modified:
dhis-2/dhis-web/dhis-web-caseentry/src/main/resources/org/hisp/dhis/caseentry/i18n_module.properties
dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/javascript/statisticalReport.js
dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/reportDataEntryForm.vm
dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/statisticalProgramDetailsReport.vm
dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/statisticalProgramReport.vm
dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/statisticalProgramReportSelect.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/resources/org/hisp/dhis/caseentry/i18n_module.properties'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/resources/org/hisp/dhis/caseentry/i18n_module.properties 2012-12-17 02:42:30 +0000
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/resources/org/hisp/dhis/caseentry/i18n_module.properties 2012-12-17 08:43:52 +0000
@@ -485,4 +485,5 @@
percent_incomplete = Percent Incomplete
percent_Scheduled = Percent scheduled
percent_overdue = Percent Overdue
-scheduled = Scheduled
\ No newline at end of file
+scheduled = Scheduled
+start = Start
\ No newline at end of file
=== modified file 'dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/javascript/statisticalReport.js'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/javascript/statisticalReport.js 2012-12-17 03:12:41 +0000
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/javascript/statisticalReport.js 2012-12-17 08:43:52 +0000
@@ -8,7 +8,6 @@
function generatedStatisticalProgramReport()
{
- hideById('backBtn');
hideById('statisticalReportDiv');
hideById('detailsDiv');
showLoader();
@@ -46,12 +45,13 @@
{
setFieldValue('status',status);
setFieldValue('total',total);
- var subTitle = getFieldValue("programStageName")
- + " - " + getStatusString( status )
- + " - " + i18n_total_result + ": " + total;
- setInnerHTML('gridSubtitleDetails', subTitle );
+ var programStageTitle = "» " + getStatusString( status )
+ + " - " + getFieldValue("programStageName");
+ setInnerHTML('programStageTitleLbl', programStageTitle );
+ setInnerHTML('totalLbl', i18n_total_result + ": " + total );
+ showById('totalLbl');
+ showById('programStageTitleLbl');
showById( 'detailsDiv');
- showById('backBtn');
hideLoader();
});
}
@@ -67,34 +67,46 @@
}
}
-function backOnClick()
-{
- hideById('backBtn');
- showById('reportTbl');
- hideById('detailsDiv');
-}
-
function loadDataEntry( programStageInstanceId )
{
+ hideById("detailsDiv");
jQuery('#viewRecordsDiv' )
.load( 'viewProgramStageRecords.action?programStageInstanceId=' + programStageInstanceId
,function(){
jQuery("#viewRecordsDiv :input" ).attr("disabled", true);
jQuery("#viewRecordsDiv :input" ).datepicker("destroy");
- showById("reportTitle");
- hideById("patientInforTB");
+ showById('patientNameLbl');
jQuery(".ui-combobox" ).hide();
+ showById("viewRecordsDiv");
hideById('inputCriteriaDiv');
- })
- .dialog({
- title: i18n_reports,
- maximize: true,
- closable: true,
- modal:false,
- overlay:{background:'#000000', opacity:0.1},
- width: 840,
- height: 400
+ hideById('totalLbl');
});
}
-function entryFormContainerOnReady(){}
\ No newline at end of file
+function entryFormContainerOnReady(){}
+
+function showCriteriaForm()
+{
+ showById('reportForm');
+ hideById('statisticalReportDiv');
+}
+
+function showStatisticalReport()
+{
+ showById('reportTbl');
+ hideById('detailsDiv');
+ hideById('totalLbl');
+ hideById('viewRecordsDiv');
+ hideById('programStageTitleLbl');
+ hideById('patientNameLbl');
+ hideById('totalLbl');
+}
+
+function detailsReport()
+{
+ hideById('viewRecordsDiv');
+ showById('detailsDiv');
+ showById('totalLbl');
+ showById('programStageTitleLbl');
+ hideById('patientNameLbl');
+}
=== modified file 'dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/reportDataEntryForm.vm'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/reportDataEntryForm.vm 2012-12-10 12:54:54 +0000
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/reportDataEntryForm.vm 2012-12-17 08:43:52 +0000
@@ -8,7 +8,7 @@
#if( $patient )
<tr>
<td>
- <span class='bold'>$i18n.getString( "full_name" ):</span>
+ <span class='bold' id="patientName">$i18n.getString( "full_name" ):</span>
</td>
<td>
$encoder.htmlEncode( $patient.getFullName() ) ( $i18n.getString( "$patient.gender" ) )
@@ -62,6 +62,7 @@
enable('completeBtn');
disable('uncompleteBtn');
#end
+ setInnerHTML("patientNameLbl", "» " + "$encoder.jsEncode( $patient.getFullName() )");
});
var i18n_value_must_integer = '$encoder.jsEscape( $i18n.getString( "value_must_integer" ) , "'")';
=== modified file 'dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/statisticalProgramDetailsReport.vm'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/statisticalProgramDetailsReport.vm 2012-12-17 03:12:41 +0000
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/statisticalProgramDetailsReport.vm 2012-12-17 08:43:52 +0000
@@ -1,11 +1,3 @@
-<h5 id="gridSubtitleDetails"></h5>
-<script>
- var subTitle = getFieldValue("programStageName")
- + " - " + getStatusString( getFieldValue('status'))
- + " - " + i18n_total_result + ": " + getFieldValue('total');
- setInnerHTML('gridSubtitleDetails', subTitle );
-</script>
-
<input type="hidden" id="programStageName" name="programStageName" value="$!encoder.jsEncode($programStage.name)">
<table width="100%">
<tr>
@@ -68,8 +60,6 @@
</tr>
</table>
-<div id="viewRecordsDiv"></div>
-
<script>
jQuery(document).ready(function(){
setTableStyles();
=== modified file 'dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/statisticalProgramReport.vm'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/statisticalProgramReport.vm 2012-12-17 03:12:41 +0000
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/statisticalProgramReport.vm 2012-12-17 08:43:52 +0000
@@ -1,7 +1,13 @@
-<h3 id="gridTitle">$!encoder.htmlEncode( $grid.title )</h3>
+<h6>
+ <a href="javascript:showCriteriaForm();">$i18n.getString("start")</a>
+ » <a href="javascript:showStatisticalReport();">$!encoder.htmlEncode( $grid.title )</a>
+ <a href="javascript:detailsReport();"><span id="programStageTitleLbl"></span></a>
+ <span id="patientNameLbl"></span>
+</h6>
+<p id="totalLbl" class="hidden"></p>
<div id="reportTbl" name="reportTbl">
- <h5 id="gridSubtitle">$!encoder.htmlEncode( $grid.subtitle )</h5>
+ <p id="totalLbl">$!encoder.htmlEncode( $grid.subtitle )</p>
<table class="listTable gridTable" width="150px;">
<thead>
<tr>
@@ -39,3 +45,5 @@
</div>
<div id='detailsDiv'></div>
+<div id="viewRecordsDiv"></div>
+
=== modified file 'dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/statisticalProgramReportSelect.vm'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/statisticalProgramReportSelect.vm 2012-12-17 03:12:41 +0000
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/statisticalProgramReportSelect.vm 2012-12-17 08:43:52 +0000
@@ -9,11 +9,6 @@
<h3>$i18n.getString( "statistical_program_report" )</h3>
-<p>
- <input type="button" onclick="showById('reportForm');" value="$i18n.getString('data')">
- <input type="button" id="backBtn" name="backBtn" onclick="backOnClick();" value="$i18n.getString('back')" class="hidden">
-</p>
-
<form id="reportForm" name="reportForm" method="post">
<input type="hidden" id="status" name="status">
<input type="hidden" id="total" name="total">