Bugzilla – Attachment 102373 Details for
Bug 4461
Add a context-sensitive report a problem process
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 4461: Add problem reports link to mainpage and admin home
Bug-4461-Add-problem-reports-link-to-mainpage-and-.patch (text/plain), 5.89 KB, created by
Jonathan Druart
on 2020-04-03 13:11:15 UTC
(
hide
)
Description:
Bug 4461: Add problem reports link to mainpage and admin home
Filename:
MIME Type:
Creator:
Jonathan Druart
Created:
2020-04-03 13:11:15 UTC
Size:
5.89 KB
patch
obsolete
>From 12625852e6475f7ce8e9a959be85411c3a200f93 Mon Sep 17 00:00:00 2001 >From: Aleisha Amohia <aleishaamohia@hotmail.com> >Date: Tue, 10 Mar 2020 22:52:29 +0000 >Subject: [PATCH] Bug 4461: Add problem reports link to mainpage and admin home > >Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> > >Signed-off-by: David Nind <david@davidnind.com> > >Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >--- > koha-tmpl/intranet-tmpl/prog/en/includes/admin-menu.inc | 3 +++ > .../intranet-tmpl/prog/en/modules/admin/admin-home.tt | 4 ++++ > koha-tmpl/intranet-tmpl/prog/en/modules/intranet-main.tt | 9 ++++++++- > mainpage.pl | 3 +++ > 4 files changed, 18 insertions(+), 1 deletion(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/includes/admin-menu.inc b/koha-tmpl/intranet-tmpl/prog/en/includes/admin-menu.inc >index fd5d5953a6..c5bd432b9e 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/includes/admin-menu.inc >+++ b/koha-tmpl/intranet-tmpl/prog/en/includes/admin-menu.inc >@@ -151,6 +151,9 @@ > [% IF ( Koha.Preference('EnableAdvancedCatalogingEditor') && CAN_user_parameters_manage_keyboard_shortcuts ) %] > <li><a href="/cgi-bin/koha/admin/adveditorshortcuts.pl">Keyboard shortcuts</a></li> > [% END %] >+ [% IF ( Koha.Preference('OPACReportProblem') && CAN_user_problem_reports ) %] >+ <li><a href="/cgi-bin/koha/admin/problem-reports.pl">OPAC problem reports</a></li> >+ [% END %] > </ul> > [% END %] > </div> >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/admin-home.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/admin-home.tt >index dc162f47df..fded276005 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/admin-home.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/admin-home.tt >@@ -238,6 +238,10 @@ > <dt><a href="/cgi-bin/koha/admin/adveditorshortcuts.pl">Keyboard shortcuts</a></dt> > <dd>Define which keys trigger actions in the advanced cataloging editor</dd> > [% END %] >+ [% IF ( Koha.Preference('OPACReportProblem') && CAN_user_problem_reports ) %] >+ <dt><a href="/cgi-bin/koha/admin/problem-reports.pl">OPAC problem reports</a></dt> >+ <dd>Manage OPAC problem reports submitted by patrons</dd> >+ [% END %] > </dl> > [% END %] > </div> >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/intranet-main.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/intranet-main.tt >index f6a213523e..e094e74e59 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/intranet-main.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/intranet-main.tt >@@ -134,7 +134,7 @@ > <div class="row"> > <div class="col-sm-12"> > [%# Following statement must be in one line for translatability %] >- [% IF ( ( CAN_user_tools_moderate_comments && pendingcomments ) || ( CAN_user_tools_moderate_tags && pendingtags ) || ( CAN_user_borrowers_edit_borrowers && pending_borrower_modifications ) || ( CAN_user_acquisition && pendingsuggestions ) || ( CAN_user_borrowers_edit_borrowers && pending_discharge_requests ) || pending_article_requests) || ( Koha.Preference('AllowCheckoutNotes') && CAN_user_circulate_manage_checkout_notes && pending_checkout_notes.count ) %] >+ [% IF ( CAN_user_tools_moderate_comments && pendingcomments ) || ( CAN_user_tools_moderate_tags && pendingtags ) || ( CAN_user_borrowers_edit_borrowers && pending_borrower_modifications ) || ( CAN_user_acquisition && pendingsuggestions ) || ( CAN_user_borrowers_edit_borrowers && pending_discharge_requests ) || pending_article_requests || ( Koha.Preference('AllowCheckoutNotes') && CAN_user_circulate_manage_checkout_notes && pending_checkout_notes.count ) || ( Koha.Preference('OPACReportProblem') && CAN_user_problem_reports && pending_problem_reports ) %] > <div id="area-pending"> > [% IF pending_article_requests %] > <div class="pending-info" id="article_requests_pending"> >@@ -188,6 +188,13 @@ > </div> > [% END %] > >+ [% IF ( Koha.Preference('OPACReportProblem') && CAN_user_problem_reports && pending_problem_reports ) %] >+ <div class="pending-info" id="problem_reports_pending"> >+ <a href="/cgi-bin/koha/admin/problem-reports.pl">OPAC problem reports pending</a>: >+ <span class="pending-number-link">[% pending_problem_reports.count | html %]</span> >+ </div> >+ [% END %] >+ > </div> > > [% END %] >diff --git a/mainpage.pl b/mainpage.pl >index 49f46fc272..75072b1073 100755 >--- a/mainpage.pl >+++ b/mainpage.pl >@@ -31,6 +31,7 @@ use Koha::Patron::Modifications; > use Koha::Patron::Discharge; > use Koha::Reviews; > use Koha::ArticleRequests; >+use Koha::ProblemReports; > > my $query = new CGI; > >@@ -74,6 +75,7 @@ my $pending_article_requests = Koha::ArticleRequests->search_limited( > $branch ? ( 'me.branchcode' => $branch ) : (), > } > )->count; >+my $pending_problem_reports = Koha::ProblemReports->search({ status => 'N' }); > > $template->param( > pendingcomments => $pendingcomments, >@@ -82,6 +84,7 @@ $template->param( > pending_borrower_modifications => $pending_borrower_modifications, > pending_discharge_requests => $pending_discharge_requests, > pending_article_requests => $pending_article_requests, >+ pending_problem_reports => $pending_problem_reports > ); > > output_html_with_http_headers $query, $cookie, $template->output; >-- >2.20.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 4461
:
58887
|
59032
|
61654
|
65871
|
66253
|
66323
|
66324
|
98687
|
98688
|
98689
|
98725
|
99551
|
99599
|
99600
|
99601
|
99602
|
99603
|
99633
|
99635
|
99636
|
99637
|
99638
|
99639
|
99929
|
99930
|
99931
|
99932
|
99933
|
99934
|
99935
|
99936
|
99937
|
99938
|
99939
|
99940
|
99941
|
99942
|
100488
|
100489
|
100490
|
100491
|
100492
|
100493
|
100494
|
100495
|
100496
|
100497
|
100498
|
100499
|
100500
|
100506
|
100507
|
100508
|
100509
|
100510
|
100511
|
100512
|
100513
|
100514
|
100515
|
100516
|
100517
|
100518
|
100519
|
100520
|
100521
|
100522
|
100523
|
100524
|
100619
|
100989
|
100990
|
102188
|
102189
|
102190
|
102191
|
102192
|
102193
|
102194
|
102195
|
102196
|
102198
|
102200
|
102201
|
102202
|
102203
|
102204
|
102205
|
102206
|
102207
|
102208
|
102209
|
102210
|
102211
|
102253
|
102279
|
102281
|
102308
|
102309
|
102310
|
102311
|
102312
|
102313
|
102314
|
102315
|
102316
|
102317
|
102318
|
102319
|
102320
|
102321
|
102322
|
102323
|
102324
|
102325
|
102326
|
102327
|
102328
|
102329
|
102330
|
102331
|
102358
|
102359
|
102360
|
102361
|
102362
|
102363
|
102364
|
102365
|
102366
|
102367
|
102368
|
102369
|
102370
|
102371
|
102372
| 102373 |
102374
|
102375
|
102376
|
102377
|
102378
|
102379
|
102380
|
102381
|
102382
|
102383
|
102384
|
102385
|
102386