nizongfeng 3 anni fa
parent
commit
53004e4b9d
4 ha cambiato i file con 21 aggiunte e 7 eliminazioni
  1. +2
    -0
      application/admin/dao/OrderHotelDao.php
  2. +2
    -0
      application/admin/dao/OrderItemDao.php
  3. +2
    -7
      application/admin/dao/PurchaseDao.php
  4. +15
    -0
      application/admin/service/OrderMainService.php

+ 2
- 0
application/admin/dao/OrderHotelDao.php Vedi File

@@ -66,6 +66,8 @@ class OrderHotelDao
"customer_name" => $param['customer_name'],
"customer_comments" => empty($param['customer_comments'])?"":$param['customer_comments'],
"trade_order_number" => $param['trade_order_number'],
"purchase_user_id" => $param['purchase_user_id'],
"purchase_user" => $param['purchase_user'],
"del_flag"=>0
];
$orderHotelModel = new OrderHotel();


+ 2
- 0
application/admin/dao/OrderItemDao.php Vedi File

@@ -52,6 +52,8 @@ class OrderItemDao
"customer_name" => $param['customer_name'],
"customer_comments" => empty($param['customer_comments'])?"":$param['customer_comments'],
"trade_order_number" => $param['trade_order_number'],
"purchase_user_id" => $param['purchase_user_id'],
"purchase_user" => $param['purchase_user'],
"del_flag"=>0
];
$model = new OrderItem();


+ 2
- 7
application/admin/dao/PurchaseDao.php Vedi File

@@ -30,12 +30,7 @@ class PurchaseDao
if (!$suplierRe['flag']) {
return $suplierRe;
}
//2.获取负责人昵称
$adminDao = new AdminDao();
$adminRe = $adminDao->getInfoById($param['purchase_user_id']);
if (!$adminRe['flag']) {
return $adminRe;
}

$data = [
"order_id" => $hotelOrder['order_id'],
"prod_type" => 'hotel',
@@ -49,7 +44,7 @@ class PurchaseDao
"supplier_id" => $param['supplier_id'],
"supplier_name" => $suplierRe['data']['supplier_name'],
"purchase_user_id" => $param['purchase_user_id'],
"purchase_user" => $adminRe['data']['nickname'],
"purchase_user" => $param['purchase_user'],
"del_flag"=>0
];



+ 15
- 0
application/admin/service/OrderMainService.php Vedi File

@@ -3,6 +3,7 @@
namespace app\admin\service;

use app\admin\command\Util;
use app\admin\dao\AdminDao;
use app\admin\dao\OrderHotelDao;
use app\admin\dao\OrderItemDao;
use app\admin\dao\OrderMainDao;
@@ -47,6 +48,13 @@ class OrderMainService
//循环子订单
foreach ($param['subOrderList'] as $subOrderParam) {
$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.添加子订单 有则激活更新、无则添加
*/
@@ -122,6 +130,13 @@ class OrderMainService
{
$orderId = $subOrderParam['order_id'];
$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.添加子订单
*/


Caricamento…
Annulla
Salva