Commit 98bb75c4 authored by 刘鑫鹏's avatar 刘鑫鹏

Merge remote-tracking branch 'origin/dev' into dev

parents e93ee0a4 05b96b41
...@@ -76,4 +76,14 @@ export function addUnifiedOrder(orderVo) { ...@@ -76,4 +76,14 @@ export function addUnifiedOrder(orderVo) {
method: 'post', method: 'post',
data: orderVo data: orderVo
}) })
}
//微信支付回调下
export function addUnifiedOrderWx(orderVo) {
return request({
url: 'http://bin001.free.idcfengye.com/dealFlow/stream/wxPayNotify',
method: 'post',
data: orderVo
})
} }
\ No newline at end of file
import {
request
} from '../utils/request.js';
// 查询训练体验列表
export function listExercise(query) {
return request({
url: '/system/course/selectCourseList',
method: 'get',
})
}
// 查询热门活动列表
export function listActivityStart(query) {
return request({
url: '/tjt-activity/activity/selectActivityListStart',
method: 'get',
})
}
//有token时调用
// 查询训练体验列表
export function listExerciseHaveToken(query) {
return request({
url: '/system/course/selectCourseListToken',
method: 'get',
})
}
// 查询热门活动列表
export function listActivityStartHaveToken(query) {
return request({
url: '/tjt-activity/activity/selectActivityListStartToken',
method: 'get',
})
}
\ No newline at end of file
{ {
"pages": [{ "pages": [
{
"path" : "pages_home/tjty_home_page/tjty_home_page",
"style": {
"navigationBarTitleText": "天体运动"
}
},
{
"path": "pages/index/index", "path": "pages/index/index",
"style": { "style": {
"navigationBarTitleText": "天体运动" "navigationBarTitleText": "天体运动"
...@@ -17,7 +25,7 @@ ...@@ -17,7 +25,7 @@
"navigationBarTitleText": "天体运动" "navigationBarTitleText": "天体运动"
} }
} }
], ],
"globalStyle": { "globalStyle": {
"navigationBarTextStyle": "black", "navigationBarTextStyle": "black",
"navigationBarTitleText": "天体运动", "navigationBarTitleText": "天体运动",
......
...@@ -220,8 +220,8 @@ ...@@ -220,8 +220,8 @@
.image { .image {
position: absolute; position: absolute;
border-top-left-radius: 15rpx; border-top-left-radius: 30rpx;
border-top-right-radius: 15rpx; border-top-right-radius: 30rpx;
height: 400rpx; height: 400rpx;
width: 100%; width: 100%;
} }
...@@ -230,6 +230,7 @@ ...@@ -230,6 +230,7 @@
// justify-content: end; // justify-content: end;
position: absolute; position: absolute;
padding-left: 86%; padding-left: 86%;
// right: 0.01rpx;
top: 0rpx; top: 0rpx;
width: 98rpx; width: 98rpx;
height: 98rpx; height: 98rpx;
......
...@@ -104,6 +104,8 @@ ...@@ -104,6 +104,8 @@
export default { export default {
data() { data() {
return { return {
//加载一次导航
isGoNavigate: false,
activityId: null, activityId: null,
wechatId: 1, wechatId: 1,
activityObject:{}, activityObject:{},
...@@ -122,6 +124,7 @@ ...@@ -122,6 +124,7 @@
onLoad(options) { onLoad(options) {
console.log('onLoad') console.log('onLoad')
this.activityId =Number.parseInt(options.activity_id) this.activityId =Number.parseInt(options.activity_id)
this.isGoNavigate = true
console.log(this.activityId) console.log(this.activityId)
this.getList(this.activityId) this.getList(this.activityId)
}, },
...@@ -264,39 +267,21 @@ ...@@ -264,39 +267,21 @@
for (var i = 0; i < this.activityObject.tjtActivityProjectVoList.length; i++) { for (var i = 0; i < this.activityObject.tjtActivityProjectVoList.length; i++) {
limitSum = limitSum + this.activityObject.tjtActivityProjectVoList[i].limitPeople limitSum = limitSum + this.activityObject.tjtActivityProjectVoList[i].limitPeople
} }
console.log(signInSum)
console.log(limitSum)
if(signInSum === limitSum) if(signInSum === limitSum)
return uni.$showMsg('报名人数已满1!') return uni.$showMsg('报名人数已满!')
if (this.activityObject.activityStatus === '2') { if (this.activityObject.activityStatus === '2') {
return uni.$showMsg('活动已结束!') return uni.$showMsg('活动已结束!')
} }
// let signupTime = Date.parse(this.activityObject.signupTime)
// console.log('signupTime'+signupTime)
// console.log('now'+Date.parse(new Date))
// if(signupTime <= Date.parse(new Date)){
// return uni.$showMsg('报名已结束!')}
console.log(Date.parse(this.activityObject.signupTime))
console.log(Date.parse(new Date()))
if (Date.parse(this.activityObject.signupTime.replace(/-/g, '/')) < Date.parse(new Date())) { if (Date.parse(this.activityObject.signupTime.replace(/-/g, '/')) < Date.parse(new Date())) {
return wx.showToast({ return uni.$showMsg('报名已结束!')}
title: '报名已结束!',
icon: 'none',
duration: 2000})
}
else{
uni.navigateTo({
url: '/pages_activity/activity_immedSignIn/activity_immedSignIn?activity_id=' + this.activityId
})
}
if(Date.parse(this.activityObject.activityEnd.replace(/-/g, '/'))< new Date()){ if(Date.parse(this.activityObject.activityEnd.replace(/-/g, '/'))< new Date()){
return uni.$showMsg('报名已结束!')} return uni.$showMsg('报名已结束!')}
else{
uni.navigateTo({ uni.navigateTo({
url: '/pages_activity/activity_immedSignIn/activity_immedSignIn?activity_id=' + this.activityId url: '/pages_activity/activity_immedSignIn/activity_immedSignIn?activity_id=' + this.activityId
}) })
} this.isGoNavigate = false
}, },
} }
} }
......
...@@ -59,7 +59,7 @@ import { ...@@ -59,7 +59,7 @@ import {
mapState mapState
} from 'vuex' } from 'vuex'
import { import {
getProjectInfo,addsignInInfo,addUnifiedOrder getProjectInfo,addsignInInfo,addUnifiedOrder,addUnifiedOrderWx
} from "@/api/activity.js"; } from "@/api/activity.js";
export default { export default {
data() { data() {
...@@ -243,12 +243,11 @@ import { ...@@ -243,12 +243,11 @@ import {
if(this.projectFee !== 0){ if(this.projectFee !== 0){
this.info.status = '0' this.info.status = '0'
addsignInInfo(this.info).then(response=>{ addsignInInfo(this.info).then(response=>{
console.log(response) console.log(response) //存在的话就返回报错
if(response.data.status ==='1') if(response.data.code === 500)
return uni.$showMsg(response.msg) return uni.$showMsg(response.msg)
this.orderVo.signupId = response.data.signupId this.orderVo.signupId = response.data.signupId
this.orderVo.wechatId = this.info.wechatId this.orderVo.wechatId = this.info.wechatId
if(response.data.status === '0'){
addUnifiedOrder(this.orderVo).then(response =>{ addUnifiedOrder(this.orderVo).then(response =>{
console.log(response) console.log(response)
uni.requestPayment({ uni.requestPayment({
...@@ -274,7 +273,7 @@ import { ...@@ -274,7 +273,7 @@ import {
} }
}) })
}) })
}
}) })
}else{ }else{
this.info.status = '1' this.info.status = '1'
......
...@@ -86,12 +86,12 @@ ...@@ -86,12 +86,12 @@
/* 主view css */ /* 主view css */
.review-main { .review-main {
width: 660rpx; width: 660rpx;
min-height: 1400rpx; min-height: 1420rpx;
height: auto; height: auto;
background-color: white; background-color: white;
border-radius: 32rpx; border-radius: 32rpx;
margin: 29.5rpx 21rpx 166rpx 21rpx; margin: 29.5rpx 21rpx 32rpx 21rpx;
padding: 40rpx 24rpx 0 24rpx; padding: 40rpx 30rpx 0 30rpx;
} }
.agreement-item-1 { .agreement-item-1 {
...@@ -126,9 +126,4 @@ ...@@ -126,9 +126,4 @@
float: right; float: right;
margin-bottom: 40rpx; margin-bottom: 40rpx;
} }
/* 隐藏滚动条,但依旧具备可以滚动的功能 */
/deep/.uni-scroll-view::-webkit-scrollbar {
display: none
}
</style> </style>
<template> <template>
<view class="review-main"> <view class="review-main">
<rich-text :nodes="agreement"> <rich-text :nodes="agreement">
</rich-text> </rich-text>
</view> </view>
...@@ -67,49 +66,13 @@ ...@@ -67,49 +66,13 @@
/* 主view css */ /* 主view css */
.review-main { .review-main {
width: 660rpx; width: 660rpx;
min-height: 1400rpx; min-height: 1430rpx;
height: auto; height: auto;
background-color: white; background-color: white;
border-radius: 32rpx; border-radius: 32rpx;
margin: 29.5rpx 21rpx 166rpx 21rpx; margin: 30rpx 21rpx 30rpx 21rpx;
padding: 40rpx 24rpx 0 24rpx; padding: 40rpx 24rpx 40rpx 24rpx;
}
.agreement-item-1 {
font-size: 32rpx;
line-height: 44rpx;
color: #333333;
text-align: left;
font-family: 'Source Han Sans CN';
font-weight: regular;
}
.agreement-item {
font-size: 32rpx;
line-height: 44rpx;
color: #333333;
text-align: left;
font-family: 'Source Han Sans CN';
font-weight: regular;
margin-bottom: 40rpx;
} }
.aboutForm-item {
font-size: 32rpx;
line-height: 44rpx;
color: #333333;
text-align: right;
font-family: 'Source Han Sans CN';
font-weight: regular;
}
.aboutForm-view {
float: right;
margin-bottom: 40rpx;
}
/* 隐藏滚动条,但依旧具备可以滚动的功能 */
/deep/.uni-scroll-view::-webkit-scrollbar {
display: none
}
</style> </style>
...@@ -69,7 +69,8 @@ ...@@ -69,7 +69,8 @@
getAreaList, getAreaList,
getPeople, getPeople,
dailyQuestion, dailyQuestion,
selectexamType selectexamType,
selectRegisterList
} from '@/api/dailyAnswer.js' } from '@/api/dailyAnswer.js'
import { import {
getActivity getActivity
...@@ -81,6 +82,7 @@ ...@@ -81,6 +82,7 @@
export default { export default {
data() { data() {
return { return {
registerPeopleNum: 0, //本微信报名人数
examCount: '', //题库试卷判断 examCount: '', //题库试卷判断
idFlag: '', idFlag: '',
color: 'background:#EEEEEE', color: 'background:#EEEEEE',
...@@ -219,20 +221,56 @@ ...@@ -219,20 +221,56 @@
}, },
computed: { computed: {
...mapState('m_user', ['userInfo']) ...mapState('m_user', ['userInfo'])
}, },
onLoad(options) { onLoad(options) {
this.info.activityId = options.activityId this.info.activityId = options.activityId
this.info.wechatId = this.userInfo.wechatId this.info.wechatId = this.userInfo.wechatId
this.getArea() this.getArea()
this.getActivityDetial(options.activityId) this.getActivityDetial(options.activityId)
this.getPerson()
uni.setStorageSync('pages', 'ans_info') uni.setStorageSync('pages', 'ans_info')
}, },
onShow() {
this.getPerson()
this.getRegisterListLength()
},
onHide() {
this.info.areaId = 1
this.getArea()
this.cityIndex = this.cityList.length - 1
this.cityCode = ''
this.info.cityId = ''
this.areaIndex = 16
this.areaDisable = true
this.areaCode = ''
this.info.cityAreaId = ''
this.schoolIndex = -1
this.schoolCode = ''
this.info.schoolId = ''
this.schoolDisable = true
this.info.idFlag = false
this.info.areaId = 1
this.info.parentName = ''
this.info.name = ''
this.info.phone = ''
this.info.idCard = ''
this.info.cityId = ''
this.info.cityAreaId = ''
this.info.schoolId = ''
},
onReady() { onReady() {
this.$refs.form.setRules(this.rules) this.$refs.form.setRules(this.rules)
}, },
methods: { methods: {
//获取报名人数
getRegisterListLength() {
selectRegisterList(this.info.wechatId, this.info.activityId).then(res => {
if (res.code === 200) {
console.log("本微信号报名信息", res);
this.registerPeopleNum = res.data.length
}
})
},
IdChange(e) { IdChange(e) {
// console.log(e); // console.log(e);
let idCareReg = let idCareReg =
...@@ -295,6 +333,29 @@ ...@@ -295,6 +333,29 @@
if (this.info.idFlag) { if (this.info.idFlag) {
return return
} }
if (this.registerPeopleNum === 3) {
return uni.$showMsg('每个答题活动最多只能报名三人!')
this.cityIndex = this.cityList.length - 1
this.cityCode = ''
this.info.cityId = ''
this.areaIndex = 16
this.areaDisable = true
this.areaCode = ''
this.info.cityAreaId = ''
this.schoolIndex = -1
this.schoolCode = ''
this.info.schoolId = ''
this.schoolDisable = true
this.info.idFlag = false
this.info.areaId = 1
this.info.parentName = ''
this.info.name = ''
this.info.phone = ''
this.info.idCard = ''
this.info.cityId = ''
this.info.cityAreaId = ''
this.info.schoolId = ''
}
addTjtActivitySignupExams(this.info).then(res => { addTjtActivitySignupExams(this.info).then(res => {
console.log(res); console.log(res);
if (res >= 0 && res !== '') { if (res >= 0 && res !== '') {
...@@ -311,9 +372,9 @@ ...@@ -311,9 +372,9 @@
dailyQuestion(res, time).then(res1 => { dailyQuestion(res, time).then(res1 => {
console.log("试卷", res1); console.log("试卷", res1);
if (res1.data.length > 0) { if (res1.data.length > 0) {
if(this.examCount === 0){ if (this.examCount === 0) {
return uni.$showMsg('报名成功,暂无试卷!') return uni.$showMsg('报名成功,暂无试卷!')
}else{ } else {
uni.showToast({ uni.showToast({
title: '报名成功!', title: '报名成功!',
icon: 'none' icon: 'none'
...@@ -339,6 +400,7 @@ ...@@ -339,6 +400,7 @@
}).catch(err => { }).catch(err => {
this.info.idFlag = this.idFlag this.info.idFlag = this.idFlag
console.log(this.info.idFlag); console.log(this.info.idFlag);
this.getPerson()
console.log('表单错误信息:', err); console.log('表单错误信息:', err);
}) })
}, },
......
This diff is collapsed.
...@@ -167,7 +167,7 @@ ...@@ -167,7 +167,7 @@
this.updateToken('') this.updateToken('')
this.updateUserInfo('') this.updateUserInfo('')
uni.navigateTo({ uni.navigateTo({
url: '/pages/index/index' url: '/pages_home/tjty_home_page/tjty_home_page'
}) })
}, },
......
<template> <template>
<view> <view>
<noData v-if="flag == 0"></noData> <noData v-if="flag == 0"></noData>
<uni-card class="newMedia-card-main" v-if="flag == 1"> <view class="newMedia-card-main" v-if="flag == 1">
<text class="title-text">{{!issue.titleName ? '--' : issue.titleName}}</text> <text class="title-text">{{!issue.titleName ? '--' : issue.titleName}}</text>
<view class="message-view"> <view class="message-view">
<text style="color: #3B7CDE">{{!issueBranch ? "--" : issueBranch}}</text> <text style="color: #3B7CDE">{{!issueBranch ? "--" : issueBranch}}</text>
...@@ -12,11 +12,11 @@ ...@@ -12,11 +12,11 @@
<!-- <view v-for="item in listImg"> <!-- <view v-for="item in listImg">
<image :src="base_url + item" :webp="true"></image> <image :src="base_url + item" :webp="true"></image>
</view> --> </view> -->
<view style="width: 650rpx;"> <!-- <view style="width: 630rpx;"> -->
<rich-text :nodes="issue.detail"></rich-text> <rich-text :nodes="issue.detail"></rich-text>
</view> <!-- </view> -->
</view> </view>
</uni-card> </view>
<view class="newMedia-button-view"> <view class="newMedia-button-view">
<button style="background-color: #3B7CDE; margin-left: 40rpx;" class="newMedia-button" <button style="background-color: #3B7CDE; margin-left: 40rpx;" class="newMedia-button"
@click="goPhoneBtn(phoneNumber)">咨询电话</button> @click="goPhoneBtn(phoneNumber)">咨询电话</button>
...@@ -46,8 +46,8 @@ ...@@ -46,8 +46,8 @@
phoneNumber: '188222333444', phoneNumber: '188222333444',
issue: {}, issue: {},
listImg: [], listImg: [],
address:'天津', address: '天津',
detail:'', detail: '',
pushTime: '', pushTime: '',
base_url: 'https://www.aiwanyundong.com/api', base_url: 'https://www.aiwanyundong.com/api',
// base_url: 'http://192.168.0.97:8080', // base_url: 'http://192.168.0.97:8080',
...@@ -100,7 +100,7 @@ ...@@ -100,7 +100,7 @@
}, },
messageConsult(e) { messageConsult(e) {
uni.navigateTo({ uni.navigateTo({
url: '/pages_new_media/tity_message_consult/tity_message_consult?consultType=' + '0' url: '/pages_new_media/tity_message_consult/tity_message_consult?consultType=' + 0
}) })
}, },
...@@ -117,14 +117,15 @@ ...@@ -117,14 +117,15 @@
// if(this.issue.pushTime){ // if(this.issue.pushTime){
// this.pushTime = this.issue.pushTime.substring(0, 16).replace('T', ' ') // this.pushTime = this.issue.pushTime.substring(0, 16).replace('T', ' ')
// } // }
if(this.issue.updateTime){ if (this.issue.updateTime) {
this.pushTime = this.issue.updateTime.substring(0, 16).replace('T', ' ') this.pushTime = this.issue.updateTime.substring(0, 16).replace('T', ' ')
if(this.issue.address){ if (this.issue.address) {
this.address = this.issue.address this.address = this.issue.address
}} }
var reg = new RegExp('<body*>','gi') }
var reg1 = new RegExp('</body*>','gi') var reg = new RegExp('<body*>', 'gi')
var reg1 = new RegExp('</body*>', 'gi')
this.issue.detail = this.issue.detail.replace(reg, '') this.issue.detail = this.issue.detail.replace(reg, '')
this.issue.detail = this.issue.detail.replace(reg1, '') this.issue.detail = this.issue.detail.replace(reg1, '')
console.log("处理后的内容--->", this.issue.detail) console.log("处理后的内容--->", this.issue.detail)
...@@ -163,18 +164,31 @@ ...@@ -163,18 +164,31 @@
</script> </script>
<style scoped> <style scoped>
/*
/deep/.uni-card { /deep/.uni-card {
display: flex; display: flex;
/* margin-top: -20rpx; */ margin-top: -20rpx;
margin: 10.5rpx; margin: 10.5rpx;
border-radius: 32rpx 32rpx 0 0; border-radius: 32rpx 32rpx 0 0;
min-height: 1330rpx; min-height: 1330rpx;
height: auto; height: auto;
width: 670rpx; width: 670rpx;
margin-bottom: 166px; margin-bottom: 166px;
transform: translateX(-12rpx); transform: translateX(-12rpx);
} }
*/
.newMedia-card-main{
background-color: #fff;
margin: 30rpx 20rpx 0 20rpx;
padding: 35rpx 30rpx 30rpx 30rpx;
border-radius: 32rpx 32rpx 0 0;
/* min-height: 1330rpx; */
height: auto;
/* width: 670rpx; */
margin-bottom: 170rpx;
}
.newMedia-button-view { .newMedia-button-view {
display: flex; display: flex;
/* margin-bottom: 50rpx; */ /* margin-bottom: 50rpx; */
...@@ -196,10 +210,9 @@ ...@@ -196,10 +210,9 @@
} }
.button-hover { .button-hover {
background-color: rgba(144, 238, 144, 0.5);
background-color: rgba(144, 238, 144, 0.5); opacity: 0.7;
opacity: 0.7;
} }
/* 标题css */ /* 标题css */
...@@ -221,13 +234,9 @@ ...@@ -221,13 +234,9 @@
/* 正文样式 */ /* 正文样式 */
.content-view { .content-view {
margin-bottom: 150rpx; margin-top: 30rpx;
margin-right: 20rpx; /* margin-bottom: 120rpx; */
/* margin-right: 20rpx; */
}
/* 隐藏滚动条,但依旧具备可以滚动的功能 */
/deep/.uni-scroll-view::-webkit-scrollbar {
display: none
} }
</style> </style>
...@@ -15,11 +15,9 @@ ...@@ -15,11 +15,9 @@
</view> </view>
<noData v-if="!customerListLength" :style="fullHeight"></noData> <noData v-if="!customerListLength" :style="fullHeight"></noData>
<!-- 选项卡内容轮播滑动显示,current为当前第几个swiper子项 --> <!-- 选项卡内容轮播滑动显示,current为当前第几个swiper子项 -->
<!-- <swiper @change="change" :current="isActive" class="swiper-content" :style="fullHeight" <swiper @change="change" :current="isActive" class="swiper-content" :style="fullHeight"
v-if="customerList.length !== 0"> v-if="customerList.length !== 0">
<swiper-item class="swiperitem-content"> --> <swiper-item class="swiperitem-content" @touchmove.stop="stopTouchMove">
<view class="swiper-content" :style="fullHeight" v-if="customerList.length !== 0">
<view class="swiperitem-content">
<scroll-view scroll-y style="height: 100%;" @scrolltolower="lowerBottom" lower-threshold="150px" <scroll-view scroll-y style="height: 100%;" @scrolltolower="lowerBottom" lower-threshold="150px"
refresher-enabled="true" @refresherrefresh="refresh" :refresher-triggered="triggered"> refresher-enabled="true" @refresherrefresh="refresh" :refresher-triggered="triggered">
<view class="nav_item"> <view class="nav_item">
...@@ -34,11 +32,8 @@ ...@@ -34,11 +32,8 @@
</view> </view>
</view> </view>
</scroll-view> </scroll-view>
</view> </swiper-item>
</view> </swiper>
<!-- </swiper-item>
</swiper> -->
<view class="nav_item_bottom"> <view class="nav_item_bottom">
<button style="background-color:#3b7cde; color:white;" @click="goPhoneBtn(phoneNumber)">咨询电话</button> <button style="background-color:#3b7cde; color:white;" @click="goPhoneBtn(phoneNumber)">咨询电话</button>
<button type="primary" @click="gotoMessageConsult">留言咨询</button> <button type="primary" @click="gotoMessageConsult">留言咨询</button>
...@@ -158,6 +153,10 @@ ...@@ -158,6 +153,10 @@
} }
}); });
}, },
//限制页面左右滑动
stopTouchMove() {
return true
},
//留言咨询 //留言咨询
gotoMessageConsult() { gotoMessageConsult() {
console.log("准备进入到留言咨询。。。。") console.log("准备进入到留言咨询。。。。")
...@@ -357,7 +356,7 @@ ...@@ -357,7 +356,7 @@
min-height: calc(100% - 10%); min-height: calc(100% - 10%);
padding: 5rpx; padding: 5rpx;
height: auto; height: auto;
padding-bottom: 20%; padding-bottom: 35%;
.customer-item { .customer-item {
margin: 20rpx 5%; margin: 20rpx 5%;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment