|
|
@@ -85,22 +85,31 @@
|
|
|
:visible.sync="payDialog"
|
|
|
width="30%"
|
|
|
center
|
|
|
- >
|
|
|
- </el-dialog>
|
|
|
+ />
|
|
|
|
|
|
<el-dialog
|
|
|
title="物流"
|
|
|
append-to-body
|
|
|
- :visible.sync="deliveryDialog"
|
|
|
+ :visible.sync="logisticsDialog"
|
|
|
width="30%"
|
|
|
center
|
|
|
>
|
|
|
+ <el-timeline :reverse="false">
|
|
|
+ <el-timeline-item
|
|
|
+ v-for="(item, index) in logisticsList"
|
|
|
+ :key="index"
|
|
|
+ :timestamp="item.createAt"
|
|
|
+ placement="top"
|
|
|
+ >
|
|
|
+ <span>{{ item.current }}</span>
|
|
|
+ </el-timeline-item>
|
|
|
+ </el-timeline>
|
|
|
</el-dialog>
|
|
|
</el-row>
|
|
|
</template>
|
|
|
|
|
|
<script>
|
|
|
-import { getOrders } from '@/api/mall'
|
|
|
+import { getOrderLogistics, getOrders } from '@/api/mall'
|
|
|
|
|
|
export default {
|
|
|
name: 'Order',
|
|
|
@@ -124,7 +133,8 @@ export default {
|
|
|
totalPrice: '0.00',
|
|
|
productId: null,
|
|
|
payDialog: false,
|
|
|
- deliveryDialog: false
|
|
|
+ logisticsDialog: false,
|
|
|
+ logisticsList: []
|
|
|
}
|
|
|
},
|
|
|
created() {
|
|
|
@@ -174,7 +184,12 @@ export default {
|
|
|
if (status === 1) {
|
|
|
this.payDialog = true
|
|
|
} else if (status === 2) {
|
|
|
- this.deliveryDialog = true
|
|
|
+ getOrderLogistics(row.orderId).then(resp => {
|
|
|
+ if (resp.code === 0) {
|
|
|
+ this.logisticsDialog = true
|
|
|
+ this.logisticsList = resp.data
|
|
|
+ }
|
|
|
+ })
|
|
|
} else if (status === 3) {
|
|
|
this.$message.info('待确认')
|
|
|
}
|