文化活动活动时间可以选择时分秒;职工慰问收款人固定为申请人

This commit is contained in:
2026-10-14 18:59:41 +08:00
parent e784b5d4a8
commit c350485fbe
6 changed files with 38 additions and 86 deletions
@@ -116,14 +116,17 @@ const ACTIVITY_CULTURE_APPLY_ACTIVITY = {
<el-col :span="12">
<el-form-item label="实际活动时间" prop="time">
<!-- 三类文化活动共用此表单,活动起止时间均保留到秒。 -->
<el-date-picker
end-placeholder="结束日期"
align="right"
end-placeholder="结束时间"
range-separator="-"
start-placeholder="开始日期"
start-placeholder="开始时间"
style="width: 100%"
type="daterange"
format="yyyy-MM-dd HH:mm:ss"
type="datetimerange"
v-model="formData.time"
value-format="yyyy-MM-dd">
value-format="yyyy-MM-dd HH:mm:ss">
</el-date-picker>
</el-form-item>
</el-col>
@@ -3,7 +3,7 @@ layout("/layouts/platform.html"){
#-->
<div id="app" v-cloak>
<el-card shadow="never">
<custom-card>
<snaker-start slot="header" label="职工慰问" define_key="ZGWW"></snaker-start>
<el-form :model="formData" ref="formRef" :rules="formRules" label-width="0" label-suffix=":"
class="flow-task-form">
@@ -89,24 +89,7 @@ layout("/layouts/platform.html"){
<!-- </el-form-item>-->
<!-- </el-descriptions-item>-->
<el-descriptions-item label="收款人">
<el-form-item prop="payUserId" label="收款人">
<el-select style="width: 100%"
v-model="formData.payUserId"
filterable
clearable
remote
reserve-keyword
placeholder="请输入姓名或工号查询"
:remote-method="createRemoteMethod(payUserOptions)"
@change="payUserChange">
<el-option
v-for="item in payUserOptions"
:key="item.id"
:label="item.userName+'('+item.loginName+')'+'('+item.unitName+')'"
:value="item.id">
</el-option>
</el-select>
</el-form-item>
{{formData.applyUserName}}
</el-descriptions-item>
<el-descriptions-item label="慰问类型">
<el-form-item prop="type" label="慰问类型">
@@ -239,7 +222,7 @@ layout("/layouts/platform.html"){
</el-descriptions-item>
</el-descriptions>
</el-form>
<el-row type="flex" justify="end" class="mt20">
<template slot="footer">
<el-button type="primary" plain @click="onSave" :loading="submitLoading">
{{ submitLoading ? "提交中..." : "保存" }}
</el-button>
@@ -249,8 +232,8 @@ layout("/layouts/platform.html"){
<el-button type="primary" @click="onFinishTask" :loading="submitLoading" v-else>
{{ submitLoading ? "提交中..." : "提交" }}
</el-button>
</el-row>
</el-card>
</template>
</custom-card>
</div>
<script nonce="${cspNonce!}">
@@ -267,7 +250,6 @@ layout("/layouts/platform.html"){
submitLoading: false,
formRules: {
helpUserId: [{required: true, message: "必填", trigger: ["change", "blur"]}],
payUserId: [{required: true, message: "必填", trigger: ["change", "blur"]}],
type: [{required: true, message: "必填", trigger: ["change", "blur"]}],
way: [{required: true, message: "必填", trigger: ["change", "blur"]}],
money: [{required: true, message: "必填", trigger: ["change", "blur"]}],
@@ -291,7 +273,6 @@ layout("/layouts/platform.html"){
hospitalizationTime: [{required: true, message: "必填", trigger: ["change", "blur"]}],
},
chooseType: {},
payUserOptions: [],
helpUserOptions: [],
typeOptions: [],
@@ -350,14 +331,6 @@ layout("/layouts/platform.html"){
this.$set(this.formData, "certifierUnionName", unionName)
}
},
payUserChange(val) {
const user = this.payUserOptions.find(o => o.id === val)
if (user) {
const {userName, loginName} = user
this.$set(this.formData, "payUserName", userName)
this.$set(this.formData, "payLoginName", loginName)
}
},
typeChange(id) {
this.chooseType = this.typeOptions.find(o => o.id === id)
if (this.chooseType) {
@@ -436,7 +409,6 @@ layout("/layouts/platform.html"){
if (res.code === 0) {
this.formData = res.data
this.selectQueryUser(this.formData.helpLoginName, this.helpUserOptions)
this.selectQueryUser(this.formData.payLoginName, this.payUserOptions)
this.selectQueryUser(this.formData.certifierLoginName, this.certifierUserOptions)
this.selectQueryUser(this.formData.handlerLoginName, this.handlerUserOptions)
this.chooseType = this.typeOptions.find(o => o.id === this.formData.type)
@@ -150,39 +150,13 @@ layout("/layouts/platform_h5.html"){
<!-- </van-action-sheet>-->
<van-field
v-model="formData.payUserName"
:value="formData.applyUserName"
name="payUserName"
label="收款人"
required
readonly
:rules="[{ required: true }]"
placeholder="请点击选择收款人"
@click="payUserSelectShow = true"
is-link
></van-field>
<van-action-sheet v-model="payUserSelectShow" title="收款人" class="height100">
<van-search
v-model="searchKeyword"
:show-action="false"
:reverse-color="false"
input-align="left"
placeholder="请输入工号或姓名选择收款人"
@input="(val) => {userRemoteMethod(val, 'pay')}"
@clear="(val) => {userRemoteMethod(val, 'pay')}"
shape="round"
></van-search>
<div class="van-action-sheet__content mt5" v-if="userOptions && userOptions.length>0">
<template>
<template v-for="item in userOptions">
<van-button native-type="button" @click="payUserChange(item)"
class="van-action-sheet__item van-hairline--bottom">
<span class="van-action-sheet__name">{{item.userName}}({{item.loginName}})</span>
</van-button>
</template>
</template>
</div>
<van-empty description="暂无数据" v-else></van-empty>
</van-action-sheet>
<van-field
v-model="formData.typeName"
@@ -409,7 +383,6 @@ layout("/layouts/platform_h5.html"){
typeOptions: [],
helpUserSelectShow: false,
payUserSelectShow: false,
showTypePicker: false,
typeColumns: [],
searchKeyword: "",
@@ -498,8 +471,6 @@ layout("/layouts/platform_h5.html"){
this.certifierUserSelectShow = true
} else if (type === "handler") {
this.handlerUserSelectShow = true
}else if (type === "pay") {
this.payUserSelectShow = true
}
}
},
@@ -521,15 +492,6 @@ layout("/layouts/platform_h5.html"){
this.searchKeyword = ""
this.userOptions = []
},
payUserChange(user) {
const { id, userName, loginName } = user
this.$set(this.formData, "payUserId", id)
this.$set(this.formData, "payUserName", userName)
this.$set(this.formData, "payLoginName", loginName)
this.payUserSelectShow = false
this.searchKeyword = ""
this.userOptions = []
},
typeChange(id) {
this.chooseType = this.typeOptions.find(o => o.id === id)
if (this.chooseType) {
@@ -615,7 +577,6 @@ layout("/layouts/platform_h5.html"){
if (res.code === 0) {
this.formData = res.data
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)
}
})