Bugzilla – Attachment 26246 Details for
Bug 11578
Improvement of the funds list view
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 11578: Hide inactive budgets by default
Bug-11578-Hide-inactive-budgets-by-default.patch (text/plain), 4.31 KB, created by
Jonathan Druart
on 2014-03-13 10:29:45 UTC
(
hide
)
Description:
Bug 11578: Hide inactive budgets by default
Filename:
MIME Type:
Creator:
Jonathan Druart
Created:
2014-03-13 10:29:45 UTC
Size:
4.31 KB
patch
obsolete
>From 220b63c0fae40e9af0a9a80042b8ad964d9802cb Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@biblibre.com> >Date: Fri, 14 Feb 2014 10:38:35 +0100 >Subject: [PATCH] Bug 11578: Hide inactive budgets by default > >This patch hides inactive budgets by default. >They can be shown/hidden using 2 new links "Hide/Show inactive budgets". >--- > .../prog/en/modules/admin/aqbudgets.tt | 27 +++++++++++++++----- > 1 file changed, 21 insertions(+), 6 deletions(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/aqbudgets.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/aqbudgets.tt >index 1742a1f..40f4e93 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/aqbudgets.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/aqbudgets.tt >@@ -160,12 +160,12 @@ var MSG_PARENT_BENEATH_BUDGET = "- " + _("New budget-parent is beneath budget") > } > > var nTrs = $('#budgeth tbody tr'); >- var iColspan = nTrs[0].getElementsByTagName('td').length; >+ var iColspan = nTrs[1].getElementsByTagName('td').length; > var sLastGroup = ""; > for ( var i=0 ; i<nTrs.length ; i++ ) > { > var iDisplayIndex = oSettings._iDisplayStart + i; >- var sGroup = oSettings.aoData[ oSettings.aiDisplay[iDisplayIndex] ]._aData[0]; >+ var sGroup = oSettings.aoData[ oSettings.aiDisplay[iDisplayIndex] ]._aData[1]; > if ( sGroup != sLastGroup ) > { > var nGroup = document.createElement( 'tr' ); >@@ -180,10 +180,10 @@ var MSG_PARENT_BENEATH_BUDGET = "- " + _("New budget-parent is beneath budget") > } > }, > "aoColumnDefs": [ >- { "bVisible": false, "aTargets": [ 0 ] } >+ { "bVisible": false, "aTargets": [ 0, 1 ] } > ], >- "aaSortingFixed": [[ 0, 'asc' ]], >- "aaSorting": [[ 1, 'asc' ]], >+ "aaSortingFixed": [[ 1, 'asc' ]], >+ "aaSorting": [[ 2, 'asc' ]], > 'bSort': false, > 'bPaginate': false, > "bAutoWidth": false >@@ -202,9 +202,19 @@ var MSG_PARENT_BENEATH_BUDGET = "- " + _("New budget-parent is beneath budget") > $(oTable).treetable('collapseAll'); > }); > >+ $("#hide_inactive").click(function(e){ >+ e.preventDefault(); >+ oTable.fnFilter( 0, 0 ); // Hide active=0 >+ }); >+ $("#show_inactive").click(function(e){ >+ e.preventDefault(); >+ oTable.fnFilter( '', 0 ); >+ }); >+ > $("#filterbutton").click(function() { > $("#fundfilters").slideToggle(0); > }); >+ $("#hide_inactive").click(); > }); > //]]> > </script> >@@ -256,10 +266,13 @@ var MSG_PARENT_BENEATH_BUDGET = "- " + _("New budget-parent is beneath budget") > <table id="budgeth"> > <caption> > <span class="actions"><a href="#" id="expand_all">Expand all</a> >- | <a href="#" id="collapse_all">Collapse all</a></span> >+ | <a href="#" id="collapse_all">Collapse all</a> >+ | <a href="#" id="hide_inactive">Hide inactive budgets</a> >+ | <a href="#" id="show_inactive">Show inactive budgets</a></span> > </caption> > <thead> > <tr> >+ <th>Active</th> > <th>Budget period description</th> > <th>Fund code</th> > <th>Fund name</th> >@@ -274,6 +287,7 @@ var MSG_PARENT_BENEATH_BUDGET = "- " + _("New budget-parent is beneath budget") > <tfoot> > <tr> > <th></th> >+ <th></th> > <th colspan="2" style="text-align: left;" nowrap="nowrap">Period allocated [% IF ( budget_period_total ) %][% budget_period_total %][% END %] </th> > <th nowrap="nowrap" class="data"> [% period_alloc_total %]</th> > <th nowrap="nowrap" class="data"> [% base_alloc_total %]</th> >@@ -287,6 +301,7 @@ var MSG_PARENT_BENEATH_BUDGET = "- " + _("New budget-parent is beneath budget") > [% FOREACH budget IN budgets %] > > <tr data-tt-id="[% budget.budget_id %]" [% IF ( budget.budget_parent_id ) %]data-tt-parent-id="[% budget.budget_parent_id %]"[% END %]> >+ <td>[% budget.budget_period_active %]</td> > <td>Budget [% budget.budget_period_description %]</td> > <td>[% budget.budget_code_indent %]</td> > <td>[% budget.budget_name %]</td> >-- >1.7.10.4
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 11578
:
24505
|
24506
|
24507
|
24508
|
25175
|
25245
|
25246
|
26243
|
26244
|
26245
|
26246
|
26247
|
27404
|
27706
|
27707
|
27708
|
27709
|
27710
|
27736
|
27754
|
27755
|
27763
|
27764
|
27765
|
27766
|
27767
|
27768
|
27769
|
27813
|
27814
|
27815
|
27816