commit eb78cd58bd238511d07f7042ad0bcf49913cae92
parent 9bfb281cd792ceae5dbb0e38489b0c77f1d773b3
Author: Felicitus <felicitus@felicitus.org>
Date: Fri, 6 Nov 2015 19:05:51 +0100
Added exporter button to the project reports
Diffstat:
1 file changed, 12 insertions(+), 3 deletions(-)
diff --git a/src/PartKeepr/FrontendBundle/Resources/public/js/Components/Project/ProjectReport.js b/src/PartKeepr/FrontendBundle/Resources/public/js/Components/Project/ProjectReport.js
@@ -16,7 +16,6 @@ Ext.define('PartKeepr.ProjectReportView', {
initComponent: function ()
{
-
this.createStores();
this.upperGridEditing = Ext.create('Ext.grid.plugin.CellEditing', {
@@ -72,6 +71,7 @@ Ext.define('PartKeepr.ProjectReportView', {
header: i18n("Part Name"),
renderer: function (val, p, rec)
{
+ console.log(rec);
return rec.getPart().get("name");
},
flex: 1
@@ -144,7 +144,16 @@ Ext.define('PartKeepr.ProjectReportView', {
}
],
store: this.projectReportStore,
- plugins: [this.editing]
+ plugins: [this.editing],
+ bbar: [
+ Ext.create("PartKeepr.Exporter.GridExporterButton", {
+ itemId: 'export',
+ genericExporter: false,
+ tooltip: i18n("Export"),
+ iconCls: "fugue-icon application-export",
+ disabled: this.store.isLoading()
+ })
+ ]
});
this.createReportButton = Ext.create('Ext.button.Button', {
@@ -381,6 +390,6 @@ Ext.define('PartKeepr.ProjectReportView', {
iconCls: 'fugue-icon drill',
title: i18n('Project Reports'),
closable: true,
- menuPath: [{ text: i18n("View")}]
+ menuPath: [{text: i18n("View")}]
}
});