feat: 慰问、困难帮扶

This commit is contained in:
2026-10-30 17:49:45 +08:00
parent 16cae3ed2b
commit f8457386fd
22 changed files with 207 additions and 290 deletions
@@ -43,9 +43,9 @@ public class DifficultHelpApprovalController {
}
ProcessTask task = dao.fetch(ProcessTask.class, args.getLong(FlowConst.PROCESS_TASK_ID_KEY));
if (task == null) throw new BaseException("审批任务不存在");
boolean amountApproval = "36ebafda-44c2-4bd3-bd7f-10839a575a0d".equals(task.getTaskName())
|| "715ece82-4ae3-433c-ad18-ed875f45d1e3".equals(task.getTaskName());
if (!amountApproval && !"e405f96c-5fc0-4f63-b323-e69dfe853253".equals(task.getTaskName())) {
boolean amountApproval = "715ece82-4ae3-433c-ad18-ed875f45d1e3".equals(task.getTaskName());
if (!amountApproval && !"36ebafda-44c2-4bd3-bd7f-10839a575a0d".equals(task.getTaskName())
&& !"e405f96c-5fc0-4f63-b323-e69dfe853253".equals(task.getTaskName())) {
throw new BaseException("当前任务不是困难帮扶审批任务");
}
ProcessInstance instance = dao.fetch(ProcessInstance.class, task.getProcessInstanceId());
@@ -54,24 +54,23 @@ public class DifficultHelpApprovalController {
if (StrUtil.isBlank(args.getStr("tf_sign"))) throw new BaseException("请完成审批签字");
if (StrUtil.isBlank(args.getStr("tf_opinion"))) throw new BaseException("请填写审批意见");
String level = args.getStr("level");
Integer submitType = args.getInt(FlowConst.SUBMIT_TYPE);
boolean skipAmount = "36ebafda-44c2-4bd3-bd7f-10839a575a0d".equals(task.getTaskName())
&& (ProcessSubmitTypeEnum.REJECT.getCode().equals(submitType)
|| ProcessSubmitTypeEnum.ROLLBACK_TO_OPERATOR.getCode().equals(submitType));
Double money = amountApproval && !skipAmount ? args.getDouble("money") : null;
if (amountApproval && !skipAmount) {
if (StrUtil.isBlank(level) || money == null || !Double.isFinite(money) || money < 0) {
throw new BaseException("请填写完整的级别和帮扶金额");
args.remove("level");
args.remove("tf_level");
Double money = amountApproval ? args.getDouble("money") : null;
if (amountApproval) {
if (money == null || !Double.isFinite(money) || money < 0) {
throw new BaseException("请填写有效的帮扶金额");
}
args.put("tf_level", level);
args.put("tf_money", money);
} else {
args.remove("money");
args.remove("tf_money");
}
// 参与者权限由流程引擎校验,业务入口不接受客户端指定管理员代办。
args.remove(FlowConst.EXT_ENABLE_OPERATOR);
flowCommonService.executeTask(args);
if (amountApproval && Integer.valueOf(ProcessSubmitTypeEnum.AGREE.getCode()).equals(args.getInt(FlowConst.SUBMIT_TYPE))) {
dao.update(DifficultHelpInfo.class, Chain.make("level", level).add("money", money), Cnd.where("id", "=", info.getId()));
dao.update(DifficultHelpInfo.class, Chain.make("money", money), Cnd.where("id", "=", info.getId()));
}
return Result.success();
}
@@ -1,6 +1,7 @@
package com.budwk.app.zhgh.staffbenefit.difficulthelp.controller;
import cn.dev33.satoken.annotation.SaCheckPermission;
import cn.dev33.satoken.annotation.SaMode;
import cn.hutool.core.util.StrUtil;
import com.budwk.app.base.annotation.SLog;
import com.budwk.app.base.page.Pagination;
@@ -137,7 +138,7 @@ public class DifficultHelpMineController {
@At
@ApiModelProperty("获取困难补助申请")
@SaCheckPermission("difficultHelp.mine")
@SaCheckPermission(value = {"difficultHelp.mine", "difficultHelp.reading"}, mode = SaMode.OR)
public Result findOne(String id) {
DifficultHelpInfo helpInfo = dao.fetch(DifficultHelpInfo.class, id);
return Result.success().addData(helpInfo);
@@ -154,7 +154,7 @@ public class DifficultHelpReadingController {
""");
Cnd cnd = Cnd.NEW();
cnd.and("ins.state", "=", 20);
pageParam.buildSearch(cnd, "info.");
pageParam.buildSearch(cnd, "info.", false);
cnd.groupBy("info.id");
sql.setCondition(cnd);
Pagination<NutMap> pagination = difficultHelpCommonService.listPageMap(pageParam.getPageNumber(), pageParam.getPageSize(), sql);
@@ -238,6 +238,7 @@ public class DifficultHelpReadingController {
@At
@Ok("void")
@SaCheckPermission("difficultHelp.reading")
public void doExportAllApply(DifficultHelpPageParam pageParam, HttpServletResponse response) throws Exception {
Sql sql = Sqls.create("""
SELECT
@@ -268,7 +269,7 @@ public class DifficultHelpReadingController {
$condition
""");
Cnd cnd = Cnd.NEW();
pageParam.buildSearch(cnd, "info.");
pageParam.buildSearch(cnd, "info.", false);
cnd.groupBy("info.id");
sql.setCondition(cnd);
List<NutMap> list = difficultHelpCommonService.listMap(sql);
@@ -469,6 +470,7 @@ public class DifficultHelpReadingController {
@At
@Ok("void")
@SaCheckPermission("difficultHelp.reading")
public void exportSummary(DifficultHelpPageParam pageParam,String flag,
HttpServletResponse response) throws Exception {
NutMap result = new NutMap();
@@ -498,7 +500,7 @@ public class DifficultHelpReadingController {
$condition
""");
Cnd cnd = Cnd.NEW();
pageParam.buildSearch(cnd, "info.");
pageParam.buildSearch(cnd, "info.", false);
cnd.groupBy("info.id");
sql.setCondition(cnd);
List<NutMap> list = difficultHelpCommonService.listMap(sql);
@@ -90,6 +90,7 @@ public class SpecialCondolenceMineController {
Sql sql = Sqls.create("""
SELECT
info.*,
COALESCE(recipientTotals.recipientCount, 0) AS recipientCount,
type.name as typeName,
ins.id AS instanceId,
ins.businessNo,
@@ -109,6 +110,12 @@ public class SpecialCondolenceMineController {
(select MAX(id) from wf_process_task where processInstanceId = ins.id and taskName = 'startTask') AS startTaskId
FROM
special_condolence info
LEFT JOIN (
SELECT applyId, COUNT(*) AS recipientCount
FROM special_condolence_recipient
WHERE delFlag = false
GROUP BY applyId
) recipientTotals ON recipientTotals.applyId = info.id
LEFT JOIN special_condolence_type type ON info.type = type.id
LEFT JOIN `wf_process_instance` ins ON ins.businessNo = info.id
LEFT JOIN (
@@ -0,0 +1,98 @@
<template>
<div class="h5-user-select">
<van-field v-bind="$attrs" :value="displayName" readonly clickable is-link @click="open"></van-field>
<van-popup v-model="visible" position="bottom" round get-container="body" class="h5-user-select-popup">
<div class="h5-user-select-popup__header">
<van-button native-type="button" type="default" size="small" @click="visible = false">取消</van-button>
<strong>选择慰问对象</strong>
<van-button native-type="button" type="info" size="small" :disabled="!pendingUser" @click="confirm">确认</van-button>
</div>
<van-search v-model="keyword" placeholder="请输入姓名或工号查询" @input="scheduleSearch" @search="search" @clear="search"></van-search>
<div class="h5-user-select-popup__list">
<div v-if="loading" class="h5-user-select-popup__status"><van-loading size="24px">加载中</van-loading></div>
<div v-else-if="error" class="h5-user-select-popup__status"><span class="h5-user-select-popup__error">{{ error }}</span><van-button native-type="button" size="small" @click="search">重新加载</van-button></div>
<van-empty v-else-if="!options.length" description="未找到本工会人员"></van-empty>
<template v-else>
<van-cell v-for="person in options" :key="person.id" clickable
:class="{ 'h5-user-select-popup__selected': pendingUser && pendingUser.id === person.id }"
:title="person.userName + (person.loginName ? '(' + person.loginName + ')' : '')"
:label="[person.unitName, person.personType].filter(Boolean).join(' · ')"
@click="pendingUser = person">
<van-icon v-if="pendingUser && pendingUser.id === person.id" name="success" color="#1989fa"></van-icon>
</van-cell>
</template>
</div>
</van-popup>
</div>
</template>
<script>
module.exports = {
inheritAttrs: false,
model: { prop: 'value', event: 'change' },
props: {
value: { type: String, default: '' },
displayName: { type: String, default: '' },
api: { type: String, required: true }
},
data() {
return { visible: false, keyword: '', options: [], pendingUser: null, loading: false, error: '', searchTimer: null, requestId: 0 }
},
beforeDestroy() {
clearTimeout(this.searchTimer)
this.requestId++
},
methods: {
open() {
this.keyword = ''
this.pendingUser = null
this.visible = true
this.search()
},
scheduleSearch() {
clearTimeout(this.searchTimer)
this.requestId++
this.pendingUser = null
this.loading = true
this.searchTimer = setTimeout(() => this.search(), 250)
},
async search() {
clearTimeout(this.searchTimer)
const requestId = ++this.requestId
this.loading = true
this.error = ''
this.pendingUser = null
try {
const result = await this.$axios.post(this.api, { keyword: this.keyword })
if (requestId !== this.requestId) return
if (result.code !== 0) throw new Error(result.msg || '人员加载失败')
this.options = result.data || []
} catch (error) {
if (requestId !== this.requestId) return
this.options = []
this.error = error.message || '人员加载失败'
} finally {
if (requestId === this.requestId) this.loading = false
}
},
confirm() {
if (!this.pendingUser) return
const person = this.pendingUser
this.$emit('change', person.id)
this.$emit('selected', person, person.id)
this.visible = false
}
}
}
</script>
<style>
.h5-user-select-popup { display: flex; flex-direction: column; height: 72vh; max-height: 640px; padding-bottom: env(safe-area-inset-bottom); box-sizing: border-box; }
.h5-user-select-popup__header { display: flex; align-items: center; justify-content: space-between; flex-shrink: 0; padding: 14px 16px; border-bottom: 1px solid #ebedf0; }
.h5-user-select-popup__header strong { font-size: 16px; color: #323233; }
.h5-user-select-popup__header .van-button { min-width: 56px; }
.h5-user-select-popup__list { flex: 1; min-height: 0; overflow-y: auto; -webkit-overflow-scrolling: touch; }
.h5-user-select-popup__selected { background: #edf6ff; }
.h5-user-select-popup__status { display: flex; align-items: center; justify-content: center; flex-direction: column; gap: 12px; padding: 40px 16px; }
.h5-user-select-popup__error { color: #ee0a24; }
</style>
@@ -106,7 +106,9 @@ module.exports = {
}
},
onChange(val) {
const selected = this.options.find(item => String(item[this.option_value]) === String(val)) || null
this.$emit("change", val)
this.$emit("selected", selected, val)
},
clearOptions() {
@@ -114,7 +116,7 @@ module.exports = {
}
},
created() {
this.clearOptions()
this.options = this.option_list || []
console.log(this.placeholder)
}
}
@@ -62,13 +62,7 @@ layout("/layouts/platform.html"){
<el-button @click="onView(row)" size="mini" type="primary">查看</el-button>
<el-button v-if="row.taskKey === 'startTask' || !row.instanceId" @click="onEdit(row)" size="mini" type="primary">编辑</el-button>
<el-button v-if="row.canRevoke" size="mini" type="danger" @click="onRevoke(row)">撤回</el-button>
<el-dropdown v-if="row.createdBy === $store.state.user.id && row.instanceState == 20" trigger="click" @command="format => doExportApply(row, format)">
<el-button size="mini" type="primary">导出</el-button>
<el-dropdown-menu slot="dropdown">
<el-dropdown-item command="pdf">导出 PDF</el-dropdown-item>
<el-dropdown-item command="word">导出 Word</el-dropdown-item>
</el-dropdown-menu>
</el-dropdown>
<el-button v-if="row.createdBy === $store.state.user.id && row.instanceState == 20" @click="doExportApply(row)" size="mini" type="primary">导出</el-button>
<el-button v-if="row.taskKey === 'startTask' || !row.instanceId" @click="onDelete(row.id)" size="mini" type="danger">
删除
</el-button>
@@ -109,8 +103,8 @@ layout("/layouts/platform.html"){
}
},
methods: {
doExportApply(row, format) {
this.$downLoad('/platform/condolence/mine/doExportApply?id=' + row.id + '&print=' + (format === 'pdf'))
doExportApply(row) {
this.$downLoad('/platform/condolence/mine/doExportApply?id=' + row.id + '&print=false')
},
onAdd() {
commonUtil.pjaxPush('/platform/condolence/apply')
@@ -1,17 +1,5 @@
<div id="difficult_help_branch_union_approval_form">
<el-form :model="formData" ref="formRef" label-width="100px" label-suffix=":">
<el-row :gutter="20">
<el-col :span="12">
<el-form-item label="级别" prop="level" :rules="[{required:true,message:'请选择级别',trigger:['change','blur']}]">
<dict-select v-model="formData.level" code="DIFFICULT_LEVEL" style="width: 100%" placeholder="请选择级别"></dict-select>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="帮扶金额" prop="money" :rules="[{required:true,message:'请填写帮扶金额',trigger:['change','blur']}]">
<el-input-number v-model="formData.money" style="width: 100%" :precision="2" :min="0" placeholder="请输入帮扶金额"></el-input-number>
</el-form-item>
</el-col>
</el-row>
<el-form-item label="审批意见" prop="tf_opinion" :rules="[{required:true,message:'必填',trigger:['change','blur']}]">
<user-opinion-textarea v-model="formData.tf_opinion"></user-opinion-textarea>
</el-form-item>
@@ -29,8 +17,6 @@
return {
businessId: GetQueryString("businessId"),
formData: {
level: "",
money: undefined,
tf_sign: "", tf_opinion: ""
},
}
@@ -84,18 +84,6 @@ layout("/layouts/platform.html"){
<el-dialog title="设置帮扶审批信息" :visible.sync="batchVisible" width="760px">
<el-form :model="batchForm" ref="batchFormRef" label-width="130px">
<el-row :gutter="20">
<el-col :span="12">
<el-form-item label="级别" prop="level" :rules="[{required:true,message:'请选择级别',trigger:['change','blur']}]">
<dict-select v-model="batchForm.level" code="DIFFICULT_LEVEL" style="width: 100%" placeholder="请选择级别"></dict-select>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="帮扶金额(元)" prop="money" :rules="[{required:true,message:'请填写帮扶金额',trigger:['change','blur']}]">
<el-input-number v-model="batchForm.money" style="width: 100%" :precision="2" :min="0" placeholder="请输入帮扶金额"></el-input-number>
</el-form-item>
</el-col>
</el-row>
<el-form-item label="审批意见" prop="tf_opinion" :rules="[{required:true,whitespace:true,message:'请填写审批意见',trigger:['change','blur']}]">
<user-opinion-textarea v-model="batchForm.tf_opinion"></user-opinion-textarea>
</el-form-item>
@@ -113,18 +101,6 @@ layout("/layouts/platform.html"){
{{formData.taskName}}
</div>
<el-form :model="formData" ref="formRef" :rules="formRules" label-width="100px" label-suffix=":">
<el-row :gutter="20">
<el-col :span="12">
<el-form-item label="级别" prop="level" :rules="[{required:true,message:'请选择级别',trigger:['change','blur']}]">
<dict-select v-model="formData.level" code="DIFFICULT_LEVEL" style="width: 100%" placeholder="请选择级别"></dict-select>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="帮扶金额" prop="money" :rules="[{required:true,message:'请填写帮扶金额',trigger:['change','blur']}]">
<el-input-number v-model="formData.money" style="width: 100%" :precision="2" :min="0" placeholder="请输入帮扶金额"></el-input-number>
</el-form-item>
</el-col>
</el-row>
<el-form-item label="审批意见" prop="tf_opinion"
:rules="[{required:true,message:'必填',trigger:['change','blur']}]">
<user-opinion-textarea v-model="formData.tf_opinion"></user-opinion-textarea>
@@ -178,7 +154,7 @@ layout("/layouts/platform.html"){
formData: {},
batchVisible: false,
batchForm: {level: "", money: undefined, tf_sign: "", tf_opinion: ""},
batchForm: {tf_sign: "", tf_opinion: ""},
showApprovalForm: false,
selectData: []
}
@@ -208,7 +184,7 @@ layout("/layouts/platform.html"){
return;
}
this.batchForm = {level: "", money: undefined, tf_sign: "", tf_opinion: ""}
this.batchForm = {tf_sign: "", tf_opinion: ""}
this.batchVisible = true
},
async submitBatch() {
@@ -295,8 +271,6 @@ layout("/layouts/platform.html"){
this.formData = {
processTaskId: row.taskId,
taskName: row.curTaskName,
level: "",
money: undefined,
tf_sign: "", tf_opinion: ""
}
this.$refs.infoRef.onOpen(row)
@@ -305,16 +279,7 @@ layout("/layouts/platform.html"){
async handleTaskAction(val) {
try {
let valid
if (val === 2 || val === 6) {
this.$refs.formRef.clearValidate(['level', 'money'])
const results = await Promise.all(['tf_opinion', 'tf_sign'].map(prop => new Promise(resolve => {
this.$refs.formRef.validateField(prop, error => resolve(!error))
})))
valid = results.every(result => result)
} else {
valid = await this.$refs.formRef.validate()
}
const valid = await this.$refs.formRef.validate()
if (!valid) return
} catch (error) {
return
@@ -72,13 +72,7 @@ layout("/layouts/platform.html"){
</el-button>
<el-button v-if="row.createdBy === $store.state.user.id && row.canRevoke" @click="onRevoke(row)" size="mini" type="danger">撤回
</el-button>
<el-dropdown v-if="row.createdBy === $store.state.user.id && row.instanceState == 20" trigger="click" @command="format => doExportApply(row, format)">
<el-button size="mini" type="primary">导出</el-button>
<el-dropdown-menu slot="dropdown">
<el-dropdown-item command="pdf">导出 PDF</el-dropdown-item>
<el-dropdown-item command="word">导出 Word</el-dropdown-item>
</el-dropdown-menu>
</el-dropdown>
<el-button v-if="row.createdBy === $store.state.user.id && row.instanceState == 20" @click="doExportApply(row)" size="mini" type="primary">导出</el-button>
<el-button v-if="row.createdBy === $store.state.user.id && (row.taskKey === 'startTask' || !row.instanceId)" @click="onDelete(row.id)" size="mini" type="danger">删除</el-button>
</template>
</el-table-column>
@@ -187,8 +181,8 @@ layout("/layouts/platform.html"){
this.units = await this.$businessTool.listUnit((this.$store.state.user.union || {}).id || this.pageForm.unionId)
}
},
doExportApply(row, format) {
this.$downLoad('/platform/difficultHelp/reading/doExportApply?id=' + row.id + '&print=' + (format === 'pdf'))
doExportApply(row) {
this.$downLoad('/platform/difficultHelp/reading/doExportApply?id=' + row.id + '&print=false')
}
},
async created() {
@@ -178,11 +178,7 @@ layout("/layouts/platform.html"){
},
async flushUnits(){
this.$set(this.pageForm, "unitId", null)
if (this.$auth.hasRoleOr('SYSADMIN, SCHOOL_UNION_ADMIN')) {
this.units = await this.$businessTool.listUnit(this.pageForm.unionId)
} else {
this.units = await this.$businessTool.listUnit((this.$store.state.user.union || {}).id || this.pageForm.unionId)
}
this.units = await this.$businessTool.listUnit(this.pageForm.unionId)
},
exportYearPayRecord(){
this.$downLoad('/platform/difficultHelp/reading/exportYearPayRecord', this.pageForm)
@@ -204,11 +200,7 @@ layout("/layouts/platform.html"){
},
async created() {
this.pageData()
if (this.$auth.hasRoleOr('SYSADMIN, SCHOOL_UNION_ADMIN')) {
this.unions = await this.$businessTool.listUnion()
} else {
this.unions = await this.$businessTool.listUnion((this.$store.state.user.union || {}).id)
}
this.unions = await this.$businessTool.listUnion()
}
})
</script>
@@ -1,11 +1,6 @@
<div id="difficult_help_branch_union_approval_form">
<el-form :model="formData" ref="formRef" label-width="100px" label-suffix=":">
<el-row :gutter="20">
<el-col :span="12">
<el-form-item label="级别" prop="level" :rules="[{required:true,message:'请选择级别',trigger:['change','blur']}]">
<dict-select v-model="formData.level" code="DIFFICULT_LEVEL" style="width: 100%" placeholder="请选择级别"></dict-select>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="帮扶金额" prop="money" :rules="[{required:true,message:'请填写帮扶金额',trigger:['change','blur']}]">
<el-input-number v-model="formData.money" style="width: 100%" :precision="2" :min="0" placeholder="请输入帮扶金额"></el-input-number>
@@ -29,7 +24,6 @@
return {
businessId: GetQueryString("businessId"),
formData: {
level: "",
money: undefined,
tf_sign: "", tf_opinion: ""
},
@@ -84,11 +84,6 @@ layout("/layouts/platform.html"){
<el-dialog title="设置帮扶审批信息" :visible.sync="batchVisible" width="760px">
<el-form :model="batchForm" ref="batchFormRef" label-width="130px">
<el-row :gutter="20">
<el-col :span="12">
<el-form-item label="级别" prop="level" :rules="[{required:true,message:'请选择级别',trigger:['change','blur']}]">
<dict-select v-model="batchForm.level" code="DIFFICULT_LEVEL" style="width: 100%" placeholder="请选择级别"></dict-select>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="帮扶金额(元)" prop="money" :rules="[{required:true,message:'请填写帮扶金额',trigger:['change','blur']}]">
<el-input-number v-model="batchForm.money" style="width: 100%" :precision="2" :min="0" placeholder="请输入帮扶金额"></el-input-number>
@@ -113,11 +108,6 @@ layout("/layouts/platform.html"){
</div>
<el-form :model="formData" ref="formRef" :rules="formRules" label-width="100px" label-suffix=":">
<el-row :gutter="20">
<el-col :span="12">
<el-form-item label="级别" prop="level" :rules="[{required:true,message:'请选择级别',trigger:['change','blur']}]">
<dict-select v-model="formData.level" code="DIFFICULT_LEVEL" style="width: 100%" placeholder="请选择级别"></dict-select>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="帮扶金额" prop="money" :rules="[{required:true,message:'请填写帮扶金额',trigger:['change','blur']}]">
<el-input-number v-model="formData.money" style="width: 100%" :precision="2" :min="0" placeholder="请输入帮扶金额"></el-input-number>
@@ -177,7 +167,7 @@ layout("/layouts/platform.html"){
formData: {},
batchVisible: false,
batchForm: {level: "", money: undefined, tf_sign: "", tf_opinion: ""},
batchForm: {money: undefined, tf_sign: "", tf_opinion: ""},
showApprovalForm: false,
selectData: [],
}
@@ -201,7 +191,7 @@ layout("/layouts/platform.html"){
this.$message.warning('请勾选待审核数据!');
return;
}
this.batchForm = {level: "", money: undefined, tf_sign: "", tf_opinion: ""}
this.batchForm = {money: undefined, tf_sign: "", tf_opinion: ""}
this.batchVisible = true
},
async submitBatch() {
@@ -288,7 +278,6 @@ layout("/layouts/platform.html"){
this.formData = {
processTaskId: row.taskId,
taskName: row.curTaskName,
level: "",
money: undefined,
tf_sign: "", tf_opinion: ""
}
@@ -207,7 +207,7 @@ layout("/layouts/platform.html"){
this.$axios.post("/platform/special_condolence/apply/save", { data: JSON.stringify(this.formData) }).then(res => {
if (res.code === 0) {
this.$message.success(res.msg)
commonUtil.pjaxPush("/platform/special_condolence/mine")
window.location.replace("/platform/special_condolence/mine")
}
})
})
@@ -226,7 +226,7 @@ layout("/layouts/platform.html"){
}).then(res => {
if (res.code === 0) {
this.$message.success(res.msg)
commonUtil.pjaxPush("/platform/special_condolence/mine")
window.location.replace("/platform/special_condolence/mine")
}
})
})
@@ -247,7 +247,7 @@ layout("/layouts/platform.html"){
}).then(res => {
if (res.code === 0) {
this.$message.success(res.msg)
commonUtil.pjaxPush("/platform/special_condolence/mine")
window.location.replace("/platform/special_condolence/mine")
}
})
})
@@ -61,3 +61,7 @@
.special-condolence-apply .special-condolence-table-item .el-table .el-form-item { margin: 8px 0 20px; }
.special-condolence-apply .special-condolence-table-item .el-table .el-form-item__error { position: absolute; padding: 4px 0 0; font-size: 11px; line-height: 14px; white-space: normal; }
.special-condolence-apply .flow-task-form .el-form-item__error { color: #f56c6c !important; }
.special-condolence-apply .el-form-item.is-error .el-input__inner,
.special-condolence-apply .el-form-item.is-error .el-textarea__inner { border-color: #f56c6c; }
@@ -32,7 +32,7 @@
<el-form-item prop="recipients" label-width="0" class="special-condolence-table-item">
<el-table :data="formData.recipients" border stripe size="small" max-height="520" empty-text="暂无慰问对象,点击新增或从 Excel 导入">
<el-table-column type="index" label="序号" width="55" align="center" fixed="left"></el-table-column>
<el-table-column label="慰问对象" width="200" fixed="left"><template slot-scope="s"><el-form-item :prop="'recipients.' + s.$index + '.helpUserId'" :rules="recipientRules.helpUserId"><user-select size="small" :ref="'recipientUser' + s.$index" v-model="s.row.helpUserId" api="/platform/special_condolence/apply/listUser" api_input_key_name="keyword" :option_list="recipientOptions(s.row)" :option_label_func="item => item.userName + '(' + (item.loginName || '') + ')'" @hook:mounted="seedRecipientOptions(s.row, s.$index)" @change="id => recipientUserChange(s.row, s.$index, id)"></user-select></el-form-item></template></el-table-column>
<el-table-column label="慰问对象" width="200" fixed="left"><template slot-scope="s"><el-form-item :prop="'recipients.' + s.$index + '.helpUserId'" :rules="recipientRules.helpUserId"><user-select size="small" v-model="s.row.helpUserId" api="/platform/special_condolence/apply/listUser" api_input_key_name="keyword" :option_list="recipientOptions(s.row)" :option_label_func="item => item.userName + '(' + (item.loginName || '') + ')'" @selected="(user, id) => recipientUserChange(s.row, s.$index, id, user)"></user-select></el-form-item></template></el-table-column>
<el-table-column label="工号" min-width="150"><template slot-scope="s"><el-form-item :prop="'recipients.' + s.$index + '.helpLoginName'" :rules="[{ validator: (rule, value, cb) => cb(s.row.personType === '劳务派遣人员' || value ? undefined : new Error('普通人员工号不能为空')), trigger: 'change' }]"><el-input size="small" v-model="s.row.helpLoginName" readonly placeholder="选人后带出,劳务派遣可空"></el-input></el-form-item></template></el-table-column>
<el-table-column label="身份证号码" min-width="205"><template slot-scope="s"><el-form-item :prop="'recipients.' + s.$index + '.idCard'" :rules="recipientRules.idCard"><el-input size="small" v-model="s.row.idCard" maxlength="18" placeholder="请输入18位身份证号"></el-input></el-form-item></template></el-table-column>
<el-table-column label="开户行" min-width="190"><template slot-scope="s"><el-form-item :prop="'recipients.' + s.$index + '.bankOfDeposit'" :rules="recipientRules.bankOfDeposit"><el-input size="small" v-model="s.row.bankOfDeposit" maxlength="100" placeholder="请输入开户银行及支行"></el-input></el-form-item></template></el-table-column>
@@ -37,15 +37,9 @@ const specialCondolenceRecipients = {
return '10X98765432'[weights.reduce((sum, weight, index) => sum + weight * Number(card[index]), 0) % 11] === card[17]
},
recipientOptions(row) {
return row.helpUserId ? [{ id: row.helpUserId, userName: row.helpUserName, loginName: row.helpLoginName }] : []
return row.helpUserId ? [{ id: row.helpUserId, userName: row.helpUserName, loginName: row.helpLoginName, personType: row.personType, idCard: row.idCard, bankOfDeposit: row.bankOfDeposit, bankUserName: row.bankUserName, bankCardNumber: row.bankCardNumber }] : []
},
seedRecipientOptions(row, index) {
const component = this.$refs['recipientUser' + index]
if (component && row.helpUserId) component.options = this.recipientOptions(row)
},
recipientUserChange(row, index, id) {
const component = this.$refs['recipientUser' + index]
const user = component && component.options.find(item => item.id === id)
recipientUserChange(row, index, id, user) {
this.$set(row, 'helpUserId', user ? user.id : '')
this.$set(row, 'helpUserName', user ? user.userName : '')
this.$set(row, 'helpLoginName', user ? user.loginName : '')
@@ -54,7 +48,13 @@ const specialCondolenceRecipients = {
this.$set(row, 'bankOfDeposit', user ? user.bankOfDeposit || '' : '')
this.$set(row, 'bankUserName', user ? user.bankUserName || user.userName : '')
this.$set(row, 'bankCardNumber', user ? user.bankCardNumber || '' : '')
this.$nextTick(() => this.$refs.formRef.validateField('recipients.' + index + '.helpUserId'))
this.$nextTick(() => {
const fields = ['helpUserId', 'helpLoginName', 'idCard', 'bankOfDeposit', 'bankUserName', 'bankCardNumber']
const names = fields.map(field => 'recipients.' + index + '.' + field)
const form = this.$refs.formRef
if (typeof form.validateField === 'function') form.validateField(names)
else if (typeof form.validate === 'function') form.validate(names).catch(() => {})
})
},
newRecipient() {
@@ -62,13 +62,7 @@ layout("/layouts/platform.html"){
<el-button @click="onView(row)" size="mini" type="primary">查看</el-button>
<el-button v-if="row.taskKey === 'startTask' || !row.instanceId" @click="onEdit(row)" size="mini" type="primary">编辑</el-button>
<el-button v-if="row.canRevoke" size="mini" type="danger" @click="onRevoke(row)">撤回</el-button>
<el-dropdown v-if="row.createdBy === $store.state.user.id && row.instanceState == 20" trigger="click" @command="format => doExportApply(row, format)">
<el-button size="mini" type="primary">导出</el-button>
<el-dropdown-menu slot="dropdown">
<el-dropdown-item command="pdf">导出 PDF</el-dropdown-item>
<el-dropdown-item command="word">导出 Word</el-dropdown-item>
</el-dropdown-menu>
</el-dropdown>
<el-button v-if="row.createdBy === $store.state.user.id && row.instanceState == 20" @click="doExportApply(row)" size="mini" type="primary">导出</el-button>
<el-button v-if="row.taskKey === 'startTask' || !row.instanceId" @click="onDelete(row.id)" size="mini" type="danger">
删除
</el-button>
@@ -96,21 +90,22 @@ layout("/layouts/platform.html"){
data() {
return {
typeOptions: [],
pageDataUrl: "/platform/special_condolence/mine/pageData",
tableColumns: [
{prop: 'helpUserName', label: '慰问对象'},
{prop: 'helpLoginName', label: '慰问对象工号'},
{prop: 'applyUserName', label: '申请人'},
{prop: 'applyUnionName', label: '所属工会'},
{prop: 'applyUnitName', label: '所属单位'},
{prop: 'typeName', label: '慰问类型'},
{prop: 'recipientCount', label: '慰问人数', width: 100},
{prop: 'taskName', label: '当前节点'},
{prop: 'instanceState', label: '流程状态'},
],
}
},
methods: {
doExportApply(row, format) {
this.$downLoad('/platform/special_condolence/mine/doExportApply?id=' + row.id + '&print=' + (format === 'pdf'))
doExportApply(row) {
this.$downLoad('/platform/special_condolence/mine/doExportApply?id=' + row.id + '&print=false')
},
onAdd() {
commonUtil.pjaxPush('/platform/special_condolence/apply')
@@ -114,33 +114,6 @@ layout("/layouts/platform_h5.html"){
审批意见<span class="difficult-help-audit-card__required">*</span>
</h2>
<van-form ref="formRef">
<section class="difficult-help-info-card">
<h2 class="difficult-help-info-card__title">审核信息</h2>
<div class="difficult-help-audit-form">
<van-field
v-model="formData.level"
class="difficult-help-audit-select"
name="level"
label="级别"
placeholder="请选择级别"
readonly
is-link
required
@click="openLevelPicker"
:rules="[{ required: true, message: '请选择级别' }]"
></van-field>
<van-field
v-model="formData.money"
class="difficult-help-audit-money"
name="money"
label="帮扶金额(元)"
placeholder="请输入帮扶金额(元)"
type="number"
required
:rules="[{ required: true, message: '请输入帮扶金额(元)' }]"
></van-field>
</div>
</section>
<van-field
v-model="formData.tf_opinion"
class="difficult-help-audit-textarea"
@@ -167,14 +140,6 @@ layout("/layouts/platform_h5.html"){
</div>
</div>
</info>
<van-popup :value="showLevelPicker" position="bottom" :close-on-click-overlay="false">
<van-picker
show-toolbar
:columns="levelColumns"
@confirm="onLevelConfirm"
@cancel="closeLevelPicker">
</van-picker>
</van-popup>
<van-dialog
:value="confirmVisible"
title="提示"
@@ -214,8 +179,6 @@ layout("/layouts/platform_h5.html"){
skeletonLoading: true,
formData: {},
levelColumns: [],
showLevelPicker: false,
showApprovalForm: false,
formLoading: false,
confirmVisible: false,
@@ -280,42 +243,11 @@ layout("/layouts/platform_h5.html"){
this.$set(this, "formData", {
processTaskId: row.taskId,
taskName: row.curTaskName,
level: "",
money: undefined,
tf_sign: "", tf_opinion: ""
})
this.$refs.infoRef.onOpen(row, row.curTaskName || "帮扶审核")
},
// 加载困难级别字典并转换为 Vant Picker 所需的 text/value 结构。
initLevelDict() {
return this.$axios.post("/open/common/dictOptions", {code: "DIFFICULT_LEVEL"}, {h5SkeletonLoading: true}).then((res) => {
const levelData = res && res.code === 0 ? res.data : []
this.$set(this, "levelColumns", (levelData || []).map((item) => ({
text: item.name,
value: item.code
})))
})
},
// 级别选择器作为详情上层弹框,打开时同步增加浏览器历史。
openLevelPicker() {
if (window.h5HistoryLayerManager && window.h5HistoryLayerManager.open("difficult-help-level-picker")) return
this.$set(this, "showLevelPicker", true)
},
closeLevelPicker(afterClose = null) {
if (window.h5HistoryLayerManager && window.h5HistoryLayerManager.close("difficult-help-level-picker", afterClose)) return
this.$set(this, "showLevelPicker", false)
if (typeof afterClose === "function") afterClose()
},
onLevelConfirm(option) {
this.closeLevelPicker(() => {
this.$set(this.formData, "level", option.value)
})
},
// val 为流程提交类型:1 同意、2 拒绝、6 退回;校验通过后打开历史栈确认框。
handleTaskAction(val) {
this.$refs.formRef.validate()
@@ -427,14 +359,12 @@ layout("/layouts/platform_h5.html"){
},
},
created() {
// 先订阅弹框状态,工会加载异常也不能阻断等级选择器与确认框的打开、返回。
// 先订阅弹框状态,工会加载异常也不能阻断确认框的打开、返回。
if (window.h5HistoryLayerManager) {
this.$set(this, "historyLayerUnsubscribe", window.h5HistoryLayerManager.subscribe((stack) => {
this.$set(this, "confirmVisible", stack.includes("difficult-help-action-confirm"))
this.$set(this, "showLevelPicker", stack.includes("difficult-help-level-picker"))
}))
}
this.initLevelDict()
// 缓存已就绪时立即加载,否则等待用户接口回填;只初始化一次,避免重置已选筛选条件。
// $watch 由当前 Vue 实例管理,页面销毁时自动注销。
let filtersInitialized = false
@@ -113,18 +113,6 @@ layout("/layouts/platform_h5.html"){
<section class="difficult-help-info-card">
<h2 class="difficult-help-info-card__title">审核信息</h2>
<div class="difficult-help-audit-form">
<van-field
v-model="formData.level"
class="difficult-help-audit-select"
name="level"
label="级别"
placeholder="请选择级别"
readonly
is-link
required
@click="openLevelPicker"
:rules="[{ required: true, message: '请选择级别' }]"
></van-field>
<van-field
v-model="formData.money"
class="difficult-help-audit-money"
@@ -167,14 +155,6 @@ layout("/layouts/platform_h5.html"){
</div>
</div>
</info>
<van-popup :value="showLevelPicker" position="bottom" :close-on-click-overlay="false">
<van-picker
show-toolbar
:columns="levelColumns"
@confirm="onLevelConfirm"
@cancel="closeLevelPicker">
</van-picker>
</van-popup>
<van-dialog
:value="confirmVisible"
title="提示"
@@ -216,8 +196,6 @@ layout("/layouts/platform_h5.html"){
formData: {},
showApprovalForm: false,
formLoading: false,
showLevelPicker: false,
levelColumns: [],
confirmVisible: false,
confirmActionType: "task",
pendingSubmitType: null,
@@ -272,42 +250,12 @@ layout("/layouts/platform_h5.html"){
this.$set(this, "formData", {
processTaskId: row.taskId,
taskName: row.curTaskName,
level: "",
money: undefined,
tf_sign: "", tf_opinion: ""
})
this.$refs.infoRef.onOpen(row, row.curTaskName || "帮扶审核")
},
// 加载困难级别字典并转换为 Vant Picker 所需的 text/value 结构。
initLevelDict() {
return this.$axios.post("/open/common/dictOptions", {code: "DIFFICULT_LEVEL"}, {h5SkeletonLoading: true}).then((res) => {
const levelData = res && res.code === 0 ? res.data : []
this.$set(this, "levelColumns", (levelData || []).map((item) => ({
text: item.name,
value: item.code
})))
})
},
// 级别选择器作为详情上层弹框,打开时同步增加浏览器历史。
openLevelPicker() {
if (window.h5HistoryLayerManager && window.h5HistoryLayerManager.open("difficult-help-level-picker")) return
this.$set(this, "showLevelPicker", true)
},
closeLevelPicker(afterClose = null) {
if (window.h5HistoryLayerManager && window.h5HistoryLayerManager.close("difficult-help-level-picker", afterClose)) return
this.$set(this, "showLevelPicker", false)
if (typeof afterClose === "function") afterClose()
},
onLevelConfirm(option) {
this.closeLevelPicker(() => {
this.$set(this.formData, "level", option.value)
})
},
// val 为流程提交类型:1 同意、2 拒绝、6 退回;校验通过后打开历史栈确认框。
handleTaskAction(val) {
this.$refs.formRef.validate()
@@ -420,11 +368,9 @@ layout("/layouts/platform_h5.html"){
},
created() {
this.initUnion().then(() => this.flushUnits())
this.initLevelDict()
if (!window.h5HistoryLayerManager) return
this.$set(this, "historyLayerUnsubscribe", window.h5HistoryLayerManager.subscribe((stack) => {
this.$set(this, "confirmVisible", stack.includes("difficult-help-action-confirm"))
this.$set(this, "showLevelPicker", stack.includes("difficult-help-level-picker"))
}))
},
beforeDestroy() {
@@ -162,6 +162,9 @@ layout("/layouts/platform_h5.html"){
#app .van-picker-column__item {
font-size: 18px;
}
.specialcondolence-apply-form .van-field__error-message,
.specialcondolence-apply-form .van-field--error .van-field__control { color: #ee0a24 !important; }
.specialcondolence-apply-form .van-field__error-message { font-size: 12px; line-height: 18px; padding-top: 4px; }
</style>
<div id="app">
@@ -185,19 +188,22 @@ layout("/layouts/platform_h5.html"){
<van-field label="申请人工会" :rules="[{ required: true }]" v-model="formData.applyUnionName" readonly
required name="applyUnionName"></van-field>
<van-field label="慰问类型" required><template #input><select v-model="formData.type" @change="typeChange(formData.type)"><option value="">请选择</option><option v-for="t in typeOptions" :key="t.id" :value="t.id">{{t.name}}</option></select></template></van-field>
<van-field v-model="formData.perMoney" label="每人金额" type="number" required :rules="[{ validator: validateMoney, message: '金额须大于0且不超过10000元,最多两位小数' }]"></van-field>
<van-field v-model="formData.occurTime" label="慰问时间" placeholder="yyyy-MM-dd" required :rules="[{required:true}]"></van-field>
<van-field :value="chooseType.name || formData.typeName" name="type" label="慰问类型" readonly clickable is-link required placeholder="请选择慰问类型" :rules="[{ validator: () => !!formData.type, message: '请选择慰问类型' }]" @click="showTypePickerClick"></van-field>
<van-popup v-model="showTypePicker" position="bottom" round get-container="body"><van-picker :columns="typeColumns" :default-index="typeDefaultIndex" show-toolbar @confirm="onTypeConfirm" @cancel="showTypePicker = false"></van-picker></van-popup>
<van-field v-model="formData.perMoney" name="perMoney" label="每人金额" type="number" required :rules="[{ validator: validateMoney, message: '金额须大于0且不超过10000元,最多两位小数' }]"></van-field>
<van-field v-model="formData.occurTime" name="occurTime" label="慰问时间" readonly clickable is-link placeholder="请选择慰问时间" required :rules="[{ validator: value => $moment(value, 'YYYY-MM-DD', true).isValid(), message: '请选择有效慰问时间' }]" @click="showTimePickerClick"></van-field>
<van-popup v-model="showTimePicker" position="bottom" round get-container="body"><van-datetime-picker v-model="formData.occurDate" type="date" :min-date="minDate" :max-date="new Date(2100, 11, 31)" title="请选择慰问时间" @confirm="confirmOccurTime" @cancel="showTimePicker = false"></van-datetime-picker></van-popup>
<div v-for="(person, index) in formData.recipients" :key="index">
<van-cell :title="'慰问对象 ' + (index + 1)"><van-button native-type="button" size="mini" @click="formData.recipients.splice(index, 1)">删除</van-button></van-cell>
<van-field v-model="person.helpUserName" label="慰问对象" required :rules="[{required:true}]"></van-field>
<van-field v-model="person.helpLoginName" label="工号" placeholder="普通人员必填,劳务派遣可空"></van-field>
<van-field v-model="person.idCard" label="身份证号码" maxlength="18" required :rules="[{required:true}]"></van-field>
<van-field v-model="person.bankOfDeposit" label="开户行" maxlength="100" required :rules="[{required:true}]"></van-field>
<van-field v-model="person.bankUserName" label="户名" maxlength="100" required :rules="[{required:true}]"></van-field>
<van-field v-model="person.bankCardNumber" label="收款账户" maxlength="30" required :rules="[{required:true}]"></van-field>
<h5-user-select v-model="person.helpUserId" :display-name="person.helpUserName" api="/platform/special_condolence/apply/listUser" label="慰问对象" placeholder="点击选择本工会人员" required :name="'recipients.' + index + '.helpUserId'" :rules="mobileRecipientRules('helpUserId', person)" @selected="(user, id) => recipientUserChange(person, index, id, user)"></h5-user-select>
<van-field v-model="person.helpLoginName" label="工号" readonly placeholder="选人后带出,劳务派遣可空" :required="person.personType !== '劳务派遣人员'" :name="'recipients.' + index + '.helpLoginName'" :rules="mobileRecipientRules('helpLoginName', person)"></van-field>
<van-field v-model="person.idCard" label="身份证号码" maxlength="18" required :name="'recipients.' + index + '.idCard'" :rules="mobileRecipientRules('idCard', person)"></van-field>
<van-field v-model="person.bankOfDeposit" label="开户行" maxlength="100" required :name="'recipients.' + index + '.bankOfDeposit'" :rules="mobileRecipientRules('bankOfDeposit', person)"></van-field>
<van-field v-model="person.bankUserName" label="户名" maxlength="100" required :name="'recipients.' + index + '.bankUserName'" :rules="mobileRecipientRules('bankUserName', person)"></van-field>
<van-field v-model="person.bankCardNumber" label="收款账户" maxlength="30" required :name="'recipients.' + index + '.bankCardNumber'" :rules="mobileRecipientRules('bankCardNumber', person)"></van-field>
</div>
<van-button native-type="button" @click="formData.recipients.push(newRecipient())">增加一行</van-button>
<van-field name="recipients" :value="recipientCount" :rules="[{ validator: value => Number(value) > 0, message: '请至少添加一位慰问对象' }]"><template #input><van-button native-type="button" size="small" type="info" plain @click="formData.recipients.push(newRecipient())">增加一行</van-button></template></van-field>
<van-cell title="慰问金额合计" :value="'¥ ' + recipientTotal + '(' + recipientCount + '人)'"></van-cell>
<van-field
v-model="formData.remark"
name="remark"
@@ -263,7 +269,9 @@ layout("/layouts/platform_h5.html"){
el: "#app",
store,
mixins: [specialCondolenceRecipients],
components: {},
components: {
'h5-user-select': httpVueLoader('/components/plugins/sysUserSelect/h5Index.vue?v=' + h5ComponentVersion)
},
data() {
return {
bizId: GetQueryString("bizId"),
@@ -297,6 +305,17 @@ layout("/layouts/platform_h5.html"){
}
},
methods: {
mobileRecipientRules(field, person) {
const names = { helpUserId: '慰问对象', helpLoginName: '工号', idCard: '身份证号码', bankOfDeposit: '开户行', bankUserName: '户名', bankCardNumber: '收款账户' }
if (field === 'helpLoginName') return [{ validator: value => person.personType === '劳务派遣人员' || !!String(value || '').trim(), message: '普通人员工号不能为空' }]
if (field === 'helpUserId') return [{ validator: () => !!person.helpUserId, message: '请选择慰问对象' }]
const rules = [{ validator: value => !!String(value || '').trim(), message: '请填写' + names[field] }]
if (field === 'idCard') rules.push({ validator: value => this.validRecipientIdCard(value), message: '身份证号码不正确' })
if (field === 'bankCardNumber') rules.push({ pattern: /^[0-9]{6,30}$/, message: '收款账户须为6至30位数字' })
if (field === 'bankOfDeposit' || field === 'bankUserName') rules.push({ validator: value => String(value || '').length <= 100, message: names[field] + '最多100字' })
return rules
},
validateMoney(value) {
return /^(0|[1-9][0-9]*)(\.[0-9]{1,2})?$/.test(String(value)) && Number(value) > 0 && Number(value) <= 10000
},
@@ -316,13 +335,14 @@ layout("/layouts/platform_h5.html"){
},
// 选择慰问时间
showTimePickerClick() {
if (this.formData.occurTime) {
this.formData.occurDate = new Date(this.formData.occurTime)
}else{
this.formData.occurDate = new Date()
}
this.$set(this.formData, 'occurDate', this.formData.occurTime ? this.$moment(this.formData.occurTime, 'YYYY-MM-DD').toDate() : new Date())
this.showTimePicker = true
},
confirmOccurTime(value) {
this.$set(this.formData, 'occurTime', this.$moment(value).format('YYYY-MM-DD'))
this.showTimePicker = false
this.$nextTick(() => this.$refs.formRef.validate('occurTime').catch(() => {}))
},
// 选择慰问类型
showTypePickerClick() {
if (this.formData.type) {
@@ -411,6 +431,7 @@ layout("/layouts/platform_h5.html"){
this.showTypePicker = false
},
onSave() {
this.$refs.formRef.validate().then(() => {
this.$dialog.confirm({
title: "提示",
message: "您确定保存吗?"
@@ -418,10 +439,11 @@ layout("/layouts/platform_h5.html"){
this.$axios.post("/platform/special_condolence/apply/save", { data: JSON.stringify(this.formData) }).then(res => {
if (res.code === 0) {
this.$toast(res.msg)
this.$pjaxReplace("/platform/special_condolence/mine/h5")
window.location.replace("/platform/special_condolence/mine/h5")
}
})
})
}).catch(() => {})
},
async onSubmit() {
this.$refs.formRef.validate().then(() => {
@@ -436,7 +458,7 @@ layout("/layouts/platform_h5.html"){
this.$axios.post("/platform/special_condolence/apply/submit", { data: JSON.stringify(this.formData) }).then(res => {
if (res.code === 0) {
this.$toast(res.msg)
this.$pjaxReplace("/platform/special_condolence/mine/h5")
window.location.replace("/platform/special_condolence/mine/h5")
}
})
})
@@ -458,7 +480,7 @@ layout("/layouts/platform_h5.html"){
}).then(res => {
if (res.code === 0) {
this.$toast(res.msg)
this.$pjaxReplace("/platform/special_condolence/mine/h5")
window.location.replace("/platform/special_condolence/mine/h5")
}
})
})
@@ -470,9 +492,7 @@ layout("/layouts/platform_h5.html"){
if (res.code === 0) {
this.formData = res.data
this.initRecipients()
this.selectQueryUser(this.formData.helpLoginName, this.helpUserOptions)
this.selectQueryUser(this.formData.payLoginName, this.payUserOptions)
this.chooseType = this.typeOptions.find(o => o.id === this.formData.type)
this.chooseType = this.typeOptions.find(o => o.id === this.formData.type) || {}
}
})
} else {
@@ -328,7 +328,6 @@ layout("/layouts/platform_h5.html"){
<div class="specialcondolence-card-header">
<div class="specialcondolence-card-heading">
<div class="specialcondolence-card-title">{{row.helpUserName || '--'}}</div>
<div class="specialcondolence-card-code">工号:{{row.helpLoginName || '--'}}</div>
</div>
<enum-tag class="specialcondolence-card-status" v-if="row.instanceState" :value="row.instanceState"
name="ProcessInstanceStateEnum" label_key="message" size="small"></enum-tag>
@@ -336,11 +335,11 @@ layout("/layouts/platform_h5.html"){
</template>
<template v-slot="{index,row}">
<table-column label="慰问对象">{{row.helpUserName}}</table-column>
<table-column label="慰问对象工号">{{row.helpLoginName}}</table-column>
<table-column label="申请人">{{row.applyUserName}}</table-column>
<table-column label="所属工会">{{row.applyUnionName}}</table-column>
<table-column label="所属单位">{{row.applyUnitName}}</table-column>
<table-column label="慰问类型">{{row.typeName}}</table-column>
<table-column label="慰问人数">{{row.recipientCount}} 人</table-column>
<table-column label="当前节点">{{row.taskName}}</table-column>
</template>
<template #actions="{index,row}">