定制 advancedmediatechnology/laravel-shippy-pro-connector 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

advancedmediatechnology/laravel-shippy-pro-connector

Composer 安装命令:

composer require advancedmediatechnology/laravel-shippy-pro-connector

包简介

Shippypro Connector for Laravel

README 文档

README

Shippypro connector is a simple PHP library that allows to integrate Shippypro into your project. You can check carrier rates and ship orders.

Add folowing line to config/app.php to providers array

'providers' => [
    ...
    \advancedmediatechnology\ShippyProConnector\ShippyproServiceProvider::class
],

Then you have to publish configuration. Execute command

    php artisan vendor:publish

After that you have to configure your Shippypro API key in config/shippypro.php

    /* This example uses env file but you can paste in this place your API key */
    'api_key' => env('SHIPPYPRO_API', null),

This is an example integration

$sender = new ShippyproAddress('Jan Kowalski', '/', 'Prosta 20', '/', 'Wrocław', 'DS', '50-419', 'PL', '445544544', 'jankowalski@gmail.com');
$recivier = new ShippyproAddress('Jan Kowalski', '/', 'Prosta 20', '/', 'Wrocław', 'DS', '50-419', 'PL', '445544544', 'jankowalski@gmail.com');
$parcel = new ShippyproParcel('30', '20', '20', '10');
$shipment = new ShippyproShipment(30.00, 'Description');
$shipment->to_address($recivier);
$shipment->from_address($sender);
$shipment->addParcel($parcel);
$array = $shipment->getRates();
$rate = $array->searchByKey('carrier_id', 1081);
$shipment->setTransactionId(2349);
if ($rate) {
    $shipment->setRate($rate);
    $order = $shipment->purchase();
}

统计信息

  • 总下载量: 88
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 3
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 0
  • Forks: 1
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2021-09-27

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固