mozgbrasil/magento-product-page-shipping-php56

使用扩展,客户将能够在产品页面中查看发货方式。

1.0.3 2017-09-04 16:57 UTC

This package is auto-updated.

Last update: 2024-09-06 11:33:17 UTC


README

valid XHTML

Mozg\ProductPageShipping

摘要

在产品页面中显示发货方式。

动机

为了满足市场对 Magento 模块的需求,提供改进和优质的客户支持。

支持/疑问

要获得适当的支持,请点击此处,尽可能详细地说明问题原因,并附加屏幕截图以供理解。

价格

点击此处

技术特性

在产品查看页面的 "product.info.extrahint" 块中显示运费计算表单,其中返回相应的配送服务及其价值。

安装 - 更新 - 卸载 - 禁用

--

此模块旨在使用 Composer 安装。

在终端中运行以下命令,以查看 Composer 及其版本

composer --version

如果您环境中没有 Composer,建议阅读以下文章点击此处

--

服务器需要支持 ionCube PHP Loader 扩展。

为了查看您的服务器是否支持此扩展

请确保您的项目根目录中存在 phpinfo.php 文件

<?php phpinfo(); ?>

如果您的 Magento 项目根目录中不存在 phpinfo.php 文件,请创建该文件并添加上述内容

通过浏览器访问该文件

然后搜索 "ionCube PHP Loader" 术语

如果您的服务器不支持此扩展,请点击此处

在 "Loader Downloads API" 中,下载与您的服务器兼容的包

解压缩包并将 "loader-wizard.php" 文件上传到您的服务器,将展示激活扩展的逐步过程

点击此处查看执行过程

--

要使用 MOZG 模块,必须接受最终用户许可协议

--

建议您保持一个测试环境进行测试,并在测试通过后才在生产环境中应用相应的操作。

--

建议备份 Magento 平台和数据库。

--

在更新 Magento 之前,请始终确保禁用 Compiler 和 Cache。

--

请确保您的 Magento 项目根目录中存在 composer.json 文件,并且其参数类似于以下 JSON 模型

{
  "minimum-stability": "dev",
  "prefer-stable": true,
  "license": [
    "proprietary"
  ],
  "repositories": [
    {
      "type": "composer",
      "url": "https?://packages.firegento.com"
    }
  ],
  "extra": {
    "magento-root-dir": "./",
    "magento-deploystrategy": "copy",
    "magento-force": true
  }
}

如果您的 Magento 项目根目录中没有 composer.json 文件,请创建该文件并添加上述内容

要安装模块,请在您的服务器终端中项目的目录下运行以下命令

composer require mozgbrasil/magento-product-page-shipping-php56:dev-master

您可以通过进入后端来检查模块是否已安装

STORES -> Configuration -> ADVANCED/Advanced -> Disable Modules Output

--

要更新模块,请在服务器的终端中进入项目目录并执行以下命令

在执行涉及更新Magento的任何过程之前,建议关闭编译器和缓存

composer clear-cache && composer update

如果发生错误,请重命名 /vendor/mozgbrasil 文件夹并再次执行

要检查模块的日期,请执行以下命令

grep -ri --include=*.json 'time": "' ./vendor/mozgbrasil

--

卸载模块,请在服务器的终端中进入项目目录并执行以下命令

composer remove mozgbrasil/magento-product-page-shipping-php56 && composer clear-cache && composer update

--

要禁用模块

  1. 在执行涉及更新Magento的任何过程之前,需要保持编译器和缓存关闭

  2. 如果要禁用MOZG的模块,请重命名以下文件夹 app/code/local/Mozg

禁用模块可用于检测特定事件是否与模块相关

如何配置配送方式

要配置配送方式,请在后端访问

STORES -> Configuration -> MOZG -> Geral -> Visualização dos métodos de entrega na página do produto

您将看到以下字段

激活

用于“激活”或“禁用”该配送方式的使用

调试

激活调试以查看块名

块名称

插入块名称

常见问题解答 "FAQ"

功能已激活但未显示

更改资源的顺序

在配送方式配置中激活调试

将显示多个带名称的资源内部块

选择要插入资源的块名称

在配送方式配置中更改为新块名称

如何更改资源布局

您可以在产品页面的任何位置添加以下块,并根据需要自定义

<!-- MOZG -->
<script>
window.addEventListener("load", function(){ 
    $('block-shipping-form').remove();
});
</script>

<div class="block" style="width:300px">
    <div class="block-title">
        <strong><span><?php echo $this->__('Estimate Shipping') ?></span></strong>
    </div>
    <div class="block-content">
        <ul class="shipping-estimation-form" id="shipping-estimation-form">
           <li class="item odd" id="li-estimate-country">
              <label for="estimate_country">País</label>
              <div class="input-box">
                 <select name="estimate[country_id]" id="estimate_country" class="validate-select" title="País">
                    <option value=""> </option>
                    <option value="BR" selected="selected">Brasil</option>
                 </select>
              </div>
           </li>
           <li class="item even" id="li-estimate-region">
              <label for="estimate_region_id">Estado</label>
              <div class="input-box">
                 <input type="text" class="input-text" id="_estimate_region" name="estimate[region]" value="SP">
              </div>
           </li>
           <li class="item odd" id="li-estimate-city">
              <label for="city">Cidade</label>
              <div class="input-box">
                 <input class="input-text" id="estimate_city" name="estimate[city]" value="São Paulo" type="text">
              </div>
           </li>
           <li class="item last even" id="li-estimate-postcode">
              <label for="estimate_postcode">CEP</label>
              <div class="input-box">
                 <input class="input-text validate-postcode" id="estimate_postcode" name="estimate[postcode]" value="08250-580" type="text">
              </div>
           </li>
        </ul>
        <div class="actions">
            <div class="f-right">
                <button onclick="estimateProductShipping('new-shipping-estimate-results');" class="button " title="Ok" type="button"><span><span>Ok</span></span></button>
            </div>
        </div>
        <div id="new-shipping-estimate-results"></div>
    </div>
</div>
<!-- / MOZG -->

贡献者

Mozg 团队

许可证

商业许可证

徽章

Join the chat at https://gitter.im/mozgbrasil Latest Stable Version Total Downloads Latest Unstable Version License Monthly Downloads Daily Downloads Reference Status Dependency Status

🐈