commit
This commit is contained in:
@@ -1,4 +1,3 @@
|
||||
|
||||
<template>
|
||||
<div>
|
||||
<el-steps :active="active" finish-status="success" simple>
|
||||
@@ -194,7 +193,7 @@
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<el-form-item prop="applyWay" label="报名方式">
|
||||
<el-checkbox-group v-model="form.applyWay" >
|
||||
<el-checkbox-group v-model="form.applyWay">
|
||||
<el-checkbox :disabled="form.activityLevel !== 40001" :label="2"
|
||||
border>基层工会报名
|
||||
</el-checkbox>
|
||||
@@ -207,7 +206,7 @@
|
||||
<el-form-item prop="isSign" label="是否需要签字">
|
||||
<el-radio-group v-model="form.isSign">
|
||||
<el-radio :label="true" border>需要</el-radio>
|
||||
<el-radio :label="false" border >不需要</el-radio>
|
||||
<el-radio :label="false" border>不需要</el-radio>
|
||||
</el-radio-group>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
@@ -698,10 +697,10 @@ module.exports = {
|
||||
type: Object,
|
||||
default: {}
|
||||
},
|
||||
is_club: { type: Boolean, default: false },
|
||||
is_union: { type: Boolean, default: false },
|
||||
is_sysadmin: { type: Boolean, default: false },
|
||||
is_a06: { type: Boolean, default: false }
|
||||
is_club: {type: Boolean, default: false},
|
||||
is_union: {type: Boolean, default: false},
|
||||
is_sysadmin: {type: Boolean, default: false},
|
||||
is_a06: {type: Boolean, default: false}
|
||||
},
|
||||
components: {
|
||||
"file-upload": httpVueLoader("/components/plugins/FileUpload.vue"),
|
||||
@@ -725,7 +724,7 @@ module.exports = {
|
||||
return {
|
||||
unionUserNumOneKeyRatio: null,
|
||||
summaryCount: 0,
|
||||
unionUserNumCalc: [{ startNum: 1, endNum: 1, resultNum: 1 }],
|
||||
unionUserNumCalc: [{startNum: 1, endNum: 1, resultNum: 1}],
|
||||
activityGroupList: [],
|
||||
active: 0,
|
||||
eventForm: {
|
||||
@@ -742,18 +741,18 @@ module.exports = {
|
||||
events: [],
|
||||
projectType: "",
|
||||
formRules: {
|
||||
name: [{ required: true, message: "必填", trigger: ["blur", "change"] }],
|
||||
address: [{ required: true, message: "必填", trigger: ["blur", "change"] }],
|
||||
typeId: [{ required: true, message: "必填", trigger: ["blur", "change"] }],
|
||||
eventsIds: [{ required: true, message: "必填", trigger: ["blur", "change"] }],
|
||||
applyTime: [{ required: true, message: "必填", trigger: ["blur", "change"] }],
|
||||
unitSponsor: [{ required: true, message: "必填", trigger: ["blur", "change"] }],
|
||||
undertakeUnit: [{ required: true, message: "必填", trigger: ["blur", "change"] }],
|
||||
name: [{required: true, message: "必填", trigger: ["blur", "change"]}],
|
||||
address: [{required: true, message: "必填", trigger: ["blur", "change"]}],
|
||||
typeId: [{required: true, message: "必填", trigger: ["blur", "change"]}],
|
||||
eventsIds: [{required: true, message: "必填", trigger: ["blur", "change"]}],
|
||||
applyTime: [{required: true, message: "必填", trigger: ["blur", "change"]}],
|
||||
unitSponsor: [{required: true, message: "必填", trigger: ["blur", "change"]}],
|
||||
undertakeUnit: [{required: true, message: "必填", trigger: ["blur", "change"]}],
|
||||
// unitJointly: [{required: true, message: '必填', trigger: ['blur', 'change']}],
|
||||
time: [{ required: true, message: "必填", trigger: ["blur", "change"] }],
|
||||
activityGroupId: [{ required: true, message: "必填", trigger: ["blur", "change"] }],
|
||||
gameStyle: [{ required: true, message: "必填", trigger: ["blur", "change"] }],
|
||||
applyWay: [{ required: true, message: "必填", trigger: ["blur", "change"] }],
|
||||
time: [{required: true, message: "必填", trigger: ["blur", "change"]}],
|
||||
activityGroupId: [{required: true, message: "必填", trigger: ["blur", "change"]}],
|
||||
gameStyle: [{required: true, message: "必填", trigger: ["blur", "change"]}],
|
||||
applyWay: [{required: true, message: "必填", trigger: ["blur", "change"]}],
|
||||
restrictTotalPeople: [{
|
||||
required: true,
|
||||
message: "必填",
|
||||
@@ -769,12 +768,12 @@ module.exports = {
|
||||
// rewardMethod: [{required: true, message: '必填', trigger: ['blur', 'change']}],
|
||||
// precautions: [{required: true, message: '必填', trigger: ['blur', 'change']}],
|
||||
// eventNotification: [{required: true, message: '必填', trigger: ['blur', 'change']}],
|
||||
personType: [{ required: true, message: "必填", trigger: ["blur", "change"] }],
|
||||
personType: [{required: true, message: "必填", trigger: ["blur", "change"]}],
|
||||
// athleteQualification: [{required: true, message: '必填', trigger: ['blur', 'change']}],
|
||||
activityLevel: [{ required: true, message: "必填", trigger: ["blur", "change"] }],
|
||||
activityLevel: [{required: true, message: "必填", trigger: ["blur", "change"]}],
|
||||
// belongClubId: [{required: true, message: '必填', trigger: ['blur', 'change']}],
|
||||
applyType: [{ required: true, message: "必填", trigger: ["blur", "change"] }],
|
||||
athletesMaxNum: [{ required: true, message: "必填", trigger: ["blur", "change"] }],
|
||||
applyType: [{required: true, message: "必填", trigger: ["blur", "change"]}],
|
||||
athletesMaxNum: [{required: true, message: "必填", trigger: ["blur", "change"]}],
|
||||
restrictRegNumber: [{
|
||||
required: true,
|
||||
message: "必填",
|
||||
@@ -787,7 +786,7 @@ module.exports = {
|
||||
async applyUserModelInput(val) {
|
||||
if (val === 2) {
|
||||
if (!this.eventForm.unionLimit || this.eventForm.unionLimit.length === 0) {
|
||||
const resp = await $.get(loc() + "/getUnionLimit", { activityScopeId: this.eventForm.activityGroupId })
|
||||
const resp = await $.get(loc() + "/getUnionLimit", {activityScopeId: this.eventForm.activityGroupId})
|
||||
if (resp.code === 0) {
|
||||
this.$set(this.eventForm, "unionLimit", resp.data)
|
||||
}
|
||||
@@ -932,7 +931,7 @@ module.exports = {
|
||||
},
|
||||
async eventChange(val) {
|
||||
const data = this.checkedEventInfo.find((v) => v.eventId === val)
|
||||
const resp = await $.get("/platform/activity/school/info/mange/getEventData", { id: val })
|
||||
const resp = await $.get("/platform/activity/school/info/mange/getEventData", {id: val})
|
||||
await this.$nextTick()
|
||||
if (data) {
|
||||
data.applyUserModel = data.applyUserModel ? data.applyUserModel : 1
|
||||
@@ -995,7 +994,7 @@ module.exports = {
|
||||
|
||||
},
|
||||
getArrDifference(arr1, arr2) {
|
||||
return arr1.concat(arr2).filter(function(v, i, arr) {
|
||||
return arr1.concat(arr2).filter(function (v, i, arr) {
|
||||
return arr.indexOf(v) === arr.lastIndexOf(v)
|
||||
})
|
||||
},
|
||||
@@ -1003,26 +1002,26 @@ module.exports = {
|
||||
this.$refs["activityForm"].validate(async (valid) => {
|
||||
const form = clone(this.form)
|
||||
if (!valid) {
|
||||
this.$notify.warning({ title: "警告", message: "存在未填的必填项" })
|
||||
this.$notify.warning({title: "警告", message: "存在未填的必填项"})
|
||||
return
|
||||
}
|
||||
const arrDifference = this.getArrDifference(this.form.unitJointly, this.form.unitSponsor)
|
||||
if (arrDifference.length === 0) {
|
||||
this.$notify.error({ title: "错误", message: "协办单位里存在主办单位" })
|
||||
this.$notify.error({title: "错误", message: "协办单位里存在主办单位"})
|
||||
return
|
||||
}
|
||||
|
||||
if (moment(this.form.time[0]).valueOf() <= moment(this.form.applyTime[0]).valueOf()) {
|
||||
this.$notify.error({ title: "错误", message: "活动时间必须晚于报名时间" })
|
||||
this.$notify.error({title: "错误", message: "活动时间必须晚于报名时间"})
|
||||
return
|
||||
}
|
||||
|
||||
if (form.applyWay.includes(3) && !form.image) {
|
||||
this.$notify.error({ title: "错误", message: "请上传小程序活动封面图" })
|
||||
this.$notify.error({title: "错误", message: "请上传小程序活动封面图"})
|
||||
return
|
||||
}
|
||||
if (this.form.eventsIds.length === 0) {
|
||||
this.$notify.error({ title: "错误", message: "请选择项目" })
|
||||
this.$notify.error({title: "错误", message: "请选择项目"})
|
||||
return
|
||||
}
|
||||
|
||||
@@ -1112,7 +1111,7 @@ module.exports = {
|
||||
})
|
||||
},
|
||||
async getActivityCode(activity_type) {
|
||||
const { data } = await $.get("/platform/activity/apply/generateActivityCode", { activity_type: activity_type })
|
||||
const {data} = await $.get("/platform/activity/apply/generateActivityCode", {activity_type: activity_type})
|
||||
return data
|
||||
},
|
||||
async openEdit(row, flag) {
|
||||
@@ -1120,10 +1119,10 @@ module.exports = {
|
||||
await this.applyTypeChange(row.applyType)
|
||||
this.planList = await activity.getSchoolActivityPlan(1)
|
||||
await this.getActivityGroup()
|
||||
const { id } = row
|
||||
const {id} = row
|
||||
this.$set(row, "loading", true)
|
||||
|
||||
const resp = await $.get("/platform/activity/school/info/mange/findOne", { id })
|
||||
const resp = await $.get("/platform/activity/school/info/mange/findOne", {id})
|
||||
if (resp.code === 0) {
|
||||
const v = resp.data
|
||||
|
||||
@@ -1193,13 +1192,13 @@ module.exports = {
|
||||
this.$emit("flip")
|
||||
window.location.reload()
|
||||
} else {
|
||||
this.$notify.error({ title: "错误", message: resp.msg })
|
||||
this.$notify.error({title: "错误", message: resp.msg})
|
||||
}
|
||||
loading.close()
|
||||
},
|
||||
async operate() {
|
||||
const deleteEventIds = this.eventsIds.filter((v) => !this.form.eventsIds.includes(v))
|
||||
const { data } = await $.get(loc() + "/getEventApply", {
|
||||
const {data} = await $.get(loc() + "/getEventApply", {
|
||||
activityId: this.form.id,
|
||||
eventId: JSON.stringify(deleteEventIds)
|
||||
})
|
||||
@@ -1243,7 +1242,7 @@ module.exports = {
|
||||
form.restrictMinNum = form.athletesMaxNum
|
||||
form.isSave = true
|
||||
|
||||
const { time, applyTime } = form
|
||||
const {time, applyTime} = form
|
||||
if (applyTime && applyTime.length) {
|
||||
form.applyStartTime = applyTime[0]
|
||||
form.applyEndTime = applyTime[1]
|
||||
@@ -1295,21 +1294,21 @@ module.exports = {
|
||||
loading.close()
|
||||
},
|
||||
examineTrans(form) {
|
||||
const { unitJointly, unitSponsor, time, applyTime, applyWay, image } = form
|
||||
const {unitJointly, unitSponsor, time, applyTime, applyWay, image} = form
|
||||
|
||||
const arrDifference = this.getArrDifference(unitJointly, unitSponsor)
|
||||
if (arrDifference.length === 0) {
|
||||
this.$notify.error({ title: "错误", message: "协办单位里存在主办单位" })
|
||||
this.$notify.error({title: "错误", message: "协办单位里存在主办单位"})
|
||||
return
|
||||
}
|
||||
|
||||
if (moment(time[0]).valueOf() <= moment(applyTime[0]).valueOf()) {
|
||||
this.$notify.error({ title: "错误", message: "活动时间必须晚于报名时间" })
|
||||
this.$notify.error({title: "错误", message: "活动时间必须晚于报名时间"})
|
||||
return
|
||||
}
|
||||
|
||||
if (applyWay.includes(3) && !image) {
|
||||
this.$notify.error({ title: "错误", message: "请上传小程序活动封面图" })
|
||||
this.$notify.error({title: "错误", message: "请上传小程序活动封面图"})
|
||||
return
|
||||
}
|
||||
|
||||
@@ -1335,7 +1334,7 @@ module.exports = {
|
||||
this.$set(this.eventForm, "restrictGirlNum", 0)
|
||||
},
|
||||
async getActivityGroup() {
|
||||
const { data } = await $.get("/platform/activity/basic/scope/getActivityUserScopeGroup")
|
||||
const {data} = await $.get("/platform/activity/basic/scope/getActivityUserScopeGroup")
|
||||
this.activityGroupList = data
|
||||
},
|
||||
async initCnd() {
|
||||
@@ -1343,11 +1342,11 @@ module.exports = {
|
||||
const personType = await getDictByCode("personType")
|
||||
|
||||
const userStateOptions = userState.map((v) => {
|
||||
return { label: v.name, value: v.name }
|
||||
return {label: v.name, value: v.name}
|
||||
})
|
||||
|
||||
const personTypeOptions = personType.map((v) => {
|
||||
return { label: v.name, value: v.name }
|
||||
return {label: v.name, value: v.name}
|
||||
})
|
||||
|
||||
this.fields = [
|
||||
@@ -1356,8 +1355,8 @@ module.exports = {
|
||||
value: "sex",
|
||||
type: "select",
|
||||
options: [
|
||||
{ label: "男", value: "男" },
|
||||
{ label: "女", value: "女" }
|
||||
{label: "男", value: "男"},
|
||||
{label: "女", value: "女"}
|
||||
]
|
||||
},
|
||||
{
|
||||
|
||||
@@ -1210,6 +1210,18 @@ layout("/layouts/platform.html"){
|
||||
</span>
|
||||
</el-dialog>
|
||||
|
||||
<el-dialog
|
||||
:close-on-click-modal="false"
|
||||
:visible.sync="detailsDialogVisible"
|
||||
title="活动通知"
|
||||
width="70%"
|
||||
>
|
||||
<div v-html="activityData2.eventNotification"></div>
|
||||
<span class="dialog-footer" slot="footer">
|
||||
<el-button @click="detailsDialogVisible = false" type="primary">关 闭</el-button>
|
||||
</span>
|
||||
</el-dialog>
|
||||
|
||||
</div>
|
||||
|
||||
<script>
|
||||
@@ -1342,7 +1354,9 @@ layout("/layouts/platform.html"){
|
||||
promiseBookDialogVisible: false,
|
||||
|
||||
// 活动审核相关
|
||||
activityIsAudit: false
|
||||
activityIsAudit: false,
|
||||
|
||||
detailsDialogVisible: false,
|
||||
}
|
||||
},
|
||||
filters: {
|
||||
@@ -1812,6 +1826,8 @@ layout("/layouts/platform.html"){
|
||||
this.pageData()
|
||||
|
||||
await this.changeActivit()
|
||||
|
||||
this.detailsDialogVisible = true
|
||||
},
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user