=== modified file 'local/vn/dhis-web-spreadsheet-reporting/src/main/java/org/hisp/dhis/reportsheet/exporting/GenerateExcelReportGeneric.java' --- local/vn/dhis-web-spreadsheet-reporting/src/main/java/org/hisp/dhis/reportsheet/exporting/GenerateExcelReportGeneric.java 2012-05-03 10:04:29 +0000 +++ local/vn/dhis-web-spreadsheet-reporting/src/main/java/org/hisp/dhis/reportsheet/exporting/GenerateExcelReportGeneric.java 2012-05-09 05:19:35 +0000 @@ -26,16 +26,16 @@ */ package org.hisp.dhis.reportsheet.exporting; +import static org.hisp.dhis.reportsheet.utils.ExpressionUtils.generateExpression; +import static org.hisp.dhis.reportsheet.utils.ExpressionUtils.generateIndicatorExpression; +import static org.hisp.dhis.reportsheet.utils.DateUtils.getTimeRoll; +import static org.hisp.dhis.reportsheet.utils.DateUtils.getFirstDayOfMonth; +import static org.hisp.dhis.reportsheet.utils.DateUtils.getStartQuaterly; import static org.hisp.dhis.reportsheet.utils.DateUtils.getEndQuaterly; +import static org.hisp.dhis.reportsheet.utils.DateUtils.getStartSixMonthly; import static org.hisp.dhis.reportsheet.utils.DateUtils.getEndSixMonthly; -import static org.hisp.dhis.reportsheet.utils.DateUtils.getFirstDayOfMonth; import static org.hisp.dhis.reportsheet.utils.DateUtils.getFirstDayOfYear; import static org.hisp.dhis.reportsheet.utils.DateUtils.getLastDayOfYear; -import static org.hisp.dhis.reportsheet.utils.DateUtils.getStartQuaterly; -import static org.hisp.dhis.reportsheet.utils.DateUtils.getStartSixMonthly; -import static org.hisp.dhis.reportsheet.utils.DateUtils.getTimeRoll; -import static org.hisp.dhis.reportsheet.utils.ExpressionUtils.generateExpression; -import static org.hisp.dhis.reportsheet.utils.ExpressionUtils.generateIndicatorExpression; import static org.hisp.dhis.reportsheet.utils.FileUtils.checkingExtensionExcelFile; import static org.hisp.dhis.system.util.MathUtils.calculateExpression; @@ -219,6 +219,10 @@ protected Font csFont11Bold; protected Font csFont10Bold; + + protected Font csFont9Bold; + + protected Font csFont8Bold; protected Font csFont12BoldCenter; @@ -229,6 +233,10 @@ protected CellStyle csText; protected CellStyle csText10Bold; + + protected CellStyle csText9Bold; + + protected CellStyle csText8Bold; protected CellStyle csTextSerial; @@ -287,6 +295,8 @@ { sheetPOI = templateWorkbook.getSheetAt( 0 ); csFont = templateWorkbook.createFont(); + csFont8Bold = templateWorkbook.createFont(); + csFont9Bold = templateWorkbook.createFont(); csFont10Bold = templateWorkbook.createFont(); csFont11Bold = templateWorkbook.createFont(); csFont12BoldCenter = templateWorkbook.createFont(); @@ -295,6 +305,7 @@ csFormula = templateWorkbook.createCellStyle(); csText = templateWorkbook.createCellStyle(); csText10Bold = templateWorkbook.createCellStyle(); + csText10Bold = templateWorkbook.createCellStyle(); csTextSerial = templateWorkbook.createCellStyle(); csTextICDJustify = templateWorkbook.createCellStyle(); csText12BoldCenter = templateWorkbook.createCellStyle(); @@ -307,6 +318,12 @@ initPOIStylesManager.initDefaultFont( csFont ); initPOIStylesManager.initDefaultCellStyle( csText, csFont ); + initPOIStylesManager.initFont( csFont8Bold, "Tahoma", (short) 8, Font.BOLDWEIGHT_BOLD, IndexedColors.BLACK + .getIndex() ); + + initPOIStylesManager.initFont( csFont9Bold, "Tahoma", (short) 9, Font.BOLDWEIGHT_BOLD, IndexedColors.BLACK + .getIndex() ); + initPOIStylesManager.initFont( csFont10Bold, "Tahoma", (short) 10, Font.BOLDWEIGHT_BOLD, IndexedColors.BLACK .getIndex() ); initPOIStylesManager.initFont( csFont11Bold, "Tahoma", (short) 11, Font.BOLDWEIGHT_BOLD, @@ -321,6 +338,14 @@ this.CELLSTYLE_BORDER_COLOR, this.CELLSTYLE_BORDER, this.CELLSTYLE_BORDER_COLOR, this.CELLSTYLE_BORDER, this.CELLSTYLE_BORDER_COLOR, this.CELLSTYLE_BORDER, this.CELLSTYLE_BORDER_COLOR, this.CELLSTYLE_ALIGN_RIGHT, true ); + initPOIStylesManager.initCellStyle( csText8Bold, csFont8Bold, this.CELLSTYLE_BORDER, + this.CELLSTYLE_BORDER_COLOR, this.CELLSTYLE_BORDER, this.CELLSTYLE_BORDER_COLOR, this.CELLSTYLE_BORDER, + this.CELLSTYLE_BORDER_COLOR, this.CELLSTYLE_BORDER, this.CELLSTYLE_BORDER_COLOR, this.CELLSTYLE_ALIGN_LEFT, + true ); + initPOIStylesManager.initCellStyle( csText9Bold, csFont9Bold, this.CELLSTYLE_BORDER, + this.CELLSTYLE_BORDER_COLOR, this.CELLSTYLE_BORDER, this.CELLSTYLE_BORDER_COLOR, this.CELLSTYLE_BORDER, + this.CELLSTYLE_BORDER_COLOR, this.CELLSTYLE_BORDER, this.CELLSTYLE_BORDER_COLOR, this.CELLSTYLE_ALIGN_LEFT, + true ); initPOIStylesManager.initCellStyle( csText10Bold, csFont10Bold, this.CELLSTYLE_BORDER, this.CELLSTYLE_BORDER_COLOR, this.CELLSTYLE_BORDER, this.CELLSTYLE_BORDER_COLOR, this.CELLSTYLE_BORDER, this.CELLSTYLE_BORDER_COLOR, this.CELLSTYLE_BORDER, this.CELLSTYLE_BORDER_COLOR, this.CELLSTYLE_ALIGN_LEFT, === modified file 'local/vn/dhis-web-spreadsheet-reporting/src/main/java/org/hisp/dhis/reportsheet/exporting/action/GenerateReportVerticalCategoryAction.java' --- local/vn/dhis-web-spreadsheet-reporting/src/main/java/org/hisp/dhis/reportsheet/exporting/action/GenerateReportVerticalCategoryAction.java 2012-05-04 09:50:39 +0000 +++ local/vn/dhis-web-spreadsheet-reporting/src/main/java/org/hisp/dhis/reportsheet/exporting/action/GenerateReportVerticalCategoryAction.java 2012-05-09 05:19:35 +0000 @@ -109,7 +109,7 @@ if ( reportItem.getItemType().equalsIgnoreCase( ExportItem.TYPE.DATAELEMENT_NAME ) ) { ExcelUtils.writeValueByPOI( rowBegin, reportItem.getColumn(), group.getName(), ExcelUtils.TEXT, - sheet, this.csText12BoldCenter ); + sheet, this.csText10Bold ); } run++; @@ -123,7 +123,7 @@ if ( reportItem.getItemType().equalsIgnoreCase( ExportItem.TYPE.DATAELEMENT_NAME ) ) { ExcelUtils.writeValueByPOI( rowBegin, reportItem.getColumn(), categoryOption.getName(), - ExcelUtils.TEXT, sheet, this.csText10Bold ); + ExcelUtils.TEXT, sheet, this.csText8Bold ); } else if ( reportItem.getItemType().equalsIgnoreCase( ExportItem.TYPE.SERIAL ) ) { === modified file 'local/vn/dhis-web-spreadsheet-reporting/src/main/java/org/hisp/dhis/reportsheet/exportreport/action/GetExportReportAction.java' --- local/vn/dhis-web-spreadsheet-reporting/src/main/java/org/hisp/dhis/reportsheet/exportreport/action/GetExportReportAction.java 2012-04-16 03:00:30 +0000 +++ local/vn/dhis-web-spreadsheet-reporting/src/main/java/org/hisp/dhis/reportsheet/exportreport/action/GetExportReportAction.java 2012-05-09 05:19:35 +0000 @@ -27,6 +27,9 @@ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +import java.util.List; + +import org.hisp.dhis.reportsheet.ExportItem; import org.hisp.dhis.reportsheet.ExportReportService; import org.hisp.dhis.reportsheet.ExportReport; import org.hisp.dhis.reportsheet.action.ActionSupport; @@ -95,6 +98,11 @@ return ExportReport.class.getSimpleName(); } + public List getPeriodTypes() + { + return ExportItem.PERIODTYPE.getPeriodTypes(); + } + // ------------------------------------------------------------------------- // Execute method // ------------------------------------------------------------------------- === modified file 'local/vn/dhis-web-spreadsheet-reporting/src/main/resources/org/hisp/dhis/reportsheet/i18n_module.properties' --- local/vn/dhis-web-spreadsheet-reporting/src/main/resources/org/hisp/dhis/reportsheet/i18n_module.properties 2012-05-04 09:50:39 +0000 +++ local/vn/dhis-web-spreadsheet-reporting/src/main/resources/org/hisp/dhis/reportsheet/i18n_module.properties 2012-05-09 05:19:35 +0000 @@ -206,6 +206,7 @@ intro_clean_up = This feature allows users to delete the temporary files generated during the generating report or previewing report. intro_import_reports = Create, update, delete and view the elements for importing data from excel files. This import items closer to export items. intro_excel_template_management = Upload, rename, search, download and delete the file extension .xls or .xlsx. Users can identify which files are used and unused files to. Automatically, allowing to update excel reporting system when file names which are used to be changed. +intro_define_categoryoption_associations = Thus function allows users for assigning the categoy option to organisation unit. translation_translate = Translate template_using = File is using template_pending = File is pending === modified file 'local/vn/dhis-web-spreadsheet-reporting/src/main/resources/org/hisp/dhis/reportsheet/i18n_module_vi_VN.properties' --- local/vn/dhis-web-spreadsheet-reporting/src/main/resources/org/hisp/dhis/reportsheet/i18n_module_vi_VN.properties 2012-05-04 09:50:39 +0000 +++ local/vn/dhis-web-spreadsheet-reporting/src/main/resources/org/hisp/dhis/reportsheet/i18n_module_vi_VN.properties 2012-05-09 05:19:35 +0000 @@ -26,6 +26,7 @@ group=Nh\u00f3m move_selected=B\u1ecf v\u00e0o intro_clean_up=Ch\u1ee9c n\u0103ng n\u00e0y cho ph\u00e9p ng\u01b0\u1eddi d\u00f9ng x\u00f3a c\u00e1c t\u1eadp tin t\u1ea1m sinh ra trong qu\u00e1 tr\u00ecnh sinh b\u00e1o c\u00e1o ho\u1eb7c xem tr\u01b0\u1edbc b\u00e1o c\u00e1o. +intro_define_categoryoption_associations=Ch\u1ee9c n\u0103ng n\u00e0y cho ph\u00e9p ng\u01b0\u1eddi d\u00f9ng g\u00e1n Ph\u1ea7n t\u1eed ph\u00e2n lo\u1ea1i v\u00e0o \u0111\u01a1n v\u1ecb. not_null=kh\u00f4ng r\u1ed7ng upload_file=T\u1ea3i l\u00ean add_export_item=Th\u00eam ph\u1ea7n t\u1eed === modified file 'local/vn/dhis-web-spreadsheet-reporting/src/main/resources/struts.xml' --- local/vn/dhis-web-spreadsheet-reporting/src/main/resources/struts.xml 2012-05-08 08:07:28 +0000 +++ local/vn/dhis-web-spreadsheet-reporting/src/main/resources/struts.xml 2012-05-09 05:19:35 +0000 @@ -289,10 +289,11 @@ + class="org.hisp.dhis.reportsheet.action.NoAction"> /main.vm /dhis-web-spreadsheet-reporting/categoryOptionAssociations.vm /dhis-web-spreadsheet-reporting/menu.vm + javascript/category.ajax.js style/basic.css === modified file 'local/vn/dhis-web-spreadsheet-reporting/src/main/webapp/dhis-web-spreadsheet-reporting/categoryOptionAssociations.vm' --- local/vn/dhis-web-spreadsheet-reporting/src/main/webapp/dhis-web-spreadsheet-reporting/categoryOptionAssociations.vm 2012-05-04 09:50:39 +0000 +++ local/vn/dhis-web-spreadsheet-reporting/src/main/webapp/dhis-web-spreadsheet-reporting/categoryOptionAssociations.vm 2012-05-09 05:19:35 +0000 @@ -4,26 +4,30 @@ jQuery(document).ready( function() { validator = validation( "categoryOptionAssociationsForm", function( form ) { validateCategoryOptionAssociations( form ); }); + + categoryLib.loadCategories( "categoryId" ); } ); + var i18n_label = '$encoder.jsEscape($i18n.getString( 'select_category_option' ) , "'")'; var i18n_verify_category_option = '$encoder.jsEscape($i18n.getString( 'please_select_category_option' ) , "'")';

$i18n.getString( "define_categoryoption_associations" )

-

$encoder.htmlEncode( $!group.name )

-
+ + + + @@ -39,7 +43,7 @@
$i18n.getString( "categories" )
+ +
$i18n.getString( "category_options" )
- +
@@ -48,6 +52,12 @@