Bug 32600: Housebound module needs page-section treatment
This patch adds a .page-section container to two areas in the patron
homebound template.
This patch contains indentation changes, so please ignore whitespace
when looking at the diff.
To test, apply the patch and make sure the HouseboundModule system
preference is enabled.
- Locate a patron and edit their record.
- In the "Housebound roles" section, check both "Chooser" and
"Deliverer."
- Locate another patron and click on the "Housebound" menu item in the
left-hand sidebar.
- On the "Manage housebound profile" page, set a delivery day and
frequency and save changes.
- On the "Housebound details for..." page the details section at the top
should be correctly styled.
- Click "Add a new delivery."
- Fill out some delivery details and click "Save."
- Now the "Housebound details for..." page should show a "Deliveries"
section which is correctly styled.
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 5a0dbb3cd7)
Signed-off-by: Jacob O'Mara <jacob.omara@ptfs-europe.com>
This commit is contained in:
parent
8f8bd259ed
commit
ed78699381
|
|
@ -369,51 +369,56 @@
|
|||
</a>
|
||||
</fieldset>
|
||||
</form>
|
||||
<h3>Housebound details</h3>
|
||||
[% PROCESS 'homebound-details' %]
|
||||
<!-- Display a housebound_profile -->
|
||||
<div class="page-section">
|
||||
<h3>Housebound details</h3>
|
||||
[% PROCESS 'homebound-details' %]
|
||||
<!-- Display a housebound_profile -->
|
||||
</div> <!-- /.page-section -->
|
||||
[% ELSIF ( housebound_profile ) %]
|
||||
[% PROCESS 'homebound-details' %]
|
||||
<div class="action">
|
||||
<a class="btn btn-default btn-xs" href="/cgi-bin/koha/members/housebound.pl?borrowernumber=[% patron.borrowernumber | html %]&method=update_or_create"><i class="fa fa-pencil"></i> Edit</a>
|
||||
</div>
|
||||
<div>
|
||||
<h3>Deliveries</h3>
|
||||
[% housebound_visits = housebound_profile.housebound_visits %]
|
||||
[% IF housebound_visits.count > 0 %]
|
||||
<table border="0" width="100%" cellpadding="3" cellspacing="0">
|
||||
<tr>
|
||||
<th>ID</th><th>Date</th><th>Chooser</th><th>Deliverer</th><th class="noExport">Actions</th>
|
||||
</tr>
|
||||
[% FOREACH entry IN housebound_visits %]
|
||||
<tr>
|
||||
<td>[% entry.id | html %]</td>
|
||||
<td>[% entry.appointment_date | $KohaDates %] ([% entry.day_segment | html %])</td>
|
||||
<td>
|
||||
<a href="/cgi-bin/koha/members/moremember.pl?borrowernumber=[% entry.chooser.borrowernumber | uri %]">
|
||||
[% INCLUDE 'patron-title.inc' patron = entry.chooser invert_name = 0 %]
|
||||
</a>
|
||||
</td>
|
||||
<td>
|
||||
<a href="/cgi-bin/koha/members/moremember.pl?borrowernumber=[% entry.deliverer.borrowernumber | uri %]">
|
||||
[% INCLUDE 'patron-title.inc' patron = entry.deliverer invert_name = 0 %]
|
||||
</a>
|
||||
</td>
|
||||
<td class="actions">
|
||||
<a class="btn btn-default btn-xs" href="/cgi-bin/koha/members/housebound.pl?method=visit_update_or_create&visit_id=[% entry.id | html %]&borrowernumber=[% patron.borrowernumber | html %]"><i class="fa fa-pencil"></i> Edit</a>
|
||||
<a class="delete btn btn-default btn-xs" href="/cgi-bin/koha/members/housebound.pl?method=visit_delete&visit_id=[% entry.id | html %]&borrowernumber=[% patron.borrowernumber | html %]"><i class="fa fa-trash"></i> Delete</a>
|
||||
</td>
|
||||
</tr>
|
||||
<div class="page-section">
|
||||
[% PROCESS 'homebound-details' %]
|
||||
<div class="action">
|
||||
<a class="btn btn-default btn-xs" href="/cgi-bin/koha/members/housebound.pl?borrowernumber=[% patron.borrowernumber | html %]&method=update_or_create"><i class="fa fa-pencil"></i> Edit</a>
|
||||
</div>
|
||||
</div> <!-- /.page-section -->
|
||||
|
||||
<div class="page-section">
|
||||
<h3>Deliveries</h3>
|
||||
[% housebound_visits = housebound_profile.housebound_visits %]
|
||||
[% IF housebound_visits.count > 0 %]
|
||||
<table border="0" width="100%" cellpadding="3" cellspacing="0">
|
||||
<tr>
|
||||
<th>ID</th><th>Date</th><th>Chooser</th><th>Deliverer</th><th class="noExport">Actions</th>
|
||||
</tr>
|
||||
[% FOREACH entry IN housebound_visits %]
|
||||
<tr>
|
||||
<td>[% entry.id | html %]</td>
|
||||
<td>[% entry.appointment_date | $KohaDates %] ([% entry.day_segment | html %])</td>
|
||||
<td>
|
||||
<a href="/cgi-bin/koha/members/moremember.pl?borrowernumber=[% entry.chooser.borrowernumber | uri %]">
|
||||
[% INCLUDE 'patron-title.inc' patron = entry.chooser invert_name = 0 %]
|
||||
</a>
|
||||
</td>
|
||||
<td>
|
||||
<a href="/cgi-bin/koha/members/moremember.pl?borrowernumber=[% entry.deliverer.borrowernumber | uri %]">
|
||||
[% INCLUDE 'patron-title.inc' patron = entry.deliverer invert_name = 0 %]
|
||||
</a>
|
||||
</td>
|
||||
<td class="actions">
|
||||
<a class="btn btn-default btn-xs" href="/cgi-bin/koha/members/housebound.pl?method=visit_update_or_create&visit_id=[% entry.id | html %]&borrowernumber=[% patron.borrowernumber | html %]"><i class="fa fa-pencil"></i> Edit</a>
|
||||
<a class="delete btn btn-default btn-xs" href="/cgi-bin/koha/members/housebound.pl?method=visit_delete&visit_id=[% entry.id | html %]&borrowernumber=[% patron.borrowernumber | html %]"><i class="fa fa-trash"></i> Delete</a>
|
||||
</td>
|
||||
</tr>
|
||||
[% END %]
|
||||
</table>
|
||||
[% END %]
|
||||
</table>
|
||||
[% END %]
|
||||
<div class="action">
|
||||
<a href="/cgi-bin/koha/members/housebound.pl?method=visit_update_or_create&borrowernumber=[% patron.borrowernumber | uri %]"
|
||||
class="btn btn-default btn-sm">
|
||||
<i class="fa fa-plus"></i> Add a new delivery
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
<div class="action">
|
||||
<a href="/cgi-bin/koha/members/housebound.pl?method=visit_update_or_create&borrowernumber=[% patron.borrowernumber | uri %]"
|
||||
class="btn btn-default btn-sm">
|
||||
<i class="fa fa-plus"></i> Add a new delivery
|
||||
</a>
|
||||
</div>
|
||||
</div> <!-- /.page-section -->
|
||||
|
||||
[% END %]
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue