PluginProbe
Tiered Pricing Table for WooCommerce / 6.1.0
Tiered Pricing Table for WooCommerce v6.1.0
8.0.2 7.1.7 7.1.5 7.1.4 7.1.1 6.5.0 6.4.0 6.1.0 trunk 1.0 1.1 2.0 2.0.1 2.0.2 2.1 2.1.1 2.1.2 2.2.0 2.2.1 2.2.2 2.2.3 2.3.0 2.3.1 2.3.2 2.3.3 All 91 releases
tier-pricing-table / views / addons / role-based-pricing / simple / role.php

role.php in Tiered Pricing Table for WooCommerce 6.1.0, at views/addons/role-based-pricing/simple/role.php

52 lines 1.6 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php use TierPricingTable\Core\FileManager;
2
3 defined( 'ABSPATH' ) || die;
4
5 /**
6 * Available variables
7 *
8 * @var int $minimum_amount
9 * @var float $regular_price
10 * @var float $sale_price
11 * @var string $role
12 * @var string $type
13 * @var array $price_rules_fixed
14 * @var array $price_rules_percentage
15 * @var FileManager $fileManager
16 *
17 */
18
19 global $wp_roles;
20
21 $roleName = isset( $wp_roles->role_names[ $role ] ) ? translate_user_role( $wp_roles->role_names[ $role ] ) : $role;
22 ?>
23
24 <div class="tpt-role-based-role tpt-role-based-role--<?php echo esc_attr($role); ?>"
25 data-role-slug="<?php echo esc_attr($role); ?>" data-role-name="<?php echo esc_attr($roleName); ?>">
26 <div class="tpt-role-based-role__header">
27 <div class="tpt-role-based-role__name">
28 <b><?php echo esc_attr($roleName); ?></b>
29 </div>
30 <div class="tpt-role-based-role__actions">
31 <span class="tpt-role-based-role__action-toggle-view tpt-role-based-role__action-toggle-view--open"></span>
32 <a href="#" class="tpt-role-based-role-action--delete"><?php esc_attr_e( 'Remove', 'woocommerce' ); ?></a>
33 </div>
34 </div>
35 <div class="tpt-role-based-role__content">
36 <?php
37
38 $fileManager->includeTemplate( 'addons/role-based-pricing/simple/add-price-rules.php', array(
39 'minimum_amount' => $minimum_amount,
40 'price_rules_fixed' => $price_rules_fixed,
41 'price_rules_percentage' => $price_rules_percentage,
42 'regular_price' => $regular_price,
43 'sale_price' => $sale_price,
44 'type' => $type,
45 'isFree' => false,
46 'role' => $role
47 ) );
48
49 ?>
50 </div>
51 </div>
52