(1)小程序需要和青年户外协会关联,做一个banner放在小程序第一个。banner内容是邀请/推广的。 (2)点击banner,跳出协会入会申请页面
This commit is contained in:
parent
ef61da5979
commit
30d0ce01b1
@ -24,9 +24,8 @@
|
|||||||
<view class="swiper-box">
|
<view class="swiper-box">
|
||||||
<!-- <MySwiper :list="swiperList"></MySwiper> -->
|
<!-- <MySwiper :list="swiperList"></MySwiper> -->
|
||||||
<view class="swiper_s">
|
<view class="swiper_s">
|
||||||
<swiper class="swiper_s" :autoplay="true" indicator-active-color="#0DAE11"
|
<swiper class="swiper_s" :autoplay="true" indicator-active-color="#0DAE11" indicator-color="#ffffff"
|
||||||
indicator-color="#ffffff" :indicator-dots="false" :current="swiperCurrent"
|
:indicator-dots="false" :current="swiperCurrent" @change="swiperChange">
|
||||||
@change="swiperChange">
|
|
||||||
<swiper-item v-for="(item, index) in swiperList" :key="index" @click="openSwiper(item)">
|
<swiper-item v-for="(item, index) in swiperList" :key="index" @click="openSwiper(item)">
|
||||||
<view style="position: relative;width: 100%;height: 100%">
|
<view style="position: relative;width: 100%;height: 100%">
|
||||||
<view class="fnon_tit"></view>
|
<view class="fnon_tit"></view>
|
||||||
@ -191,6 +190,74 @@
|
|||||||
</view>
|
</view>
|
||||||
<u-loadmore v-else style="margin-bottom: 60rpx;" :status="loadStatus" />
|
<u-loadmore v-else style="margin-bottom: 60rpx;" :status="loadStatus" />
|
||||||
</view>
|
</view>
|
||||||
|
<u-popup @touchmove.native.stop.prevent :show="formShow" :round="10">
|
||||||
|
<view style="display: flex;align-items: center;justify-content: space-between;padding: 32rpx;">
|
||||||
|
<view style="display: flex;align-items: center;">
|
||||||
|
<view>
|
||||||
|
<view style="height: 35rpx;width: 6rpx;background-color: #BBFC5B;"></view>
|
||||||
|
</view>
|
||||||
|
<view
|
||||||
|
style="font-size: 32rpx;color: #3D3D3D;font-weight: 600;margin-left: 20rpx;font-family: PingFang SC, PingFang SC;">
|
||||||
|
会员招募信息
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<view @click="formShow = false" style="font-family: PingFang SC, PingFang SC;font-size: 32rpx;">关闭
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<view style="width: 100%;height: 1px;background-color: #D8D8D8;"></view>
|
||||||
|
<view style="padding:30rpx 30rpx;">
|
||||||
|
<view style="display: flex;align-items: center;justify-content: space-between;">
|
||||||
|
<view style="color: #3D3D3D;font-weight: 300;font-family: PingFang SC, PingFang SC;">
|
||||||
|
联系人
|
||||||
|
</view>
|
||||||
|
<view>
|
||||||
|
<input type="text" placeholder="请填写" class="input" v-model="formData.name"
|
||||||
|
placeholder-class="plasty" />
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<view class="line-row"></view>
|
||||||
|
<view style="display: flex;align-items: center;justify-content: space-between;">
|
||||||
|
<view style="color: #3D3D3D;font-weight: 300;font-family: PingFang SC, PingFang SC;">
|
||||||
|
联系电话
|
||||||
|
</view>
|
||||||
|
<view>
|
||||||
|
<input type="text" placeholder="请填写" class="input" v-model="formData.mobile"
|
||||||
|
placeholder-class="plasty" />
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<view class="line-row"></view>
|
||||||
|
<view style="display: flex;align-items: center;justify-content: space-between;">
|
||||||
|
<view style="color: #3D3D3D;font-weight: 300;font-family: PingFang SC, PingFang SC;">
|
||||||
|
企业名称
|
||||||
|
</view>
|
||||||
|
<view>
|
||||||
|
<input type="text" placeholder="请填写" class="input" v-model="formData.enterprise_name"
|
||||||
|
placeholder-class="plasty" />
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<view class="line-row"></view>
|
||||||
|
<view style="display: flex;align-items: center;justify-content: space-between;">
|
||||||
|
<view style="color: #3D3D3D;font-weight: 300;font-family: PingFang SC, PingFang SC;">
|
||||||
|
企业地址
|
||||||
|
</view>
|
||||||
|
<view>
|
||||||
|
<input type="text" placeholder="请填写" class="input" v-model="formData.enterprise_addr"
|
||||||
|
placeholder-class="plasty" />
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<view class="line-row"></view>
|
||||||
|
<view style="display: flex;align-items: center;justify-content: space-between;">
|
||||||
|
<view style="color: #3D3D3D;font-weight: 300;font-family: PingFang SC, PingFang SC;">
|
||||||
|
经营/热爱的户外运动
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<view class="textarea_mph" style="margin-top: 30rpx;">
|
||||||
|
<u--textarea maxlength="400" placeholder-class="bttops" v-model="formData.outdoor_sport"
|
||||||
|
placeholder="请输入您经营热爱的户外运动"></u--textarea>
|
||||||
|
</view>
|
||||||
|
<view class="btn_1" @click="submitDo()">确认提交</view>
|
||||||
|
</view>
|
||||||
|
</u-popup>
|
||||||
<tab-bar :tabBarShow="0"></tab-bar>
|
<tab-bar :tabBarShow="0"></tab-bar>
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
@ -237,7 +304,15 @@
|
|||||||
],
|
],
|
||||||
limit: 6,
|
limit: 6,
|
||||||
page: 1,
|
page: 1,
|
||||||
show: false
|
show: false,
|
||||||
|
formShow: false,
|
||||||
|
formData: {
|
||||||
|
name: '',
|
||||||
|
mobile: '',
|
||||||
|
enterprise_name: '',
|
||||||
|
enterprise_addr: '',
|
||||||
|
outdoor_sport: '',
|
||||||
|
}
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
onLoad() {
|
onLoad() {
|
||||||
@ -253,7 +328,7 @@
|
|||||||
this.videoContext = uni.createVideoContext("myVideo"); //创建视频实例指向video
|
this.videoContext = uni.createVideoContext("myVideo"); //创建视频实例指向video
|
||||||
},
|
},
|
||||||
onShow() {
|
onShow() {
|
||||||
|
|
||||||
},
|
},
|
||||||
beforeDestroy() {
|
beforeDestroy() {
|
||||||
this.autoplay = false;
|
this.autoplay = false;
|
||||||
@ -264,16 +339,124 @@
|
|||||||
// }
|
// }
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
openSwiper(item){
|
|
||||||
console.log(item);
|
|
||||||
if(item.url=='xxx'){
|
submitDo() {
|
||||||
|
const token = uni.getStorageSync('token');
|
||||||
|
if (!token) {
|
||||||
uni.showToast({
|
uni.showToast({
|
||||||
title: '入会申请表单',
|
title: '请登录',
|
||||||
icon: 'none',
|
icon: 'none',
|
||||||
|
duration: 2000,
|
||||||
|
complete: function() {
|
||||||
|
setTimeout(function() {
|
||||||
|
uni.switchTab({
|
||||||
|
url: '/pages/my/index',
|
||||||
|
});
|
||||||
|
}, 2000);
|
||||||
|
}
|
||||||
});
|
});
|
||||||
}else{
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (this.formData.name == '') {
|
||||||
|
uni.showToast({
|
||||||
|
title: '请填写联系人!',
|
||||||
|
icon: "none",
|
||||||
|
duration: 2000,
|
||||||
|
});
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if (this.formData.mobile == '') {
|
||||||
|
uni.showToast({
|
||||||
|
title: '请填写联系电话!',
|
||||||
|
icon: "none",
|
||||||
|
duration: 2000,
|
||||||
|
});
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if (this.formData.enterprise_name == '') {
|
||||||
|
uni.showToast({
|
||||||
|
title: '请填写企业名称!',
|
||||||
|
icon: "none",
|
||||||
|
duration: 2000,
|
||||||
|
});
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if (this.formData.enterprise_addr == '') {
|
||||||
|
uni.showToast({
|
||||||
|
title: '请填写企业地址!',
|
||||||
|
icon: "none",
|
||||||
|
duration: 2000,
|
||||||
|
});
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if (this.formData.outdoor_sport == '') {
|
||||||
|
uni.showToast({
|
||||||
|
title: '请填写经营/热爱的户外运动!',
|
||||||
|
icon: "none",
|
||||||
|
duration: 2000,
|
||||||
|
});
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
uni.$u.http
|
||||||
|
.post("/api/school.spor_apply/add", this.formData)
|
||||||
|
.then((res) => {
|
||||||
|
console.log(res);
|
||||||
|
if (res.code == 1) {
|
||||||
|
uni.showToast({
|
||||||
|
title: '提交成功!',
|
||||||
|
icon: "none",
|
||||||
|
duration: 2000,
|
||||||
|
});
|
||||||
|
this.formShow = false;
|
||||||
|
this.formData = {
|
||||||
|
name: '',
|
||||||
|
mobile: '',
|
||||||
|
enterprise_name: '',
|
||||||
|
enterprise_addr: '',
|
||||||
|
outdoor_sport: '',
|
||||||
|
};
|
||||||
|
} else {
|
||||||
|
uni.showToast({
|
||||||
|
title: res.msg,
|
||||||
|
icon: "none",
|
||||||
|
duration: 2000,
|
||||||
|
});
|
||||||
|
}
|
||||||
|
})
|
||||||
|
.catch((error) => {
|
||||||
|
uni.showToast({
|
||||||
|
title: "请求失败,请稍后再试",
|
||||||
|
icon: "none",
|
||||||
|
duration: 2000,
|
||||||
|
});
|
||||||
|
});
|
||||||
|
},
|
||||||
|
openSwiper(item) {
|
||||||
|
console.log(item);
|
||||||
|
if (item.url == 'outdoor_sport_apply') {
|
||||||
|
const token = uni.getStorageSync('token');
|
||||||
|
if (!token) {
|
||||||
|
uni.showToast({
|
||||||
|
title: '请登录',
|
||||||
|
icon: 'none',
|
||||||
|
duration: 2000,
|
||||||
|
complete: function() {
|
||||||
|
setTimeout(function() {
|
||||||
|
uni.switchTab({
|
||||||
|
url: '/pages/my/index',
|
||||||
|
});
|
||||||
|
}, 2000);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
return;
|
||||||
|
} else {
|
||||||
|
this.formShow = true;
|
||||||
|
}
|
||||||
|
} else {
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url:item.url
|
url: item.url
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
@ -1244,7 +1427,7 @@
|
|||||||
text-align: center;
|
text-align: center;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
bottom: 70rpx;
|
bottom: 70rpx;
|
||||||
transform: translateZ(0);
|
transform: translateZ(0);
|
||||||
}
|
}
|
||||||
|
|
||||||
.fnon_tit {
|
.fnon_tit {
|
||||||
@ -1296,4 +1479,51 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.line-row {
|
||||||
|
margin: 40rpx 0rpx;
|
||||||
|
height: 1rpx;
|
||||||
|
width: 100%;
|
||||||
|
background: #F0F0F0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.input {
|
||||||
|
text-align: right;
|
||||||
|
font-family: PingFang SC, PingFang SC;
|
||||||
|
font-size: 26rpx;
|
||||||
|
color: #343434;
|
||||||
|
line-height: 32rpx;
|
||||||
|
}
|
||||||
|
|
||||||
|
.plasty {
|
||||||
|
color: #999999;
|
||||||
|
font-weight: 300;
|
||||||
|
font-size: 28rpx;
|
||||||
|
}
|
||||||
|
|
||||||
|
.textarea_mph {
|
||||||
|
::v-deep .u-textarea {
|
||||||
|
height: 237rpx;
|
||||||
|
padding: 20rpx;
|
||||||
|
border: none;
|
||||||
|
font-size: 26rpx;
|
||||||
|
color: #9C9C9C;
|
||||||
|
background-color: #F8F8F8 !important;
|
||||||
|
border-radius: 18rpx;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.btn_1 {
|
||||||
|
width: 100%;
|
||||||
|
height: 90rpx;
|
||||||
|
background: #323232;
|
||||||
|
border-radius: 198rpx 198rpx 198rpx 198rpx;
|
||||||
|
font-family: YouSheBiaoTiHei, YouSheBiaoTiHei;
|
||||||
|
font-weight: 400;
|
||||||
|
font-size: 32rpx;
|
||||||
|
color: #BBFC5B;
|
||||||
|
line-height: 90rpx;
|
||||||
|
text-align: center;
|
||||||
|
margin-top: 50rpx;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
Loading…
x
Reference in New Issue
Block a user