|
@@ -70,7 +70,7 @@
|
|
:rowKey="(record) => record.id"
|
|
:rowKey="(record) => record.id"
|
|
:columns="columns"
|
|
:columns="columns"
|
|
:data="loadData"
|
|
:data="loadData"
|
|
- :scroll="{ x: 1370, y: tableHeight }"
|
|
|
|
|
|
+ :scroll="{ x: 1330, y: tableHeight }"
|
|
bordered>
|
|
bordered>
|
|
<!-- 散件退货单号 -->
|
|
<!-- 散件退货单号 -->
|
|
<template slot="sparePartsReturnNo" slot-scope="text, record">
|
|
<template slot="sparePartsReturnNo" slot-scope="text, record">
|
|
@@ -82,7 +82,7 @@
|
|
<a-button
|
|
<a-button
|
|
size="small"
|
|
size="small"
|
|
type="link"
|
|
type="link"
|
|
- v-if="record.state != 'FINISH' && $hasPermissions('B_bulkReturnGoodsEdit')"
|
|
|
|
|
|
+ v-if="(record.state == 'WAIT_SUBMIT' || record.state == 'AUDIT_REJECT') && $hasPermissions('B_bulkReturnGoodsEdit')"
|
|
@click="handleEdit(record)"
|
|
@click="handleEdit(record)"
|
|
class="button-info"
|
|
class="button-info"
|
|
id="bulkReturnGoodsList-edit-btn">编辑</a-button>
|
|
id="bulkReturnGoodsList-edit-btn">编辑</a-button>
|
|
@@ -96,11 +96,18 @@
|
|
<a-button
|
|
<a-button
|
|
size="small"
|
|
size="small"
|
|
type="link"
|
|
type="link"
|
|
- v-if="record.state != 'FINISH' && $hasPermissions('B_bulkReturnGoodsDel')"
|
|
|
|
|
|
+ v-if="record.state == 'WAIT_AUDIT' && $hasPermissions('B_bulkReturnGoodsAudit')"
|
|
|
|
+ @click="handleEexamine(record)"
|
|
|
|
+ class="button-primary"
|
|
|
|
+ id="bulkReturnGoodsList-warehouse-btn">审核</a-button>
|
|
|
|
+ <a-button
|
|
|
|
+ size="small"
|
|
|
|
+ type="link"
|
|
|
|
+ v-if="(record.state == 'WAIT_SUBMIT' || record.state == 'AUDIT_REJECT') && $hasPermissions('B_bulkReturnGoodsDel')"
|
|
@click="handleDel(record)"
|
|
@click="handleDel(record)"
|
|
class="button-error"
|
|
class="button-error"
|
|
id="bulkReturnGoodsList-del-btn">删除</a-button>
|
|
id="bulkReturnGoodsList-del-btn">删除</a-button>
|
|
- <span v-if="!(record.state != 'FINISH' && $hasPermissions('B_bulkReturnGoodsEdit')) && !(record.state == 'WAIT_OUT_WAREHOUSE' && $hasPermissions('B_bulkReturnGoodsOutStock')) && !(record.state != 'FINISH' && $hasPermissions('B_bulkReturnGoodsDel'))">--</span>
|
|
|
|
|
|
+ <span v-if="!((record.state == 'WAIT_SUBMIT' || record.state == 'AUDIT_REJECT') && ($hasPermissions('B_bulkReturnGoodsEdit') || $hasPermissions('B_bulkReturnGoodsDel'))) && !(record.state == 'WAIT_OUT_WAREHOUSE' && $hasPermissions('B_bulkReturnGoodsOutStock')) && !(record.state == 'WAIT_AUDIT' && $hasPermissions('B_bulkReturnGoodsAudit'))">--</span>
|
|
</template>
|
|
</template>
|
|
</s-table>
|
|
</s-table>
|
|
</a-spin>
|
|
</a-spin>
|
|
@@ -108,6 +115,8 @@
|
|
<basic-info-modal :openModal="openModal" @ok="handleOk" @close="openModal=false" />
|
|
<basic-info-modal :openModal="openModal" @ok="handleOk" @close="openModal=false" />
|
|
<!-- 详情 -->
|
|
<!-- 详情 -->
|
|
<bulkReturnGoods-detail-modal :openModal="openDetailModal" :itemSn="itemSn" :isGrab="isGrab" @close="handleDetailClose" />
|
|
<bulkReturnGoods-detail-modal :openModal="openDetailModal" :itemSn="itemSn" :isGrab="isGrab" @close="handleDetailClose" />
|
|
|
|
+ <!-- 审核 -->
|
|
|
|
+ <auditModal :openModal="visibleAudit" :spinning="spinningAudit" @close="visibleAudit=false" @ok="auditOrder(true)" @fail="auditOrder(false)" />
|
|
</a-card>
|
|
</a-card>
|
|
</template>
|
|
</template>
|
|
|
|
|
|
@@ -116,10 +125,11 @@ import { STable, VSelect } from '@/components'
|
|
import basicInfoModal from './basicInfoModal.vue'
|
|
import basicInfoModal from './basicInfoModal.vue'
|
|
import bulkReturnGoodsDetailModal from './detailModal.vue'
|
|
import bulkReturnGoodsDetailModal from './detailModal.vue'
|
|
import rangeDate from '@/views/common/rangeDate.vue'
|
|
import rangeDate from '@/views/common/rangeDate.vue'
|
|
|
|
+import auditModal from '@/views/common/auditModal.vue'
|
|
import { supplierAllList } from '@/api/supplier'
|
|
import { supplierAllList } from '@/api/supplier'
|
|
-import { sparePartsRetList, sparePartsRetDel, sparePartsRetOutStock } from '@/api/sparePartsRet'
|
|
|
|
|
|
+import { sparePartsRetList, sparePartsRetDel, sparePartsRetOutStock, sparePartsRetAudit } from '@/api/sparePartsRet'
|
|
export default {
|
|
export default {
|
|
- components: { STable, VSelect, basicInfoModal, rangeDate, bulkReturnGoodsDetailModal },
|
|
|
|
|
|
+ components: { STable, VSelect, basicInfoModal, rangeDate, bulkReturnGoodsDetailModal, auditModal },
|
|
data () {
|
|
data () {
|
|
return {
|
|
return {
|
|
spinning: false,
|
|
spinning: false,
|
|
@@ -147,7 +157,7 @@ export default {
|
|
{ title: '财务状态', dataIndex: 'settleStateDictValue', width: 100, align: 'center', customRender: function (text) { return text || '--' } },
|
|
{ title: '财务状态', dataIndex: 'settleStateDictValue', width: 100, align: 'center', customRender: function (text) { return text || '--' } },
|
|
{ title: '创建时间', dataIndex: 'createDate', width: 140, align: 'center', customRender: function (text) { return text || '--' } },
|
|
{ title: '创建时间', dataIndex: 'createDate', width: 140, align: 'center', customRender: function (text) { return text || '--' } },
|
|
{ title: '出库时间', dataIndex: 'outStockTime', width: 140, align: 'center', customRender: function (text) { return text || '--' } },
|
|
{ title: '出库时间', dataIndex: 'outStockTime', width: 140, align: 'center', customRender: function (text) { return text || '--' } },
|
|
- { title: '操作', scopedSlots: { customRender: 'action' }, width: 140, align: 'center', fixed: 'right' }
|
|
|
|
|
|
+ { title: '操作', scopedSlots: { customRender: 'action' }, width: 100, align: 'center', fixed: 'right' }
|
|
],
|
|
],
|
|
// 加载数据方法 必须为 Promise 对象
|
|
// 加载数据方法 必须为 Promise 对象
|
|
loadData: parameter => {
|
|
loadData: parameter => {
|
|
@@ -166,7 +176,10 @@ export default {
|
|
openModal: false, // 基本信息弹框是否显示
|
|
openModal: false, // 基本信息弹框是否显示
|
|
openDetailModal: false,
|
|
openDetailModal: false,
|
|
itemSn: null,
|
|
itemSn: null,
|
|
- isGrab: null
|
|
|
|
|
|
+ isGrab: null,
|
|
|
|
+ visibleAudit: false,
|
|
|
|
+ auditInfo: null,
|
|
|
|
+ spinningAudit: false
|
|
}
|
|
}
|
|
},
|
|
},
|
|
methods: {
|
|
methods: {
|
|
@@ -250,6 +263,28 @@ export default {
|
|
}
|
|
}
|
|
})
|
|
})
|
|
},
|
|
},
|
|
|
|
+ // 审核
|
|
|
|
+ handleEexamine (row) {
|
|
|
|
+ this.auditInfo = row
|
|
|
|
+ this.visibleAudit = true
|
|
|
|
+ },
|
|
|
|
+ auditOrder (billStatus) {
|
|
|
|
+ this.spinningAudit = true
|
|
|
|
+ sparePartsRetAudit({
|
|
|
|
+ sparePartsReturnSnList: [ this.auditInfo.sparePartsReturnSn ],
|
|
|
|
+ auditFlag: billStatus
|
|
|
|
+ }).then(res => {
|
|
|
|
+ if (res.status == 200) {
|
|
|
|
+ this.visibleAudit = false
|
|
|
|
+ this.$message.success(res.message)
|
|
|
|
+ this.$refs.table.refresh()
|
|
|
|
+ this.spinningAudit = false
|
|
|
|
+ } else {
|
|
|
|
+ this.visibleAudit = false
|
|
|
|
+ this.spinningAudit = false
|
|
|
|
+ }
|
|
|
|
+ })
|
|
|
|
+ },
|
|
handleDetailClose () {
|
|
handleDetailClose () {
|
|
this.itemSn = null
|
|
this.itemSn = null
|
|
this.isGrab = null
|
|
this.isGrab = null
|