687 lines
33 KiB
HTML
687 lines
33 KiB
HTML
<!--#
|
|
layout("/mobile/platform.html"){
|
|
#-->
|
|
|
|
<style>
|
|
[v-cloak] {
|
|
display: none;
|
|
}
|
|
|
|
.yd-navbar-item span {
|
|
color: #40A9FB !important;
|
|
}
|
|
|
|
.van-tabs__content {
|
|
|
|
}
|
|
|
|
.van-tabs__nav--card {
|
|
margin: 0px 10px;
|
|
}
|
|
|
|
@font-face {
|
|
font-family: 'iconfont'; /* project id 1341271 */
|
|
src: url('//at.alicdn.com/t/font_1341271_xgu8wtr4c1q.eot');
|
|
src: url('//at.alicdn.com/t/font_1341271_xgu8wtr4c1q.eot?#iefix') format('embedded-opentype'),
|
|
url('//at.alicdn.com/t/font_1341271_xgu8wtr4c1q.woff2') format('woff2'),
|
|
url('//at.alicdn.com/t/font_1341271_xgu8wtr4c1q.woff') format('woff'),
|
|
url('//at.alicdn.com/t/font_1341271_xgu8wtr4c1q.ttf') format('truetype'),
|
|
url('//at.alicdn.com/t/font_1341271_xgu8wtr4c1q.svg#iconfont') format('svg');
|
|
}
|
|
|
|
.iconfont {
|
|
font-family: "iconfont" !important;
|
|
font-size: 0.6rem;
|
|
/*color: rgb(255, 104, 93);*/
|
|
font-style: normal;
|
|
-webkit-font-smoothing: antialiased;
|
|
-webkit-text-stroke-width: 0.2px;
|
|
-moz-osx-font-smoothing: grayscale;
|
|
}
|
|
|
|
.yd-list-donetip {
|
|
padding: 0 0 .25rem 0;
|
|
}
|
|
|
|
.yd-confirm-ft > a.primary {
|
|
color: #40A9FB;
|
|
}
|
|
|
|
.van-pull-refresh__head {
|
|
height: 80px;
|
|
line-height: 100px;
|
|
}
|
|
|
|
.van-pull-refresh {
|
|
overflow: visible;
|
|
}
|
|
|
|
.van-tabs--card {
|
|
padding-top: 0px;
|
|
}
|
|
|
|
</style>
|
|
<div id="app" v-cloak>
|
|
<van-nav-bar title="活动报名"
|
|
left-arrow placeholder fixed
|
|
@click-left="location.replace('/mobile/index')">
|
|
</van-nav-bar>
|
|
|
|
<van-pull-refresh v-model="isLoading" @refresh="onRefresh" style="margin-top: 0.5rem;">
|
|
|
|
<div>
|
|
|
|
<van-tabs type="card" color="#40A9FB" @click="onClick">
|
|
<van-tab title="校活动">
|
|
|
|
<yd-infinitescroll :callback="load" ref="infinitescroll">
|
|
<yd-list theme="1" slot="list">
|
|
<ul>
|
|
<div style="margin-left: 34px;margin-bottom: 8px;font-size: 14px;color: #989898"></div>
|
|
<li v-for="item,index in dataList"
|
|
style="box-shadow:#B5B5B5 0px 0px 4px;background-color: white;margin: 0px 0.20rem 0.4rem 0.20rem;padding: 0.3rem 0.34rem">
|
|
|
|
<div style="display: flex;justify-content:space-around;">
|
|
<div style="width: 80%">
|
|
<div style="font-size: 1rem;font-family: 等线;color: #161616">{{item.xhdmc}}
|
|
</div>
|
|
<div style="margin-top: 0.5rem;font-size: .6rem;color: #606060;">
|
|
{{item.hddz}}
|
|
</div>
|
|
</div>
|
|
<div style="width: 20%;display: flex;align-items:center;justify-content: center">
|
|
<div v-if="(item.cc=='1'||item.cc=='2')&&item.bmzt=='未报名'||item.bmzt==''||item.bmzt==null"
|
|
@click="xhdBm(item.id,item.hdrs)" style="color:rgb(255, 104, 93)"><i
|
|
slot="icon" class="iconfont" color="#FF685D"
|
|
style="font-size: 1.5rem;"></i></div>
|
|
<div v-if="(item.cc!='1'||item.cc!='2')&&item.bmzt=='报名待审核'"
|
|
@click="qxXhdBm(item.id)" style="color: #FFA500"><i slot="icon"
|
|
class="iconfont"
|
|
color="#FFA500"
|
|
style="font-size: 1.5rem;"></i>
|
|
</div>
|
|
<div v-if="(item.cc!='1'&&item.cc!='2')&&item.bmzt=='报名通过'"
|
|
@click="qxXhdBm(item.id)" style="color:#90EE90"><i slot="icon"
|
|
class="iconfont"
|
|
color=" #90EE90"
|
|
style="font-size: 1.5rem;font-weight: bolder"></i>
|
|
</div>
|
|
<div v-if="(item.cc!='1'||item.cc!='2')&&item.bmzt=='报名驳回'"
|
|
@click="xhdBm(item.id,item.hdrs)" style="color:#B5B5B5"><i slot="icon"
|
|
class="iconfont"
|
|
color="#B5B5B5"
|
|
style="font-size: 1.5rem;"></i>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<div style="width: 100%;height: 1px;margin: 10px 0;background-color: #dcdcdc"></div>
|
|
|
|
<div @click="viewInfo(item.id,item.xhdmc)" style="display: flex;font-size: 12px">
|
|
<div style="width: 38%">
|
|
<div style="color: gray;margin-bottom: 10px">活动项目</div>
|
|
<div class="text-overflow">{{item.name}}</div>
|
|
</div>
|
|
<div style="width: 38%">
|
|
<div style="color: gray;margin-bottom: 10px">报名结束时间</div>
|
|
<div class="text-overflow">{{item.bmjssj}}</div>
|
|
</div>
|
|
<div style="width: 23%">
|
|
<div style="color: gray;margin-bottom: 10px">活动开始时间</div>
|
|
<div class="text-overflow">{{item.hdkssj}}</div>
|
|
</div>
|
|
</div>
|
|
|
|
</li>
|
|
<van-empty
|
|
v-if="xShow"
|
|
class="custom-image"
|
|
image="/none.svg"
|
|
description="暂无数据"
|
|
></van-empty>
|
|
</ul>
|
|
|
|
</yd-list>
|
|
<!-- 数据全部加载完毕显示 -->
|
|
<span slot="doneTip">没有更多数据了</span>
|
|
|
|
</yd-infinitescroll>
|
|
|
|
</van-tab>
|
|
|
|
<van-tab title="分会活动">
|
|
<yd-infinitescroll :callback="fhLoad" ref="fhInfinitescroll">
|
|
<yd-list theme="1" slot="list">
|
|
|
|
<ul>
|
|
<div style="margin-left: 34px;margin-bottom: 8px;font-size: 14px;color: #989898"></div>
|
|
<li v-for="item,index in fhDataList"
|
|
style="box-shadow:#B5B5B5 0px 0px 4px;background-color: white;margin: 0px 0.20rem 0.4rem 0.20rem;padding: 0.3rem 0.34rem">
|
|
|
|
<div style="display: flex;justify-content:space-around;">
|
|
<div style="width: 80%" @click="viewInfo(item.id,item.fhdmc)">
|
|
<div style="font-size: 1rem;font-family: 等线;color: #161616">{{item.fhdmc}}
|
|
</div>
|
|
<div style="margin-top: 0.5rem;font-size: .6rem;color: #606060;">
|
|
{{item.hddz}}
|
|
</div>
|
|
</div>
|
|
<div style="width: 20%;display: flex;align-items:center;justify-content: center">
|
|
<div v-if="item.sfbm=='0'" @click="fhdBm(item.id,item.hdrs)"
|
|
style="color:rgb(255, 104, 93)"><i slot="icon" class="iconfont"
|
|
color="#FF685D"
|
|
style="font-size: 0.7rem;"></i>
|
|
</div>
|
|
<div v-if="item.sfbm>'0'" @click="qxFhBm(item.id,item.hdrs)"
|
|
style="color:#90EE90;"><i slot="icon" class="iconfont" color="#90EE90"
|
|
style="font-size: 0.7rem;font-weight: bolder"></i>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<div style="width: 100%;height: 1px;margin: 10px 0;background-color: #dcdcdc"></div>
|
|
|
|
<div @click="viewInfo(item.id,item.fhdmc)" style="display: flex;font-size: 12px">
|
|
<div style="width: 38%">
|
|
<div style="color: gray;margin-bottom: 10px">活动项目</div>
|
|
<div class="text-overflow">{{item.name}}</div>
|
|
</div>
|
|
<div style="width: 38%">
|
|
<div style="color: gray;margin-bottom: 10px">报名结束时间</div>
|
|
<div class="text-overflow">{{item.bmjssj}}</div>
|
|
</div>
|
|
<div style="width: 23%">
|
|
<div style="color: gray;margin-bottom: 10px">活动开始时间</div>
|
|
<div class="text-overflow">{{item.hdkssj}}</div>
|
|
</div>
|
|
</div>
|
|
</li>
|
|
<van-empty
|
|
v-if="fhShow"
|
|
class="custom-image"
|
|
image="/none.svg"
|
|
description="暂无数据"
|
|
></van-empty>
|
|
</ul>
|
|
|
|
</yd-list>
|
|
<!-- 数据全部加载完毕显示 -->
|
|
<span slot="doneTip">没有更多数据了</span>
|
|
|
|
</yd-infinitescroll>
|
|
</van-tab>
|
|
|
|
<van-tab title="协会活动">
|
|
<yd-infinitescroll :callback="stLoad" ref="stInfinitescroll">
|
|
<yd-list theme="1" slot="list">
|
|
|
|
<ul>
|
|
<div style="margin-left: 34px;margin-bottom: 8px;font-size: 14px;color: #989898"></div>
|
|
<li v-for="item,index in stDataList"
|
|
style="box-shadow:#B5B5B5 0px 0px 4px;background-color: white;margin: 0px 0.20rem 0.4rem 0.20rem;padding: 0.3rem 0.34rem">
|
|
|
|
<div style="display: flex;justify-content:space-around;">
|
|
<div style="width: 80%" @click="viewInfo(item.id,item.hdmc)">
|
|
<div style="font-size: 1rem;font-family: 等线;color: #161616">{{item.hdmc}}
|
|
</div>
|
|
<div style="margin-top: 0.5rem;font-size: .6rem;color: #606060;">
|
|
{{item.hddz}}
|
|
</div>
|
|
</div>
|
|
<div style="width: 20%;display: flex;align-items:center;justify-content: center">
|
|
<div v-if="item.sfbm=='0'" @click="sthdBm(item.id,item.cyrs)"
|
|
style="color:rgb(255, 104, 93)"><i slot="icon" class="iconfont"
|
|
color="#FF685D"
|
|
style="font-size: 0.7rem;"></i>
|
|
</div>
|
|
<div v-if="item.sfbm>'0'" @click="qxsthBm(item.id,item.cyrs)"
|
|
style="color:#90EE90;"><i slot="icon" class="iconfont" color="#90EE90"
|
|
style="font-size: 0.7rem;font-weight: bolder"></i>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<div style="width: 100%;height: 1px;margin: 10px 0;background-color: #dcdcdc"></div>
|
|
|
|
<div @click="viewInfo(item.id,item.hdmc)" style="display: flex;font-size: 12px">
|
|
<div style="width: 38%">
|
|
<div style="color: gray;margin-bottom: 10px">活动项目</div>
|
|
<div class="text-overflow">{{item.name}}</div>
|
|
</div>
|
|
<div style="width: 38%">
|
|
<div style="color: gray;margin-bottom: 10px">报名结束时间</div>
|
|
<div class="text-overflow">{{item.bmjssj}}</div>
|
|
</div>
|
|
<div style="width: 23%">
|
|
<div style="color: gray;margin-bottom: 10px">活动开始时间</div>
|
|
<div class="text-overflow">{{item.hdkssj}}</div>
|
|
</div>
|
|
</div>
|
|
</li>
|
|
<van-empty
|
|
v-if="stShow"
|
|
class="custom-image"
|
|
image="/none.svg"
|
|
description="暂无数据"
|
|
></van-empty>
|
|
</ul>
|
|
|
|
</yd-list>
|
|
<!-- 数据全部加载完毕显示 -->
|
|
<span slot="doneTip">没有更多数据了</span>
|
|
|
|
</yd-infinitescroll>
|
|
</van-tab>
|
|
|
|
</van-tabs>
|
|
|
|
</div>
|
|
</van-pull-refresh>
|
|
<yd-backtop></yd-backtop>
|
|
|
|
</div>
|
|
|
|
<!-- 引入组件库 -->
|
|
<script src="//unpkg.com/vue-ydui/dist/ydui.rem.js"></script>
|
|
<script>Vue.config.productionTip = false</script>
|
|
|
|
<script>
|
|
let Vue = window.Vue;
|
|
let vant = window.vant;
|
|
|
|
// 注册 Lazyload 组件
|
|
Vue.use(vant.Lazyload);
|
|
|
|
let vue = new Vue({
|
|
el: '#app',
|
|
data() {
|
|
return {
|
|
active: "0",
|
|
pageForm: {
|
|
pageNumber: 1,
|
|
pageSize: 5,
|
|
searchWord: "",
|
|
},
|
|
fhPageForm: {
|
|
pageNumber: 1,
|
|
pageSize: 5,
|
|
searchWord: "",
|
|
},
|
|
stPageForm: {
|
|
pageNumber: 1,
|
|
pageSize: 5,
|
|
searchWord: "",
|
|
},
|
|
flag: "0",
|
|
dataList: [],
|
|
fhDataList: [],
|
|
stDataList: [],
|
|
isLoading: false,
|
|
xShow: false,
|
|
fhShow: false,
|
|
stShow: false,
|
|
}
|
|
},
|
|
methods: {
|
|
pageData() {
|
|
let self = this;
|
|
$.post("/mobile/hd/hdbm/data", self.pageForm, function (data) {
|
|
if (data.code == 0) {
|
|
if (data.data.hds.list.length == 0) {
|
|
self.xShow = true;
|
|
} else {
|
|
self.dataList = [];
|
|
self.xShow = false;
|
|
self.dataList = data.data.hds.list;
|
|
self.$refs.infinitescroll.$emit('ydui.infinitescroll.reInit');
|
|
}
|
|
}
|
|
}, "json");
|
|
},
|
|
load() {
|
|
let self = this;
|
|
setTimeout(function () {
|
|
self.pageForm.pageNumber = self.pageForm.pageNumber + 1;
|
|
$.post("/mobile/hd/hdbm/data", self.pageForm, function (data) {
|
|
if (data.code == 0) {
|
|
self.dataList = self.dataList.concat(data.data.hds.list);
|
|
if (data.data.hds.list.length == 0) {
|
|
self.$refs.infinitescroll.$emit('ydui.infinitescroll.loadedDone');
|
|
return;
|
|
} else {
|
|
self.$refs.infinitescroll.$emit('ydui.infinitescroll.finishLoad');
|
|
}
|
|
}
|
|
}, "json");
|
|
}, 400);
|
|
},
|
|
fhLoad() {
|
|
let self = this;
|
|
setTimeout(function () {
|
|
self.fhPageForm.pageNumber = self.fhPageForm.pageNumber + 1;
|
|
$.post("/mobile/hd/hdbm/fhData", self.fhPageForm, function (data) {
|
|
if (data.code == 0) {
|
|
self.fhDataList = self.fhDataList.concat(data.data.hds.list);
|
|
if (data.data.hds.list.length == 0) {
|
|
self.$refs.fhInfinitescroll.$emit('ydui.infinitescroll.loadedDone');
|
|
return;
|
|
} else {
|
|
self.$refs.fhInfinitescroll.$emit('ydui.infinitescroll.finishLoad');
|
|
}
|
|
}
|
|
}, "json");
|
|
}, 400);
|
|
},
|
|
stLoad() {
|
|
let self = this;
|
|
setTimeout(function () {
|
|
self.stPageForm.pageNumber = self.stPageForm.pageNumber + 1;
|
|
$.post("/mobile/hd/hdbm/stData", self.stPageForm, function (data) {
|
|
if (data.code == 0) {
|
|
self.stDataList = self.stDataList.concat(data.data.hds.list);
|
|
if (data.data.hds.list.length == 0) {
|
|
self.$refs.stInfinitescroll.$emit('ydui.infinitescroll.loadedDone');
|
|
return;
|
|
} else {
|
|
self.$refs.stInfinitescroll.$emit('ydui.infinitescroll.finishLoad');
|
|
}
|
|
}
|
|
}, "json");
|
|
}, 400);
|
|
},
|
|
onClick(name, title) {
|
|
let self = this;
|
|
self.flag = name;
|
|
if (name == "0") {
|
|
self.clickXhd();
|
|
} else if (name == "1") {
|
|
self.clickFhd();
|
|
} else if (name == "2") {
|
|
self.clickSthd();
|
|
}
|
|
},
|
|
|
|
clickXhd() {
|
|
let self = this;
|
|
self.pageForm.pageNumber = 1;
|
|
$.post("/mobile/hd/hdbm/data", self.pageForm, function (data) {
|
|
if (data.code == 0) {
|
|
self.dataList = data.data.hds.list;
|
|
if (self.dataList.length == 0) {
|
|
self.xShow = true;
|
|
} else {
|
|
self.xShow = false;
|
|
}
|
|
self.$refs.infinitescroll.$emit('ydui.infinitescroll.reInit');
|
|
}
|
|
}, "json");
|
|
},
|
|
clickFhd() {
|
|
let self = this;
|
|
self.fhPageForm.pageNumber = 1;
|
|
$.post("/mobile/hd/hdbm/fhData", self.fhPageForm, function (data) {
|
|
if (data.code == 0) {
|
|
self.fhDataList = data.data.hds.list;
|
|
if (self.fhDataList.length == 0) {
|
|
self.fhShow = true;
|
|
} else {
|
|
self.fhShow = false;
|
|
}
|
|
self.$refs.fhInfinitescroll.$emit('ydui.infinitescroll.reInit');
|
|
}
|
|
}, "json");
|
|
},
|
|
clickSthd() {
|
|
let self = this;
|
|
self.stPageForm.pageNumber = 1;
|
|
$.post("/mobile/hd/hdbm/stData", self.stPageForm, function (data) {
|
|
if (data.code == 0) {
|
|
self.stDataList = data.data.hds.list;
|
|
if (self.stDataList.length == 0) {
|
|
self.stShow = true;
|
|
} else {
|
|
self.stShow = false;
|
|
}
|
|
self.$refs.stInfinitescroll.$emit('ydui.infinitescroll.reInit');
|
|
}
|
|
}, "json");
|
|
},
|
|
|
|
xhdBm(id, hdrs) {
|
|
let self = this;
|
|
$.post("/mobile/hd/hdbm/findXhdBmrs", {hdid: id, hdrs: hdrs}, function (data) {
|
|
if (data.code == 0) {
|
|
|
|
vant.Dialog.confirm({
|
|
title: '温馨提示',
|
|
message: '确认是否要报名此活动吗?',
|
|
}).then(() => {
|
|
$.post("/mobile/hd/hdbm/xhdBm", {
|
|
hdid: id,
|
|
rysfid: "11",
|
|
rylx: "1",
|
|
shzt: "1",
|
|
qxbm: "0"
|
|
}, function (data) {
|
|
if (data.code == 0) {
|
|
let toast = vant.Toast.loading({
|
|
mask: true,
|
|
duration: 0, // 持续展示 toast
|
|
forbidClick: true, // 禁用背景点击
|
|
loadingType: 'spinner',
|
|
message: '报名中...'
|
|
});
|
|
setTimeout(function () {
|
|
toast.message = "报名成功";
|
|
}, 1000);
|
|
setTimeout(function () {
|
|
toast.clear();
|
|
self.clickXhd();
|
|
}, 2000);
|
|
}
|
|
}, "json");
|
|
}).catch(() => {
|
|
// on cancel
|
|
});
|
|
} else if (data.code == 1) {
|
|
vant.Dialog.alert({
|
|
message: '当前活动男队人数名额已满',
|
|
})
|
|
|
|
} else if (data.code == 2) {
|
|
vant.Dialog.alert({
|
|
message: '当前活动女队人数名额已满',
|
|
})
|
|
|
|
} else if (data.code == 3) {
|
|
vant.Dialog.alert({
|
|
message: '当前活动人数名额已满',
|
|
})
|
|
|
|
}
|
|
}, "json");
|
|
},
|
|
qxXhdBm(id) {
|
|
let self = this;
|
|
vant.Dialog.confirm({
|
|
title: '温馨提示',
|
|
message: '您是否要<span style=\'color: red\'>取消</span>此活动的报名?',
|
|
}).then(() => {
|
|
$.post("/mobile/hd/hdbm/qxXhdBm", {hdid: id}, function (data) {
|
|
if (data.code == 0) {
|
|
let toast = vant.Toast.loading({
|
|
mask: true,
|
|
duration: 0, // 持续展示 toast
|
|
forbidClick: true, // 禁用背景点击
|
|
loadingType: 'spinner',
|
|
message: '取消中...'
|
|
});
|
|
setTimeout(function () {
|
|
toast.message = "取消成功";
|
|
}, 1000);
|
|
setTimeout(function () {
|
|
toast.clear();
|
|
self.clickXhd();
|
|
}, 2000);
|
|
}
|
|
}, "json");
|
|
}).catch(() => {
|
|
// on cancel
|
|
});
|
|
},
|
|
fhdBm(id, hdrs) {
|
|
let self = this;
|
|
$.post("/mobile/hd/hdbm/findFhdBmrs", {hdid: id, hdrs: hdrs}, function (data) {
|
|
if (data.code == 0) {
|
|
vant.Dialog.confirm({
|
|
title: '温馨提示',
|
|
message: '确认是否要报名此活动吗?',
|
|
}).then(() => {
|
|
$.post("/mobile/hd/hdbm/fhBm", {hdid: id}, function (data) {
|
|
if (data.code == 0) {
|
|
let toast = vant.Toast.loading({
|
|
mask: true,
|
|
duration: 0, // 持续展示 toast
|
|
forbidClick: true, // 禁用背景点击
|
|
loadingType: 'spinner',
|
|
message: '报名中...'
|
|
});
|
|
setTimeout(function () {
|
|
toast.message = "报名成功";
|
|
}, 1000);
|
|
setTimeout(function () {
|
|
toast.clear();
|
|
self.clickFhd();
|
|
}, 2000);
|
|
}
|
|
}, "json");
|
|
}).catch(() => {
|
|
// on cancel
|
|
});
|
|
} else if (data.code == -1) {
|
|
vant.Dialog.alert({
|
|
message: '此活动人数已满',
|
|
})
|
|
}
|
|
}, "json");
|
|
},
|
|
qxFhBm(id) {
|
|
let self = this;
|
|
vant.Dialog.confirm({
|
|
title: '温馨提示',
|
|
message: "您是否要<span style='color: red'>取消</span>此活动的报名?",
|
|
}).then(() => {
|
|
$.post("/mobile/hd/hdbm/qxFhBm", {hdid: id}, function (data) {
|
|
if (data.code == 0) {
|
|
let toast = vant.Toast.loading({
|
|
mask: true,
|
|
duration: 0, // 持续展示 toast
|
|
forbidClick: true, // 禁用背景点击
|
|
loadingType: 'spinner',
|
|
message: '取消中...'
|
|
});
|
|
setTimeout(function () {
|
|
toast.message = "取消成功";
|
|
}, 1000);
|
|
setTimeout(function () {
|
|
toast.clear();
|
|
self.clickFhd();
|
|
}, 2000);
|
|
}
|
|
}, "json");
|
|
}).catch(() => {
|
|
// on cancel
|
|
});
|
|
},
|
|
sthdBm(id, hdrs) {
|
|
let self = this;
|
|
$.post("/mobile/hd/hdbm/findSthdBmrs", {hdid: id, hdrs: hdrs}, function (data) {
|
|
if (data.code == 0) {
|
|
vant.Dialog.confirm({
|
|
title: '温馨提示',
|
|
message: "确认是否要报名此活动吗?",
|
|
}).then(() => {
|
|
$.post("/mobile/hd/hdbm/sthdBm", {hdid: id}, function (data) {
|
|
if (data.code == 0) {
|
|
let toast = vant.Toast.loading({
|
|
mask: true,
|
|
duration: 0, // 持续展示 toast
|
|
forbidClick: true, // 禁用背景点击
|
|
loadingType: 'spinner',
|
|
message: '报名中...'
|
|
});
|
|
setTimeout(function () {
|
|
toast.message = "报名成功";
|
|
}, 1000);
|
|
setTimeout(function () {
|
|
toast.clear();
|
|
self.clickSthd();
|
|
}, 2000);
|
|
}
|
|
}, "json");
|
|
}).catch(() => {
|
|
// on cancel
|
|
});
|
|
} else if (data.code == -1) {
|
|
vant.Dialog.alert({
|
|
message: '此活动人数已满',
|
|
})
|
|
}
|
|
}, "json");
|
|
},
|
|
qxsthBm(id) {
|
|
let self = this;
|
|
vant.Dialog.confirm({
|
|
title: '温馨提示',
|
|
message: "您是否要<span style='color: red'>取消</span>此活动的报名?",
|
|
}).then(() => {
|
|
$.post("/mobile/hd/hdbm/qxSthdBm", {hdid: id}, function (data) {
|
|
if (data.code == 0) {
|
|
let toast = vant.Toast.loading({
|
|
mask: true,
|
|
duration: 0, // 持续展示 toast
|
|
forbidClick: true, // 禁用背景点击
|
|
loadingType: 'spinner',
|
|
message: '取消中...'
|
|
});
|
|
setTimeout(function () {
|
|
toast.message = "取消成功";
|
|
}, 1000);
|
|
setTimeout(function () {
|
|
toast.clear();
|
|
self.clickSthd();
|
|
}, 2000);
|
|
}
|
|
}, "json");
|
|
}).catch(() => {
|
|
// on cancel
|
|
});
|
|
},
|
|
onRefresh() {
|
|
let self = this;
|
|
setTimeout(function () {
|
|
self.clickXhd();
|
|
self.clickFhd();
|
|
self.clickSthd();
|
|
self.isLoading = false;
|
|
}, 600)
|
|
},
|
|
|
|
viewInfo(id) {
|
|
let self = this;
|
|
location.href = "/platform/wxMobile/wxHdInfo?hdid=" + id + "&flag=" + self.flag;
|
|
}
|
|
},
|
|
created() {
|
|
this.pageData();
|
|
},
|
|
updated() {
|
|
|
|
},
|
|
watch: {},
|
|
|
|
})
|
|
</script>
|
|
<!--#
|
|
}
|
|
#--> |