|
@@ -22,6 +22,13 @@
|
|
</a-form-item>
|
|
</a-form-item>
|
|
</a-form>
|
|
</a-form>
|
|
<div style="border-top:1px solid #eee;padding-top:10px;">
|
|
<div style="border-top:1px solid #eee;padding-top:10px;">
|
|
|
|
+ <a-button
|
|
|
|
+ type="primary"
|
|
|
|
+ ghost
|
|
|
|
+ :loading="loading"
|
|
|
|
+ @click="openGuideModal=true"
|
|
|
|
+ style="margin-right:5px;"
|
|
|
|
+ >导入产品</a-button>
|
|
<a-button type="primary" :loading="loading" class="button-info" @click="openModal = true">新增产品</a-button>
|
|
<a-button type="primary" :loading="loading" class="button-info" @click="openModal = true">新增产品</a-button>
|
|
<a-button type="primary" :loading="loading" class="button-error" @click="handlePlss">批量实收</a-button>
|
|
<a-button type="primary" :loading="loading" class="button-error" @click="handlePlss">批量实收</a-button>
|
|
<span v-if="rowSelectionInfo&&rowSelectionInfo.selectedRowKeys&&rowSelectionInfo.selectedRowKeys.length">已选{{ rowSelectionInfo.selectedRowKeys.length }}项</span>
|
|
<span v-if="rowSelectionInfo&&rowSelectionInfo.selectedRowKeys&&rowSelectionInfo.selectedRowKeys.length">已选{{ rowSelectionInfo.selectedRowKeys.length }}项</span>
|
|
@@ -109,6 +116,8 @@
|
|
:buyerSn="$route.params.buyerSn"
|
|
:buyerSn="$route.params.buyerSn"
|
|
@close="openModal=false"
|
|
@close="openModal=false"
|
|
@addProduct="addProduct"></chooseProductsModal>
|
|
@addProduct="addProduct"></chooseProductsModal>
|
|
|
|
+ <!-- 导入产品 -->
|
|
|
|
+ <importGuideModal :params="{salesReturnBillSn: $route.params.sn}" :openModal="openGuideModal" @close="openGuideModal=false" @ok="importOk" />
|
|
</div>
|
|
</div>
|
|
</template>
|
|
</template>
|
|
|
|
|
|
@@ -117,7 +126,8 @@ import { commonMixin } from '@/utils/mixin'
|
|
import { STable, VSelect } from '@/components'
|
|
import { STable, VSelect } from '@/components'
|
|
import chooseProductsModal from './chooseProductsModal.vue'
|
|
import chooseProductsModal from './chooseProductsModal.vue'
|
|
import returnReason from '@/views/common/returnReason'
|
|
import returnReason from '@/views/common/returnReason'
|
|
-import { salesReturnDetail, salesReturnReceive } from '@/api/salesReturn'
|
|
|
|
|
|
+import importGuideModal from './importGuideModal.vue'
|
|
|
|
+import { salesReturnDetail, salesReturnReceive, salesReturnDetailBatchByReceive } from '@/api/salesReturn'
|
|
import {
|
|
import {
|
|
salesReturnDetailList, salesReturnDetailReceiveBatch, salesReturnDetailUpdateReceiveQty, salesReturnDetailUpdateReason, insertByReceive, deleteByReceiver
|
|
salesReturnDetailList, salesReturnDetailReceiveBatch, salesReturnDetailUpdateReceiveQty, salesReturnDetailUpdateReason, insertByReceive, deleteByReceiver
|
|
} from '@/api/salesReturnDetail'
|
|
} from '@/api/salesReturnDetail'
|
|
@@ -128,10 +138,12 @@ export default {
|
|
STable,
|
|
STable,
|
|
VSelect,
|
|
VSelect,
|
|
chooseProductsModal,
|
|
chooseProductsModal,
|
|
- returnReason
|
|
|
|
|
|
+ returnReason,
|
|
|
|
+ importGuideModal
|
|
},
|
|
},
|
|
data () {
|
|
data () {
|
|
return {
|
|
return {
|
|
|
|
+ openGuideModal: false,
|
|
spinning: false,
|
|
spinning: false,
|
|
tableHeight: 0, // 表格高度
|
|
tableHeight: 0, // 表格高度
|
|
orderSn: null,
|
|
orderSn: null,
|
|
@@ -179,12 +191,12 @@ export default {
|
|
const arr = [
|
|
const arr = [
|
|
{ title: '序号', dataIndex: 'no', width: '4%', align: 'center' },
|
|
{ title: '序号', dataIndex: 'no', width: '4%', align: 'center' },
|
|
{ title: '产品编码', dataIndex: 'productEntity.code', align: 'center', width: '10%', customRender: function (text) { return text || '--' } },
|
|
{ title: '产品编码', dataIndex: 'productEntity.code', align: 'center', width: '10%', customRender: function (text) { return text || '--' } },
|
|
- { title: '产品名称', dataIndex: 'productEntity.name', width: '20%', align: 'left', customRender: function (text) { return text || '--' }, ellipsis: true },
|
|
|
|
|
|
+ { title: '产品名称', dataIndex: 'productEntity.name', width: '25%', align: 'left', customRender: function (text) { return text || '--' }, ellipsis: true },
|
|
{ title: '申请退货数量', dataIndex: 'initialQty', align: 'center', width: '10%', scopedSlots: { customRender: 'initialQty' } },
|
|
{ title: '申请退货数量', dataIndex: 'initialQty', align: 'center', width: '10%', scopedSlots: { customRender: 'initialQty' } },
|
|
{ title: '仓库实收数量', dataIndex: 'receiveQty', align: 'center', width: '10%', scopedSlots: { customRender: 'receiveQty' } },
|
|
{ title: '仓库实收数量', dataIndex: 'receiveQty', align: 'center', width: '10%', scopedSlots: { customRender: 'receiveQty' } },
|
|
{ title: '单位', dataIndex: 'productEntity.unit', width: '6%', align: 'center', customRender: function (text) { return text || '--' } },
|
|
{ title: '单位', dataIndex: 'productEntity.unit', width: '6%', align: 'center', customRender: function (text) { return text || '--' } },
|
|
// { title: '退货单价', dataIndex: 'price', align: 'center', width: '10%', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
|
|
// { title: '退货单价', dataIndex: 'price', align: 'center', width: '10%', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
|
|
- { title: '退货原因', dataIndex: 'returnReason', width: '20%', align: 'center', scopedSlots: { customRender: 'returnReason' } },
|
|
|
|
|
|
+ { title: '退货原因', dataIndex: 'returnReason', width: '25%', align: 'center', scopedSlots: { customRender: 'returnReason' } },
|
|
{ title: '操作', scopedSlots: { customRender: 'action' }, width: '10%', align: 'center' }
|
|
{ title: '操作', scopedSlots: { customRender: 'action' }, width: '10%', align: 'center' }
|
|
]
|
|
]
|
|
return arr
|
|
return arr
|
|
@@ -199,6 +211,17 @@ export default {
|
|
handleBack () {
|
|
handleBack () {
|
|
this.$router.push({ name: 'receiveCheckList' })
|
|
this.$router.push({ name: 'receiveCheckList' })
|
|
},
|
|
},
|
|
|
|
+ // 确认导入明细
|
|
|
|
+ importOk(data){
|
|
|
|
+ this.spinning = true
|
|
|
|
+ salesReturnDetailBatchByReceive({detailList:data, salesReturnBillSn: this.orderSn}).then(res => {
|
|
|
|
+ if(res.status == 200){
|
|
|
|
+ this.resetSearchForm()
|
|
|
|
+ this.$message.info(res.message)
|
|
|
|
+ }
|
|
|
|
+ this.spinning = false
|
|
|
|
+ })
|
|
|
|
+ },
|
|
// 添加产品
|
|
// 添加产品
|
|
addProduct (data) {
|
|
addProduct (data) {
|
|
const params = {
|
|
const params = {
|