Bugzilla – Attachment 55682 Details for
Bug 14764
Add OPAC News branch selector
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 14764: OPAC news selector - Template tags
Bug-14764-OPAC-news-selector---Template-tags.patch (text/plain), 2.42 KB, created by
Liz Rea
on 2016-09-19 04:00:43 UTC
(
hide
)
Description:
Bug 14764: OPAC news selector - Template tags
Filename:
MIME Type:
Creator:
Liz Rea
Created:
2016-09-19 04:00:43 UTC
Size:
2.42 KB
patch
obsolete
>From b8daf3937306d630fdce5b47256af719a021241c Mon Sep 17 00:00:00 2001 >From: Martin Persson <xarragon@gmail.com> >Date: Thu, 15 Sep 2016 14:26:56 +1200 >Subject: [PATCH] Bug 14764: OPAC news selector - Template tags > >Test plan: > >1) Add more than one library, at least two in total is needed. Make note of which is your current user's home branch. >2) Go to Tools -> News and add one global ("All") news item and one specific for each branch. >3) Apply the patches. >4) Perform database upgrades when you log in. >5) Go to OPAC main, it should work as before: Showing global news as well as the news for your home branch once logged in. >6) Go to System Preferences -> OPAC and set 'OPACNewsBranchSelect' to yes. >7) Go to OPAC main, you should see the global news item plus any items for your home branch for the current user if logged in. >8) Above the news, you will see a dropdown that lists the branches. Select one, and click "Change library." >9) You should now see global news and the news for the selected branch, regardless of whether logged in or not. > >Sponsored-By: Halland County Library >--- > koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-main.tt | 12 ++++++++++++ > 1 file changed, 12 insertions(+) > >diff --git a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-main.tt b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-main.tt >index 2ec85cf..8c2b949 100644 >--- a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-main.tt >+++ b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-main.tt >@@ -39,6 +39,18 @@ > [% END %] > > [% IF ( koha_news_count ) %] >+ [% IF Koha.Preference( 'OpacNewsBranchSelect' ) == 1 %] >+ <form id="news-branch-select" class="form-inline" name="news-branch-select" method="get" action="/cgi-bin/koha/opac-main.pl"> >+ <select id="news-branch" name="branch"> >+ <option value="" selected="selected">See news for...</option> >+ [% FOREACH BranchesLoo IN Branches.all %] >+ <option value="[% BranchesLoo.branchcode %]">[% BranchesLoo.branchname %]</option> >+ [% END %] >+ </select> >+ <button id="news-branch-submit" class="btn btn-link" type="submit">Change library</button> >+ </form> >+ [% END %] >+ > <div id="news" class="newscontainer"> > [% SET newsdisp = ( Koha.Preference('NewsAuthorDisplay') ) %] > [% FOREACH koha_new IN koha_news %] >-- >1.9.1
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 14764
:
42129
|
42130
|
42131
|
42132
|
42139
|
42146
|
42147
|
55679
|
55680
|
55681
|
55682
|
55724
|
55725
|
55726
|
56107
|
56108
|
56109
|
57058
|
57059
|
57060
|
57061
|
57062
|
57063
|
57110
|
59648
|
59653
|
59827
|
60396
|
60424
|
60425
|
60451
|
60452