Merge branch 'main' of https://dd3skj.picp.vip/zhaoxinyu/zhgh_njnu
This commit is contained in:
+1
@@ -134,6 +134,7 @@ public class ActivityCultureUserStatisticsController {
|
||||
public Result getActivityByYearOrType(Integer year,
|
||||
@Valid Integer activity_type) {
|
||||
Cnd cnd = Cnd.where("activity_type", "=", activity_type);
|
||||
cnd.and("projectTypeCode", "!=", 50004);
|
||||
if (!AuthUtil.hasRoleOr(RoleConstant.SYSADMIN.name(), RoleConstant.SCHOOL_UNION_ADMIN.name())) {
|
||||
cnd.and("signUpMethod", "in", List.of(1, 2, 3));
|
||||
if (activity_type == 40002) {
|
||||
|
||||
+1
-1
@@ -83,7 +83,7 @@ public class ActivitySportsInfoManageController {
|
||||
school.activityCode,
|
||||
school.foundDate,
|
||||
school.applyType,
|
||||
(SELECT COUNT(1) FROM activity_school_apply asa WHERE asa.activityId = school.id) applyNum
|
||||
(SELECT COUNT(1) FROM activity_school_apply asa WHERE asa.activityId = school.id and status=2) applyNum
|
||||
FROM
|
||||
activity_school school
|
||||
LEFT JOIN activity_basic_settings ba ON ba.`code` = school.activityLevel
|
||||
|
||||
+8
@@ -17,6 +17,7 @@ import com.budwk.app.zhgh.activity.sports.models.ActivitySchoolTeam;
|
||||
import com.budwk.app.zhgh.activity.sports.param.ActivitySportsApplyUserPageParam;
|
||||
import com.budwk.app.zhgh.activity.sports.service.ActivitySportsApplyUserService;
|
||||
import org.nutz.aop.interceptor.ioc.TransAop;
|
||||
import org.nutz.dao.Chain;
|
||||
import org.nutz.dao.Cnd;
|
||||
import org.nutz.dao.Dao;
|
||||
import org.nutz.dao.Sqls;
|
||||
@@ -384,6 +385,13 @@ public class ActivitySportsApplyUserServiceImpl extends BaseServiceImpl<Activity
|
||||
.and("activityUnionId", "=", basicUnion.getId())
|
||||
.and("eventId", "=", eventId));
|
||||
}
|
||||
if (pass) {
|
||||
dao().update(ActivitySchoolApply.class,
|
||||
Chain.make("status", 2),
|
||||
Cnd.where("activityId", "=", activityId)
|
||||
.and("activityUnionId", "=", basicUnion.getId()));
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
+2
-1
@@ -211,7 +211,8 @@ public class ActivitySportsServiceImpl extends BaseServiceImpl<ActivitySchool> i
|
||||
LEFT JOIN activity_event ev ON ev.id = app.eventId
|
||||
LEFT JOIN activity_school sc ON sc.id=app.activityId
|
||||
WHERE
|
||||
activityId = @id
|
||||
app.activityId = @id
|
||||
and app.status = 2
|
||||
$cnd
|
||||
ORDER BY
|
||||
ev.allName DESC,
|
||||
|
||||
@@ -1,115 +1,121 @@
|
||||
<template>
|
||||
<el-select v-model="selectValue" filterable remote :remote-method="selectUser" @change="onChange" v-bind="$attrs">
|
||||
<el-option
|
||||
v-for="item in options"
|
||||
v-if="!item.disabled"
|
||||
:key="item[option_value]"
|
||||
:label="option_label_func ? option_label_func(item) : item[option_label]"
|
||||
:value="item[option_value]"
|
||||
></el-option>
|
||||
</el-select>
|
||||
<el-select v-model="selectValue" :clearable="clearable" filterable remote :remote-method="selectUser"
|
||||
@change="onChange" v-bind="$attrs">
|
||||
<el-option
|
||||
v-for="item in options"
|
||||
v-if="!item.disabled"
|
||||
:key="item[option_value]"
|
||||
:label="option_label_func ? option_label_func(item) : item[option_label]"
|
||||
:value="item[option_value]"
|
||||
></el-option>
|
||||
</el-select>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
module.exports = {
|
||||
model: {
|
||||
prop: "value",
|
||||
event: "change"
|
||||
},
|
||||
props: {
|
||||
value: { type: [String, Array] },
|
||||
model: {
|
||||
prop: "value",
|
||||
event: "change"
|
||||
},
|
||||
props: {
|
||||
value: {type: [String, Array]},
|
||||
|
||||
api: {
|
||||
type: String,
|
||||
required: false,
|
||||
default: "/open/common/userOptions"
|
||||
},
|
||||
|
||||
api_params: {
|
||||
type: Object,
|
||||
required: false,
|
||||
default: () => {
|
||||
return {}
|
||||
}
|
||||
},
|
||||
|
||||
api_input_key_name: {
|
||||
type: String,
|
||||
required: false,
|
||||
default: "keyWord"
|
||||
},
|
||||
|
||||
option_list: {
|
||||
type: Array,
|
||||
default: () => {
|
||||
return []
|
||||
}
|
||||
},
|
||||
|
||||
option_value: {
|
||||
type: String,
|
||||
default: "id"
|
||||
},
|
||||
|
||||
option_label: {
|
||||
type: String,
|
||||
default: "username"
|
||||
},
|
||||
|
||||
option_label_func: {
|
||||
type: Function,
|
||||
required: false
|
||||
}
|
||||
api: {
|
||||
type: String,
|
||||
required: false,
|
||||
default: "/open/common/userOptions"
|
||||
},
|
||||
|
||||
data() {
|
||||
return {
|
||||
options: [],
|
||||
selectValue: null
|
||||
}
|
||||
api_params: {
|
||||
type: Object,
|
||||
required: false,
|
||||
default: () => {
|
||||
return {}
|
||||
}
|
||||
},
|
||||
|
||||
watch: {
|
||||
value: {
|
||||
handler: function (val) {
|
||||
if (this.$attrs.multiple) {
|
||||
this.selectValue = [...val]
|
||||
} else {
|
||||
this.selectValue = val ? val.toString() : ""
|
||||
}
|
||||
},
|
||||
immediate: true,
|
||||
deep: true
|
||||
},
|
||||
option_list: {
|
||||
handler: function (val) {
|
||||
if (val) {
|
||||
this.options = val
|
||||
}
|
||||
},
|
||||
immediate: true
|
||||
}
|
||||
clearable: {
|
||||
type: Boolean,
|
||||
default: true
|
||||
},
|
||||
|
||||
methods: {
|
||||
selectUser(query) {
|
||||
if (query !== "") {
|
||||
$.get(this.api, { [this.api_input_key_name]: query, ...this.api_params }).then((res) => {
|
||||
this.options = res.data
|
||||
})
|
||||
}
|
||||
},
|
||||
onChange(val) {
|
||||
this.$emit("change", val)
|
||||
},
|
||||
|
||||
clearOptions() {
|
||||
this.options = []
|
||||
}
|
||||
api_input_key_name: {
|
||||
type: String,
|
||||
required: false,
|
||||
default: "keyWord"
|
||||
},
|
||||
created() {
|
||||
this.clearOptions()
|
||||
|
||||
option_list: {
|
||||
type: Array,
|
||||
default: () => {
|
||||
return []
|
||||
}
|
||||
},
|
||||
|
||||
option_value: {
|
||||
type: String,
|
||||
default: "id"
|
||||
},
|
||||
|
||||
option_label: {
|
||||
type: String,
|
||||
default: "username"
|
||||
},
|
||||
|
||||
option_label_func: {
|
||||
type: Function,
|
||||
required: false
|
||||
}
|
||||
},
|
||||
|
||||
data() {
|
||||
return {
|
||||
options: [],
|
||||
selectValue: null
|
||||
}
|
||||
},
|
||||
|
||||
watch: {
|
||||
value: {
|
||||
handler: function (val) {
|
||||
if (this.$attrs.multiple) {
|
||||
this.selectValue = [...val]
|
||||
} else {
|
||||
this.selectValue = val ? val.toString() : ""
|
||||
}
|
||||
},
|
||||
immediate: true,
|
||||
deep: true
|
||||
},
|
||||
option_list: {
|
||||
handler: function (val) {
|
||||
if (val) {
|
||||
this.options = val
|
||||
}
|
||||
},
|
||||
immediate: true
|
||||
}
|
||||
},
|
||||
|
||||
methods: {
|
||||
selectUser(query) {
|
||||
if (query !== "") {
|
||||
$.get(this.api, {[this.api_input_key_name]: query, ...this.api_params}).then((res) => {
|
||||
this.options = res.data
|
||||
})
|
||||
}
|
||||
},
|
||||
onChange(val) {
|
||||
this.$emit("change", val)
|
||||
},
|
||||
|
||||
clearOptions() {
|
||||
this.options = []
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.clearOptions()
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
|
||||
+4
-2
@@ -4,7 +4,7 @@ layout("/layouts/platform.html"){
|
||||
|
||||
<div id="app" v-cloak>
|
||||
<guava ref="guava">
|
||||
<activity-culture-apply-activity :activity_type="activityType"></activity-culture-apply-activity>
|
||||
<activity-culture-apply-activity :activity_type="activityType" ref="activityApply"></activity-culture-apply-activity>
|
||||
</guava>
|
||||
</div>
|
||||
<script>
|
||||
@@ -22,7 +22,9 @@ layout("/layouts/platform.html"){
|
||||
"activity-culture-apply-activity": ACTIVITY_CULTURE_APPLY_ACTIVITY
|
||||
},
|
||||
methods: {},
|
||||
async created() {}
|
||||
async created() {
|
||||
setTimeout(()=>{this.$refs.activityApply.init()},500)
|
||||
}
|
||||
})
|
||||
</script>
|
||||
|
||||
|
||||
@@ -31,10 +31,10 @@ const ACTIVITY_CULTURE_APPLY_ACTIVITY = {
|
||||
style="width: 100%;"
|
||||
v-model="formData.projectTypeCode">
|
||||
<el-option
|
||||
:key="item.id"
|
||||
:label="item.name+' ('+item.code+')'"
|
||||
:value="item.code"
|
||||
v-for="item in projectTypeList">
|
||||
:key="item.id"
|
||||
:label="item.name+' ('+item.code+')'"
|
||||
:value="item.code"
|
||||
v-for="item in projectTypeList">
|
||||
</el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
@@ -68,10 +68,10 @@ const ACTIVITY_CULTURE_APPLY_ACTIVITY = {
|
||||
reserve-keyword
|
||||
style="width: 100%" v-model="formData.userId">
|
||||
<el-option
|
||||
:key="item.userId"
|
||||
:label="item.userName+'-'+item.loginName+'-'+item.unitName"
|
||||
:value="item.userId"
|
||||
v-for="item in userList">
|
||||
:key="item.userId"
|
||||
:label="item.userName+'-'+item.loginName+'-'+item.unitName"
|
||||
:value="item.userId"
|
||||
v-for="item in userList">
|
||||
</el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
@@ -84,48 +84,48 @@ const ACTIVITY_CULTURE_APPLY_ACTIVITY = {
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
|
||||
<!-- <el-col :span="12"-->
|
||||
<!-- v-if="formData.isEnrollSystem === true">-->
|
||||
<!-- <el-form-item label="活动计划时间" prop="plannedDate">-->
|
||||
<!-- <el-date-picker-->
|
||||
<!-- @change="plannedDateChange"-->
|
||||
<!-- end-placeholder="结束日期"-->
|
||||
<!-- range-separator="-"-->
|
||||
<!-- start-placeholder="开始日期"-->
|
||||
<!-- style="width: 100%"-->
|
||||
<!-- type="daterange"-->
|
||||
<!-- v-model="formData.plannedDate" value-format="yyyy-MM-dd">-->
|
||||
<!-- </el-date-picker>-->
|
||||
<!-- </el-form-item>-->
|
||||
<!-- </el-col>-->
|
||||
<!-- <el-col :span="12"-->
|
||||
<!-- v-if="formData.isEnrollSystem === true">-->
|
||||
<!-- <el-form-item label="活动计划时间" prop="plannedDate">-->
|
||||
<!-- <el-date-picker-->
|
||||
<!-- @change="plannedDateChange"-->
|
||||
<!-- end-placeholder="结束日期"-->
|
||||
<!-- range-separator="-"-->
|
||||
<!-- start-placeholder="开始日期"-->
|
||||
<!-- style="width: 100%"-->
|
||||
<!-- type="daterange"-->
|
||||
<!-- v-model="formData.plannedDate" value-format="yyyy-MM-dd">-->
|
||||
<!-- </el-date-picker>-->
|
||||
<!-- </el-form-item>-->
|
||||
<!-- </el-col>-->
|
||||
|
||||
<el-col :span="12">
|
||||
<el-form-item label="实际活动时间" prop="time">
|
||||
<el-date-picker
|
||||
end-placeholder="结束日期"
|
||||
range-separator="-"
|
||||
start-placeholder="开始日期"
|
||||
style="width: 100%"
|
||||
type="daterange"
|
||||
v-model="formData.time"
|
||||
value-format="yyyy-MM-dd">
|
||||
end-placeholder="结束日期"
|
||||
range-separator="-"
|
||||
start-placeholder="开始日期"
|
||||
style="width: 100%"
|
||||
type="daterange"
|
||||
v-model="formData.time"
|
||||
value-format="yyyy-MM-dd">
|
||||
</el-date-picker>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
|
||||
<el-col :span="12">
|
||||
<el-form-item
|
||||
:rules="[{required:[1,2].includes(formData.signUpMethod),message:'请选择报名日期',trigger:['change','blur']}]"
|
||||
label="报名日期"
|
||||
prop="applyTime2">
|
||||
:rules="[{required:[1,2].includes(formData.signUpMethod),message:'请选择报名日期',trigger:['change','blur']}]"
|
||||
label="报名日期"
|
||||
prop="applyTime2">
|
||||
<el-date-picker
|
||||
end-placeholder="结束时间"
|
||||
range-separator="-"
|
||||
start-placeholder="开始时间"
|
||||
style="width: 100%"
|
||||
type="datetimerange"
|
||||
v-model="formData.applyTime2"
|
||||
value-format="yyyy-MM-dd HH:mm">
|
||||
end-placeholder="结束时间"
|
||||
range-separator="-"
|
||||
start-placeholder="开始时间"
|
||||
style="width: 100%"
|
||||
type="datetimerange"
|
||||
v-model="formData.applyTime2"
|
||||
value-format="yyyy-MM-dd HH:mm">
|
||||
</el-date-picker>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
@@ -133,9 +133,9 @@ const ACTIVITY_CULTURE_APPLY_ACTIVITY = {
|
||||
<el-col :span="12" v-if="!formData.isEnrollSystem">
|
||||
<el-form-item label="活动人数" prop="peopleNum">
|
||||
<el-input
|
||||
maxlength="10"
|
||||
placeholder="请填写活动人数"
|
||||
v-model="formData.peopleNum"></el-input>
|
||||
maxlength="10"
|
||||
placeholder="请填写活动人数"
|
||||
v-model="formData.peopleNum"></el-input>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
|
||||
@@ -156,8 +156,8 @@ const ACTIVITY_CULTURE_APPLY_ACTIVITY = {
|
||||
</div>
|
||||
<div>
|
||||
<el-button
|
||||
@click="$refs.drawerUserScope.userScopeDialog = true"
|
||||
type="primary">设置
|
||||
@click="$refs.drawerUserScope.userScopeDialog = true"
|
||||
type="primary">设置
|
||||
</el-button>
|
||||
</div>
|
||||
</div>
|
||||
@@ -181,15 +181,13 @@ const ACTIVITY_CULTURE_APPLY_ACTIVITY = {
|
||||
<el-form-item label="报名人数限制" prop="userNumberLimit">
|
||||
<el-radio-group v-model="formData.userNumberLimit" size="small">
|
||||
<el-radio border :label="1">总人数限制</el-radio>
|
||||
<el-radio border :label="2" v-if="activity_type===40001">
|
||||
分工会人数限制
|
||||
</el-radio>
|
||||
<el-radio border :label="2" v-if="activity_type===40001">分工会人数限制</el-radio>
|
||||
<el-radio border :label="null">不限制</el-radio>
|
||||
</el-radio-group>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :lg="12" :xl="12" :xs="12"
|
||||
v-if="[3].includes(formData.signUpMethod)">
|
||||
v-if="[2].includes(formData.signUpMethod)">
|
||||
<el-form-item label="组队人数" prop="totalUserNumberLimit">
|
||||
<el-input-number :max="2000" :min="1"
|
||||
:precision="0"
|
||||
@@ -317,10 +315,10 @@ const ACTIVITY_CULTURE_APPLY_ACTIVITY = {
|
||||
<el-col :span="24" v-if="formData.isEnrollSystem === false">
|
||||
<el-form-item label="活动考核内容" prop="activityExamineContent">
|
||||
<el-input
|
||||
:rows="7"
|
||||
placeholder="请输入活动考核内容"
|
||||
type="textarea"
|
||||
v-model="formData.activityExamineContent">
|
||||
:rows="7"
|
||||
placeholder="请输入活动考核内容"
|
||||
type="textarea"
|
||||
v-model="formData.activityExamineContent">
|
||||
</el-input>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
@@ -430,16 +428,16 @@ const ACTIVITY_CULTURE_APPLY_ACTIVITY = {
|
||||
<el-table :data="userData" border height="500" size="small"
|
||||
stripe v-loading="userTabLoading" row-key="userId">
|
||||
<el-table-column
|
||||
label="序号" type="index"
|
||||
width="100">
|
||||
label="序号" type="index"
|
||||
width="100">
|
||||
</el-table-column>
|
||||
|
||||
<el-table-column
|
||||
:label="column.label"
|
||||
:prop="column.prop"
|
||||
:key="column.prop"
|
||||
:sortable="column.sortable"
|
||||
v-for="column in userColumns">
|
||||
:label="column.label"
|
||||
:prop="column.prop"
|
||||
:key="column.prop"
|
||||
:sortable="column.sortable"
|
||||
v-for="column in userColumns">
|
||||
</el-table-column>
|
||||
<el-table-column label="操作"
|
||||
prop="userOnline"
|
||||
@@ -457,25 +455,26 @@ const ACTIVITY_CULTURE_APPLY_ACTIVITY = {
|
||||
</table-tool>
|
||||
<el-form-item label="" prop="activitySummary">
|
||||
<el-input
|
||||
:disabled="!formData.time || Date.now() < Date.parse(formData.time[1])"
|
||||
:rows="5"
|
||||
placeholder="请输入活动内容"
|
||||
type="textarea"
|
||||
v-model="formData.activitySummary">
|
||||
:disabled="!formData.time || Date.now() < Date.parse(formData.time[1])"
|
||||
:rows="5"
|
||||
placeholder="请输入活动内容"
|
||||
type="textarea"
|
||||
v-model="formData.activitySummary">
|
||||
</el-input>
|
||||
</el-form-item>
|
||||
<el-alert
|
||||
class="mb20"
|
||||
show-icon
|
||||
style="margin-left: 130px"
|
||||
title="活动结束后可输入活动总结"
|
||||
type="info"
|
||||
v-if="!formData.time || Date.now() < Date.parse(formData.time[1])">
|
||||
class="mb20"
|
||||
show-icon
|
||||
style="margin-left: 130px"
|
||||
title="活动结束后可输入活动总结"
|
||||
type="info"
|
||||
v-if="!formData.time || Date.now() < Date.parse(formData.time[1])">
|
||||
</el-alert>
|
||||
</el-tab-pane>
|
||||
</el-tabs>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<div style="padding: 20px;text-align: center;">
|
||||
<el-button @click="operation" style="width: 300px" type="primary" :disabled="formLoading">
|
||||
确 定
|
||||
@@ -485,12 +484,12 @@ const ACTIVITY_CULTURE_APPLY_ACTIVITY = {
|
||||
</el-card>
|
||||
|
||||
<drawer-user-scope
|
||||
@group_change="getActivityGroup"
|
||||
ref="drawerUserScope"
|
||||
:group_id.sync="formData.groupId"
|
||||
@group_change="getActivityGroup"
|
||||
ref="drawerUserScope"
|
||||
:group_id.sync="formData.groupId"
|
||||
></drawer-user-scope>
|
||||
|
||||
<el-dialog :close-on-click-modal="false" :visible.sync="userDialogVisible" append-to-body title="添加人员" width="40%">
|
||||
<el-dialog :append-to-body="true" :close-on-click-modal="false" :visible.sync="userDialogVisible" title="添加人员" width="40%">
|
||||
|
||||
<el-form :model="formData" label-width="100px">
|
||||
<el-form-item label="参加人员" prop="userId">
|
||||
@@ -502,11 +501,11 @@ const ACTIVITY_CULTURE_APPLY_ACTIVITY = {
|
||||
style="width: 100%"
|
||||
v-model="formData.tissuePersonList">
|
||||
<el-option
|
||||
:disabled="userData.map(v=>v.userId).includes(item.userId)"
|
||||
:key="item.userId"
|
||||
:label="item.userName+'-'+item.loginName+'-'+item.unitName"
|
||||
:value="item.userId"
|
||||
v-for="item in userList">
|
||||
:disabled="userData.map(v=>v.userId).includes(item.userId)"
|
||||
:key="item.userId"
|
||||
:label="item.userName+'-'+item.loginName+'-'+item.unitName"
|
||||
:value="item.userId"
|
||||
v-for="item in userList">
|
||||
</el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
@@ -733,29 +732,34 @@ const ACTIVITY_CULTURE_APPLY_ACTIVITY = {
|
||||
})
|
||||
return data
|
||||
},
|
||||
init() {
|
||||
this.formData = {
|
||||
time: [],
|
||||
applyTime2: [],
|
||||
plannedDate: [],
|
||||
goods: [],
|
||||
billFiles: [],
|
||||
photoFiles: [],
|
||||
otherFiles: [],
|
||||
tissuePersonList: [],
|
||||
unionUserNumberLimit: [],
|
||||
signUpMethod: null,
|
||||
rangerMeter: 100,
|
||||
isEnrollSystem: true,
|
||||
isPushHome: 0,
|
||||
isIntegral: false
|
||||
init(id) {
|
||||
if (id){
|
||||
this.activeName = "1"
|
||||
this.findOne(id)
|
||||
}else{
|
||||
this.formData = {
|
||||
time: [],
|
||||
applyTime2: [],
|
||||
plannedDate: [],
|
||||
goods: [],
|
||||
billFiles: [],
|
||||
photoFiles: [],
|
||||
otherFiles: [],
|
||||
tissuePersonList: [],
|
||||
unionUserNumberLimit: [],
|
||||
signUpMethod: null,
|
||||
rangerMeter: 100,
|
||||
isEnrollSystem: true,
|
||||
isPushHome: 0,
|
||||
isIntegral: false
|
||||
}
|
||||
this.generateActivityCode().then((data) => {
|
||||
this.$set(this.formData, "activityCode", data)
|
||||
})
|
||||
this.getUnionData().then((data) => {
|
||||
this.$set(this.formData, "unionUserNumberLimit", data)
|
||||
})
|
||||
}
|
||||
this.generateActivityCode().then((data) => {
|
||||
this.$set(this.formData, "activityCode", data)
|
||||
})
|
||||
this.getUnionData().then((data) => {
|
||||
this.$set(this.formData, "unionUserNumberLimit", data)
|
||||
})
|
||||
},
|
||||
async queryUserByIds(ids) {
|
||||
const { data } = await this.$axios.post("/platform/activity/culture/applyActivity/queryUserByIds", { ids: JSON.stringify(ids) })
|
||||
@@ -787,7 +791,7 @@ const ACTIVITY_CULTURE_APPLY_ACTIVITY = {
|
||||
},
|
||||
openEdit(id) {
|
||||
this.activeName = "1"
|
||||
this.findOne(id)
|
||||
this.init(id)
|
||||
}
|
||||
},
|
||||
async created() {
|
||||
@@ -799,6 +803,6 @@ const ACTIVITY_CULTURE_APPLY_ACTIVITY = {
|
||||
})
|
||||
})
|
||||
this.getActivityGroup()
|
||||
this.init()
|
||||
// this.init()
|
||||
}
|
||||
}
|
||||
|
||||
@@ -25,9 +25,9 @@ const singleSignUp = {
|
||||
:
|
||||
'协会/社团活动' }}
|
||||
</el-descriptions-item>
|
||||
<!-- <el-descriptions-item label="活动计划时间">-->
|
||||
<!-- {{ viewData.startPlannedDate + ' - ' + viewData.endPlannedDate }}-->
|
||||
<!-- </el-descriptions-item>-->
|
||||
<!-- <el-descriptions-item label="活动计划时间">-->
|
||||
<!-- {{ viewData.startPlannedDate + ' - ' + viewData.endPlannedDate }}-->
|
||||
<!-- </el-descriptions-item>-->
|
||||
<el-descriptions-item label="活动时间">
|
||||
{{ viewData.startTime + ' - ' + viewData.endTime }}
|
||||
</el-descriptions-item>
|
||||
@@ -107,19 +107,19 @@ const singleSignUp = {
|
||||
</div>
|
||||
<span v-if="!isApplyUser" class="text-primary">如需取消报名,请联系报名人。</span>
|
||||
<el-select
|
||||
v-if="isApplyUser && inApplyTime"
|
||||
v-model="searchTeammateUserId"
|
||||
filterable
|
||||
clearable
|
||||
remote
|
||||
reserve-keyword
|
||||
placeholder="请输入关键词"
|
||||
:remote-method="queryTeammate">
|
||||
v-if="isApplyUser && inApplyTime"
|
||||
v-model="searchTeammateUserId"
|
||||
filterable
|
||||
clearable
|
||||
remote
|
||||
reserve-keyword
|
||||
placeholder="请输入关键词"
|
||||
:remote-method="queryTeammate">
|
||||
<el-option
|
||||
v-for="item in teammateOptions"
|
||||
:key="item.userId"
|
||||
:label="item.userName + '(' + item.loginName + ')'"
|
||||
:value="item.userId">
|
||||
v-for="item in teammateOptions"
|
||||
:key="item.userId"
|
||||
:label="item.userName + '(' + item.loginName + ')'"
|
||||
:value="item.userId">
|
||||
</el-option>
|
||||
</el-select>
|
||||
<el-button v-if="isApplyUser && inApplyTime" class="ml5" type="primary" icon="el-icon-plus"
|
||||
@@ -160,10 +160,10 @@ const singleSignUp = {
|
||||
<template v-if="isCustomForm">
|
||||
<div class="process-title">填写报名信息</div>
|
||||
<form-create
|
||||
:value.sync="dynamicFormData"
|
||||
v-model="fapi"
|
||||
:rule="formCreateRule"
|
||||
:option="formCreateOption"
|
||||
:value.sync="dynamicFormData"
|
||||
v-model="fapi"
|
||||
:rule="formCreateRule"
|
||||
:option="formCreateOption"
|
||||
></form-create>
|
||||
</template>
|
||||
|
||||
@@ -233,7 +233,7 @@ const singleSignUp = {
|
||||
|
||||
//查询报名人员
|
||||
listTeamUser() {
|
||||
this.$axios.post("/platform/activity/culture/applyUser/listTeamUser", { activityId: this.id }).then((res) => {
|
||||
this.$axios.post("/platform/activity/culture/applyUser/listTeamUser", {activityId: this.id}).then((res) => {
|
||||
if (res.code === 0) {
|
||||
this.isSignUp = res.data.length > 0
|
||||
this.teamUsers = res.data
|
||||
@@ -270,10 +270,6 @@ const singleSignUp = {
|
||||
|
||||
//提交报名
|
||||
async onConfirm() {
|
||||
console.log(this.fapi)
|
||||
|
||||
console.log(this.fapi.formData())
|
||||
|
||||
if (this.isCustomForm && this.fapi) {
|
||||
let formValid = false
|
||||
try {
|
||||
@@ -411,7 +407,7 @@ const singleSignUp = {
|
||||
cancelButtonText: "取消",
|
||||
type: "warning"
|
||||
}).then(() => {
|
||||
this.$axios.post("/platform/activity/culture/applyUser/cancelSignUp", { activityId: this.id }).then((res) => {
|
||||
this.$axios.post("/platform/activity/culture/applyUser/cancelSignUp", {activityId: this.id}).then((res) => {
|
||||
if (res.code === 0) {
|
||||
this.dialogVisible = false
|
||||
this.$message.success(res.msg)
|
||||
@@ -424,8 +420,9 @@ const singleSignUp = {
|
||||
//查询队友信息
|
||||
queryTeammate(val) {
|
||||
if (val) {
|
||||
this.$axios.post("/platform/activity/culture/applyUser/queryTeammate", { keyword: val }).then((res) => {
|
||||
this.$axios.post("/platform/activity/culture/applyUser/queryTeammate", {keyword: val}).then((res) => {
|
||||
if (res.code === 0) {
|
||||
res.data.map(v => v.applyUserId = this.$store.state.user.id)
|
||||
this.teammateOptions = res.data
|
||||
}
|
||||
})
|
||||
@@ -457,7 +454,7 @@ const singleSignUp = {
|
||||
|
||||
//活动信息
|
||||
activityInfo() {
|
||||
this.$axios.post("/platform/activity/culture/infoManage/activityInfo", { id: this.id }).then((res) => {
|
||||
this.$axios.post("/platform/activity/culture/infoManage/activityInfo", {id: this.id}).then((res) => {
|
||||
if (res.code === 0) {
|
||||
this.viewData = res.data
|
||||
if (this.viewData.formConfig) {
|
||||
|
||||
+4
-2
@@ -4,7 +4,7 @@ layout("/layouts/platform.html"){
|
||||
|
||||
<div id="app" v-cloak>
|
||||
<guava ref="guava">
|
||||
<activity-culture-apply-activity :activity_type="activityType"></activity-culture-apply-activity>
|
||||
<activity-culture-apply-activity :activity_type="activityType" ref="activityApply"></activity-culture-apply-activity>
|
||||
</guava>
|
||||
</div>
|
||||
|
||||
@@ -23,7 +23,9 @@ layout("/layouts/platform.html"){
|
||||
"activity-culture-apply-activity": ACTIVITY_CULTURE_APPLY_ACTIVITY
|
||||
},
|
||||
methods: {},
|
||||
async created() {}
|
||||
async created() {
|
||||
setTimeout(()=>{this.$refs.activityApply.init()},500)
|
||||
}
|
||||
})
|
||||
</script>
|
||||
|
||||
|
||||
+4
-2
@@ -4,7 +4,7 @@ layout("/layouts/platform.html"){
|
||||
|
||||
<div id="app" v-cloak>
|
||||
<guava ref="guava">
|
||||
<activity-culture-apply-activity :activity_type="activityType"></activity-culture-apply-activity>
|
||||
<activity-culture-apply-activity :activity_type="activityType" ref="activityApply"></activity-culture-apply-activity>
|
||||
</guava>
|
||||
</div>
|
||||
<script>
|
||||
@@ -22,7 +22,9 @@ layout("/layouts/platform.html"){
|
||||
"activity-culture-apply-activity": ACTIVITY_CULTURE_APPLY_ACTIVITY
|
||||
},
|
||||
methods: {},
|
||||
async created() {}
|
||||
async created() {
|
||||
setTimeout(()=>{this.$refs.activityApply.init()},500)
|
||||
}
|
||||
})
|
||||
</script>
|
||||
|
||||
|
||||
@@ -26,12 +26,12 @@ layout("/layouts/platform.html"){
|
||||
<search @search="activityInfoData">
|
||||
<search-item label="">
|
||||
<el-date-picker
|
||||
@change="activityInfoData"
|
||||
placeholder="选择年"
|
||||
style="width: 100%"
|
||||
type="year"
|
||||
v-model="pageForm.year"
|
||||
value-format="yyyy"
|
||||
@change="activityInfoData"
|
||||
placeholder="选择年"
|
||||
style="width: 100%"
|
||||
type="year"
|
||||
v-model="pageForm.year"
|
||||
value-format="yyyy"
|
||||
></el-date-picker>
|
||||
</search-item>
|
||||
|
||||
@@ -45,12 +45,12 @@ layout("/layouts/platform.html"){
|
||||
<search-item label=""
|
||||
v-if="$auth.hasRole('SYSADMIN')||$auth.hasRole('SCHOOL_UNION_ADMIN')">
|
||||
<el-select
|
||||
@change="doSearch"
|
||||
clearable
|
||||
filterable
|
||||
placeholder="报名所属分工会"
|
||||
style="width: 100%"
|
||||
v-model="pageForm.unionId"
|
||||
@change="doSearch"
|
||||
clearable
|
||||
filterable
|
||||
placeholder="报名所属分工会"
|
||||
style="width: 100%"
|
||||
v-model="pageForm.unionId"
|
||||
>
|
||||
<el-option :key="item.id" :label="item.name" :value="item.id"
|
||||
v-for="item in unionOptions"></el-option>
|
||||
@@ -67,8 +67,8 @@ layout("/layouts/platform.html"){
|
||||
<el-col :key="item.id" :span="6"
|
||||
v-for="item in activityList.slice((index-1)*4,index*4)">
|
||||
<el-card
|
||||
:class="'box-card '+(item.id===pageForm.activityId?'activeCard':'')"
|
||||
style="border-radius: 10px">
|
||||
:class="'box-card '+(item.id===pageForm.activityId?'activeCard':'')"
|
||||
style="border-radius: 10px">
|
||||
<div @click="openApply(item)" class="clearfix" slot="header"
|
||||
style="font-size: 16px; padding: 5px 0">
|
||||
<el-tooltip :content="item.NAME" class="item" effect="dark"
|
||||
@@ -87,27 +87,27 @@ layout("/layouts/platform.html"){
|
||||
|
||||
<span v-if="item.gameStyle===1">{{item.activityLevelName}}</span>
|
||||
<el-tag
|
||||
effect="dark"
|
||||
style="border-radius: 50%; float: right"
|
||||
type="danger"
|
||||
v-if="$moment(item.applyEndTime).valueOf() <$moment().valueOf()"
|
||||
effect="dark"
|
||||
style="border-radius: 50%; float: right"
|
||||
type="danger"
|
||||
v-if="$moment(item.applyEndTime).valueOf() <$moment().valueOf()"
|
||||
>
|
||||
报名结束
|
||||
</el-tag>
|
||||
<el-tag
|
||||
effect="dark"
|
||||
style="border-radius: 50%; float: right"
|
||||
type="success"
|
||||
v-else-if="$moment().valueOf()>$moment(item.applyStartTime).valueOf()
|
||||
effect="dark"
|
||||
style="border-radius: 50%; float: right"
|
||||
type="success"
|
||||
v-else-if="$moment().valueOf()>$moment(item.applyStartTime).valueOf()
|
||||
&&$moment().valueOf()<$moment(item.applyEndTime).valueOf()"
|
||||
>
|
||||
报名中
|
||||
</el-tag>
|
||||
<el-tag
|
||||
effect="dark"
|
||||
style="border-radius: 50%; float: right"
|
||||
type="danger"
|
||||
v-else-if="$moment().valueOf()<$moment(item.applyEndTime).valueOf()"
|
||||
effect="dark"
|
||||
style="border-radius: 50%; float: right"
|
||||
type="danger"
|
||||
v-else-if="$moment().valueOf()<$moment(item.applyEndTime).valueOf()"
|
||||
>
|
||||
报名未开始
|
||||
</el-tag>
|
||||
@@ -138,13 +138,13 @@ layout("/layouts/platform.html"){
|
||||
<table-tool label="活动项目信息">
|
||||
<div class="search-item-option">
|
||||
<el-select
|
||||
@change="doSearch"
|
||||
clearable
|
||||
filterable
|
||||
placeholder="请选择组别"
|
||||
style="width: 100%; margin-bottom: 5px; margin-left: 10px"
|
||||
v-if="unionLeaderCoach"
|
||||
v-model="pageForm.groupName"
|
||||
@change="doSearch"
|
||||
clearable
|
||||
filterable
|
||||
placeholder="请选择组别"
|
||||
style="width: 100%; margin-bottom: 5px; margin-left: 10px"
|
||||
v-if="unionLeaderCoach"
|
||||
v-model="pageForm.groupName"
|
||||
>
|
||||
<el-option :key="item.id" :label="item.name" :value="item.name"
|
||||
v-for="item in groupList"></el-option>
|
||||
@@ -153,13 +153,13 @@ layout("/layouts/platform.html"){
|
||||
|
||||
<div class="search-item-option">
|
||||
<el-select
|
||||
@change="doSearch"
|
||||
clearable
|
||||
filterable
|
||||
placeholder="请选择活动项目"
|
||||
style="width: 100%; margin-bottom: 5px; margin-left: 10px"
|
||||
v-if="unionLeaderCoach"
|
||||
v-model="pageForm.eventId"
|
||||
@change="doSearch"
|
||||
clearable
|
||||
filterable
|
||||
placeholder="请选择活动项目"
|
||||
style="width: 100%; margin-bottom: 5px; margin-left: 10px"
|
||||
v-if="unionLeaderCoach"
|
||||
v-model="pageForm.eventId"
|
||||
>
|
||||
<el-option :key="item.eventId" :label="item.allName"
|
||||
:value="item.eventId" v-for="item in eventList"></el-option>
|
||||
@@ -170,7 +170,7 @@ layout("/layouts/platform.html"){
|
||||
<span style="color: #419bf8">{{leaderData.username?leaderData.username:'暂无'}}</span>
|
||||
  教练:
|
||||
<span
|
||||
style="color: #419bf8">{{coachData.username ?coachData.username:'暂无'}}</span>
|
||||
style="color: #419bf8">{{coachData.username ?coachData.username:'暂无'}}</span>
|
||||
</div>
|
||||
<div>
|
||||
<el-button @click="openLeaderCoach" size="medium" type="primary"
|
||||
@@ -179,32 +179,32 @@ layout("/layouts/platform.html"){
|
||||
</div>
|
||||
</table-tool>
|
||||
<el-table
|
||||
:data="tableData"
|
||||
:size="tableSize"
|
||||
@sort-change="pageOrder"
|
||||
class="vi-table"
|
||||
row-key="id"
|
||||
style="width: 100%; margin-bottom: 20px"
|
||||
v-loading="tableLoading"
|
||||
:data="tableData"
|
||||
:size="tableSize"
|
||||
@sort-change="pageOrder"
|
||||
class="vi-table"
|
||||
row-key="id"
|
||||
style="width: 100%; margin-bottom: 20px"
|
||||
v-loading="tableLoading"
|
||||
>
|
||||
<el-table-column
|
||||
:index="indexMethod"
|
||||
align="center"
|
||||
header-align="center"
|
||||
label="序号"
|
||||
type="index"
|
||||
width="80px"
|
||||
:index="indexMethod"
|
||||
align="center"
|
||||
header-align="center"
|
||||
label="序号"
|
||||
type="index"
|
||||
width="80px"
|
||||
></el-table-column>
|
||||
|
||||
<el-table-column
|
||||
:key="column.prop"
|
||||
:label="column.label"
|
||||
:prop="column.prop"
|
||||
:sortable="column.sortable"
|
||||
align="center"
|
||||
header-align="center"
|
||||
show-overflow-tooltip
|
||||
v-for="column in tableColumns"
|
||||
:key="column.prop"
|
||||
:label="column.label"
|
||||
:prop="column.prop"
|
||||
:sortable="column.sortable"
|
||||
align="center"
|
||||
header-align="center"
|
||||
show-overflow-tooltip
|
||||
v-for="column in tableColumns"
|
||||
>
|
||||
<template scope="{row}" v-if="column.prop=='projectType'">
|
||||
<span v-if="row.eveProjectType==1">单项</span>
|
||||
@@ -214,7 +214,7 @@ layout("/layouts/platform.html"){
|
||||
<template scope="{row}" v-else-if="column.prop=='applyNum'">
|
||||
<span v-if="row.successUserApply>0&&row.applyType!==3">{{ row.successUserApply }}人</span>
|
||||
<span
|
||||
v-else-if="JSON.parse(row.applyWay).length===2&&row.applyWay.includes(1)">
|
||||
v-else-if="JSON.parse(row.applyWay).length===2&&row.applyWay.includes(1)">
|
||||
{{row.totalApplyNum}}人</span>
|
||||
<span v-else-if="row.totalApplyNum>0&&row.applyType===3">{{ row.totalApplyNum }}人</span>
|
||||
<span v-else>0人</span>
|
||||
@@ -235,10 +235,10 @@ layout("/layouts/platform.html"){
|
||||
项目报名
|
||||
</el-button>
|
||||
<el-button
|
||||
:loading="row.loading"
|
||||
@click="doDelete(row)"
|
||||
size="mini"
|
||||
type="danger"
|
||||
:loading="row.loading"
|
||||
@click="doDelete(row)"
|
||||
size="mini"
|
||||
type="danger"
|
||||
>
|
||||
删除报名人员
|
||||
</el-button>
|
||||
@@ -274,13 +274,13 @@ layout("/layouts/platform.html"){
|
||||
<table-tool label="填写领队信息"></table-tool>
|
||||
<el-form-item label="姓  名" prop="userId">
|
||||
<user-select
|
||||
:option_label_func="(item)=>{return item.username + item.loginname}"
|
||||
@change="changeLeader"
|
||||
api="/platform/activity/apply/getUserUnion"
|
||||
api_input_key_name="query"
|
||||
ref="userData"
|
||||
style="width: 100%"
|
||||
v-model="leaderData.userId"
|
||||
:option_label_func="(item)=>{return item.username + item.loginname}"
|
||||
@change="changeLeader"
|
||||
api="/platform/activity/apply/getUserUnion"
|
||||
api_input_key_name="query"
|
||||
ref="userData"
|
||||
style="width: 100%"
|
||||
v-model="leaderData.userId"
|
||||
></user-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="所在单位" prop="unitId">
|
||||
@@ -299,12 +299,13 @@ layout("/layouts/platform.html"){
|
||||
<table-tool label="填写教练信息"></table-tool>
|
||||
<el-form-item label="姓  名" prop="userId">
|
||||
<user-select
|
||||
:option_label_func="(item)=>{return item.username + item.loginname}"
|
||||
@change="changeCoach"
|
||||
api="/platform/activity/apply/getUserUnion"
|
||||
api_input_key_name="query"
|
||||
style="width: 100%"
|
||||
v-model="coachData.userId"
|
||||
:option_label_func="(item)=>{return item.username + item.loginname}"
|
||||
@change="changeCoach"
|
||||
api="/platform/activity/apply/getUserUnion"
|
||||
api_input_key_name="query"
|
||||
style="width: 100%"
|
||||
ref="userData2"
|
||||
v-model="coachData.userId"
|
||||
></user-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="所在单位" prop="unitId">
|
||||
@@ -328,9 +329,9 @@ layout("/layouts/platform.html"){
|
||||
</el-dialog>
|
||||
|
||||
<el-dialog
|
||||
title="活动通知"
|
||||
:visible.sync="activityNoticeDialog"
|
||||
width="50%"
|
||||
title="活动通知"
|
||||
:visible.sync="activityNoticeDialog"
|
||||
width="50%"
|
||||
>
|
||||
<div style="margin: 10px; ">
|
||||
<div style="height: 500px; overflow: auto;"
|
||||
@@ -343,9 +344,9 @@ layout("/layouts/platform.html"){
|
||||
</div>
|
||||
|
||||
<script>
|
||||
<!--#include("applyUser.js"){}#-->
|
||||
<!--#include("deleteUser.js"){}#-->
|
||||
new Vue({
|
||||
<!--#include("applyUser.js"){}#-->
|
||||
<!--#include("deleteUser.js"){}#-->
|
||||
new Vue({
|
||||
el: "#app",
|
||||
store,
|
||||
mixins: [initTableMixins],
|
||||
@@ -366,10 +367,10 @@ layout("/layouts/platform.html"){
|
||||
groupList: [],
|
||||
eventList: [],
|
||||
tableColumns: [
|
||||
{ prop: "allName", label: "项目名称" },
|
||||
{ prop: "projectType", label: "项目类型" },
|
||||
{ prop: "applyNum", label: "已报名人数" },
|
||||
{ prop: "apply_num_bc", label: "暂保存人数" }
|
||||
{prop: "allName", label: "项目名称"},
|
||||
{prop: "projectType", label: "项目类型"},
|
||||
{prop: "applyNum", label: "已报名人数"},
|
||||
{prop: "apply_num_bc", label: "暂保存人数"}
|
||||
],
|
||||
unionOptions: [],
|
||||
|
||||
@@ -386,36 +387,40 @@ layout("/layouts/platform.html"){
|
||||
},
|
||||
methods: {
|
||||
changeLeader(id) {
|
||||
const userList = this.$refs.userData.options
|
||||
const user = userList.find((v) => v.id === id)
|
||||
this.$set(this.leaderData, "userId", id)
|
||||
this.$set(this.leaderData, "loginname", user.loginname)
|
||||
this.$set(this.leaderData, "username", user.username)
|
||||
this.$set(this.leaderData, "unitId", user.unitId)
|
||||
this.$set(this.leaderData, "sex", user.sex)
|
||||
this.$set(this.leaderData, "mobile", user.mobile)
|
||||
this.$set(this.leaderData, "unionLeader", true)
|
||||
this.$set(this.leaderData, "unionId", user.unionId)
|
||||
this.$set(this.leaderData, "identity", ["3"])
|
||||
this.$set(this.leaderData, "status", 2)
|
||||
this.$set(this.leaderData, "awardsMode", 2)
|
||||
this.$set(this.leaderData, "activityId", this.activityData.id)
|
||||
if (id) {
|
||||
const userList = this.$refs.userData.options
|
||||
const user = userList.find((v) => v.id === id)
|
||||
this.$set(this.leaderData, "userId", id)
|
||||
this.$set(this.leaderData, "loginname", user.loginname)
|
||||
this.$set(this.leaderData, "username", user.username)
|
||||
this.$set(this.leaderData, "unitId", user.unitId)
|
||||
this.$set(this.leaderData, "sex", user.sex)
|
||||
this.$set(this.leaderData, "mobile", user.mobile)
|
||||
this.$set(this.leaderData, "unionLeader", true)
|
||||
this.$set(this.leaderData, "unionId", user.unionId)
|
||||
this.$set(this.leaderData, "identity", ["3"])
|
||||
this.$set(this.leaderData, "status", 0)
|
||||
this.$set(this.leaderData, "awardsMode", 2)
|
||||
this.$set(this.leaderData, "activityId", this.activityData.id)
|
||||
}
|
||||
},
|
||||
changeCoach(id) {
|
||||
const userList = this.$refs.userData.options
|
||||
const user = userList.find((v) => v.id === id)
|
||||
this.$set(this.coachData, "userId", id)
|
||||
this.$set(this.coachData, "loginname", user.loginname)
|
||||
this.$set(this.coachData, "username", user.username)
|
||||
this.$set(this.coachData, "unitId", user.unitId)
|
||||
this.$set(this.coachData, "sex", user.sex)
|
||||
this.$set(this.coachData, "mobile", user.mobile)
|
||||
this.$set(this.coachData, "unionCoach", true)
|
||||
this.$set(this.coachData, "unionId", user.unionId)
|
||||
this.$set(this.coachData, "identity", ["2"])
|
||||
this.$set(this.coachData, "status", 2)
|
||||
this.$set(this.coachData, "awardsMode", 2)
|
||||
this.$set(this.coachData, "activityId", this.activityData.id)
|
||||
if (id) {
|
||||
const userList = this.$refs.userData2.options
|
||||
const user = userList.find((v) => v.id === id)
|
||||
this.$set(this.coachData, "userId", id)
|
||||
this.$set(this.coachData, "loginname", user.loginname)
|
||||
this.$set(this.coachData, "username", user.username)
|
||||
this.$set(this.coachData, "unitId", user.unitId)
|
||||
this.$set(this.coachData, "sex", user.sex)
|
||||
this.$set(this.coachData, "mobile", user.mobile)
|
||||
this.$set(this.coachData, "unionCoach", true)
|
||||
this.$set(this.coachData, "unionId", user.unionId)
|
||||
this.$set(this.coachData, "identity", ["2"])
|
||||
this.$set(this.coachData, "status", 0)
|
||||
this.$set(this.coachData, "awardsMode", 2)
|
||||
this.$set(this.coachData, "activityId", this.activityData.id)
|
||||
}
|
||||
},
|
||||
async doLeaderCoach() {
|
||||
this.formLoading = true
|
||||
@@ -445,8 +450,17 @@ layout("/layouts/platform.html"){
|
||||
this.coachData = {}
|
||||
if (this.leaderData || this.coachData) {
|
||||
await this.getUnionCoachLeaderHead()
|
||||
|
||||
}
|
||||
this.dialogLeaderCoach = true
|
||||
setTimeout(async () => {
|
||||
if (this.leaderData.loginname) {
|
||||
await this.$refs.userData.selectUser(this.leaderData.loginname)
|
||||
}
|
||||
if (this.coachData.loginname) {
|
||||
await this.$refs.userData2.selectUser(this.coachData.loginname)
|
||||
}
|
||||
}, 500)
|
||||
},
|
||||
async activityInfoData() {
|
||||
const resp = await this.$axios.post(loc() + "/activityData", this.pageForm)
|
||||
@@ -486,8 +500,8 @@ layout("/layouts/platform.html"){
|
||||
this.coachData = {}
|
||||
this.headData = {}
|
||||
this.staffData = {}
|
||||
const resp = await this.$axios.post(loc() + "/getUnionCoachLeaderHead", { activityId: this.pageForm.activityId })
|
||||
const { unionCoach, unionLeader, unionHead, unionStaff, userOptions } = resp.data
|
||||
const resp = await this.$axios.post(loc() + "/getUnionCoachLeaderHead", {activityId: this.pageForm.activityId})
|
||||
const {unionCoach, unionLeader, unionHead, unionStaff, userOptions} = resp.data
|
||||
if (unionCoach) {
|
||||
this.coachData = unionCoach
|
||||
}
|
||||
@@ -504,14 +518,14 @@ layout("/layouts/platform.html"){
|
||||
this.userOptions = userOptions
|
||||
},
|
||||
async changeActivity() {
|
||||
const resp = await this.$axios.post("/platform/activity/apply/getEvents", { activityId: this.pageForm.activityId })
|
||||
const resp = await this.$axios.post("/platform/activity/apply/getEvents", {activityId: this.pageForm.activityId})
|
||||
this.eventList = resp.data
|
||||
},
|
||||
pageData() {
|
||||
this.tabLoading = true
|
||||
const pageForm = clone(this.pageForm)
|
||||
pageForm.isMenWomen = JSON.stringify(pageForm.isMenWomen)
|
||||
this.$axios.post("/platform/activity/apply/pageData", { data: JSON.stringify(pageForm) }).then((res) => {
|
||||
this.$axios.post("/platform/activity/apply/pageData", {data: JSON.stringify(pageForm)}).then((res) => {
|
||||
if (res.code === 0) {
|
||||
this.tableData = res.data.list
|
||||
this.pageForm.totalCount = res.data.totalCount
|
||||
|
||||
@@ -148,12 +148,13 @@ layout("/layouts/platform_h5.html"){
|
||||
margin-left: 0 !important;
|
||||
}
|
||||
|
||||
.form-create-h5 .el-radio-group{
|
||||
.form-create-h5 .el-radio-group {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
row-gap: 20px;
|
||||
}
|
||||
.form-create-h5 .el-radio-group label{
|
||||
|
||||
.form-create-h5 .el-radio-group label {
|
||||
width: 100%;
|
||||
margin-right: 0;
|
||||
}
|
||||
@@ -161,7 +162,8 @@ layout("/layouts/platform_h5.html"){
|
||||
</style>
|
||||
|
||||
<div id="app" v-cloak>
|
||||
<van-nav-bar @click-left="historyBack" placeholder fixed left-arrow left-text="返回" placeholder title="活动详情"></van-nav-bar>
|
||||
<van-nav-bar @click-left="historyBack" placeholder fixed left-arrow left-text="返回" placeholder
|
||||
title="活动详情"></van-nav-bar>
|
||||
|
||||
<div style="background: #ededed; padding-bottom: 56px">
|
||||
<van-image :src="viewData.cover"></van-image>
|
||||
@@ -198,12 +200,12 @@ layout("/layouts/platform_h5.html"){
|
||||
<span style="color: var(--color-primary)">{{viewData.teamNum}}</span>
|
||||
人
|
||||
</div>
|
||||
<!-- <div class="info-item" v-if="viewData.signUpMethod==1">-->
|
||||
<!-- <van-icon name="location-o"></van-icon>-->
|
||||
<!-- 报名人数:-->
|
||||
<!-- <span style="color: var(--color-primary)">2</span>-->
|
||||
<!-- 人-->
|
||||
<!-- </div>-->
|
||||
<!-- <div class="info-item" v-if="viewData.signUpMethod==1">-->
|
||||
<!-- <van-icon name="location-o"></van-icon>-->
|
||||
<!-- 报名人数:-->
|
||||
<!-- <span style="color: var(--color-primary)">2</span>-->
|
||||
<!-- 人-->
|
||||
<!-- </div>-->
|
||||
</div>
|
||||
|
||||
<div class="notice">
|
||||
@@ -225,23 +227,25 @@ layout("/layouts/platform_h5.html"){
|
||||
<span v-if="!isApplyUser" class="text-primary">如需取消报名,请联系报名人。</span>
|
||||
<div style="margin-top: 10px">
|
||||
<el-select
|
||||
v-if="isApplyUser && inApplyTime"
|
||||
v-model="searchTeammateUserId"
|
||||
filterable
|
||||
clearable
|
||||
remote
|
||||
reserve-keyword
|
||||
placeholder="请输入关键词"
|
||||
:remote-method="queryTeammate"
|
||||
v-if="isApplyUser && inApplyTime"
|
||||
v-model="searchTeammateUserId"
|
||||
filterable
|
||||
clearable
|
||||
remote
|
||||
reserve-keyword
|
||||
placeholder="请输入关键词"
|
||||
:remote-method="queryTeammate"
|
||||
>
|
||||
<el-option
|
||||
v-for="item in teammateOptions"
|
||||
:key="item.userId"
|
||||
:label="item.userName + '(' + item.loginName + ')'"
|
||||
:value="item.userId"
|
||||
v-for="item in teammateOptions"
|
||||
:key="item.userId"
|
||||
:label="item.userName + '(' + item.loginName + ')'"
|
||||
:value="item.userId"
|
||||
></el-option>
|
||||
</el-select>
|
||||
<el-button v-if="isApplyUser && inApplyTime" class="ml5" type="primary" icon="el-icon-plus" @click="addTeamUser">添加</el-button>
|
||||
<el-button v-if="isApplyUser && inApplyTime" class="ml5" type="primary" icon="el-icon-plus"
|
||||
@click="addTeamUser">添加
|
||||
</el-button>
|
||||
|
||||
<el-table :data="teamUsers" class="mt10" border>
|
||||
<el-table-column label="序号" type="index" width="60px"></el-table-column>
|
||||
@@ -256,13 +260,14 @@ layout("/layouts/platform_h5.html"){
|
||||
<el-tag size="mini" v-if="row.applyUserId==row.userId">报名人</el-tag>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="操作" width="100px" v-if="(isApplyUser || teamUsers.length===0) && inApplyTime">
|
||||
<el-table-column label="操作" width="100px"
|
||||
v-if="(isApplyUser || teamUsers.length===0) && inApplyTime">
|
||||
<template slot-scope="scope">
|
||||
<el-button
|
||||
type="danger"
|
||||
size="mini"
|
||||
@click="removeTeamUser(scope.$index)"
|
||||
v-if="scope.row.applyUserId!==scope.row.userId"
|
||||
type="danger"
|
||||
size="mini"
|
||||
@click="removeTeamUser(scope.$index)"
|
||||
v-if="scope.row.applyUserId!==scope.row.userId"
|
||||
>
|
||||
删除
|
||||
</el-button>
|
||||
@@ -274,17 +279,20 @@ layout("/layouts/platform_h5.html"){
|
||||
|
||||
<div class="form-create-h5" v-if="isCustomForm">
|
||||
<div class="notice-title left-tag-title">填写报名信息</div>
|
||||
<form-create :value.sync="dynamicFormData" v-model="fapi" :rule="formCreateRule" :option="formCreateOption"></form-create>
|
||||
<form-create :value.sync="dynamicFormData" v-model="fapi" :rule="formCreateRule"
|
||||
:option="formCreateOption"></form-create>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="footer">
|
||||
<div class="bottom-button" style="background: var(--color-primary)" v-if="!isSignUp && inApplyTime" @click="onConfirm">
|
||||
<div class="bottom-button" style="background: var(--color-primary)" v-if="!isSignUp && inApplyTime"
|
||||
@click="onConfirm">
|
||||
<span>立即报名</span>
|
||||
<span style="font-size: 12px; margin-top: 5px">{{viewData.applyEndTime}}截止报名</span>
|
||||
</div>
|
||||
|
||||
<div class="bottom-button" style="background: var(--color-primary)" v-if="isSignUp && inApplyTime" @click="onConfirmAgain">
|
||||
<div class="bottom-button" style="background: var(--color-primary)" v-if="isSignUp && inApplyTime"
|
||||
@click="onConfirmAgain">
|
||||
<span>重新提交</span>
|
||||
<span style="font-size: 12px; margin-top: 5px">{{viewData.applyEndTime}}截止报名</span>
|
||||
</div>
|
||||
@@ -351,7 +359,7 @@ layout("/layouts/platform_h5.html"){
|
||||
methods: {
|
||||
init() {
|
||||
if (this.id) {
|
||||
this.$axios.post("/platform/activity/culture/infoManage/activityInfo", { id: this.id }).then((res) => {
|
||||
this.$axios.post("/platform/activity/culture/infoManage/activityInfo", {id: this.id}).then((res) => {
|
||||
if (res.code === 0) {
|
||||
this.viewData = res.data
|
||||
if (this.viewData.formConfig) {
|
||||
@@ -365,7 +373,7 @@ layout("/layouts/platform_h5.html"){
|
||||
},
|
||||
//查询报名人员
|
||||
listTeamUser() {
|
||||
this.$axios.post("/platform/activity/culture/applyUser/listTeamUser", { activityId: this.id }).then((res) => {
|
||||
this.$axios.post("/platform/activity/culture/applyUser/listTeamUser", {activityId: this.id}).then((res) => {
|
||||
if (res.code === 0) {
|
||||
this.isSignUp = res.data.length > 0
|
||||
this.teamUsers = res.data
|
||||
@@ -419,15 +427,29 @@ layout("/layouts/platform_h5.html"){
|
||||
if (this.viewData.signUpMethod === 2) {
|
||||
//组队人数判断
|
||||
if (this.teamUsers.length === 0) {
|
||||
this.$message.warning("请添加队友后再提交!")
|
||||
this.$toast("请添加队友后再提交!")
|
||||
return
|
||||
}
|
||||
if (this.teamUsers.length < this.viewData.teamNum) {
|
||||
this.$message.warning("您选择的人数小于" + this.viewData.teamNum + "人,请重新选择!")
|
||||
this.$dialog
|
||||
.alert({
|
||||
title: "提示",
|
||||
message: "您选择的人数小于" + this.viewData.teamNum + "人,请重新选择!"
|
||||
})
|
||||
.then(() => {
|
||||
|
||||
})
|
||||
return
|
||||
}
|
||||
if (this.teamUsers.length > this.viewData.teamNum) {
|
||||
this.$message.warning("您选择的人数大于" + this.viewData.teamNum + "人,请重新选择!")
|
||||
this.$dialog
|
||||
.alert({
|
||||
title: "提示",
|
||||
message: "您选择的人数大于" + this.viewData.teamNum + "人,请重新选择!"
|
||||
})
|
||||
.then(() => {
|
||||
|
||||
})
|
||||
return
|
||||
}
|
||||
}
|
||||
@@ -435,11 +457,25 @@ layout("/layouts/platform_h5.html"){
|
||||
//分工会
|
||||
if (this.viewData.signUpMethod === 3) {
|
||||
if (this.teamUsers.length === 0) {
|
||||
this.$message.warning("请添加报名人员后再提交!")
|
||||
this.$dialog
|
||||
.alert({
|
||||
title: "提示",
|
||||
message: "请添加报名人员后再提交!"
|
||||
})
|
||||
.then(() => {
|
||||
|
||||
})
|
||||
return
|
||||
}
|
||||
if (this.teamUsers.length > this.viewData.teamNum) {
|
||||
this.$message.warning("您选择的人数大于" + this.viewData.teamNum + "人,请重新选择!")
|
||||
this.$dialog
|
||||
.alert({
|
||||
title: "提示",
|
||||
message: "您选择的人数大于" + this.viewData.teamNum + "人,请重新选择!"
|
||||
})
|
||||
.then(() => {
|
||||
|
||||
})
|
||||
return
|
||||
}
|
||||
}
|
||||
@@ -485,15 +521,36 @@ layout("/layouts/platform_h5.html"){
|
||||
if (this.viewData.signUpMethod === 2) {
|
||||
//组队人数判断
|
||||
if (this.teamUsers.length === 0) {
|
||||
this.$message.warning("请添加队友后再提交!")
|
||||
this.$dialog
|
||||
.alert({
|
||||
title: "提示",
|
||||
message: "请添加队友后再提交!"
|
||||
})
|
||||
.then(() => {
|
||||
|
||||
})
|
||||
return
|
||||
}
|
||||
if (this.teamUsers.length < this.viewData.teamNum) {
|
||||
this.$message.warning("您选择的人数小于" + this.viewData.teamNum + "人,请重新选择!")
|
||||
this.$dialog
|
||||
.alert({
|
||||
title: "提示",
|
||||
message: "您选择的人数小于" + this.viewData.teamNum + "人,请重新选择!"
|
||||
})
|
||||
.then(() => {
|
||||
|
||||
})
|
||||
return
|
||||
}
|
||||
if (this.teamUsers.length > this.viewData.teamNum) {
|
||||
this.$message.warning("您选择的人数大于" + this.viewData.teamNum + "人,请重新选择!")
|
||||
this.$dialog
|
||||
.alert({
|
||||
title: "提示",
|
||||
message: "您选择的人数大于" + this.viewData.teamNum + "人,请重新选择!"
|
||||
})
|
||||
.then(() => {
|
||||
|
||||
})
|
||||
return
|
||||
}
|
||||
}
|
||||
@@ -501,11 +558,25 @@ layout("/layouts/platform_h5.html"){
|
||||
//分工会
|
||||
if (this.viewData.signUpMethod === 3) {
|
||||
if (this.teamUsers.length === 0) {
|
||||
this.$message.warning("请添加报名人员后再提交!")
|
||||
this.$dialog
|
||||
.alert({
|
||||
title: "提示",
|
||||
message: "请添加报名人员后再提交!"
|
||||
})
|
||||
.then(() => {
|
||||
|
||||
})
|
||||
return
|
||||
}
|
||||
if (this.teamUsers.length > this.viewData.teamNum) {
|
||||
this.$message.warning("您选择的人数大于" + this.viewData.teamNum + "人,请重新选择!")
|
||||
this.$dialog
|
||||
.alert({
|
||||
title: "提示",
|
||||
message: "您选择的人数大于" + this.viewData.teamNum + "人,请重新选择!"
|
||||
})
|
||||
.then(() => {
|
||||
|
||||
})
|
||||
return
|
||||
}
|
||||
}
|
||||
@@ -544,11 +615,11 @@ layout("/layouts/platform_h5.html"){
|
||||
message: "确定取消报名吗?"
|
||||
})
|
||||
.then(() => {
|
||||
this.$axios.post("/platform/activity/culture/applyUser/cancelSignUp", { activityId: this.id }).then((res) => {
|
||||
this.$axios.post("/platform/activity/culture/applyUser/cancelSignUp", {activityId: this.id}).then((res) => {
|
||||
if (res.code === 0) {
|
||||
this.fapi.resetFields()
|
||||
this.$toast.success(res.msg)
|
||||
this.listTeamUser()
|
||||
this.fapi.resetFields()
|
||||
}
|
||||
})
|
||||
})
|
||||
@@ -557,8 +628,11 @@ layout("/layouts/platform_h5.html"){
|
||||
//查询队友信息
|
||||
queryTeammate(val) {
|
||||
if (val) {
|
||||
this.$axios.post("/platform/activity/culture/applyUser/queryTeammate", { keyword: val }).then((res) => {
|
||||
this.$axios.post("/platform/activity/culture/applyUser/queryTeammate", {keyword: val}).then((res) => {
|
||||
if (res.code === 0) {
|
||||
res.data.map(v => {
|
||||
v.applyUserId = this.$store.state.user.id
|
||||
})
|
||||
this.teammateOptions = res.data
|
||||
}
|
||||
})
|
||||
@@ -568,15 +642,36 @@ layout("/layouts/platform_h5.html"){
|
||||
//添加队友
|
||||
addTeamUser() {
|
||||
if (!this.searchTeammateUserId) {
|
||||
this.$message.error("请先选择后再添加")
|
||||
this.$dialog
|
||||
.alert({
|
||||
title: "提示",
|
||||
message: "请先选择后再添加!"
|
||||
})
|
||||
.then(() => {
|
||||
|
||||
})
|
||||
return
|
||||
}
|
||||
if (this.teamUsers.some((v) => v.userId === this.searchTeammateUserId)) {
|
||||
this.$message.error("请勿重复添加")
|
||||
this.$dialog
|
||||
.alert({
|
||||
title: "提示",
|
||||
message: "请勿重复添加!"
|
||||
})
|
||||
.then(() => {
|
||||
|
||||
})
|
||||
return
|
||||
}
|
||||
if (this.teamUsers.length >= this.viewData.teamNum) {
|
||||
this.$message.error("已满员")
|
||||
this.$dialog
|
||||
.alert({
|
||||
title: "提示",
|
||||
message: "已满员!"
|
||||
})
|
||||
.then(() => {
|
||||
|
||||
})
|
||||
return
|
||||
}
|
||||
this.teamUsers.push(this.teammateOptions.find((v) => v.userId === this.searchTeammateUserId))
|
||||
|
||||
@@ -1,40 +1,49 @@
|
||||
<!--#
|
||||
layout("/layouts/platform_h5.html"){
|
||||
#-->
|
||||
<style>
|
||||
.van-tag--default {
|
||||
background-color: #f1f1f1 !important;
|
||||
}
|
||||
</style>
|
||||
|
||||
<div id="app" v-cloak>
|
||||
<van-nav-bar title="活动列表" @click-left="historyBack" left-arrow left-text="返回" placeholder fixed></van-nav-bar>
|
||||
<van-nav-bar title="活动列表" @click-left="()=>this.$pjaxReplace('/platform/home')" left-arrow left-text="返回" placeholder fixed></van-nav-bar>
|
||||
<van-sticky offset-top="46px">
|
||||
<van-dropdown-menu>
|
||||
<year-van-dropdown-item :num="5" @change="pageData" v-model="pageForm.year"></year-van-dropdown-item>
|
||||
<van-dropdown-item :options="stateList" @change="pageData" v-model="pageForm.isActivity"></van-dropdown-item>
|
||||
<van-dropdown-item :options="applyStatusOptions" @change="pageData" v-model="pageForm.applyStatus"></van-dropdown-item>
|
||||
<van-dropdown-item :options="stateList" @change="pageData"
|
||||
v-model="pageForm.isActivity"></van-dropdown-item>
|
||||
<van-dropdown-item :options="applyStatusOptions" @change="pageData"
|
||||
v-model="pageForm.applyStatus"></van-dropdown-item>
|
||||
</van-dropdown-menu>
|
||||
</van-sticky>
|
||||
|
||||
<div>
|
||||
<van-list :finished="finished" @load="pageData" finished-text="没有更多了" v-if="tableData.length>0" v-model="loading">
|
||||
<van-list :finished="finished" @load="pageData" finished-text="没有更多了" v-if="tableData.length>0"
|
||||
v-model="loading">
|
||||
<div class="table-list">
|
||||
<div :key="row.id" class="table-card" v-for="row in tableData">
|
||||
<van-tag mark size="small" style="position: absolute; left: 5px; top: 5px; z-index: 1">
|
||||
<span style="color: forestgreen" v-if="$moment(row.applyStartTime).valueOf() > $moment().valueOf()">未开始报名</span>
|
||||
<van-tag mark size="large" style="position: absolute; right: 0%; top: 5px; z-index: 1">
|
||||
<span style="color: forestgreen"
|
||||
v-if="$moment(row.applyStartTime).valueOf() > $moment().valueOf()">未开始报名</span>
|
||||
<span
|
||||
style="color: forestgreen"
|
||||
v-else-if="$moment(row.applyEndTime).valueOf() > $moment().valueOf() &&
|
||||
style="color: forestgreen"
|
||||
v-else-if="$moment(row.applyEndTime).valueOf() > $moment().valueOf() &&
|
||||
$moment().valueOf() > $moment(row.applyStartTime).valueOf()"
|
||||
>
|
||||
报名中
|
||||
</span>
|
||||
<span
|
||||
style="color: #ee1919"
|
||||
v-else-if="$moment(row.applyEndTime).valueOf() < $moment().valueOf() &&
|
||||
style="color: #ee1919"
|
||||
v-else-if="$moment(row.applyEndTime).valueOf() < $moment().valueOf() &&
|
||||
$moment().valueOf() < $moment(row.startTime).valueOf()"
|
||||
>
|
||||
报名结束
|
||||
</span>
|
||||
<span
|
||||
style="color: forestgreen"
|
||||
v-else-if="$moment(row.startTime).valueOf() < $moment().valueOf() &&
|
||||
style="color: forestgreen"
|
||||
v-else-if="$moment(row.startTime).valueOf() < $moment().valueOf() &&
|
||||
$moment().valueOf() < $moment(row.endTime).valueOf()"
|
||||
>
|
||||
活动进行中
|
||||
@@ -53,19 +62,20 @@ layout("/layouts/platform_h5.html"){
|
||||
<van-cell :value="row.applyEndTime" title="报名结束时间"></van-cell>
|
||||
<van-cell class="table-card-footer">
|
||||
<template>
|
||||
<van-button :loading="subLoading" @click="openView(row)" round size="small" type="primary">查看</van-button>
|
||||
<van-button :loading="subLoading" @click="openView(row)" round size="small" type="primary">查 看</van-button>
|
||||
</template>
|
||||
</van-cell>
|
||||
</div>
|
||||
</div>
|
||||
</van-list>
|
||||
<van-empty image="/assets/platform/plugins/vant-green/images/nodata/nodata.png" description="暂无数据" v-else></van-empty>
|
||||
<van-empty image="/assets/platform/plugins/vant-green/images/nodata/nodata.png" description="暂无数据"
|
||||
v-else></van-empty>
|
||||
</div>
|
||||
|
||||
<activity_event_notification
|
||||
:event_notification="viewData.eventNotification"
|
||||
:id="viewData.id"
|
||||
ref="eventNotification"
|
||||
:event_notification="viewData.eventNotification"
|
||||
:id="viewData.id"
|
||||
ref="eventNotification"
|
||||
></activity_event_notification>
|
||||
</div>
|
||||
|
||||
@@ -88,13 +98,13 @@ layout("/layouts/platform_h5.html"){
|
||||
},
|
||||
yearList: [],
|
||||
applyStatusOptions: [
|
||||
{ value: 1, text: "未报名" },
|
||||
{ value: 2, text: "已报名" }
|
||||
{value: 1, text: "未报名"},
|
||||
{value: 2, text: "已报名"}
|
||||
],
|
||||
stateList: [
|
||||
{ value: 1, text: "全部" },
|
||||
{ value: 2, text: "报名中" },
|
||||
{ value: 3, text: "报名已结束" }
|
||||
{value: 1, text: "全部"},
|
||||
{value: 2, text: "报名中"},
|
||||
{value: 3, text: "报名已结束"}
|
||||
],
|
||||
subLoading: false,
|
||||
viewShow: false,
|
||||
|
||||
Reference in New Issue
Block a user