安财赛事报名

dev_202412
yujialong 6 months ago
parent 175962b8dc
commit cf7a643f2e
  1. 13
      src/pages/account/login/index.vue
  2. 8
      src/pages/match/details/index.vue
  3. 6
      src/pages/match/list/index.vue
  4. 192
      src/pages/touristMatch/list/index.vue
  5. 2
      src/setting.js

@ -1,12 +1,12 @@
<template>
<div class="wrap">
<div class="login">
<div class="notice-alert">
<!-- <div class="notice-alert">
<el-alert
title="平台维护通知:我们计划于2024年9月6日(星期五)20:00至2024年9月7日(星期六)12:00进行系统维护升级工作。维护期间,平台将暂时关闭,所有用户将无法登录平台,全部服务将暂停使用。"
type="warning" :closable="false">
</el-alert>
</div>
</div> -->
<div class="form">
<h6 class="title">欢迎使用请登录</h6>
@ -746,7 +746,7 @@ export default {
.login {
min-height: calc(100vh - 43px);
padding-top: calc((100vh - 750px) / 2);
padding-top: calc((100vh - 584px) / 2);
background: url(../../../assets/img/shapes/shape1.png) (0 123px) / auto no-repeat,
url(../../../assets/img/shapes/shape2.png) (35px 238px) / auto no-repeat,
url(../../../assets/img/shapes/shape3.png) (0 485px) / auto no-repeat,
@ -888,13 +888,6 @@ export default {
border-radius: 4px;
border: 0;
}
.notice {
width: 400px;
// padding: 10px 20px;
margin-left: 20px;
// box-shadow: 0 0 7px rgba(235, 235, 235, .8);
}
}
.copyright {

@ -1369,7 +1369,7 @@ export default {
//
async getCurSchool () {
const res = await this.$post(this.api.getSchoolIdByToken)
this.enterForm.realSchoolId = res.schoolId
this.curRealSchoolId = res.schoolId
},
//
async getSchool () {
@ -1426,6 +1426,7 @@ export default {
//
enterClose () {
this.enterForm = {
realSchoolId: '',
competitionId: this.id,
teamId: '',
registrationInvitationCode: '',
@ -1699,8 +1700,11 @@ export default {
} else if (status == 2) { //
//
if (competitionType || this.fromOffical) {
this.agreeCheck = false
this.enterVisible = true
if (this.fromOffical) {
this.agreeCheck = false
this.enterForm.realSchoolId = this.curRealSchoolId
}
} else { //
if (form.completeCompetitionSetup.isNeedCode) {
this.peopleSignupForm.registrationInvitationCode = ''

@ -458,7 +458,7 @@ export default {
},
computed: {
...mapState("user", [
"userId", 'account', , 'userName'
"userId", 'account', 'userName'
])
},
watch: {
@ -481,7 +481,6 @@ export default {
this.clearTimer()
})
console.log(333, this.fromOffical)
if (this.fromOffical) {
this.getCurSchool()
this.getSchool()
@ -691,7 +690,6 @@ export default {
async getCurSchool () {
const res = await this.$post(this.api.getSchoolIdByToken)
this.curRealSchoolId = res.schoolId
console.log("🚀 ~ getCurSchool ~ this.enterForm.realSchoolId:", this.enterForm.realSchoolId)
},
//
async getSchool () {
@ -730,6 +728,7 @@ export default {
await this.$post(this.api[isTeam ? 'joinCompetitionTeam' : 'addCompetitionRegistration'], form)
this.enterVisible = false
this.getData()
this.getCurSchool()
Util.successMsg('报名成功!')
this.submiting = false
},
@ -1008,6 +1007,7 @@ export default {
if (competitionType || this.fromOffical) {
this.getTeam()
this.enterForm = {
realSchoolId: '',
competitionId: id,
teamId: '',
invitationCode: '',

@ -129,6 +129,7 @@
</div>
</div>
<!-- 个人报名有赛事邀请码的情况没有赛事邀请码的情况不用弹框直接报名成功 -->
<el-dialog title="报名" :visible.sync="peopleSignupVisible" :close-on-click-modal="false" width="300px">
<el-form class="dia-form">
<el-form-item>
@ -141,7 +142,72 @@
<el-button size="small" @click="peopleSignupVisible = false">取消</el-button>
</span>
</el-dialog>
<el-dialog title="报名" :visible.sync="enterVisible" :close-on-click-modal="false" width="300px">
<!-- 安财赛事报名专用个人及团队都用这个 -->
<el-dialog v-if="fromOffical" title="报名" :visible.sync="enterVisible" :close-on-click-modal="false" width="850px"
custom-class="enter-dia">
<div class="flex">
<el-form class="dia-form" label-width="90px">
<el-form-item label="姓名">
<el-input disabled v-model="userName"></el-input>
</el-form-item>
<el-form-item label="来自学校">
<el-select v-model="enterForm.realSchoolId" filterable style="width: 100%">
<el-option v-for="(item, i) in schools" :key="i" :label="item.schoolName"
:value="item.schoolId"></el-option>
</el-select>
</el-form-item>
<!-- 团队报名 -->
<template v-if="curItem.competitionType">
<p class="m-t-20 m-b-5">请选择要加入的团队</p>
<el-form-item label="团队">
<el-select class="w-100" v-model="enterForm.teamId" filterable>
<el-option v-for="(item, i) in teams" :key="i" :label="item.teamName" :value="item.teamId"></el-option>
</el-select>
</el-form-item>
<el-form-item label="团队邀请码">
<el-input placeholder="请输入团队邀请码" maxlength="6" v-model="enterForm.invitationCode"></el-input>
</el-form-item>
</template>
<el-form-item label="大赛邀请码" v-if="curItem.isNeedCode">
<el-input placeholder="请输入大赛邀请码" maxlength="6" v-model="enterForm.registrationInvitationCode"></el-input>
</el-form-item>
<p v-if="curItem.competitionType" class="tips">
查找不到团队点击 <el-link :underline="false" type="primary" @click="toTeam">创建团队</el-link>
</p>
</el-form>
<div class="agree">
<div class="agreement">
<h6>参赛选手承诺书</h6>
<div class="text">
<p class="line">本人自愿参加2024年安徽省大学生金融投资创新大赛为进一步提高廉洁自律意识客观公正的履行职责我以大赛参赛学生的身份和荣誉郑重作出如下承诺</p>
<p class="line">1尊重大赛组委会及秘书处尊重专家和仲裁尊重参赛单位和其他选手客观公正地参加比赛</p>
<p class="line">
2遵守道德遵守大赛纪律不私下接触其他参赛单位和团队成员专家裁判员仲裁员
</p>
<p class="line">
3保证提交的所有信息数据和材料均真实准确合法及有效不侵犯任何第三方的知识产权和其他权益参赛选手均无条件配合大赛组委会对参赛选手提供的数据信息材料及有关情况等进行核实
</p>
<p class="line">4遵守公正公平原则不干扰裁判员仲裁员等工作及其他参赛单位和团队成员等比赛影响比赛成绩认可大赛组委会提供的基础数据</p>
<p class="line">5不发表不传播没有根据并对大赛产生不利影响的言论</p>
<p class="line">6不隐瞒按规定应该回避的事项</p>
<p class="line">7对于涉嫌泄密事宜愿接受协助配合相关部门的监督检查并履行举证义务</p>
<p class="line">8如若发生上述问题自愿承担相关责任</p>
<p class="line">特此承诺</p>
<p class="line">勾选后才可登录和注册</p>
</div>
</div>
<el-checkbox class="m-t-15 m-l-20" v-model="agreeCheck">同意我已阅读</el-checkbox>
</div>
</div>
<span slot="footer" class="dialog-footer">
<el-button size="small" type="primary" @click="officalEnterSubmit">报名</el-button>
<el-button size="small" @click="enterVisible = false">取消</el-button>
</span>
</el-dialog>
<el-dialog v-else title="报名" :visible.sync="enterVisible" :close-on-click-modal="false" width="300px">
<el-form class="dia-form">
<p style="margin-bottom: 5px">请选择要加入的团队</p>
<el-form-item>
@ -164,6 +230,7 @@
<el-button size="small" @click="enterVisible = false">取消</el-button>
</span>
</el-dialog>
<el-dialog title="创建团队" :visible.sync="teamVisible" :close-on-click-modal="false" width="300px">
<el-form class="dia-form">
<el-form-item>
@ -260,11 +327,15 @@ export default {
enterVisible: false,
enterForm: {
realSchoolId: '',
competitionId: '',
teamId: '',
invitationCode: '',
registrationInvitationCode: ''
},
curRealSchoolId: '',
schools: [],
agreeCheck: false,
teamVisible: false,
teams: [],
@ -286,18 +357,28 @@ export default {
timer: null,
};
},
computed: {
...mapState("user", [
'userId', , 'userName'
])
},
watch: {
keyword: function (val) {
keyword: function () {
clearTimeout(this.searchTimer);
this.searchTimer = setTimeout(() => {
this.initData();
}, 500);
this.initData()
}, 500)
}
},
mounted () {
this.getProvince()
this.getData()
this.$once('hook:beforeDestroy', this.clearTimer)
if (this.fromOffical && this.token) {
this.getCurSchool()
this.getSchool()
}
},
methods: {
getList () {
@ -320,9 +401,10 @@ export default {
let result = []
// 4
if (this.fromOffical) {
list.forEach(e => {
(+e.id > 457 && +e.id < 462) && result.push(e)
})
result = list
// list.forEach(e => {
// (+e.id > 457 && +e.id < 462) && result.push(e)
// })
} else {
result = list
}
@ -484,27 +566,59 @@ export default {
},
//
peopleSignupSubmit () {
this.$post(this.api.addCompetitionRegistration, {
async peopleSignupSubmit () {
await this.$post(this.api.addCompetitionRegistration, {
competitionId: this.curRow.id,
registrationInvitationCode: this.peopleSignupForm.registrationInvitationCode
}).then(res => {
this.peopleSignupVisible = false
this.getData()
this.$message.success('报名成功')
}).catch(res => { })
})
this.peopleSignupVisible = false
this.getData()
this.$message.success('报名成功')
},
//
async getCurSchool () {
const res = await this.$post(this.api.getSchoolIdByToken)
this.curRealSchoolId = res.schoolId
},
//
async getSchool () {
const res = await this.$post(this.api.customerSettingsList, {
pageNum: 1,
pageSize: 10000,
})
this.schools = res.page.records
},
//
enterSubmit () {
async enterSubmit () {
const form = this.enterForm
if (!form.teamId) return Util.errorMsg('请选择团队')
if (!form.invitationCode) return Util.errorMsg('请输入团队邀请码')
if (this.curItem.isNeedCode && !form.registrationInvitationCode) return Util.errorMsg('请输入大赛邀请码')
this.$post(this.api.joinCompetitionTeam, form).then(res => {
this.enterVisible = false
this.getData()
Util.successMsg('报名成功!')
}).catch(res => { })
delete form.realSchoolId
await this.$post(this.api.joinCompetitionTeam, form)
this.enterVisible = false
this.getData()
Util.successMsg('报名成功!')
},
//
async officalEnterSubmit () {
if (this.submiting) return false
if (!this.agreeCheck) return Util.errorMsg('请勾选同意,才可继续报名!')
const form = this.enterForm
const isTeam = this.curItem.competitionType //
if (isTeam) {
if (!form.teamId) return Util.errorMsg('请选择团队')
if (!form.invitationCode) return Util.errorMsg('请输入团队邀请码')
}
if (!form.realSchoolId) return Util.errorMsg('请选择来自学校')
if (this.curItem.isNeedCode && !form.registrationInvitationCode) return Util.errorMsg('请输入大赛邀请码')
this.submiting = true
await this.$post(this.api[isTeam ? 'joinCompetitionTeam' : 'addCompetitionRegistration'], form)
this.enterVisible = false
this.getData()
this.getCurSchool()
Util.successMsg('报名成功!')
this.submiting = false
},
// 线
@ -591,16 +705,21 @@ export default {
this.getAllow(item)
}
} else if (status == 2) { //
//
if (item.competitionType) {
//
if (competitionType || this.fromOffical) {
this.getTeam()
this.enterForm = {
realSchoolId: '',
competitionId: id,
teamId: '',
invitationCode: '',
registrationInvitationCode: ''
}
this.enterVisible = true
if (this.fromOffical) {
this.agreeCheck = false
this.enterForm.realSchoolId = this.curRealSchoolId
}
} else { //
if (item.isNeedCode) {
this.curRow = item
@ -632,7 +751,6 @@ export default {
type: 'success',
closeOnClickModal: false
}).then(() => {
// this.$route.query.q ? localStorage.removeItem('toMatch') : localStorage.setItem('toMatch', item.id)
localStorage.setItem('toMatch', item.id)
this.$router.push('/login')
}).catch(() => { })
@ -997,6 +1115,34 @@ export default {
}
}
/deep/.enter-dia {
.agree {
width: 500px;
margin-left: 20px;
}
.agreement {
max-height: 300px;
padding: 10px 20px;
box-shadow: 0 0 7px rgba(235, 235, 235, .8);
overflow: auto;
h6 {
font-size: 20px;
font-weight: 600;
text-align: center;
}
.text {
line-height: 1.6;
}
.line {
margin-top: 7px;
}
}
}
@media (max-width: 1000px) {
.main {
.center-wrap {

@ -30,7 +30,7 @@ if (isDev) {
host = "http://121.37.12.51/"; // 测试服
// host = 'https://www.occupationlab.com/' // 正式服
const ip = localStorage.getItem('localIp')
const ips = ['http://192.168.31.217:9000/', 'http://192.168.31.51:9000/', 'https://izhixinyun.com/']
const ips = ['http://192.168.31.217:9000/', 'http://192.168.31.51:9000/', 'http://121.37.12.51/']
host = ips[+ip]
// host = 'http://192.168.31.51:9000/'
} else if (isSq) {

Loading…
Cancel
Save