|
@@ -54,25 +54,23 @@
|
|
<a-tab-pane v-for="item in orderDetail.officialPartnerOrderList" :key="item.officialPartnerNo" :tab="item.officialPartner.name"></a-tab-pane>
|
|
<a-tab-pane v-for="item in orderDetail.officialPartnerOrderList" :key="item.officialPartnerNo" :tab="item.officialPartner.name"></a-tab-pane>
|
|
</a-tabs>
|
|
</a-tabs>
|
|
<!-- 商品订单 -->
|
|
<!-- 商品订单 -->
|
|
- <!-- <GoodsOrder v-for="(item, index) in orderData" :key="index" :orderData="item" @sendGoods="sendGoods" /> -->
|
|
|
|
<div v-if="orderData">
|
|
<div v-if="orderData">
|
|
<!-- 待发货 -->
|
|
<!-- 待发货 -->
|
|
- <GoodsOrder v-for="(item, index) in orderData.orderExpressList" :key="index" type="express" :orderData="item" @sendGoods="sendGoods" />
|
|
|
|
|
|
+ <GoodsOrder type="orderGoods" :orderData="orderData.orderGoodsList" :isReset="isReset" @sendGoods="sendGoods" />
|
|
<!-- 已发货 -->
|
|
<!-- 已发货 -->
|
|
- <GoodsOrder v-for="(item, index) in orderData.orderGoodsList" :key="index" type="orderGoods" :orderData="item" />
|
|
|
|
|
|
+ <GoodsOrder v-for="(item, index) in orderData.orderExpressList" :key="index" type="express" :orderData="item" />
|
|
</div>
|
|
</div>
|
|
-
|
|
|
|
</div>
|
|
</div>
|
|
</a-card>
|
|
</a-card>
|
|
<!-- 物流信息 -->
|
|
<!-- 物流信息 -->
|
|
- <GoodsLogistics v-if="orderDetail" :openModal="openModal" :orderNo="orderDetail.orderNo" @success="handleClick" @close="openModal=false" />
|
|
|
|
|
|
+ <GoodsLogistics :openModal="openModal" @submit="handleSubmit" @close="openModal=false" />
|
|
</div>
|
|
</div>
|
|
</template>
|
|
</template>
|
|
|
|
|
|
<script>
|
|
<script>
|
|
import GoodsOrder from './GoodsOrder.vue'
|
|
import GoodsOrder from './GoodsOrder.vue'
|
|
import GoodsLogistics from './GoodsLogistics.vue'
|
|
import GoodsLogistics from './GoodsLogistics.vue'
|
|
-import { orderFind, offPartnerOrderFind } from '@/api/order'
|
|
|
|
|
|
+import { orderFind, offPartnerOrderFind, orderExpressSend } from '@/api/order'
|
|
export default {
|
|
export default {
|
|
name: 'OrderDetail',
|
|
name: 'OrderDetail',
|
|
components: { GoodsOrder, GoodsLogistics },
|
|
components: { GoodsOrder, GoodsLogistics },
|
|
@@ -81,7 +79,9 @@ export default {
|
|
orderDetail: null, // 订单详情
|
|
orderDetail: null, // 订单详情
|
|
orderData: null,
|
|
orderData: null,
|
|
officialPartnerNo: '', // 供货商编号
|
|
officialPartnerNo: '', // 供货商编号
|
|
- openModal: false // 是否填写物流信息
|
|
|
|
|
|
+ openModal: false, // 是否填写物流信息
|
|
|
|
+ orderGoodsNoList: [], // 发货订单号
|
|
|
|
+ isReset: false // 是否重置数据
|
|
}
|
|
}
|
|
},
|
|
},
|
|
methods: {
|
|
methods: {
|
|
@@ -100,13 +100,9 @@ export default {
|
|
},
|
|
},
|
|
// 立即发货
|
|
// 立即发货
|
|
sendGoods (idArr) {
|
|
sendGoods (idArr) {
|
|
- console.log(idArr)
|
|
|
|
|
|
+ this.orderGoodsNoList = idArr
|
|
this.openModal = true
|
|
this.openModal = true
|
|
},
|
|
},
|
|
- // // 物流信息填写成功
|
|
|
|
- // sendGoodsSuccess () {
|
|
|
|
- // console.log('物流信息填写成功')
|
|
|
|
- // },
|
|
|
|
getOrderDetail () {
|
|
getOrderDetail () {
|
|
orderFind({ id: this.$route.params.id }).then(res => {
|
|
orderFind({ id: this.$route.params.id }).then(res => {
|
|
if (res.status == 200) {
|
|
if (res.status == 200) {
|
|
@@ -119,6 +115,18 @@ export default {
|
|
this.orderDetail = null
|
|
this.orderDetail = null
|
|
}
|
|
}
|
|
})
|
|
})
|
|
|
|
+ },
|
|
|
|
+ // 提交物流
|
|
|
|
+ handleSubmit (form) {
|
|
|
|
+ form.orderGoodsNoList = this.orderGoodsNoList
|
|
|
|
+ orderExpressSend(form).then(res => {
|
|
|
|
+ if (res.status == 200) {
|
|
|
|
+ this.isReset = true
|
|
|
|
+ this.$message.success(res.message)
|
|
|
|
+ this.handleClick()
|
|
|
|
+ this.openModal = false
|
|
|
|
+ }
|
|
|
|
+ })
|
|
}
|
|
}
|
|
},
|
|
},
|
|
beforeRouteEnter (to, from, next) {
|
|
beforeRouteEnter (to, from, next) {
|