dhis2-devs team mailing list archive
-
dhis2-devs team
-
Mailing list archive
-
Message #21005
[Branch ~dhis2-devs-core/dhis2/trunk] Rev 9834: Clean up code.
------------------------------------------------------------
revno: 9834
committer: Tran Chau <tran.hispvietnam@xxxxxxxxx>
branch nick: dhis2
timestamp: Tue 2013-02-19 15:33:46 +0700
message:
Clean up code.
removed:
dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/jsonAggregateReport.vm
dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-patient/src/main/webapp/dhis-web-maintenance-patient/programStageList.vm
renamed:
dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/jsonAggregateReportResult.vm => dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/jsonTabularAggregateReportResult.vm
modified:
dhis-2/dhis-web/dhis-web-caseentry/src/main/resources/struts.xml
dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-patient/src/main/webapp/dhis-web-maintenance-patient/programStage.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/struts.xml'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/resources/struts.xml 2013-02-19 07:58:54 +0000
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/resources/struts.xml 2013-02-19 08:33:46 +0000
@@ -893,7 +893,7 @@
<action name="generateAggregateReport"
class="org.hisp.dhis.caseentry.action.report.GenerateAggregateReportAction">
- <result name="success" type="velocity-json">/dhis-web-caseentry/jsonAggregateReportResult.vm
+ <result name="success" type="velocity-json">/dhis-web-caseentry/jsonTabularAggregateReportResult.vm
</result>
<result name="xls" type="gridXlsResult" />
<result name="pdf" type="gridPdfResult" />
=== removed file 'dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/jsonAggregateReport.vm'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/jsonAggregateReport.vm 2013-02-11 15:09:56 +0000
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/jsonAggregateReport.vm 1970-01-01 00:00:00 +0000
@@ -1,36 +0,0 @@
-
-#set( $noRows = $grid.getRows().size() )
-{
-#set( $noHeader = $grid.getHeaders().size() )
-#set( $metaData = $noHeader - $valueTypes.size() )
-"message": "$!message",
-"total": "$total",
-"totalRecords": "$totalRecords",
-"title": "$!encoder.jsonEncode(${grid.subtitle})",
-"columns":[
- #set($index = 0)
- #foreach( $col in $grid.getHeaders() )
- {
- #set( $mapIndx = $index - $metaData )
- "xtype": #if( $mapSuggestedValues.get($mapIndx) && $index > $metaData && $mapSuggestedValues.get($mapIndx).size() > 0 )"combobox"#else"textfield"#end,
- "suggested": [#set( $suggestedValues = $mapSuggestedValues.get($mapIndx) )
- #foreach( $suggestedValue in $suggestedValues )
- ["$!encoder.jsonEncode( ${suggestedValue} )"]
- #if( $velocityCount < $suggestedValues.size() ),#end
- #end],
- "name": "$!encoder.jsonEncode($!col.name)",
- "hidden": "$!col.hidden"
- }#if( $velocityCount < $noHeader ),#end
- #set($index = $index + 1)
- #end
-],
-"items":[
- #foreach( $row in $grid.getRows() )
- [
- #foreach( $col in $row )
- "$!encoder.jsonEncode($!col)"#if( $velocityCount < $noHeader ),#end
- #end
- ]#if( $velocityCount < $noRows ),#end
- #end
- ]
-}
\ No newline at end of file
=== renamed file 'dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/jsonAggregateReportResult.vm' => 'dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/jsonTabularAggregateReportResult.vm'
=== modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-patient/src/main/webapp/dhis-web-maintenance-patient/programStage.vm'
--- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-patient/src/main/webapp/dhis-web-maintenance-patient/programStage.vm 2013-01-23 10:27:28 +0000
+++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-patient/src/main/webapp/dhis-web-maintenance-patient/programStage.vm 2013-02-19 08:33:46 +0000
@@ -13,14 +13,66 @@
#end
<input type="button" value="$i18n.getString( 'back' )" onclick="window.location.href='program.action'" style="width:150px">
</td>
- <td style="width:264px"></td>
+ </tr>
+ <tr>
+ <td style="vertical-align:top" colspan=2>
+ <table class="listTable" id="listTable">
+ <col>
+ <col>
+ <col width="160">
+ <thead>
+ <tr>
+ <th>$i18n.getString( "name" )</th>
+ <th>$i18n.getString( "description" )</th>
+ <th>$i18n.getString( "operations" )</th>
+ </tr>
+ </thead>
+
+ <tbody id="list">
+ #set( $mark = false )
+ #foreach( $association in $associations )
+ <tr id="tr${association.id}" #alternate( $mark )>
+ <td onclick="showProgramStageDetails( $association.id )">$encoder.htmlEncode( $association.displayName )</td>
+ <td onclick="showProgramStageDetails( $association.id )">$encoder.htmlEncode( $association.description )</td>
+
+ <td style="text-align:center"#alternate( $mark )>
+ <a href="showUpdateProgramStageForm.action?id=$association.id" title="$i18n.getString( "edit" )"><img src="../images/edit.png" alt="$i18n.getString( 'edit' )"></a>
+ <a href="javascript:translate( 'ProgramStage', '$association.id' )" title="$i18n.getString( 'translation_translate' )"><img src="../images/i18n.png" alt="$i18n.getString( 'translation_translate' )"/></a>
+ #if( $program.type=='1' )
+ <a href="javascript:removeItem( '$association.id', '$encoder.jsEncode( $association.name )', i18n_confirm_delete , 'removeProgramStage.action' )" title="$i18n.getString( 'remove' )"><img src="../images/delete.png" alt="$i18n.getString( 'remove' )"></a>
+ #end
+ <a href="javascript:showProgramStageDetails( $association.id )" title="$i18n.getString( "show_details" )"><img src="../images/information.png" alt="$i18n.getString( 'show_details' )"></a>
+ <a href="programStageSectionList.action?id=$association.id" title="$i18n.getString( 'section_management' )"><img src="images/sections.png" alt="$i18n.getString( 'section_management' )"></a>
+ <a href="viewDataEntryForm.action?programStageId=$association.id" title="$i18n.getString( "design_data_entry_form" )"><img src="../images/edit_layout.png" alt="$i18n.getString( 'design_data_entry_form' )"></a>
+ </td>
+ </tr>
+ #set( $mark = !$mark )
+ #end
+ </tbody>
+ </table>
+ </td>
+
+ <td style="width:20em; padding-left:2em; vertical-align:top">
+ <div id="detailsArea" style="display:none">
+ <div style="float:right">
+ <a href="javascript:hideDetails()" title="$i18n.getString( 'hide_details' )"><img src="../images/hide.png" alt="$i18n.getString( 'hide_details' )"></a>
+ </div>
+ <p><label class="bold">$i18n.getString( "name" ):</label><br><span id="nameField"></span></p>
+ <p><label class="bold">$i18n.getString( "description" ):</label><br><span id="descriptionField"></span></p>
+ <p><label class="bold">$i18n.getString( "scheduled_days_from_start" ):</label><br><span id="scheduledDaysFromStartField"></span></p>
+ <p><label class="bold">$i18n.getString( "auto_generate_event" ):</label><br><span id="autoGenerateEventField"></span></p>
+ <p><label class="bold">$i18n.getString( "irregular" ):</label><br><span id="irregularField"></span></p>
+ <p><label class="bold">$i18n.getString( "display_generate_event_box_after_completed" ):</label><br><span id="displayGenerateEventBoxField"></span></p>
+ <p><label class="bold">$i18n.getString( "standard_interval_days" ):</label><br><span id="standardIntervalField"></span></p>
+ <p><label class="bold">$i18n.getString( "complete_allowed_only_if_validation_passes" ):</label><br><span id="validCompleteOnlyField"></span></p>
+ <p><label class="bold">$i18n.getString( "report_date_description" ):</label><br><span id="reportDateDescriptionField"></span></p>
+ <p><label class="bold">$i18n.getString( "no_of_dataelements" ):</label><br><span id="dataElementCountField"></span></p>
+ <p><span id="templateMessageField"></span></p>
+ </div>
+ </td>
</tr>
</table>
-<div id='programStageListDiv'>
- #parse( "/dhis-web-maintenance-patient/programStageList.vm" )
-</div>
-
<script type="text/javascript">
var i18n_please_select_program = '$encoder.jsEscape( $i18n.getString( "please_select_program" ) , "'" )';
var i18n_confirm_delete = '$encoder.jsEscape( $i18n.getString( "confirm_delete_prorgam_stage" ) , "'" )';
=== removed file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-patient/src/main/webapp/dhis-web-maintenance-patient/programStageList.vm'
--- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-patient/src/main/webapp/dhis-web-maintenance-patient/programStageList.vm 2013-02-13 15:58:32 +0000
+++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-patient/src/main/webapp/dhis-web-maintenance-patient/programStageList.vm 1970-01-01 00:00:00 +0000
@@ -1,59 +0,0 @@
-<table class="mainPageTable">
- <tr>
- <td style="vertical-align:top" colspan=2>
- <table class="listTable" id="listTable">
- <col>
- <col>
- <col width="180">
- <thead>
- <tr>
- <th>$i18n.getString( "name" )</th>
- <th>$i18n.getString( "description" )</th>
- <th>$i18n.getString( "operations" )</th>
- </tr>
- </thead>
-
- <tbody id="list">
- #set( $mark = false )
- #foreach( $association in $associations )
- <tr id="tr${association.id}" #alternate( $mark )>
- <td onclick="showProgramStageDetails( $association.id )">$encoder.htmlEncode( $association.displayName )</td>
- <td onclick="showProgramStageDetails( $association.id )">$encoder.htmlEncode( $association.description )</td>
-
- <td style="text-align:center"#alternate( $mark )>
- <a href="showUpdateProgramStageForm.action?id=$association.id" title="$i18n.getString( "edit" )"><img src="../images/edit.png" alt="$i18n.getString( 'edit' )"></a>
- <a href="javascript:translate( 'ProgramStage', '$association.id' )" title="$i18n.getString( 'translation_translate' )"><img src="../images/i18n.png" alt="$i18n.getString( 'translation_translate' )"/></a>
- #if( $program.type=='1' )
- <a href="javascript:removeItem( '$association.id', '$encoder.jsEncode( $association.name )', i18n_confirm_delete , 'removeProgramStage.action' )" title="$i18n.getString( 'remove' )"><img src="../images/delete.png" alt="$i18n.getString( 'remove' )"></a>
- #end
- <a href="javascript:showProgramStageDetails( $association.id )" title="$i18n.getString( "show_details" )"><img src="../images/information.png" alt="$i18n.getString( 'show_details' )"></a>
- <a href="programStageSectionList.action?id=$association.id" title="$i18n.getString( 'section_management' )"><img src="images/sections.png" alt="$i18n.getString( 'section_management' )"></a>
- <a href="viewDataEntryForm.action?programStageId=$association.id" title="$i18n.getString( "design_data_entry_form" )"><img src="../images/edit_layout.png" alt="$i18n.getString( 'design_data_entry_form' )"></a>
- </td>
- </tr>
- #set( $mark = !$mark )
- #end
- </tbody>
- </table>
- </td>
-
- <td style="width:20em; padding-left:2em; vertical-align:top">
- <div id="detailsArea" style="display:none">
- <div style="float:right">
- <a href="javascript:hideDetails()" title="$i18n.getString( 'hide_details' )"><img src="../images/hide.png" alt="$i18n.getString( 'hide_details' )"></a>
- </div>
- <p><label class="bold">$i18n.getString( "name" ):</label><br><span id="nameField"></span></p>
- <p><label class="bold">$i18n.getString( "description" ):</label><br><span id="descriptionField"></span></p>
- <p><label class="bold">$i18n.getString( "scheduled_days_from_start" ):</label><br><span id="scheduledDaysFromStartField"></span></p>
- <p><label class="bold">$i18n.getString( "auto_generate_event" ):</label><br><span id="autoGenerateEventField"></span></p>
- <p><label class="bold">$i18n.getString( "irregular" ):</label><br><span id="irregularField"></span></p>
- <p><label class="bold">$i18n.getString( "display_generate_event_box_after_completed" ):</label><br><span id="displayGenerateEventBoxField"></span></p>
- <p><label class="bold">$i18n.getString( "standard_interval_days" ):</label><br><span id="standardIntervalField"></span></p>
- <p><label class="bold">$i18n.getString( "complete_allowed_only_if_validation_passes" ):</label><br><span id="validCompleteOnlyField"></span></p>
- <p><label class="bold">$i18n.getString( "report_date_description" ):</label><br><span id="reportDateDescriptionField"></span></p>
- <p><label class="bold">$i18n.getString( "no_of_dataelements" ):</label><br><span id="dataElementCountField"></span></p>
- <p><span id="templateMessageField"></span></p>
- </div>
- </td>
- </tr>
-</table>