|
@@ -11,19 +11,20 @@
|
|
<!-- 详情 -->
|
|
<!-- 详情 -->
|
|
<div v-if="itemData">
|
|
<div v-if="itemData">
|
|
<a-descriptions :column="3" size="default">
|
|
<a-descriptions :column="3" size="default">
|
|
- <a-descriptions-item label="调货单号">123456789</a-descriptions-item>
|
|
|
|
- <a-descriptions-item label="创建时间">2022-11-4 10:00:02</a-descriptions-item>
|
|
|
|
- <a-descriptions-item label="状态" :span="1">已完成</a-descriptions-item>
|
|
|
|
- <a-descriptions-item label="退库时间">1</a-descriptions-item>
|
|
|
|
|
|
+ <a-descriptions-item label="调回单号">{{ itemData.recallBillNo }}</a-descriptions-item>
|
|
|
|
+ <a-descriptions-item label="创建时间">{{ itemData.createDate }}</a-descriptions-item>
|
|
|
|
+ <a-descriptions-item label="状态" :span="1">{{ itemData.billStateDictValue }}</a-descriptions-item>
|
|
|
|
+ <a-descriptions-item label="退库时间">{{ itemData.confirmTime }}</a-descriptions-item>
|
|
<a-descriptions-item label="关联销售退货单">
|
|
<a-descriptions-item label="关联销售退货单">
|
|
- <span class="recallBillNo" @click="seeRecallBill">DH221104000008,</span>
|
|
|
|
- <span class="recallBillNo">DH221104000008</span>
|
|
|
|
- <a-button type="primary" ghost class="recallBillBtn">生成销售退货单</a-button>
|
|
|
|
|
|
+ <span v-if="salesReturnBillList && salesReturnBillList.length>0">
|
|
|
|
+ <span v-for="con in salesReturnBillList" :key="con.id" class="recallBillNo">{{ con.salesReturnNo }}</span>
|
|
|
|
+ </span>
|
|
|
|
+ <a-button type="primary" ghost class="recallBillBtn" @click="seeRecallBill">生成销售退货单</a-button>
|
|
</a-descriptions-item>
|
|
</a-descriptions-item>
|
|
</a-descriptions>
|
|
</a-descriptions>
|
|
</div>
|
|
</div>
|
|
<!-- 表格 -->
|
|
<!-- 表格 -->
|
|
- <div class="table-body">
|
|
|
|
|
|
+ <div class="table-body" v-if="detailList && detailList.length>0">
|
|
<table>
|
|
<table>
|
|
<tr>
|
|
<tr>
|
|
<th width="10%">序号</th>
|
|
<th width="10%">序号</th>
|
|
@@ -33,13 +34,13 @@
|
|
<th width="10%">实退数量</th>
|
|
<th width="10%">实退数量</th>
|
|
<th width="10%">单位</th>
|
|
<th width="10%">单位</th>
|
|
</tr>
|
|
</tr>
|
|
- <tr v-for="(item,index) in 5" :key="item.productSn">
|
|
|
|
|
|
+ <tr v-for="(item,index) in detailList" :key="item.id">
|
|
<td>{{ index + 1 }}</td>
|
|
<td>{{ index + 1 }}</td>
|
|
- <td>JA-11070N</td>
|
|
|
|
- <td>名字名字名字名字名字名字名字名字名字名字名字名字名字名字名字名字名字名字名字名字</td>
|
|
|
|
- <td>2</td>
|
|
|
|
- <td>2</td>
|
|
|
|
- <td>个</td>
|
|
|
|
|
|
+ <td>{{ item.productCode }}</td>
|
|
|
|
+ <td>{{ item.productName }}</td>
|
|
|
|
+ <td>{{ item.qty }}</td>
|
|
|
|
+ <td>{{ item.confirmQty }}</td>
|
|
|
|
+ <td>{{ item.product.unit }}</td>
|
|
</tr>
|
|
</tr>
|
|
</table>
|
|
</table>
|
|
</div>
|
|
</div>
|
|
@@ -53,25 +54,27 @@
|
|
:closable="false"
|
|
:closable="false"
|
|
:footer="null"
|
|
:footer="null"
|
|
width="23%">
|
|
width="23%">
|
|
- <div class="tipTop">
|
|
|
|
- <div>产品总款数:<span>5</span></div>
|
|
|
|
- <div>产品总件数:<span>5</span></div>
|
|
|
|
|
|
+ <div class="tipTop" v-if="itemData">
|
|
|
|
+ <div>产品总款数:<span>{{ itemData.totalCategory }}</span></div>
|
|
|
|
+ <div>产品总件数:<span>{{ itemData.totalQty }}</span></div>
|
|
</div>
|
|
</div>
|
|
- <div class="tipCon">确认生成销售退货订单吗?</div>
|
|
|
|
- <div class="tipCon">此调货单已经存在相应的销售退货单,确定再次生成销售退货单吗?</div>
|
|
|
|
- <div class="tipRecallBillNo">
|
|
|
|
- <p>DH221104000008</p>
|
|
|
|
- <p>DH221104000008</p>
|
|
|
|
|
|
+ <div class="tipCon" v-if="salesReturnBillList && salesReturnBillList.length==0">确认生成销售退货订单吗?</div>
|
|
|
|
+ <div v-else>
|
|
|
|
+ <div class="tipCon">此调货单已经存在相应的销售退货单,确定再次生成销售退货单吗?</div>
|
|
|
|
+ <div class="tipRecallBillNo">
|
|
|
|
+ <p v-for="con in salesReturnBillList" :key="con.id">{{ con.salesReturnNo }}</p>
|
|
|
|
+ </div>
|
|
</div>
|
|
</div>
|
|
<div class="tipFooter">
|
|
<div class="tipFooter">
|
|
<div class="btnLeft" @click="tipVisible = false">取消</div>
|
|
<div class="btnLeft" @click="tipVisible = false">取消</div>
|
|
- <div class="btnLeft">确定</div>
|
|
|
|
|
|
+ <div class="btnLeft" @click="setReturnBill">确定</div>
|
|
</div>
|
|
</div>
|
|
</a-modal>
|
|
</a-modal>
|
|
</a-modal>
|
|
</a-modal>
|
|
</template>
|
|
</template>
|
|
|
|
|
|
<script>
|
|
<script>
|
|
|
|
+import { generateSaleReturnBill } from '@/api/shelfRecall.js'
|
|
export default {
|
|
export default {
|
|
name: 'DetailModal',
|
|
name: 'DetailModal',
|
|
props: {
|
|
props: {
|
|
@@ -89,7 +92,9 @@ export default {
|
|
data () {
|
|
data () {
|
|
return {
|
|
return {
|
|
isShow: this.openModal, // 是否打开弹框
|
|
isShow: this.openModal, // 是否打开弹框
|
|
- tipVisible: false
|
|
|
|
|
|
+ tipVisible: false,
|
|
|
|
+ salesReturnBillList: [],
|
|
|
|
+ detailList: []
|
|
}
|
|
}
|
|
},
|
|
},
|
|
watch: {
|
|
watch: {
|
|
@@ -101,17 +106,32 @@ export default {
|
|
isShow (newValue, oldValue) {
|
|
isShow (newValue, oldValue) {
|
|
if (!newValue) {
|
|
if (!newValue) {
|
|
this.$emit('close')
|
|
this.$emit('close')
|
|
|
|
+ } else {
|
|
|
|
+ if (this.itemData) {
|
|
|
|
+ this.salesReturnBillList = this.itemData.salesReturnBillList
|
|
|
|
+ this.detailList = this.itemData.detailList
|
|
|
|
+ }
|
|
}
|
|
}
|
|
- // else {
|
|
|
|
- // this.getDetailList()
|
|
|
|
- // }
|
|
|
|
}
|
|
}
|
|
},
|
|
},
|
|
methods: {
|
|
methods: {
|
|
seeRecallBill () {
|
|
seeRecallBill () {
|
|
this.tipVisible = true
|
|
this.tipVisible = true
|
|
|
|
+ },
|
|
|
|
+ // 生成销售退货单
|
|
|
|
+ setReturnBill () {
|
|
|
|
+ this.spinning = true
|
|
|
|
+ generateSaleReturnBill({ recallBillSn: this.itemData.recallBillSn }).then(res => {
|
|
|
|
+ if (res.status == 200) {
|
|
|
|
+ this.$message.success(res.message)
|
|
|
|
+ this.tipVisible = false
|
|
|
|
+ this.$emit('close')
|
|
|
|
+ this.spinning = false
|
|
|
|
+ } else {
|
|
|
|
+ this.spinning = false
|
|
|
|
+ }
|
|
|
|
+ })
|
|
}
|
|
}
|
|
-
|
|
|
|
}
|
|
}
|
|
}
|
|
}
|
|
</script>
|
|
</script>
|
|
@@ -139,7 +159,10 @@ export default {
|
|
}
|
|
}
|
|
.recallBillNo{
|
|
.recallBillNo{
|
|
color:#39f;
|
|
color:#39f;
|
|
- font-weight: 600;
|
|
|
|
|
|
+ font-weight: 600;
|
|
|
|
+ }
|
|
|
|
+ .recallBillNo:not(:last-child)::after{
|
|
|
|
+ content:',';
|
|
}
|
|
}
|
|
.recallBillBtn{
|
|
.recallBillBtn{
|
|
border-color:#39f;
|
|
border-color:#39f;
|
|
@@ -167,7 +190,7 @@ export default {
|
|
color:#333;
|
|
color:#333;
|
|
margin:0 auto;
|
|
margin:0 auto;
|
|
span{
|
|
span{
|
|
- color:#f30f3;
|
|
|
|
|
|
+ color:#f30f30;
|
|
font-weight: bold;
|
|
font-weight: bold;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
@@ -177,7 +200,7 @@ export default {
|
|
text-align: center;
|
|
text-align: center;
|
|
}
|
|
}
|
|
.tipRecallBillNo{
|
|
.tipRecallBillNo{
|
|
- padding:20px;
|
|
|
|
|
|
+ padding:0 20px;
|
|
p{
|
|
p{
|
|
padding-bottom: 15px;
|
|
padding-bottom: 15px;
|
|
border-bottom: 1px solid #e0e0e0;
|
|
border-bottom: 1px solid #e0e0e0;
|