Spamworldpro Mini Shell
Spamworldpro


Server : Apache
System : Linux server2.corals.io 4.18.0-348.2.1.el8_5.x86_64 #1 SMP Mon Nov 15 09:17:08 EST 2021 x86_64
User : corals ( 1002)
PHP Version : 7.4.33
Disable Function : exec,passthru,shell_exec,system
Directory :  /home/corals/old/vendor/extmag/shiplab/view/adminhtml/web/js/order/create/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Current File : /home/corals/old/vendor/extmag/shiplab/view/adminhtml/web/js/order/create/scripts.js
/**
 * @api
 */

/* global AdminOrder */
define([
    'jquery',
    'Extmag_Shiplab/js/order/create/get-access-point',
    'prototype',
    'Magento_Sales/order/create/scripts'
], function ($, accessPoint) {
    'use strict';
    window.ExtmagAdminOrder = new Class.create();
    ExtmagAdminOrder.prototype = AdminOrder.prototype;

    ExtmagAdminOrder.prototype.submitAP = ExtmagAdminOrder.prototype.submit;

    ExtmagAdminOrder.prototype.submit = function () {
        let selectedShipMethod = $('[name="order[shipping_method]"]:checked').val();
        if (selectedShipMethod) {
            let parsedShipMethod = selectedShipMethod.split("_", 3);
            if (parsedShipMethod[0] == 'extmag') {
                let isAP = $('[name="order[shipping_method]"]:checked').attr('data-access_point');
                if (isAP == '1') {
                    accessPoint.startAction();
                    return false;
                }
            }
        }

        ExtmagAdminOrder.prototype.submitAP();
    };
});

Spamworldpro Mini