|
@@ -20,19 +20,19 @@
|
|
|
<supplier v-model="queryParam.supplierSn" isPermission placeholder="请输入供应商名称"></supplier>
|
|
|
</a-form-item>
|
|
|
</a-col>
|
|
|
- <template v-if="advanced">
|
|
|
- <a-col :md="6" :sm="24">
|
|
|
- <a-form-item label="退货原因">
|
|
|
- <v-select
|
|
|
- v-model="queryParam.returnReason"
|
|
|
- ref="returnReason"
|
|
|
- id="purchaseReturn-returnReason"
|
|
|
- code="SPARE_PARTS_RETURN_REASON"
|
|
|
- placeholder="请选择退货原因"
|
|
|
- allowClear></v-select>
|
|
|
- </a-form-item>
|
|
|
- </a-col>
|
|
|
- <a-col :md="6" :sm="24" v-show="isShowWarehouse">
|
|
|
+ <template v-if="advanced">
|
|
|
+ <a-col :md="6" :sm="24">
|
|
|
+ <a-form-item label="退货原因">
|
|
|
+ <v-select
|
|
|
+ v-model="queryParam.returnReason"
|
|
|
+ ref="returnReason"
|
|
|
+ id="purchaseReturn-returnReason"
|
|
|
+ code="SPARE_PARTS_RETURN_REASON"
|
|
|
+ placeholder="请选择退货原因"
|
|
|
+ allowClear></v-select>
|
|
|
+ </a-form-item>
|
|
|
+ </a-col>
|
|
|
+ <a-col :md="6" :sm="24" v-show="isShowWarehouse">
|
|
|
<a-form-item label="退货仓库">
|
|
|
<warehouse
|
|
|
v-model="queryParam.warehouseSn"
|
|
@@ -42,18 +42,18 @@
|
|
|
/>
|
|
|
</a-form-item>
|
|
|
</a-col>
|
|
|
- <a-col :md="6" :sm="24">
|
|
|
- <a-form-item label="业务状态">
|
|
|
- <v-select
|
|
|
- v-model="queryParam.state"
|
|
|
- ref="state"
|
|
|
- id="purchaseReturn-state"
|
|
|
- code="SPARE_PARTS_RETURN_STATE"
|
|
|
- placeholder="请选择审核状态"
|
|
|
- allowClear
|
|
|
- ></v-select>
|
|
|
- </a-form-item>
|
|
|
- </a-col>
|
|
|
+ <a-col :md="6" :sm="24">
|
|
|
+ <a-form-item label="业务状态">
|
|
|
+ <v-select
|
|
|
+ v-model="queryParam.state"
|
|
|
+ ref="state"
|
|
|
+ id="purchaseReturn-state"
|
|
|
+ code="SPARE_PARTS_RETURN_STATE"
|
|
|
+ placeholder="请选择审核状态"
|
|
|
+ allowClear
|
|
|
+ ></v-select>
|
|
|
+ </a-form-item>
|
|
|
+ </a-col>
|
|
|
</template>
|
|
|
<a-col :md="6" :sm="24">
|
|
|
<span class="table-page-search-submitButtons">
|
|
@@ -78,11 +78,11 @@
|
|
|
</a-form>
|
|
|
</div>
|
|
|
</a-card>
|
|
|
- <a-card size="small" :bordered="false" class="bulkWarehousingOrderList-wrap">
|
|
|
- <a-spin :spinning="spinning" tip="Loading...">
|
|
|
- <!-- 操作按钮 -->
|
|
|
- <div class="table-operator">
|
|
|
- <a-button v-if="$hasPermissions('B_purchaseReturnAdd')" id="bulkWarehousingOrderList-add" type="primary" class="button-error" @click="handleAdd">新增</a-button>
|
|
|
+ <a-card size="small" :bordered="false" class="bulkWarehousingOrderList-wrap">
|
|
|
+ <a-spin :spinning="spinning" tip="Loading...">
|
|
|
+ <!-- 操作按钮 -->
|
|
|
+ <div class="table-operator">
|
|
|
+ <a-button v-if="$hasPermissions('B_purchaseReturnAdd')" id="bulkWarehousingOrderList-add" type="primary" class="button-error" @click="handleAdd">新增</a-button>
|
|
|
<!-- <a-button
|
|
|
style="margin-left: 10px"
|
|
|
type="primary"
|
|
@@ -91,74 +91,74 @@
|
|
|
:disabled="disabled"
|
|
|
:loading="exportLoading"
|
|
|
>同步到ERP</a-button> -->
|
|
|
- </div>
|
|
|
- <!-- 列表 -->
|
|
|
- <s-table
|
|
|
- class="sTable fixPagination"
|
|
|
- ref="table"
|
|
|
- :style="{ height: tableHeight+70+'px' }"
|
|
|
- size="small"
|
|
|
- :rowKey="(record) => record.sparePartsReturnNo"
|
|
|
- :columns="columns"
|
|
|
- :data="loadData"
|
|
|
- :pageSize="30"
|
|
|
- :scroll="{ y: tableHeight }"
|
|
|
- :defaultLoadData="false"
|
|
|
- bordered>
|
|
|
- <!-- 采购退货单号 -->
|
|
|
- <template slot="sparePartsReturnNo" slot-scope="text, record">
|
|
|
- <span v-if="$hasPermissions('B_purchaseReturnDetail')" class="link-bule" @click="handleDetail(record)">{{ record.sparePartsReturnNo }}</span>
|
|
|
- <span v-else>{{ record.sparePartsReturnNo }}</span>
|
|
|
- </template>
|
|
|
- <!-- 操作 -->
|
|
|
- <!-- state 待提交 WAIT_SUBMIT 待审核 WAIT_AUDIT 已完结 FINISH 审核不通过 AUDIT_REJECT -->
|
|
|
- <template slot="action" slot-scope="text, record">
|
|
|
- <a-button
|
|
|
- size="small"
|
|
|
- type="link"
|
|
|
- v-if="$hasPermissions('B_purchaseReturnEdit') && record.state == 'WAIT_SUBMIT'"
|
|
|
- @click="handleEdit(record)"
|
|
|
- class="button-info"
|
|
|
- id="bulkWarehousingOrderList-edit-btn">编辑</a-button>
|
|
|
- <a-button
|
|
|
- size="small"
|
|
|
- type="link"
|
|
|
- class="button-warning"
|
|
|
- @click="handleSH(record)"
|
|
|
- v-if="$hasPermissions('B_purchaseReturnRate') && record.state !='WAIT_SUBMIT'"
|
|
|
- id="allocateBillList-examine-btn">审核进度</a-button>
|
|
|
- <!-- <a-button
|
|
|
+ </div>
|
|
|
+ <!-- 列表 -->
|
|
|
+ <s-table
|
|
|
+ class="sTable fixPagination"
|
|
|
+ ref="table"
|
|
|
+ :style="{ height: tableHeight+70+'px' }"
|
|
|
+ size="small"
|
|
|
+ :rowKey="(record) => record.sparePartsReturnNo"
|
|
|
+ :columns="columns"
|
|
|
+ :data="loadData"
|
|
|
+ :pageSize="30"
|
|
|
+ :scroll="{ y: tableHeight }"
|
|
|
+ :defaultLoadData="false"
|
|
|
+ bordered>
|
|
|
+ <!-- 采购退货单号 -->
|
|
|
+ <template slot="sparePartsReturnNo" slot-scope="text, record">
|
|
|
+ <span v-if="$hasPermissions('B_purchaseReturnDetail')" class="link-bule" @click="handleDetail(record)">{{ record.sparePartsReturnNo }}</span>
|
|
|
+ <span v-else>{{ record.sparePartsReturnNo }}</span>
|
|
|
+ </template>
|
|
|
+ <!-- 操作 -->
|
|
|
+ <!-- state 待提交 WAIT_SUBMIT 待审核 WAIT_AUDIT 已完结 FINISH 审核不通过 AUDIT_REJECT -->
|
|
|
+ <template slot="action" slot-scope="text, record">
|
|
|
+ <a-button
|
|
|
+ size="small"
|
|
|
+ type="link"
|
|
|
+ v-if="$hasPermissions('B_purchaseReturnEdit') && record.state == 'WAIT_SUBMIT'"
|
|
|
+ @click="handleEdit(record)"
|
|
|
+ class="button-info"
|
|
|
+ id="bulkWarehousingOrderList-edit-btn">编辑</a-button>
|
|
|
+ <a-button
|
|
|
+ size="small"
|
|
|
+ type="link"
|
|
|
+ class="button-warning"
|
|
|
+ @click="handleSH(record)"
|
|
|
+ v-if="$hasPermissions('B_purchaseReturnRate') && record.state !='WAIT_SUBMIT'"
|
|
|
+ id="allocateBillList-examine-btn">审核进度</a-button>
|
|
|
+ <!-- <a-button
|
|
|
size="small"
|
|
|
type="link"
|
|
|
v-if="record.state == 'FINISH'"
|
|
|
@click="handleEdit(record)"
|
|
|
class="button-info"
|
|
|
id="bulkWarehousingOrderList-edit-btn">同步到ERP</a-button> -->
|
|
|
- <a-button
|
|
|
- size="small"
|
|
|
- type="link"
|
|
|
- v-if="$hasPermissions('B_purchaseReturnSubmit') && record.state == 'AUDIT_REJECT'"
|
|
|
- @click="handleResubmit(record)"
|
|
|
- class="button-info"
|
|
|
- id="bulkWarehousingOrderList-edit-btn">再次提交</a-button>
|
|
|
- <a-button
|
|
|
- size="small"
|
|
|
- type="link"
|
|
|
- v-if="$hasPermissions('B_purchaseReturnDel') && record.state == 'WAIT_SUBMIT'"
|
|
|
- @click="handleDel(record)"
|
|
|
- class="button-error"
|
|
|
- id="bulkWarehousingOrderList-del-btn">删除</a-button>
|
|
|
- </template>
|
|
|
- </s-table>
|
|
|
- </a-spin>
|
|
|
- <!-- 新增、详情弹窗-->
|
|
|
- <add-modal v-drag :openModal="openModal" @ok="handleOk" @close="openModal=false" />
|
|
|
- <detailModal v-drag :openModal="openDetailModal" :itemSn="itemSn" @close="closeDetailModal" />
|
|
|
- <!-- 导出提示框 -->
|
|
|
- <reportModal :visible="showExport" @close="showExport=false"></reportModal>
|
|
|
- <!-- 审核进度弹窗 -->
|
|
|
- <reviewProgressModal v-drag :itemSn="itemSnSh" :auditTime="auditTime" :openModal="openReviewModal" @close="openReviewModal=false"></reviewProgressModal>
|
|
|
- </a-card>
|
|
|
+ <a-button
|
|
|
+ size="small"
|
|
|
+ type="link"
|
|
|
+ v-if="$hasPermissions('B_purchaseReturnSubmit') && record.state == 'AUDIT_REJECT'"
|
|
|
+ @click="handleResubmit(record)"
|
|
|
+ class="button-info"
|
|
|
+ id="bulkWarehousingOrderList-edit-btn">再次提交</a-button>
|
|
|
+ <a-button
|
|
|
+ size="small"
|
|
|
+ type="link"
|
|
|
+ v-if="$hasPermissions('B_purchaseReturnDel') && record.state == 'WAIT_SUBMIT'"
|
|
|
+ @click="handleDel(record)"
|
|
|
+ class="button-error"
|
|
|
+ id="bulkWarehousingOrderList-del-btn">删除</a-button>
|
|
|
+ </template>
|
|
|
+ </s-table>
|
|
|
+ </a-spin>
|
|
|
+ <!-- 新增、详情弹窗-->
|
|
|
+ <add-modal v-drag :openModal="openModal" @ok="handleOk" @close="openModal=false" />
|
|
|
+ <detailModal v-drag :openModal="openDetailModal" :itemSn="itemSn" @close="closeDetailModal" />
|
|
|
+ <!-- 导出提示框 -->
|
|
|
+ <reportModal :visible="showExport" @close="showExport=false"></reportModal>
|
|
|
+ <!-- 审核进度弹窗 -->
|
|
|
+ <reviewProgressModal v-drag :itemSn="itemSnSh" :auditTime="auditTime" :openModal="openReviewModal" @close="openReviewModal=false"></reviewProgressModal>
|
|
|
+ </a-card>
|
|
|
</div>
|
|
|
</template>
|
|
|
|
|
@@ -225,7 +225,7 @@ export default {
|
|
|
},
|
|
|
computed: {
|
|
|
columns () {
|
|
|
- let _this=this
|
|
|
+ const _this = this
|
|
|
const arr = [
|
|
|
{ title: '序号', dataIndex: 'no', width: '5%', align: 'center' },
|
|
|
{ title: '创建时间', dataIndex: 'createDate', width: '8%', align: 'center', customRender: function (text) { return text || '--' } },
|
|
@@ -237,8 +237,8 @@ export default {
|
|
|
{ title: '审核状态', dataIndex: 'stateDictValue', width: '8%', align: 'center', customRender: function (text) { return text || '--' } },
|
|
|
{ title: '操作', scopedSlots: { customRender: 'action' }, width: '10%', align: 'center' }
|
|
|
]
|
|
|
- if(this.isShowWarehouse){
|
|
|
- arr.splice(5,0,{ title: '退货仓库', dataIndex: 'warehouseName', width: '10%', align: 'center', customRender: function (text) { return text || '--' } },)
|
|
|
+ if (this.isShowWarehouse) {
|
|
|
+ arr.splice(5, 0, { title: '退货仓库', dataIndex: 'warehouseName', width: '10%', align: 'center', customRender: function (text) { return text || '--' } })
|
|
|
}
|
|
|
if (this.$hasPermissions('M_purchaseReturnList_costPrice')) { // 售价权限
|
|
|
arr.splice(7, 0, { title: '退货金额', dataIndex: 'totalCost', width: '8%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text, 2) : '--') } })
|
|
@@ -275,7 +275,11 @@ export default {
|
|
|
},
|
|
|
// 编辑
|
|
|
handleEdit (row) {
|
|
|
- this.$router.push({ name: 'purchaseReturnEdit', query: { returnSn: row.sparePartsReturnSn, no: row.sparePartsReturnNo, sn: row.supplierSn } })
|
|
|
+ if (row.grabFlag == 0) {
|
|
|
+ this.$router.push({ name: 'purchaseReturnEdit', query: { returnSn: row.sparePartsReturnSn, no: row.sparePartsReturnNo, sn: row.supplierSn } })
|
|
|
+ } else {
|
|
|
+ this.$router.push({ name: 'purchaseReturnEditGrab', query: { returnSn: row.sparePartsReturnSn, no: row.sparePartsReturnNo, sn: row.supplierSn } })
|
|
|
+ }
|
|
|
},
|
|
|
// 审核进度
|
|
|
handleSH (row) {
|