结算功能优化
This commit is contained in:
parent
40c37af130
commit
40e2dc42a1
|
|
@ -160,7 +160,7 @@ export default {
|
||||||
type: [Number, String],
|
type: [Number, String],
|
||||||
default: () => 0,
|
default: () => 0,
|
||||||
},
|
},
|
||||||
// 列表类型 1.01承担方 2.03承担方 3.维修 4.未还 5.报废 6.待报废
|
// 列表类型 1 01承担方 2 03承担方 3 维修 4 未还 5 报废 6 待报废
|
||||||
listType: {
|
listType: {
|
||||||
type: Number,
|
type: Number,
|
||||||
default: () => 0,
|
default: () => 0,
|
||||||
|
|
@ -291,7 +291,7 @@ export default {
|
||||||
min-height: 48px;
|
min-height: 48px;
|
||||||
border: 1px solid #7e7e7e;
|
border: 1px solid #7e7e7e;
|
||||||
background: linear-gradient(to right, #b4b3b3, #edebeb);
|
background: linear-gradient(to right, #b4b3b3, #edebeb);
|
||||||
align-items: center;
|
align-items: center !important;
|
||||||
justify-content: space-around;
|
justify-content: space-around;
|
||||||
|
|
||||||
.cost-bear {
|
.cost-bear {
|
||||||
|
|
|
||||||
|
|
@ -11,12 +11,9 @@
|
||||||
<el-form inline :model="monthRecordParams" ref="monthRecordFormRef">
|
<el-form inline :model="monthRecordParams" ref="monthRecordFormRef">
|
||||||
<el-form-item label="结算月份" prop="dateMonth">
|
<el-form-item label="结算月份" prop="dateMonth">
|
||||||
<el-date-picker
|
<el-date-picker
|
||||||
v-model="monthRecordParams.dateMonth"
|
v-model="dateMonth"
|
||||||
type="monthrange"
|
type="month"
|
||||||
placeholder="请选择导出月份"
|
placeholder="请选择月份"
|
||||||
range-separator="至"
|
|
||||||
start-placeholder="开始月份"
|
|
||||||
end-placeholder="结束月份"
|
|
||||||
value-format="yyyy-MM"
|
value-format="yyyy-MM"
|
||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
|
@ -61,23 +58,23 @@
|
||||||
>
|
>
|
||||||
<el-table-column type="selection" align="center" />
|
<el-table-column type="selection" align="center" />
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="unit_name"
|
prop="unitName"
|
||||||
align="center"
|
align="center"
|
||||||
label="单位名称"
|
label="单位名称"
|
||||||
/>
|
/>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="prod_name"
|
prop="projectName"
|
||||||
align="center"
|
align="center"
|
||||||
label="工程名称"
|
label="工程名称"
|
||||||
/>
|
/>
|
||||||
<el-table-column prop="month" align="center" label="结算月份" />
|
<el-table-column prop="month" align="center" label="结算月份" />
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="month"
|
prop="costBearingParty"
|
||||||
align="center"
|
align="center"
|
||||||
label="费用承担方"
|
label="费用承担方"
|
||||||
/>
|
/>
|
||||||
<el-table-column prop="month" align="center" label="结算金额" />
|
<el-table-column prop="costs" align="center" label="结算金额" />
|
||||||
<el-table-column prop="month" align="center" label="操作">
|
<el-table-column align="center" label="操作">
|
||||||
<template slot-scope="{ row }">
|
<template slot-scope="{ row }">
|
||||||
<el-button type="text" @click="previewDetails(row)"
|
<el-button type="text" @click="previewDetails(row)"
|
||||||
>明细</el-button
|
>明细</el-button
|
||||||
|
|
@ -105,31 +102,84 @@
|
||||||
:before-close="handleCloseMInnerDialog"
|
:before-close="handleCloseMInnerDialog"
|
||||||
>
|
>
|
||||||
<el-row :gutter="20" class="title-row">
|
<el-row :gutter="20" class="title-row">
|
||||||
<el-col :span="12"> 领用单位: </el-col>
|
<el-col :span="12">
|
||||||
<el-col :span="12" class="pl-col"> 月结月份: </el-col>
|
领用单位:{{ monthDetailsInfo.unitName || '' }}
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="12" class="pl-col">
|
||||||
|
月结月份:
|
||||||
|
{{ monthDetailsInfo.month || '' }}</el-col
|
||||||
|
>
|
||||||
</el-row>
|
</el-row>
|
||||||
<el-row :gutter="20" class="title-row">
|
<el-row :gutter="20" class="title-row">
|
||||||
<el-col :span="12"> 工程名称: </el-col>
|
<el-col :span="12">
|
||||||
|
工程名称:{{ monthDetailsInfo.projectName || '' }}
|
||||||
|
</el-col>
|
||||||
<el-col :span="12" class="pl-col" style="color: red">
|
<el-col :span="12" class="pl-col" style="color: red">
|
||||||
费用承担方: 01( 项目 ) / 03 ( 分包 )
|
费用承担方:{{
|
||||||
|
monthDetailsInfo.costBearingParty || ''
|
||||||
|
}}
|
||||||
|
|
||||||
|
{{
|
||||||
|
monthDetailsInfo.costBearingParty == '01'
|
||||||
|
? '(项目)'
|
||||||
|
: '(分包)'
|
||||||
|
}}
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
|
|
||||||
<el-table border>
|
<el-table border :data="monthDetails" max-height="600">
|
||||||
<el-table-column label="序号" align="center" />
|
|
||||||
<el-table-column label="设备名称" align="center" />
|
|
||||||
<el-table-column label="规格型号" align="center" />
|
|
||||||
<el-table-column label="单位" align="center" />
|
|
||||||
<el-table-column label="数量" align="center" />
|
|
||||||
<el-table-column
|
<el-table-column
|
||||||
|
label="序号"
|
||||||
|
align="center"
|
||||||
|
type="index"
|
||||||
|
width="55"
|
||||||
|
/>
|
||||||
|
<el-table-column
|
||||||
|
prop="typeName"
|
||||||
|
label="设备名称"
|
||||||
|
align="center"
|
||||||
|
/>
|
||||||
|
<el-table-column
|
||||||
|
prop="modelName"
|
||||||
|
label="规格型号"
|
||||||
|
align="center"
|
||||||
|
/>
|
||||||
|
<el-table-column
|
||||||
|
prop="nuitName"
|
||||||
|
label="单位"
|
||||||
|
align="center"
|
||||||
|
/>
|
||||||
|
<el-table-column prop="num" label="数量" align="center" />
|
||||||
|
<el-table-column
|
||||||
|
prop="leasePrice"
|
||||||
label="台班费单价 (元/天)"
|
label="台班费单价 (元/天)"
|
||||||
align="center"
|
align="center"
|
||||||
/>
|
/>
|
||||||
<el-table-column label="开始日期" align="center" />
|
<el-table-column
|
||||||
<el-table-column label="结算日期" align="center" />
|
prop="startTime"
|
||||||
<el-table-column label="结算天数" align="center" />
|
label="开始日期"
|
||||||
<el-table-column label="结算金额" align="center" />
|
align="center"
|
||||||
<el-table-column label="本月暂记金额(元)" align="center" />
|
/>
|
||||||
|
<el-table-column
|
||||||
|
prop="endTime"
|
||||||
|
label="结算日期"
|
||||||
|
align="center"
|
||||||
|
/>
|
||||||
|
<el-table-column
|
||||||
|
prop="leaseDays"
|
||||||
|
label="结算天数"
|
||||||
|
align="center"
|
||||||
|
/>
|
||||||
|
<el-table-column
|
||||||
|
prop="costs"
|
||||||
|
label="结算金额"
|
||||||
|
align="center"
|
||||||
|
/>
|
||||||
|
<el-table-column
|
||||||
|
prop="realCosts"
|
||||||
|
label="本月暂记金额(元)"
|
||||||
|
align="center"
|
||||||
|
/>
|
||||||
</el-table>
|
</el-table>
|
||||||
</el-dialog>
|
</el-dialog>
|
||||||
</el-dialog>
|
</el-dialog>
|
||||||
|
|
@ -144,11 +194,9 @@ export default {
|
||||||
type: Boolean,
|
type: Boolean,
|
||||||
default: () => false,
|
default: () => false,
|
||||||
},
|
},
|
||||||
getRecordParams: {
|
agreementId: {
|
||||||
type: Array,
|
type: [String, Number],
|
||||||
default: () => {
|
default: () => '',
|
||||||
return []
|
|
||||||
},
|
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
|
|
@ -161,26 +209,27 @@ export default {
|
||||||
],
|
],
|
||||||
// 查询参数
|
// 查询参数
|
||||||
monthRecordParams: {
|
monthRecordParams: {
|
||||||
dateMonth: '',
|
startTime: '',
|
||||||
|
endTime: '',
|
||||||
costBear: '',
|
costBear: '',
|
||||||
|
agreementId: '',
|
||||||
pageNum: 1,
|
pageNum: 1,
|
||||||
pageSize: 10,
|
pageSize: 10,
|
||||||
},
|
},
|
||||||
// 列表数据源
|
// 列表数据源
|
||||||
monthRecordList: [
|
monthRecordList: [],
|
||||||
{
|
|
||||||
unit_name: 'xxxxx',
|
|
||||||
prod_name: 'xxxxx',
|
|
||||||
month: 'xxx',
|
|
||||||
month: 'xxx',
|
|
||||||
},
|
|
||||||
],
|
|
||||||
// 复选框勾选后数据
|
// 复选框勾选后数据
|
||||||
selectList: [],
|
selectList: [],
|
||||||
// 内测弹框
|
// 内测弹框
|
||||||
innerVisible: false,
|
innerVisible: false,
|
||||||
// 列表数量
|
// 列表数量
|
||||||
monthRecordTotal: 1,
|
monthRecordTotal: 1,
|
||||||
|
// 筛选日期
|
||||||
|
dateMonth: '',
|
||||||
|
// 月结明细表头
|
||||||
|
monthDetailsInfo: {},
|
||||||
|
// 月结明细 列表
|
||||||
|
monthDetails: [],
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
|
|
@ -190,8 +239,12 @@ export default {
|
||||||
/** 获取月结记录列表数据 */
|
/** 获取月结记录列表数据 */
|
||||||
async getMonthRecordList() {
|
async getMonthRecordList() {
|
||||||
// console.log('99999')
|
// console.log('99999')
|
||||||
|
this.monthRecordParams.startTime = this.dateMonth[0] || ''
|
||||||
|
this.monthRecordParams.endTime = this.dateMonth[1] || ''
|
||||||
|
this.monthRecordParams.agreementId = this.agreementId
|
||||||
// 调后台 Api 获取数据
|
// 调后台 Api 获取数据
|
||||||
const res = await getMonthRecordApi(this.getRecordParams)
|
const res = await getMonthRecordApi([this.monthRecordParams])
|
||||||
|
this.monthRecordList = res.data
|
||||||
console.log(res, '月结记录---')
|
console.log(res, '月结记录---')
|
||||||
},
|
},
|
||||||
/** 查询 */
|
/** 查询 */
|
||||||
|
|
@ -201,6 +254,7 @@ export default {
|
||||||
/** 重置 */
|
/** 重置 */
|
||||||
resetQuery() {
|
resetQuery() {
|
||||||
this.resetForm('monthRecordFormRef')
|
this.resetForm('monthRecordFormRef')
|
||||||
|
this.dateMonth = []
|
||||||
this.getMonthRecordList()
|
this.getMonthRecordList()
|
||||||
},
|
},
|
||||||
/** 批量明细导出 */
|
/** 批量明细导出 */
|
||||||
|
|
@ -227,7 +281,16 @@ export default {
|
||||||
this.innerVisible = false
|
this.innerVisible = false
|
||||||
},
|
},
|
||||||
/** 明细按钮 */
|
/** 明细按钮 */
|
||||||
previewDetails() {
|
previewDetails(row) {
|
||||||
|
const { unitName, month, projectName, costBearingParty } = row
|
||||||
|
this.monthDetailsInfo = {
|
||||||
|
unitName,
|
||||||
|
month,
|
||||||
|
projectName,
|
||||||
|
costBearingParty,
|
||||||
|
}
|
||||||
|
console.log(row, '明细')
|
||||||
|
this.monthDetails = row.node
|
||||||
this.innerVisible = true
|
this.innerVisible = true
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
|
|
||||||
|
|
@ -182,7 +182,7 @@
|
||||||
<MonthRecord
|
<MonthRecord
|
||||||
v-if="monthRecordDialogVisible"
|
v-if="monthRecordDialogVisible"
|
||||||
:monthRecordDialogVisible="monthRecordDialogVisible"
|
:monthRecordDialogVisible="monthRecordDialogVisible"
|
||||||
:getRecordParams="getRecordParams"
|
:agreementId="agreementId"
|
||||||
@handleCloseMonthRecordDialog="handleCloseMonthRecordDialog"
|
@handleCloseMonthRecordDialog="handleCloseMonthRecordDialog"
|
||||||
/>
|
/>
|
||||||
</template>
|
</template>
|
||||||
|
|
@ -262,7 +262,7 @@ export default {
|
||||||
// 页面标题
|
// 页面标题
|
||||||
pageContent: '',
|
pageContent: '',
|
||||||
// 查询月结记录的参数
|
// 查询月结记录的参数
|
||||||
getRecordParams: [],
|
agreementId: '',
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
|
|
@ -356,8 +356,7 @@ export default {
|
||||||
},
|
},
|
||||||
/** 月结记录 */
|
/** 月结记录 */
|
||||||
handleMonthRecord(row) {
|
handleMonthRecord(row) {
|
||||||
this.getRecordParams.push({ agreementId: row.agreementId })
|
this.agreementId = row.agreementId
|
||||||
console.log(this.getRecordParams, '月结记录')
|
|
||||||
this.monthRecordDialogVisible = true
|
this.monthRecordDialogVisible = true
|
||||||
},
|
},
|
||||||
/** 完工结算 结算明细*/
|
/** 完工结算 结算明细*/
|
||||||
|
|
|
||||||
|
|
@ -98,6 +98,7 @@
|
||||||
></el-input>
|
></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item
|
<el-form-item
|
||||||
|
v-if="domain.partType == 1"
|
||||||
:prop="'premiumList.' + index + '.partCost'"
|
:prop="'premiumList.' + index + '.partCost'"
|
||||||
label="配件费用:"
|
label="配件费用:"
|
||||||
:rules="{
|
:rules="{
|
||||||
|
|
@ -229,6 +230,7 @@
|
||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item
|
<el-form-item
|
||||||
|
v-if="domain.partType == 1"
|
||||||
:prop="'premiumListTwo.' + index + '.partType'"
|
:prop="'premiumListTwo.' + index + '.partType'"
|
||||||
label="是否收费:"
|
label="是否收费:"
|
||||||
required
|
required
|
||||||
|
|
@ -444,7 +446,7 @@ export default {
|
||||||
// } else {
|
// } else {
|
||||||
// callback(new Error('请输入大于0的并且小于维修总量的正整数'))
|
// callback(new Error('请输入大于0的并且小于维修总量的正整数'))
|
||||||
// }
|
// }
|
||||||
|
|
||||||
if (this.isRequired && (value === '' || !reg.test(value))) {
|
if (this.isRequired && (value === '' || !reg.test(value))) {
|
||||||
callback(new Error('请输入大于0的正整数'))
|
callback(new Error('请输入大于0的正整数'))
|
||||||
} else {
|
} else {
|
||||||
|
|
@ -556,6 +558,12 @@ export default {
|
||||||
'this.dynamicValidateForm.premiumList1111)',
|
'this.dynamicValidateForm.premiumList1111)',
|
||||||
this.dynamicValidateForm.premiumList,
|
this.dynamicValidateForm.premiumList,
|
||||||
)
|
)
|
||||||
|
|
||||||
|
this.dynamicValidateForm.premiumList.forEach((e) => {
|
||||||
|
if (e.partType == 0) {
|
||||||
|
e.partCost = ''
|
||||||
|
}
|
||||||
|
})
|
||||||
let params = {
|
let params = {
|
||||||
taskId: this.rowObj.taskId,
|
taskId: this.rowObj.taskId,
|
||||||
maId: this.rowObj.maId,
|
maId: this.rowObj.maId,
|
||||||
|
|
@ -591,6 +599,11 @@ export default {
|
||||||
submitTwo() {
|
submitTwo() {
|
||||||
this.$refs['dynamicValidateFormTwo'].validate((valid) => {
|
this.$refs['dynamicValidateFormTwo'].validate((valid) => {
|
||||||
if (valid) {
|
if (valid) {
|
||||||
|
this.dynamicValidateFormTwo.premiumListTwo.forEach((e) => {
|
||||||
|
if (e.partType == 0) {
|
||||||
|
e.partCost = ''
|
||||||
|
}
|
||||||
|
})
|
||||||
// 数量管理传递参数
|
// 数量管理传递参数
|
||||||
let params = {
|
let params = {
|
||||||
taskId: this.rowObj.taskId,
|
taskId: this.rowObj.taskId,
|
||||||
|
|
|
||||||
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue