@@ -66,6 +66,8 @@ class OrderHotelDao | |||||
"customer_name" => $param['customer_name'], | "customer_name" => $param['customer_name'], | ||||
"customer_comments" => empty($param['customer_comments'])?"":$param['customer_comments'], | "customer_comments" => empty($param['customer_comments'])?"":$param['customer_comments'], | ||||
"trade_order_number" => $param['trade_order_number'], | "trade_order_number" => $param['trade_order_number'], | ||||
"purchase_user_id" => $param['purchase_user_id'], | |||||
"purchase_user" => $param['purchase_user'], | |||||
"del_flag"=>0 | "del_flag"=>0 | ||||
]; | ]; | ||||
$orderHotelModel = new OrderHotel(); | $orderHotelModel = new OrderHotel(); | ||||
@@ -52,6 +52,8 @@ class OrderItemDao | |||||
"customer_name" => $param['customer_name'], | "customer_name" => $param['customer_name'], | ||||
"customer_comments" => empty($param['customer_comments'])?"":$param['customer_comments'], | "customer_comments" => empty($param['customer_comments'])?"":$param['customer_comments'], | ||||
"trade_order_number" => $param['trade_order_number'], | "trade_order_number" => $param['trade_order_number'], | ||||
"purchase_user_id" => $param['purchase_user_id'], | |||||
"purchase_user" => $param['purchase_user'], | |||||
"del_flag"=>0 | "del_flag"=>0 | ||||
]; | ]; | ||||
$model = new OrderItem(); | $model = new OrderItem(); | ||||
@@ -30,12 +30,7 @@ class PurchaseDao | |||||
if (!$suplierRe['flag']) { | if (!$suplierRe['flag']) { | ||||
return $suplierRe; | return $suplierRe; | ||||
} | } | ||||
//2.获取负责人昵称 | |||||
$adminDao = new AdminDao(); | |||||
$adminRe = $adminDao->getInfoById($param['purchase_user_id']); | |||||
if (!$adminRe['flag']) { | |||||
return $adminRe; | |||||
} | |||||
$data = [ | $data = [ | ||||
"order_id" => $hotelOrder['order_id'], | "order_id" => $hotelOrder['order_id'], | ||||
"prod_type" => 'hotel', | "prod_type" => 'hotel', | ||||
@@ -49,7 +44,7 @@ class PurchaseDao | |||||
"supplier_id" => $param['supplier_id'], | "supplier_id" => $param['supplier_id'], | ||||
"supplier_name" => $suplierRe['data']['supplier_name'], | "supplier_name" => $suplierRe['data']['supplier_name'], | ||||
"purchase_user_id" => $param['purchase_user_id'], | "purchase_user_id" => $param['purchase_user_id'], | ||||
"purchase_user" => $adminRe['data']['nickname'], | |||||
"purchase_user" => $param['purchase_user'], | |||||
"del_flag"=>0 | "del_flag"=>0 | ||||
]; | ]; | ||||
@@ -3,6 +3,7 @@ | |||||
namespace app\admin\service; | namespace app\admin\service; | ||||
use app\admin\command\Util; | use app\admin\command\Util; | ||||
use app\admin\dao\AdminDao; | |||||
use app\admin\dao\OrderHotelDao; | use app\admin\dao\OrderHotelDao; | ||||
use app\admin\dao\OrderItemDao; | use app\admin\dao\OrderItemDao; | ||||
use app\admin\dao\OrderMainDao; | use app\admin\dao\OrderMainDao; | ||||
@@ -47,6 +48,13 @@ class OrderMainService | |||||
//循环子订单 | //循环子订单 | ||||
foreach ($param['subOrderList'] as $subOrderParam) { | foreach ($param['subOrderList'] as $subOrderParam) { | ||||
$subOrderParam['group_id'] = $param['group_id']; | $subOrderParam['group_id'] = $param['group_id']; | ||||
//2.获取负责人昵称 | |||||
$adminDao = new AdminDao(); | |||||
$adminRe = $adminDao->getInfoById($subOrderParam['purchase_user_id']); | |||||
if (!$adminRe['flag']) { | |||||
return $adminRe; | |||||
} | |||||
$subOrderParam['purchase_user'] = $adminRe['data']['nickname']; | |||||
/** | /** | ||||
* 2.添加子订单 有则激活更新、无则添加 | * 2.添加子订单 有则激活更新、无则添加 | ||||
*/ | */ | ||||
@@ -122,6 +130,13 @@ class OrderMainService | |||||
{ | { | ||||
$orderId = $subOrderParam['order_id']; | $orderId = $subOrderParam['order_id']; | ||||
$orderMainDao = new OrderMainDao(); | $orderMainDao = new OrderMainDao(); | ||||
//2.获取负责人昵称 | |||||
$adminDao = new AdminDao(); | |||||
$adminRe = $adminDao->getInfoById($subOrderParam['purchase_user_id']); | |||||
if (!$adminRe['flag']) { | |||||
return $adminRe; | |||||
} | |||||
$subOrderParam['purchase_user'] = $adminRe['data']['nickname']; | |||||
/** | /** | ||||
* 2.添加子订单 | * 2.添加子订单 | ||||
*/ | */ | ||||