parent
b1344614b4
commit
ae7ea6ce64
@ -0,0 +1,174 @@
|
||||
<template>
|
||||
<el-dialog title="选择对账单" :close-on-click-modal="false" :visible.sync="visible" class="JNPF-dialog JNPF-dialog_center"
|
||||
lock-scroll append-to-body width="800px">
|
||||
<el-row class="JNPF-common-search-box" :gutter="16">
|
||||
<el-form @submit.native.prevent>
|
||||
<el-col :span="10">
|
||||
<el-form-item label="关键词">
|
||||
<el-input v-model="keyword" placeholder="请输入关键词查询" clearable @keyup.enter.native="search()" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<el-form-item>
|
||||
<el-button type="primary" icon="el-icon-search" @click="search()">{{ $t('common.search') }}
|
||||
</el-button>
|
||||
<el-button icon="el-icon-refresh-right" @click="refresh()">{{ $t('common.reset') }}
|
||||
</el-button>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-form>
|
||||
<div class="JNPF-common-search-box-right">
|
||||
<el-tooltip effect="dark" :content="$t('common.refresh')" placement="top">
|
||||
<el-link icon="icon-ym icon-ym-Refresh JNPF-common-head-icon" :underline="false" @click="search()" />
|
||||
</el-tooltip>
|
||||
</div>
|
||||
</el-row>
|
||||
<JNPF-table v-loading="listLoading" :data="list" hasC @selection-change="handleSelectionChange" :border="false">
|
||||
<el-table-column prop="code" label="单据编号" align="center" width="200">
|
||||
</el-table-column>
|
||||
<el-table-column label="类型" prop="type" align="center" width="200">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.type}}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="businessType" label="业务类型" width="150" align="center">
|
||||
<template slot-scope="scope" v-if="!scope.row.top">
|
||||
<el-tag type="warning" v-if="scope.row.businessType==1">采购订单</el-tag>
|
||||
<el-tag type="success" v-else-if="scope.row.businessType==2">采购退供</el-tag>
|
||||
<el-tag type="danger" v-else-if="scope.row.businessType==3">销售订单</el-tag>
|
||||
<el-tag type="info" v-else-if="scope.row.businessType==4">销售退供</el-tag>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="settlementSubjectName" label="结算主体名称" align="center" width="250">
|
||||
</el-table-column>
|
||||
<el-table-column prop="docmentNum" label="单据数" align="center" width="150">
|
||||
</el-table-column>
|
||||
<el-table-column prop="settlementAmount" label="应收/应付合计(含税)" align="center" width="150">
|
||||
</el-table-column>
|
||||
<!-- <el-table-column prop="paymentAmount" label="已付金额" align="center" width="150">
|
||||
</el-table-column>
|
||||
<el-table-column prop="prepaidDeductionAmount" label="预付抵扣" align="center" width="150">
|
||||
</el-table-column>
|
||||
<el-table-column prop="returnAmount" label="退回金额" align="center" width="150">
|
||||
</el-table-column> -->
|
||||
<el-table-column prop="payableAmount" label="应结金额" align="center" width="150">
|
||||
</el-table-column>
|
||||
<el-table-column prop="settledAmount" label="已结金额" align="center" width="150">
|
||||
</el-table-column>
|
||||
<el-table-column prop="settlableAmount" label="可结金额" align="center" width="150">
|
||||
</el-table-column>
|
||||
</JNPF-table>
|
||||
<pagination :total="total" :page.sync="listQuery.currentPage" :limit.sync="listQuery.pageSize" @pagination="init" />
|
||||
<span slot="footer" class="dialog-footer">
|
||||
<el-button @click="visible = false">{{ $t('common.cancelButton') }}</el-button>
|
||||
<el-button type="primary" @click="select()">{{ $t('common.confirmButton') }}</el-button>
|
||||
</span>
|
||||
</el-dialog>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import request from '@/utils/request'
|
||||
import {
|
||||
GoodsList
|
||||
} from '@/api/extend/order'
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
visible: false,
|
||||
listLoading: true,
|
||||
keyword: '',
|
||||
list: [],
|
||||
total: 0,
|
||||
listQuery: {
|
||||
superQueryJson: '',
|
||||
currentPage: 1,
|
||||
pageSize: 20,
|
||||
sort: "desc",
|
||||
sidx: "",
|
||||
},
|
||||
excludeIdList: [],
|
||||
subjectId: '',
|
||||
contractId: '',
|
||||
checked: []
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
init(excludeIdList, subjectId, contractId) {
|
||||
this.visible = true
|
||||
this.listLoading = true
|
||||
if (excludeIdList && excludeIdList instanceof Array) {
|
||||
this.excludeIdList = excludeIdList;
|
||||
}
|
||||
if (subjectId && typeof(subjectId) == 'string') {
|
||||
this.subjectId = subjectId;
|
||||
}
|
||||
if (contractId && typeof(contractId) == 'string') {
|
||||
this.contractId = contractId;
|
||||
}
|
||||
let query = {
|
||||
...this.listQuery,
|
||||
keyword: this.keyword,
|
||||
excludeIdList: this.excludeIdList,
|
||||
subjectId: this.subjectId,
|
||||
contractId: this.contractId,
|
||||
dataType: 0,
|
||||
menuId: '532534180186188741',
|
||||
queryFlowTaskPass: '1'//查询审批通过的
|
||||
}
|
||||
/* GoodsList(query).then(res => {
|
||||
this.list = res.data.list
|
||||
this.listLoading = false
|
||||
}) */
|
||||
request({
|
||||
url: `/api/scm/Cwsettlement/getList`,
|
||||
method: 'post',
|
||||
data: query
|
||||
}).then(res => {
|
||||
this.list = res.data.list
|
||||
this.listLoading = false
|
||||
this.total = res.data.pagination.total
|
||||
})
|
||||
},
|
||||
refresh() {
|
||||
this.keyword = ''
|
||||
this.listQuery.currentPage = 1
|
||||
this.listQuery.pageSize = 20
|
||||
this.listQuery.sort = "desc"
|
||||
this.listQuery.sidx = ""
|
||||
this.init()
|
||||
},
|
||||
search() {
|
||||
this.listQuery.currentPage = 1
|
||||
this.listQuery.pageSize = 20
|
||||
this.listQuery.sort = "desc"
|
||||
this.listQuery.sidx = ""
|
||||
this.init()
|
||||
},
|
||||
select() {
|
||||
if (!this.checked.length) return
|
||||
this.visible = false
|
||||
this.$emit('refreshDataList', this.checked)
|
||||
},
|
||||
handleSelectionChange(val) {
|
||||
this.checked = val
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
>>>.el-dialog__body {
|
||||
height: 70vh;
|
||||
padding: 0 0 10px !important;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
overflow: hidden;
|
||||
|
||||
.JNPF-common-search-box {
|
||||
margin-bottom: 0;
|
||||
|
||||
.JNPF-common-search-box-right {
|
||||
padding: 10px 10px 0 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
Loading…
Reference in new issue