Bug 36157

Summary: Links in the "Run with template" dropdown at guided_reports.pl have odd formatting
Product: Koha Reporter: Jason Robb <jrobb>
Component: TemplatesAssignee: Pedro Amorim <pedro.amorim>
Status: CLOSED FIXED QA Contact: Martin Renvoize (ashimema) <martin.renvoize>
Severity: trivial    
Priority: P5 - low CC: caroline.cyr-la-rose, david, fridolin.somers, kyle, lucas, martin.renvoize, pedro.amorim
Version: Main   
Hardware: All   
OS: All   
Change sponsored?: --- Patch complexity: String patch
Documentation contact: Documentation submission:
Text to go in the release notes:
Version(s) released in:
24.05.00,23.11.04
Circulation function:
Bug Depends on: 36156, 36158    
Bug Blocks:    
Attachments: Dropdown formatting differences
Bug 36157: Remove class from anchor link
Bug 36157: Remove class from anchor link
Bug 36157: Remove class from anchor link
Bug 36157: Remove class from anchor link

Description Jason Robb 2024-02-23 15:04:06 UTC
Created attachment 162385 [details]
Dropdown formatting differences

When using the feature added by bug 34136, the new "Run with template" dropdown  has btn classes on the links in the dropdown list which gives it odd formatting compared to the rest of the dropdowns in the toolbar. I attached a screenshot to hopefully better illustrate.

To replicate:
- Create a notice with the module of "Reports" -- add something to the "Print" section. Example from the other bug:

[% FOREACH b IN data %]
<div class="panel panel-default">
  <div class="panel-heading">[% b.surname %], [% b.firstname %]</div>
  <div class="panel-body">Expiration: [% b.dateexpiry %]</div>
  <div class="panel-footer">ID: [% b.borrowernumber %]</div>
</div>
[% END %]

- Create and run a saved report. Example from the other bug:

SELECT * FROM borrowers

- Click on the "Run with template" dropdown and hover the template title.
Comment 1 Pedro Amorim 2024-02-23 16:23:22 UTC
Created attachment 162391 [details] [review]
Bug 36157: Remove class from anchor link
Comment 2 David Nind 2024-02-23 18:58:35 UTC
Getting sha1 error when trying to apply the patch:

Apply? [(y)es, (n)o, (i)nteractive] y
Applying: Bug 36157: Remove class from anchor link
error: sha1 information is lacking or useless (koha-tmpl/intranet-tmpl/prog/en/includes/reports-toolbar.inc).
error: could not build fake ancestor
Patch failed at 0001 Bug 36157: Remove class from anchor link
hint: Use 'git am --show-current-patch=diff' to see the failed patch

Also, shouldn't the commit message be formatted according to the guidelines? (https://wiki.koha-community.org/wiki/Commit_messages)
Comment 3 Pedro Amorim 2024-02-26 09:11:17 UTC
Created attachment 162422 [details] [review]
Bug 36157: Remove class from anchor link

Test plan:
- Create a notice with the module of "Reports" -- add something to the "Print" section. Example from bug 34136:
[% FOREACH b IN data %]
<div class="panel panel-default">
  <div class="panel-heading">[% b.surname %], [% b.firstname %]</div>
  <div class="panel-body">Expiration: [% b.dateexpiry %]</div>
  <div class="panel-footer">ID: [% b.borrowernumber %]</div>
</div>
[% END %]

- Create and run a saved report. Example from the other bug:
SELECT * FROM borrowers

- Click on the "Run with template" dropdown and hover the template title.

- Notice it the styling of the hover. Apply patch. Repeat.
Comment 4 Kyle M Hall (khall) 2024-02-26 11:48:12 UTC
Created attachment 162429 [details] [review]
Bug 36157: Remove class from anchor link

Test plan:
- Create a notice with the module of "Reports" -- add something to the "Print" section. Example from bug 34136:
[% FOREACH b IN data %]
<div class="panel panel-default">
  <div class="panel-heading">[% b.surname %], [% b.firstname %]</div>
  <div class="panel-body">Expiration: [% b.dateexpiry %]</div>
  <div class="panel-footer">ID: [% b.borrowernumber %]</div>
</div>
[% END %]

- Create and run a saved report. Example from the other bug:
SELECT * FROM borrowers

- Click on the "Run with template" dropdown and hover the template title.

- Notice it the styling of the hover. Apply patch. Repeat.

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Comment 5 Martin Renvoize (ashimema) 2024-02-29 10:26:50 UTC
Created attachment 162582 [details] [review]
Bug 36157: Remove class from anchor link

Test plan:
- Create a notice with the module of "Reports" -- add something to the "Print" section. Example from bug 34136:
[% FOREACH b IN data %]
<div class="panel panel-default">
  <div class="panel-heading">[% b.surname %], [% b.firstname %]</div>
  <div class="panel-body">Expiration: [% b.dateexpiry %]</div>
  <div class="panel-footer">ID: [% b.borrowernumber %]</div>
</div>
[% END %]

- Create and run a saved report. Example from the other bug:
SELECT * FROM borrowers

- Click on the "Run with template" dropdown and hover the template title.

- Notice it the styling of the hover. Apply patch. Repeat.

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Comment 6 Katrin Fischer 2024-03-07 14:04:45 UTC
Pushed for 24.05!

Well done everyone, thank you!
Comment 7 Fridolin Somers 2024-03-11 09:23:59 UTC
Pushed to 23.11.x for 23.11.04
Comment 8 Lucas Gass (lukeg) 2024-03-19 15:08:51 UTC
Missing 23.05.x dependencies, no backport.