Compare commits

..

No commits in common. "2dd2fed0c0324b50023c343b3a92603b2507f93a" and "e3c08391b757c295158676e16d8ecd92ff0d66f6" have entirely different histories.

13 changed files with 24 additions and 117 deletions

View File

@ -186,7 +186,7 @@
v-if="scope.row.is_direct_mode && scope.row.appointment_status == 1"
size="small"
icon="el-icon-thumb"
@click="confirmOrder(scope.row)"
@click="dyOrderConfirm(scope.row)"
>
确认接单
</el-button>
@ -570,81 +570,6 @@
</el-tabs>
</el-dialog>
<el-dialog title="确认接单" :visible.sync="orderConfirmDialogVisible">
<el-form label-width="130px" :model="item">
<el-form-item label="产品名称">
{{ item.product_name }}
</el-form-item>
<el-row>
<el-col :span="12">
<el-form-item label="产品状态">
{{ item.order_status_name }}
</el-form-item>
<el-form-item label="数量">
{{ item.quantity }}
</el-form-item>
<el-form-item label="手机">
{{ item.mobile }}
</el-form-item>
<el-form-item label="下单时间">
{{ item.create_at | parseTime("{y}-{m}-{d} {h}:{i}") }}
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item v-if="item.dyOrderAppointments.number_of_guests" label="人员">
<el-row>
<el-col :span="3">大人</el-col>
<el-col :span="5"
><el-input
v-model="item.dyOrderAppointments.number_of_guests.adult"
name="adult"
placeholder="大人"
/></el-col>
<el-col :span="3">小孩</el-col>
<el-col :span="5"
><el-input
v-model="item.dyOrderAppointments.number_of_guests.child"
name="child"
placeholder="小孩"
/></el-col>
</el-row>
</el-form-item>
<el-form-item label="出游日期">
{{ item.dyOrderAppointments.book_info.book_start_date }}
</el-form-item>
<el-form-item label="返回日期">
{{ item.dyOrderAppointments.book_info.book_end_date }}
</el-form-item>
</el-col>
</el-row>
<el-form-item label="预约详情">
<el-table
v-if="item.dyOrderAppointments.book_info.occupancies"
:data="item.dyOrderAppointments.book_info.occupancies"
style="width: 100%;margin-bottom: 0;">
<el-table-column
prop="name"
label="出行人"
width="180">
</el-table-column>
<el-table-column
prop="license_id"
label="证件号"
width="180">
</el-table-column>
</el-table>
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button type="primary" @click="dyOrderConfirm(item, 1)">确认接单</el-button>
<el-button type="primary" @click="dyOrderConfirm(item, 2)">拒绝</el-button>
</div>
</el-dialog>
<el-dialog title="纯核销" :visible.sync="dialog2Visible">
<el-form label-width="160px" :model="form">
<el-form-item label="平台">
@ -767,13 +692,12 @@ export default {
os_status: [],
appointment_status: "",
},
item: { next_follow: "", personnel: { adult: "" }, dyOrderAppointments:{book_info:{}} },
item: { next_follow: "", personnel: { adult: "" } },
follow: [],
dialogVisible: false,
dialog2Visible: false,
applyVisible: false,
orderConfirmDialogVisible:false,
oss: [],
isSynchronization: false,
item3: {
@ -930,15 +854,6 @@ export default {
})
.catch((err) => {});
},
confirmOrder(item) {
this.$axios
.get("/admin/order/info", { params: { id: item.id } })
.then((res) => {
this.item = res.data;
this.orderConfirmDialogVisible = true;
})
.catch((err) => {});
},
resetForm(formName) {
this.$refs[formName].resetFields();
},
@ -1124,17 +1039,16 @@ export default {
});
});
},
dyOrderConfirm(item, confirm_result) {
dyOrderConfirm(item) {
this.$axios
.post("/admin/order/dyOrderConfirm", { id: item.id, confirm_result:confirm_result })
.post("/admin/order/dyOrderConfirm", { id: item.id })
.then((res) => {
this.$notify({
title: "成功",
message: "操作成功",
message: "接单成功",
type: "success",
});
this.orderConfirmDialogVisible = false;
this.getList();
// this.getList();
})
.catch((err) => {
this.$notify.error({

View File

@ -242,7 +242,7 @@ class OrderController extends base
if($request->admin->is_super == 0) {
$where[] = ['admin_id','=',$request->admin->id];
}
$item = Orders::where($where)->with(['follow.admin','finance', 'dyOrderAppointments'])->find();
$item = Orders::where($where)->with(['follow.admin','finance'])->find();
if(empty($item)) {
return $this->error(2002, '订单没有找到或者已经转移到其他人');
@ -714,13 +714,11 @@ class OrderController extends base
return $this->error(2004, '记录没有找到.');
}
// 1接单 2拒单
if (!$request->post('confirm_result') || !in_array($request->post('confirm_result'), [1, 2])) {
return $this->error(2005, '确认状态错误');
}
$confirmResult = $request->post('confirm_result', 1);
// 抖音预约信息z
$appoint = DyOrderProductAppointments::query()->where(['source_order_id' => $order['sn']])->order('id desc')->find();
// if (!$request->post('confirm_result') || !in_array($request->post('confirm_result'), [1, 2])) {
// return $this->error(2005, '确认状态错误');
// }
// 抖音预约信息
$appoint = DyOrderProductAppointments::query()->where(['source_order_id' => $order['sn']])->find();
if (empty($appoint)) {
return $this->error(2004, '该订单暂未预约,不可接单');
}
@ -741,7 +739,7 @@ class OrderController extends base
'order_id' => $appoint->dy_order_id,
'source_order_id' => $appoint->source_order_id,
'confirm_info' => [
'confirm_result' => $confirmResult,
'confirm_result' => $request->post('confirm_result', 1),
'reject_code' => $request->post('reject_code'), // 1: 库存已约满 2商品需加价 3无法满足顾客需求
// 'hotel_info' => [], // 境内住宿类目/酒景套餐 必填
// 'play_info' => [], // 境内游玩类目 必填
@ -750,7 +748,7 @@ class OrderController extends base
];
// 自由行必填参数
$dyApiService = new DyApiService();
if ($confirmResult == 1 && in_array($dyOrderProduct->category_id, $zyxCategoryIds)) {
if (in_array($dyOrderProduct->category_id, $zyxCategoryIds)) {
$onedayTourList = [];
foreach ($dyOrderProduct->travel_details as $k => $travel_detail) {
array_push($onedayTourList, [
@ -761,7 +759,7 @@ class OrderController extends base
}
$confirmData['confirm_info']['free_travel_info']['oneday_tour_list'] = $onedayTourList;
}
if ($confirmResult == 1 && in_array($dyOrderProduct->category_id, $jnCategoryIds)) {
if (in_array($dyOrderProduct->category_id, $jnCategoryIds)) {
// 获取poi信息
$poiRes = $dyApiService->send(DyApiService::POI_QUERY, ['order_id' => $order->sn, 'account_id' => env('DY_ACCOUNT_ID')]);
$payInfo = [

View File

@ -179,11 +179,6 @@ class Orders extends base
return $this->belongsTo(Products::class, 'product_id', 'third_product_id');
}
public function dyOrderAppointments()
{
return $this->belongsTo(DyOrderProductAppointments::class, 'sn', 'source_order_id');
}
public static function fish($id, $admin_id)
{
return Db::transaction(function () use ($id, $admin_id) {

View File

@ -499,7 +499,7 @@ class Douyin
'Content-type: application/json'
];
if ($method == 'GET' || $method == 'POST') {
$header[] = 'x-secsdk-csrf-token: ' . $this->_token('');
$header[] = 'x-secsdk-csrf-token: ' . $this->_token('', $this->os);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
} else {
curl_setopt($ch, CURLOPT_HEADER, 1);

View File

@ -164,9 +164,9 @@ class Meituan {
Log::info('http:' . $http);
Log::info('body:' . $body);
if ($this->tryTimes > 1) {
// if ($this->tryTimes > 1) {
(new ThirdApiService())->weComNotice($this->os);
}
// }
$this->tryTimes++;
}
return $res;

File diff suppressed because one or more lines are too long

View File

@ -1 +1 @@
.pagination-container[data-v-28fdfbeb]{padding:32px 16px;position:fixed;bottom:0;left:0;width:100%;background:#fff;padding:40px 280px;-webkit-box-shadow:0 -2px 10px rgba(0,0,0,.1);box-shadow:0 -2px 10px rgba(0,0,0,.1);z-index:100}.pagination-container.hidden[data-v-28fdfbeb]{display:none}.app-container[data-v-553f6d94]{position:relative;padding-bottom:60px}.el-table[data-v-553f6d94],.filter-container[data-v-553f6d94]{padding-bottom:5px}
.pagination-container[data-v-28fdfbeb]{padding:32px 16px;position:fixed;bottom:0;left:0;width:100%;background:#fff;padding:40px 280px;-webkit-box-shadow:0 -2px 10px rgba(0,0,0,.1);box-shadow:0 -2px 10px rgba(0,0,0,.1);z-index:100}.pagination-container.hidden[data-v-28fdfbeb]{display:none}.app-container[data-v-6312f01b]{position:relative;padding-bottom:60px}.el-table[data-v-6312f01b],.filter-container[data-v-6312f01b]{padding-bottom:5px}

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long