Bugzilla – Attachment 107788 Details for
Bug 26087
Add table configuration and export options to orders by fund report
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 26087: Add table configuration and export options to orders by fund report
Bug-26087-Add-table-configuration-and-export-optio.patch (text/plain), 4.42 KB, created by
ByWater Sandboxes
on 2020-08-04 15:44:55 UTC
(
hide
)
Description:
Bug 26087: Add table configuration and export options to orders by fund report
Filename:
MIME Type:
Creator:
ByWater Sandboxes
Created:
2020-08-04 15:44:55 UTC
Size:
4.42 KB
patch
obsolete
>From e8503f804ed7def65d78a8a5551d1a191aefad4e Mon Sep 17 00:00:00 2001 >From: Owen Leonard <oleonard@myacpl.org> >Date: Wed, 29 Jul 2020 13:49:16 +0000 >Subject: [PATCH] Bug 26087: Add table configuration and export options to > orders by fund report > >This patch adds column configuration to the orders by funds report >results table. The "Basket" column is excluded from being togglable. > >To test, apply the patch and clear your browser cache if necessary. > >- Go to Reports -> Orders by fund >- Submit parameters which will return multiple results. >- Test that the "Column visibility" button works to show and hide > columns. The "Basket" column should be excluded. >- Test the export options (Excel, CSV, etc) >- Go to Administration -> Columns settings and edit the default > configuration of the orders by fund report. Confirm that these changes > are reflected in the report results. > >Signed-off-by: Sally <sally.healey@cheshiresharedservices.gov.uk> >--- > admin/columns_settings.yml | 40 ++++++++++++++++++++++ > .../prog/en/modules/reports/orders_by_budget.tt | 21 +++++++----- > 2 files changed, 53 insertions(+), 8 deletions(-) > >diff --git a/admin/columns_settings.yml b/admin/columns_settings.yml >index 1a24b3084b..d847d40e22 100644 >--- a/admin/columns_settings.yml >+++ b/admin/columns_settings.yml >@@ -915,6 +915,46 @@ modules: > - > columnname: notes > >+ orders_by_fund: >+ funds-table: >+ default_display_length: 20 >+ default_sort_order: 0 >+ columns: >+ - >+ columnname: fund >+ - >+ columnname: basket >+ cannot_be_toggled: 1 >+ cannot_be_modified: 1 >+ - >+ columnname: basket_name >+ - >+ columnname: basket_by >+ - >+ columnname: title >+ - >+ columnname: currency >+ - >+ columnname: list_price >+ - >+ columnname: rrp >+ - >+ columnname: budgeted_cost >+ - >+ columnname: quantity >+ - >+ columnname: total_rrp >+ - >+ columnname: total_cost >+ - >+ columnname: entry_date >+ - >+ columnname: date_received >+ - >+ columnname: internal_note >+ - >+ columnname: vendor_note >+ > saved-sql: > table_reports: > columns: >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/reports/orders_by_budget.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/reports/orders_by_budget.tt >index 89a9d0c915..274bf4c99e 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/reports/orders_by_budget.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/reports/orders_by_budget.tt >@@ -1,6 +1,7 @@ > [% USE raw %] > [% USE Asset %] > [% USE Price %] >+[% USE TablesSettings %] > [% SET footerjs = 1 %] > [% INCLUDE 'doc-head-open.inc' %] > <title>Koha › Reports › Orders by fund</title> >@@ -23,13 +24,6 @@ > [% END %] > > [% IF ( get_orders ) %] >- <div class="results"> >- [% IF ( total ) %] >- Orders found: [% total | html %] >- [% ELSE %] >- No order found >- [% END %] >- </div> > > [% IF ( ordersloop ) %]<table id="funds"> > <thead> >@@ -150,9 +144,20 @@ > > [% MACRO jsinclude BLOCK %] > [% INCLUDE 'datatables.inc' %] >+ [% INCLUDE 'columns_settings.inc' %] > <script> >+ var columns_settings = [% TablesSettings.GetColumns( 'reports', 'orders_by_fund', 'funds-table', 'json' ) | $raw %]; >+ [% SET table_settings = TablesSettings.GetTableSettings( 'reports', 'orders_by_fund', 'funds-table' ) %]; > $(document).ready( function () { >- $('#funds').DataTable($.extend(true, {}, dataTablesDefaults,{"sPaginationType": "full_numbers"})); >+ var funds_table = KohaTable("funds", { >+ "columnDefs": [ >+ { "sortable": false, "searchable": false, 'targets': [ 'NoSort' ] }, >+ { "type": "title-string", "targets" : [ "title-string" ] } >+ ], >+ "pageLength": [% table_settings.default_display_length | html %], >+ "order": [[ [% table_settings.default_sort_order | html %], 'asc']], >+ 'autoWidth': false, >+ }, columns_settings ); > > showallbudgets = $('#budgetfilter').html(); > $('#budgetfilter .b_inactive').remove(); >-- >2.11.0
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 26087
:
107514
|
107788
|
107964