Files
income_payments_enterprise_…/src/views/dataMember/DataMember.vue
T

268 lines
9.6 KiB
Vue

<template>
<div class="main-box">
<a-card :bordered="false">
<!--查询区域begin-->
<div class="table-page-search-wrapper">
<a-form layout="inline" @keyup.enter.native="searchQuery">
<a-row :gutter="24">
<a-col :xl="6" :lg="8" :md="8" :sm="24">
<a-form-item label="项目名称">
<a-input placeholder="请输入项目名称" v-model="queryParam.projectName" :maxLength="50"></a-input>
</a-form-item>
</a-col>
<a-col :xl="6" :lg="8" :md="8" :sm="24">
<a-form-item label="运行年份">
<j-year-date style="width:100%" placeholder="请选择运行年份" v-model="queryParam.particularYear"></j-year-date>
</a-form-item>
</a-col>
<!-- <a-col :xl="6" :lg="8" :md="8" :sm="24">-->
<!-- <a-form-item label="需要发票">-->
<!-- <j-dict-select-tag dict-code="invoice_type" placeholder="请选择是否需要发票"-->
<!-- v-model="queryParam.needInvoice"></j-dict-select-tag>-->
<!-- </a-form-item>-->
<!-- </a-col>-->
<!-- <a-col :xl="6" :lg="8" :md="8" :sm="24">-->
<!-- <a-form-item label="打包项目">-->
<!-- <j-dict-select-tag dict-code="yn" placeholder="请选择是否打包"-->
<!-- v-model="queryParam.pack"></j-dict-select-tag>-->
<!-- </a-form-item>-->
<!-- </a-col>-->
<a-col :xl="6" :lg="8" :md="8" :sm="24">
<span style="float: left;overflow: hidden;" class="table-page-search-submitButtons">
<a-button type="primary" @click="searchQuery" icon="search">查询</a-button>
<a-button class="reset-button" @click="searchReset" icon="reload" style="margin-left: 8px">重置</a-button>
</span>
</a-col>
</a-row>
</a-form>
</div>
<!--查询区域end-->
<!-- 表格区域-->
<div>
<!-- <a-spin :spinning="loading">-->
<!-- <project-table :column-data="columns" :table-data="dataSource" @change="handlePageChange">-->
<!-- &lt;!&ndash; 打包需要发票&ndash;&gt;-->
<!-- <template v-slot:status-pack="{record, text}">-->
<!-- <status-slot :statu-obj="record" :status-no="text"></status-slot>-->
<!-- </template>-->
<!-- &lt;!&ndash; 到账&ndash;&gt;-->
<!-- <template v-slot:status="{record, text}">-->
<!-- <status-slot :statu-obj="record" :status-no="text" :status-type="true"></status-slot>-->
<!-- </template>-->
<!-- &lt;!&ndash; 开票&ndash;&gt;-->
<!-- <template v-slot:status-bill="{record, text}">-->
<!-- <status-slot :statu-obj="record" :status-no="text" :status-type="true" status-key="bill"></status-slot>-->
<!-- </template>-->
<!-- &lt;!&ndash; 邮寄&ndash;&gt;-->
<!-- <template v-slot:status-mail="{record, text}">-->
<!-- <status-slot :statu-obj="record" :status-no="text" :status-type="true" status-key="mail"></status-slot>-->
<!-- </template>-->
<!-- &lt;!&ndash; 项目名称&ndash;&gt;-->
<!-- <template v-slot:projectName="{record}">-->
<!-- <div @click="openDetailModal(record)" class="project-name">-->
<!-- {{ record.chargeProject }}-->
<!-- </div>-->
<!-- </template>-->
<!-- &lt;!&ndash; 项目名称&ndash;&gt;-->
<!-- <template v-slot:projectName="{record}">-->
<!-- <div @click="openDetailModal(record)" class="project-name">-->
<!-- <j-ellipsis :value="record.projectName" :length="20"></j-ellipsis>-->
<!-- </div>-->
<!-- </template>-->
<!-- &lt;!&ndash; 需要tooltip的文本&ndash;&gt;-->
<!-- <template v-slot:text="{record,text}">-->
<!-- <a-tooltip>-->
<!-- <template slot="title">-->
<!-- {{ text }}-->
<!-- </template>-->
<!-- {{ text }}-->
<!-- </a-tooltip>-->
<!-- </template>-->
<!-- &lt;!&ndash; 金额&ndash;&gt;-->
<!-- <template v-slot:money="{record,text}">-->
<!-- <a-tooltip>-->
<!-- <template slot="title">-->
<!-- {{ text }}-->
<!-- </template>-->
<!-- {{ text }}-->
<!-- </a-tooltip>-->
<!-- </template>-->
<!-- </project-table>-->
<!-- </a-spin>-->
<a-table
ref="table"
rowKey="id"
size="middle"
:scroll="{x: 1200}"
:columns="columns"
:dataSource="dataSource"
:pagination="ipagination"
:loading="loading"
@change="handleTableChange"
class="j-table-force-nowrap">
<!-- 项目名称-->
<template slot="projectName" slot-scope="text, record">
<j-ellipsis :value="text" :length="20" class="project-name" @click="openDetailModal(record)"></j-ellipsis>
</template>
<template slot="text" slot-scope="text">
<j-ellipsis :value="text" :length="20"></j-ellipsis>
</template>
<!-- 缴费凭证-->
<span slot="action" class="action-span-cell" slot-scope="text,record">
<a @click="paymentVoucher(record)" :disabled="Number(record.amountReceivable) === 0 || $store.getters.userInfo.roleCode === '3'">申请开票</a>
</span>
</a-table>
</div>
<!-- 表格区域end-->
</a-card>
<project-detail-modal ref="projectDetail" @openContractModule="handleOpenContractModule"></project-detail-modal>
<mine-contract-module :contract-id="contractId" :visible.sync="contractModuleVisible" @openProjectDetail="openDetailModal"></mine-contract-module>
</div>
</template>
<script>
import JYearDate from '@comp/jero/JYearDate'
import { JeroListMixin } from '@/mixins/JeroListMixin'
// import ProjectTable from '@comp/table/ProjectTable'
import ProjectDetailModal from '@views/MessagePage/ProjectDetailModal'
// import StatusSlot from '@comp/tools/StatusSlot'
import JEllipsis from '@comp/jero/JEllipsis'
import MineContractModule from '@views/mineContract/modules/MineContractModule'
export default {
name: 'DataMember',
components: { ProjectDetailModal, JYearDate,JEllipsis, MineContractModule },
mixins: [JeroListMixin],
data() {
return {
columns: [
{
title: '序号',
dataIndex: '',
key: 'rowIndex',
width: 60,
align: 'center',
customRender: function (t, r, index) {
return parseInt(index) + 1
}
},
{
title: '项目名称',
dataIndex: 'projectName',
align: 'center',
scopedSlots: { customRender: 'projectName' }
}, {
title: '项目负责人',
dataIndex: 'directorName',
align: 'center',
scopedSlots: { customRender: 'text' }
},
{
title: '负责人电话',
dataIndex: 'phone',
align: 'center',
scopedSlots: { customRender: 'text' }
},
{
title: '负责人邮箱',
dataIndex: 'email',
align: 'center',
scopedSlots: { customRender: 'text' }
},
{
title: '缴费凭证状态',
dataIndex: 'paymentStatus_dictText',
align: 'center',
scopedSlots: { customRender: 'text' }
},
{
title: '操作',
dataIndex: 'action',
align: 'center',
fixed: 'right',
width: 100,
scopedSlots: { customRender: 'action' }
}
],
loading: false,
// 合同详情
contractModuleVisible: false,
queryParam:{
particularYear:this.getCurrentYear()
},
lastQueryParam:{
particularYear:this.getCurrentYear()
},
contractId: '',
url: {
list: '/jero/memberProjectSubitem/pageCompany'
}
}
},
methods: {
/**
* 分页变化获取数据
* @param pagination
*/
// handlePageChange(pagination) {
// this.ipagination.current = pagination.current
// this.ipagination.pageSize = pagination.pageSize
// this.loadData()
// },
/**
* 打开合同详情
* @param contractId
*/
handleOpenContractModule(contractId) {
this.contractId = contractId
this.contractModuleVisible = true
},
searchReset(){
this.queryParam = {}
this.lastQueryParam = {}
this.queryParam.particularYear = this.getCurrentYear()
this.lastQueryParam.particularYear = this.getCurrentYear()
this.loadData()
},
//获取当前年
getCurrentYear(){
return new Date().getFullYear()+''
},
/**
* 缴费凭证
* @param record
*/
paymentVoucher(record) {
this.$router.push({
path: '/MessagePage/PaymentVoucher',
query: {
projectId: record.id,
projectName: record.projectName,
projectType: 4
}
})
}
}
}
</script>
<style scoped lang="less">
@import '~@assets/less/common.less';
.project-name {
cursor: pointer;
font-size: 16px;
font-family: PingFang SC, PingFang SC-Bold;
font-weight: 700;
color: #069f99;
//overflow: hidden;
//word-break: keep-all;
//text-overflow: ellipsis;
}
</style>