| 1 |
<?php |
| 2 |
|
| 3 |
namespace MakeCommerce\Shipping\Method\ParcelMachine; |
| 4 |
|
| 5 |
/** |
| 6 |
* DPD parcelmachine shippinh method. |
| 7 |
* Defines all DPD specific options. |
| 8 |
* |
| 9 |
* @since 3.0.0 |
| 10 |
*/ |
| 11 |
|
| 12 |
class DPD extends \MakeCommerce\Shipping\Method\ParcelMachine { |
| 13 |
|
| 14 |
use \MakeCommerce\Shipping\Method\Common\DPD; |
| 15 |
|
| 16 |
public $default_price = "5.00"; |
| 17 |
public $default_max_weight = "30"; |
| 18 |
|
| 19 |
/** |
| 20 |
* Loads all form fields specific to this shipping method |
| 21 |
* |
| 22 |
* @since 3.0.0 |
| 23 |
*/ |
| 24 |
public function initialize_method_form_fields() { |
| 25 |
|
| 26 |
//This is needed for our API. It changes behaviour depending on the country your contract has been signed in |
| 27 |
$this->form_fields['service_carrier'] = array( |
| 28 |
'type' => 'select', |
| 29 |
'title' => __( 'Integration country', 'wc_makecommerce_domain' ), |
| 30 |
'options' => array( |
| 31 |
"DPD" => __( 'Estonia', 'wc_makecommerce_domain' ), |
| 32 |
"DPD_LV" => __( 'Latvia', 'wc_makecommerce_domain' ), |
| 33 |
"DPD_LT" => __( 'Lithuania', 'wc_makecommerce_domain' ), |
| 34 |
), |
| 35 |
'default' => "ee", |
| 36 |
'description' => __( "Which country's carrier gave you the credentials", 'wc_makecommerce_domain' ), |
| 37 |
); |
| 38 |
} |
| 39 |
} |