|
|
@@ -1,81 +1,42 @@
|
|
|
<template>
|
|
|
- <app-view class="purchasetradedetail">
|
|
|
+ <app-view class="order-detail g-form">
|
|
|
<template #header>
|
|
|
<app-navbar title="采购详情" />
|
|
|
</template>
|
|
|
- <div v-if="detail" class="purchasetradedetail__container">
|
|
|
- <table class="purchasetradedetail__container__table" cellspacing="0" cellpadding="0">
|
|
|
- <tbody>
|
|
|
- <tr class="row">
|
|
|
- <td>商品:</td>
|
|
|
- <td>{{ handleNoneValue(detail.wrstandardname) }}</td>
|
|
|
- <td>仓库:</td>
|
|
|
- <td>{{ handleNoneValue(detail.warehousename) }}</td>
|
|
|
- </tr>
|
|
|
- <tr class="row">
|
|
|
- <td>预售价:</td>
|
|
|
- <td>{{ handleNoneValue(detail.tradeprice) }}</td>
|
|
|
- <td>数量:</td>
|
|
|
- <td>{{ handleNoneValue(detail.tradeqty) }}</td>
|
|
|
- </tr>
|
|
|
- <tr class="row">
|
|
|
- <td>定金:</td>
|
|
|
- <td>{{ handleNoneValue(detail.payeddeposit) }}</td>
|
|
|
- <td>实际价:</td>
|
|
|
- <td>{{ handleNoneValue(detail.lastprice) }}</td>
|
|
|
- </tr>
|
|
|
- <tr class="row">
|
|
|
- <td>尾款:</td>
|
|
|
- <td>{{ handleNoneValue(detail.remainamount) }}</td>
|
|
|
- <td>优惠:</td>
|
|
|
- <td>{{ handleNoneValue(detail.discountamount) }}</td>
|
|
|
- </tr>
|
|
|
- <tr class="row">
|
|
|
- <td>状态:</td>
|
|
|
- <td>{{ handleNoneValue(detail.orderstatus) }}</td>
|
|
|
- <td>总货款:</td>
|
|
|
- <td>{{ handleNoneValue(detail.tradeamount) }}</td>
|
|
|
- </tr>
|
|
|
- <tr class="row">
|
|
|
- <td>提货方式:</td>
|
|
|
- <td>{{ handleNoneValue(detail.thjdeliverymodedisplay) }}</td>
|
|
|
- <td>摘牌时间:</td>
|
|
|
- <td>{{ formatDate(detail.tradetime, 'YYYY/MM/DD HH:mm:ss') }}</td>
|
|
|
- </tr>
|
|
|
- <tr class="row">
|
|
|
- <td>联系人:</td>
|
|
|
- <td>{{ handleNoneValue(detail.contactname) }}</td>
|
|
|
- <td>联系方式:</td>
|
|
|
- <td>{{ handleNoneValue(detail.contactinfo) }}</td>
|
|
|
- </tr>
|
|
|
- <tr class="row">
|
|
|
- <td>目的地地址:</td>
|
|
|
- <td colspan="3">{{ handleNoneValue(detail.desaddress) }}</td>
|
|
|
- </tr>
|
|
|
- <tr class="row">
|
|
|
- <td>发票信息:</td>
|
|
|
- <td colspan="3">{{ handleNoneValue(detail.receiptinfo )}}</td>
|
|
|
- </tr>
|
|
|
- <tr class="row">
|
|
|
- <td>合同单号:</td>
|
|
|
- <td colspan="2">{{ handleNoneValue(detail.wrtradedetailid) }}</td>
|
|
|
- <Button size="mini">查看合同</Button>
|
|
|
- </tr>
|
|
|
- </tbody>
|
|
|
- </table>
|
|
|
+ <div v-if="detail" class="order-detail__container g-form__container">
|
|
|
+ <CellGroup title="采购信息">
|
|
|
+ <Cell title="商品" :value="detail.wrstandardname" />
|
|
|
+ <Cell title="仓库" :value="detail.warehousename" />
|
|
|
+ <Cell title="预售价" :value="detail.tradeprice" />
|
|
|
+ <Cell title="数量" :value="detail.tradeqty" />
|
|
|
+ <Cell title="定金" :value="detail.payeddeposit" />
|
|
|
+ <Cell title="实际价" :value="detail.lastprice" />
|
|
|
+ <Cell title="尾款" :value="detail.remainamount" />
|
|
|
+ <Cell title="状态" :value="detail.orderstatus" />
|
|
|
+ <Cell title="总货款" :value="detail.tradeamount" />
|
|
|
+ <Cell title="摘牌时间:" :value="formatDate(detail.tradetime, 'YYYY/MM/DD HH:mm:ss')" />
|
|
|
+ </CellGroup>
|
|
|
+ <CellGroup title="提货信息">
|
|
|
+ <Cell title="提货方式" :value="detail.thjdeliverymodedisplay" />
|
|
|
+ <Cell title="联系人" :value="detail.contactname" v-if="detail.contactname" />
|
|
|
+ <Cell title="联系方式" :value="detail.contactinfo" v-if="detail.contactinfo" />
|
|
|
+ <Cell title="目的地地址" :value="detail.desaddress" v-if="detail.desaddress" />
|
|
|
+ <Cell title="发票信息" :value="detail.receiptinfo" v-if="detail.receiptinfo" />
|
|
|
+ <Cell title="合同单号" :value="detail.wrtradedetailid" is-link />
|
|
|
+ </CellGroup>
|
|
|
</div>
|
|
|
<div v-else>
|
|
|
<Empty />
|
|
|
</div>
|
|
|
<template #footer>
|
|
|
- <div class="purchasetradedetail_buttonview">
|
|
|
- <!-- <Button block round type="primary" v-if="detail?.orderstatus === 1">合同转让</Button>
|
|
|
- <Button block round type="primary" v-if="detail?.orderstatus === 8">转让撤销</Button> -->
|
|
|
- <Button block round type="primary" v-if="detail?.orderstatus === 5" @click="spotConfirmSubmit">确认交收</Button>
|
|
|
- <div class="pay__buttonview">
|
|
|
- <Button block round type="primary" v-if="detail?.orderstatus === 3" @click="spotApplySubmit">违约</Button>
|
|
|
- <Button block round type="primary" v-if="detail?.orderstatus === 3" @click="spotPlaymentSubmit">支付</Button>
|
|
|
- </div>
|
|
|
+ <div class="g-form__footer" v-if="detail">
|
|
|
+ <!-- <Button block round type="primary" v-if="detail.orderstatus === 1">合同转让</Button>
|
|
|
+ <Button block round type="primary" v-if="detail.orderstatus === 8">转让撤销</Button> -->
|
|
|
+ <Button block round type="primary" v-if="detail.orderstatus === 5"
|
|
|
+ @click="spotConfirmSubmit">确认交收</Button>
|
|
|
+ <Button block round type="primary" v-if="detail.orderstatus === 3" @click="spotApplySubmit">违约</Button>
|
|
|
+ <Button block round type="primary" v-if="detail.orderstatus === 3"
|
|
|
+ @click="spotPlaymentSubmit">支付</Button>
|
|
|
</div>
|
|
|
</template>
|
|
|
</app-view>
|
|
|
@@ -83,25 +44,24 @@
|
|
|
|
|
|
<script lang="ts" setup>
|
|
|
|
|
|
-import { shallowRef, computed, ref } from 'vue'
|
|
|
+import { shallowRef } from 'vue'
|
|
|
import { useNavigation } from '@/hooks/navigation'
|
|
|
import { fullloading, dialog } from '@/utils/vant'
|
|
|
-import { Empty, Button, Toast } from 'vant'
|
|
|
-import { handleNoneValue, formatDate } from "@/filters";
|
|
|
+import { CellGroup, Cell, Empty, Button, Toast } from 'vant'
|
|
|
+import { formatDate } from "@/filters";
|
|
|
import { useSpotPresaleDeliveryConfirm, useSpotPresaleBreachOfContractApply, useSpotPresalePlayment } from "@/business/trade";
|
|
|
|
|
|
-const { route } = useNavigation()
|
|
|
+const { route, router } = useNavigation()
|
|
|
const item = route.params.item
|
|
|
const detail = shallowRef<Model.THJPurchaseTradeDetailRsp>()
|
|
|
-const { router } = useNavigation()
|
|
|
|
|
|
const { confirmSubmit } = useSpotPresaleDeliveryConfirm()
|
|
|
-const { applySubmit} = useSpotPresaleBreachOfContractApply()
|
|
|
-const { playmentSubmit} = useSpotPresalePlayment()
|
|
|
+const { applySubmit } = useSpotPresaleBreachOfContractApply()
|
|
|
+const { playmentSubmit } = useSpotPresalePlayment()
|
|
|
|
|
|
if (item) {
|
|
|
detail.value = JSON.parse(item.toString())
|
|
|
-}
|
|
|
+}
|
|
|
|
|
|
/// 确认交收
|
|
|
const spotConfirmSubmit = () => {
|
|
|
@@ -154,30 +114,9 @@ const spotPlaymentSubmit = () => {
|
|
|
})
|
|
|
})
|
|
|
}
|
|
|
-
|
|
|
+
|
|
|
</script>
|
|
|
|
|
|
<style lang="less">
|
|
|
-
|
|
|
-.purchasetradedetail {
|
|
|
- &__container {
|
|
|
- height: 100%;
|
|
|
- overflow-y: auto;
|
|
|
- padding: .10rem .20rem;
|
|
|
- }
|
|
|
-
|
|
|
- &_buttonview {
|
|
|
- .pay__buttonview {
|
|
|
- display: flex;
|
|
|
- flex-direction: row;
|
|
|
- justify-content: space-between;
|
|
|
- padding: .1rem;
|
|
|
-
|
|
|
- .van-button {
|
|
|
- width: 45%;
|
|
|
- }
|
|
|
- }
|
|
|
- }
|
|
|
-}
|
|
|
-
|
|
|
+@import './index.less';
|
|
|
</style>
|