订单管理-外卖订单-订单详情

master
panqihua 2 years ago
parent 673c6dcd11
commit 509ba1bc33
  1. 19
      src/views/platform/components/order_detail.vue
  2. 37
      src/views/platform/components/progress.vue
  3. 7
      src/views/platform/order_management/delivery_order.vue
  4. 4
      src/views/platform/self-operated-mall/components/refund_order_detail.vue
  5. 4
      src/views/platform/self-operated-mall/order.vue

@ -1,5 +1,5 @@
<template> <template>
<el-dialog :visible="showDetail" :show-close="false" @closed="view = true"> <el-dialog :visible="open" :show-close="false" @closed="view = true">
<div slot="title" class="title"> <div slot="title" class="title">
<span>订单详情</span> <span>订单详情</span>
<i :class="{ <i :class="{
@ -19,6 +19,9 @@
<el-form-item label="订单号"> <el-form-item label="订单号">
<el-input v-model="form.orderId"></el-input> <el-input v-model="form.orderId"></el-input>
</el-form-item> </el-form-item>
<el-form-item label="购买门店" v-if="type === 2" style="margin-left:20px">
<el-input v-model="form.shopName"></el-input>
</el-form-item>
<br /> <br />
<el-form-item label="用户昵称"> <el-form-item label="用户昵称">
<el-input v-model="form.user.nickName"></el-input> <el-input v-model="form.user.nickName"></el-input>
@ -26,14 +29,16 @@
<el-form-item label="用户ID" style="margin-left:20px"> <el-form-item label="用户ID" style="margin-left:20px">
<el-input v-model="form.user.userId"></el-input> <el-input v-model="form.user.userId"></el-input>
</el-form-item> </el-form-item>
<el-form-item label="配送物流"> <el-form-item :label="'配送' + (type === 1 ? '物流' : '类型')">
<el-input v-model="form.logisticsCompany"></el-input> <el-input v-model="form.logisticsCompany"></el-input>
</el-form-item> </el-form-item>
<template v-if="type === 1">
<el-form-item label="快递单号" style="margin-left:20px"> <el-form-item label="快递单号" style="margin-left:20px">
<el-input v-model="form.expressNumber"></el-input> <el-input v-model="form.expressNumber"></el-input>
</el-form-item> </el-form-item>
<br /> <br />
<el-form-item label="创建时间"> </template>
<el-form-item label="创建时间" :style="type === 2 ? 'margin-left:20px' : ''">
<el-input v-model="form.createTime"></el-input> <el-input v-model="form.createTime"></el-input>
</el-form-item> </el-form-item>
<br /> <br />
@ -92,7 +97,7 @@
<el-button @click="$emit('close')">关闭</el-button> <el-button @click="$emit('close')">关闭</el-button>
</div> </div>
</div> </div>
<order-progress v-else /> <order-progress :type="type" v-else />
</el-dialog> </el-dialog>
</template> </template>
<script> <script>
@ -101,7 +106,10 @@ export default {
name: "OrderDetail", name: "OrderDetail",
components: { OrderProgress }, components: { OrderProgress },
props: { props: {
showDetail: Boolean // dialog
open: Boolean,
//TODO: 1 2 UI
type: Number
}, },
data() { data() {
return { return {
@ -113,6 +121,7 @@ export default {
userId: 123131, userId: 123131,
nickName: '用户昵称' nickName: '用户昵称'
}, },
shopName: '门店名称',
logisticsCompany: '美团转送', logisticsCompany: '美团转送',
expressNumber: '13132131361313132', expressNumber: '13132131361313132',
createTime: '2022-12-31 12:31', createTime: '2022-12-31 12:31',

@ -1,6 +1,8 @@
<template> <template>
<div> <div>
<div class="logistics-info">物流公司xxxxx<br /> <div class="logistics-info">
<div>
物流公司xxxxx<br />
物流单号xxxx<br /> 物流单号xxxx<br />
起点湖北省武汉市东西湖区xxx<br /> 起点湖北省武汉市东西湖区xxx<br />
目的地xxxx<br /> 目的地xxxx<br />
@ -8,8 +10,13 @@
签收时间xxx<br /> 签收时间xxx<br />
完成时间xxx 完成时间xxx
</div> </div>
<div class="right" v-if="type === 2">
<div>送达时间xxx</div>
<img src="http://www.dummyimage.com/100x100" />
</div>
</div>
<div class="progress"> <div class="progress" v-if="type === 1">
<div class="circle start"></div> <div class="circle start"></div>
<template v-for="item in 4"> <template v-for="item in 4">
<div class="line"></div> <div class="line"></div>
@ -28,12 +35,20 @@
<div class="line"></div> <div class="line"></div>
<i class="el-icon-caret-right end" /> <i class="el-icon-caret-right end" />
</div> </div>
<div class="map" v-else>
地图
</div>
</div> </div>
</template> </template>
<script> <script>
export default { export default {
name: 'Progress' name: 'Progress',
props: {
//TODO: 1 2 UI
type: Number
}
} }
</script> </script>
<style scoped lang="scss"> <style scoped lang="scss">
@ -42,6 +57,22 @@ $circle-size: 20px;
.logistics-info { .logistics-info {
font-size: 16px; font-size: 16px;
display: flex;
&>.right {
margin-left: 10%;
display: flex;
flex-direction: column;
justify-content: space-between;
}
}
.map {
width: 100%;
background-color: rgba(0, 0, 0, 0.2);
font-size: 20px;
height: 50vh;
margin-top: 10px;
} }
.progress { .progress {

@ -55,20 +55,25 @@
<el-table-column align="center" label="创建时间">2022-12-31 12:31</el-table-column> <el-table-column align="center" label="创建时间">2022-12-31 12:31</el-table-column>
<el-table-column align="center" label="收货地址">河南省郑州市金水区光明路125号</el-table-column> <el-table-column align="center" label="收货地址">河南省郑州市金水区光明路125号</el-table-column>
<el-table-column align="center" label="操作"> <el-table-column align="center" label="操作">
<el-button type="text">订单详情</el-button> <el-button type="text" @click="open = true">订单详情</el-button>
</el-table-column> </el-table-column>
</el-table> </el-table>
<order-detail :open="open" @close="open = false" :type="2" />
<pagination v-show="total > 0" :total="total" :page.sync="queryParams.pageNum" <pagination v-show="total > 0" :total="total" :page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize" @pagination="getList" /> :limit.sync="queryParams.pageSize" @pagination="getList" />
</div> </div>
</template> </template>
<script> <script>
import OrderDetail from '../components/order_detail';
export default { export default {
name: 'DeliveryOrder', name: 'DeliveryOrder',
components: { OrderDetail },
dicts: ['delivery_type'], dicts: ['delivery_type'],
data() { data() {
return { return {
open: false,
dataList: [{}], dataList: [{}],
total: 1, total: 1,
activeName: "all", activeName: "all",

@ -144,11 +144,11 @@
<el-button @click="$emit('close')">关闭</el-button> <el-button @click="$emit('close')">关闭</el-button>
</div> </div>
</template> </template>
<order-progress v-else /> <order-progress :type="1" v-else />
</el-dialog> </el-dialog>
</template> </template>
<script> <script>
import OrderProgress from "./progress" import OrderProgress from "@/views/platform/components/progress"
export default { export default {
name: 'RefundOrderDetail', name: 'RefundOrderDetail',
components: { OrderProgress }, components: { OrderProgress },

@ -77,7 +77,7 @@
</el-table> </el-table>
<order-detail :show-detail="open" @close="open = false" /> <order-detail :open="open" @close="open = false" :type="1" />
<pagination v-show="total > 0" :total="total" :page.sync="queryParams.pageNum" <pagination v-show="total > 0" :total="total" :page.sync="queryParams.pageNum"
@ -85,7 +85,7 @@
</div> </div>
</template> </template>
<script> <script>
import OrderDetail from "./components/order_detail.vue" import OrderDetail from "../components/order_detail"
export default { export default {
name: "Order", name: "Order",
components: { OrderDetail }, components: { OrderDetail },

Loading…
Cancel
Save