Plugin Directory

Changeset 3150114


Ignore:
Timestamp:
09/11/2024 01:28:35 PM (19 months ago)
Author:
eshoplogistic
Message:

Оптимизация формы выгрузки заказов

Location:
eshoplogisticru/trunk
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • eshoplogisticru/trunk/Classes/Shipping/ExportFileds.php

    r3137454 r3150114  
    121121    }
    122122
    123     public function exportFields( $name, $shippingMethods = array() ) {
     123    public function exportFields( $name, $shippingMethods = array(), $order = array() ) {
    124124        $result = array();
    125125        if ( $name === 'boxberry' ) {
     
    266266            }
    267267
     268            $index = '';
     269            if($order){
     270                $orderData = $order->get_data();
     271                $index = $orderData['billing']['postcode']??'';
     272            }
     273
    268274            $result = array(
    269275                'delivery' => array(
     
    271277                ),
    272278                'delivery[location_to][address]' => array(
    273                     'index||text||Индекс адреса доставки' => ''
     279                    'index||text||Индекс адреса доставки' => $index
    274280                )
    275281            );
  • eshoplogisticru/trunk/Modules/Unloading.php

    r3137454 r3150114  
    285285
    286286                $methodDelivery = new ExportFileds();
    287                 $fieldDelivery  = $methodDelivery->exportFields( mb_strtolower( $typeMethod['name'] ), $this->shippingMethods );
     287                $fieldDelivery  = $methodDelivery->exportFields( mb_strtolower( $typeMethod['name'] ), $this->shippingMethods, $order );
    288288
    289289                $eshopLogisticApi = new EshopLogisticApi( new WpHttpClient() );
  • eshoplogisticru/trunk/readme.txt

    r3150055 r3150114  
    44Requires at least: 5.3
    55Tested up to: 5.8
    6 Stable tag: 2.1.25
     6Stable tag: 2.1.26
    77License: GPLv2
    88License URI: http://www.gnu.org/licenses/gpl-2.0.html
  • eshoplogisticru/trunk/wc-eshop-logistic.php

    r3150055 r3150114  
    66 *
    77 * @link              https://wp.eshoplogistic.ru/
    8  * @since             2.1.25
     8 * @since             2.1.26
    99 * @package           WC_Eshop_Logistic
    1010 *
     
    1313 * Plugin URI:        https://wp.eshoplogistic.ru/
    1414 * Description:       Несколько служб доставки в одной интеграции: CDEK, DPD, Boxberry, IML, Почта России, Деловые Линии, ПЭК, Dostavista, GTD, Байкал Сервис и др.
    15  * Version:           2.1.25
     15 * Version:           2.1.26
    1616 * Author:            eShopLogistic
    1717 * Author URI:        https://eshoplogistic.ru/p747575
     
    4141define( 'WC_ESL_PLUGIN_DIR', plugin_dir_path(__FILE__) );
    4242
    43 define( 'WC_ESL_VERSION', '2.1.25' );
     43define( 'WC_ESL_VERSION', '2.1.26' );
    4444
    4545define( 'WC_ESL_DOMAIN', 'wc-esl' );
Note: See TracChangeset for help on using the changeset viewer.