Browse Source

打印添加配送方式

master
Lemon 5 years ago
parent
commit
04a8fbd9f9
  1. 10
      app/Constants/v3/Shipping.php
  2. 4
      app/Service/v3/Implementations/FeiePrintService.php
  3. 2
      app/Service/v3/Interfaces/FeiePrintServiceInterface.php

10
app/Constants/v3/Shipping.php

@ -14,4 +14,14 @@ class Shipping extends AbstractConstants
* @Message("服务站配送")
*/
const TYPE_LANZU = 1;
/**
* @Message("达达配送")
*/
const TYPE_DADA = 2;
/**
* @Message("用户自提")
*/
const SELF_TAKING = 3;
}

4
app/Service/v3/Implementations/FeiePrintService.php

@ -2,6 +2,7 @@
namespace App\Service\v3\Implementations;
use App\Constants\v3\Shipping;
use App\Libs\FeiePrintClient;
use App\Model\v3\Feprint;
use App\Model\v3\OrderMain;
@ -168,7 +169,10 @@ class FeiePrintService implements FeiePrintServiceInterface
$orderInfo .= str_pad($userName,$A+$B+$userLength,' ',STR_PAD_RIGHT);
$orderInfo .= str_pad($total,$C+$D+$totalLength+1,' ',STR_PAD_LEFT);
$orderInfo .= '<BR>';
$orderInfo .= '配送方式:' . $arr->shipping_type_text . '<BR>';
if($arr->shipping_type != Shipping::SELF_TAKING){
$orderInfo .= '送货地点:' . $arr->address . '<BR>';
}
$tel = substr_replace( $arr->tel, '****', 3, 4);
$orderInfo .= '联系电话:' . $tel . '<BR>';
$orderInfo .= '下单时间:' . $arr->pay_time_text . '<BR>';

2
app/Service/v3/Interfaces/FeiePrintServiceInterface.php

@ -6,5 +6,5 @@ namespace App\Service\v3\Interfaces;
interface FeiePrintServiceInterface
{
public function feiePrint($order_num);
public function feiePrint($globalOrderId);
}
Loading…
Cancel
Save