mozgbrasil / magento-product-page-shipping-php55
使用此扩展,客户将在产品页面上看到配送方式。
Requires
This package is auto-updated.
Last update: 2024-09-06 10:40:29 UTC
README
Mozg\ProductPageShipping
简介
在产品页面上显示配送方式。
动机
满足市场对Magento模块的需求,提供改进和良好的支持
支持/疑问
要获取支持,请点击此处,尽可能详细地报告发生的原因,并附上屏幕截图以供理解
价格
技术特性
在产品查看页面中特定于标识符为"product.info.extrahint"的块中显示货运计算表单,其中返回带有各自价值的配送服务。
安装 - 更新 - 卸载 - 禁用
--
此模块旨在通过Composer安装
在终端中执行以下命令,以查看Composer及其版本
composer --version
如果您的环境中没有Composer,建议阅读以下文章点击此处
--
服务器需要支持ionCube PHP Loader扩展
要查看该扩展是否已在您的服务器上激活
请确保您的项目根目录存在phpinfo.php文件
<?php phpinfo(); ?>
如果您的项目根目录中没有phpinfo.php文件,请创建该文件并添加上述内容
通过浏览器访问该文件
然后搜索"ionCube PHP Loader"术语
如果您的服务器不支持此扩展,请点击此处
在"Loader Downloads API"中,下载与您的服务器兼容的包
解压缩包并将"loader-wizard.php"文件上传到您的服务器,将展示激活扩展的步骤
点击此处查看执行过程
--
要使用MOZG模块,必须接受最终用户许可协议
--
建议您保留一个测试环境以进行测试,并且在生产环境中仅经过适当测试后应用适当的程序
--
建议备份您的Magento平台和数据库
--
在执行任何Magento更新之前,始终确保Compiler和Cache已禁用
--
请确保您的项目根目录存在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
}
}
如果您的项目根目录中没有composer.json文件,请创建该文件并添加上述内容
要安装模块,请在您的服务器终端的项目目录中执行以下命令
composer require mozgbrasil/magento-product-page-shipping-php55:dev-master
您可以通过进入后端并查看来检查模块是否已安装
STORES -> Configuration -> ADVANCED/Advanced -> Disable Modules Output
--
要更新模块,请在服务器的终端中,在项目目录下执行以下命令:
在进行任何涉及 Magento 更新的过程之前,建议关闭 Compiler 和 Cache。
composer clear-cache && composer update
发生错误时,请将 /vendor/mozgbrasil 文件夹重命名,然后重新执行。
要检查模块的日期,请执行以下命令:
grep -ri --include=*.json 'time": "' ./vendor/mozgbrasil
--
要卸载模块,请在服务器的终端中,在项目目录下执行以下命令:
composer remove mozgbrasil/magento-product-page-shipping-php55 && composer clear-cache && composer update
--
要禁用模块:
-
在进行任何涉及 Magento 更新的过程之前,必须保持 Compiler 和 Cache 禁用。
-
如果您想禁用 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 团队
许可
徽章
🐈