[1240] | 1 | <?xml version="1.0" encoding="utf-8"?>
|
---|
| 2 | <mx:VBox xmlns:mx="http://www.adobe.com/2006/mxml" xmlns:reports="gov.va.med.edp.view.reports.*" width="100%"
|
---|
| 3 | height="100%" creationComplete="{ReportUtil.setExportButtonState(exportButton)}" xmlns:widget="gov.va.med.edp.widget.*">
|
---|
| 4 |
|
---|
| 5 | <mx:Script>
|
---|
| 6 | <![CDATA[
|
---|
| 7 | import gov.va.med.edp.control.reports.ReportDownloadEvent;
|
---|
| 8 | import gov.va.med.edp.util.ReportUtil;
|
---|
| 9 | import mx.core.Application;
|
---|
| 10 | import gov.va.med.edp.view.reports.print.ReportDataGridPrintView;
|
---|
| 11 | import mx.printing.FlexPrintJob;
|
---|
| 12 | import gov.va.med.edp.model.TrackingModelLocator;
|
---|
| 13 | import gov.va.med.edp.util.ChangeWatcher;
|
---|
| 14 | import gov.va.med.edp.util.AccessibilityTools;
|
---|
| 15 |
|
---|
| 16 | [Bindable]
|
---|
| 17 | private var model: TrackingModelLocator = TrackingModelLocator.getInstance();
|
---|
| 18 |
|
---|
| 19 | private function doPrint():void {
|
---|
| 20 |
|
---|
| 21 | var printJob:FlexPrintJob = new FlexPrintJob();
|
---|
| 22 | if (printJob.start() != true) return;
|
---|
| 23 | ReportUtil.printDataGrid(printJob,dgAcuityReportStats.columns, dgAcuityReportStats.dataProvider, lblReportTitle.text);
|
---|
| 24 | printJob.send();
|
---|
| 25 | }
|
---|
| 26 |
|
---|
| 27 | ]]>
|
---|
| 28 | </mx:Script>
|
---|
| 29 | <mx:HBox width="100%">
|
---|
| 30 | <mx:Label
|
---|
| 31 | id="lblReportTitle"
|
---|
| 32 | text="{ReportUtil.buildReportLabelText('Acuity Report')}"
|
---|
| 33 | paddingTop="0"
|
---|
| 34 | paddingBottom="0"
|
---|
| 35 | width="100%"
|
---|
| 36 | styleName="viewTitle"
|
---|
| 37 | textAlign="center" />
|
---|
| 38 | <mx:HBox id="exportButton">
|
---|
| 39 | <widget:LinkButton label="Export" click="{ReportUtil.exportReport(ReportDownloadEvent.EVENT_ACUITY_REPORT);}" tabIndex="1900"/>
|
---|
| 40 | <mx:Label text="|" paddingLeft="0" paddingRight="0" textAlign="center"/>
|
---|
| 41 | </mx:HBox>
|
---|
| 42 | <widget:LinkButton label="Print" click="{doPrint()}" tabIndex="1901"/>
|
---|
| 43 | </mx:HBox>
|
---|
| 44 |
|
---|
| 45 | <mx:DataGrid id="dgAcuityReportStats"
|
---|
| 46 | dataProvider="{model.reports.acuityReport.acuityStats}"
|
---|
| 47 | initialize="{AccessibilityTools.accessComponentName(dgAcuityReportStats,ReportUtil.accessibleReportLabelText('Acuity Report'))}"
|
---|
| 48 | width="100%"
|
---|
| 49 | height="100%"
|
---|
| 50 | tabIndex="1100">
|
---|
| 51 | <mx:columns>
|
---|
| 52 | <mx:DataGridColumn dataField="type" headerText="Acuity->" width="160"/>
|
---|
| 53 | <mx:DataGridColumn dataField="none" headerText="None" sortable="false"/>
|
---|
| 54 | <mx:DataGridColumn dataField="one" headerText="1" sortable="false"/>
|
---|
| 55 | <mx:DataGridColumn dataField="two" headerText="2" sortable="false"/>
|
---|
| 56 | <mx:DataGridColumn dataField="three" headerText="3" sortable="false"/>
|
---|
| 57 | <mx:DataGridColumn dataField="four" headerText="4" sortable="false"/>
|
---|
| 58 | <mx:DataGridColumn dataField="five" headerText="5" sortable="false"/>
|
---|
| 59 | <mx:DataGridColumn dataField="avgTotal" headerText="Total/Average" width="120" sortable="false"/>
|
---|
| 60 | </mx:columns>
|
---|
| 61 | </mx:DataGrid>
|
---|
| 62 |
|
---|
| 63 | </mx:VBox>
|
---|