bug修改
This commit is contained in:
@@ -34,8 +34,8 @@
|
|||||||
@change="handleImportExcel" v-has="'company:import'">
|
@change="handleImportExcel" v-has="'company:import'">
|
||||||
<a-button type="primary" icon="import">导入</a-button>
|
<a-button type="primary" icon="import">导入</a-button>
|
||||||
</a-upload>
|
</a-upload>
|
||||||
<a-button type="primary" icon="export" @click="handleExportXls('企业管理')" v-has="'company:export'">导出</a-button>
|
<a-button type="primary" icon="export" @click="handleExportXls('单位/开票信息')" v-has="'company:export'">导出</a-button>
|
||||||
<a-button type="primary" icon="download" @click="downTemplate('企业管理导入模板')" v-has="'company:downTemplate'">下载模板</a-button>
|
<a-button type="primary" icon="download" @click="downTemplate('单位/开票信息导入模板')" v-has="'company:downTemplate'">下载模板</a-button>
|
||||||
<a-button type="danger" icon="delete" @click="batchDel" v-has="'company:batchDel'">批量删除</a-button>
|
<a-button type="danger" icon="delete" @click="batchDel" v-has="'company:batchDel'">批量删除</a-button>
|
||||||
</div>
|
</div>
|
||||||
<!-- 操作按钮区域-end-->
|
<!-- 操作按钮区域-end-->
|
||||||
|
|||||||
@@ -36,7 +36,7 @@
|
|||||||
@change="handleSignedCompanyChange"></company-select>
|
@change="handleSignedCompanyChange"></company-select>
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
</a-col>
|
</a-col>
|
||||||
<a-col :xxl="6" :xl="8" :sm="12" style="margin-bottom: -5px">
|
<a-col :xxl="6" :xl="8" :sm="12" style="margin-bottom: 0">
|
||||||
<a-form-item label="签订联系人" :labelCol="labelCol" :wrapperCol="wrapperCol">
|
<a-form-item label="签订联系人" :labelCol="labelCol" :wrapperCol="wrapperCol">
|
||||||
<select-contacts placeholder="请选择签订联系人"
|
<select-contacts placeholder="请选择签订联系人"
|
||||||
:selected-company="selectedCompany"
|
:selected-company="selectedCompany"
|
||||||
|
|||||||
@@ -115,6 +115,7 @@ export default {
|
|||||||
this.form.resetFields()
|
this.form.resetFields()
|
||||||
this.model = Object.assign({}, record)
|
this.model = Object.assign({}, record)
|
||||||
this.visible = true
|
this.visible = true
|
||||||
|
console.log(this.model)
|
||||||
let date = new Date()
|
let date = new Date()
|
||||||
let sendDate = date.getFullYear() + '-' + (date.getMonth() + 1) + '-' + date.getDate()
|
let sendDate = date.getFullYear() + '-' + (date.getMonth() + 1) + '-' + date.getDate()
|
||||||
this.$nextTick(() => {
|
this.$nextTick(() => {
|
||||||
|
|||||||
@@ -118,12 +118,16 @@ export default {
|
|||||||
this.form.resetFields()
|
this.form.resetFields()
|
||||||
this.model = Object.assign({}, record)
|
this.model = Object.assign({}, record)
|
||||||
this.visible = true
|
this.visible = true
|
||||||
let date = new Date()
|
|
||||||
let sendDate = date.getFullYear() + '-' + (date.getMonth() + 1) + '-' + date.getDate()
|
|
||||||
this.$nextTick(() => {
|
this.$nextTick(() => {
|
||||||
this.form.setFieldsValue({'sendDate': sendDate})
|
|
||||||
this.form.setFieldsValue(pick(this.model, 'sendMethod', 'sendDate', 'postNo', 'remark'))
|
this.form.setFieldsValue(pick(this.model, 'sendMethod', 'sendDate', 'postNo', 'remark'))
|
||||||
})
|
})
|
||||||
|
if (!this.model.sendDate) {
|
||||||
|
let date = new Date()
|
||||||
|
let sendDate = date.getFullYear() + '-' + (date.getMonth() + 1) + '-' + date.getDate()
|
||||||
|
this.$nextTick(() => {
|
||||||
|
this.form.setFieldsValue({'sendDate': sendDate})
|
||||||
|
})
|
||||||
|
}
|
||||||
},
|
},
|
||||||
close() {
|
close() {
|
||||||
this.$emit('close')
|
this.$emit('close')
|
||||||
|
|||||||
@@ -65,10 +65,16 @@
|
|||||||
<!-- 操作按钮区域-->
|
<!-- 操作按钮区域-->
|
||||||
<div class="table-operator">
|
<div class="table-operator">
|
||||||
<a-button type="primary" icon="plus" @click="handlePack" v-has="'packProject:pack'">打包</a-button>
|
<a-button type="primary" icon="plus" @click="handlePack" v-has="'packProject:pack'">打包</a-button>
|
||||||
<a-button type="danger" icon="close-circle" @click="batchCancelPack" v-has="'packProject:batchCancelPack'">批量取消打包</a-button>
|
<a-button type="danger" icon="close-circle" @click="batchCancelPack" v-has="'packProject:batchCancelPack'">
|
||||||
<a-button type="primary" icon="pay-circle" @click="batchIncomePayment" v-has="'packProject:batchIncomePayment'">批量来款</a-button>
|
批量取消打包
|
||||||
<a-button type="primary" icon="file-text" @click="batchInvoicing" v-has="'packProject:batchInvoicing'">批量开票</a-button>
|
</a-button>
|
||||||
<a-button type="primary" icon="export" @click="handleExportXls('打包项目列表')" v-has="'packProject:export'">导出</a-button>
|
<a-button type="primary" icon="pay-circle" @click="batchIncomePayment" v-has="'packProject:batchIncomePayment'">
|
||||||
|
批量来款
|
||||||
|
</a-button>
|
||||||
|
<a-button type="primary" icon="file-text" @click="batchInvoicing" v-has="'packProject:batchInvoicing'">批量开票
|
||||||
|
</a-button>
|
||||||
|
<a-button type="primary" icon="export" @click="handleExportXls('打包项目列表')" v-has="'packProject:export'">导出
|
||||||
|
</a-button>
|
||||||
</div>
|
</div>
|
||||||
<!-- 操作按钮区域-end-->
|
<!-- 操作按钮区域-end-->
|
||||||
|
|
||||||
@@ -118,9 +124,11 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<span slot="action" class="action-span-cell" slot-scope="text, record">
|
<span slot="action" class="action-span-cell" slot-scope="text, record">
|
||||||
<a @click="incomePayment(record)" :disabled="Number(record.receivableAmount) === 0" v-has="'packProject:incomePayment'">来款</a>
|
<a @click="incomePayment(record)" :disabled="Number(record.receivableAmount) === 0"
|
||||||
|
v-has="'packProject:incomePayment'">来款</a>
|
||||||
<a @click="cancelPack(record.id)" v-has="'packProject:cancelPack'">取消打包</a>
|
<a @click="cancelPack(record.id)" v-has="'packProject:cancelPack'">取消打包</a>
|
||||||
<a @click="invoicing(record)" :disabled="record.needInvoice === 0 || Number(record.receivableAmount) === 0" v-has="'packProject:invoicing'">开票</a>
|
<a @click="invoicing(record)" :disabled="record.needInvoice === 0 || Number(record.receivableAmount) === 0"
|
||||||
|
v-has="'packProject:invoicing'">开票</a>
|
||||||
</span>
|
</span>
|
||||||
</a-table>
|
</a-table>
|
||||||
</div>
|
</div>
|
||||||
@@ -163,6 +171,9 @@
|
|||||||
:project-type="selectProjectType"
|
:project-type="selectProjectType"
|
||||||
:project-name="selectProjectName"
|
:project-name="selectProjectName"
|
||||||
@ok="modalFormOk"></invoicing-stage-module>
|
@ok="modalFormOk"></invoicing-stage-module>
|
||||||
|
|
||||||
|
<!-- 项目详情-->
|
||||||
|
<project-detail-modal ref="projectDetail"></project-detail-modal>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
@@ -178,6 +189,7 @@ import BatchInvoicingModule from './modules/BatchInvoicingModule'
|
|||||||
import ArriveStageModule from '../financialManagement/arriveAndInvoicing/modules/ArriveStageModule'
|
import ArriveStageModule from '../financialManagement/arriveAndInvoicing/modules/ArriveStageModule'
|
||||||
import InvoicingStageModule from '../financialManagement/arriveAndInvoicing/modules/InvoicingStageModule'
|
import InvoicingStageModule from '../financialManagement/arriveAndInvoicing/modules/InvoicingStageModule'
|
||||||
import { getPackCompanyById, batchRemovePackProject, removePackProject } from '../../api/incomePaymentsApi'
|
import { getPackCompanyById, batchRemovePackProject, removePackProject } from '../../api/incomePaymentsApi'
|
||||||
|
import ProjectDetailModal from '../../components/ProjectDetailModal'
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'PackProjectMaintenance',
|
name: 'PackProjectMaintenance',
|
||||||
@@ -189,7 +201,8 @@ export default {
|
|||||||
BatchIncomePaymentModule,
|
BatchIncomePaymentModule,
|
||||||
BatchInvoicingModule,
|
BatchInvoicingModule,
|
||||||
ArriveStageModule,
|
ArriveStageModule,
|
||||||
InvoicingStageModule
|
InvoicingStageModule,
|
||||||
|
ProjectDetailModal
|
||||||
},
|
},
|
||||||
mixins: [JeroListMixin],
|
mixins: [JeroListMixin],
|
||||||
data() {
|
data() {
|
||||||
@@ -508,7 +521,7 @@ export default {
|
|||||||
// 开票
|
// 开票
|
||||||
if (operateType === 'invoic') {
|
if (operateType === 'invoic') {
|
||||||
// 是否存在不需要发票的项目
|
// 是否存在不需要发票的项目
|
||||||
if (arr.some(item => item.needInvoice === 0 || Number(item.receivableAmount) === 0)){
|
if (arr.some(item => item.needInvoice === 0 || Number(item.receivableAmount) === 0)) {
|
||||||
reject('存在不需要发票的项目!')
|
reject('存在不需要发票的项目!')
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -600,13 +600,18 @@ export default {
|
|||||||
*/
|
*/
|
||||||
validateContact(rule, value, callback) {
|
validateContact(rule, value, callback) {
|
||||||
if (value) {
|
if (value) {
|
||||||
|
// 需要联动验证的字段
|
||||||
|
let fieldArr = ['contactsIdOne', 'contactsIdTwo', 'contactsIdThree']
|
||||||
|
// 去掉当前更改的字段
|
||||||
|
fieldArr = fieldArr.filter(tt => tt !== rule.field)
|
||||||
const contactObj = this.form.getFieldsValue(['contactsIdOne', 'contactsIdTwo', 'contactsIdThree'])
|
const contactObj = this.form.getFieldsValue(['contactsIdOne', 'contactsIdTwo', 'contactsIdThree'])
|
||||||
const contactArr = Object.values(contactObj)
|
const contactArr = Object.values(contactObj)
|
||||||
contactArr.filter(tt => tt !== undefined)
|
contactArr.filter(tt => tt !== undefined)
|
||||||
console.log(contactArr)
|
|
||||||
if (isRepeat(contactArr)) {
|
if (isRepeat(contactArr)) {
|
||||||
callback('请选择不同的企业联系人')
|
callback('请选择不同的企业联系人')
|
||||||
} else {
|
} else {
|
||||||
|
// 进行其余两个联系人字段的重复校验
|
||||||
|
this.form.validateFields(fieldArr)
|
||||||
callback()
|
callback()
|
||||||
}
|
}
|
||||||
callback()
|
callback()
|
||||||
|
|||||||
+18
-2
@@ -250,7 +250,14 @@ export default {
|
|||||||
],
|
],
|
||||||
filters: {
|
filters: {
|
||||||
id: this.$route.query.workGroupId
|
id: this.$route.query.workGroupId
|
||||||
}
|
},
|
||||||
|
// 给定当年作为来款年份默认查询条件
|
||||||
|
queryParam: {
|
||||||
|
year: new Date().getFullYear().toString()
|
||||||
|
},
|
||||||
|
lastQueryParam: {
|
||||||
|
year: new Date().getFullYear().toString()
|
||||||
|
},
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
@@ -309,7 +316,16 @@ export default {
|
|||||||
},
|
},
|
||||||
true
|
true
|
||||||
)
|
)
|
||||||
}
|
},
|
||||||
|
searchReset() {
|
||||||
|
this.lastQueryParam = {
|
||||||
|
year: new Date().getFullYear().toString()
|
||||||
|
}
|
||||||
|
this.queryParam = {
|
||||||
|
year: new Date().getFullYear().toString()
|
||||||
|
}
|
||||||
|
this.loadData(1)
|
||||||
|
},
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
Reference in New Issue
Block a user