1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
|
<?php
namespace AutomateWoo;
if ( ! defined( 'ABSPATH' ) ) { exit; }
/** * Variable_Order_Shipping_Postcode class. * * @since 4.4.2 * * @class Variable_Order_Shipping_Postcode */ class Variable_Order_Shipping_Postcode extends Variable {
/** * Load description for variable in admin screen. */ public function load_admin_details() { $this->description = __( 'Displays the shipping postcode for the order.', 'automatewoo' ); }
/** * Method: get_value() - get and return the shipping postcode. * * @param \WC_Order $order * * @return string */ public function get_value( $order ) { return $order->get_shipping_postcode(); } }
|