9 changed files with 2653 additions and 11 deletions
@ -1,3 +1,51 @@ |
|||
<template> |
|||
<div>55555555</div> |
|||
<div class="app-container"> |
|||
<el-tabs |
|||
v-model="activeName" |
|||
@tab-click="handleClick" |
|||
style="margin-bottom: 20px" |
|||
> |
|||
<el-tab-pane label="农民工实名制" name="realNameSystem" :lazy="true"> |
|||
<realNameSystem :proNo="proNo" :proCode="proCode" /> |
|||
</el-tab-pane> |
|||
|
|||
<el-tab-pane label="农民工考勤" name="clockingIn" :lazy="true"> |
|||
<clockingIn :proNo="proNo" :proCode="proCode" /> |
|||
</el-tab-pane> |
|||
<el-tab-pane label="工资保证金账户" name="marginAccount" :lazy="true"> |
|||
<marginAccount :proNo="proNo" :proCode="proCode" /> |
|||
</el-tab-pane> |
|||
<el-tab-pane label="农民工工资发放管理" name="payroll" :lazy="true"> |
|||
<payroll :proNo="proNo" :proCode="proCode" /> |
|||
</el-tab-pane> |
|||
</el-tabs> |
|||
</div> |
|||
</template> |
|||
<script> |
|||
import realNameSystem from "./options/realNameSystem.vue"; |
|||
import clockingIn from "./options/clockingIn.vue"; |
|||
import marginAccount from "./options/marginAccount.vue"; |
|||
import payroll from "./options/payroll.vue"; |
|||
export default { |
|||
components: { |
|||
realNameSystem, |
|||
clockingIn, |
|||
marginAccount, |
|||
payroll, |
|||
}, |
|||
props: ["proNo", "proCode"], |
|||
data() { |
|||
return { |
|||
activeName: "realNameSystem", |
|||
}; |
|||
}, |
|||
methods: { |
|||
// 切换标签页 |
|||
handleClick(tab, event) { |
|||
// console.log("切换标签页", tab, event); |
|||
// console.log("切换标签页", this.routeList[1].routeName); |
|||
// this.routeList[1].routeName = tab.label; |
|||
}, |
|||
}, |
|||
}; |
|||
</script> |
|||
|
@ -0,0 +1,488 @@ |
|||
<template> |
|||
<div class="app-container"> |
|||
<el-form |
|||
:model="queryParams" |
|||
ref="queryForm" |
|||
:inline="true" |
|||
v-show="showSearch" |
|||
label-width="68px" |
|||
> |
|||
<el-form-item label="姓名" prop="name" label-width="40px"> |
|||
<el-input |
|||
v-model="queryParams.data.name" |
|||
placeholder="请输入身份证号码" |
|||
clearable |
|||
size="small" |
|||
@keyup.enter.native="handleQuery" |
|||
/> |
|||
</el-form-item> |
|||
<el-form-item> |
|||
<el-button |
|||
type="cyan" |
|||
icon="el-icon-search" |
|||
size="mini" |
|||
@click="handleQuery" |
|||
>搜索</el-button |
|||
> |
|||
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery" |
|||
>重置</el-button |
|||
> |
|||
</el-form-item> |
|||
</el-form> |
|||
|
|||
<el-row :gutter="10" class="mb8"> |
|||
<el-col :span="1.5"> |
|||
<el-button |
|||
type="primary" |
|||
icon="el-icon-plus" |
|||
size="mini" |
|||
@click="handleAdd" |
|||
v-hasPermi="['build:attendance:add']" |
|||
>新增</el-button |
|||
> |
|||
</el-col> |
|||
<el-col :span="1.5"> |
|||
<el-button |
|||
type="success" |
|||
icon="el-icon-edit" |
|||
size="mini" |
|||
:disabled="single" |
|||
@click="handleUpdate" |
|||
v-hasPermi="['build:attendance:edit']" |
|||
>修改</el-button |
|||
> |
|||
</el-col> |
|||
<el-col :span="1.5"> |
|||
<el-button |
|||
type="danger" |
|||
icon="el-icon-delete" |
|||
size="mini" |
|||
:disabled="multiple" |
|||
@click="handleDelete" |
|||
v-hasPermi="['build:attendance:remove']" |
|||
>删除</el-button |
|||
> |
|||
</el-col> |
|||
<right-toolbar |
|||
:showSearch.sync="showSearch" |
|||
@queryTable="getList" |
|||
></right-toolbar> |
|||
</el-row> |
|||
|
|||
<el-table |
|||
v-loading="loading" |
|||
:data="attendanceList" |
|||
@selection-change="handleSelectionChange" |
|||
> |
|||
<el-table-column type="selection" width="55" align="center" fixed /> |
|||
<el-table-column |
|||
label="序号" |
|||
type="index" |
|||
width="50" |
|||
align="center" |
|||
fixed |
|||
/> |
|||
<el-table-column |
|||
label="姓名" |
|||
align="center" |
|||
prop="name" |
|||
min-width="120" |
|||
/> |
|||
<el-table-column |
|||
label="身份证号码" |
|||
align="center" |
|||
prop="idNo" |
|||
min-width="120" |
|||
/> |
|||
<el-table-column |
|||
label="考勤所属年月" |
|||
align="center" |
|||
prop="attendanceYear" |
|||
min-width="120" |
|||
> |
|||
<template slot-scope="scope"> |
|||
<!-- <span>{{ parseTime(scope.row.attendanceYear, "{y}-{m}-{d}") }}</span> --> |
|||
<span>{{ parseTime(scope.row.attendanceYear, "{y}-{m}") }}</span> |
|||
</template> |
|||
</el-table-column> |
|||
<el-table-column |
|||
label="考勤所属年月考勤天数" |
|||
align="center" |
|||
prop="attendanceDay" |
|||
min-width="150" |
|||
/> |
|||
<el-table-column |
|||
label="所属单位" |
|||
align="center" |
|||
prop="belowUnit" |
|||
min-width="120" |
|||
/> |
|||
<el-table-column |
|||
label="所属单位统一社会信用代码" |
|||
align="center" |
|||
prop="socialCreditCode" |
|||
min-width="180" |
|||
/> |
|||
|
|||
<el-table-column |
|||
label="操作" |
|||
align="center" |
|||
class-name="small-padding fixed-width" |
|||
fixed="right" |
|||
width="180" |
|||
> |
|||
<template slot-scope="scope"> |
|||
<el-button |
|||
size="mini" |
|||
type="text" |
|||
icon="el-icon-edit" |
|||
@click="handleUpdate(scope.row)" |
|||
v-hasPermi="['build:attendance:edit']" |
|||
>修改</el-button |
|||
> |
|||
<el-button |
|||
size="mini" |
|||
type="text" |
|||
icon="el-icon-delete" |
|||
@click="handleDelete(scope.row)" |
|||
v-hasPermi="['build:attendance:remove']" |
|||
>删除</el-button |
|||
> |
|||
</template> |
|||
</el-table-column> |
|||
</el-table> |
|||
|
|||
<pagination |
|||
v-show="total > 0" |
|||
:total="total" |
|||
:page.sync="queryParams.pageNum" |
|||
:limit.sync="queryParams.pageSize" |
|||
@pagination="getList" |
|||
/> |
|||
|
|||
<!-- 添加或修改农民工人员考勤信息对话框 --> |
|||
<el-dialog |
|||
:title="title" |
|||
:visible.sync="open" |
|||
width="1200px" |
|||
append-to-body |
|||
:close-on-click-modal="false" |
|||
> |
|||
<el-form ref="form" :model="form" :rules="rules" label-width="180px"> |
|||
<el-form-item label="姓名" prop="name"> |
|||
<!-- <el-input v-model="form.name" placeholder="请输入姓名"/> --> |
|||
<el-select |
|||
v-model="form.name" |
|||
placeholder="请选择农民工" |
|||
filterable |
|||
clearable |
|||
size="small" |
|||
style="width: 100%" |
|||
> |
|||
<el-option |
|||
v-for="dict in peasantWorkers" |
|||
:key="dict.id" |
|||
:label="dict.name" |
|||
:value="dict.name" |
|||
@click.native="getOtherMsg(dict)" |
|||
/> |
|||
</el-select> |
|||
</el-form-item> |
|||
<el-form-item label="身份证号码" prop="idNo"> |
|||
<el-input |
|||
v-model="form.idNo" |
|||
placeholder="请输入身份证号码" |
|||
readonly |
|||
/> |
|||
</el-form-item> |
|||
<el-form-item label="所属单位" prop="belowUnit"> |
|||
<el-input |
|||
v-model="form.belowUnit" |
|||
placeholder="请输入所属单位" |
|||
readonly |
|||
/> |
|||
</el-form-item> |
|||
<el-form-item label="所属单位统一社会信用代码" prop="socialCreditCode"> |
|||
<el-input |
|||
v-model="form.socialCreditCode" |
|||
placeholder="请输入所属单位统一社会信用代码" |
|||
readonly |
|||
/> |
|||
</el-form-item> |
|||
<el-form-item label="考勤所属年月" prop="attendanceYear"> |
|||
<el-date-picker |
|||
clearable |
|||
size="small" |
|||
style="width: 100%" |
|||
v-model="form.attendanceYear" |
|||
type="month" |
|||
value-format="yyyy-MM-dd" |
|||
placeholder="选择考勤所属年月" |
|||
> |
|||
</el-date-picker> |
|||
</el-form-item> |
|||
<el-form-item label="考勤所属年月考勤天数" prop="attendanceDay"> |
|||
<el-input |
|||
v-model.number="form.attendanceDay" |
|||
placeholder="请输入考勤所属年月考勤天数" |
|||
> |
|||
<template slot="append">天</template> |
|||
</el-input> |
|||
</el-form-item> |
|||
</el-form> |
|||
<div slot="footer" class="dialog-footer"> |
|||
<el-button type="primary" @click="submitForm">确 定</el-button> |
|||
<el-button @click="cancel">取 消</el-button> |
|||
</div> |
|||
</el-dialog> |
|||
</div> |
|||
</template> |
|||
|
|||
<script> |
|||
import { |
|||
listAttendance, |
|||
getAttendance, |
|||
delAttendance, |
|||
addAttendance, |
|||
updateAttendance, |
|||
exportAttendance, |
|||
} from "@/api/build/attendance"; |
|||
import { listRealName } from "@/api/build/realName"; |
|||
|
|||
export default { |
|||
name: "Attendance", |
|||
props: ["proNo", "proCode"], |
|||
data() { |
|||
return { |
|||
// 遮罩层 |
|||
loading: true, |
|||
// 选中数组 |
|||
ids: [], |
|||
// 非单个禁用 |
|||
single: true, |
|||
// 非多个禁用 |
|||
multiple: true, |
|||
// 显示搜索条件 |
|||
showSearch: true, |
|||
// 总条数 |
|||
total: 0, |
|||
// 农民工人员考勤信息表格数据 |
|||
attendanceList: [], |
|||
// 弹出层标题 |
|||
title: "", |
|||
// 是否显示弹出层 |
|||
open: false, |
|||
// 查询参数 |
|||
queryParams: { |
|||
pageNum: 1, |
|||
pageSize: 10, |
|||
ids: null, |
|||
data: { |
|||
socialCreditCode: null, |
|||
idNo: null, |
|||
name: null, |
|||
attendanceYear: null, |
|||
createUid: null, |
|||
updateUid: null, |
|||
proCode: null, |
|||
proNo: null, |
|||
owerDept: null, |
|||
attendanceDay: null, |
|||
}, |
|||
// 排序方式 |
|||
params: { |
|||
// 按哪个字段排序 |
|||
orderBy: "create_time", |
|||
// desc降序,升序asc |
|||
sort: "desc", |
|||
}, |
|||
}, |
|||
// 表单参数 |
|||
form: {}, |
|||
// 表单校验 |
|||
rules: { |
|||
attendanceYear: [ |
|||
{ required: true, message: "请选择考勤年月", trigger: "blur" }, |
|||
], |
|||
attendanceDay: [ |
|||
{ required: true, message: "请输入考勤年月天数", trigger: "blur" }, |
|||
|
|||
{ |
|||
pattern: /^[+]{0,1}(\d+)$/, |
|||
message: "考勤年月天数为正整数", |
|||
trigger: "blur", |
|||
}, |
|||
], |
|||
}, |
|||
peasantWorkers: [], |
|||
}; |
|||
}, |
|||
created() { |
|||
this.getList(); |
|||
listRealName({ |
|||
data: { |
|||
proNo: this.proNo, |
|||
proCode: this.proCode, |
|||
}, |
|||
}).then((response) => { |
|||
this.peasantWorkers = response.records; |
|||
console.log("this.peasantWorkers", this.peasantWorkers); |
|||
}); |
|||
}, |
|||
methods: { |
|||
getOtherMsg(msg) { |
|||
this.form.idNo = msg.idNo; |
|||
this.form.belowUnit = msg.belowUnit; |
|||
this.form.socialCreditCode = msg.socialCreditCode; |
|||
this.form.idNo = msg.idNo; |
|||
}, |
|||
/** 查询农民工人员考勤信息列表 */ |
|||
getList() { |
|||
this.loading = true; |
|||
this.queryParams.data.proNo = this.proNo; |
|||
this.queryParams.data.proCode = this.proCode; |
|||
listAttendance(this.queryParams).then((response) => { |
|||
this.attendanceList = response.records; |
|||
this.total = response.total; |
|||
this.loading = false; |
|||
}); |
|||
}, |
|||
// 取消按钮 |
|||
cancel() { |
|||
this.open = false; |
|||
this.reset(); |
|||
}, |
|||
// 表单重置 |
|||
reset() { |
|||
this.form = { |
|||
id: null, |
|||
socialCreditCode: null, |
|||
idNo: null, |
|||
name: null, |
|||
attendanceYear: null, |
|||
createUid: null, |
|||
updateUid: null, |
|||
createTime: null, |
|||
updateTime: null, |
|||
proCode: null, |
|||
proNo: null, |
|||
owerDept: null, |
|||
remark: null, |
|||
attendanceDay: null, |
|||
}; |
|||
this.resetForm("form"); |
|||
}, |
|||
// 查询表单重置 |
|||
resetQueryForm() { |
|||
this.queryParams = { |
|||
pageNum: 1, |
|||
pageSize: 10, |
|||
data: { |
|||
id: null, |
|||
socialCreditCode: null, |
|||
idNo: null, |
|||
name: null, |
|||
attendanceYear: null, |
|||
createUid: null, |
|||
updateUid: null, |
|||
createTime: null, |
|||
updateTime: null, |
|||
proCode: null, |
|||
proNo: null, |
|||
owerDept: null, |
|||
remark: null, |
|||
attendanceDay: null, |
|||
}, |
|||
}; |
|||
this.resetForm("form"); |
|||
}, |
|||
/** 搜索按钮操作 */ |
|||
handleQuery() { |
|||
this.queryParams.pageNum = 1; |
|||
this.getList(); |
|||
}, |
|||
/** 重置按钮操作 */ |
|||
resetQuery() { |
|||
this.resetQueryForm(); |
|||
this.handleQuery(); |
|||
}, |
|||
// 多选框选中数据 |
|||
handleSelectionChange(selection) { |
|||
this.ids = selection.map((item) => item.id); |
|||
this.single = selection.length !== 1; |
|||
this.multiple = !selection.length; |
|||
}, |
|||
/** 新增按钮操作 */ |
|||
handleAdd() { |
|||
this.reset(); |
|||
this.open = true; |
|||
this.title = "添加农民工人员考勤信息"; |
|||
}, |
|||
/** 修改按钮操作 */ |
|||
handleUpdate(row) { |
|||
this.reset(); |
|||
const id = row.id || this.ids; |
|||
getAttendance(id).then((response) => { |
|||
this.form = response.data; |
|||
this.open = true; |
|||
this.title = "修改农民工人员考勤信息"; |
|||
}); |
|||
}, |
|||
/** 提交按钮 */ |
|||
submitForm() { |
|||
this.$refs["form"].validate((valid) => { |
|||
if (valid) { |
|||
this.form.proNo = this.proNo; |
|||
this.form.proCode = this.proCode; |
|||
if (this.form.id != null) { |
|||
updateAttendance(this.form).then((response) => { |
|||
if (response.code === 200) { |
|||
this.msgSuccess("修改成功"); |
|||
this.open = false; |
|||
this.getList(); |
|||
} |
|||
}); |
|||
} else { |
|||
addAttendance(this.form).then((response) => { |
|||
if (response.code === 200) { |
|||
this.msgSuccess("新增成功"); |
|||
this.open = false; |
|||
this.getList(); |
|||
} |
|||
}); |
|||
} |
|||
} |
|||
}); |
|||
}, |
|||
/** 删除按钮操作 */ |
|||
handleDelete(row) { |
|||
const ids = row.id || this.ids; |
|||
if (ids) { |
|||
this.$confirm("是否删除选中的数据?", "警告", { |
|||
confirmButtonText: "确定", |
|||
cancelButtonText: "取消", |
|||
type: "warning", |
|||
}) |
|||
.then(function () { |
|||
return delAttendance(ids); |
|||
}) |
|||
.then(() => { |
|||
this.getList(); |
|||
this.msgSuccess("删除成功"); |
|||
}) |
|||
.catch(function () {}); |
|||
} else { |
|||
this.$message.warning("请选择要删除的数据!!"); |
|||
} |
|||
}, |
|||
}, |
|||
}; |
|||
</script> |
|||
<style lang="scss" scoped> |
|||
@import "@/assets/css/dialog.scss"; |
|||
// ::v-deep { |
|||
// .el-dialog { |
|||
// margin-top: 10vh !important; |
|||
// } |
|||
// } |
|||
</style> |
@ -0,0 +1,944 @@ |
|||
<template> |
|||
<div class="app-container"> |
|||
<el-form |
|||
:model="queryParams" |
|||
ref="queryForm" |
|||
:inline="true" |
|||
v-show="showSearch" |
|||
label-width="68px" |
|||
> |
|||
<el-form-item label="收支方式" prop="incomeExpenditureMethods"> |
|||
<el-input |
|||
v-model="queryParams.data.incomeExpenditureMethods" |
|||
placeholder="请输入收支方式" |
|||
clearable |
|||
size="small" |
|||
@keyup.enter.native="handleQuery" |
|||
/> |
|||
</el-form-item> |
|||
<el-form-item |
|||
label="工资保证金开户银行" |
|||
prop="depositBankSalaryDeposit" |
|||
label-width="152px" |
|||
> |
|||
<el-input |
|||
v-model="queryParams.data.depositBankSalaryDeposit" |
|||
placeholder="请输入工资保证金开户银行" |
|||
clearable |
|||
size="small" |
|||
@keyup.enter.native="handleQuery" |
|||
/> |
|||
</el-form-item> |
|||
|
|||
<el-form-item> |
|||
<el-button |
|||
type="cyan" |
|||
icon="el-icon-search" |
|||
size="mini" |
|||
@click="handleQuery" |
|||
>搜索</el-button |
|||
> |
|||
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery" |
|||
>重置</el-button |
|||
> |
|||
</el-form-item> |
|||
</el-form> |
|||
|
|||
<el-row :gutter="10" class="mb8"> |
|||
<el-col :span="1.5"> |
|||
<el-button |
|||
type="primary" |
|||
icon="el-icon-plus" |
|||
size="mini" |
|||
@click="handleAdd" |
|||
v-hasPermi="['build:ensure:add']" |
|||
>新增</el-button |
|||
> |
|||
</el-col> |
|||
<el-col :span="1.5"> |
|||
<el-button |
|||
type="success" |
|||
icon="el-icon-edit" |
|||
size="mini" |
|||
:disabled="single" |
|||
@click="handleUpdate" |
|||
v-hasPermi="['build:ensure:edit']" |
|||
>修改</el-button |
|||
> |
|||
</el-col> |
|||
<el-col :span="1.5"> |
|||
<el-button |
|||
type="danger" |
|||
icon="el-icon-delete" |
|||
size="mini" |
|||
:disabled="multiple" |
|||
@click="handleDelete" |
|||
v-hasPermi="['build:ensure:remove']" |
|||
>删除</el-button |
|||
> |
|||
</el-col> |
|||
<right-toolbar |
|||
:showSearch.sync="showSearch" |
|||
@queryTable="getList" |
|||
></right-toolbar> |
|||
</el-row> |
|||
|
|||
<el-table |
|||
v-loading="loading" |
|||
:data="ensureList" |
|||
@selection-change="handleSelectionChange" |
|||
> |
|||
<el-table-column type="selection" width="55" align="center" fixed /> |
|||
<el-table-column |
|||
label="序号" |
|||
type="index" |
|||
width="50" |
|||
align="center" |
|||
fixed |
|||
/> |
|||
|
|||
<el-table-column |
|||
label="差异化缴存金额(万元)" |
|||
align="center" |
|||
prop="differentiatedDepositAmount" |
|||
min-width="164" |
|||
/> |
|||
<el-table-column |
|||
label="应缴金额(万元)" |
|||
align="center" |
|||
prop="amountPayable" |
|||
min-width="124" |
|||
/> |
|||
<el-table-column |
|||
label="已缴纳金额(万元)" |
|||
align="center" |
|||
prop="paidAmount" |
|||
min-width="138" |
|||
/> |
|||
<el-table-column |
|||
label="收支方式" |
|||
align="center" |
|||
prop="incomeExpenditureMethods" |
|||
min-width="120" |
|||
/> |
|||
<el-table-column |
|||
label="工资保证金开户银行" |
|||
align="center" |
|||
prop="depositBankSalaryDeposit" |
|||
min-width="150" |
|||
/> |
|||
<el-table-column |
|||
label="工资保证金银行账户" |
|||
align="center" |
|||
prop="salaryDepositBankAccount" |
|||
min-width="150" |
|||
/> |
|||
<el-table-column |
|||
label="现金金额(万元)" |
|||
align="center" |
|||
prop="cashAmount" |
|||
min-width="124" |
|||
/> |
|||
<el-table-column |
|||
label="担保银行名称" |
|||
align="center" |
|||
prop="guaranteeBankName" |
|||
min-width="120" |
|||
/> |
|||
<el-table-column |
|||
label="银行保函函号" |
|||
align="center" |
|||
prop="bankGuaranteeLetterNo" |
|||
min-width="120" |
|||
/> |
|||
<el-table-column |
|||
label="银行保函担保金额(万元)" |
|||
align="center" |
|||
prop="bankGuaranteeLetterAmount" |
|||
min-width="180" |
|||
/> |
|||
<el-table-column |
|||
label="银行保函有效期起始日期" |
|||
align="center" |
|||
prop="bankGuaranteeStartYear" |
|||
min-width="166" |
|||
/> |
|||
<el-table-column |
|||
label="终止日期" |
|||
align="center" |
|||
prop="bankGuaranteeEndYear" |
|||
min-width="120" |
|||
/> |
|||
<el-table-column |
|||
label="担保公司名称" |
|||
align="center" |
|||
prop="guaranteeCompanyName" |
|||
min-width="120" |
|||
/> |
|||
<el-table-column |
|||
label="担保公司保函函号" |
|||
align="center" |
|||
prop="guaranteeCompanyLetterNo" |
|||
min-width="166" |
|||
/> |
|||
<el-table-column |
|||
label="担保公司担保金额(万元)" |
|||
align="center" |
|||
prop="guaranteeCompanyAmount" |
|||
min-width="180" |
|||
/> |
|||
<el-table-column |
|||
label="担保公司保函有效期起始日期" |
|||
align="center" |
|||
prop="guaranteeCompanyStartYear" |
|||
min-width="190" |
|||
> |
|||
<template slot-scope="scope"> |
|||
<span>{{ |
|||
parseTime(scope.row.guaranteeCompanyStartYear, "{y}-{m}-{d}") |
|||
}}</span> |
|||
</template> |
|||
</el-table-column> |
|||
<el-table-column |
|||
label="担保公司终止日期" |
|||
align="center" |
|||
prop="guaranteeCompanyEndYear" |
|||
min-width="124" |
|||
/> |
|||
<el-table-column |
|||
label="保险公司名称" |
|||
align="center" |
|||
prop="insuranceCompanyName" |
|||
min-width="120" |
|||
/> |
|||
<el-table-column |
|||
label="保险单号" |
|||
align="center" |
|||
prop="insuranceNo" |
|||
min-width="120" |
|||
/> |
|||
<el-table-column |
|||
label="保险金额(万元)" |
|||
align="center" |
|||
prop="insuranceAmount" |
|||
min-width="124" |
|||
/> |
|||
<el-table-column |
|||
label="保险有效期起始日期" |
|||
align="center" |
|||
prop="insuranceStartTime" |
|||
min-width="150" |
|||
> |
|||
<template slot-scope="scope"> |
|||
<span>{{ |
|||
parseTime(scope.row.insuranceStartTime, "{y}-{m}-{d}") |
|||
}}</span> |
|||
</template> |
|||
</el-table-column> |
|||
<el-table-column |
|||
label="保险终止日期" |
|||
align="center" |
|||
prop="insuranceEndTime" |
|||
min-width="120" |
|||
> |
|||
<template slot-scope="scope"> |
|||
<span>{{ |
|||
parseTime(scope.row.insuranceEndTime, "{y}-{m}-{d}") |
|||
}}</span> |
|||
</template> |
|||
</el-table-column> |
|||
<el-table-column |
|||
label="其他金额(万元)" |
|||
align="center" |
|||
prop="otherAmount" |
|||
min-width="124" |
|||
/> |
|||
<el-table-column |
|||
label="收支时间" |
|||
align="center" |
|||
prop="incomeTime" |
|||
min-width="120" |
|||
> |
|||
<template slot-scope="scope"> |
|||
<span>{{ parseTime(scope.row.incomeTime, "{y}-{m}-{d}") }}</span> |
|||
</template> |
|||
</el-table-column> |
|||
<el-table-column |
|||
label="操作" |
|||
align="center" |
|||
class-name="small-padding fixed-width" |
|||
width="180" |
|||
fixed="right" |
|||
> |
|||
<template slot-scope="scope"> |
|||
<el-button |
|||
size="mini" |
|||
type="text" |
|||
icon="el-icon-edit" |
|||
@click="handleUpdate(scope.row)" |
|||
v-hasPermi="['build:ensure:edit']" |
|||
>修改</el-button |
|||
> |
|||
<el-button |
|||
size="mini" |
|||
type="text" |
|||
icon="el-icon-delete" |
|||
@click="handleDelete(scope.row)" |
|||
v-hasPermi="['build:ensure:remove']" |
|||
>删除</el-button |
|||
> |
|||
</template> |
|||
</el-table-column> |
|||
</el-table> |
|||
|
|||
<pagination |
|||
v-show="total > 0" |
|||
:total="total" |
|||
:page.sync="queryParams.pageNum" |
|||
:limit.sync="queryParams.pageSize" |
|||
@pagination="getList" |
|||
/> |
|||
|
|||
<!-- 添加或修改工资保证金账户管理对话框 --> |
|||
<el-dialog |
|||
:title="title" |
|||
:visible.sync="open" |
|||
width="1200px" |
|||
append-to-body |
|||
:close-on-click-modal="false" |
|||
> |
|||
<el-row :gutter="15"> |
|||
<el-form ref="form" :model="form" :rules="rules" label-width="194px"> |
|||
<el-col :span="12"> |
|||
<el-form-item |
|||
label="差异化缴存金额" |
|||
prop="differentiatedDepositAmount" |
|||
> |
|||
<el-input |
|||
v-model="form.differentiatedDepositAmount" |
|||
placeholder="请输入差异化缴存金额" |
|||
> |
|||
<template slot="append">万元</template> |
|||
</el-input> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="12"> |
|||
<el-form-item label="应缴金额" prop="amountPayable"> |
|||
<el-input |
|||
v-model="form.amountPayable" |
|||
placeholder="请输入应缴金额" |
|||
> |
|||
<template slot="append">万元</template> |
|||
</el-input> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="12"> |
|||
<el-form-item label="已缴纳金额" prop="paidAmount"> |
|||
<el-input |
|||
v-model="form.paidAmount" |
|||
placeholder="请输入已缴纳金额" |
|||
> |
|||
<template slot="append">万元</template> |
|||
</el-input> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="12"> |
|||
<el-form-item label="收支方式" prop="incomeExpenditureMethods"> |
|||
<el-input |
|||
v-model="form.incomeExpenditureMethods" |
|||
placeholder="请输入收支方式" |
|||
/> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="12"> |
|||
<el-form-item |
|||
label="工资保证金开户银行" |
|||
prop="depositBankSalaryDeposit" |
|||
> |
|||
<el-input |
|||
v-model="form.depositBankSalaryDeposit" |
|||
placeholder="请输入工资保证金开户银行" |
|||
/> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="12"> |
|||
<el-form-item |
|||
label="工资保证金银行账户" |
|||
prop="salaryDepositBankAccount" |
|||
> |
|||
<el-input |
|||
v-model="form.salaryDepositBankAccount" |
|||
placeholder="请输入工资保证金银行账户" |
|||
/> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="12"> |
|||
<el-form-item label="现金金额" prop="cashAmount"> |
|||
<el-input v-model="form.cashAmount" placeholder="请输入现金金额"> |
|||
<template slot="append">万元</template> |
|||
</el-input> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="12"> |
|||
<el-form-item label="担保银行名称" prop="guaranteeBankName"> |
|||
<el-input |
|||
v-model="form.guaranteeBankName" |
|||
placeholder="请输入担保银行名称" |
|||
/> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="12"> |
|||
<el-form-item label="银行保函函号" prop="bankGuaranteeLetterNo"> |
|||
<el-input |
|||
v-model="form.bankGuaranteeLetterNo" |
|||
placeholder="请输入银行保函函号" |
|||
/> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="12"> |
|||
<el-form-item |
|||
label="银行保函担保金额" |
|||
prop="bankGuaranteeLetterAmount" |
|||
> |
|||
<el-input |
|||
v-model="form.bankGuaranteeLetterAmount" |
|||
placeholder="请输入银行保函担保金额" |
|||
> |
|||
<template slot="append">万元</template> |
|||
</el-input> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="12"> |
|||
<el-form-item |
|||
label="银行保函有效期起始日期" |
|||
prop="bankGuaranteeStartYear" |
|||
> |
|||
<!-- <el-input |
|||
v-model="form.bankGuaranteeStartYear" |
|||
placeholder="请输入银行保函有效期起始日期" |
|||
/> --> |
|||
<el-date-picker |
|||
clearable |
|||
size="small" |
|||
style="width: 100%" |
|||
v-model="form.bankGuaranteeStartYear" |
|||
type="date" |
|||
value-format="yyyy-MM-dd" |
|||
placeholder="选择银行保函有效期起始日期" |
|||
> |
|||
</el-date-picker> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="12"> |
|||
<el-form-item label="终止日期" prop="bankGuaranteeEndYear"> |
|||
<!-- <el-input |
|||
v-model="form.bankGuaranteeEndYear" |
|||
placeholder="请输入终止日期" |
|||
/> --> |
|||
<el-date-picker |
|||
clearable |
|||
size="small" |
|||
style="width: 100%" |
|||
v-model="form.bankGuaranteeEndYear" |
|||
type="date" |
|||
value-format="yyyy-MM-dd" |
|||
placeholder="选择终止日期" |
|||
> |
|||
</el-date-picker> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="12"> |
|||
<el-form-item label="担保公司名称" prop="guaranteeCompanyName"> |
|||
<el-input |
|||
v-model="form.guaranteeCompanyName" |
|||
placeholder="请输入担保公司名称" |
|||
/> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="12"> |
|||
<el-form-item |
|||
label="担保公司保函函号" |
|||
prop="guaranteeCompanyLetterNo" |
|||
> |
|||
<el-input |
|||
v-model="form.guaranteeCompanyLetterNo" |
|||
placeholder="请输入担保公司保函函号" |
|||
/> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="12"> |
|||
<el-form-item |
|||
label="担保公司担保金额" |
|||
prop="guaranteeCompanyAmount" |
|||
> |
|||
<el-input |
|||
v-model="form.guaranteeCompanyAmount" |
|||
placeholder="请输入担保公司担保金额" |
|||
> |
|||
<template slot="append">万元</template> |
|||
</el-input> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="12"> |
|||
<el-form-item |
|||
label="担保公司保函有效期起始日期" |
|||
prop="guaranteeCompanyStartYear" |
|||
> |
|||
<el-date-picker |
|||
clearable |
|||
size="small" |
|||
style="width: 100%" |
|||
v-model="form.guaranteeCompanyStartYear" |
|||
type="date" |
|||
value-format="yyyy-MM-dd" |
|||
placeholder="选择担保公司保函有效期起始日期" |
|||
> |
|||
</el-date-picker> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="12"> |
|||
<el-form-item |
|||
label="担保公司终止日期" |
|||
prop="guaranteeCompanyEndYear" |
|||
> |
|||
<!-- <el-input |
|||
v-model="form.guaranteeCompanyEndYear" |
|||
placeholder="请输入担保公司终止日期" |
|||
/> --> |
|||
<el-date-picker |
|||
clearable |
|||
size="small" |
|||
style="width: 100%" |
|||
v-model="form.guaranteeCompanyEndYear" |
|||
type="date" |
|||
value-format="yyyy-MM-dd" |
|||
placeholder="选择担保公司终止日期" |
|||
> |
|||
</el-date-picker> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="12"> |
|||
<el-form-item label="保险公司名称" prop="insuranceCompanyName"> |
|||
<el-input |
|||
v-model="form.insuranceCompanyName" |
|||
placeholder="请输入保险公司名称" |
|||
/> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="12"> |
|||
<el-form-item label="保险单号" prop="insuranceNo"> |
|||
<el-input |
|||
v-model="form.insuranceNo" |
|||
placeholder="请输入保险单号" |
|||
/> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="12"> |
|||
<el-form-item label="保险金额" prop="insuranceAmount"> |
|||
<el-input |
|||
v-model="form.insuranceAmount" |
|||
placeholder="请输入保险金额" |
|||
> |
|||
<template slot="append">万元</template> |
|||
</el-input> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="12"> |
|||
<el-form-item label="保险有效期起始日期" prop="insuranceStartTime"> |
|||
<el-date-picker |
|||
clearable |
|||
size="small" |
|||
style="width: 100%" |
|||
v-model="form.insuranceStartTime" |
|||
type="date" |
|||
value-format="yyyy-MM-dd" |
|||
placeholder="选择保险有效期起始日期" |
|||
> |
|||
</el-date-picker> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="12"> |
|||
<el-form-item label="保险终止日期" prop="insuranceEndTime"> |
|||
<el-date-picker |
|||
clearable |
|||
size="small" |
|||
style="width: 100%" |
|||
v-model="form.insuranceEndTime" |
|||
type="date" |
|||
value-format="yyyy-MM-dd" |
|||
placeholder="选择保险终止日期" |
|||
> |
|||
</el-date-picker> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="12"> |
|||
<el-form-item label="其他金额" prop="otherAmount"> |
|||
<el-input v-model="form.otherAmount" placeholder="请输入其他金额"> |
|||
<template slot="append">万元</template> |
|||
</el-input> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="12"> |
|||
<el-form-item label="收支时间" prop="incomeTime"> |
|||
<el-date-picker |
|||
clearable |
|||
size="small" |
|||
style="width: 100%" |
|||
v-model="form.incomeTime" |
|||
type="date" |
|||
value-format="yyyy-MM-dd" |
|||
placeholder="选择收支时间" |
|||
> |
|||
</el-date-picker> |
|||
</el-form-item> |
|||
</el-col> |
|||
</el-form> |
|||
</el-row> |
|||
<div slot="footer" class="dialog-footer"> |
|||
<el-button type="primary" @click="submitForm">确 定</el-button> |
|||
<el-button @click="cancel">取 消</el-button> |
|||
</div> |
|||
</el-dialog> |
|||
</div> |
|||
</template> |
|||
|
|||
<script> |
|||
import { |
|||
listEnsure, |
|||
getEnsure, |
|||
delEnsure, |
|||
addEnsure, |
|||
updateEnsure, |
|||
exportEnsure, |
|||
} from "@/api/build/ensure"; |
|||
|
|||
export default { |
|||
name: "Ensure", |
|||
props: ["proNo", "proCode"], |
|||
data() { |
|||
return { |
|||
// 遮罩层 |
|||
loading: true, |
|||
// 选中数组 |
|||
ids: [], |
|||
// 非单个禁用 |
|||
single: true, |
|||
// 非多个禁用 |
|||
multiple: true, |
|||
// 显示搜索条件 |
|||
showSearch: true, |
|||
// 总条数 |
|||
total: 0, |
|||
// 工资保证金账户管理表格数据 |
|||
ensureList: [], |
|||
// 弹出层标题 |
|||
title: "", |
|||
// 是否显示弹出层 |
|||
open: false, |
|||
// 查询参数 |
|||
queryParams: { |
|||
pageNum: 1, |
|||
pageSize: 10, |
|||
ids: null, |
|||
data: { |
|||
differentiatedDepositAmount: null, |
|||
amountPayable: null, |
|||
paidAmount: null, |
|||
incomeExpenditureMethods: null, |
|||
depositBankSalaryDeposit: null, |
|||
salaryDepositBankAccount: null, |
|||
cashAmount: null, |
|||
guaranteeBankName: null, |
|||
bankGuaranteeLetterNo: null, |
|||
bankGuaranteeLetterAmount: null, |
|||
bankGuaranteeStartYear: null, |
|||
bankGuaranteeEndYear: null, |
|||
guaranteeCompanyName: null, |
|||
guaranteeCompanyLetterNo: null, |
|||
guaranteeCompanyAmount: null, |
|||
guaranteeCompanyStartYear: null, |
|||
guaranteeCompanyEndYear: null, |
|||
insuranceCompanyName: null, |
|||
insuranceNo: null, |
|||
insuranceAmount: null, |
|||
insuranceStartTime: null, |
|||
insuranceEndTime: null, |
|||
otherAmount: null, |
|||
incomeTime: null, |
|||
createUid: null, |
|||
updateUid: null, |
|||
proCode: null, |
|||
proNo: null, |
|||
owerDept: null, |
|||
}, |
|||
// 排序方式 |
|||
params: { |
|||
// 按哪个字段排序 |
|||
orderBy: "create_time", |
|||
// desc降序,升序asc |
|||
sort: "desc", |
|||
}, |
|||
}, |
|||
// 表单参数 |
|||
form: {}, |
|||
// 表单校验 |
|||
rules: { |
|||
differentiatedDepositAmount: [ |
|||
{ |
|||
pattern: |
|||
/(^[1-9]([0-9]+)?(\.[0-9]{1,2})?$)|(^(0){1}$)|(^[0-9]\.[0-9]([0-9])?$)/, |
|||
message: "请输入数字,可保留两位小数", |
|||
trigger: "blur", |
|||
}, |
|||
], |
|||
amountPayable: [ |
|||
{ |
|||
pattern: |
|||
/(^[1-9]([0-9]+)?(\.[0-9]{1,2})?$)|(^(0){1}$)|(^[0-9]\.[0-9]([0-9])?$)/, |
|||
message: "请输入数字,可保留两位小数", |
|||
trigger: "blur", |
|||
}, |
|||
], |
|||
paidAmount: [ |
|||
{ |
|||
pattern: |
|||
/(^[1-9]([0-9]+)?(\.[0-9]{1,2})?$)|(^(0){1}$)|(^[0-9]\.[0-9]([0-9])?$)/, |
|||
message: "请输入数字,可保留两位小数", |
|||
trigger: "blur", |
|||
}, |
|||
], |
|||
cashAmount: [ |
|||
{ |
|||
pattern: |
|||
/(^[1-9]([0-9]+)?(\.[0-9]{1,2})?$)|(^(0){1}$)|(^[0-9]\.[0-9]([0-9])?$)/, |
|||
message: "请输入数字,可保留两位小数", |
|||
trigger: "blur", |
|||
}, |
|||
], |
|||
bankGuaranteeLetterAmount: [ |
|||
{ |
|||
pattern: |
|||
/(^[1-9]([0-9]+)?(\.[0-9]{1,2})?$)|(^(0){1}$)|(^[0-9]\.[0-9]([0-9])?$)/, |
|||
message: "请输入数字,可保留两位小数", |
|||
trigger: "blur", |
|||
}, |
|||
], |
|||
guaranteeCompanyAmount: [ |
|||
{ |
|||
pattern: |
|||
/(^[1-9]([0-9]+)?(\.[0-9]{1,2})?$)|(^(0){1}$)|(^[0-9]\.[0-9]([0-9])?$)/, |
|||
message: "请输入数字,可保留两位小数", |
|||
trigger: "blur", |
|||
}, |
|||
], |
|||
insuranceAmount: [ |
|||
{ |
|||
pattern: |
|||
/(^[1-9]([0-9]+)?(\.[0-9]{1,2})?$)|(^(0){1}$)|(^[0-9]\.[0-9]([0-9])?$)/, |
|||
message: "请输入数字,可保留两位小数", |
|||
trigger: "blur", |
|||
}, |
|||
], |
|||
otherAmount: [ |
|||
{ |
|||
pattern: |
|||
/(^[1-9]([0-9]+)?(\.[0-9]{1,2})?$)|(^(0){1}$)|(^[0-9]\.[0-9]([0-9])?$)/, |
|||
message: "请输入数字,可保留两位小数", |
|||
trigger: "blur", |
|||
}, |
|||
], |
|||
}, |
|||
}; |
|||
}, |
|||
created() { |
|||
this.getList(); |
|||
}, |
|||
methods: { |
|||
/** 查询工资保证金账户管理列表 */ |
|||
getList() { |
|||
this.loading = true; |
|||
this.queryParams.data.proNo = this.proNo; |
|||
this.queryParams.data.proCode = this.proCode; |
|||
listEnsure(this.queryParams).then((response) => { |
|||
this.ensureList = response.records; |
|||
this.total = response.total; |
|||
this.loading = false; |
|||
}); |
|||
}, |
|||
// 取消按钮 |
|||
cancel() { |
|||
this.open = false; |
|||
this.reset(); |
|||
}, |
|||
// 表单重置 |
|||
reset() { |
|||
this.form = { |
|||
id: null, |
|||
differentiatedDepositAmount: null, |
|||
amountPayable: null, |
|||
paidAmount: null, |
|||
incomeExpenditureMethods: null, |
|||
depositBankSalaryDeposit: null, |
|||
salaryDepositBankAccount: null, |
|||
cashAmount: null, |
|||
guaranteeBankName: null, |
|||
bankGuaranteeLetterNo: null, |
|||
bankGuaranteeLetterAmount: null, |
|||
bankGuaranteeStartYear: null, |
|||
bankGuaranteeEndYear: null, |
|||
guaranteeCompanyName: null, |
|||
guaranteeCompanyLetterNo: null, |
|||
guaranteeCompanyAmount: null, |
|||
guaranteeCompanyStartYear: null, |
|||
guaranteeCompanyEndYear: null, |
|||
insuranceCompanyName: null, |
|||
insuranceNo: null, |
|||
insuranceAmount: null, |
|||
insuranceStartTime: null, |
|||
insuranceEndTime: null, |
|||
otherAmount: null, |
|||
incomeTime: null, |
|||
createUid: null, |
|||
updateUid: null, |
|||
createTime: null, |
|||
updateTime: null, |
|||
proCode: null, |
|||
proNo: null, |
|||
owerDept: null, |
|||
remark: null, |
|||
}; |
|||
this.resetForm("form"); |
|||
}, |
|||
// 查询表单重置 |
|||
resetQueryForm() { |
|||
this.queryParams = { |
|||
pageNum: 1, |
|||
pageSize: 10, |
|||
data: { |
|||
id: null, |
|||
differentiatedDepositAmount: null, |
|||
amountPayable: null, |
|||
paidAmount: null, |
|||
incomeExpenditureMethods: null, |
|||
depositBankSalaryDeposit: null, |
|||
salaryDepositBankAccount: null, |
|||
cashAmount: null, |
|||
guaranteeBankName: null, |
|||
bankGuaranteeLetterNo: null, |
|||
bankGuaranteeLetterAmount: null, |
|||
bankGuaranteeStartYear: null, |
|||
bankGuaranteeEndYear: null, |
|||
guaranteeCompanyName: null, |
|||
guaranteeCompanyLetterNo: null, |
|||
guaranteeCompanyAmount: null, |
|||
guaranteeCompanyStartYear: null, |
|||
guaranteeCompanyEndYear: null, |
|||
insuranceCompanyName: null, |
|||
insuranceNo: null, |
|||
insuranceAmount: null, |
|||
insuranceStartTime: null, |
|||
insuranceEndTime: null, |
|||
otherAmount: null, |
|||
incomeTime: null, |
|||
createUid: null, |
|||
updateUid: null, |
|||
createTime: null, |
|||
updateTime: null, |
|||
proCode: null, |
|||
proNo: null, |
|||
owerDept: null, |
|||
remark: null, |
|||
}, |
|||
}; |
|||
this.resetForm("form"); |
|||
}, |
|||
/** 搜索按钮操作 */ |
|||
handleQuery() { |
|||
this.queryParams.pageNum = 1; |
|||
this.getList(); |
|||
}, |
|||
/** 重置按钮操作 */ |
|||
resetQuery() { |
|||
this.resetQueryForm(); |
|||
this.handleQuery(); |
|||
}, |
|||
// 多选框选中数据 |
|||
handleSelectionChange(selection) { |
|||
this.ids = selection.map((item) => item.id); |
|||
this.single = selection.length !== 1; |
|||
this.multiple = !selection.length; |
|||
}, |
|||
/** 新增按钮操作 */ |
|||
handleAdd() { |
|||
this.reset(); |
|||
this.open = true; |
|||
this.title = "添加工资保证金账户管理"; |
|||
}, |
|||
/** 修改按钮操作 */ |
|||
handleUpdate(row) { |
|||
this.reset(); |
|||
const id = row.id || this.ids; |
|||
getEnsure(id).then((response) => { |
|||
this.form = response.data; |
|||
this.open = true; |
|||
this.title = "修改工资保证金账户管理"; |
|||
}); |
|||
}, |
|||
/** 提交按钮 */ |
|||
submitForm() { |
|||
this.$refs["form"].validate((valid) => { |
|||
if (valid) { |
|||
this.form.proNo = this.proNo; |
|||
this.form.proCode = this.proCode; |
|||
if (this.form.id != null) { |
|||
updateEnsure(this.form).then((response) => { |
|||
if (response.code === 200) { |
|||
this.msgSuccess("修改成功"); |
|||
this.open = false; |
|||
this.getList(); |
|||
} |
|||
}); |
|||
} else { |
|||
addEnsure(this.form).then((response) => { |
|||
if (response.code === 200) { |
|||
this.msgSuccess("新增成功"); |
|||
this.open = false; |
|||
this.getList(); |
|||
} |
|||
}); |
|||
} |
|||
} |
|||
}); |
|||
}, |
|||
/** 删除按钮操作 */ |
|||
handleDelete(row) { |
|||
const ids = row.id || this.ids; |
|||
if (ids) { |
|||
this.$confirm("是否删除选中的数据?", "警告", { |
|||
confirmButtonText: "确定", |
|||
cancelButtonText: "取消", |
|||
type: "warning", |
|||
}) |
|||
.then(function () { |
|||
return delEnsure(ids); |
|||
}) |
|||
.then(() => { |
|||
this.getList(); |
|||
this.msgSuccess("删除成功"); |
|||
}) |
|||
.catch(function () {}); |
|||
} else { |
|||
this.$message.warning("请选择要删除的数据!!"); |
|||
} |
|||
}, |
|||
}, |
|||
}; |
|||
</script> |
|||
<style lang="scss" scoped> |
|||
@import "@/assets/css/dialog.scss"; |
|||
::v-deep { |
|||
.el-dialog { |
|||
margin-top: 3vh !important; |
|||
} |
|||
} |
|||
</style> |
@ -0,0 +1,603 @@ |
|||
<template> |
|||
<div class="app-container"> |
|||
<el-form |
|||
:model="queryParams" |
|||
ref="queryForm" |
|||
:inline="true" |
|||
v-show="showSearch" |
|||
label-width="68px" |
|||
> |
|||
<!-- <el-form-item label="银行账户" prop="bankAccount"> |
|||
<el-input |
|||
v-model="queryParams.data.bankAccount" |
|||
placeholder="请输入银行账户" |
|||
clearable |
|||
size="small" |
|||
@keyup.enter.native="handleQuery" |
|||
/> |
|||
</el-form-item> |
|||
<el-form-item label="银行流水号" prop="bankSerialNumber"> |
|||
<el-input |
|||
v-model="queryParams.data.bankSerialNumber" |
|||
placeholder="请输入银行流水号" |
|||
clearable |
|||
size="small" |
|||
@keyup.enter.native="handleQuery" |
|||
/> |
|||
</el-form-item> --> |
|||
<!-- <el-form-item label="务工人员身份证号" prop="idNo"> |
|||
<el-input |
|||
v-model="queryParams.data.idNo" |
|||
placeholder="请输入务工人员身份证号" |
|||
clearable |
|||
size="small" |
|||
@keyup.enter.native="handleQuery" |
|||
/> |
|||
</el-form-item> --> |
|||
<el-form-item label="务工人员姓名" prop="name" label-width="96px"> |
|||
<el-input |
|||
v-model="queryParams.data.name" |
|||
placeholder="请输入务工人员姓名" |
|||
clearable |
|||
size="small" |
|||
@keyup.enter.native="handleQuery" |
|||
/> |
|||
</el-form-item> |
|||
<!-- <el-form-item label="工资年月" prop="salaryTime"> |
|||
<el-date-picker |
|||
clearable |
|||
size="small" |
|||
style="width: 200px" |
|||
v-model="queryParams.salaryTime" |
|||
type="date" |
|||
value-format="yyyy-MM-dd" |
|||
placeholder="选择工资年月" |
|||
> |
|||
</el-date-picker> |
|||
</el-form-item> |
|||
<el-form-item label="当月应发金额" prop="monthlySalaryPayable"> |
|||
<el-input |
|||
v-model="queryParams.data.monthlySalaryPayable" |
|||
placeholder="请输入当月应发金额" |
|||
clearable |
|||
size="small" |
|||
@keyup.enter.native="handleQuery" |
|||
/> |
|||
</el-form-item> |
|||
<el-form-item label="当月扣发金额" prop="monthlySalaryDeduct"> |
|||
<el-input |
|||
v-model="queryParams.data.monthlySalaryDeduct" |
|||
placeholder="请输入当月扣发金额" |
|||
clearable |
|||
size="small" |
|||
@keyup.enter.native="handleQuery" |
|||
/> |
|||
</el-form-item> |
|||
<el-form-item label="当月实发工资" prop="monthlySalaryCurrent"> |
|||
<el-input |
|||
v-model="queryParams.data.monthlySalaryCurrent" |
|||
placeholder="请输入当月实发工资" |
|||
clearable |
|||
size="small" |
|||
@keyup.enter.native="handleQuery" |
|||
/> |
|||
</el-form-item> |
|||
<el-form-item label="工资支付方式" prop="salaryPayableMethods"> |
|||
<el-input |
|||
v-model="queryParams.data.salaryPayableMethods" |
|||
placeholder="请输入工资支付方式" |
|||
clearable |
|||
size="small" |
|||
@keyup.enter.native="handleQuery" |
|||
/> |
|||
</el-form-item> --> |
|||
<el-form-item> |
|||
<el-button |
|||
type="cyan" |
|||
icon="el-icon-search" |
|||
size="mini" |
|||
@click="handleQuery" |
|||
>搜索</el-button |
|||
> |
|||
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery" |
|||
>重置</el-button |
|||
> |
|||
</el-form-item> |
|||
</el-form> |
|||
|
|||
<el-row :gutter="10" class="mb8"> |
|||
<el-col :span="1.5"> |
|||
<el-button |
|||
type="primary" |
|||
icon="el-icon-plus" |
|||
size="mini" |
|||
@click="handleAdd" |
|||
v-hasPermi="['build:payable:add']" |
|||
>新增</el-button |
|||
> |
|||
</el-col> |
|||
<el-col :span="1.5"> |
|||
<el-button |
|||
type="success" |
|||
icon="el-icon-edit" |
|||
size="mini" |
|||
:disabled="single" |
|||
@click="handleUpdate" |
|||
v-hasPermi="['build:payable:edit']" |
|||
>修改</el-button |
|||
> |
|||
</el-col> |
|||
<el-col :span="1.5"> |
|||
<el-button |
|||
type="danger" |
|||
icon="el-icon-delete" |
|||
size="mini" |
|||
:disabled="multiple" |
|||
@click="handleDelete" |
|||
v-hasPermi="['build:payable:remove']" |
|||
>删除</el-button |
|||
> |
|||
</el-col> |
|||
<right-toolbar |
|||
:showSearch.sync="showSearch" |
|||
@queryTable="getList" |
|||
></right-toolbar> |
|||
</el-row> |
|||
|
|||
<el-table |
|||
v-loading="loading" |
|||
:data="payableList" |
|||
@selection-change="handleSelectionChange" |
|||
> |
|||
<el-table-column type="selection" width="55" align="center" fixed /> |
|||
<el-table-column |
|||
label="序号" |
|||
type="index" |
|||
width="50" |
|||
align="center" |
|||
fixed |
|||
/> |
|||
|
|||
<el-table-column |
|||
label="银行账户" |
|||
align="center" |
|||
prop="bankAccount" |
|||
min-width="120" |
|||
/> |
|||
<el-table-column |
|||
label="银行流水号" |
|||
align="center" |
|||
prop="bankSerialNumber" |
|||
min-width="120" |
|||
/> |
|||
<el-table-column |
|||
label="务工人员身份证号" |
|||
align="center" |
|||
prop="idNo" |
|||
min-width="124" |
|||
/> |
|||
<el-table-column |
|||
label="务工人员姓名" |
|||
align="center" |
|||
prop="name" |
|||
min-width="120" |
|||
/> |
|||
<el-table-column |
|||
label="工资年月" |
|||
align="center" |
|||
prop="salaryTime" |
|||
min-width="120" |
|||
> |
|||
<template slot-scope="scope"> |
|||
<span>{{ parseTime(scope.row.salaryTime, "{y}-{m}-{d}") }}</span> |
|||
</template> |
|||
</el-table-column> |
|||
<el-table-column |
|||
label="当月应发金额" |
|||
align="center" |
|||
prop="monthlySalaryPayable" |
|||
min-width="120" |
|||
/> |
|||
<el-table-column |
|||
label="当月扣发金额" |
|||
align="center" |
|||
prop="monthlySalaryDeduct" |
|||
min-width="120" |
|||
/> |
|||
<el-table-column |
|||
label="当月实发工资" |
|||
align="center" |
|||
prop="monthlySalaryCurrent" |
|||
min-width="120" |
|||
/> |
|||
<el-table-column |
|||
label="工资支付方式" |
|||
align="center" |
|||
prop="salaryPayableMethods" |
|||
min-width="120" |
|||
/> |
|||
<el-table-column |
|||
label="操作" |
|||
align="center" |
|||
class-name="small-padding fixed-width" |
|||
width="180" |
|||
fixed="right" |
|||
> |
|||
<template slot-scope="scope"> |
|||
<el-button |
|||
size="mini" |
|||
type="text" |
|||
icon="el-icon-edit" |
|||
@click="handleUpdate(scope.row)" |
|||
v-hasPermi="['build:payable:edit']" |
|||
>修改</el-button |
|||
> |
|||
<el-button |
|||
size="mini" |
|||
type="text" |
|||
icon="el-icon-delete" |
|||
@click="handleDelete(scope.row)" |
|||
v-hasPermi="['build:payable:remove']" |
|||
>删除</el-button |
|||
> |
|||
</template> |
|||
</el-table-column> |
|||
</el-table> |
|||
|
|||
<pagination |
|||
v-show="total > 0" |
|||
:total="total" |
|||
:page.sync="queryParams.pageNum" |
|||
:limit.sync="queryParams.pageSize" |
|||
@pagination="getList" |
|||
/> |
|||
|
|||
<!-- 添加或修改农民工工资发放管理对话框 --> |
|||
<el-dialog |
|||
:title="title" |
|||
:visible.sync="open" |
|||
width="1200px" |
|||
append-to-body |
|||
:close-on-click-modal="false" |
|||
> |
|||
<el-row :gutter="15"> |
|||
<el-form ref="form" :model="form" :rules="rules" label-width="130px"> |
|||
<el-col :span="12"> |
|||
<el-form-item label="银行账户" prop="bankAccount"> |
|||
<el-input |
|||
v-model="form.bankAccount" |
|||
placeholder="请输入银行账户" |
|||
/> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="12"> |
|||
<el-form-item label="银行流水号" prop="bankSerialNumber"> |
|||
<el-input |
|||
v-model="form.bankSerialNumber" |
|||
placeholder="请输入银行流水号" |
|||
/> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="12"> |
|||
<el-form-item label="务工人员身份证号" prop="idNo"> |
|||
<el-input |
|||
v-model="form.idNo" |
|||
placeholder="请输入务工人员身份证号" |
|||
/> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="12"> |
|||
<el-form-item label="务工人员身份证号" prop="name"> |
|||
<el-input |
|||
v-model="form.name" |
|||
placeholder="请输入务工人员身份证号" |
|||
/> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="12"> |
|||
<el-form-item label="工资年月" prop="salaryTime"> |
|||
<el-date-picker |
|||
clearable |
|||
size="small" |
|||
style="width: 100%" |
|||
v-model="form.salaryTime" |
|||
type="date" |
|||
value-format="yyyy-MM-dd" |
|||
placeholder="选择工资年月" |
|||
> |
|||
</el-date-picker> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="12"> |
|||
<el-form-item label="当月应发金额" prop="monthlySalaryPayable"> |
|||
<el-input |
|||
v-model="form.monthlySalaryPayable" |
|||
placeholder="请输入当月应发金额" |
|||
> |
|||
<template slot="append">元</template> |
|||
</el-input> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="12"> |
|||
<el-form-item label="当月扣发金额" prop="monthlySalaryDeduct"> |
|||
<el-input |
|||
v-model="form.monthlySalaryDeduct" |
|||
placeholder="请输入当月扣发金额" |
|||
> |
|||
<template slot="append">元</template> |
|||
</el-input> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="12"> |
|||
<el-form-item label="当月实发工资" prop="monthlySalaryCurrent"> |
|||
<el-input |
|||
v-model="form.monthlySalaryCurrent" |
|||
placeholder="请输入当月实发工资" |
|||
> |
|||
<template slot="append">元</template> |
|||
</el-input> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="12"> |
|||
<el-form-item label="工资支付方式" prop="salaryPayableMethods"> |
|||
<el-input |
|||
v-model="form.salaryPayableMethods" |
|||
placeholder="请输入工资支付方式" |
|||
/> |
|||
</el-form-item> |
|||
</el-col> |
|||
</el-form> |
|||
</el-row> |
|||
<div slot="footer" class="dialog-footer"> |
|||
<el-button type="primary" @click="submitForm">确 定</el-button> |
|||
<el-button @click="cancel">取 消</el-button> |
|||
</div> |
|||
</el-dialog> |
|||
</div> |
|||
</template> |
|||
|
|||
<script> |
|||
import { |
|||
listPayable, |
|||
getPayable, |
|||
delPayable, |
|||
addPayable, |
|||
updatePayable, |
|||
exportPayable, |
|||
} from "@/api/build/payable"; |
|||
|
|||
export default { |
|||
name: "Payable", |
|||
props: ["proNo", "proCode"], |
|||
data() { |
|||
return { |
|||
// 遮罩层 |
|||
loading: true, |
|||
// 选中数组 |
|||
ids: [], |
|||
// 非单个禁用 |
|||
single: true, |
|||
// 非多个禁用 |
|||
multiple: true, |
|||
// 显示搜索条件 |
|||
showSearch: true, |
|||
// 总条数 |
|||
total: 0, |
|||
// 农民工工资发放管理表格数据 |
|||
payableList: [], |
|||
// 弹出层标题 |
|||
title: "", |
|||
// 是否显示弹出层 |
|||
open: false, |
|||
// 查询参数 |
|||
queryParams: { |
|||
pageNum: 1, |
|||
pageSize: 10, |
|||
ids: null, |
|||
data: { |
|||
bankAccount: null, |
|||
bankSerialNumber: null, |
|||
idNo: null, |
|||
name: null, |
|||
salaryTime: null, |
|||
monthlySalaryPayable: null, |
|||
monthlySalaryDeduct: null, |
|||
monthlySalaryCurrent: null, |
|||
salaryPayableMethods: null, |
|||
createUid: null, |
|||
updateUid: null, |
|||
owerDept: null, |
|||
proCode: null, |
|||
proNo: null, |
|||
}, |
|||
// 排序方式 |
|||
params: { |
|||
// 按哪个字段排序 |
|||
orderBy: "create_time", |
|||
// desc降序,升序asc |
|||
sort: "desc", |
|||
}, |
|||
}, |
|||
// 表单参数 |
|||
form: {}, |
|||
// 表单校验 |
|||
rules: { |
|||
monthlySalaryPayable: [ |
|||
{ |
|||
pattern: |
|||
/(^[1-9]([0-9]+)?(\.[0-9]{1,2})?$)|(^(0){1}$)|(^[0-9]\.[0-9]([0-9])?$)/, |
|||
message: "请输入数字,可保留两位小数", |
|||
trigger: "blur", |
|||
}, |
|||
], |
|||
monthlySalaryDeduct: [ |
|||
{ |
|||
pattern: |
|||
/(^[1-9]([0-9]+)?(\.[0-9]{1,2})?$)|(^(0){1}$)|(^[0-9]\.[0-9]([0-9])?$)/, |
|||
message: "请输入数字,可保留两位小数", |
|||
trigger: "blur", |
|||
}, |
|||
], |
|||
monthlySalaryCurrent: [ |
|||
{ |
|||
pattern: |
|||
/(^[1-9]([0-9]+)?(\.[0-9]{1,2})?$)|(^(0){1}$)|(^[0-9]\.[0-9]([0-9])?$)/, |
|||
message: "请输入数字,可保留两位小数", |
|||
trigger: "blur", |
|||
}, |
|||
], |
|||
}, |
|||
}; |
|||
}, |
|||
created() { |
|||
this.getList(); |
|||
}, |
|||
methods: { |
|||
/** 查询农民工工资发放管理列表 */ |
|||
getList() { |
|||
this.loading = true; |
|||
listPayable(this.queryParams).then((response) => { |
|||
this.payableList = response.records; |
|||
this.total = response.total; |
|||
this.loading = false; |
|||
}); |
|||
}, |
|||
// 取消按钮 |
|||
cancel() { |
|||
this.open = false; |
|||
this.reset(); |
|||
}, |
|||
// 表单重置 |
|||
reset() { |
|||
this.form = { |
|||
id: null, |
|||
bankAccount: null, |
|||
bankSerialNumber: null, |
|||
idNo: null, |
|||
name: null, |
|||
salaryTime: null, |
|||
monthlySalaryPayable: null, |
|||
monthlySalaryDeduct: null, |
|||
monthlySalaryCurrent: null, |
|||
salaryPayableMethods: null, |
|||
createUid: null, |
|||
updateUid: null, |
|||
createTime: null, |
|||
updateTime: null, |
|||
owerDept: null, |
|||
proCode: null, |
|||
proNo: null, |
|||
remark: null, |
|||
}; |
|||
this.resetForm("form"); |
|||
}, |
|||
// 查询表单重置 |
|||
resetQueryForm() { |
|||
this.queryParams = { |
|||
pageNum: 1, |
|||
pageSize: 10, |
|||
data: { |
|||
id: null, |
|||
bankAccount: null, |
|||
bankSerialNumber: null, |
|||
idNo: null, |
|||
name: null, |
|||
salaryTime: null, |
|||
monthlySalaryPayable: null, |
|||
monthlySalaryDeduct: null, |
|||
monthlySalaryCurrent: null, |
|||
salaryPayableMethods: null, |
|||
createUid: null, |
|||
updateUid: null, |
|||
createTime: null, |
|||
updateTime: null, |
|||
owerDept: null, |
|||
proCode: null, |
|||
proNo: null, |
|||
remark: null, |
|||
}, |
|||
}; |
|||
this.resetForm("form"); |
|||
}, |
|||
/** 搜索按钮操作 */ |
|||
handleQuery() { |
|||
this.queryParams.pageNum = 1; |
|||
this.getList(); |
|||
}, |
|||
/** 重置按钮操作 */ |
|||
resetQuery() { |
|||
this.resetQueryForm(); |
|||
this.handleQuery(); |
|||
}, |
|||
// 多选框选中数据 |
|||
handleSelectionChange(selection) { |
|||
this.ids = selection.map((item) => item.id); |
|||
this.single = selection.length !== 1; |
|||
this.multiple = !selection.length; |
|||
}, |
|||
/** 新增按钮操作 */ |
|||
handleAdd() { |
|||
this.reset(); |
|||
this.open = true; |
|||
this.title = "添加农民工工资发放管理"; |
|||
}, |
|||
/** 修改按钮操作 */ |
|||
handleUpdate(row) { |
|||
this.reset(); |
|||
const id = row.id || this.ids; |
|||
getPayable(id).then((response) => { |
|||
this.form = response.data; |
|||
this.open = true; |
|||
this.title = "修改农民工工资发放管理"; |
|||
}); |
|||
}, |
|||
/** 提交按钮 */ |
|||
submitForm() { |
|||
this.$refs["form"].validate((valid) => { |
|||
if (valid) { |
|||
this.form.proNo = this.proNo; |
|||
this.form.proCode = this.proCode; |
|||
if (this.form.id != null) { |
|||
updatePayable(this.form).then((response) => { |
|||
if (response.code === 200) { |
|||
this.msgSuccess("修改成功"); |
|||
this.open = false; |
|||
this.getList(); |
|||
} |
|||
}); |
|||
} else { |
|||
addPayable(this.form).then((response) => { |
|||
if (response.code === 200) { |
|||
this.msgSuccess("新增成功"); |
|||
this.open = false; |
|||
this.getList(); |
|||
} |
|||
}); |
|||
} |
|||
} |
|||
}); |
|||
}, |
|||
/** 删除按钮操作 */ |
|||
handleDelete(row) { |
|||
const ids = row.id || this.ids; |
|||
if (ids) { |
|||
this.$confirm("是否删除选中的数据?", "警告", { |
|||
confirmButtonText: "确定", |
|||
cancelButtonText: "取消", |
|||
type: "warning", |
|||
}) |
|||
.then(function () { |
|||
return delPayable(ids); |
|||
}) |
|||
.then(() => { |
|||
this.getList(); |
|||
this.msgSuccess("删除成功"); |
|||
}) |
|||
.catch(function () {}); |
|||
} else { |
|||
this.$message.warning("请选择要删除的数据!!"); |
|||
} |
|||
}, |
|||
}, |
|||
}; |
|||
</script> |
@ -0,0 +1,549 @@ |
|||
<template> |
|||
<div class="app-container"> |
|||
<el-form |
|||
:model="queryParams" |
|||
ref="queryForm" |
|||
:inline="true" |
|||
v-show="showSearch" |
|||
label-width="68px" |
|||
> |
|||
<!-- <el-form-item |
|||
label="所属单位统一社会信用代码" |
|||
prop="socialCreditCode" |
|||
label-width="180px" |
|||
> |
|||
<el-input |
|||
v-model="queryParams.data.socialCreditCode" |
|||
placeholder="请输入所属单位统一社会信用代码" |
|||
clearable |
|||
size="small" |
|||
@keyup.enter.native="handleQuery" |
|||
/> |
|||
</el-form-item> |
|||
<el-form-item label="身份证号码" prop="idNo"> |
|||
<el-input |
|||
v-model="queryParams.data.idNo" |
|||
placeholder="请输入身份证号码" |
|||
clearable |
|||
size="small" |
|||
@keyup.enter.native="handleQuery" |
|||
/> |
|||
</el-form-item> --> |
|||
<el-form-item label="姓名" prop="name" label-width="40px"> |
|||
<el-input |
|||
v-model="queryParams.data.name" |
|||
placeholder="请输入姓名" |
|||
clearable |
|||
size="small" |
|||
@keyup.enter.native="handleQuery" |
|||
/> |
|||
</el-form-item> |
|||
<!-- <el-form-item label="出生日期" prop="birthday"> |
|||
<el-date-picker |
|||
clearable |
|||
size="small" |
|||
style="width: 200px" |
|||
v-model="queryParams.birthday" |
|||
type="date" |
|||
value-format="yyyy-MM-dd" |
|||
placeholder="选择出生日期" |
|||
> |
|||
</el-date-picker> |
|||
</el-form-item> |
|||
<el-form-item label="民族" prop="nation"> |
|||
<el-input |
|||
v-model="queryParams.data.nation" |
|||
placeholder="请输入民族" |
|||
clearable |
|||
size="small" |
|||
@keyup.enter.native="handleQuery" |
|||
/> |
|||
</el-form-item> |
|||
<el-form-item label="籍贯" prop="nativePlace"> |
|||
<el-input |
|||
v-model="queryParams.data.nativePlace" |
|||
placeholder="请输入籍贯" |
|||
clearable |
|||
size="small" |
|||
@keyup.enter.native="handleQuery" |
|||
/> |
|||
</el-form-item> --> |
|||
|
|||
<el-form-item> |
|||
<el-button |
|||
type="cyan" |
|||
icon="el-icon-search" |
|||
size="mini" |
|||
@click="handleQuery" |
|||
>搜索</el-button |
|||
> |
|||
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery" |
|||
>重置</el-button |
|||
> |
|||
</el-form-item> |
|||
</el-form> |
|||
|
|||
<el-row :gutter="10" class="mb8"> |
|||
<el-col :span="1.5"> |
|||
<el-button |
|||
type="primary" |
|||
icon="el-icon-plus" |
|||
size="mini" |
|||
@click="handleAdd" |
|||
v-hasPermi="['build:realName:add']" |
|||
>新增</el-button |
|||
> |
|||
</el-col> |
|||
<el-col :span="1.5"> |
|||
<el-button |
|||
type="success" |
|||
icon="el-icon-edit" |
|||
size="mini" |
|||
:disabled="single" |
|||
@click="handleUpdate" |
|||
v-hasPermi="['build:realName:edit']" |
|||
>修改</el-button |
|||
> |
|||
</el-col> |
|||
<el-col :span="1.5"> |
|||
<el-button |
|||
type="danger" |
|||
icon="el-icon-delete" |
|||
size="mini" |
|||
:disabled="multiple" |
|||
@click="handleDelete" |
|||
v-hasPermi="['build:realName:remove']" |
|||
>删除</el-button |
|||
> |
|||
</el-col> |
|||
<right-toolbar |
|||
:showSearch.sync="showSearch" |
|||
@queryTable="getList" |
|||
></right-toolbar> |
|||
</el-row> |
|||
|
|||
<el-table |
|||
v-loading="loading" |
|||
:data="realNameList" |
|||
@selection-change="handleSelectionChange" |
|||
> |
|||
<el-table-column type="selection" width="55" align="center" fixed /> |
|||
<el-table-column |
|||
label="序号" |
|||
type="index" |
|||
width="50" |
|||
align="center" |
|||
fixed |
|||
/> |
|||
<el-table-column |
|||
label="姓名" |
|||
align="center" |
|||
prop="name" |
|||
min-width="120" |
|||
/> |
|||
<el-table-column |
|||
label="身份证号码" |
|||
align="center" |
|||
prop="idNo" |
|||
min-width="180" |
|||
/> |
|||
|
|||
<el-table-column |
|||
label="所属单位" |
|||
align="center" |
|||
prop="belowUnit" |
|||
min-width="120" |
|||
/> |
|||
<el-table-column |
|||
label="所属单位统一社会信用代码" |
|||
align="center" |
|||
prop="socialCreditCode" |
|||
min-width="180" |
|||
/> |
|||
<el-table-column |
|||
label="出生日期" |
|||
align="center" |
|||
prop="birthday" |
|||
min-width="120" |
|||
> |
|||
<template slot-scope="scope"> |
|||
<span>{{ parseTime(scope.row.birthday, "{y}-{m}-{d}") }}</span> |
|||
</template> |
|||
</el-table-column> |
|||
<el-table-column |
|||
label="民族" |
|||
align="center" |
|||
prop="nation" |
|||
min-width="120" |
|||
/> |
|||
<el-table-column |
|||
label="籍贯" |
|||
align="center" |
|||
prop="nativePlace" |
|||
min-width="120" |
|||
/> |
|||
<el-table-column |
|||
label="操作" |
|||
align="center" |
|||
class-name="small-padding fixed-width" |
|||
width="180" |
|||
fixed="right" |
|||
> |
|||
<template slot-scope="scope"> |
|||
<el-button |
|||
size="mini" |
|||
type="text" |
|||
icon="el-icon-edit" |
|||
@click="handleUpdate(scope.row)" |
|||
v-hasPermi="['build:realName:edit']" |
|||
>修改</el-button |
|||
> |
|||
<el-button |
|||
size="mini" |
|||
type="text" |
|||
icon="el-icon-delete" |
|||
@click="handleDelete(scope.row)" |
|||
v-hasPermi="['build:realName:remove']" |
|||
>删除</el-button |
|||
> |
|||
</template> |
|||
</el-table-column> |
|||
</el-table> |
|||
|
|||
<pagination |
|||
v-show="total > 0" |
|||
:total="total" |
|||
:page.sync="queryParams.pageNum" |
|||
:limit.sync="queryParams.pageSize" |
|||
@pagination="getList" |
|||
/> |
|||
|
|||
<!-- 添加或修改农民工人员实名制信息对话框 --> |
|||
<el-dialog |
|||
:title="title" |
|||
:visible.sync="open" |
|||
width="1200px" |
|||
append-to-body |
|||
:close-on-click-modal="false" |
|||
> |
|||
<el-row> |
|||
<el-form ref="form" :model="form" :rules="rules" label-width="180px"> |
|||
<el-col :span="24"> |
|||
<el-form-item label="所属施工单位" prop="belowUnit"> |
|||
<!-- <el-input |
|||
v-model="form.belowUnit" |
|||
placeholder="请输入所属施工单位" |
|||
/> --> |
|||
<el-select |
|||
v-model="form.belowUnit" |
|||
placeholder="请选择所属施工单位" |
|||
filterable |
|||
clearable |
|||
size="small" |
|||
style="width: 100%" |
|||
> |
|||
<el-option |
|||
v-for="dict in firmInfo" |
|||
:key="dict.id" |
|||
:label="dict.enterpriseName" |
|||
:value="dict.enterpriseName" |
|||
@click.native="getSocialCreditCode(dict)" |
|||
/> |
|||
</el-select> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="24"> |
|||
<el-form-item |
|||
label="所属单位统一社会信用代码" |
|||
prop="socialCreditCode" |
|||
> |
|||
<el-input |
|||
v-model="form.socialCreditCode" |
|||
placeholder="请输入所属单位统一社会信用代码" |
|||
readonly |
|||
/> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="24"> |
|||
<el-form-item label="身份证号码" prop="idNo"> |
|||
<el-input v-model="form.idNo" placeholder="请输入身份证号码" /> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="24"> |
|||
<el-form-item label="姓名" prop="name"> |
|||
<el-input v-model="form.name" placeholder="请输入姓名" /> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="24"> |
|||
<el-form-item label="出生日期" prop="birthday"> |
|||
<el-date-picker |
|||
clearable |
|||
size="small" |
|||
style="width: 100%" |
|||
v-model="form.birthday" |
|||
type="date" |
|||
value-format="yyyy-MM-dd" |
|||
placeholder="选择出生日期" |
|||
> |
|||
</el-date-picker> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="24"> |
|||
<el-form-item label="民族" prop="nation"> |
|||
<el-input v-model="form.nation" placeholder="请输入民族" /> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="24"> |
|||
<el-form-item label="籍贯" prop="nativePlace"> |
|||
<el-input v-model="form.nativePlace" placeholder="请输入籍贯" /> |
|||
</el-form-item> |
|||
</el-col> |
|||
</el-form> |
|||
</el-row> |
|||
<div slot="footer" class="dialog-footer"> |
|||
<el-button type="primary" @click="submitForm">确 定</el-button> |
|||
<el-button @click="cancel">取 消</el-button> |
|||
</div> |
|||
</el-dialog> |
|||
</div> |
|||
</template> |
|||
|
|||
<script> |
|||
import { |
|||
listRealName, |
|||
getRealName, |
|||
delRealName, |
|||
addRealName, |
|||
updateRealName, |
|||
exportRealName, |
|||
} from "@/api/build/realName"; |
|||
import { listInfo } from "@/api/build/enteInfo"; |
|||
|
|||
export default { |
|||
name: "RealName", |
|||
props: ["proNo", "proCode"], |
|||
data() { |
|||
return { |
|||
// 遮罩层 |
|||
loading: true, |
|||
// 选中数组 |
|||
ids: [], |
|||
// 非单个禁用 |
|||
single: true, |
|||
// 非多个禁用 |
|||
multiple: true, |
|||
// 显示搜索条件 |
|||
showSearch: true, |
|||
// 总条数 |
|||
total: 0, |
|||
// 农民工人员实名制信息表格数据 |
|||
realNameList: [], |
|||
// 弹出层标题 |
|||
title: "", |
|||
// 是否显示弹出层 |
|||
open: false, |
|||
// 查询参数 |
|||
queryParams: { |
|||
pageNum: 1, |
|||
pageSize: 10, |
|||
ids: null, |
|||
data: { |
|||
socialCreditCode: null, |
|||
idNo: null, |
|||
name: null, |
|||
birthday: null, |
|||
nation: null, |
|||
nativePlace: null, |
|||
createUid: null, |
|||
updateUid: null, |
|||
proCode: null, |
|||
proNo: null, |
|||
owerDept: null, |
|||
}, |
|||
// 排序方式 |
|||
params: { |
|||
// 按哪个字段排序 |
|||
orderBy: "create_time", |
|||
// desc降序,升序asc |
|||
sort: "desc", |
|||
}, |
|||
}, |
|||
// 表单参数 |
|||
form: {}, |
|||
// 表单校验 |
|||
rules: {}, |
|||
// 施工单位 |
|||
firmInfo: [], |
|||
firmInfoQuery: { |
|||
data: { |
|||
proNo: this.proNo, |
|||
proCode: this.proCode, |
|||
}, |
|||
}, |
|||
}; |
|||
}, |
|||
created() { |
|||
this.getList(); |
|||
listInfo(this.firmInfoQuery).then((response) => { |
|||
this.firmInfo = response.data.enterpriseInfoList.filter( |
|||
(item) => item.enterpriseType == "1" |
|||
); |
|||
console.log(" this.firmInfo", this.firmInfo); |
|||
}); |
|||
}, |
|||
methods: { |
|||
getSocialCreditCode(firmData) { |
|||
this.form.socialCreditCode = firmData.socialCreditCode; |
|||
}, |
|||
/** 查询农民工人员实名制信息列表 */ |
|||
getList() { |
|||
this.loading = true; |
|||
this.queryParams.data.proNo = this.proNo; |
|||
this.queryParams.data.proCode = this.proCode; |
|||
listRealName(this.queryParams).then((response) => { |
|||
this.realNameList = response.records; |
|||
this.total = response.total; |
|||
this.loading = false; |
|||
}); |
|||
}, |
|||
// 取消按钮 |
|||
cancel() { |
|||
this.open = false; |
|||
this.reset(); |
|||
}, |
|||
// 表单重置 |
|||
reset() { |
|||
this.form = { |
|||
id: null, |
|||
socialCreditCode: null, |
|||
idNo: null, |
|||
name: null, |
|||
birthday: null, |
|||
nation: null, |
|||
nativePlace: null, |
|||
createUid: null, |
|||
updateUid: null, |
|||
createTime: null, |
|||
updateTime: null, |
|||
proCode: null, |
|||
proNo: null, |
|||
owerDept: null, |
|||
remark: null, |
|||
}; |
|||
this.resetForm("form"); |
|||
}, |
|||
// 查询表单重置 |
|||
resetQueryForm() { |
|||
this.queryParams = { |
|||
pageNum: 1, |
|||
pageSize: 10, |
|||
data: { |
|||
id: null, |
|||
socialCreditCode: null, |
|||
idNo: null, |
|||
name: null, |
|||
birthday: null, |
|||
nation: null, |
|||
nativePlace: null, |
|||
createUid: null, |
|||
updateUid: null, |
|||
createTime: null, |
|||
updateTime: null, |
|||
proCode: null, |
|||
proNo: null, |
|||
owerDept: null, |
|||
remark: null, |
|||
}, |
|||
}; |
|||
this.resetForm("form"); |
|||
}, |
|||
/** 搜索按钮操作 */ |
|||
handleQuery() { |
|||
this.queryParams.pageNum = 1; |
|||
this.getList(); |
|||
}, |
|||
/** 重置按钮操作 */ |
|||
resetQuery() { |
|||
this.resetQueryForm(); |
|||
this.handleQuery(); |
|||
}, |
|||
// 多选框选中数据 |
|||
handleSelectionChange(selection) { |
|||
this.ids = selection.map((item) => item.id); |
|||
this.single = selection.length !== 1; |
|||
this.multiple = !selection.length; |
|||
}, |
|||
/** 新增按钮操作 */ |
|||
handleAdd() { |
|||
this.reset(); |
|||
this.open = true; |
|||
this.title = "添加农民工人员实名制信息"; |
|||
}, |
|||
/** 修改按钮操作 */ |
|||
handleUpdate(row) { |
|||
this.reset(); |
|||
const id = row.id || this.ids; |
|||
getRealName(id).then((response) => { |
|||
this.form = response.data; |
|||
this.open = true; |
|||
this.title = "修改农民工人员实名制信息"; |
|||
}); |
|||
}, |
|||
/** 提交按钮 */ |
|||
submitForm() { |
|||
this.$refs["form"].validate((valid) => { |
|||
if (valid) { |
|||
this.form.proNo = this.proNo; |
|||
this.form.proCode = this.proCode; |
|||
if (this.form.id != null) { |
|||
updateRealName(this.form).then((response) => { |
|||
if (response.code === 200) { |
|||
this.msgSuccess("修改成功"); |
|||
this.open = false; |
|||
this.getList(); |
|||
} |
|||
}); |
|||
} else { |
|||
addRealName(this.form).then((response) => { |
|||
if (response.code === 200) { |
|||
this.msgSuccess("新增成功"); |
|||
this.open = false; |
|||
this.getList(); |
|||
} |
|||
}); |
|||
} |
|||
} |
|||
}); |
|||
}, |
|||
/** 删除按钮操作 */ |
|||
handleDelete(row) { |
|||
const ids = row.id || this.ids; |
|||
if (ids) { |
|||
this.$confirm("是否删除选中的数据?", "警告", { |
|||
confirmButtonText: "确定", |
|||
cancelButtonText: "取消", |
|||
type: "warning", |
|||
}) |
|||
.then(function () { |
|||
return delRealName(ids); |
|||
}) |
|||
.then(() => { |
|||
this.getList(); |
|||
this.msgSuccess("删除成功"); |
|||
}) |
|||
.catch(function () {}); |
|||
} else { |
|||
this.$message.warning("请选择要删除的数据!!"); |
|||
} |
|||
}, |
|||
}, |
|||
}; |
|||
</script> |
|||
<style lang="scss" scoped> |
|||
@import "@/assets/css/dialog.scss"; |
|||
// ::v-deep { |
|||
// .el-dialog { |
|||
// margin-top: 10vh !important; |
|||
// } |
|||
// } |
|||
</style> |
Loading…
Reference in new issue