This commit is contained in:
2025-09-09 20:25:19 +08:00
parent 7e9ec112f1
commit 2a1d1e11ed
212 changed files with 3716 additions and 863 deletions
@@ -1,190 +1,194 @@
<template>
<div>
<van-uploader
v-model="fileList"
:before-read="beforeRead"
:after-read="afterRead"
multiple
progress
:accept="accept"
:max-count="upload_number"
title=""
description=""
tip=""
></van-uploader>
</div>
<div>
<van-uploader
v-model="fileList"
:before-read="beforeRead"
:after-read="afterRead"
multiple
progress
:accept="accept"
:max-count="upload_number"
title=""
description=""
tip=""
></van-uploader>
</div>
</template>
<script>
module.exports = {
name: "h5Index",
props: {
// 上传返回id
upload_return_id_api: {
type: String,
default: "/platform/sys/file/uploadLocalReturnId",
required: false
},
// 上传返回url
upload_dynamic_return_url_api: {
type: String,
default: "/platform/sys/file/uploadDynamicReturnUrl",
required: false
},
// 当上传接口为id的情况下,配置下载接口
upload_id_download_url: {
type: String,
default: "/platform/sys/file/download?id=",
required: false
},
// 上传样式或图片方式 file || drag || image
upload_mode: {
type: String,
default: "file",
required: false
},
// 上传数量
upload_number: {
type: Number,
default: 1,
required: false
},
// 上传返回id或url
upload_result_type: {
type: String,
default: "url",
required: false
},
// 上传返回分类 数组或字符串逗号隔离 interval | array
upload_result_category: {
type: String,
default: "interval",
required: false
},
// 跟antdv官方一样,是否显示文件列表
show_upload_list: {
type: Boolean,
default: true,
required: false
},
// 跟antdv官方一样,接受上传的文件类型
accept: {
type: String,
default: "",
required: false
},
// 是否是完整的结果(就是文件上传返回什么,该组件返回什么,uploadResultCategory必须为array
complete_result: {
type: Boolean,
default: false,
required: false
},
// 父组件传来的参数
value: {
type: [String, Array],
required: false
}
name: "h5Index",
props: {
// 上传返回id
upload_return_id_api: {
type: String,
default: "/platform/sys/file/uploadLocalReturnId",
required: false
},
data() {
return {
fileList: [
// { url: "http://localhost:8080/platform/sys/file/download?id=rn1v1efh2ag0aps59ult3ebudf", isImage: true }
]
}
// 上传返回url
upload_dynamic_return_url_api: {
type: String,
default: "/platform/sys/file/uploadDynamicReturnUrl",
required: false
},
watch: {
value: {
handler: function (val) {
if (val) {
if (Array.isArray(val)) {
this.fileList = val.map((v) => {
return {
...v,
status: null,
isImage: ["jpg", "jpeg", "png", "gif", "bmp", "webp"].includes(v.name.split(".").pop().toLowerCase())
}
})
} else {
val = JSON.parse(val)
this.fileList = val.map((v) => {
return {
...v,
url: v.url ? v.url : v.response?.data,
isImage: ["jpg", "jpeg", "png", "gif", "bmp", "webp"].includes(v.name.split(".").pop().toLowerCase()),
status: null
}
})
}
} else {
this.fileList = []
}
console.log(this.fileList)
},
immediate: true
}
// 当上传接口为id的情况下,配置下载接口
upload_id_download_url: {
type: String,
default: "/platform/sys/file/download?id=",
required: false
},
computed: {
action() {
return this.upload_result_type === "id" ? this.upload_return_id_api : this.upload_dynamic_return_url_api
}
// 上传样式或图片方式 file || drag || image
upload_mode: {
type: String,
default: "file",
required: false
},
methods: {
beforeRead(file) {
return true
},
afterRead(files) {
const uploadPromises = this.fileList
.filter((f) => f.status === "loading")
.map((f) => {
const formData = new FormData()
formData.append("file", f.file)
return this.$axios.post(this.action, formData).then((resp) => {
if (resp.code === 0) {
console.log(resp)
f.name = f.file.name
f.size = f.file.size
f.status = null
f.url = resp.data
f.response = resp
f.percentage = 100
f.isImage = true
delete f.file
delete f.content
console.log(f)
} else {
f.status = "fail"
}
})
// 上传数量
upload_number: {
type: Number,
default: 1,
required: false
},
// 上传返回id或url
upload_result_type: {
type: String,
default: "url",
required: false
},
// 上传返回分类 数组或字符串逗号隔离 interval | array
upload_result_category: {
type: String,
default: "interval",
required: false
},
// 跟antdv官方一样,是否显示文件列表
show_upload_list: {
type: Boolean,
default: true,
required: false
},
// 跟antdv官方一样,接受上传的文件类型
accept: {
type: String,
default: "",
required: false
},
// 是否是完整的结果(就是文件上传返回什么,该组件返回什么,uploadResultCategory必须为array
complete_result: {
type: Boolean,
default: false,
required: false
},
// 父组件传来的参数
value: {
type: [String, Array],
required: false
}
},
data() {
return {
fileList: [
// { url: "http://localhost:8080/platform/sys/file/download?id=rn1v1efh2ag0aps59ult3ebudf", isImage: true }
]
}
},
watch: {
value: {
handler: function (val) {
if (val) {
if (Array.isArray(val)) {
this.fileList = val.map((v) => {
return {
...v,
status: null,
isImage: ["jpg", "jpeg", "png", "gif", "bmp", "webp"].includes(v.name.split(".").pop().toLowerCase())
}
})
} else {
val = JSON.parse(val)
this.fileList = val.map((v) => {
return {
...v,
url: v.url ? v.url : v.response?.data,
isImage: ["jpg", "jpeg", "png", "gif", "bmp", "webp"].includes(v.name.split(".").pop().toLowerCase()),
status: null
}
})
}
} else {
this.fileList = []
}
},
immediate: true
}
},
computed: {
action() {
return this.upload_result_type === "id" ? this.upload_return_id_api : this.upload_dynamic_return_url_api
}
},
methods: {
beforeRead(file) {
return true
},
afterRead(files) {
this.fileList.map((f) => {
if (f.file && f.file.name === files.file.name ) {
f.status = "loading"
}
})
const uploadPromises = this.fileList
.filter((f) => f.status === "loading")
.map((f) => {
const formData = new FormData()
formData.append("file", f.file)
return this.$axios.post(this.action, formData).then((resp) => {
if (resp.code === 0) {
f.name = f.file.name
f.size = f.file.size
f.status = null
f.url = resp.data
f.response = resp
f.percentage = 100
f.isImage = true
delete f.file
delete f.content
} else {
f.status = "fail"
}
})
})
Promise.all(uploadPromises)
.then(() => {
if (this.upload_result_category === "interval") {
} else if (this.upload_result_category === "array") {
if (this.complete_result) {
this.$emit("update:value", this.fileList)
} else {
const resultArrayValue = []
this.fileList.forEach((data) => {
resultArrayValue.push(data.response.data)
})
Promise.all(uploadPromises)
.then(() => {
if (this.upload_result_category === "interval") {
} else if (this.upload_result_category === "array") {
if (this.complete_result) {
this.$emit("update:value", this.fileList)
} else {
const resultArrayValue = []
this.fileList.forEach((data) => {
resultArrayValue.push(data.response.data)
})
this.$emit("update:value", resultArrayValue)
}
}
})
.catch((error) => {
console.error("所有上传请求失败:", error)
})
}
},
created() {}
this.$emit("update:value", resultArrayValue)
}
}
})
.catch((error) => {
console.error("所有上传请求失败:", error)
})
}
},
created() {
}
}
</script>
<style scoped>
.van-uploader__title {
padding-left: 0;
padding-left: 0;
}
.van-uploader__wrapper {
margin-left: 0;
margin-left: 0;
}
</style>
@@ -26,8 +26,8 @@ layout("/layouts/platform.html"){
</search-item>
<search-item label="报名状态">
<el-radio-group @change="activityInfoData" v-model="pageForm.applyStatus">
<el-radio-button :label="1">未报名</el-radio-button>
<el-radio-button :label="2">已报名</el-radio-button>
<el-radio-button :label="1">未报名</el-radio-button>
</el-radio-group>
</search-item>
</search>
@@ -186,7 +186,7 @@ layout("/layouts/platform.html"){
activityList: [],
pageForm: {
isActivity: 2,
applyStatus: 2,
applyStatus: 1,
year: new Date().getFullYear() + ""
},
activityData: {},
@@ -124,7 +124,6 @@ layout("/layouts/platform.html"){
</el-descriptions-item>
<el-descriptions-item label="备注">
<el-form-item prop="note"
:rules="[{required:true,message:'必填',trigger:['change','blur']}]">
@@ -224,7 +223,7 @@ layout("/layouts/platform.html"){
// 保存
onSave() {
const msg = this.validateBirthday()
if ( msg){
if (msg) {
this.$message.warning(msg)
return
}
@@ -250,28 +249,32 @@ layout("/layouts/platform.html"){
// 提交
onSubmit() {
const msg = this.validateBirthday()
if ( msg){
if (msg) {
this.$message.warning(msg)
return
}
this.getIsRepeatByIdCard().then(flag => {
if (flag) {
this.$refs.formRef.validate((valid) => {
if (valid) {
this.getIsRepeatByIdCard().then(flag => {
if (flag) {
} else {
this.$confirm("您确定要提交吗?", "提示", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning"
}).then(() => {
this.$axios.post('/platform/enrollmentRegistration/apply/submit', {
data: JSON.stringify(this.formData),
taskId: GetQueryString("taskId")
}).then(res => {
if (res.code === 0) {
this.$message.success("提交成功")
window.location.href = '/platform/enrollmentRegistration/applyList/index'
}
})
} else {
this.$confirm("您确定要提交吗?", "提示", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning"
}).then(() => {
this.$axios.post('/platform/enrollmentRegistration/apply/submit', {
data: JSON.stringify(this.formData),
taskId: GetQueryString("taskId")
}).then(res => {
if (res.code === 0) {
this.$message.success("提交成功")
window.location.href = '/platform/enrollmentRegistration/applyList/index'
}
})
})
}
})
}
})
@@ -279,28 +282,32 @@ layout("/layouts/platform.html"){
},
onFinishTask() {
const msg = this.validateBirthday()
if ( msg){
if (msg) {
this.$message.warning(msg)
return
}
this.getIsRepeatByIdCard().then(flag => {
if (flag) {
this.$refs.formRef.validate((valid) => {
if (valid) {
this.getIsRepeatByIdCard().then(flag => {
if (flag) {
} else {
this.$confirm("您确定要提交吗?", "提示", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning"
}).then(() => {
this.$axios.post('/platform/enrollmentRegistration/apply/submitAgain', {
data: JSON.stringify(this.formData),
taskId: GetQueryString("taskId")
}).then(res => {
if (res.code === 0) {
this.$message.success("提交成功")
window.location.href = '/platform/enrollmentRegistration/applyList/index'
}
})
} else {
this.$confirm("您确定要提交吗?", "提示", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning"
}).then(() => {
this.$axios.post('/platform/enrollmentRegistration/apply/submitAgain', {
data: JSON.stringify(this.formData),
taskId: GetQueryString("taskId")
}).then(res => {
if (res.code === 0) {
this.$message.success("提交成功")
window.location.href = '/platform/enrollmentRegistration/applyList/index'
}
})
})
}
})
}
})
@@ -75,7 +75,7 @@ layout("/layouts/platform.html"){
</template>
</el-table-column>
<el-table-column prop="applyTime" label="填报时间"></el-table-column>
<el-table-column prop="taskName" label="当前节点"></el-table-column>
<el-table-column prop="curTaskName" label="当前节点"></el-table-column>
<el-table-column prop="instanceState" label="流程状态">
<template v-slot="{row}">
<enum-tag :value="row.instanceState" name="ProcessInstanceStateEnum" label_key="message"
@@ -60,7 +60,7 @@ layout("/layouts/platform.html"){
</template>
</el-table-column>
<el-table-column prop="applyTime" label="填报时间"></el-table-column>
<el-table-column prop="taskName" label="当前节点"></el-table-column>
<el-table-column prop="curTaskName" label="当前节点"></el-table-column>
<el-table-column prop="instanceState" label="流程状态">
<template v-slot="{row}">
<enum-tag :value="row.instanceState" name="ProcessInstanceStateEnum" label_key="message"
@@ -93,11 +93,9 @@ layout("/layouts/platform.html"){
:rules="[{required:true,message:'必填',trigger:['change','blur']}]">
<user-opinion-textarea v-model="formData.tf_opinion"></user-opinion-textarea>
</el-form-item>
<!--
:rules="[{required:true,message:'必填',trigger:['change','blur']}]"
-->
<el-form-item label="签字" prop="tf_userSign"
>
:rules="[{required:true,message:'必填',trigger:['change','blur']}]">
<pc-signature v-model="formData.tf_userSign"></pc-signature>
</el-form-item>
</el-form>
@@ -27,7 +27,6 @@ layout("/layouts/platform.html"){
<el-table-column prop="honorTypeName" label="荣誉类型"></el-table-column>
<el-table-column label="操作" width="200px">
<template slot-scope="{row}">
<el-button size="mini" type="primary" @click="openView(row)">查看</el-button>
<el-button size="mini" type="primary" @click="openApply(row)">申请</el-button>
</template>
</el-table-column>
@@ -38,6 +37,9 @@ layout("/layouts/platform.html"){
<template #edit>
<apply_form ref="applyFormRef" @refresh=""></apply_form>
</template>
<template #view>
<info ref="infoRef"></info>
</template>
</guava>
</div>
@@ -57,8 +59,6 @@ layout("/layouts/platform.html"){
}
},
methods: {
openView(row) {
},
openApply(row) {
$.post("/platform/evaluate/apply/valid", {id: row.id}).then((res) => {
if (res.code === 0) {
@@ -50,7 +50,7 @@ layout("/layouts/platform.html"){
<el-table-column prop="mobile" label="联系方式"></el-table-column>
<el-table-column prop="applyDateTime" label="申请时间"></el-table-column>
<el-table-column prop="honorName" label="类型" show-overflow-tooltip></el-table-column>
<el-table-column prop="taskName" label="当前节点"></el-table-column>
<el-table-column prop="curTaskName" label="当前节点"></el-table-column>
<el-table-column prop="instanceState" label="流程状态">
<template v-slot="{row}">
<enum-tag :value="row.instanceState" name="ProcessInstanceStateEnum" label_key="message"
@@ -58,7 +58,7 @@ layout("/layouts/platform.html"){
<el-table-column prop="mobile" label="联系方式"></el-table-column>
<el-table-column prop="honorName" label="类型" show-overflow-tooltip></el-table-column>
<el-table-column prop="applyDateTime" label="申请时间"></el-table-column>
<el-table-column prop="taskName" label="当前节点"></el-table-column>
<el-table-column prop="curTaskName" label="当前节点"></el-table-column>
<el-table-column prop="instanceState" label="流程状态">
<template v-slot="{row}">
<enum-tag :value="row.instanceState" name="ProcessInstanceStateEnum" label_key="message"
@@ -67,7 +67,7 @@ layout("/layouts/platform.html"){
<el-table-column prop="activityMatter" label="活动项目"></el-table-column>
<el-table-column prop="declareTotalBudgetMoney" label="申报预算金额"></el-table-column>
<el-table-column prop="applyDate" label="申报时间"></el-table-column>
<el-table-column prop="taskName" label="当前节点"></el-table-column>
<el-table-column prop="curTaskName" label="当前节点"></el-table-column>
<el-table-column prop="instanceState" label="流程状态">
<template slot-scope="{row}">
<enum-tag :value="row.instanceState" name="ProcessInstanceStateEnum" label_key="message"
@@ -18,8 +18,8 @@ layout("/layouts/platform.html"){
</el-radio-group>
</el-form-item>
</el-descriptions-item>
<el-descriptions-item label="申人姓名">{{formData.userName}}</el-descriptions-item>
<el-descriptions-item label="申人工号">{{formData.loginName}}</el-descriptions-item>
<el-descriptions-item label="申人姓名">{{formData.userName}}</el-descriptions-item>
<el-descriptions-item label="申人工号">{{formData.loginName}}</el-descriptions-item>
<el-descriptions-item label="联系方式">
<el-form-item label="联系方式" prop="mobile"
:rules="[{required:true,message:'必填',trigger:['change','blur']}]">
@@ -95,8 +95,7 @@ layout("/layouts/platform.html"){
</el-date-picker>
</el-form-item>
</el-descriptions-item>
<el-descriptions-item
v-if="!['ACTIVITY_BUDGET_TYPE_THREE'].includes(formData.outlayManageSource)"></el-descriptions-item>
<el-descriptions-item></el-descriptions-item>
<el-descriptions-item label="支付内容" :span="2">
<el-form-item label="支付内容" prop="paymentContent"
:rules="[{required:true,message:'必填',trigger:['change','blur']}]">
@@ -42,7 +42,7 @@ layout("/layouts/platform.html"){
</template>
</el-table-column>
<el-table-column prop="money" label="金额"></el-table-column>
<el-table-column prop="applyTime" label="申时间"></el-table-column>
<el-table-column prop="applyTime" label="申时间"></el-table-column>
<el-table-column prop="taskName" label="当前节点"></el-table-column>
<el-table-column prop="instanceState" label="流程状态">
<template v-slot="{row}">
@@ -120,6 +120,18 @@ layout("/layouts/platform.html"){
})
},
doDelete(id) {
this.$confirm("您确定要撤回吗?", "提示", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning"
}).then(() => {
this.$axios.post("/platform/outlay/reimburse/applyList/doDelete", {id}).then((res) => {
if (res.code === 0) {
this.$message.success(res.msg)
this.pageData()
}
})
})
}
},
async created() {
@@ -58,7 +58,7 @@ layout("/layouts/platform.html"){
</el-table-column>
<el-table-column prop="money" label="金额"></el-table-column>
<el-table-column prop="applyTime" label="申报时间"></el-table-column>
<el-table-column prop="taskName" label="当前节点"></el-table-column>
<el-table-column prop="curTaskName" label="当前节点"></el-table-column>
<el-table-column prop="instanceState" label="流程状态">
<template v-slot="{row}">
<enum-tag :value="row.instanceState" name="ProcessInstanceStateEnum" label_key="message"
@@ -58,7 +58,7 @@ layout("/layouts/platform.html"){
</el-table-column>
<el-table-column prop="money" label="金额"></el-table-column>
<el-table-column prop="applyTime" label="申报时间"></el-table-column>
<el-table-column prop="taskName" label="当前节点"></el-table-column>
<el-table-column prop="curTaskName" label="当前节点"></el-table-column>
<el-table-column prop="instanceState" label="流程状态">
<template v-slot="{row}">
<enum-tag :value="row.instanceState" name="ProcessInstanceStateEnum" label_key="message"
@@ -72,7 +72,7 @@ layout("/layouts/platform.html"){
</el-table-column>
<el-table-column prop="money" label="金额"></el-table-column>
<el-table-column prop="applyTime" label="申报时间"></el-table-column>
<el-table-column prop="taskName" label="当前节点"></el-table-column>
<el-table-column prop="curTaskName" label="当前节点"></el-table-column>
<el-table-column prop="instanceState" label="流程状态">
<template v-slot="{row}">
<enum-tag :value="row.instanceState" name="ProcessInstanceStateEnum" label_key="message"
@@ -90,7 +90,7 @@ layout("/layouts/platform.html"){
</template>
</el-table-column>
<el-table-column prop="applyTime" label="申报时间"></el-table-column>
<el-table-column prop="taskName" label="当前节点"></el-table-column>
<el-table-column prop="curTaskName" label="当前节点"></el-table-column>
<el-table-column prop="instanceState" label="流程状态">
<template v-slot="{row}">
<enum-tag :value="row.instanceState" name="ProcessInstanceStateEnum" label_key="message"
@@ -90,7 +90,7 @@ layout("/layouts/platform.html"){
</template>
</el-table-column>
<el-table-column prop="applyTime" label="申报时间"></el-table-column>
<el-table-column prop="taskName" label="当前节点"></el-table-column>
<el-table-column prop="curTaskName" label="当前节点"></el-table-column>
<el-table-column prop="instanceState" label="流程状态">
<template v-slot="{row}">
<enum-tag :value="row.instanceState" name="ProcessInstanceStateEnum" label_key="message"
@@ -58,7 +58,7 @@ layout("/layouts/platform.html"){
</el-table-column>
<el-table-column prop="money" label="金额"></el-table-column>
<el-table-column prop="applyTime" label="申报时间"></el-table-column>
<el-table-column prop="taskName" label="当前节点"></el-table-column>
<el-table-column prop="curTaskName" label="当前节点"></el-table-column>
<el-table-column prop="instanceState" label="流程状态">
<template v-slot="{row}">
<enum-tag :value="row.instanceState" name="ProcessInstanceStateEnum" label_key="message"
@@ -40,11 +40,10 @@ const basicForm = {
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item prop="unionId" label="工会"
:rules="[{required:true,message:'请选择工会',trigger:['change','blur']}]">
<el-form-item prop="unionId" label="查找工会">
<el-select clearable filterable multiple style="width: 100%"
v-model="formData.unionId"
placeholder="请选择活动线路"
placeholder="请选择工会"
@change="onUnionChange">
<el-option :value="item.id"
:key="item.id"
@@ -210,7 +210,7 @@ const SIGN_UP_FORM = {
type: "warning"
}).then(() => {
this.getSIgnUpUserList().then(data => {
const union = this.activityData.unionQuotaAllocationList(v => v.unionId === this.unionId)
const union = this.activityData.unionQuotaAllocationList.find(v => v.unionId === this.unionId)
if (data >= union.allocationNum) {
this.$message.error("该活动已满")
return
@@ -79,7 +79,7 @@ layout("/layouts/platform.html"){
<el-table-column label="所属单位" prop="unitName"></el-table-column>
<el-table-column label="报名线路" prop="lineName"></el-table-column>
<el-table-column prop="signUpTime" label="报名时间"></el-table-column>
<el-table-column prop="taskName" label="当前节点"></el-table-column>
<el-table-column prop="curTaskName" label="当前节点"></el-table-column>
<el-table-column prop="instanceState" label="流程状态">
<template v-slot="{row}">
<enum-tag :value="row.instanceState" name="ProcessInstanceStateEnum" label_key="message"
@@ -0,0 +1,479 @@
<!--#
layout("/layouts/platform_h5.html"){
#-->
<style>
</style>
<div id="app">
<!-- 导航栏 -->
<van-nav-bar title="子女入学" left-text="返回" left-arrow
@click-left="historyBack" fixed></van-nav-bar>
<!-- 表单容器 -->
<div class="form-container">
<van-form ref="formRef">
<!-- 登记类型信息 -->
<van-cell-group title="登记类型">
<van-field
:rules="[{ required: true }]"
v-model="formData.registrationTypeName"
label="登记类型"
placeholder="请选择登记类型"
required
is-link
readonly
@click="showRegistrationTypePopup = true"
></van-field>
<van-popup v-model="showRegistrationTypePopup" position="bottom">
<van-picker
show-toolbar
:columns="registrationTypeOption.map(i => i.registrationTypeName)"
@confirm="onRegistrationTypeConfirm"
@cancel="showRegistrationTypePopup = false"
></van-picker>
</van-popup>
</van-cell-group>
<!-- 教职工信息 -->
<van-cell-group title="教职工信息">
<van-field label="监护人(教工)姓名" :rules="[{ required: true }]" v-model="formData.userName" readonly
required></van-field>
<van-field label="工号" :rules="[{ required: true }]" v-model="formData.loginName" readonly
required></van-field>
<van-field label="手机号码" name="mobile" :rules="[{ required: true }]" v-model="formData.mobile"
required
placeholder="请输入手机号码"></van-field>
<van-field label="所在单位" :rules="[{ required: true }]" v-model="formData.unitName" readonly
required></van-field>
<van-field
:rules="[{ required: true }]"
v-model="formData.childRelationshipName"
label="监护人与学生关系"
name="childRelationshipName"
placeholder="请选择监护人与学生关系"
required
is-link
readonly
@click="showChildRelationshipPopup = true"
></van-field>
<van-popup v-model="showChildRelationshipPopup" position="bottom">
<van-picker
show-toolbar
:columns="childRelationshipOption.map(i => i.name)"
@confirm="onChildRelationshipConfirm"
@cancel="showChildRelationshipPopup = false"
></van-picker>
</van-popup>
</van-cell-group>
<!-- 子女信息 -->
<van-cell-group title="子女信息">
<van-field label="子女姓名" name="childrenName" :rules="[{ required: true }]"
v-model="formData.childrenName" required
placeholder="请输入子女姓名"></van-field>
<van-field
:rules="[{ required: true }]"
v-model="formData.sex"
label="性别"
name="sex"
placeholder="请选择性别"
required
is-link
readonly
@click="showSexPopup = true"
></van-field>
<van-popup v-model="showSexPopup" position="bottom">
<van-picker
show-toolbar
:columns="sexOption"
@confirm="onSexConfirm"
@cancel="showSexPopup = false"
></van-picker>
</van-popup>
<van-field label="身份证号"
name="childrenIdCard"
:rules="[{ required: true }]"
v-model="formData.childrenIdCard"
placeholder="请输入身份证号"
required
></van-field>
<van-field label="出生年月"
name="childrenBirthday"
:rules="[{ required: true }]"
:value="formData.childrenBirthday"
readonly
is-link
placeholder="请填写出生年月"
required
@click="childrenBirthdayPopup = true"></van-field>
<van-popup v-model="childrenBirthdayPopup" position="bottom">
<van-datetime-picker
v-model="formData.childrenBirthdayDate"
type="date"
title="选择出生年月"
:min-date="childrenBirthdayMinDate"
:max-date="childrenBirthdayMaxDate"
@confirm="childrenBirthdayConfirm"
@cancel="childrenBirthdayPopup=false"
></van-datetime-picker>
</van-popup>
<van-field label="现就读学校"
:rules="[{ required: true }]"
v-model="formData.childrenCurrentSchool"
required
placeholder="请输入现就读学校"></van-field>
<van-field
:rules="[{ required: true }]"
v-model="formData.childrenPlanSchoolName"
label="拟报就读学校"
name="childrenPlanSchoolName"
placeholder="请选择拟报就读学校"
required
is-link
readonly
@click="showChildrenPlanSchoolPopup = true"
class="van-field"
></van-field>
<van-popup v-model="showChildrenPlanSchoolPopup" position="bottom">
<van-picker
show-toolbar
:columns="childrenPlanSchoolOption.map(i => i.name)"
@confirm="onChildrenPlanSchoolConfirm"
@cancel="showChildrenPlanSchoolPopup = false"
></van-picker>
</van-popup>
<van-field label="子女户口所在地"
:rules="[{ required: true }]"
v-model="formData.childrenHuKouAddress"
required
type="textarea"
name="childrenHuKouAddress"
rows="4"
autosize
class="more-text"
placeholder="请输入子女户口所在地"></van-field>
<van-field label="备注"
:rules="[{ required: true }]"
v-model="formData.note"
required
type="textarea"
name="note"
rows="4"
autosize
class="more-text"
placeholder="请填写户籍所在地派出所"></van-field>
</van-cell-group>
<!-- 户口簿照片 -->
<van-cell-group title="户口簿照片">
<van-field class="more-text" name="huKouFiles" :rules="[{ required: true,message:'请上传户口簿照片' }]"
label="" required>
<template #input>
<h5-file-upload
slot="input"
:value.sync="formData.huKouFiles"
:upload_number="10"
upload_mode="file"
upload_result_category="array"
upload_result_type="url"
complete_result
></h5-file-upload>
</template>
</van-field>
</van-cell-group>
<!-- 子女出生证照片 -->
<van-cell-group title="子女出生证照片">
<van-field class="more-text" name="birthCertificateFiles" label="">
<template #input>
<h5-file-upload
slot="input"
:value.sync="formData.birthCertificateFiles"
:upload_number="10"
upload_mode="image"
upload_result_category="array"
upload_result_type="url"
complete_result
></h5-file-upload>
</template>
</van-field>
</van-cell-group>
<!-- 按钮区域 -->
<div class="form-actions">
<van-button native-type="button" plain type="info" @click="onSave">保存</van-button>
<van-button type="primary" @click="onSubmit" v-if="!taskId">提交</van-button>
<van-button type="primary" @click="onFinishTask" v-else>提交</van-button>
</div>
</van-form>
</div>
</div>
<script>
const vue = new Vue({
el: "#app",
store,
dicts: ["ENROLLMENT_REGISTRATION_CHILD_RELATIONSHIP", "ENROLLMENT_REGISTRATION_CHILDREN_PLAN_SCHOOL"],
components: {},
data() {
return {
bizId: GetQueryString("bizId"),
taskId: GetQueryString("taskId"),
formData: {},
registrationTypeOption: [],
showRegistrationTypePopup: false,
childRelationshipOption: [],
showChildRelationshipPopup: false,
sexOption: ["男", "女"],
showSexPopup: false,
childrenBirthdayMinDate: new Date(1900, 0, 1),
childrenBirthdayMaxDate: new Date(),
childrenBirthdayPopup: false,
childrenPlanSchoolOption: [],
showChildrenPlanSchoolPopup: false,
}
},
methods: {
async getEnrollmentRegistrationPlan() {
const res = await this.$axios.post("/platform/enrollmentRegistration/apply/getEnrollmentRegistrationPlan")
if (res.code === 0) {
this.registrationTypeOption = res.data
}
},
init() {
setTimeout(() => {
this.childRelationshipOption = this.dict.type.ENROLLMENT_REGISTRATION_CHILD_RELATIONSHIP
this.childrenPlanSchoolOption = this.dict.type.ENROLLMENT_REGISTRATION_CHILDREN_PLAN_SCHOOL
}, 300)
if (this.bizId) {
this.findOne(this.bizId).then(async data => {
this.formData = data
//登记类型回显
const registrationType = this.registrationTypeOption.find(v => v.registrationType === data.registrationType)
if (registrationType) {
this.$set(this.formData, "registrationTypeName", registrationType.registrationTypeName)
}
//监护人与学生关系回显
const childRelationship = this.dict.type.ENROLLMENT_REGISTRATION_CHILD_RELATIONSHIP.find(v => v.code === data.childRelationship)
if (childRelationship) {
this.$set(this.formData, "childRelationshipName", childRelationship.name)
}
//出生年月回显
if (data.childrenBirthday) {
this.$set(this.formData, "childrenBirthdayDate", new Date(data.childrenBirthday))
}
//拟报就读学校
const childrenPlanSchool = this.dict.type.ENROLLMENT_REGISTRATION_CHILDREN_PLAN_SCHOOL.find(v => v.code === data.childrenPlanSchool)
if (childrenPlanSchool) {
this.$set(this.formData, "childrenPlanSchoolName", childrenPlanSchool.name)
}
})
} else {
const {id, username, loginname, mobile, union, unit} = this.$store.state.user
this.formData = {
userId: id,
userName: username,
loginName: loginname,
unitName: unit.name,
unitId: unit.id,
unionName: union.name,
unionId: union.id,
mobile: mobile,
}
}
},
onChildrenPlanSchoolConfirm(value, index) {
this.formData.childrenPlanSchool = this.childrenPlanSchoolOption[index].code;
this.formData.childrenPlanSchoolName = value;
this.showChildrenPlanSchoolPopup = false;
},
childrenBirthdayConfirm(value) {
this.formData.childrenBirthdayDate = value
this.formData.childrenBirthday = this.$moment(value).format("YYYY-MM-DD")
this.childrenBirthdayPopup = false
},
onSexConfirm(value) {
this.formData.sex = value;
this.showSexPopup = false;
},
onChildRelationshipConfirm(value, index) {
this.formData.childRelationship = this.childRelationshipOption[index].code;
this.formData.childRelationshipName = value;
this.showChildRelationshipPopup = false;
},
onRegistrationTypeConfirm(value, index) {
this.formData.registrationType = this.registrationTypeOption[index].registrationType;
this.formData.registrationTypeName = value;
this.showRegistrationTypePopup = false;
},
validateBirthday() {
if (!this.formData.registrationType) {
return "请选择登记类型"
}
if (!this.formData.childrenBirthday) {
return "请选择子女出生年月"
}
const childrenBirthday = new Date(this.formData.childrenBirthday);
if (isNaN(childrenBirthday.getTime())) {
return "出生日期格式无效";
}
const registrationType = this.registrationTypeOption.find(item => item.registrationType === this.formData.registrationType)
if (registrationType.greaterThanBirthday) {
const greaterThanBirthday = new Date(registrationType.greaterThanBirthday);
if (isNaN(greaterThanBirthday.getTime())) {
return "限制日期格式无效";
}
if (childrenBirthday < greaterThanBirthday) {
return "出生日期不能小于" + registrationType.greaterThanBirthday;
}
}
if (registrationType.lessThanBirthday) {
const lessThanBirthday = new Date(registrationType.lessThanBirthday);
if (isNaN(lessThanBirthday.getTime())) {
return "限制日期格式无效";
}
if (childrenBirthday > lessThanBirthday) {
return "出生日期不能大于" + registrationType.lessThanBirthday;
}
}
return null; // 表示通过
},
async getIsRepeatByIdCard() {
if (!this.formData.childrenIdCard) {
this.$toast.fail("请填写子女身份证号码")
return
}
const res = await this.$axios.post('/platform/enrollmentRegistration/apply/getIsRepeatByIdCard', {
idCard: this.formData.childrenIdCard,
id: this.formData.id
})
if (res.code === 0) {
if (res.data > 0) {
this.$toast.fail("该身份证在本年度已填报!")
return true
} else {
this.$toast.success("该身份证在本年度暂未填报!")
return false
}
}
},
async findOne(id) {
const resp = await $.get('/platform/enrollmentRegistration/apply/findOne', {id})
if (resp.code === 0) {
return resp.data
}
},
onSave() {
const msg = this.validateBirthday()
if (msg) {
this.$toast.fail(msg)
return
}
this.$dialog.confirm({
title: '温馨提示',
message: '您确定保存吗?',
}).then(() => {
this.$axios.post('/platform/enrollmentRegistration/apply/save', {
data: JSON.stringify(this.formData)
}).then(res => {
if (res.code === 0) {
this.$toast.success("提交成功")
pjaxReplace("/platform/h5/enrollmentRegistration/apply/mine")
}
})
}).catch(() => {
// on cancel
});
},
onSubmit() {
const msg = this.validateBirthday()
if (msg) {
this.$toast.fail(msg)
return
}
this.$refs.formRef.validate().then(() => {
this.$dialog.confirm({
title: '温馨提示',
message: '您确定要提交吗?',
}).then(() => {
this.$axios.post('/platform/enrollmentRegistration/apply/submit', {
data: JSON.stringify(this.formData),
taskId: GetQueryString("taskId")
}).then(res => {
if (res.code === 0) {
this.$toast.success("提交成功")
pjaxReplace("/platform/h5/enrollmentRegistration/apply/mine")
}
})
}).catch(() => {
// on cancel
});
}).catch();
},
onFinishTask() {
const msg = this.validateBirthday()
if (msg) {
this.$toast.fail(msg)
return
}
this.$refs.formRef.validate().then(() => {
this.$dialog.confirm({
title: '温馨提示',
message: '您确定要提交吗?',
}).then(() => {
this.$axios.post('/platform/enrollmentRegistration/apply/submitAgain', {
data: JSON.stringify(this.formData),
taskId: GetQueryString("taskId")
}).then(res => {
if (res.code === 0) {
this.$toast.success("提交成功")
pjaxReplace("/platform/h5/enrollmentRegistration/apply/mine")
}
})
}).catch(() => {
// on cancel
});
}).catch();
}
},
async created() {
await this.getEnrollmentRegistrationPlan()
this.init()
}
})
</script>
<!--#
}
#-->
@@ -0,0 +1,170 @@
const H5_ENROLLMENT_REGISTRATION_INFO = {
template: /*language=HTML*/ `
<van-action-sheet v-model="visible" title="查看详情">
<div>
<div class="process-title">教职工信息</div>
<van-cell-group>
<van-cell title="监护人(教工)姓名">
{{ viewData.userName }}
</van-cell>
<van-cell title="工号">
{{ viewData.loginName }}
</van-cell>
<van-cell title="手机号码">
{{ viewData.mobile }}
</van-cell>
<van-cell title="所在单位">
{{ viewData.unitName }}
</van-cell>
<van-cell title="监护人与学生关系">
<dict-tag :options="dict.type.ENROLLMENT_REGISTRATION_CHILD_RELATIONSHIP"
:value="viewData.childRelationship"></dict-tag>
</van-cell>
<van-cell title="登记类型">
<dict-tag :options="dict.type.ENROLLMENT_REGISTRATION_TYPE"
:value="viewData.registrationType"></dict-tag>
</van-cell>
</van-cell-group>
<div class="process-title">子女信息</div>
<van-cell-group>
<van-cell title="子女姓名">
{{viewData.childrenName}}
</van-cell>
<van-cell title="性别">
{{viewData.sex}}
</van-cell>
<van-cell title="身份证号">
{{viewData.childrenIdCard}}
</van-cell>
<van-cell title="出生日期">
{{viewData.childrenBirthday}}
</van-cell>
<van-cell title="现就读学校">
{{viewData.childrenCurrentSchool}}
</van-cell>
<van-cell title="拟报就读学校">
<dict-tag :options="dict.type.ENROLLMENT_REGISTRATION_CHILDREN_PLAN_SCHOOL"
:value="viewData.childrenPlanSchool"></dict-tag>
</van-cell>
<van-cell title="子女户口所在地">
{{viewData.childrenHuKouAddress}}
</van-cell>
<van-cell title="备注">
{{viewData.note}}
</van-cell>
<van-cell title="户口簿照片">
<template #label>
<template v-for="(item,index) in viewData.huKouFiles">
<van-image :src="item.url"
v-if="item.url"
class="signature-image"
@click="previewOptionImg(viewData.huKouFiles,index)"></van-image>
</template>
</template>
</van-cell>
<van-cell title="子女出生证照片">
<template #label>
<template v-for="(item,index) in viewData.birthCertificateFiles">
<van-image :src="item.url"
v-if="item.url"
class="signature-image"
@click="previewOptionImg(viewData.birthCertificateFiles,index)"></van-image>
</template>
</template>
</van-cell>
</van-cell-group>
<template v-for="(task,index) in doneTasks">
<div class="process-title">
{{ task.displayName }}
</div>
<van-cell-group v-if="task.ext.isFirstTaskNode">
<van-cell title="申请用户">
{{ task.ext.initiatorName}}({{task.ext.initiatorAccount}})
</van-cell>
<van-cell title="申请时间">
{{ task.finishTime}}
</van-cell>
<van-cell title="办理结果">
<dict-tag :options="dict.type.PROCESS_TASK_SUBMIT_TYPE"
:value="task.ext.submitType"></dict-tag>
</van-cell>
</van-cell-group>
<van-cell-group v-else>
<van-cell title="办理用户">
{{ task.taskFormData.userName}}({{task.taskFormData.loginName}})
</van-cell>
<van-cell title="办理时间">
{{ task.finishTime}}
</van-cell>
<van-cell title="办理结果">
<dict-tag :options="dict.type.PROCESS_TASK_SUBMIT_TYPE"
:value="task.ext.submitType"></dict-tag>
</van-cell>
<van-cell title="办理意见" v-if="!task.ext.isFirstTaskNode">
<template #label>
{{
task.taskFormData.opinion
}}
</template>
</van-cell>
<van-cell title="签字" v-if="!task.ext.isFirstTaskNode">
<van-image :src="task.ext.tf_userSign"
v-if="task.ext.tf_userSign"
class="signature-image"></van-image>
</van-cell>
</van-cell-group>
</template>
<slot></slot>
</div>
</van-action-sheet>
`,
dicts: ["ENROLLMENT_REGISTRATION_TYPE", "ENROLLMENT_REGISTRATION_CHILD_RELATIONSHIP", "ENROLLMENT_REGISTRATION_CHILDREN_PLAN_SCHOOL", "PROCESS_TASK_SUBMIT_TYPE"],
data() {
return {
visible: false,
viewData: {},
doneTasks: [],
row: null
}
},
methods: {
//预览图片
previewOptionImg(files, index) {
const urls = files.map(item => item.url)
vant.ImagePreview({images: urls, startPosition: index})
},
// 打开
onOpen(row) {
this.row = row
this.visible = true
this.getInfo()
this.getDoneTasks()
},
// 关闭
onClose() {
this.visible = false
},
// 获取申请信息
getInfo() {
this.$axios.post('/platform/enrollmentRegistration/apply/findOne', {id: this.row.id}).then((res) => {
if (res.code === 0) {
this.viewData = res.data
}
})
},
// 获取已办任务审批记录
getDoneTasks() {
this.$axios.post("/flow/common/doneTasks", {bizId: this.row.id}).then((res) => {
if (res.code === 0) {
this.doneTasks = res.data
}
})
},
}
}
@@ -4,14 +4,16 @@ layout("/layouts/platform_h5.html"){
<div id="app">
<!-- 导航栏 -->
<van-sticky>
<van-nav-bar title="我的申报" left-text="返回" left-arrow
@click-left="pjaxReplace('/platform/home')"></van-nav-bar>
<van-nav-bar title="我的申报" left-text="返回" left-arrow placeholder
@click-left="historyBack" fixed></van-nav-bar>
<van-sticky offset-top="46px">
<van-dropdown-menu :close-on-click-outside="false" :close-on-click-overlay="false">
<year-van-dropdown-item :num="5" @change="doSearch" v-model="pageForm.year"></year-van-dropdown-item>
</van-dropdown-menu>
</van-sticky>
<table-list api="/platform/enrollmentRegistration/applyList/pageData" :page_form.sync="pageForm" ref="tableListRef"
@ready="doSearch" title="taskName">
<template v-slot="{index,row}">
@@ -26,37 +28,44 @@ layout("/layouts/platform_h5.html"){
<table-column label="填报时间">{{row.applyTime}}</table-column>
</template>
<template #actions="{index,row}">
<van-button type="info" size="small" @click="onOpen(row)">查看</van-button>
<van-button @click="openEdit(row)" v-if="row.taskKey === 'startTask' || !row.instanceId"
size="small">编辑
</van-button>
<van-button
@click="openRevoke(row)"
v-if="row.canRevoke"
size="small"
type="danger"
>
撤回
</van-button>
<van-button v-if="row.taskKey === 'startTask' || !row.instanceId" @click="doDelete(row.id)"
size="small" type="danger">
删除
</van-button>
<div class="action-btn" @click="onView(row)">
<i class="fa fa-eye"></i>
<span>查看</span>
</div>
<div class="action-btn" @click="onEdit(row)">
<i class="fa fa-edit"></i>
<span>编辑</span>
</div>
<div class="action-btn delete" v-if="row.canRevoke" @click="onRevoke(row)">
<i class="fa fa-undo"></i>
<span>撤回</span>
</div>
<div class="action-btn delete" @click="onDelete(row)"
v-if="row.taskKey === 'startTask' || !row.instanceId">
<i class="fa fa-trash"></i>
<span>删除</span>
</div>
</template>
</table-list>
<h5-enrollment-registration-info ref="h5EnrollmentRegistrationInfoRef"></h5-enrollment-registration-info>
</div>
<script>
<!--#include('../info.js'){}#-->
const vue = new Vue({
el: "#app",
store,
dicts: ["ENROLLMENT_REGISTRATION_TYPE", "ENROLLMENT_REGISTRATION_CHILD_RELATIONSHIP", "ENROLLMENT_REGISTRATION_CHILDREN_PLAN_SCHOOL"],
components: {},
components: {
"h5-enrollment-registration-info": H5_ENROLLMENT_REGISTRATION_INFO
},
data() {
return {
yearList: [],
pageForm: {
pageNumber: 1,
pageSize: 10,
@@ -66,12 +75,13 @@ layout("/layouts/platform_h5.html"){
}
},
methods: {
onOpen() {
onView(row) {
this.$refs.h5EnrollmentRegistrationInfoRef.onOpen(row)
},
openEdit(row) {
onEdit(row) {
pjaxReplace('/platform/h5/enrollmentRegistration/apply/index?taskId=' + (row.startTaskId || '') + "&bizId=" + row.id)
},
doDelete(id) {
onDelete(id) {
this.$dialog.confirm({
title: '温馨提示',
message: '您确定要删除吗?',
@@ -88,7 +98,7 @@ layout("/layouts/platform_h5.html"){
// on cancel
});
},
openRevoke(row) {
onRevoke(row) {
this.$dialog.confirm({
title: '温馨提示',
message: '您确定要撤回吗?',
@@ -0,0 +1,186 @@
<!--#
layout("/layouts/platform_h5.html"){
#-->
<div id="app">
<van-nav-bar @click-left="historyBack" left-arrow left-text="返回" title="校工会审核" placeholder
fixed></van-nav-bar>
<van-sticky offset-top="46px">
<van-search
:reverse-color="false"
:show-action="false"
@search="doSearch"
input-align="left"
placeholder="请输入姓名搜索"
v-model="pageForm.searchKeyword"
></van-search>
<van-tabs v-model="pageForm.approvalText"
@change="(val)=>{this.pageForm.approval = val==='1';this.doSearch();}">
<van-tab title="已审核" name="1"></van-tab>
<van-tab title="未审核" name="0"></van-tab>
</van-tabs>
</van-sticky>
<table-list api="/platform/enrollmentRegistration/schoolAudit/pageData" :page_form.sync="pageForm"
ref="tableListRef"
title="curTaskName" @ready="doSearch">
<template v-slot="{index,row}">
<table-column label="子女姓名">{{row.childrenName}}</table-column>
<table-column label="教职工姓名">{{row.userName}}</table-column>
<table-column label="手机号码">{{row.mobile}}</table-column>
<table-column label="所属单位">{{row.unitName}}</table-column>
<table-column label="登记类型">
<dict-tag :options="dict.type.ENROLLMENT_REGISTRATION_TYPE"
:value="row.registrationType"></dict-tag>
</table-column>
<table-column label="填报时间">{{row.applyTime}}</table-column>
</template>
<template #actions="{index,row}">
<div class="action-btn" @click="onView(row)">
<i class="fa fa-eye"></i>
<span>查看</span>
</div>
<div class="action-btn" v-if="row.taskState === 10" @click="onAudit(row)">
<i class="fa fa-edit"></i>
<span>审核</span>
</div>
<div class="action-btn delete" v-if="row.canRevoke" @click="onRevoke(row)">
<i class="fa fa-undo"></i>
<span>撤回</span>
</div>
</template>
</table-list>
<h5-enrollment-registration-info ref="h5EnrollmentRegistrationInfoRef">
<div v-if="showApprovalForm">
<div class="process-title">
校工会审核
</div>
<div class="form-container">
<van-form ref="formRef">
<van-cell-group title="审批意见">
<van-field label=""
:rules="[{ required: true,message:'请填审批意见' }]"
v-model="formData.tf_opinion"
required
type="textarea"
name="tf_opinion"
rows="4"
autosize
class="more-text"
placeholder="请填审批意见"></van-field>
</van-cell-group>
<van-cell-group title="电子签名" class="form-section">
<van-field class="more-text" name="tf_userSign" label="">
<template #input>
<h5-signature v-model="formData.tf_userSign" slot="input"></h5-signature>
</template>
</van-field>
</van-cell-group>
<!-- 按钮区域 -->
<div class="form-actions">
<van-button @click="handleTaskAction(6)">退回到发起人</van-button>
<van-button type="danger" @click="handleTaskAction(2)">拒绝申请</van-button>
<van-button type="primary" @click="handleTaskAction(1)">同意申请</van-button>
</div>
</van-form>
</div>
</div>
</h5-enrollment-registration-info>
</div>
<script>
<!--#include('../info.js'){}#-->
const vue = new Vue({
el: "#app",
store,
dicts: ["ENROLLMENT_REGISTRATION_TYPE", "ENROLLMENT_REGISTRATION_CHILD_RELATIONSHIP", "ENROLLMENT_REGISTRATION_CHILDREN_PLAN_SCHOOL"],
components: {
"h5-enrollment-registration-info": H5_ENROLLMENT_REGISTRATION_INFO
},
data() {
return {
pageForm: {
pageNumber: 1,
pageSize: 10,
totalCount: 0,
year: new Date().getFullYear(),
approvalText: "0",
approval: false,
searchName: "info.userName",
},
formData: {},
infoShow: false,
showApprovalForm: false,
}
},
methods: {
handleTaskAction(val) {
this.$refs.formRef.validate().then(() => {
this.$dialog.confirm({
title: '温馨提示',
message: '您确定要提交吗?',
}).then(() => {
this.$axios.post('/flow/common/executeTask', {
data: JSON.stringify({
...this.formData,
submitType: val
})
}).then(res => {
if (res.code === 0) {
this.$toast.success("提交成功")
this.doSearch()
this.$refs.h5EnrollmentRegistrationInfoRef.onClose()
}
})
}).catch(() => {
// on cancel
});
}).catch();
},
onAudit(row) {
this.showApprovalForm = true
this.formData = {
tf_opinion: null,
tf_userSign: null,
processTaskId: row.taskId,
taskName: row.curTaskName
}
this.$refs.h5EnrollmentRegistrationInfoRef.onOpen(row)
},
onRevoke(row) {
this.$dialog.confirm({
title: '温馨提示',
message: '您确定要撤回吗?',
}).then(() => {
this.$axios.post("/flow/common/revokeTask", {taskId: row.taskId}).then(res => {
if (res.code === 0) {
this.$toast.success("提交成功")
this.doSearch()
this.infoShow = false
}
})
}).catch(() => {
// on cancel
});
},
onView(row) {
this.showApprovalForm = false
this.$refs.h5EnrollmentRegistrationInfoRef.onOpen(row)
},
doSearch() {
this.$nextTick(() => {
this.pageForm.pageNumber = 1
this.pageForm.totalCount = 0
this.$refs.tableListRef.doSearch()
})
},
}
})
</script>
<!--#
}
#-->
@@ -0,0 +1,188 @@
<!--#
layout("/layouts/platform_h5.html"){
#-->
<div id="app">
<van-nav-bar @click-left="historyBack" left-arrow left-text="返回" title="分工会审核" placeholder
fixed></van-nav-bar>
<van-sticky offset-top="46px">
<van-search
:reverse-color="false"
:show-action="false"
@search="doSearch"
input-align="left"
placeholder="请输入姓名搜索"
v-model="pageForm.searchKeyword"
></van-search>
<!--<van-dropdown-menu :close-on-click-outside="false" :close-on-click-overlay="false">
<year-van-dropdown-item :num="5" @change="doSearch" v-model="pageForm.year"></year-van-dropdown-item>
</van-dropdown-menu>-->
<van-tabs v-model="pageForm.approvalText"
@change="(val)=>{this.pageForm.approval = val==='1';this.doSearch();}">
<van-tab title="已审核" name="1"></van-tab>
<van-tab title="未审核" name="0"></van-tab>
</van-tabs>
</van-sticky>
<table-list api="/platform/enrollmentRegistration/unionAudit/pageData" :page_form.sync="pageForm" ref="tableListRef"
title="curTaskName" @ready="doSearch">
<template v-slot="{index,row}">
<table-column label="子女姓名">{{row.childrenName}}</table-column>
<table-column label="教职工姓名">{{row.userName}}</table-column>
<table-column label="手机号码">{{row.mobile}}</table-column>
<table-column label="所属单位">{{row.unitName}}</table-column>
<table-column label="登记类型">
<dict-tag :options="dict.type.ENROLLMENT_REGISTRATION_TYPE"
:value="row.registrationType"></dict-tag>
</table-column>
<table-column label="填报时间">{{row.applyTime}}</table-column>
</template>
<template #actions="{index,row}">
<div class="action-btn" @click="onView(row)">
<i class="fa fa-eye"></i>
<span>查看</span>
</div>
<div class="action-btn" v-if="row.taskState === 10" @click="onAudit(row)">
<i class="fa fa-edit"></i>
<span>审核</span>
</div>
<div class="action-btn delete" v-if="row.canRevoke" @click="onRevoke(row)">
<i class="fa fa-undo"></i>
<span>撤回</span>
</div>
</template>
</table-list>
<h5-enrollment-registration-info ref="h5EnrollmentRegistrationInfoRef">
<div v-if="showApprovalForm">
<div class="process-title">
分工会审核
</div>
<div class="form-container">
<van-form ref="formRef">
<van-cell-group title="审批意见">
<van-field label=""
:rules="[{ required: true,message:'请填审批意见' }]"
v-model="formData.tf_opinion"
required
type="textarea"
name="tf_opinion"
rows="4"
autosize
class="more-text"
placeholder="请填审批意见"></van-field>
</van-cell-group>
<van-cell-group title="电子签名" class="form-section">
<van-field class="more-text" name="tf_userSign" label="">
<template #input>
<h5-signature v-model="formData.tf_userSign" slot="input"></h5-signature>
</template>
</van-field>
</van-cell-group>
<!-- 按钮区域 -->
<div class="form-actions">
<van-button @click="handleTaskAction(6)">退回到发起人</van-button>
<van-button type="danger" @click="handleTaskAction(2)">拒绝申请</van-button>
<van-button type="primary" @click="handleTaskAction(1)">同意申请</van-button>
</div>
</van-form>
</div>
</div>
</h5-enrollment-registration-info>
</div>
<script>
<!--#include('../info.js'){}#-->
const vue = new Vue({
el: "#app",
store,
dicts: ["ENROLLMENT_REGISTRATION_TYPE", "ENROLLMENT_REGISTRATION_CHILD_RELATIONSHIP", "ENROLLMENT_REGISTRATION_CHILDREN_PLAN_SCHOOL"],
components: {
"h5-enrollment-registration-info": H5_ENROLLMENT_REGISTRATION_INFO
},
data() {
return {
pageForm: {
pageNumber: 1,
pageSize: 10,
totalCount: 0,
year: new Date().getFullYear(),
approvalText: "0",
approval: false,
searchName: "info.userName",
},
formData: {},
infoShow: false,
showApprovalForm: false,
}
},
methods: {
handleTaskAction(val) {
this.$refs.formRef.validate().then(() => {
this.$dialog.confirm({
title: '温馨提示',
message: '您确定要提交吗?',
}).then(() => {
this.$axios.post('/flow/common/executeTask', {
data: JSON.stringify({
...this.formData,
submitType: val
})
}).then(res => {
if (res.code === 0) {
this.$toast.success("提交成功")
this.doSearch()
this.$refs.h5EnrollmentRegistrationInfoRef.onClose()
}
})
}).catch(() => {
// on cancel
});
}).catch();
},
onAudit(row) {
this.showApprovalForm = true
this.formData = {
tf_opinion: null,
tf_userSign: null,
processTaskId: row.taskId,
taskName: row.curTaskName
}
this.$refs.h5EnrollmentRegistrationInfoRef.onOpen(row)
},
onRevoke(row) {
this.$dialog.confirm({
title: '温馨提示',
message: '您确定要撤回吗?',
}).then(() => {
this.$axios.post("/flow/common/revokeTask", {taskId: row.taskId}).then(res => {
if (res.code === 0) {
this.$toast.success("提交成功")
this.doSearch()
this.infoShow = false
}
})
}).catch(() => {
// on cancel
});
},
onView(row) {
this.showApprovalForm = false
this.$refs.h5EnrollmentRegistrationInfoRef.onOpen(row)
},
doSearch() {
this.$nextTick(() => {
this.pageForm.pageNumber = 1
this.pageForm.totalCount = 0
this.$refs.tableListRef.doSearch()
})
},
}
})
</script>
<!--#
}
#-->
@@ -0,0 +1,464 @@
<!--#
layout("/layouts/platform_h5.html"){
#-->
<style>
</style>
<div id="app">
<!-- 导航栏 -->
<van-nav-bar title="报销申请" left-text="返回" left-arrow
@click-left="historyBack" fixed></van-nav-bar>
<!-- 表单容器 -->
<div class="form-container">
<van-form ref="formRef">
<van-cell-group title="活动类型">
<van-field
:rules="[{ required: true }]"
v-model="formData.outlayManageSourceName"
label="活动类型"
placeholder="请选择活动类型"
required
is-link
readonly
@click="showOutlayManageSourcePopup = true"
></van-field>
<van-popup v-model="showOutlayManageSourcePopup" position="bottom">
<van-picker
show-toolbar
:columns="budgetTypeOption.map(i => i.name)"
@confirm="onOutlayManageSourceConfirm"
@cancel="showOutlayManageSourcePopup = false"
></van-picker>
</van-popup>
</van-cell-group>
<van-cell-group title="申请人信息">
<van-field label="申请人姓名" :rules="[{ required: true }]" v-model="formData.userName" readonly
required></van-field>
<van-field label="申请人工号" :rules="[{ required: true }]" v-model="formData.loginName" readonly
required></van-field>
<van-field label="手机号码" name="mobile" :rules="[{ required: true }]" v-model="formData.mobile"
required
placeholder="请输入手机号码"
maxlength="11"
type="tel"></van-field>
<van-field
:rules="[{ required: true }]"
v-model="formData.clubName"
label="所属协会"
placeholder="请选择所属协会"
required
is-link
readonly
@click="showClubNamePopup = true"
v-if="['ACTIVITY_BUDGET_TYPE_THREE'].includes(formData.outlayManageSource)"
></van-field>
<van-popup v-model="showClubNamePopup" position="bottom">
<van-picker
show-toolbar
:columns="clubOption.map(i => i.clubName)"
@confirm="onClubNameConfirm"
@cancel="showClubNamePopup = false"
></van-picker>
</van-popup>
<van-field label="经费余额" :rules="[{ required: true }]" v-model="budgetMoney" readonly
required></van-field>
<van-field label="活动事项" name="activityMatter"
:rules="[{ required: true }]"
v-model="formData.activityMatter"
required
maxlength="50"
placeholder="请输入活动事项"
v-if="['ACTIVITY_BUDGET_TYPE_THREE'].includes(formData.outlayManageSource)"></van-field>
<van-field
:rules="[{ required: true }]"
v-model="formData.budgetName"
label="活动事项"
placeholder="请选择活动事项"
required
is-link
readonly
@click="showBudgetNamePopup = true"
v-if="!['ACTIVITY_BUDGET_TYPE_THREE'].includes(formData.outlayManageSource)"
></van-field>
<van-popup v-model="showBudgetNamePopup" position="bottom">
<van-picker
show-toolbar
:columns="activityList.map(i => i.activityMatter)"
@confirm="onBudgetNameConfirm"
@cancel="showBudgetNamePopup = false"
></van-picker>
</van-popup>
<van-field label="活动人数" name="activityNumber"
:rules="[{ required: true }]"
v-model="formData.activityNumber"
required
maxlength="4"
placeholder="请输入活动人数"
type="digit"></van-field>
<van-field label="金额" name="money"
:rules="[{ required: true }]"
v-model="formData.money"
required
:placeholder="moneyPlaceholder"
type="number"></van-field>
<van-field label="活动时间"
name="activityTime"
:rules="[{ required: true }]"
:value="formData.activityTime"
readonly
is-link
placeholder="请填写活动时间"
required
@click="showActivityTimePopup = true"></van-field>
<van-popup v-model="showActivityTimePopup" position="bottom">
<van-datetime-picker
v-model="formData.activityTimeDate"
type="date"
title="选择活动时间"
:max-date="activityTimeMaxDate"
@confirm="onActivityTimeConfirm"
@cancel="showActivityTimePopup=false"
></van-datetime-picker>
</van-popup>
<van-field label="支付内容"
:rules="[{ required: true }]"
v-model="formData.paymentContent"
required
type="textarea"
name="paymentContent"
rows="4"
autosize
maxlength="500"
class="more-text"
placeholder="请填写支付内容"></van-field>
</van-cell-group>
<van-cell-group title="附件">
<van-field class="more-text" name="files"
:rules="[{ required: true,message:'请上传附件' }]"
label="" required>
<template #input>
<h5-file-upload
slot="input"
:value.sync="formData.files"
:upload_number="10"
upload_mode="file"
upload_result_category="array"
upload_result_type="url"
complete_result
></h5-file-upload>
</template>
</van-field>
</van-cell-group>
<van-cell-group title="电子签名">
<van-field class="more-text"
name="userSign"
label=""
required>
<template #input>
<h5-signature v-model="formData.userSign" slot="input"></h5-signature>
</template>
</van-field>
</van-cell-group>
<!-- 按钮区域 -->
<div class="form-actions">
<van-button native-type="button" plain type="info" @click="onSave">保存</van-button>
<van-button type="primary" @click="onSubmit" v-if="!taskId">提交</van-button>
<van-button type="primary" @click="onFinishTask" v-else>提交</van-button>
</div>
</van-form>
</div>
</div>
<script>
const vue = new Vue({
el: "#app",
store,
dicts: ["ACTIVITY_BUDGET_TYPE"],
data() {
return {
bizId: GetQueryString("bizId"),
taskId: GetQueryString("taskId"),
formData: {},
moneyPlaceholder: "请输入金额",
budgetMoney: 0,
budgetTypeOption: [],
showOutlayManageSourcePopup: false,
clubOption: [],
showClubNamePopup: false,
activityList: [],
showBudgetNamePopup: false,
showActivityTimePopup: false,
activityTimeMaxDate: new Date(),
}
},
methods: {
onSave() {
this.$dialog.confirm({
title: '温馨提示',
message: '您确定保存吗?',
}).then(() => {
this.$axios.post('/platform/outlay/reimburse/apply/save', {
data: JSON.stringify(this.formData)
}).then(res => {
if (res.code === 0) {
this.$toast.success("提交成功")
pjaxReplace("/platform/outlay/reimburse/applyList/h5")
}
})
}).catch(() => {
// on cancel
});
},
onSubmit() {
this.$refs.formRef.validate().then(() => {
this.$dialog.confirm({
title: '温馨提示',
message: '您确定要提交吗?',
}).then(() => {
this.$axios.post('/platform/outlay/reimburse/apply/submit', {
data: JSON.stringify(this.formData),
taskId: GetQueryString("taskId")
}).then(res => {
if (res.code === 0) {
this.$toast.success("提交成功")
pjaxReplace("/platform/outlay/reimburse/applyList/h5")
}
})
}).catch(() => {
});
}).catch();
},
onFinishTask() {
this.$refs.formRef.validate().then(() => {
this.$dialog.confirm({
title: '温馨提示',
message: '您确定要提交吗?',
}).then(() => {
this.$axios.post('/platform/outlay/reimburse/apply/submitAgain', {
data: JSON.stringify(this.formData),
taskId: GetQueryString("taskId")
}).then(res => {
if (res.code === 0) {
this.$toast.success("提交成功")
pjaxReplace("/platform/outlay/reimburse/applyList/h5")
}
})
}).catch(() => {
// on cancel
});
}).catch();
},
onActivityTimeConfirm(value, index) {
this.formData.activityTimeDate = value
this.formData.activityTime = this.$moment(value).format("YYYY-MM-DD")
this.showActivityTimePopup = false
},
async budgetIdChange(val) {
if (val) {
if (["ACTIVITY_BUDGET_TYPE_TWO", "ACTIVITY_BUDGET_TYPE_ONE"].includes(this.formData.outlayManageSource)) {
//如果是分工会和校工会
const data = this.activityList.find(a => a.id === val)
if (this.formData.outlayManageSource === "ACTIVITY_BUDGET_TYPE_TWO") {
//如果是分工会
const money = await this.getBxMoneyByBudgetId(val)
if (data.isSchoolBudget) {
//如果这一条分工会活动预算金额是属于校工会的
this.moneyPlaceholder = "预算金额" + data.totalBudgetMoney + "元,已报销金额:" + money
} else {
//如果这一条分工会活动活动,并且预算金额也是自己分工会的
if (data.isRepeatReimburse) {
//如果这一条活动预算可以重复报销
this.moneyPlaceholder = "预算金额:" + data.totalBudgetMoney + "元,已报销金额:" + money + ",不能超过20%"
} else {
//如果如果不能重复报销暂无判断
}
}
} else {
//如果是校工会
if (data.twoLevelBudgetList.length > 0) {
//如果大于0代表肯定有分工会使用校工会的预算,这里要减去分工会的预算
this.moneyPlaceholder = "预算金额:" + data.totalBudgetMoney + "元,已报销金额:" + data.twoLevelTotalBudgetMoney
} else {
if (data.isRepeatReimburse) {
const money = await this.getBxMoneyByBudgetId(val)
this.moneyPlaceholder = "预算金额:" + data.totalBudgetMoney + "元,已报销金额:" + money + ",不能超过20%"
} else {
//如果如果不能重复报销暂无判断
}
}
}
this.totalBudgetMoney = data.totalBudgetMoney
this.$set(this.formData, 'activityMatter', data.activityMatter)
} else {
this.moneyPlaceholder = "预算金额" + this.budgetMoney + "元"
this.totalBudgetMoney = this.budgetMoney
this.$set(this.formData, 'activityMatter', val)
}
} else {
this.moneyPlaceholder = "请输入金额"
this.totalBudgetMoney = 0
this.$set(this.formData, 'activityMatter', null)
}
},
async getBxMoneyByBudgetId(budgetId) {
const resp = await this.$axios.post("/platform/outlay/reimburse/apply/getBxMoneyByBudgetId", {
budgetId
})
if (resp.code === 0) {
return resp.data
} else {
return 0
}
},
async onBudgetNameConfirm(value, index) {
this.formData.budgetId = this.activityList[index].id;
this.formData.budgetName = value;
await this.budgetIdChange(this.formData.budgetId)
this.showBudgetNamePopup = false
},
async onClubNameConfirm(value, index) {
this.formData.clubId = this.clubOption[index].id;
this.formData.clubName = value;
await this.getBudgetMoneyOrActivity();
this.showClubNamePopup = false
},
async onOutlayManageSourceConfirm(value, index) {
this.formData.outlayManageSource = this.budgetTypeOption[index].code;
this.formData.outlayManageSourceName = value;
if (!this.formData.outlayManageSource) {
this.budgetMoney = 0
return
}
this.$set(this.formData, "budgetId", null)
this.$set(this.formData, "clubId", null)
this.$set(this.formData, "clubName", null)
await this.getBudgetMoneyOrActivity()
if (this.formData.outlayManageSource === "ACTIVITY_BUDGET_TYPE_TWO") {
this.$set(this.formData, "unionId", this.$store.state.user.union.id)
}
this.showOutlayManageSourcePopup = false;
},
async getBudgetMoneyOrActivity() {
const resp = await this.$axios.post("/platform/outlay/reimburse/apply/getBudgetMoneyOrActivity", {
outlayManageSource: this.formData.outlayManageSource,
clubId: this.formData.clubId,
unionId: this.formData.unionId,
id: this.formData.id
})
if (resp.code === 0) {
this.budgetMoney = resp.data.budgetMoney
this.activityList = resp.data.activityList
}
},
async findOne(id) {
const resp = await $.get('/platform/outlay/reimburse/apply/findOne', {id})
if (resp.code === 0) {
return resp.data
}
},
async init() {
this.clubOption = await this.$businessTool.listCLubByRole()
this.budgetTypeOption = await this.$businessTool.getDictOptions("ACTIVITY_BUDGET_TYPE")
const budgetTypeOption = []
if (this.$auth.hasRoleOr(["SYSADMIN", "SCHOOL_UNION_ADMIN"])) {
} else {
if (this.$auth.hasRoleOr(["SCHOOL_OUTLAY_ADMIN", "SCHOOL_UNION_ADMIN"])) {
this.budgetTypeOption.map(v => {
if (["ACTIVITY_BUDGET_TYPE_ONE"].includes(v.code)) {
budgetTypeOption.push(v)
}
})
}
if (this.$auth.hasRoleOr(["BRANCH_UNION_CHAIRMAN", "BRANCH_UNION_ADMIN"])) {
this.budgetTypeOption.map(v => {
if (["ACTIVITY_BUDGET_TYPE_TWO"].includes(v.code)) {
budgetTypeOption.push(v)
}
})
}
if (this.$auth.hasRoleOr(["CLUB_MANAGER", "CLUB_PRESIDENT"])) {
this.budgetTypeOption.map(v => {
if (["ACTIVITY_BUDGET_TYPE_THREE"].includes(v.code)) {
budgetTypeOption.push(v)
}
})
}
this.budgetTypeOption = budgetTypeOption
}
if (this.bizId) {
this.findOne(this.bizId).then(async data => {
this.formData = data
await this.getBudgetMoneyOrActivity()
if (data.budgetId) {
await this.budgetIdChange(data.budgetId)
}
//活动时间回显
if (data.activityTime) {
this.$set(this.formData, "activityTimeDate", new Date(data.activityTime))
}
//活动类型
const outlayManageSource = this.dict.type.ACTIVITY_BUDGET_TYPE.find(v => v.code === data.outlayManageSource)
if (outlayManageSource) {
this.$set(this.formData, "outlayManageSourceName", outlayManageSource.name)
}
if (data.budgetId) {
const activity= this.activityList.find(v => v.id === data.budgetId)
this.$set(this.formData, "budgetName", activity.activityMatter)
}
})
} else {
const {id, username, loginname, mobile, union, unit} = this.$store.state.user
this.formData = {
userId: id,
userName: username,
loginName: loginname,
unitName: unit.name,
unitId: unit.id,
unionName: union.name,
unionId: union.id,
mobile: mobile,
}
}
}
},
created() {
this.init()
}
})
</script>
<!--#
}
#-->
@@ -0,0 +1,136 @@
<!--#
layout("/layouts/platform_h5.html"){
#-->
<div id="app">
<!-- 导航栏 -->
<van-nav-bar title="我的申请" left-text="返回" left-arrow placeholder
@click-left="historyBack" fixed></van-nav-bar>
<van-sticky offset-top="46px">
<van-dropdown-menu :close-on-click-outside="false" :close-on-click-overlay="false">
<year-van-dropdown-item :num="5" @change="doSearch" v-model="pageForm.year"></year-van-dropdown-item>
</van-dropdown-menu>
</van-sticky>
<table-list api="/platform/outlay/reimburse/applyList/pageData" :page_form.sync="pageForm"
ref="tableListRef"
@ready="doSearch" title="taskName">
<template v-slot="{index,row}">
<table-column label="经办人工号">{{row.loginName}}</table-column>
<table-column label="姓名">{{row.userName}}</table-column>
<table-column label="活动类型">
<dict-tag :options="dict.type.ACTIVITY_BUDGET_TYPE"
:value="row.outlayManageSource"></dict-tag>
</table-column>
<table-column label="活动事项">{{row.activityMatter}}</table-column>
<table-column label="申报单位">
<span v-if="['ACTIVITY_BUDGET_TYPE_ONE'].includes(row.outlayManageSource)">校工会</span>
<span v-if="['ACTIVITY_BUDGET_TYPE_TWO'].includes(row.outlayManageSource)">{{row.unionName}}</span>
<span v-if="['ACTIVITY_BUDGET_TYPE_THREE','ACTIVITY_BUDGET_TYPE_FOUR'].includes(row.outlayManageSource)">{{row.clubName}}</span>
</table-column>
<table-column label="金额">{{row.money}}</table-column>
<table-column label="申请时间">{{row.applyTime}}</table-column>
</template>
<template #actions="{index,row}">
<div class="action-btn" @click="onView(row)">
<i class="fa fa-eye"></i>
<span>查看</span>
</div>
<div class="action-btn" @click="onEdit(row)">
<i class="fa fa-edit"></i>
<span>编辑</span>
</div>
<div class="action-btn delete" v-if="row.canRevoke" @click="onRevoke(row)">
<i class="fa fa-undo"></i>
<span>撤回</span>
</div>
<div class="action-btn delete" @click="onDelete(row.id)"
v-if="row.taskKey === 'startTask' || !row.instanceId">
<i class="fa fa-trash"></i>
<span>删除</span>
</div>
</template>
</table-list>
<h5-outlay-reimburse-info ref="h5OutlayReimburseInfo"></h5-outlay-reimburse-info>
</div>
<script>
<!--#include('../info.js'){}#-->
const vue = new Vue({
el: "#app",
store,
dicts: ["ACTIVITY_BUDGET_TYPE"],
components: {
"h5-outlay-reimburse-info": H5_OUTLAY_REIMBURSE_INFO
},
data() {
return {
pageForm: {
pageNumber: 1,
pageSize: 10,
totalCount: 0,
year: new Date().getFullYear(),
},
}
},
methods: {
onView(row) {
this.$refs.h5OutlayReimburseInfo.onOpen(row)
},
onEdit(row) {
pjaxReplace('/platform/outlay/reimburse/apply/h5?taskId=' + (row.startTaskId || '') + "&bizId=" + row.id)
},
onDelete(id) {
this.$dialog.confirm({
title: '温馨提示',
message: '您确定要删除吗?',
}).then(() => {
this.$axios.post("/platform/outlay/reimburse/applyList/doDelete", {id}).then((res) => {
if (res.code === 0) {
this.$toast.success(res.msg)
this.doSearch()
} else {
this.$toast.fail(res.msg)
}
})
}).catch(() => {
// on cancel
});
},
onRevoke(row) {
this.$dialog.confirm({
title: '温馨提示',
message: '您确定要撤回吗?',
}).then(() => {
this.$axios.post("/flow/common/revokeTask", {taskId: row.startTaskId}).then((res) => {
if (res.code === 0) {
this.$toast.success(res.msg)
this.doSearch()
} else {
this.$toast.fail(res.msg)
}
})
}).catch(() => {
// on cancel
});
},
doSearch() {
this.pageForm.pageNumber = 1
this.pageForm.totalCount = 0
this.$refs.tableListRef.doSearch()
},
},
created() {
}
})
</script>
<!--#
}
#-->
@@ -0,0 +1,185 @@
<!--#
layout("/layouts/platform_h5.html"){
#-->
<div id="app">
<van-nav-bar @click-left="historyBack" left-arrow left-text="返回" title="协会审核" placeholder
fixed></van-nav-bar>
<van-sticky offset-top="46px">
<van-search
:reverse-color="false"
:show-action="false"
@search="doSearch"
input-align="left"
placeholder="请输入姓名搜索"
v-model="pageForm.searchKeyword"
></van-search>
<van-tabs v-model="pageForm.approvalText"
@change="(val)=>{this.pageForm.approval = val==='1';this.doSearch();}">
<van-tab title="已审核" name="1"></van-tab>
<van-tab title="未审核" name="0"></van-tab>
</van-tabs>
</van-sticky>
<table-list api="/platform/outlay/reimburse/clubAudit/pageData" :page_form.sync="pageForm"
ref="tableListRef"
title="curTaskName" @ready="doSearch">
<template v-slot="{index,row}">
<table-column label="经办人工号">{{row.loginName}}</table-column>
<table-column label="姓名">{{row.userName}}</table-column>
<table-column label="活动类型">
<dict-tag :options="dict.type.ACTIVITY_BUDGET_TYPE"
:value="row.outlayManageSource"></dict-tag>
</table-column>
<table-column label="活动事项">{{row.activityMatter}}</table-column>
<table-column label="申报单位">
<span v-if="['ACTIVITY_BUDGET_TYPE_ONE'].includes(row.outlayManageSource)">校工会</span>
<span v-if="['ACTIVITY_BUDGET_TYPE_TWO'].includes(row.outlayManageSource)">{{row.unionName}}</span>
<span v-if="['ACTIVITY_BUDGET_TYPE_THREE','ACTIVITY_BUDGET_TYPE_FOUR'].includes(row.outlayManageSource)">{{row.clubName}}</span>
</table-column>
<table-column label="金额">{{row.money}}</table-column>
<table-column label="申请时间">{{row.applyTime}}</table-column>
</template>
<template #actions="{index,row}">
<div class="action-btn" @click="onView(row)">
<i class="fa fa-eye"></i>
<span>查看</span>
</div>
<div class="action-btn" v-if="row.taskState === 10" @click="onAudit(row)">
<i class="fa fa-edit"></i>
<span>审核</span>
</div>
<div class="action-btn delete" v-if="row.canRevoke" @click="onRevoke(row)">
<i class="fa fa-undo"></i>
<span>撤回</span>
</div>
</template>
</table-list>
<h5-outlay-reimburse-info ref="h5OutlayReimburseInfo">
<div v-if="showApprovalForm">
<div class="process-title">{{formData.taskName}}</div>
<div class="form-container">
<van-form ref="formRef">
<van-field label="审批意见"
:rules="[{ required: true,message:'请填审批意见' }]"
v-model="formData.tf_opinion"
required
type="textarea"
name="tf_opinion"
rows="4"
autosize
placeholder="请填审批意见"></van-field>
<van-field name="tf_userSign" label="签字">
<template #input>
<h5-signature v-model="formData.tf_userSign" slot="input"></h5-signature>
</template>
</van-field>
<!-- 按钮区域 -->
<div class="form-actions">
<van-button @click="handleTaskAction(6)">退回到发起人</van-button>
<van-button type="danger" @click="handleTaskAction(2)">拒绝申请</van-button>
<van-button type="primary" @click="handleTaskAction(1)">同意申请</van-button>
</div>
</van-form>
</div>
</div>
</h5-outlay-reimburse-info>
</div>
<script>
<!--#include('../info.js'){}#-->
const vue = new Vue({
el: "#app",
store,
dicts: ["ACTIVITY_BUDGET_TYPE"],
components: {
"h5-outlay-reimburse-info": H5_OUTLAY_REIMBURSE_INFO
},
data() {
return {
pageForm: {
pageNumber: 1,
pageSize: 10,
totalCount: 0,
year: new Date().getFullYear(),
approvalText: "0",
approval: false,
searchName: "info.userName",
},
formData: {},
infoShow: false,
showApprovalForm: false,
}
},
methods: {
handleTaskAction(val) {
this.$refs.formRef.validate().then(() => {
this.$dialog.confirm({
title: '温馨提示',
message: '您确定要提交吗?',
}).then(() => {
this.$axios.post('/flow/common/executeTask', {
data: JSON.stringify({
...this.formData,
submitType: val
})
}).then(res => {
if (res.code === 0) {
this.$toast.success("提交成功")
this.doSearch()
this.$refs.h5OutlayReimburseInfo.onClose()
}
})
}).catch(() => {
// on cancel
});
}).catch();
},
onAudit(row) {
this.showApprovalForm = true
this.formData = {
tf_opinion: null,
tf_userSign: null,
processTaskId: row.taskId,
taskName: row.curTaskName
}
this.$refs.h5OutlayReimburseInfo.onOpen(row)
},
onRevoke(row) {
this.$dialog.confirm({
title: '温馨提示',
message: '您确定要撤回吗?',
}).then(() => {
this.$axios.post("/flow/common/revokeTask", {taskId: row.taskId}).then(res => {
if (res.code === 0) {
this.$toast.success("提交成功")
this.doSearch()
this.infoShow = false
}
})
}).catch(() => {
// on cancel
});
},
onView(row) {
this.showApprovalForm = false
this.$refs.h5OutlayReimburseInfo.onOpen(row)
},
doSearch() {
this.$nextTick(() => {
this.pageForm.pageNumber = 1
this.pageForm.totalCount = 0
this.$refs.tableListRef.doSearch()
})
},
}
})
</script>
<!--#
}
#-->
@@ -0,0 +1,185 @@
<!--#
layout("/layouts/platform_h5.html"){
#-->
<div id="app">
<van-nav-bar @click-left="historyBack" left-arrow left-text="返回" title="协会分管主席审核" placeholder
fixed></van-nav-bar>
<van-sticky offset-top="46px">
<van-search
:reverse-color="false"
:show-action="false"
@search="doSearch"
input-align="left"
placeholder="请输入姓名搜索"
v-model="pageForm.searchKeyword"
></van-search>
<van-tabs v-model="pageForm.approvalText"
@change="(val)=>{this.pageForm.approval = val==='1';this.doSearch();}">
<van-tab title="已审核" name="1"></van-tab>
<van-tab title="未审核" name="0"></van-tab>
</van-tabs>
</van-sticky>
<table-list api="/platform/outlay/reimburse/clubZxAudit/pageData" :page_form.sync="pageForm"
ref="tableListRef"
title="curTaskName" @ready="doSearch">
<template v-slot="{index,row}">
<table-column label="经办人工号">{{row.loginName}}</table-column>
<table-column label="姓名">{{row.userName}}</table-column>
<table-column label="活动类型">
<dict-tag :options="dict.type.ACTIVITY_BUDGET_TYPE"
:value="row.outlayManageSource"></dict-tag>
</table-column>
<table-column label="活动事项">{{row.activityMatter}}</table-column>
<table-column label="申报单位">
<span v-if="['ACTIVITY_BUDGET_TYPE_ONE'].includes(row.outlayManageSource)">校工会</span>
<span v-if="['ACTIVITY_BUDGET_TYPE_TWO'].includes(row.outlayManageSource)">{{row.unionName}}</span>
<span v-if="['ACTIVITY_BUDGET_TYPE_THREE','ACTIVITY_BUDGET_TYPE_FOUR'].includes(row.outlayManageSource)">{{row.clubName}}</span>
</table-column>
<table-column label="金额">{{row.money}}</table-column>
<table-column label="申请时间">{{row.applyTime}}</table-column>
</template>
<template #actions="{index,row}">
<div class="action-btn" @click="onView(row)">
<i class="fa fa-eye"></i>
<span>查看</span>
</div>
<div class="action-btn" v-if="row.taskState === 10" @click="onAudit(row)">
<i class="fa fa-edit"></i>
<span>审核</span>
</div>
<div class="action-btn delete" v-if="row.canRevoke" @click="onRevoke(row)">
<i class="fa fa-undo"></i>
<span>撤回</span>
</div>
</template>
</table-list>
<h5-outlay-reimburse-info ref="h5OutlayReimburseInfo">
<div v-if="showApprovalForm">
<div class="process-title">{{formData.taskName}}</div>
<div class="form-container">
<van-form ref="formRef">
<van-field label="审批意见"
:rules="[{ required: true,message:'请填审批意见' }]"
v-model="formData.tf_opinion"
required
type="textarea"
name="tf_opinion"
rows="4"
autosize
placeholder="请填审批意见"></van-field>
<van-field name="tf_userSign" label="签字">
<template #input>
<h5-signature v-model="formData.tf_userSign" slot="input"></h5-signature>
</template>
</van-field>
<!-- 按钮区域 -->
<div class="form-actions">
<van-button @click="handleTaskAction(6)">退回到发起人</van-button>
<van-button type="danger" @click="handleTaskAction(2)">拒绝申请</van-button>
<van-button type="primary" @click="handleTaskAction(1)">同意申请</van-button>
</div>
</van-form>
</div>
</div>
</h5-outlay-reimburse-info>
</div>
<script>
<!--#include('../info.js'){}#-->
const vue = new Vue({
el: "#app",
store,
dicts: ["ACTIVITY_BUDGET_TYPE"],
components: {
"h5-outlay-reimburse-info": H5_OUTLAY_REIMBURSE_INFO
},
data() {
return {
pageForm: {
pageNumber: 1,
pageSize: 10,
totalCount: 0,
year: new Date().getFullYear(),
approvalText: "0",
approval: false,
searchName: "info.userName",
},
formData: {},
infoShow: false,
showApprovalForm: false,
}
},
methods: {
handleTaskAction(val) {
this.$refs.formRef.validate().then(() => {
this.$dialog.confirm({
title: '温馨提示',
message: '您确定要提交吗?',
}).then(() => {
this.$axios.post('/flow/common/executeTask', {
data: JSON.stringify({
...this.formData,
submitType: val
})
}).then(res => {
if (res.code === 0) {
this.$toast.success("提交成功")
this.doSearch()
this.$refs.h5OutlayReimburseInfo.onClose()
}
})
}).catch(() => {
// on cancel
});
}).catch();
},
onAudit(row) {
this.showApprovalForm = true
this.formData = {
tf_opinion: null,
tf_userSign: null,
processTaskId: row.taskId,
taskName: row.curTaskName
}
this.$refs.h5OutlayReimburseInfo.onOpen(row)
},
onRevoke(row) {
this.$dialog.confirm({
title: '温馨提示',
message: '您确定要撤回吗?',
}).then(() => {
this.$axios.post("/flow/common/revokeTask", {taskId: row.taskId}).then(res => {
if (res.code === 0) {
this.$toast.success("提交成功")
this.doSearch()
this.infoShow = false
}
})
}).catch(() => {
// on cancel
});
},
onView(row) {
this.showApprovalForm = false
this.$refs.h5OutlayReimburseInfo.onOpen(row)
},
doSearch() {
this.$nextTick(() => {
this.pageForm.pageNumber = 1
this.pageForm.totalCount = 0
this.$refs.tableListRef.doSearch()
})
},
}
})
</script>
<!--#
}
#-->
@@ -0,0 +1,146 @@
const H5_OUTLAY_REIMBURSE_INFO = {
template: /*language=HTML*/ `
<van-action-sheet v-model="visible" title="查看详情">
<div>
<div class="process-title">申请信息</div>
<van-cell-group>
<van-cell title="申请人">
{{ viewData.userName }}
</van-cell>
<van-cell title="工号">
{{ viewData.loginName }}
</van-cell>
<van-cell title="联系方式">
{{ viewData.mobile }}
</van-cell>
<van-cell title="预算类型">
<dict-tag :options="dict.type.ACTIVITY_BUDGET_TYPE"
:value="viewData.outlayManageSource"></dict-tag>
</van-cell>
<van-cell title="预算类型">
{{viewData.activityMatter}}
</van-cell>
<van-cell title="申请金额">
{{viewData.money}}
</van-cell>
<van-cell title="活动时间">
{{viewData.activityTime}}
</van-cell>
<van-cell title="活动人数">
{{viewData.activityNumber}}
</van-cell>
<van-cell title="支付内容">
<div style="white-space: pre-line">{{viewData.paymentContent}}</div>
</van-cell>
<van-cell title="附件">
<template #label>
<template v-for="(item,index) in viewData.files">
<van-image :src="item.url"
v-if="item.url"
class="signature-image"
@click="previewOptionImg(viewData.files,index)"></van-image>
</template>
</template>
</van-cell>
<van-cell title="签字" >
<van-image :src="viewData.userSign"
class="signature-image"></van-image>
</van-cell>
</van-cell-group>
<template v-for="(task,index) in doneTasks">
<div class="process-title">
{{ task.displayName }}
</div>
<van-cell-group v-if="task.ext.isFirstTaskNode">
<van-cell title="申请用户">
{{ task.ext.initiatorName}}({{task.ext.initiatorAccount}})
</van-cell>
<van-cell title="申请时间">
{{ task.finishTime}}
</van-cell>
<van-cell title="办理结果">
<dict-tag :options="dict.type.PROCESS_TASK_SUBMIT_TYPE"
:value="task.ext.submitType"></dict-tag>
</van-cell>
</van-cell-group>
<van-cell-group v-else>
<van-cell title="办理用户">
{{ task.taskFormData.userName}}({{task.taskFormData.loginName}})
</van-cell>
<van-cell title="办理时间">
{{ task.finishTime}}
</van-cell>
<van-cell title="办理结果">
<dict-tag :options="dict.type.PROCESS_TASK_SUBMIT_TYPE"
:value="task.ext.submitType"></dict-tag>
</van-cell>
<van-cell title="办理意见" v-if="!task.ext.isFirstTaskNode">
<template #label>
{{
task.taskFormData.opinion
}}
</template>
</van-cell>
<van-cell title="签字" v-if="!task.ext.isFirstTaskNode">
<van-image :src="task.ext.tf_userSign"
v-if="task.ext.tf_userSign"
class="signature-image"></van-image>
</van-cell>
</van-cell-group>
</template>
<slot></slot>
</div>
</van-action-sheet>
`,
dicts: ["PROCESS_TASK_SUBMIT_TYPE","ACTIVITY_BUDGET_TYPE","ACTIVITY_BUDGET_DETAILS_TYPE"],
data() {
return {
visible: false,
viewData: {},
doneTasks: [],
row: null
}
},
methods: {
//预览图片
previewOptionImg(files, index) {
const urls = files.map(item => item.url)
vant.ImagePreview({images: urls, startPosition: index})
},
// 打开
onOpen(row) {
this.row = row
this.visible = true
this.getInfo()
this.getDoneTasks()
},
// 关闭
onClose() {
this.visible = false
},
// 获取申请信息
getInfo() {
this.$axios.post('/platform/outlay/reimburse/apply/findOne', {id: this.row.id}).then((res) => {
if (res.code === 0) {
this.viewData = res.data
}
})
},
// 获取已办任务审批记录
getDoneTasks() {
this.$axios.post("/flow/common/doneTasks", {bizId: this.row.id}).then((res) => {
if (res.code === 0) {
this.doneTasks = res.data
}
})
},
}
}
@@ -0,0 +1,185 @@
<!--#
layout("/layouts/platform_h5.html"){
#-->
<div id="app">
<van-nav-bar @click-left="historyBack" left-arrow left-text="返回" title="校工会出纳审核" placeholder
fixed></van-nav-bar>
<van-sticky offset-top="46px">
<van-search
:reverse-color="false"
:show-action="false"
@search="doSearch"
input-align="left"
placeholder="请输入姓名搜索"
v-model="pageForm.searchKeyword"
></van-search>
<van-tabs v-model="pageForm.approvalText"
@change="(val)=>{this.pageForm.approval = val==='1';this.doSearch();}">
<van-tab title="已审核" name="1"></van-tab>
<van-tab title="未审核" name="0"></van-tab>
</van-tabs>
</van-sticky>
<table-list api="/platform/outlay/reimburse/schoolCnAudit/pageData" :page_form.sync="pageForm"
ref="tableListRef"
title="curTaskName" @ready="doSearch">
<template v-slot="{index,row}">
<table-column label="经办人工号">{{row.loginName}}</table-column>
<table-column label="姓名">{{row.userName}}</table-column>
<table-column label="活动类型">
<dict-tag :options="dict.type.ACTIVITY_BUDGET_TYPE"
:value="row.outlayManageSource"></dict-tag>
</table-column>
<table-column label="活动事项">{{row.activityMatter}}</table-column>
<table-column label="申报单位">
<span v-if="['ACTIVITY_BUDGET_TYPE_ONE'].includes(row.outlayManageSource)">校工会</span>
<span v-if="['ACTIVITY_BUDGET_TYPE_TWO'].includes(row.outlayManageSource)">{{row.unionName}}</span>
<span v-if="['ACTIVITY_BUDGET_TYPE_THREE','ACTIVITY_BUDGET_TYPE_FOUR'].includes(row.outlayManageSource)">{{row.clubName}}</span>
</table-column>
<table-column label="金额">{{row.money}}</table-column>
<table-column label="申请时间">{{row.applyTime}}</table-column>
</template>
<template #actions="{index,row}">
<div class="action-btn" @click="onView(row)">
<i class="fa fa-eye"></i>
<span>查看</span>
</div>
<div class="action-btn" v-if="row.taskState === 10" @click="onAudit(row)">
<i class="fa fa-edit"></i>
<span>审核</span>
</div>
<div class="action-btn delete" v-if="row.canRevoke" @click="onRevoke(row)">
<i class="fa fa-undo"></i>
<span>撤回</span>
</div>
</template>
</table-list>
<h5-outlay-reimburse-info ref="h5OutlayReimburseInfo">
<div v-if="showApprovalForm">
<div class="process-title">{{formData.taskName}}</div>
<div class="form-container">
<van-form ref="formRef">
<van-field label="审批意见"
:rules="[{ required: true,message:'请填审批意见' }]"
v-model="formData.tf_opinion"
required
type="textarea"
name="tf_opinion"
rows="4"
autosize
placeholder="请填审批意见"></van-field>
<van-field name="tf_userSign" label="签字">
<template #input>
<h5-signature v-model="formData.tf_userSign" slot="input"></h5-signature>
</template>
</van-field>
<!-- 按钮区域 -->
<div class="form-actions">
<van-button @click="handleTaskAction(6)">退回到发起人</van-button>
<van-button type="danger" @click="handleTaskAction(2)">拒绝申请</van-button>
<van-button type="primary" @click="handleTaskAction(1)">同意申请</van-button>
</div>
</van-form>
</div>
</div>
</h5-outlay-reimburse-info>
</div>
<script>
<!--#include('../info.js'){}#-->
const vue = new Vue({
el: "#app",
store,
dicts: ["ACTIVITY_BUDGET_TYPE"],
components: {
"h5-outlay-reimburse-info": H5_OUTLAY_REIMBURSE_INFO
},
data() {
return {
pageForm: {
pageNumber: 1,
pageSize: 10,
totalCount: 0,
year: new Date().getFullYear(),
approvalText: "0",
approval: false,
searchName: "info.userName",
},
formData: {},
infoShow: false,
showApprovalForm: false,
}
},
methods: {
handleTaskAction(val) {
this.$refs.formRef.validate().then(() => {
this.$dialog.confirm({
title: '温馨提示',
message: '您确定要提交吗?',
}).then(() => {
this.$axios.post('/flow/common/executeTask', {
data: JSON.stringify({
...this.formData,
submitType: val
})
}).then(res => {
if (res.code === 0) {
this.$toast.success("提交成功")
this.doSearch()
this.$refs.h5OutlayReimburseInfo.onClose()
}
})
}).catch(() => {
// on cancel
});
}).catch();
},
onAudit(row) {
this.showApprovalForm = true
this.formData = {
tf_opinion: null,
tf_userSign: null,
processTaskId: row.taskId,
taskName: row.curTaskName
}
this.$refs.h5OutlayReimburseInfo.onOpen(row)
},
onRevoke(row) {
this.$dialog.confirm({
title: '温馨提示',
message: '您确定要撤回吗?',
}).then(() => {
this.$axios.post("/flow/common/revokeTask", {taskId: row.taskId}).then(res => {
if (res.code === 0) {
this.$toast.success("提交成功")
this.doSearch()
this.infoShow = false
}
})
}).catch(() => {
// on cancel
});
},
onView(row) {
this.showApprovalForm = false
this.$refs.h5OutlayReimburseInfo.onOpen(row)
},
doSearch() {
this.$nextTick(() => {
this.pageForm.pageNumber = 1
this.pageForm.totalCount = 0
this.$refs.tableListRef.doSearch()
})
},
}
})
</script>
<!--#
}
#-->
@@ -0,0 +1,207 @@
<!--#
layout("/layouts/platform_h5.html"){
#-->
<div id="app">
<van-nav-bar @click-left="historyBack" left-arrow left-text="返回" title="校工会会计审核" placeholder
fixed></van-nav-bar>
<van-sticky offset-top="46px">
<van-search
:reverse-color="false"
:show-action="false"
@search="doSearch"
input-align="left"
placeholder="请输入姓名搜索"
v-model="pageForm.searchKeyword"
></van-search>
<van-tabs v-model="pageForm.approvalText"
@change="(val)=>{this.pageForm.approval = val==='1';this.doSearch();}">
<van-tab title="已审核" name="1"></van-tab>
<van-tab title="未审核" name="0"></van-tab>
</van-tabs>
</van-sticky>
<table-list api="/platform/outlay/reimburse/schoolKjAudit/pageData"
:page_form.sync="pageForm"
ref="tableListRef"
title="curTaskName" @ready="doSearch">
<template v-slot="{index,row}">
<table-column label="经办人工号">{{row.loginName}}</table-column>
<table-column label="姓名">{{row.userName}}</table-column>
<table-column label="活动类型">
<dict-tag :options="dict.type.ACTIVITY_BUDGET_TYPE"
:value="row.outlayManageSource"></dict-tag>
</table-column>
<table-column label="活动事项">{{row.activityMatter}}</table-column>
<table-column label="申报单位">
<span v-if="['ACTIVITY_BUDGET_TYPE_ONE'].includes(row.outlayManageSource)">校工会</span>
<span v-if="['ACTIVITY_BUDGET_TYPE_TWO'].includes(row.outlayManageSource)">{{row.unionName}}</span>
<span v-if="['ACTIVITY_BUDGET_TYPE_THREE','ACTIVITY_BUDGET_TYPE_FOUR'].includes(row.outlayManageSource)">{{row.clubName}}</span>
</table-column>
<table-column label="金额">{{row.money}}</table-column>
<table-column label="申请时间">{{row.applyTime}}</table-column>
</template>
<template #actions="{index,row}">
<div class="action-btn" @click="onView(row)">
<i class="fa fa-eye"></i>
<span>查看</span>
</div>
<div class="action-btn" v-if="row.taskState === 10" @click="onAudit(row)">
<i class="fa fa-edit"></i>
<span>审核</span>
</div>
<div class="action-btn delete" v-if="row.canRevoke" @click="onRevoke(row)">
<i class="fa fa-undo"></i>
<span>撤回</span>
</div>
</template>
</table-list>
<h5-outlay-reimburse-info ref="h5OutlayReimburseInfo">
<div v-if="showApprovalForm">
<div class="process-title">{{formData.taskName}}</div>
<div class="form-container">
<van-form ref="formRef">
<van-field label="审批意见"
:rules="[{ required: true,message:'请填审批意见' }]"
v-model="formData.tf_opinion"
required
type="textarea"
name="tf_opinion"
rows="4"
autosize
placeholder="请填审批意见"></van-field>
<van-field name="tf_userSign" label="签字">
<template #input>
<h5-signature v-model="formData.tf_userSign" slot="input"></h5-signature>
</template>
</van-field>
<van-popup v-model="showDetailsTypePopup" position="bottom">
<van-picker
show-toolbar
:columns="detailsTypeOption.map(i => i.name)"
@confirm="onDetailsTypeConfirm"
@cancel="showDetailsTypePopup = false"
></van-picker>
</van-popup>
<!-- 按钮区域 -->
<div class="form-actions">
<van-button @click="handleTaskAction(6)">退回到发起人</van-button>
<van-button type="danger" @click="handleTaskAction(2)">拒绝申请</van-button>
<van-button type="primary" @click="openHandleTaskAction">同意申请</van-button>
</div>
</van-form>
</div>
</div>
</h5-outlay-reimburse-info>
</div>
<script>
<!--#include('../info.js'){}#-->
const vue = new Vue({
el: "#app",
store,
dicts: ["ACTIVITY_BUDGET_TYPE"],
components: {
"h5-outlay-reimburse-info": H5_OUTLAY_REIMBURSE_INFO
},
data() {
return {
pageForm: {
pageNumber: 1,
pageSize: 10,
totalCount: 0,
year: new Date().getFullYear(),
approvalText: "0",
approval: false,
searchName: "info.userName",
},
formData: {},
detailsTypeOption: [],
showApprovalForm: false,
showDetailsTypePopup: false,
}
},
methods: {
async openHandleTaskAction() {
await this.$refs.formRef.validate();
this.detailsTypeOption = await this.$businessTool.getDictOptions("ACTIVITY_BUDGET_DETAILS_TYPE")
this.showDetailsTypePopup = true
},
onDetailsTypeConfirm(value, index) {
this.formData.detailsType = this.detailsTypeOption[index].value
this.handleTaskAction(1)
},
handleTaskAction(val) {
this.$refs.formRef.validate().then(() => {
this.$dialog.confirm({
title: '温馨提示',
message: '您确定要提交吗?',
}).then(() => {
this.$axios.post('/flow/common/executeTask', {
data: JSON.stringify({
...this.formData,
submitType: val
})
}).then(res => {
if (res.code === 0) {
this.$toast.success("提交成功")
this.doSearch()
this.$refs.h5OutlayReimburseInfo.onClose()
this.showDetailsTypePopup = false
}
})
}).catch(() => {
// on cancel
});
}).catch();
},
onAudit(row) {
this.showApprovalForm = true
this.formData = {
tf_opinion: null,
tf_userSign: null,
processTaskId: row.taskId,
taskName: row.curTaskName
}
this.$refs.h5OutlayReimburseInfo.onOpen(row)
},
onRevoke(row) {
this.$dialog.confirm({
title: '温馨提示',
message: '您确定要撤回吗?',
}).then(() => {
this.$axios.post("/flow/common/revokeTask", {taskId: row.taskId}).then(res => {
if (res.code === 0) {
this.$toast.success("提交成功")
this.doSearch()
this.infoShow = false
}
})
}).catch(() => {
// on cancel
});
},
onView(row) {
this.showApprovalForm = false
this.$refs.h5OutlayReimburseInfo.onOpen(row)
},
doSearch() {
this.$nextTick(() => {
this.pageForm.pageNumber = 1
this.pageForm.totalCount = 0
this.$refs.tableListRef.doSearch()
})
},
}
})
</script>
<!--#
}
#-->
@@ -0,0 +1,185 @@
<!--#
layout("/layouts/platform_h5.html"){
#-->
<div id="app">
<van-nav-bar @click-left="historyBack" left-arrow left-text="返回" title="校工会主席终审" placeholder
fixed></van-nav-bar>
<van-sticky offset-top="46px">
<van-search
:reverse-color="false"
:show-action="false"
@search="doSearch"
input-align="left"
placeholder="请输入姓名搜索"
v-model="pageForm.searchKeyword"
></van-search>
<van-tabs v-model="pageForm.approvalText"
@change="(val)=>{this.pageForm.approval = val==='1';this.doSearch();}">
<van-tab title="已审核" name="1"></van-tab>
<van-tab title="未审核" name="0"></van-tab>
</van-tabs>
</van-sticky>
<table-list api="/platform/outlay/reimburse/schoolZxAudit/pageData" :page_form.sync="pageForm"
ref="tableListRef"
title="curTaskName" @ready="doSearch">
<template v-slot="{index,row}">
<table-column label="经办人工号">{{row.loginName}}</table-column>
<table-column label="姓名">{{row.userName}}</table-column>
<table-column label="活动类型">
<dict-tag :options="dict.type.ACTIVITY_BUDGET_TYPE"
:value="row.outlayManageSource"></dict-tag>
</table-column>
<table-column label="活动事项">{{row.activityMatter}}</table-column>
<table-column label="申报单位">
<span v-if="['ACTIVITY_BUDGET_TYPE_ONE'].includes(row.outlayManageSource)">校工会</span>
<span v-if="['ACTIVITY_BUDGET_TYPE_TWO'].includes(row.outlayManageSource)">{{row.unionName}}</span>
<span v-if="['ACTIVITY_BUDGET_TYPE_THREE','ACTIVITY_BUDGET_TYPE_FOUR'].includes(row.outlayManageSource)">{{row.clubName}}</span>
</table-column>
<table-column label="金额">{{row.money}}</table-column>
<table-column label="申请时间">{{row.applyTime}}</table-column>
</template>
<template #actions="{index,row}">
<div class="action-btn" @click="onView(row)">
<i class="fa fa-eye"></i>
<span>查看</span>
</div>
<div class="action-btn" v-if="row.taskState === 10" @click="onAudit(row)">
<i class="fa fa-edit"></i>
<span>审核</span>
</div>
<div class="action-btn delete" v-if="row.canRevoke" @click="onRevoke(row)">
<i class="fa fa-undo"></i>
<span>撤回</span>
</div>
</template>
</table-list>
<h5-outlay-reimburse-info ref="h5OutlayReimburseInfo">
<div v-if="showApprovalForm">
<div class="process-title">{{formData.taskName}}</div>
<div class="form-container">
<van-form ref="formRef">
<van-field label="审批意见"
:rules="[{ required: true,message:'请填审批意见' }]"
v-model="formData.tf_opinion"
required
type="textarea"
name="tf_opinion"
rows="4"
autosize
placeholder="请填审批意见"></van-field>
<van-field name="tf_userSign" label="签字">
<template #input>
<h5-signature v-model="formData.tf_userSign" slot="input"></h5-signature>
</template>
</van-field>
<!-- 按钮区域 -->
<div class="form-actions">
<van-button @click="handleTaskAction(6)">退回到发起人</van-button>
<van-button type="danger" @click="handleTaskAction(2)">拒绝申请</van-button>
<van-button type="primary" @click="handleTaskAction(1)">同意申请</van-button>
</div>
</van-form>
</div>
</div>
</h5-outlay-reimburse-info>
</div>
<script>
<!--#include('../info.js'){}#-->
const vue = new Vue({
el: "#app",
store,
dicts: ["ACTIVITY_BUDGET_TYPE"],
components: {
"h5-outlay-reimburse-info": H5_OUTLAY_REIMBURSE_INFO
},
data() {
return {
pageForm: {
pageNumber: 1,
pageSize: 10,
totalCount: 0,
year: new Date().getFullYear(),
approvalText: "0",
approval: false,
searchName: "info.userName",
},
formData: {},
infoShow: false,
showApprovalForm: false,
}
},
methods: {
handleTaskAction(val) {
this.$refs.formRef.validate().then(() => {
this.$dialog.confirm({
title: '温馨提示',
message: '您确定要提交吗?',
}).then(() => {
this.$axios.post('/flow/common/executeTask', {
data: JSON.stringify({
...this.formData,
submitType: val
})
}).then(res => {
if (res.code === 0) {
this.$toast.success("提交成功")
this.doSearch()
this.$refs.h5OutlayReimburseInfo.onClose()
}
})
}).catch(() => {
// on cancel
});
}).catch();
},
onAudit(row) {
this.showApprovalForm = true
this.formData = {
tf_opinion: null,
tf_userSign: null,
processTaskId: row.taskId,
taskName: row.curTaskName
}
this.$refs.h5OutlayReimburseInfo.onOpen(row)
},
onRevoke(row) {
this.$dialog.confirm({
title: '温馨提示',
message: '您确定要撤回吗?',
}).then(() => {
this.$axios.post("/flow/common/revokeTask", {taskId: row.taskId}).then(res => {
if (res.code === 0) {
this.$toast.success("提交成功")
this.doSearch()
this.infoShow = false
}
})
}).catch(() => {
// on cancel
});
},
onView(row) {
this.showApprovalForm = false
this.$refs.h5OutlayReimburseInfo.onOpen(row)
},
doSearch() {
this.$nextTick(() => {
this.pageForm.pageNumber = 1
this.pageForm.totalCount = 0
this.$refs.tableListRef.doSearch()
})
},
}
})
</script>
<!--#
}
#-->
@@ -0,0 +1,185 @@
<!--#
layout("/layouts/platform_h5.html"){
#-->
<div id="app">
<van-nav-bar @click-left="historyBack" left-arrow left-text="返回" title="分工会审核" placeholder
fixed></van-nav-bar>
<van-sticky offset-top="46px">
<van-search
:reverse-color="false"
:show-action="false"
@search="doSearch"
input-align="left"
placeholder="请输入姓名搜索"
v-model="pageForm.searchKeyword"
></van-search>
<van-tabs v-model="pageForm.approvalText"
@change="(val)=>{this.pageForm.approval = val==='1';this.doSearch();}">
<van-tab title="已审核" name="1"></van-tab>
<van-tab title="未审核" name="0"></van-tab>
</van-tabs>
</van-sticky>
<table-list api="/platform/outlay/reimburse/unionAudit/pageData" :page_form.sync="pageForm"
ref="tableListRef"
title="curTaskName" @ready="doSearch">
<template v-slot="{index,row}">
<table-column label="经办人工号">{{row.loginName}}</table-column>
<table-column label="姓名">{{row.userName}}</table-column>
<table-column label="活动类型">
<dict-tag :options="dict.type.ACTIVITY_BUDGET_TYPE"
:value="row.outlayManageSource"></dict-tag>
</table-column>
<table-column label="活动事项">{{row.activityMatter}}</table-column>
<table-column label="申报单位">
<span v-if="['ACTIVITY_BUDGET_TYPE_ONE'].includes(row.outlayManageSource)">校工会</span>
<span v-if="['ACTIVITY_BUDGET_TYPE_TWO'].includes(row.outlayManageSource)">{{row.unionName}}</span>
<span v-if="['ACTIVITY_BUDGET_TYPE_THREE','ACTIVITY_BUDGET_TYPE_FOUR'].includes(row.outlayManageSource)">{{row.clubName}}</span>
</table-column>
<table-column label="金额">{{row.money}}</table-column>
<table-column label="申请时间">{{row.applyTime}}</table-column>
</template>
<template #actions="{index,row}">
<div class="action-btn" @click="onView(row)">
<i class="fa fa-eye"></i>
<span>查看</span>
</div>
<div class="action-btn" v-if="row.taskState === 10" @click="onAudit(row)">
<i class="fa fa-edit"></i>
<span>审核</span>
</div>
<div class="action-btn delete" v-if="row.canRevoke" @click="onRevoke(row)">
<i class="fa fa-undo"></i>
<span>撤回</span>
</div>
</template>
</table-list>
<h5-outlay-reimburse-info ref="h5OutlayReimburseInfo">
<div v-if="showApprovalForm">
<div class="process-title">{{formData.taskName}}</div>
<div class="form-container">
<van-form ref="formRef">
<van-field label="审批意见"
:rules="[{ required: true,message:'请填审批意见' }]"
v-model="formData.tf_opinion"
required
type="textarea"
name="tf_opinion"
rows="4"
autosize
placeholder="请填审批意见"></van-field>
<van-field name="tf_userSign" label="签字">
<template #input>
<h5-signature v-model="formData.tf_userSign" slot="input"></h5-signature>
</template>
</van-field>
<!-- 按钮区域 -->
<div class="form-actions">
<van-button @click="handleTaskAction(6)">退回到发起人</van-button>
<van-button type="danger" @click="handleTaskAction(2)">拒绝申请</van-button>
<van-button type="primary" @click="handleTaskAction(1)">同意申请</van-button>
</div>
</van-form>
</div>
</div>
</h5-outlay-reimburse-info>
</div>
<script>
<!--#include('../info.js'){}#-->
const vue = new Vue({
el: "#app",
store,
dicts: ["ACTIVITY_BUDGET_TYPE"],
components: {
"h5-outlay-reimburse-info": H5_OUTLAY_REIMBURSE_INFO
},
data() {
return {
pageForm: {
pageNumber: 1,
pageSize: 10,
totalCount: 0,
year: new Date().getFullYear(),
approvalText: "0",
approval: false,
searchName: "info.userName",
},
formData: {},
infoShow: false,
showApprovalForm: false,
}
},
methods: {
handleTaskAction(val) {
this.$refs.formRef.validate().then(() => {
this.$dialog.confirm({
title: '温馨提示',
message: '您确定要提交吗?',
}).then(() => {
this.$axios.post('/flow/common/executeTask', {
data: JSON.stringify({
...this.formData,
submitType: val
})
}).then(res => {
if (res.code === 0) {
this.$toast.success("提交成功")
this.doSearch()
this.$refs.h5OutlayReimburseInfo.onClose()
}
})
}).catch(() => {
// on cancel
});
}).catch();
},
onAudit(row) {
this.showApprovalForm = true
this.formData = {
tf_opinion: null,
tf_userSign: null,
processTaskId: row.taskId,
taskName: row.curTaskName
}
this.$refs.h5OutlayReimburseInfo.onOpen(row)
},
onRevoke(row) {
this.$dialog.confirm({
title: '温馨提示',
message: '您确定要撤回吗?',
}).then(() => {
this.$axios.post("/flow/common/revokeTask", {taskId: row.taskId}).then(res => {
if (res.code === 0) {
this.$toast.success("提交成功")
this.doSearch()
this.infoShow = false
}
})
}).catch(() => {
// on cancel
});
},
onView(row) {
this.showApprovalForm = false
this.$refs.h5OutlayReimburseInfo.onOpen(row)
},
doSearch() {
this.$nextTick(() => {
this.pageForm.pageNumber = 1
this.pageForm.totalCount = 0
this.$refs.tableListRef.doSearch()
})
},
}
})
</script>
<!--#
}
#-->