普通项目管理
This commit is contained in:
@@ -84,9 +84,12 @@
|
||||
</template>
|
||||
|
||||
<!-- 打包、需要发票、到账、开票、邮寄状态-->
|
||||
<template slot="icon" slot-scope="text,record">
|
||||
<!-- <img v-if="text === 1">-->
|
||||
<!-- <img v-if="text === 2">-->
|
||||
<template slot="status" slot-scope="text,record">
|
||||
<status-slot :statu-obj="record" :status-no="text" :status-type="true"></status-slot>
|
||||
</template>
|
||||
|
||||
<template slot="status-pack" slot-scope="text,record">
|
||||
<status-slot :statu-obj="record" :status-no="text"></status-slot>
|
||||
</template>
|
||||
|
||||
<span slot="action" class="action-span-cell" slot-scope="text, record">
|
||||
@@ -106,10 +109,12 @@ import JYearDate from '@comp/jero/JYearDate'
|
||||
import GeneralProjectModule from './modules/GeneralProjectModule'
|
||||
import SelectPrincipal from '@comp/company/SelectPrincipal'
|
||||
import ProjectDetailModal from '@comp/ProjectDetailModal'
|
||||
import StatusSlot from '@comp/tools/StatusSlot'
|
||||
|
||||
|
||||
export default {
|
||||
name: 'GeneralProjectManagement',
|
||||
components: { JYearDate, GeneralProjectModule, SelectPrincipal, ProjectDetailModal },
|
||||
components: { JYearDate, GeneralProjectModule, SelectPrincipal, ProjectDetailModal, StatusSlot },
|
||||
mixins: [JeroListMixin],
|
||||
computed: {
|
||||
importExcelUrl: function(){
|
||||
@@ -180,28 +185,32 @@ export default {
|
||||
title: '打包',
|
||||
align: 'center',
|
||||
width: 80,
|
||||
dataIndex: 'pack'
|
||||
dataIndex: 'pack',
|
||||
scopedSlots: { customRender: 'status-pack' }
|
||||
}, {
|
||||
title: '需要发票',
|
||||
align: 'center',
|
||||
width: 80,
|
||||
dataIndex: 'needInvoice',
|
||||
// scopedSlots: { customRender: 'icon' }
|
||||
scopedSlots: { customRender: 'status-pack' }
|
||||
}, {
|
||||
title: '到账',
|
||||
align: 'center',
|
||||
width: 80,
|
||||
dataIndex: 'inAccount'
|
||||
dataIndex: 'inAccount',
|
||||
scopedSlots: { customRender: 'status' }
|
||||
}, {
|
||||
title: '开票',
|
||||
align: 'center',
|
||||
width: 80,
|
||||
dataIndex: 'makeInvoice'
|
||||
dataIndex: 'makeInvoice',
|
||||
scopedSlots: { customRender: 'status' }
|
||||
}, {
|
||||
title: '邮寄',
|
||||
align: 'center',
|
||||
width: 80,
|
||||
dataIndex: 'mail'
|
||||
dataIndex: 'mail',
|
||||
scopedSlots: { customRender: 'status' }
|
||||
}, {
|
||||
title: '操作',
|
||||
dataIndex: 'action',
|
||||
@@ -217,6 +226,21 @@ export default {
|
||||
deleteBatch: '/project/payCommonProject/deleteBatch'
|
||||
}
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
/*
|
||||
* 打开项目详情模态框
|
||||
* */
|
||||
openDetailModal(record){
|
||||
console.log(record)
|
||||
const basicInfo = {
|
||||
principalName: record.principalName,
|
||||
receivableAmount: record.receivableAmount,
|
||||
remarks: record.remarks
|
||||
}
|
||||
this.$refs.basicInfo = basicInfo
|
||||
this.$refs.projectDetail.open(record)
|
||||
},
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
@@ -58,6 +58,7 @@
|
||||
<a-col :xl="12" :sm="24">
|
||||
<a-form-item label="联系人" :labelCol="labelCol" :wrapperCol="wrapperCol">
|
||||
<select-contacts :selected-company="selectedCompany"
|
||||
:initf-contacts="selectedContact"
|
||||
placeholder="请选择联系人"
|
||||
v-decorator="['contactsId',validatorRules.contactsId]"
|
||||
:maxLength='50'
|
||||
@@ -68,6 +69,7 @@
|
||||
<a-col :xl="12" :sm="24">
|
||||
<a-form-item label="邮寄联系人" :labelCol="labelCol" :wrapperCol="wrapperCol">
|
||||
<select-contacts :selected-company="selectedCompany"
|
||||
:initf-contacts="selectedMailContact"
|
||||
placeholder="请选择邮寄联系人"
|
||||
v-decorator="['mailContactsId',validatorRules.mailContactsId]"
|
||||
:maxLength='50'
|
||||
@@ -239,7 +241,9 @@ export default {
|
||||
}
|
||||
},
|
||||
chargeWayType: null,
|
||||
selectedCompany: null,
|
||||
selectedCompany: null, // 当前选中的企业
|
||||
selectedContact: null, // 编辑时的联系人
|
||||
selectedMailContact: null, // 编辑时的邮寄联系人
|
||||
url: {
|
||||
add: '/project/payCommonProject/add',
|
||||
edit: '/project/payCommonProject/edit'
|
||||
@@ -251,16 +255,24 @@ export default {
|
||||
this.edit({})
|
||||
},
|
||||
edit(record) {
|
||||
console.log(record)
|
||||
record.chargeCompany = {
|
||||
id: record.chargeCompanyId,
|
||||
companyName: record.chargeCompanyName
|
||||
companyName: record.chargeCompanyTemporaryName
|
||||
}
|
||||
console.log(record.chargeCompany)
|
||||
// 回显选中的企业
|
||||
this.selectedCompany = record.chargeCompany
|
||||
this.form.resetFields()
|
||||
this.model = Object.assign({}, record)
|
||||
if (this.model.id) {
|
||||
this.selectedContact = {
|
||||
id: this.model.contactsTemporaryId,
|
||||
name: this.model.contactsTemporaryName
|
||||
}
|
||||
this.selectedMailContact = {
|
||||
id: this.model.mailContactsTemporaryId,
|
||||
name: this.model.mailContactsTemporaryName
|
||||
}
|
||||
}
|
||||
this.chargeWayType = record.chargeWay
|
||||
this.visible = true
|
||||
this.$nextTick(() => {
|
||||
@@ -318,9 +330,7 @@ export default {
|
||||
* @param value
|
||||
*/
|
||||
companyChange(value) {
|
||||
console.log(1)
|
||||
this.selectedCompany = value
|
||||
console.log(this.model.contactsId, this.model.mailContactsId)
|
||||
this.model.contactsId = undefined
|
||||
this.model.mailContactsId = undefined
|
||||
this.$nextTick(() => {
|
||||
|
||||
Reference in New Issue
Block a user