PluginProbe
Booking Calendar / 11.6
Booking Calendar v11.6
11.9 11.8.4 11.8.3 11.8.2 11.8.1 11.8 11.7 11.6.1 11.6 11.5 11.4.3 11.4.2 11.4.1 11.4 11.3 11.2.1 11.2 11.1 11.0 10.15.7 10.15.6 10.1.3 10.10 10.10.1 10.10.2 All 205 releases
booking / includes / page-appointment-services / templates / catalog / header-wptpl.php

header-wptpl.php in Booking Calendar 11.6, at includes/page-appointment-services/templates/catalog/header-wptpl.php

48 lines 2.3 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 /**
3 * Appointment Services table-header WP template.
4 *
5 * Renders only server-allow-listed columns and sort controls supplied by the
6 * Service catalog adapter.
7 *
8 * @package Booking Calendar
9 * @since 11.6.0
10 */
11 if ( ! defined( 'ABSPATH' ) ) { exit; }
12 ?>
13 <script type="text/html" id="tmpl-wpbc-appointment-services-header">
14 <tr>
15 <th scope="col" class="wpbc_ui_listing__selection_column column-selection"><input type="checkbox" data-wpbc-ui-catalog-select-all aria-label="{{ data.select_all_label }}"></th>
16 <# _.each( data.columns, function ( column ) { #>
17 <th
18 scope="col"
19 class="wpbc_ui_listing__column {{ column.class_name }}"
20 data-wpbc-ui-catalog-column="{{ column.id }}"
21 <# if ( 'status' === column.id ) { #>
22 aria-sort="<# if ( 'status' === data.sort_by || 'service_id' === data.sort_by ) { #>{{ 'desc' === data.sort_order ? 'descending' : 'ascending' }}<# } else { #>none<# } #>"
23 <# } else if ( column.sort_key ) { #>
24 aria-sort="{{ column.aria_sort }}"
25 <# } #>
26 >
27 <# if ( 'status' === column.id ) { #>
28 <div class="wpbc_appointment_services__status_header">
29 <a href="#" class="wpbc_ui_listing__sort_link<# if ( 'status' === data.sort_by ) { #> is-active<# } #>" data-wpbc-ui-catalog-sort="status">
30 <span>{{ column.label }}</span>
31 <i class="wpbc_ui_listing__sort_icon <# if ( 'status' === data.sort_by ) { #>wpbc-bi-arrow-{{ 'asc' === data.sort_order ? 'up' : 'down' }}<# } else { #>wpbc_icn_import_export<# } #>" aria-hidden="true"></i>
32 </a>
33 <a href="#" class="wpbc_ui_listing__sort_link<# if ( 'service_id' === data.sort_by ) { #> is-active<# } #>" data-wpbc-ui-catalog-sort="service_id">
34 <span>{{ data.id_label }}</span>
35 <i class="wpbc_ui_listing__sort_icon <# if ( 'service_id' === data.sort_by ) { #>wpbc-bi-arrow-{{ 'asc' === data.sort_order ? 'up' : 'down' }}<# } else { #>wpbc_icn_import_export<# } #>" aria-hidden="true"></i>
36 </a>
37 </div>
38 <# } else if ( column.sort_key ) { #>
39 <a href="#" class="wpbc_ui_listing__sort_link<# if ( column.is_sorted ) { #> is-active<# } #>" data-wpbc-ui-catalog-sort="{{ column.sort_key }}">
40 <span>{{ column.label }}</span>
41 <i class="wpbc_ui_listing__sort_icon {{ column.sort_icon }}" aria-hidden="true"></i>
42 </a>
43 <# } else { #>{{ column.label }}<# } #>
44 </th>
45 <# } ); #>
46 </tr>
47 </script>
48