magento 添加快递运送模块

有时magento会做国内的站,这时就需要添加国内的快递方式,就拿顺丰举例,仿照magento自带的Table Rate 首先把这4个文件放到对应路径下 文件下载 打开app\code\core\Mage\Shipping\etc\config.xml,找到并添加如下代码
<shipping_mysql4>
<class>Mage_Shipping_Model_Mysql4</class>
<entities>
<tablerate>
<table>shipping_tablerate</table>
</tablerate>
<sf><table>shipping_sf</table></sf>
</entities>
</shipping_mysql4>
  ......
<tablerate>
   ......
</tablerate>
<sf>
<active>0</active>
<sallowspecific>0</sallowspecific>
<condition_name>package_weight</condition_name>
<include_virtual_price>1</include_virtual_price>
<model>shipping/carrier_sf</model>
<name>SF Rate</name>
<title>Best Way</title>
<specificerrmsg>This shipping method is currently unavailable. If you would like to ship using this shipping method, please contact us.</specificerrmsg>
<handling_type>F</handling_type>
</sf>
继续打开app\code\core\Mage\Shipping\etc\system.xml
<tablerate translate="label">
                    <label>Table Rates</label>
                    ......
</tablerate>//复制这段代码,将其改成
<sf translate="label">
                    <label>顺丰快递</label>
                    ......
</sf>
最后,打开数据库,复制表shipping_tablerate改名为shipping_sf,可以试试效果了 这里有个运费表的设置问题,可参考 Magento table rates表运费设置和 Magento中国地区运费表设置 国际编码参考 http://zh.wikipedia.org/zh-cn/ISO_3166-1

你可能感兴趣的:(Magento,magento模块)