作者 lihongjuan

云产

正在显示 66 个修改的文件 包含 4709 行增加0 行删除

要显示太多修改。

为保证性能只显示 66 of 66+ 个文件。

/.idea
... ...
App({
onLaunch: function() {
// 展示本地存储能力
var logs = wx.getStorageSync('logs') || []
},
post: function(url, data) {
/**
* 自定义post函数,返回Promise
* +-------------------
* @param {String} url 接口网址
* @param {arrayObject} data 要传的数组对象 like: {name: 'name', age: 32}
* +-------------------
* @return {Promise} promise 返回promise供后续操作
*/
// wx.showLoading({
// title: '加载中',
// })
wx.showNavigationBarLoading()
// wx.showLoading({
// title: '加载中',
// })
var promise = new Promise((resolve, reject) => {
//init
let that = this;
let postData = data;
//let baseUrl = 'http://192.168.1.7/maternity/public';
//let baseUrl ='http://maternity.w.bronet.cn';
let baseUrl = 'https://ibaby88.cn/';
// postData.signature = that.makeSign(postData);
//网络请求
wx.request({
url: baseUrl + url,
data: postData,
method: 'POST',
header: {
'content-type': 'application/x-www-form-urlencoded'
},
success: function(res) { //返回取得的数据
if (res.data.code == '1') {
resolve(res.data.data);
} else if (res.data.code == '20001') { //返回错误提示信息
wx.showModal({
title: '提示',
content: res.data.msg,
success: function(res) {
if (res.confirm) {
wx.removeStorageSync('token');
wx.navigateTo({
// url: '/pages/startRecord/startRecord',
})
}
}
})
} else if (res.data.code == '40001') { //返回错误提示信息
wx.showModal({
title: '提示',
content: '登录已过期请重新登录!',
showCancel: false,
success: function(res) {
if (res.confirm) {
wx.removeStorageSync('token');
wx.navigateTo({
// url: '/pages/startRecord/startRecord',
})
}
}
})
} else if (res.data.code == '40000') {
wx.showModal({
title: '提示',
content: res.data.msg,
showCancel: false,
success: function(res) {}
})
} else if (res.data.code == '44002') {
// 初始化用户信息判断
let usetrInfoType = {
hasUserInfo: false
}
resolve(usetrInfoType);
// wx.showModal({
// title: '提示',
// content: res.data.msg,
// showCancel: false
// })
} else if (res.data.code == '0') {
console.log(888)
// wx.showModal({
// title: '提示',
// content: res.data.msg,
// showCancel: false
// })
// reject(res.data)
wx.showToast({
title: res.data.message,
icon: 'none'
})
wx.showToast({
title: res.data.msg,
icon: 'none'
})
} else {
reject(res)
}
setTimeout(function() {
wx.hideLoading()
wx.hideNavigationBarLoading()
}, 600)
},
fail: function(e) {
reject('网络出错');
// wx.hideLoading()
wx.hideNavigationBarLoading()
}
})
});
return promise;
},
formCollect(id) {
let url = '/sign/formid'
let params = {
formid: id,
openid: wx.getStorageSync('openId')
}
this.post(url, params).then((res) => {
console.log(res)
}).catch((errMsg) => {
})
},
nowDate() {
let date = new Date();
let month = date.getMonth() + 1;
let day = date.getDate();
return date.getFullYear() + '年' + (month > 9 ? month : ('0' + month)) + '月' + (day > 9 ? day : ('0' + day)) + '日';
},
initDate(a) {
let date1 = new Date();
let time1 = date1.getFullYear() + "年" + (date1.getMonth() + 1) + "月" + date1.getDate() + '日';
let date2 = new Date(date1);
date2.setDate(date1.getDate() + a);
let time2 = date2.getFullYear() + "年" + (date2.getMonth() + 1) + "月" + date2.getDate() + '日';
return time2;
},
// 数组移除指定元素
arryRemove(arr, item) {
return arr.filter(function(ele) {
return ele != item;
})
},
strTime(strtime) {
let str = 'bronet' + strtime + 'beijing'
return md5(md5(str))
},
globalData: {
userInfo: null,
baseUrl: 'http://beijing.w.bronet.cn'
},
// getPermission: function (obj) {
// wx.chooseLocation({
// success: function (res) {
// obj.setData({
// addr: res.address //调用成功直接设置地址
// })
// },
// fail: function () {
// wx.getSetting({
// success: function (res) {
// var statu = res.authSetting;
// if (!statu['scope.userLocation']) {
// wx.showModal({
// title: '是否授权当前位置',
// content: '需要获取您的地理位置,请确认授权,否则地图功能将无法使用',
// success: function (tip) {
// if (tip.confirm) {
// wx.openSetting({
// success: function (data) {
// if (data.authSetting["scope.userLocation"] === true) {
// wx.showToast({
// title: '授权成功',
// icon: 'success',
// duration: 1000
// })
// //授权成功之后,再调用chooseLocation选择地方
// wx.getLocation({
// type: 'wgs84',
// success: function (res) {
// console.log(res)
// var latitude = res.latitude
// var longitude = res.longitude
// that.setData({
// wd: latitude,
// jd: longitude
// })
// that.gethostipallist()
// }
// })
// } else {
// wx.showToast({
// title: '授权失败',
// icon: 'success',
// duration: 1000
// })
// }
// }
// })
// }
// }
// })
// }
// },
// fail: function (res) {
// wx.showToast({
// title: '调用授权窗口失败',
// icon: 'success',
// duration: 1000
// })
// }
// })
// }
// })
// },
})
\ No newline at end of file
... ...
{
"pages": [
"pages/homepage/homepage",
"pages/index/index",
"pages/home/stageofpregnancy/stageofpregnancy",
"pages/home/searchpage/searchpage",
"pages/person/faveritehospital/faveritehostipal",
"pages/processQuery/processQuery",
"pages/person/myCourseDetail/myCourseDetail",
"pages/home/sweepcoupon/sweepcoupon",
"pages/home/coupon/coupon",
"pages/person/myCoupon/myCoupon",
"pages/home/commentdoctor/commentdoctor",
"pages/home/communithostipal/communithostipal",
"pages/home/buildtextdetail/buildtextdetail",
"pages/active/active",
"pages/logs/logs",
"pages/home/commentdoctordetail/commentdoctordetail",
"pages/home/commenthospitaldetail/commenthospitaldetail",
"pages/home/mouthreview/mouthreview",
"pages/home/attentionpublic/attentionpublic",
"pages/home/mecomment/mecomment",
"pages/home/used/used",
"pages/home/mypublish/mypublish",
"pages/home/sellidel/sellidel",
"pages/partneritem/afterchildbirthrecover/afterchildbirthrecover",
"pages/partneritem/afterchildbirth/afterchildbirth",
"pages/partneritem/sureorder/sureorder",
"pages/partner/partner",
"pages/home/goodtail/goodtail",
"pages/home/hometail/hometail",
"pages/home/usedkind/usedkind",
"pages/home/havechildren/havechildren",
"pages/home/nochildren/nochildren",
"pages/home/buildtext/buildtext",
"pages/home/childbirthnotedetail/childbirthnotedetail",
"pages/home/childbirthnote/childbirthnote",
"pages/home/melist/melist",
"pages/home/meshare/meshare",
"pages/home/doctortail/doctortail",
"pages/knowledge/knowledge",
"pages/knowDetail/knowDetail",
"pages/personcenter/personcenter",
"pages/person/myCourse/myCourse",
"pages/person/myOrder/myOrder",
"pages/person/myOrderDetail/myOrderDetail",
"pages/person/myReport/myReport",
"pages/person/myNotes/myNotes",
"pages/person/myComment/myComment",
"pages/cityWide/monthClub/monthClub",
"pages/cityWide/monthDetail/monthDetail",
"pages/cityWide/activityName/activityName",
"pages/cityWide/remark/remark",
"pages/cityWide/nameList/nameList",
"pages/cityWide/matronPrepon/matronPrepon",
"pages/cityWide/keyFind/keyFind",
"pages/cityWide/matronDetail/matronDetail",
"pages/cityWide/diatelyMake/diatelyMake",
"pages/cityWide/matronStrategy/matronStrategy",
"pages/cityWide/WeChatCulum/WeChatCulum",
"pages/sharepage/sharepage"
],
"permission": {
"scope.userLocation": {
"desc": "你的位置信息将用于小程序位置接口的效果展示"
}
},
"window": {
"backgroundTextStyle": "dark",
"navigationBarBackgroundColor": "#FD8779",
"navigationBarTitleText": "附近产科医院",
"navigationBarTextStyle": "white"
},
"tabBar": {
"selectedColor": "#FC7E65",
"list": [
{
"pagePath": "pages/homepage/homepage",
"text": "附近医院",
"selectedColor": "#FC7E65",
"iconPath": "img/nav01@2x.png",
"selectedIconPath": "img/nav02@2x.png"
},
{
"pagePath": "pages/partner/partner",
"text": "微商城",
"selectedColor": "#FC7E65",
"iconPath": "img/nav03@2x.png",
"selectedIconPath": "img/nav04@2x.png"
},
{
"pagePath": "pages/knowledge/knowledge",
"text": "知识库",
"selectedColor": "#FC7E65",
"iconPath": "img/nav05@2x.png",
"selectedIconPath": "img/nav06@2x.png"
},
{
"pagePath": "pages/active/active",
"text": "同域活动",
"selectedColor": "#FC7E65",
"iconPath": "img/nav07@2x.png",
"selectedIconPath": "img/nav08@2x.png"
},
{
"pagePath": "pages/personcenter/personcenter",
"text": "个人中心",
"selectedColor": "#FC7E65",
"iconPath": "img/nav09@2x.png",
"selectedIconPath": "img/nav10@2x.png"
}
]
},
"sitemapLocation": "sitemap.json"
}
\ No newline at end of file
... ...
/* 首页的下三角 */
.place_img{
width:10rpx;
height:10rpx;
font-size: 0;
margin-left: 10rpx;
margin-top: 13rpx;
}
.place_img image{
width:100%;
height:100%;
}
.lj_row{
width:40rpx;
height:40rpx;
font-size: 0
}
.lj_row image{
width:100%;
height:100%;
}
/* 首页进详情里的按钮 */
.lj_comment{
width:310rpx;
height:80rpx;
border-radius: 40rpx;
background: #FD8779;
color:#fff;
font-size: 30rpx;
margin: 17rpx auto;
border:none;
outline:none;
}
.footbtn{
width:750rpx;
background: #fff;
height:110rpx;
position:fixed;
bottom:0rpx;
}
.lj_mecomment{
width:686rpx;
height:80rpx;
border-radius:40rpx;
color:#fff;
font-size: 30rpx;
text-align: center;
line-height: 80rpx;
background: #FD8779;
position:fixed;
bottom:31rpx;
left:0;
right:0;
margin: 0 auto;
}
/* 口碑详情提交 */
.lj_sub{
width:686rpx;
height:80rpx;
border-radius: 40rpx;
background: #FD8779;
color:#fff;
font-size: 30rpx;
text-align: center;
position:fixed;
bottom:31rpx;
left:0;
right:0;
margin: 0 auto;
}
.nodata{
color:#999;
font-size: 30rpx;
text-align: center;
margin-top: 32rpx;
}
.searchfuwu{
width:310rpx;
height:80rpx;
background:rgba(253,135,121,1);
border-radius:40rpx;
color:#fff;
text-align: center;
line-height: 80rpx;
position: absolute;
bottom:32rpx;
left:0;
right:0;
margin:0 auto
}
\ No newline at end of file
... ...
/* 公共表单 */
.commentlist-doctor{
display:flex;
height:100rpx;
justify-content: space-between;
align-items: center;
padding:0 32rpx;
border-bottom:16rpx solid #FCF8F7;
}
.commentlist{
border-bottom:16rpx solid #FCF8F7;
}
.commentlist_item{
display:flex;
height:100rpx;
justify-content: space-between;
align-items: center;
padding:0 32rpx;
border-bottom:1rpx solid #f5f5f5;
}
.commentlist_name{
color:#000000;
font-size: 30rpx;
}
.commentlist_right{
display:flex;
}
.commentlsit_date{
color:#666666;
font-size: 26rpx;
}
.row{
width:40rpx;
height:40rpx;
font-size: 0;
margin-left: 5rpx;
}
.row image{
width:100%;
height:100%;
}
.doctor_review{
display:flex;
justify-content: space-between;
align-items: center;
height:80rpx;
border-bottom:1rpx solid #f5f5f5;
padding: 0 40rpx 0 32rpx;
}
.doctor_review_name{
color:#292525;
font-size: 26rpx;
font-weight: bold;
}
.sub_review{
color:#5C5453;
font-size:26rpx;
}
/* 输入评论*/
.entercomment{
width:682rpx;
height:300rpx;
margin: 0 auto;
color:#CCBAB8;
font-size: 28rpx;
padding: 28rpx 0;
}
.entertext{
width:682rpx;
height:300rpx;
line-height: 1.5;
}
.choseimg{
overflow: hidden;
padding: 0 20rpx 130rpx 12rpx;
}
.selectpic{
float:left;
width:160rpx;
height:160rpx;
font-size: 0;
margin-left:20rpx;
margin-top: 20rpx;
position: relative;
}
.del{
position:absolute;
top:5rpx;
right:0rpx;
color:#999;
font-size: 40rpx
}
.selectpic image{
width:100%;
height:100%;
}
/* 随堂笔记 */
.user_essays_content{
border-bottom:1rpx solid #f5f5f5;
}
.essays_content {
display:flex;
padding:31rpx 33rpx;
}
.essays_content_img {
width:80rpx;
height:80rpx;
font-size:0;
border-radius:50%;
}
.essays_content_img image{
width:100%;
height:100%;
border-radius:50%;
}
.essays_content_text {
width:587rpx;
margin-left:17rpx;
}
.user_comment_name {
display:flex;
justify-content:space-between;
align-items:center;
}
.essays_name {
color:#000000;
font-size:30rpx;
font-weight:bold;
}
.user_comment_hostpital {
padding:5rpx 22rpx;
border-radius:22rpx;
color:#FD8779;
font-size:26rpx;
border:1rpx solid #FD8779;
}
.essays_text{
color:#292525;
font-size:28rpx;
margin-top:30rpx;
}
.user_bottom{
display:flex;
justify-content:space-between;
align-items:center;
margin-top:43rpx;
}
.user_date,.thumb_num {
color:#999999;
font-size:24rpx;
height:30rpx;
line-height:30rpx;
}
.user_lsit_img,.thumb{
display:flex;
}
.user_img image {
width:100%;
height:100%;
}
.user_img {
width:32rpx;
height:30rpx;
font-size:0;
margin-right:15rpx;
}
.user_img image {
width:100%;
height:100%;
}
.thumb_star{
margin-right:40rpx;
}
.essays_date {
color:#999999;
font-size:26rpx;
margin-top:18rpx;
}
.suinotes {
border-bottom:1px solid #f5f5f5;
}
.use_comment {
justify-content:space-between;
}
.new_left,.mew_right {
display:flex;
}
.new new_active{
color:#FD8779;
}
.new{
width:68rpx;
text-align: center;
color:#A89997;
font-size: 24rpx;
}
.new:first-child{
border-right:1px solid #f5f5f5;
}
.new_active{
color:#FD8779;
}
.use{
display:flex;
}
/* 图文编辑图片 */
.edit_img{
/*margin-top:36rpx;*/
}
.editword{
/*margin-bottom: 36rpx;*/
}
.edit_big_img{
width:400rpx;
height:400rpx;
font-size: 0
}
.edit_small_img{
width:187rpx;
height:187rpx;
font-size: 0;
margin-left: 8rpx;
margin-top: 30rpx;
}
.edit_small_img:first-child{
margin-left:0;
}
.edit_big_img image,.edit_small_img image{
width:100%;
height:100%;
}
.small_img{
display:flex;
flex-wrap: wrap;
align-items: center;
}
/* 分享按钮 */
.lj_share{
width:310rpx;
height:80rpx;
border-radius:40rpx;
background: #FD8779;
color:#fff;
font-size: 30rpx;
text-align: center;
line-height: 80rpx;
position:fixed;
bottom:31rpx;
left:0;
right:0;
margin: 0 auto;
}
.nextstep{
width:310rpx;
height:80rpx;
border-radius:40rpx;
background: #FD8779;
color:#fff;
font-size: 30rpx;
text-align: center;
line-height: 80rpx;
position:fixed;
bottom:29rpx;
left:0;
right:0;
margin: 0 auto;
}
/* 二手置换底部导航 */
.mypublish_img{
width:64rpx;
height:64rpx;
font-size: 0;
margin: 0 auto;
}
.sell_mypublish_img{
width:80rpx;
height:80rpx;
font-size: 0;
margin: 0 auto 8rpx;
position:relative;
}
.mypublish_img image,.sell_mypublish_img image{
width:100%;
height:100%;
}
/* .sell_mypublish_img image{ */
/* position: absolute;
bottom:30rpx;
left:0;
right:0; */
/* } */
/* .sellname{ */
/* position: absolute;
bottom:0;
left:0;
right:0; */
/* } */
.mypublish_foot{
display:flex;
justify-content: space-around;
align-items: center;
/* padding: 0 40rpx; */
box-sizing: border-box;
position:fixed;
bottom:0;
left:0;
right:0;
height: 108rpx;
border-top:1rpx solid #f5f5f5;
background: #fff;
}
.center_box{
/* position: absolute; */
/* left: 50%; */
/* margin-left: -40rpx; */
/* top: -40rpx; */
width: 80px;
margin: 0 auto;
position: relative;
top: -5px;
}
.mypublish_name{
text-align: center;
color:#666;
font-size: 24rpx;
}
.mypublish_item{
/* width:33.33%; */
position: relative;
}
/*点赞和收藏*/
.iscllect{
display:flex;
}
.startouch{
display:flex;
}
/* 暂无数据 */
.nodata{
color:#A89997;
font-size: 26rpx;
text-align: center;
padding: 36rpx;
}
.editword{
width:520rpx;
}
.publishdot{
width:20rpx;
height:20rpx;
border-radius:50%;
background: #FF4D4D;
position: absolute;
top:10rpx;
right:15rpx;
}
\ No newline at end of file
... ...
@font-face {font-family: "iconfont";
src: url('//at.alicdn.com/t/font_917618_k7suf0xgjkc.eot?t=1548414831956'); /* IE9 */
src: url('//at.alicdn.com/t/font_917618_k7suf0xgjkc.eot?t=1548414831956#iefix') format('embedded-opentype'), /* IE6-IE8 */
url('data:application/x-font-woff2;charset=utf-8;base64,d09GMgABAAAAAAj0AAsAAAAAEBwAAAinAAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAHEIGVgCEIAqRbI4IATYCJAMoCxYABCAFhG0HgQsbWQ0jkg9WlOw/HNBjPANypK/qUi3G9RqWbkdBRBouEc1DE3WGZPO5aHU/1RjqiNfx8M+9ev8a+DlACVgwsTFBZjeVC94ClXq8VrTX1QABECz/hzb1H3fEFI8JARp1IrbFmpxU1NlboWLpHImYVJTUhKSGTdJVhZoSAA0QMJa4zf/PBy5uitp5QkconsTu+euzkrZpgXB+DxDc6GQwBhOnvbhM/VoBeyF7o9vr+5/aOkUTCnCASiuUpzQKYAENWIAoEwCMPf42biO034jsP+VqErRGrtljcWAlR7EEPZ749sgqkikvMCbqlDLjyFzyBnR1epoGwKvz9ck/RGRFqsjQnpub+YU4sIecSc3SKZYA6O7yoa5HhjFyNfkjs/Ad9XDsxNus/phnYDCelof4Djz54EuUrMD6cypjYkRPDPRS/8FLZQqlSq4hKVG8h/SlqSEww0tCeHqpCR8vKcH3khGJXgoi2UtJFHipiPVecr45mRqI2+0HTEi/ALJPSTptTjUyIUxD58TF3j87A3FGmOvbsxAXCyc7O7a9PeLkEDxuQ/d3drG15TiwWRg2U68nDQZKpyO0Wny6SsZKUe5h4KTpkiSXMgncJVlRxqYITM17DnJ5q154RJ/CUutDOvWedafZqmF+m0DRwezgVlQwpP5yf4acoajo6ek4fLiFqWKzq0SjbVlLQEvxw6D8GEOuiUJmHdfpLpYdFbWxVYiyM6EzUKmUM3Cuchsb+YGEVrXQplLN661FZHwVWzqfTMmqFPb2suSMZk57t3RAp0tmUskDRqPkSqWKfVDnoZAzbNTq3tFz/sgaOamV7WE16imeibTzOsR8gJKlwoJh2bD4fhPnyJUsUimbX7syJkGpFDN+UgUDkSAW0g5b57IuxFLWaeO0px0Wkvjc9eSmuhuxzvuveVhUX41yOnDdc/Lm5ev1krbYdjtMktmwlM1r2b61vZxJKFrmsXSyqnK751lOIQ/Z6GC186U3GSjHMb4tVq/dtO8YB6s4Hu14cNiNXqmOkWjv4br7hOEhpX8whcRLKLKUoMbjhIRUHvDf0FzNJRT7+RJVXdyG2eSr2JJlJIRQyJdxRbFCL3+hRxDF40QJ3EUBnqK5QggK4IqihW44Lyip4AvKca4bv4ogsG6eABEFZu0VI+DgegNlMBCiS9l6LdXh9YREZ/XTasmgi1k6Q3o/qsl32ZWcxANaX/fEobmazLj9Bv4+vOL6Z+FpCjalUoXwe8oZeLuQ5AuodJxHFVFcXHA+B/ZEEf4kTvG5iSdr/OUMIVtVKQwaGBfYFxLEExEUj88tVb8/h6NNkM9WLw487YVTFIFnhMQFm9PU2LdvmMmrFcDYYJ2RzHnO88YIF0JGHec6zx0jnckH2DgWTpNtEZCDYyX+ZJkMlFGmPK/rC4pTMs2ZqcXrgr3ygOagrn6+xfvYyJRN05+2zMWYhY8szs6KwA61vX+xbNNesWvMlOLa+0w6MVl979BZzSVXwU3j06vhYK2JyE/KCz4YcGPl9P/VGMPMHtz7UOuUnTd5+uIbLkiYTU6BDBATV7v1D9Q1+fz9M9vWoAVLL4hWmtLCntq/s0wOkIzLS8r3+/6wrF5YUMoo3u42sfhcXthG+sJilPTv500x+xy9l9EuK8v+/MIS7S60VTa2ImlMCRk3xzW3WOm2oLhyOWtGatJkFd0vp4HXmw1q8/UrehxVW6hWCADnj2Ov45kKQkIiT+BVVZkOWZlGH3zRoi9foq5mBh+yywRA/3IET46ZgzUKYkyviorFae7ufLto8SJHs8nTZHYcOe2lbsaOf/naMj0U1X2aGkukRYst554HD7rRHhTMtj0P7vdg3Rgepb4IQeDCyc6xD0u2dN1ReFbvbqq6c8nH5RO72g6+fz/66hUKfh/S9ifKTK+wfTbB9tlP1IgajGgD2mgwNMJoNKBpRqO3NkBkWP48MUKUeqzwMBeJkfd2wtVF3v86rnD813ue0xe8UamR7u1NZ7xRAXBBPufTMC1gZgdD6hanynd9sw6b+dRm9e+Vb/36lU8/r95q9csY9K96GyBMR4LTB/wr30UJ61WjdrT5K54PhMvv499G6TvC+m8WU7aPmn0bPv92EPaV/TZqh0zIvYC34kHJt5tv14VdGZsx3/Jps8+g9BPz+ojtyOJZwzNSZiYaLKeH3vntOeXS46GaPuc3V+oFJo42CdS7RP4QnuOCvywS94nvPr832bU4Mi736zN9/EbxjbBwkiE+99kvUpT969S6ny6s/rGkaG7bz3l/by45FVy4flrqhoLY8tna3pUwukM3MzWZvO0hLi3dPHXdPjL2nWbq4ItliHvpVqcHbRGpv68O/pPFuX79ra9kYnz9tPrJCadzQjZ+88ij3xFlThVlWCwtG78pJ9hrpDAiprQg8vB/sRqYxAAAZrVTaDoAAFpI0yiNJwyjaQ4hUAzTdd2oaPt9NGi++bv5YDQ070q2FRj5rlOnOya9s7L9d6sxrnRazqCaUBqX/oYzaEBFCMB1Kx2DAsF37s3yLBvsOR0j2/z98lhs4vKzJSMrbADgalXqAje7TmIOTFloFaFVGw0swQPRLKk/YpCOs9HBFqLQAtJUmw2IIOd4W3CFVYACglkDgBC2w4aAE/TZaOAAw4hCOoIYpGM2OrDgOW8BLYLabIBEXM8YZSswPlxbwp5y+C/ASiqt5/QHt+eLzFBgy1h5px+1HUsFSRh/W55UUdvFPt1o0r7XoFsp4SHtQUUhULfiSPWhRXOdRZG+7RsqKYODjJawt1xz8F8iWUmll+8Pic9/kRkKbAsmfEX+qO149SARiisIn/Gq0oRT6d+NJtWzfA3G8FZK8GD5VIhGAXX2Zo5UH7IN6utMxBbSVePh8Mnl2Wb/CyehO7Sl0sayHdfzw2IWxVqyzRkrO+B2NpqqlZKLg96qNlaGNE26mXss2GvbWayUHXYLz4xOzwgC') format('woff2'),
url('//at.alicdn.com/t/font_917618_k7suf0xgjkc.woff?t=1548414831956') format('woff'),
url('//at.alicdn.com/t/font_917618_k7suf0xgjkc.ttf?t=1548414831956') format('truetype'), /* chrome, firefox, opera, Safari, Android, iOS 4.2+ */
url('//at.alicdn.com/t/font_917618_k7suf0xgjkc.svg?t=1548414831956#iconfont') format('svg'); /* iOS 4.1- */
}
.iconfont {
font-family: "iconfont" !important;
font-size: 16px;
font-style: normal;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
}
.icon-chahao:before {
content: "\e604";
}
.icon-dianhua:before {
content: "\e621";
}
.icon-xuanze1:before {
content: "\e627";
}
.icon-xuanzekuanghou:before {
content: "\e677";
}
.icon-xuanze2:before {
content: "\e63b";
}
.icon-xuanze:before {
content: "\e63d";
}
.icon-xuanzekuang:before {
content: "\e64d";
}
.icon-shanchu:before {
content: "\e61e";
}
.icon-yixiajia:before {
content: "\e718";
}
... ...
// pages/active/active.js
const app = getApp();
Page({
/**
* 页面的初始数据
*/
data: {
page_Con: [],
monIndex: 0,
monthIndex: '',
cityshowIndex: '',
cityIndex: 0,
topcityId: 0,
dateIndex: 0,
allIndex: 0,
seachid: '',
topCity: [],
conCity: [],
conMonth: [],
conDate: ['全时段', '今天', '明天', '本周', '本月'],
conWarp: ['全价格', '免费', '0-100', '100-300', '300-500', '500以上'],
reveal: false,
wxtary: ''
},
/**
* 生命周期函数--监听页面加载
*/
onLoad: function(options) {
},
//交流专区
communitclub() {
this.setData({
reveal: true
})
let that = this;
that.setData({
reveal: true
})
var url = '/api/portal/Strategy/call';
var params = {
// token: wx.getStorageSync('token'),
}
app.post(url, params).then((res) => {
console.log(res);
that.setData({
wxtary: res.secretary
})
}).catch((err) => {
})
},
// 一键复制
bindCopy: function() {
let that = this;
wx.setClipboardData({
data: that.data.wxtary,
success: function(res) {
console.log("复制成功")
setTimeout(function() {
that.setData({
reveal: false
})
}, 1500)
}
})
},
tapHide() {
this.setData({
reveal: false
})
},
// 获取活动列表
getActive: function() {
let that = this;
let url = "/api/portal/Activity/index";
let params = {
first: that.data.monthIndex,
second: that.data.cityshowIndex,
third: that.data.dateIndex,
fourth: that.data.allIndex,
keyword: that.data.seachid
}
app.post(url, params).then((res) => {
console.log(res)
// let stime = res.list;
// for(var i=0; i<stime.length; i++){
// stime[i].start_time = that.toDate(stime[i].start_time);
// stime[i].end_time = that.toDate(stime[i].end_time);
// }
let newconMonth = res.score
let newscore = {
id: '',
title: '全部'
}
newconMonth.unshift(newscore)
that.setData({
topCity: res.city,
conMonth: newconMonth,
page_Con: res.list
})
let kage = that.data.topCity[that.data.topcityId].son;
let kagename = {
id: "",
name: '全部'
}
kage.unshift(kagename)
that.setData({
conCity: kage
})
}).catch((errMsg) => {})
},
// 幸福准妈下拉
monthTap: function(e) {
let that = this;
that.setData({
monIndex: e.detail.value,
monthIndex: that.data.conMonth[e.detail.value].id,
page_Con: []
})
that.getActive()
},
// 全城下拉
cityTap: function(e) {
let that = this;
that.setData({
cityIndex: e.detail.value,
cityshowIndex: that.data.conCity[e.detail.value].id,
page_Con: []
})
that.getActive()
},
// 全时段下拉
dateTap: function(e) {
this.setData({
dateIndex: e.detail.value,
page_Con: []
})
this.getActive()
},
// 全价格下拉
allTap: function(e) {
this.setData({
allIndex: e.detail.value,
page_Con: []
})
this.getActive()
},
// 获取搜索条件
getSearch: function(e) {
this.setData({
seachid: e.detail.value,
})
if (e.detail.value == "" || e.detail.value == null) {
this.getActive()
}
},
// 点击搜索
bindSearch: function(e) {
this.setData({
page_Con: []
})
this.getActive()
},
// 城市头部下拉切换
bindPicker: function(e) {
let that = this;
this.setData({
topcityId: e.detail.value
})
let cityname = that.data.topCity[e.detail.value].name;
if (cityname == '北京市') {
let newconCity = that.data.topCity[e.detail.value].son
let kagename = {
id: "",
name: '全部'
}
newconCity.unshift(kagename)
that.setData({
conCity: newconCity
})
} else if (cityname == '上海市') {
let newconCity = that.data.topCity[e.detail.value].son
let kagename = {
id: "",
name: '全部'
}
newconCity.unshift(kagename)
that.setData({
conCity: newconCity
})
that.setData({
conCity: newconCity
})
}
},
//时间戳转换时间
toDate: function(number) {
let n = number * 1000;
let date = new Date(n);
// let Y = date.getFullYear() + '年';
let month = (date.getMonth() + 1 < 10 ? '0' + (date.getMonth() + 1) : date.getMonth() + 1) + '月';
let day = date.getDate() < 10 ? '0' + date.getDate() : date.getDate() + '日 ';
let hour = date.getHours() < 10 ? '0' + date.getHours() + ':' : date.getHours() + ':';
let minute = date.getMinutes() < 10 ? '0' + date.getMinutes() : date.getMinutes()
return (month + day + hour + minute)
},
// 跳转到 月嫂攻略
strateTap: function() {
let token = wx.getStorageSync("token");
if (token == '') {
wx.showToast({
title: '请先登录',
icon: 'none'
})
setTimeout(function() {
wx.navigateTo({
url: '/pages/index/index',
})
}, 1000)
} else {
wx.navigateTo({
url: '../cityWide/matronStrategy/matronStrategy',
})
}
},
// 跳转到 优选月嫂
preponTap: function() {
let token = wx.getStorageSync("token");
if (token == '') {
wx.showToast({
title: '请先登录',
icon: 'none'
})
setTimeout(function() {
wx.navigateTo({
url: '/pages/index/index',
})
}, 1000)
} else {
wx.navigateTo({
url: '../cityWide/matronPrepon/matronPrepon',
})
}
},
// 跳转到 月子会所
clubTap: function() {
let token = wx.getStorageSync("token");
if (token == '') {
wx.showToast({
title: '请先登录',
icon: 'none'
})
setTimeout(function() {
wx.navigateTo({
url: '/pages/index/index',
})
}, 1000)
} else {
wx.navigateTo({
url: '../cityWide/monthClub/monthClub',
})
}
},
// 跳转到 活动详情页
bindDetail: function(e) {
let token = wx.getStorageSync("token");
if (token == '') {
wx.showToast({
title: '请先登录',
icon: 'none'
})
setTimeout(function() {
wx.navigateTo({
url: '/pages/index/index',
})
}, 1000)
} else {
let activeid = e.currentTarget.dataset.activeid;
wx.navigateTo({
url: '../cityWide/monthDetail/monthDetail?activeid=' + activeid,
})
}
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady: function() {
},
/**
* 生命周期函数--监听页面显示
*/
onShow: function() {
let that = this;
that.getActive()
},
/**
* 生命周期函数--监听页面隐藏
*/
onHide: function() {
},
/**
* 生命周期函数--监听页面卸载
*/
onUnload: function() {
},
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh: function() {
},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom: function() {
},
/**
* 用户点击右上角分享
*/
onShareAppMessage: function() {
}
})
\ No newline at end of file
... ...
{
"navigationBarTitleText": "同城活动",
"navigationBarTextStyle": "white"
}
\ No newline at end of file
... ...
<!-- begin小秘书弹层 -->
<view class='clerk_fn' wx:if="{{reveal}}" bindtap='tapHide' catchtouchmove='true'>
<view class='clerk_box'>
<!-- -->
<view class='clerk_name'>小秘书微信号:{{wxtary}}</view>
<view class='clerk_con'>点击一键复制微信号,添加小秘书为好友</view>
<view class='clerk_con'>拉你进“找月嫂&育儿嫂群”,免费领取面</view>
<view class='clerk_con'>试秘籍</view>
<view class='clerk_btn' catchtap='bindCopy'>一键复制</view>
</view>
</view>
<!-- 同城活动页面 -->
<view class='city_head'>
<view class='city_left'>
<picker bindchange="bindPicker" value="{{topcityId}}" range="{{topCity}}" range-key='name'>
<text>{{topCity[topcityId].name}}</text>
<image class='city_arr' src='http://bronet.ibaby88.cn/aicon01@2x.png'></image>
</picker>
</view>
<view class='city_serch'>
<input class='city_char' type='text' placeholder='搜索活动' bindinput='getSearch'></input>
<image class='serch_img' src='http://bronet.ibaby88.cn/aicon02@2x.png' bindtap='bindSearch'></image>
</view>
</view>
<!-- begin:月嫂攻略列表 -->
<view class='city_menu'>
<view class='city_list' bindtap='strateTap'>
<view class='city_img'><image src='http://bronet.ibaby88.cn/aicon03@2x.png'></image></view>
<view class='city_info'>
<view class='city_name'>月嫂攻略</view>
<view class='city_txt'>找月嫂前必看</view>
</view>
</view>
<view class='city_list' bindtap='preponTap'>
<view class='city_img'><image src='http://bronet.ibaby88.cn/aicon04@2x.png'></image></view>
<view class='city_info'>
<view class='city_name'>优选月嫂&育儿嫂</view>
<view class='city_txt'>可预约的优质月嫂</view>
</view>
</view>
</view>
<view class='city_menu city_bom'>
<view class='city_list' bindtap='clubTap'>
<view class='city_img'><image src='http://bronet.ibaby88.cn/aicon05@2x.png'></image></view>
<view class='city_info'>
<view class='city_name'>月子会所</view>
<view class='city_txt'>必做功课</view>
</view>
</view>
<view class='city_list' bindtap='communitclub'>
<view class='city_img'><image src='http://bronet.ibaby88.cn/aicon06@2x.png'></image></view>
<view class='city_info'>
<view class='city_name'>交流专区</view>
<view class='city_txt'>组团找月嫂微信群</view>
</view>
</view>
</view>
<!-- begin:选择框下拉 -->
<view class='matron_menu'>
<view class="matron_list">
<picker bindchange="monthTap" value="{{monIndex}}" range="{{conMonth}}" range-key='title'>
<view class="picker">
{{conMonth[monIndex].title}}<image class='matron_img' src='http://bronet.ibaby88.cn/aicon01@2x.png'></image>
</view>
</picker>
</view>
<view class="matron_list">
<picker bindchange="cityTap" value="{{cityIndex}}" range="{{conCity}}" range-key='name'>
<view class="picker">
{{conCity[cityIndex].name}}<image class='matron_img' src='http://bronet.ibaby88.cn/aicon01@2x.png'></image>
</view>
</picker>
</view>
<view class="matron_list">
<picker bindchange="dateTap" value="{{dateIndex}}" range="{{conDate}}">
<view class="picker">
{{conDate[dateIndex]}}<image class='matron_img' src='http://bronet.ibaby88.cn/aicon01@2x.png'></image>
</view>
</picker>
</view>
<view class="matron_list">
<picker bindchange="allTap" value="{{allIndex}}" range="{{conWarp}}">
<view class="picker">
{{conWarp[allIndex]}}<image class='matron_img' src='http://bronet.ibaby88.cn/aicon01@2x.png'></image>
</view>
</picker>
</view>
</view>
<!-- begin:页面信息 -->
<view wx:if="{{page_Con.length == 0}}" class='page_none'>暂无数据</view>
<block wx:else>
<view class='page_info' wx:for="{{page_Con}}" wx:key="" bindtap='bindDetail' data-activeid='{{item.id}}'>
<view class='page_img'><image src='{{item.list_pic}}'></image></view>
<view class='page_title'>{{item.title}}</view>
<view class='page_txt'>
<text wx:if='{{item.cityName}}'>{{item.cityName[0]}} {{item.cityName[1]}}</text>
<text class='page_date'>
{{item.start_time}} <text wx:if="{{item.end_time!=''}}">-</text> {{item.end_time}}
</text>
</view>
<view class='page_menu'>
<view class='page_labelo' wx:if="{{item.status==1}}">报名中</view>
<view class='page_labelo' wx:if="{{item.status==2}}">报名未开始</view>
<view class='page_labelo' wx:if="{{item.status==3}}">报名结束,活动开始</view>
<view class='page_labelo' wx:if="{{item.status==4}}">活动结束</view>
<view class='page_labelo page_labelt'wx:if="{{item.money==0}}">免费</view>
<view class='page_labelo page_labelt' wx:else>{{item.money}}</view>
</view>
</view>
</block>
... ...
/* pages/cityWide/cityActivety/cityActivety.wxss */
@import '../cityWide/matronStrategy/matronStrategy.wxss';
.city_head{
display: flex;
align-items: center;
justify-content: flex-start;
height: 88rpx;
border-bottom: solid 1rpx #EBEBEB;
}
.city_left{
padding-left: 33rpx;
}
.city_left text{
color: #292625;
font-size: 26rpx;
}
.city_arr{
width: 10rpx;
height: 10rpx;
margin-left: 10rpx;
}
.city_serch{
display: flex;
align-items: center;
position: relative;
width: 582rpx;
height: 64rpx;
margin-left: 32rpx;
border-radius: 32rpx;
background: #FAFAFA;
}
.serch_img{
position: absolute;
top: 15rpx;
right: 28rpx;
width: 33rpx;
height: 33rpx;
}
.city_char{
width: 510rpx;
padding-left: 30rpx;
color: #B2B2B2;
font-size: 26rpx;
box-sizing: border-box;
}
.city_menu{
display: flex;
align-items: center;
justify-content: space-between;
}
.city_bom{
border-top: solid 1rpx #EBEBEB;
border-bottom: solid 16rpx #FCF8F7;
}
.city_list{
display: flex;
align-items: center;
justify-content: flex-start;
width: 375rpx;
height: 140rpx;
padding-left: 32rpx;
box-sizing: border-box;
border-right: solid 1rpx #EBEBEB;
}
.city_menu .city_list:last-child{
border-right: none;
}
.city_img{
width: 80rpx;
height: 80rpx;
}
.city_img image{
width: 100%;
height: 100%;
}
.city_info{
padding-left: 22rpx;
}
.city_name{
color: #292625;
font-size: 30rpx;
font-weight: bold;
}
.city_txt{
color: #5C5453;
font-size: 26rpx;
}
.matron_menu{
display: flex;
align-items: center;
justify-content: space-between;
height: 88rpx;
padding: 0 54rpx;
border-bottom: solid 1rpx #EBEBEB;
}
.matron_list{
display: flex;
align-items: center;
height: 25rpx;
}
.matron_list text,.picker{
color: #292525;
font-size: 30rpx;
}
.matron_img{
width: 10rpx;
height: 10rpx;
margin-left: 10rpx;
}
.page_info{
width: 686rpx;
margin: 0 auto;
padding: 36rpx 0;
border-bottom: solid 1rpx #EBEBEB;
}
.page_img{
width: 686rpx;
height: 272rpx;
border-radius: 16rpx;
}
.page_img image{
width: 100%;
height: 100%;
border-radius: 16rpx;
}
.page_title{
padding-top: 36rpx;
/* color: #292525; */
color:#292625;
font-size: 34rpx;
font-weight: bold;
}
.page_txt{
padding-top: 15rpx;
color: #969799;
font-size: 26rpx;
}
.page_date{
padding-left: 38rpx;
}
.page_menu{
display: flex;
align-items: center;
justify-content: flex-start;
padding-top: 15rpx;
}
.page_labelo{
padding: 4rpx 12rpx;
margin-right: 20rpx;
color: #fff;
font-size: 24rpx;
background: #FD8779;
border-radius: 3rpx;
}
.page_labelt{
background: #FFC299;
}
.page_none{
padding: 36rpx;
font-size: 26rpx;
}
.clerk_box {
bottom:0rpx;
height:500rpx;
}
\ No newline at end of file
... ...
// pages/cityWide/WeChatCulum/WeChatCulum.js
const app=getApp();
Page({
/**
* 页面的初始数据
*/
data: {
activityId:'',
joincoursecontent:''
},
/**
* 生命周期函数--监听页面加载
*/
onLoad: function (options) {
let that=this;
that.setData({
activityId: options.activeid
})
that.getwtask();
},
getwtask(){
let that=this;
let url ='/api/portal/Activity/pic'
var params = {
token: wx.getStorageSync('token'),
activityId: that.data.activityId,
}
app.post(url, params).then((res) => {
console.log(res);
that.setData({
joincoursecontent:res
})
}).catch((err) => {
})
},
//一键复制
bindCopy: function () {
let that = this;
wx.setClipboardData({
data: that.data.joincoursecontent.code,
success: function (res) {
console.log("复制成功")
}
})
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady: function () {
},
/**
* 生命周期函数--监听页面显示
*/
onShow: function () {
},
/**
* 生命周期函数--监听页面隐藏
*/
onHide: function () {
},
/**
* 生命周期函数--监听页面卸载
*/
onUnload: function () {
},
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh: function () {
},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom: function () {
},
/**
* 用户点击右上角分享
*/
onShareAppMessage: function () {
}
})
\ No newline at end of file
... ...
{
"navigationBarTitleText": "微信直播课程",
"navigationBarTextStyle": "white"
}
\ No newline at end of file
... ...
<!-- 微信直播课程 -->
<view class='culum_menu'>
<view class='culum_img'><image src='http://bronet.ibaby88.cn/bicon43@2x.png'></image></view>
<view class='culum_box'>
<view class='culum_pic'><image src='http://bronet.ibaby88.cn/dicon09@2x.png'></image></view>
<view class='culum_txt'>发送课程代码至小秘书微信</view>
<view class='culum_num'>{{joincoursecontent.code}}</view>
<view class='culum_word'>课程代码</view>
<view class='culum_btn' catchtap="bindCopy">一键复制</view>
</view>
</view>
<view class='culum_code'><image src='{{joincoursecontent.url}}'></image></view>
<view class='culum_con'>复制上面的课程代码,发送给小秘书,即可通过验证 </view>
<view class='culum_con addtype'>添加小秘书为好友的方式:</view>
<view class='culum_con'>截图整个页面,打开微信,选择“扫一扫”右上角“相册“,选择截图页面,识别二维码,添加好友</view>
... ...
/* pages/cityWide/WeChatCulum/WeChatCulum.wxss */
page{
background: #FD8779;
}
.culum_menu{
position: relative;
}
.culum_img{
position: absolute;
top: 0;
left: 0;
right: 0;
width: 686rpx;
height: 555rpx;
margin: 0 auto;
z-index: 5;
}
.culum_img image{
width: 100%;
height: 100%;
}
.culum_box{
position: relative;
padding-top: 16rpx;
z-index: 10;
}
.culum_txt{
padding-top: 22rpx;
padding-bottom: 62rpx;
color: #292525;
font-size: 30rpx;
text-align: center;
}
.culum_num{
padding-bottom: 20rpx;
color: #FD8779;
font-size: 64rpx;
font-weight: bold;
text-align: center;
}
.culum_word{
padding-bottom: 52rpx;
color: #292525;
font-size: 24rpx;
text-align: center;
}
.culum_btn{
display: flex;
align-items: center;
justify-content: center;
width: 300rpx;
height: 80rpx;
margin: 0 auto;
color: #fff;
font-size: 32rpx;
border-radius: 40rpx;
background:linear-gradient(0deg,rgba(255,135,177,1),rgba(255,171,200,1));
box-shadow:0rpx 8rpx 16rpx 0rpx rgba(255,168,198,1);
}
.culum_pic{
width: 80rpx;
height: 80rpx;
margin: 0 auto;
border-radius: 50%;
}
.culum_pic image{
width: 100%;
height: 100%;
border-radius: 50%;
}
.culum_code{
width: 280rpx;
height: 280rpx;
margin: 132rpx auto 26rpx;
}
.culum_code image{
width: 100%;
height: 100%;
}
.culum_con{
width:656rpx;
margin:0 auto;
color: #fff;
font-size: 28rpx;
line-height: 44rpx;
text-align: center;
}
/* .addtype{
text-align: left
} */
\ No newline at end of file
... ...
const app = getApp();
let interval = null;
Page({
/**
* 页面的初始数据
*/
data: {
activeid: '',
name: '',
phone: '',
activeCon: '',
codenum:'',
//获取验证码
disable: false,
time: '获取验证码', //倒计时
currentTime: 60,
},
/**
* 生命周期函数--监听页面加载
*/
onLoad: function (options) {
let that = this;
that.setData({
activeid: options.activeid
})
that.getActiveName()
},
// 获取活动报名信息
getActiveName: function(){
let that = this;
let url = "/api/portal/Activity/join";
let params = {
token: wx.getStorageSync('token'),
activityId: that.data.activeid
}
app.post(url, params).then((res) => {
that.setData({
activeCon: res.list
})
}).catch((errMsg) => {})
},
// 获取姓名
getName: function(e){
this.setData({
name: e.detail.value
})
},
// 获取手机号
getPhone: function(e){
this.setData({
phone: e.detail.value
})
},
getcode: function (options) {
let that = this;
//判断手机验证码
let reg = /^[1][3,4,5,6,7,8][0-9]{9}$/;
let phone = that.data.phone;
if (!reg.test(phone)) {
wx.showToast({
title: '请填写正确的手机号',
icon: 'none'
})
return false;
} else {
let that = this;
let currentTime = that.data.currentTime;
that.setData({
disable: true
})
interval = setInterval(function () {
currentTime--;
that.setData({
time: currentTime + '秒',
})
if (currentTime <= 0) {
clearInterval(interval)
that.setData({
time: '重新发送',
currentTime: 61,
disable: false
})
}
}, 1000)
}
var url = '/api/portal/Msg/getMes';
let token = wx.getStorageSync('token');
console.log(token)
var params = {
tel: that.data.phone
}
app.post(url, params).then((res) => {
console.log(res);
}).catch((err) => {
})
},
//获取验证码
getVerificationCode() {
this.getcode();
},
//输入验证码
entercode(e){
this.setData({
codenum:e.detail.value
})
},
activitysub(){
let that=this;
if(that.data.name==''){
wx.showToast({
title: '姓名不能为空',
icon:'none'
})
return false
}
if(that.data.phone==''){
wx.showToast({
title: '手机号不能为空',
icon: 'none'
})
return false
}
let reg = /^[1][3,4,5,6,7,8][0-9]{9}$/;
let phone = that.data.phone;
if (!reg.test(phone)) {
wx.showToast({
title: '请填写正确的手机号',
icon: 'none'
})
return false;
}
let url ='/api/portal/Activity/toJoin';
let params = {
token: wx.getStorageSync('token'),
activityId: that.data.activeid,
name:that.data.name,
tel:that.data.phone,
code:that.data.codenum,
}
app.post(url, params).then((res) => {
console.log(res)
console.log(res.activityId)
if (res.activityId){
wx.setStorageSync('activityId', res.activityId)
wx.showToast({
title: '报名成功,等待工作人员联系',
icon:'none'
})
setTimeout(function () {
wx.navigateBack({ changed: true })
// wx.switchTab({
// url: '../../active/active',
// })
}, 1500) //
}else{
wx.showToast({
title: '报名失败',
icon: 'none'
})
}
}).catch((errMsg) => { })
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady: function () {
},
/**
* 生命周期函数--监听页面显示
*/
onShow: function () {
},
/**
* 生命周期函数--监听页面隐藏
*/
onHide: function () {
},
/**
* 生命周期函数--监听页面卸载
*/
onUnload: function () {
},
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh: function () {
},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom: function () {
},
/**
* 用户点击右上角分享
*/
onShareAppMessage: function () {
}
})
\ No newline at end of file
... ...
{
"navigationBarTitleText": "活动报名",
"navigationBarTextStyle": "white"
}
\ No newline at end of file
... ...
<!-- 活动报名页面 -->
<view class='activity_box'>
<view class='activity_img'><image src='{{activeCon.list_pic}}'></image></view>
<view class='activity_menu'>
<view class='activity_name'>{{activeCon.title}}</view>
<view class='activity_date'>{{activeCon.start_time}}-{{activeCon.end_time}}</view>
<view class='activity_txt'>{{activeCon.money}}</view>
</view>
</view>
<view class='activity_tab'>
<view class='activity_list'>
<view class='activity_title'>姓名</view>
<view class='activity_char'><input type='text' placeholder='请输入姓名' bindinput='getName'></input></view>
</view>
<view class='activity_list'>
<view class='activity_title'>手机号</view>
<view class='activity_char'><input type='text' placeholder='请输入手机号' bindinput='getPhone'></input></view>
</view>
<view class='activity_list'>
<view class='activity_title'>验证码</view>
<view class='activity_char'><input type='text' placeholder='请输入验证码' bindinput='entercode'></input></view>
<!-- <view class='activity_code'>获取验证码</view> -->
<button class="activity_char getcode" bindtap="getVerificationCode" disabled="{{disable}}">{{time}} </button>
</view>
</view>
<view class='warp_btn' bindtap="activitysub">提交</view>
... ...
/* pages/cityWide/activityName/activityName.wxss */
@import '../../../style/base.wxss';
.activity_box{
display: flex;
align-items: center;
justify-content: flex-start;
padding: 16rpx 32rpx;
border-bottom: solid 16rpx #FCF8F7;
}
.activity_img{
width: 160rpx;
height: 160rpx;
border-radius: 10rpx;
}
.activity_img image{
width: 100%;
height: 100%;
border-radius: 10rpx;
}
.activity_menu{
padding-left: 28rpx;
}
.activity_name{
color: #252729;
font-size: 30rpx;
font-weight: bold;
}
.activity_date{
padding: 12rpx 0;
color: #333333;
font-size: 24rpx;
}
.activity_txt{
color: #FD8779;
font-size: 24rpx;
}
.activity_tab{
padding: 0 32rpx;
}
.activity_list{
position: relative;
display: flex;
align-items: center;
justify-content: flex-start;
height: 100rpx;
padding: 0 12rpx;
border-bottom: solid 1rpx #EBEBEB;
}
.activity_title{
width: 160rpx;
color: #000000;
font-size: 30rpx;
}
.activity_char{
color: #666666;
font-size: 26rpx;
width:228rpx;
}
.activity_char input{
width: 100%;
}
.activity_code{
width: 198rpx;
color: #FD8779;
font-size: 30rpx;
text-align: center;
border-left: solid 1rpx #FD8779;
}
.warp_btn{
position: fixed;
bottom: 36rpx;
left: 0;
right: 0;
}
.getcode{
color:#FD8779;
background: transparent
}
button::after {
border: none;
outline: none;
background: transparent;
}
... ...
// pages/cityWide/diatelyMake/diatelyMake.js
const app = getApp();
Page({
/**
* 页面的初始数据
*/
data: {
typeOf: 0,
maternityid: '',
date: '',
name: '',
phone: '',
brith:'',
childbirth: '',
commet: '',
infoCon: ''
},
/**
* 生命周期函数--监听页面加载
*/
onLoad: function (options) {
let that = this;
that.setData({
maternityid: options.maternityid,
date: app.nowDate()
})
that.getInfo();
that.getlastdate();
},
//获取上次的预产期
getlastdate(){
let that = this;
var url = '/api/portal/childbirth/getLastChildbirthDate';
var params = {
token: wx.getStorageSync('token'),
}
app.post(url, params).then((res) => {
console.log(res);
that.setData({
date: res.childbirth_date
})
console.log(that.data.date)
}).catch((err) => {
})
},
// 判断是否为空
judgeTap: function(){
let that = this;
var myreg = /^(((13[0-9]{1})|(15[0-9]{1})|(18[0-9]{1})|(17[0-9]{1}))+\d{8})$/;
if (that.data.name == ''){
wx.showToast({
title: "请输入姓名",
icon: 'none',
duration: 1500
});
return false;
} else if (that.data.phone == ''){
wx.showToast({
title: "请输入手机号",
icon: 'none',
duration: 1500
});
return false;
} else if (!myreg.test(that.data.phone)){
wx.showToast({
title: "手机号输入有误",
icon: 'none',
duration: 1500
});
return false;
}else if (that.data.typeOf==0){
wx.showToast({
title: '请选择类型',
icon:'none'
})
return false;
} else if (that.data.childbirth == "") {
wx.showToast({
title: '请输入宝宝年龄',
icon: 'none'
})
return false;
}else if (that.data.commet == ''){
wx.showToast({
title: "请输入特殊说明",
icon: 'none',
});
return false;
}else{
that.commitMake()
}
},
// 提交立即预约
commitMake: function(){
let that = this;
let url = "/api/portal/Maternity/toAdmin";
let params = {
token: wx.getStorageSync('token'),
maternityId: that.data.maternityid,
name: that.data.name,
tel: that.data.phone,
childbirth: that.data.childbirth,
type: that.data.typeOf,
else: that.data.commet,
find_type: 2
}
app.post(url, params).then((res) => {
console.log(res)
if(res.length==0){
wx.showToast({
title: '提交成功,等待后台工作人员联系',
icon:'none'
})
}
setTimeout(function(){
wx.navigateTo({
url: '../matronPrepon/matronPrepon',
})
},1500)
}).catch((errMsg) => {})
},
// 获取详情信息
getInfo: function(){
let that = this;
let url = "/api/portal/Maternity/detail";
let params = {
maternityId: that.data.maternityid
}
app.post(url, params).then((res) => {
console.log(res)
that.setData({
infoCon: res.list
})
}).catch((errMsg) => {})
},
// 获取姓名
getName: function(e){
this.setData({
name: e.detail.value
})
},
// 获取手机号
getPhone: function(e){
this.setData({
phone: e.detail.value
})
},
// 获取特殊说明
getCommit: function(e){
this.setData({
commet: e.detail.value
})
},
// 获取预产期
bindDateChange: function(e){
this.setData({
date: e.detail.value,
childbirth: e.detail.value
})
},
// 获取宝宝年龄
getBrith: function(e){
this.setData({
brith: e.detail.value,
childbirth: e.detail.value
})
},
//点击切换
clickTab: function (e) {
var that = this;
if (this.data.typeOf === e.target.dataset.current) {
return false;
} else {
that.setData({
typeOf: e.target.dataset.current
})
if (that.data.typeOf == 1) {
that.setData({
childbirth: that.data.date
})
} else if (that.data.typeOf == 2) {
that.setData({
childbirth: that.data.brith
})
}
}
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady: function () {
},
/**
* 生命周期函数--监听页面显示
*/
onShow: function () {
},
/**
* 生命周期函数--监听页面隐藏
*/
onHide: function () {
},
/**
* 生命周期函数--监听页面卸载
*/
onUnload: function () {
},
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh: function () {
},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom: function () {
},
/**
* 用户点击右上角分享
*/
onShareAppMessage: function () {
}
})
\ No newline at end of file
... ...
{
"navigationBarTitleText": "立即预约",
"navigationBarTextStyle": "white"
}
\ No newline at end of file
... ...
<!-- 立即预约页面 -->
<view class='make_box'>
<view class='make_img'><image src='{{infoCon.pic}}'></image></view>
<view class='make_menu'>
<view class='make_name'>{{infoCon.name}}</view>
<view class='make_day'>¥<text>{{infoCon.money}}</text>/天</view>
</view>
</view>
<!-- begin:信息 -->
<view class='find_box'>
<view class='find_list'>
<view class='find_name'>姓名</view>
<view class='find_left'>
<input class='make_mname' type='text' placeholder='请输入姓名' bindinput='getName'></input>
</view>
</view>
<view class='find_list'>
<view class='find_name'>手机号</view>
<view class='find_left'>
<input class='make_mname' type='text' placeholder='请输入手机号' bindinput='getPhone'></input>
</view>
</view>
<!-- begin:类型切换 -->
<view class='find_list'>
<view class='find_name'>类型</view>
<view class='find_choice'>
<view class="find_radio {{typeOf==1?'active':''}}" data-current="1" bindtap='clickTab'>月嫂</view>
<view class="find_radio {{typeOf==2?'active':''}}" data-current="2" bindtap='clickTab'>育儿嫂</view>
</view>
</view>
<!-- begin:预产期 -->
<view wx:if="{{typeOf==1}}" class='find_list'>
<view class='find_name'>预产期</view>
<view class='find_left pick'>
<picker mode="date" value="{{date}}" bindchange="bindDateChange">
<text>{{date}}</text>
</picker>
<image class='find_img' src='http://bronet.ibaby88.cn/bicon08@2x.png'></image>
</view>
</view>
<!-- begin:宝宝年龄 -->
<view wx:if="{{typeOf==2}}" class='find_list'>
<view class='find_name'>宝宝多大</view>
<view class='find_left'>
<input type='text' class='make_mname' placeholder='请输入宝宝年龄' bindinput='getBrith'></input>
</view>
</view>
</view>
<!-- begin:特殊说明 -->
<view class='find_menu'>特殊说明</view>
<view class='find_txt'><textarea placeholder='如有特别说明,请在此处留言' bindinput='getCommit'></textarea></view>
<!-- begin:按钮 -->
<view class="footbtn">
<view class='warp_btn' bindtap='judgeTap'>提交</view>
</view>
... ...
/* pages/cityWide/diatelyMake/diatelyMake.wxss */
@import '../../../style/base.wxss';
.find_box{
padding: 0 32rpx;
border-bottom: solid 16rpx #FCF8F7;
}
.find_list{
display: flex;
align-items: center;
justify-content: space-between;
height: 100rpx;
padding: 0 10rpx;
border-bottom: solid 1rpx #EBEBEB;
}
.find_box .find_list:last-child{
border-bottom: none;
}
.find_name{
color: #000000;
font-size: 30rpx;
}
.find_left{
display: flex;
align-items: center;
}
.find_left text{
padding-right: 5rpx;
color: #666666;
font-size: 26rpx;
}
.find_img{
width: 40rpx;
height: 40rpx;
}
.find_choice{
display: flex;
align-items: center;
justify-content: flex-start;
}
.find_radio{
display: flex;
align-items: center;
justify-content: center;
width: 136rpx;
height: 60rpx;
margin-left: 36rpx;
color: #999999;
font-size: 26rpx;
border-radius: 30rpx;
border: solid 1rpx #EBEBEB;
}
.active{
color: #fff;
background: #FD8779;
border: none;
}
.find_menu{
display: flex;
align-items: center;
justify-content: space-between;
height: 80rpx;
padding-left: 35rpx;
color: #292525;
font-size: 26rpx;
font-weight: bold;
border-bottom: solid 1rpx #EBEBEB;
}
.find_txt{
padding: 32rpx;
}
.find_txt textarea{
width: 686rpx;
color: #CCBAB8;
font-size: 28rpx;
}
.warp_btn{
position: fixed;
bottom: 36rpx;
left: 0;
right: 0;
}
.make_box{
display: flex;
align-items: center;
justify-content: flex-start;
padding: 16rpx 32rpx;
border-bottom: solid 16rpx #FCF8F7;
}
.make_img{
width: 160rpx;
height: 160rpx;
border-radius: 10rpx;
}
.make_img image{
width: 100%;
height: 100%;
border-radius: 10rpx;
}
.make_menu{
padding-left: 32rpx;
}
.make_name{
padding-bottom: 38rpx;
color: #252729;
font-size: 30rpx;
font-weight: bold;
}
.make_day{
color: #FD8779;
font-size: 24rpx;
}
.make_day text{
font-size: 30rpx;
font-weight: 500;
}
.make_mname{
color: #666666;
font-size: 26rpx;
text-align: right;
}
.pick picker{
margin-top: -10rpx;
}
\ No newline at end of file
... ...
// pages/cityWide/keyFind/keyFind.js
const app = getApp();
Page({
/**
* 页面的初始数据
*/
data: {
typeOf: 0,
brith: '',
date: '',
childbirth: '',
name: '',
phone: '',
comment: ''
},
/**
* 生命周期函数--监听页面加载
*/
onLoad: function (options) {
this.setData({
date: app.nowDate(),
})
this.getlastdate()
},
//获取上次的预产期
getlastdate() {
let that = this;
var url = '/api/portal/childbirth/getLastChildbirthDate';
var params = {
token: wx.getStorageSync('token'),
}
app.post(url, params).then((res) => {
console.log(res);
that.setData({
date: res.childbirth_date
})
console.log(that.data.date)
}).catch((err) => {
})
},
bindDateChange: function (e) {
console.log(e)
var val = e.detail.value;
console.log(val)
var sval = val.split("-")
console.log(sval)
sval = sval[0] + "年" + sval[1] + "月" + sval[2] + "日"
console.log(sval)
this.setData({
childbirth: sval
})
},
// 判断是否为空
judgEmpty: function(){
let that = this;
var myreg = /^(((13[0-9]{1})|(15[0-9]{1})|(18[0-9]{1})|(17[0-9]{1}))+\d{8})$/;
if (that.data.name == ''){
wx.showToast({
title: "请输入姓名",
icon: 'none',
duration: 1500
});
return false;
}else if(that.data.phone == ''){
wx.showToast({
title: "请输入手机号",
icon: 'none',
duration: 1500
});
return false;
} else if (!myreg.test(that.data.phone)){
wx.showToast({
title: "手机号输入有误",
icon: 'none',
duration: 1500
});
return false;
}
else if (that.data.typeOf==0){
wx.showToast({
title: '请选择类型',
icon:'none'
})
return false;
} else if (that.data.childbirth==""){
wx.showToast({
title: '请输入宝宝年龄',
icon:'none'
})
return false
}else if(that.data.comment == ''){
wx.showToast({
title: "请输入特殊说明",
icon: 'none',
duration: 1500
});
return false;
}else{
that.commitInfo()
}
},
// 提交一键找月嫂信息
commitInfo: function(){
let that = this;
let url = "/api/portal/Maternity/toAdmin";
let params = {
token: wx.getStorageSync('token'),
name: that.data.name,
tel: that.data.phone,
childbirth: that.data.childbirth,
type: that.data.typeOf,
else: that.data.comment,
find_type: 1
}
app.post(url, params).then((res) => {
console.log(res.length)
if(res.length==0){
console.log(999)
wx.showToast({
title: '提交成功,等待后台工作人员联系',
icon: 'none',
})
setTimeout(function () {
// wx.navigateTo({
// url: '../matronPrepon/matronPrepon',
// })
wx.navigateBack({
checked:true
})
},1500)
}
}).catch((errMsg) => {})
},
// 获取姓名
getName: function(e){
this.setData({
name: e.detail.value
})
},
// 获取手机号
getPhone: function(e){
this.setData({
phone: e.detail.value
})
},
// 获取宝宝年龄
getBrith: function(e){
this.setData({
brith: e.detail.value,
childbirth: e.detail.value
})
},
// 获取特殊说明
getElse: function(e){
this.setData({
comment: e.detail.value
})
},
// 选择预产期
// bindDateChange: function (e) {
// this.setData({
// date: e.detail.value,
// childbirth: e.detail.value
// })
// },
// 点击切换
clickTab: function (e) {
var that = this;
if (this.data.typeOf === e.target.dataset.current) {
return false;
} else {
that.setData({
typeOf: e.target.dataset.current
})
if(that.data.typeOf == 1){
that.setData({
childbirth: that.data.date
})
} else if (that.data.typeOf == 2){
that.setData({
childbirth: that.data.brith
})
}
}
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady: function () {
},
/**
* 生命周期函数--监听页面显示
*/
onShow: function () {
},
/**
* 生命周期函数--监听页面隐藏
*/
onHide: function () {
},
/**
* 生命周期函数--监听页面卸载
*/
onUnload: function () {
},
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh: function () {
},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom: function () {
},
/**
* 用户点击右上角分享
*/
onShareAppMessage: function () {
}
})
\ No newline at end of file
... ...
{
"navigationBarTitleText": "一键找月嫂",
"navigationBarTextStyle": "white"
}
\ No newline at end of file
... ...
<!-- 一键找月嫂页面 -->
<view class='find_box'>
<view class='find_list'>
<view class='find_name'>姓名</view>
<view class='find_left'>
<input type='text' placeholder='请输入姓名' bindinput='getName'></input>
</view>
</view>
<view class='find_list'>
<view class='find_name'>手机号</view>
<view class='find_left'>
<input type='number' placeholder='请输入手机号' bindinput='getPhone'></input>
</view>
</view>
</view>
<!-- begin:类型 -->
<view class='find_box'>
<view class='find_list'>
<view class='find_name'>类型</view>
<view class='find_choice'>
<view class="find_radio {{typeOf==1?'active':''}}" data-current="1" bindtap='clickTab'>月嫂</view>
<view class="find_radio {{typeOf==2?'active':''}}" data-current="2" bindtap='clickTab'>育儿嫂</view>
</view>
</view>
<view wx:if="{{typeOf==1}}" class='find_list'>
<view class='find_name'>预产期</view>
<view class='find_left'>
<picker mode="date" value="{{childbirth}}" bindchange="bindDateChange">
<view class="picker find_date">{{childbirth}}</view>
</picker>
<image class='find_img' src='http://bronet.ibaby88.cn/bicon08@2x.png'></image>
</view>
</view>
<view wx:if="{{typeOf==2}}" class='find_list'>
<view class='find_name'>宝宝多大</view>
<view class='find_left'>
<input type='text' placeholder='请输入宝宝年龄' bindinput='getBrith'></input>
</view>
</view>
</view>
<!-- begin:特殊说明 -->
<view class='find_menu'>特殊说明</view>
<view class='find_txt'><textarea placeholder='如有特别说明,请在此处留言' bindinput='getElse'></textarea></view>
<!-- begin:按钮 -->
<view class="footbtn">
<view class='warp_btn' bindtap='judgEmpty'>提交</view>
</view>
... ...
/* pages/cityWide/keyFind/keyFind.wxss */
@import '../../../style/base.wxss';
.find_box{
padding: 0 32rpx;
border-bottom: solid 16rpx #FCF8F7;
}
.find_list{
display: flex;
align-items: center;
justify-content: space-between;
height: 100rpx;
padding: 0 10rpx;
border-bottom: solid 1rpx #EBEBEB;
}
.find_box .find_list:last-child{
border-bottom: none;
}
.find_name{
color: #000000;
font-size: 30rpx;
}
.find_left{
display: flex;
align-items: center;
}
.find_left input, .find_date{
padding-right: 5rpx;
color: #666666;
font-size: 26rpx;
text-align: right;
}
.find_left picker{
height: 38rpx;
}
.find_img{
width: 40rpx;
height: 40rpx;
}
.find_choice{
display: flex;
align-items: center;
justify-content: flex-start;
}
.find_radio{
display: flex;
align-items: center;
justify-content: center;
width: 136rpx;
height: 60rpx;
margin-left: 36rpx;
color: #999999;
font-size: 26rpx;
border-radius: 30rpx;
border: solid 1rpx #EBEBEB;
}
.active{
color: #fff;
background: #FD8779;
border: none;
}
.find_menu{
display: flex;
align-items: center;
justify-content: space-between;
height: 80rpx;
padding-left: 35rpx;
color: #292525;
font-size: 26rpx;
font-weight: bold;
border-bottom: solid 1rpx #EBEBEB;
}
.find_txt{
padding: 32rpx;
}
.find_txt textarea{
width: 686rpx;
color: #CCBAB8;
font-size: 28rpx;
}
.warp_btn{
position: fixed;
bottom: 36rpx;
left: 0;
right: 0;
}
\ No newline at end of file
... ...
// pages/cityWide/matronDetail/matronDetail.js
const app = getApp();
Page({
/**
* 页面的初始数据
*/
data: {
maternityid: '',
detailCon: ''
},
/**
* 生命周期函数--监听页面加载
*/
onLoad: function (options) {
let that = this;
that.setData({
maternityid: options.maternityId
})
that.getDetail()
},
// 获取月嫂详情
getDetail: function(){
let that = this;
let url = "/api/portal/Maternity/detail";
let params = {
maternityId: that.data.maternityid
}
app.post(url, params).then((res) => {
console.log(res)
that.setData({
detailCon: res.list
})
}).catch((errMsg) => {})
},
// 跳转到 立即预约
makeTap:function(){
wx.navigateTo({
url: '../diatelyMake/diatelyMake?maternityid=' + this.data.maternityid,
})
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady: function () {
},
/**
* 生命周期函数--监听页面显示
*/
onShow: function () {
},
/**
* 生命周期函数--监听页面隐藏
*/
onHide: function () {
},
/**
* 生命周期函数--监听页面卸载
*/
onUnload: function () {
},
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh: function () {
},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom: function () {
},
/**
* 用户点击右上角分享
*/
onShareAppMessage: function () {
}
})
\ No newline at end of file
... ...
{
"navigationBarTitleText": "月嫂详情",
"navigationBarTextStyle": "white"
}
\ No newline at end of file
... ...
<!-- 月嫂详情页面 -->
<view class='detail_head'>
<view class='detail_img'><image src='{{detailCon.pic}}'></image></view>
<view class='detail_name'>{{detailCon.name}}</view>
<view class='detail_day'>¥{{detailCon.money}}/天</view>
<view class='detail_btn' bindtap='makeTap'>预约面试</view>
</view>
<!-- begin:信息 -->
<view class='detail_menu'>
<view class='detail_txt'>公司:{{detailCon.company}}</view>
<view class='detail_txt'>
<text>年龄:{{detailCon.age}}</text>
<text class='detail_num'>经验:</text>
<text wx:if="{{detailCon.experience==1}}">初级</text>
<text wx:if="{{detailCon.experience==2}}">中级</text>
<text wx:if="{{detailCon.experience==3}}">高级</text>
<text wx:if="{{detailCon.experience==4}}">金牌</text>
<text wx:if="{{detailCon.experience==5}}">首席</text>
</view>
<view class='detail_txt'>籍贯:{{detailCon.native}}</view>
<view class='detail_txt'>特长:{{detailCon.speciality}}</view>
<view class='detail_txt'>证书:{{detailCon.certificate}}</view>
</view>
<!-- begin:个人简介 -->
<view class='detail_per'>
<view class='detail_tab'>
<image class='detail_pic' src='http://bronet.ibaby88.cn/bicon11@2x.png'></image>
<text>个人简介</text>
</view>
<view class='detail_info'>{{detailCon.introduction}}</view>
</view>
<!-- begin:预约时间段 -->
<view class='detail_tab'>
<image class='detail_pic' src='http://bronet.ibaby88.cn/bicon38@2x.png'></image>
<text>可预约时段</text>
</view>
<view class='detail_date'>{{detailCon.free_time}}</view>
... ...
/* pages/cityWide/matronDetail/matronDetail.wxss */
.detail_head{
padding-top: 60rpx;
padding-bottom: 32rpx;
border-bottom: solid 16rpx #FCF8F7;
}
.detail_img{
width: 125rpx;
height: 125rpx;
margin: 0 auto;
border: solid 1rpx #FD8779;
border-radius: 50%;
}
.detail_img image{
width: 100%;
height: 100%;
border-radius: 50%;
}
.detail_name{
padding: 30rpx 0;
color: #292525;
font-size: 28rpx;
text-align: center;
font-weight: bold;
}
.detail_day{
padding-bottom: 35rpx;
color: #292525;
font-size: 26rpx;
text-align: center;
}
.detail_btn{
display: flex;
align-items: center;
justify-content: center;
width: 310rpx;
height: 80rpx;
margin: 0 auto;
color: #fff;
font-size: 30rpx;
border-radius: 40rpx;
background: #FD8779;
}
.detail_menu{
padding: 30rpx 30rpx 0;
border-bottom: solid 16rpx #FCF8F7;
}
.detail_txt{
padding-bottom: 28rpx;
color: #292525;
font-size: 28rpx;
}
.detail_num{
padding-left: 118rpx;
}
.detail_per{
border-bottom: solid 16rpx #FCF8F7;
}
.detail_tab{
display: flex;
align-items: center;
height: 80rpx;
padding-left: 36rpx;
border-bottom: solid 1rpx #EBEBEB;
}
.detail_tab text{
padding-left: 14rpx;
color: #292525;
font-size: 26rpx;
font-weight: bold;
}
.detail_pic{
width: 40rpx;
height: 40rpx;
}
.detail_info{
padding: 28rpx 34rpx 22rpx;
color: #292525;
font-size: 28rpx;
line-height: 50rpx;
}
.detail_date{
display: flex;
align-items: center;
height: 82rpx;
padding-left: 34rpx;
color: #292525;
font-size: 28rpx;
}
\ No newline at end of file
... ...
// pages/cityWide/matronPrepon/matronPrepon.js
const app = getApp();
Page({
/**
* 页面的初始数据
*/
data: {
page: 1,
matronCon:[],
priIndex: 0,
ageIndex: 0,
studyIndex: 0,
orgIndex: 0,
fourthid: '',
conPrice: ['工种', '月嫂', '育儿嫂'],
conAge: ['年龄', '35岁以下', '35~45岁', '45岁以上'],
conStudy: ['经验', '初级', '中级', '高级', '金牌', '首席'],
conOrgan: []
},
/**
* 生命周期函数--监听页面加载
*/
onLoad: function (options) {
this.getMatronlist()
},
// 获取优选月嫂列表
getMatronlist: function(){
let that = this;
let url = "/api/portal/Maternity/index";
let params = {
first: that.data.priIndex,
second: that.data.ageIndex,
third: that.data.studyIndex,
fourth: that.data.fourthid,
page: that.data.page
}
app.post(url, params).then((res) => {
that.setData({
matronCon: res.list,
conOrgan: res.score
})
}).catch((errMsg) => {})
},
//工种下拉
priceTap: function (e) {
let that = this;
that.setData({
priIndex: e.detail.value
})
that.getMatronlist()
},
//年龄下拉
ageTap: function (e) {
let that = this;
that.setData({
ageIndex: e.detail.value
})
that.getMatronlist()
},
//经验下拉
studyTap: function (e) {
let that = this;
that.setData({
studyIndex: e.detail.value
})
that.getMatronlist()
},
//机构下拉
organTap: function (e) {
let that = this;
that.setData({
orgIndex: e.detail.value,
fourthid: that.data.conOrgan[e.detail.value].id
})
that.getMatronlist()
},
//跳转到 月嫂详情
detailTap: function (e) {
let maternityId = e.currentTarget.dataset.maternityid;
wx.navigateTo({
url: '../matronDetail/matronDetail?maternityId=' + maternityId,
})
},
//跳转到 一键找月嫂
findTap: function (e) {
wx.navigateTo({
url: '../keyFind/keyFind',
})
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady: function () {
},
/**
* 生命周期函数--监听页面显示
*/
onShow: function () {
},
/**
* 生命周期函数--监听页面隐藏
*/
onHide: function () {
},
/**
* 生命周期函数--监听页面卸载
*/
onUnload: function () {
},
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh: function () {
},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom: function () {
},
/**
* 用户点击右上角分享
*/
onShareAppMessage: function () {
}
})
... ...
{
"navigationBarTitleText": "优选月嫂",
"navigationBarTextStyle": "white"
}
\ No newline at end of file
... ...
<!-- 优选月嫂页面 -->
<view class='matron_head'>
<view class='matron_txt'>一键免费定制,找到满意的月嫂</view>
<view class='matron_btn' bindtap='findTap'>立即定制</view>
</view>
<!-- begin:选择框下拉 -->
<view class='matron_menu'>
<!-- begin:工种下拉 -->
<view class='matron_list'>
<picker bindchange="priceTap" value="{{priIndex}}" range="{{conPrice}}">
<view class="picker">
{{conPrice[priIndex]}}<image class='matron_img' src='http://bronet.ibaby88.cn/aicon01@2x.png'></image>
</view>
</picker>
</view>
<!-- begin:年龄下拉 -->
<view class='matron_list'>
<picker bindchange="ageTap" value="{{ageIndex}}" range="{{conAge}}">
<view class="picker">
{{conAge[ageIndex]}}<image class='matron_img' src='http://bronet.ibaby88.cn/aicon01@2x.png'></image>
</view>
</picker>
</view>
<!-- begin:经验下拉 -->
<view class='matron_list'>
<picker bindchange="studyTap" value="{{studyIndex}}" range="{{conStudy}}">
<view class="picker">
{{conStudy[studyIndex]}}<image class='matron_img' src='http://bronet.ibaby88.cn/aicon01@2x.png'></image>
</view>
</picker>
</view>
<!-- begin:机构下拉 -->
<view class='matron_list'>
<picker bindchange="organTap" value="{{orgIndex}}" range="{{conOrgan}}" range-key='title'>
<view class="picker">
{{conOrgan[orgIndex].title}}<image class='matron_img' src='http://bronet.ibaby88.cn/aicon01@2x.png'></image>
</view>
</picker>
</view>
</view>
<!-- begin:列表信息 -->
<view class="nodata" wx:if="{{matronCon.length==0}}">暂无数据</view>
<view wx:else>
<view class='matron_tab' wx:for="{{matronCon}}" bindtap='detailTap' wx:key="name" data-maternityId="{{item.id}}">
<view class='matron_pic'><image src='{{item.pic}}'></image></view>
<view class='matron_info'>
<view class='matron_name'>{{item.name}}</view>
<view class='matron_detail'>
<text>{{item.age}}岁</text>
<text>{{item.expName}}</text>
<text wx:if="{{item.type==1}}">月嫂</text>
<text wx:if="{{item.type==2}}">育儿嫂</text>
<text>{{item.native}}</text>
</view>
<view class='matron_day'>¥<text class='matron_money'>{{item.money}}</text>/26天</view>
</view>
</view>
</view>
... ...
/* pages/cityWide/matronPrepon/matronPrepon.wxss */
.matron_head{
display: flex;
align-items: center;
justify-content: space-between;
width: 100%;
height: 70rpx;
padding: 0 32rpx;
background: #FD8779;
box-sizing: border-box;
}
.matron_txt{
color: #fff;
font-size: 26rpx;
}
.matron_btn{
display: flex;
align-items: center;
justify-content: center;
width: 137rpx;
height: 46rpx;
color: #fff;
font-size: 24rpx;
border: solid 1rpx #fff;
border-radius: 23rpx;
}
.matron_menu{
display: flex;
align-items: center;
justify-content: space-between;
height: 88rpx;
padding: 0 54rpx;
border-bottom: solid 1rpx #EBEBEB;
}
.matron_list{
display: flex;
align-items: center;
height: 25rpx;
}
.matron_list text,.picker{
color: #292525;
font-size: 30rpx;
}
.matron_img{
width: 10rpx;
height: 10rpx;
margin-left: 10rpx;
}
.matron_tab{
display: flex;
align-items: center;
justify-content: flex-start;
padding: 16rpx 32rpx;
}
.matron_pic{
width: 160rpx;
height: 160rpx;
}
.matron_pic image{
width: 100%;
height: 100%;
}
.matron_info{
padding-left: 32rpx;
}
.matron_name{
color: #252729;
font-size: 30rpx;
font-weight: bold;
}
.matron_detail{
padding: 10rpx 0;
color: #53575C;
font-size: 26rpx;
}
.matron_detail text{
margin-left:10rpx;
}
.matron_detail text:first-child{
margin-left:0;
}
.matron_day{
color: #FD8779;
font-size: 24rpx;
}
.matron_money{
font-size: 30rpx;
font-weight: 500;
}
\ No newline at end of file
... ...
// pages/cityWide/matronStrategy/matronStrategy.js
const app=getApp();
var WxParse = require('../../../wxParse/wxParse.js');
Page({
/**
* 页面的初始数据
*/
data: {
wxtary: 'honey588',
reveal: false,
monthCon: [{
id: "01",
mtitle: "找月嫂全攻略",
content: "你满意的月嫂,得这样找",
imagesUrl: "http://pi4orwnti.bkt.clouddn.com/bicon34@2x.png"
}, {
id: "02",
mtitle: "图说月嫂",
content: "三张图告诉你月嫂都干了些什么?",
imagesUrl: "http://pi4orwnti.bkt.clouddn.com/bicon34@2x.png"
}, {
id: "03",
mtitle: "教你如何面试月嫂",
content: "面试月嫂需要注意啥?最全参考在这里",
imagesUrl: "http://pi4orwnti.bkt.clouddn.com/bicon34@2x.png"
}],
strateCon: [{
id: "01",
ntitle: "随心退",
contents: "定金可退,上户后不满意可随时更换同等级月嫂,或按剩余天数退款"
}, {
id: "02",
ntitle: "监督服务",
contents: "如遇到问题,可联系您的小秘书,如确认是机构方的错误,ibaby8会扣除机构的保障金来补偿您..."
}, {
id: "03",
ntitle: "会员福利",
contents: "赠送价值1000元的产后代金券。"
}],
content:'',
secretary:''
},
/**
* 生命周期函数--监听页面加载
*/
onLoad: function (options) {
this.yuesao()
},
yuesao(){
let that = this;
var url = '/api/portal/Strategy/index';
var params = {
// token: wx.getStorageSync('token'),
}
app.post(url, params).then((res) => {
console.log(res);
that.setData({
content:res,
monthCon: res.strategy
})
WxParse.wxParse('article', 'html', res.buttom, that, 5)
}).catch((err) => {
})
},
// 点击领取福利
tapDraw: function(){
let that = this;
that.setData({
reveal: true
})
var url = '/api/portal/Strategy/call';
var params = {
// token: wx.getStorageSync('token'),
}
app.post(url, params).then((res) => {
console.log(res);
that.setData({
wxtary: res.secretary
})
}).catch((err) => {
})
},
// 隐藏小秘书弹层
tapHide: function(){
let that = this;
that.setData({
reveal: false
})
},
// 一键复制
bindCopy: function () {
let that = this;
wx.setClipboardData({
data: that.data.wxtary,
success: function (res) {
console.log("复制成功")
}
})
},
//跳转
jumpmonth_list(e) {
let that = this;
let url = e.currentTarget.dataset.link;
wx.navigateTo({
url: '../../sharepage/sharepage?url=' + url,
})
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady: function () {
},
/**
* 生命周期函数--监听页面显示
*/
onShow: function () {
},
/**
* 生命周期函数--监听页面隐藏
*/
onHide: function () {
},
/**
* 生命周期函数--监听页面卸载
*/
onUnload: function () {
},
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh: function () {
},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom: function () {
},
/**
* 用户点击右上角分享
*/
onShareAppMessage: function () {
}
})
... ...
{
"navigationBarTitleText": "月嫂攻略",
"navigationBarTextStyle": "white"
}
\ No newline at end of file
... ...
<import src="../../../wxParse/wxParse.wxml"/>
<!-- 月嫂攻略页面 -->
<view class='month_img'><image src='{{content.banner[0].image}}'></image></view>
<!-- being:列表信息 -->
<view class='month_box'>
<view class='month_list' wx:for="{{monthCon}}" wx:key="" bindtap="jumpmonth_list" data-link="{{item.link}}">
<view class='month_info'>
<view class='month_title'>{{item.title}}</view>
<view class='month_con'>{{item.description}}</view>
</view>
<view class='month_pic'><image src='{{item.pic}}'></image></view>
</view>
</view>
<!-- begin:特殊保障 -->
<view class='strate_box'>
<!-- <view class='strate_menu'>特殊保障&福利</view>
<view class='strate_info' wx:for="{{strateCon}}" wx:key="">
<view class='strate_title'>{{item.ntitle}}</view>
<view class='strate_txt'>{{item.contents}}</view>
</view> -->
<template is="wxParse" data="{{wxParseData:article.nodes}}"/>
</view>
<!-- begin:按钮 -->
<view class='month_btn' bindtap='tapDraw'>领取福利</view>
<!-- begin小秘书弹层 -->
<view class='clerk_fn' wx:if="{{reveal}}" bindtap='tapHide'>
<view class='clerk_box'>
<view class='clerk_name'>小秘书微信号:{{wxtary}}</view>
<view class='clerk_con'>点击一键复制微信号,添加小秘书为好友</view>
<view class='clerk_con'>拉你进“找月嫂&育儿嫂群”,免费领取面试秘籍</view>
<view class='clerk_con'>也可联系小秘书,个性化定制最符合您要求的月嫂</view>
<view class='clerk_btn' catchtap='bindCopy'>一键复制</view>
</view>
</view>
... ...
/* pages/cityWide/matronStrategy/matronStrategy.wxss */
@import '../../../style/base.wxss';
.month_img{
width: 750rpx;
height: 360rpx;
}
.month_img image{
width: 100%;
height: 100%;
}
.month_box{
padding: 0 32rpx;
}
.month_list{
display: flex;
align-items: center;
justify-content: space-between;
padding: 16rpx 10rpx;
border-bottom: solid 1rpx #EBEBEB;
}
.month_title{
padding-bottom: 20rpx;
color: #252729;
font-size: 30rpx;
font-weight: bold;
}
.month_con{
color: #53575C;
font-size: 26rpx;
}
.month_pic{
width: 160rpx;
height: 160rpx;
}
.month_pic image{
width: 100%;
height: 100%;
}
.month_btn{
display: flex;
align-items: center;
justify-content: center;
width: 686rpx;
height: 80rpx;
margin: 32rpx auto;
color: #fff;
font-size: 30rpx;
border-radius: 40rpx;
background: #FD8779;
}
.strate_box{
border-top: solid 16rpx #FCF8F7;
}
.strate_menu{
display: flex;
align-items: center;
height: 80rpx;
padding-left: 36rpx;
color: #292525;
font-size: 26rpx;
font-weight: bold;
border-bottom: solid 1rpx #EBEBEB;
}
.strate_info{
padding: 36rpx 32rpx 0;
}
.strate_title{
padding-bottom: 10rpx;
color: #252729;
font-size: 28rpx;
}
.strate_txt{
color: #53575C;
font-size: 26rpx;
line-height: 40rpx;
}
.strate_box{
padding: 36rpx 32rpx;
}
.wxParse-p{
color:#53575C;
font-size: 26rpx;
padding: 21rpx 0 0;
line-height: 1.5;
}
.WxEmojiView wxParse-inline{
color:#252729;
font-size: 28rpx;
}
.clerk_box{
height:600rpx;
}
\ No newline at end of file
... ...
// pages/cityWide/monthClub/monthClub.js
const app=getApp();
var WxParse = require('../../../wxParse/wxParse.js');
Page({
/**
* 页面的初始数据
*/
data: {
monthCon:[{
id: "01",
mtitle: "找月嫂全攻略",
content: "你满意的月嫂,得这样找",
imagesUrl: "http://pi4orwnti.bkt.clouddn.com/bicon34@2x.png"
}, {
id: "02",
mtitle: "图说月嫂",
content: "三张图告诉你月嫂都干了些什么?",
imagesUrl: "http://pi4orwnti.bkt.clouddn.com/bicon34@2x.png"
}, {
id: "03",
mtitle: "教你如何面试月嫂",
content: "面试月嫂需要注意啥?最全参考在这里",
imagesUrl: "http://pi4orwnti.bkt.clouddn.com/bicon34@2x.png"
}],
freegetwrap:false,
secretary:''
},
/**
* 生命周期函数--监听页面加载
*/
onLoad: function (options) {
this.yuesisuo()
},
yuesisuo(){
let that = this;
var url = '/api/portal/Club/index';
var params = {
// token: wx.getStorageSync('token'),
}
app.post(url, params).then((res) => {
console.log(res);
that.setData({
content:res,
monthCon: res.strategy,
})
WxParse.wxParse('article', 'html', res.buttom, that, 5)
}).catch((err) => {
})
},
freeget(){
let that=this;
that.setData({
freegetwrap:true
})
var url = '/api/portal/Club/call';
var params = {
// token: wx.getStorageSync('token'),
}
app.post(url, params).then((res) => {
console.log(res);
that.setData({
secretary: res.secretary
})
}).catch((err) => {
})
},
hidefreeget(){
this.setData({
freegetwrap: false
})
},
//复制
copycode: function () {
console.log(666)
let that = this;
wx.setClipboardData({
data: that.data.secretary,
success: function (res) {
// console.log("复制成功")
}
})
},
//跳转
jumpmonth_list(e) {
let that = this;
let url = e.currentTarget.dataset.link;
wx.navigateTo({
url: '../../sharepage/sharepage?url=' + url,
})
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady: function () {
},
/**
* 生命周期函数--监听页面显示
*/
onShow: function () {
},
/**
* 生命周期函数--监听页面隐藏
*/
onHide: function () {
},
/**
* 生命周期函数--监听页面卸载
*/
onUnload: function () {
},
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh: function () {
},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom: function () {
},
/**
* 用户点击右上角分享
*/
onShareAppMessage: function () {
}
})
... ...
{
"navigationBarTitleText": "月子会所",
"navigationBarTextStyle": "white"
}
\ No newline at end of file
... ...
<import src="../../../wxParse/wxParse.wxml"/>
<!-- 月子会所页面 -->
<view class='month_img'><image src='{{content.banner[0].image}}'></image></view>
<!-- begin:获取探店手册 -->
<view class='month_menu'>
<view class='month_peo'><image src='http://bronet.ibaby88.cn/dicon09@2x.png'></image></view>
<view class='month_left'>
<!-- <view class='book_title'>获取免费探店手册</view>
<view class='book_con'>知晓最新价格优惠/梳理月子会所考察点/体验会所相关服务</view> -->
<template is="wxParse" data="{{wxParseData:article.nodes}}"/>
</view>
<view class='book_btn' bindtap="freeget">了解一下</view>
</view>
<!-- being:列表信息 -->
<view class='month_box'>
<view class='month_list' wx:for="{{monthCon}}" wx:key="" bindtap="jumpmonth_list" data-link="{{item.link}}">
<view class='month_info'>
<view class='month_title'>{{item.title}}</view>
<view class='month_con'>{{item.description}}</view>
</view>
<view class='month_pic'><image src='{{item.pic}}'></image></view>
</view>
</view>
<!-- begin:按钮 -->
<view class='month_btn' bindtap="freeget">免费领取探店手册</view>
<!-- begin:小秘书弹层 -->
<view class='manual_fn' wx:if="{{freegetwrap}}" bindtap="hidefreeget">
<view class='manual_box'>
<view class='manual_head'>
<view class='manual_txt'>添加小顾问为好友</view>
<view class='manual_txt'>免费获取月子会所探店手册及优惠信息</view>
</view>
<view class='manual_title'>月子会所小顾问</view>
<view class='manaul_con'>复制小顾问微信号:{{secretary}}并添加好友</view>
<view class='manaul_btn' catchtap='copycode'>复制微信号</view>
</view>
</view>
... ...
/* pages/cityWide/monthClub/monthClub.wxss */
.month_img{
width: 750rpx;
height: 360rpx;
}
.month_img image{
width: 100%;
height: 100%;
}
.month_menu{
display: flex;
align-items: center;
justify-content: flex-start;
padding: 22rpx 32rpx;
border-bottom: solid 1rpx #EBEBEB;
}
.month_peo{
width: 109rpx;
height: 124rpx;
}
.month_peo image{
width: 100%;
height: 100%;
}
.month_left{
padding-left: 18rpx;
}
.book_title{
padding-bottom: 20rpx;
color: #FD8779;
font-size: 32rpx;
font-weight: bold;
}
.book_con{
width: 346rpx;
line-height: 40rpx;
color: #5C5453;
font-size: 24rpx;
}
.WxEmojiView{
color: #5C5453;
font-size: 24rpx;
}
.book_btn{
display: flex;
align-items: center;
justify-content: center;
width: 164rpx;
height: 60rpx;
margin-left: 32rpx;
color: #FD8779;
font-size: 26rpx;
border: solid 1rpx #FD8779;
border-radius: 30rpx;
}
.month_box{
padding: 0 32rpx;
}
.month_list{
display: flex;
align-items: center;
justify-content: space-between;
padding: 16rpx 10rpx;
border-bottom: solid 1rpx #EBEBEB;
}
.month_title{
padding-bottom: 20rpx;
color: #252729;
font-size: 30rpx;
font-weight: bold;
}
.month_con{
color: #53575C;
font-size: 26rpx;
}
.month_pic{
width: 160rpx;
height: 160rpx;
}
.month_pic image{
width: 100%;
height: 100%;
}
.month_btn{
display: flex;
align-items: center;
justify-content: center;
width: 686rpx;
height: 80rpx;
margin: 32rpx auto;
color: #fff;
font-size: 30rpx;
border-radius: 40rpx;
background: #FD8779;
}
/* 小秘书弹层 */
.manual_fn{
position: fixed;
top: 0;
left: 0;
right: 0;
width: 100%;
height: 100%;
background: rgba(0, 0, 0, 0.4);
z-index: 10;
}
.manual_box{
position: absolute;
bottom: 18rpx;
left: 0;
right: 0;
width: 718rpx;
margin: 0 auto;
padding-bottom: 33rpx;
border-radius: 36rpx;
background: #fff;
}
.manual_head{
width: 718rpx;
padding: 35rpx 0;
background: #FD8779;
border-radius: 36rpx 36rpx 0 0;
}
.manual_txt{
padding-bottom: 5rpx;
color: #fff;
font-size: 28rpx;
text-align: center;
}
.manual_title{
padding: 162rpx 0 28rpx;
color: #FD8779;
font-size: 30rpx;
font-weight: bold;
text-align: center;
}
.manaul_con{
padding-bottom: 195rpx;
color: #FD8779;
font-size: 28rpx;
text-align: center;
}
.manaul_btn{
display: flex;
align-items: center;
justify-content: center;
width: 652rpx;
height: 82rpx;
margin: 0 auto;
color: #FD8779;
font-size: 30rpx;
background: #F7F7F7;
border: solid 1rpx #E2E2E2;
border-radius: 40rpx;
}
\ No newline at end of file
... ...
// pages/cityWide/monthDetail/monthDetail.js
const app = getApp();
var WxParse = require('../../../wxParse/wxParse.js');
Page({
/**
* 页面的初始数据
*/
data: {
activeid: '',
currTab: 0,
// monthStatr: true,
detailCon: '',
detailAddr: '',
imgCourse: [],
isFocus: false,
monthCon: '',
activeStau: 1,
addrestatus:'',
talkpeople: '',
lng:'',
lat:'',
code:false,
codeimg:''
},
/**
* 生命周期函数--监听页面加载
*/
onLoad: function (options) {
console.log(options)
let that = this;
let activeid = options.activeid;
that.setData({
activeid: activeid
})
// that.getDetail()
},
// 活动详情接口
getDetail: function(e){
let that = this;
let url = "/api/portal/Activity/detail";
let params = {
token: wx.getStorageSync('token'),
activityId: that.data.activeid
}
var header={
'token': wx.getStorageSync('token'),
}
app.post(url, params,header).then((res) => {
console.log(res)
WxParse.wxParse('article', 'html', res.activity.content, that, 5)
let statu = res.activity.is_save;
let activeType = res.activity.activity_type;
let isJoin = res.activity.is_join;
if (statu == 1){
that.setData({
isFocus: true
})
} else if (statu == 2){
that.setData({
isFocus: false
})
}
//报名人数
console.log(typeof(res.activity.sign))
if (res.activity.sign==null){
res.activity.sign=0
}
// 1是活动 2是微课 1是已报名 2是未报名
if (activeType == 1 && isJoin ==2) {
that.setData({
activeStau:1,
addrestatus:true,
talkpeople:false,
iconshow:true
})
wx.setNavigationBarTitle({
title: '活动详情' //页面切换,更换页面标题
})
} else if (activeType == 2 && isJoin ==2){
that.setData({
activeStau:2,
addrestatus: false,
talkpeople: true,
iconshow:false
})
wx.setNavigationBarTitle({
title: '微课详情' //页面切换,更换页面标题
})
} else if (activeType == 1 && isJoin == 1) {
that.setData({
activeStau: 3,
addrestatus: true,
talkpeople: false,
iconshow: true
})
wx.setNavigationBarTitle({
title: '活动详情' //页面切换,更换页面标题
})
} else if (activeType == 2 && isJoin == 1) {
that.setData({
activeStau: 4,
addrestatus: false,
talkpeople: true,
iconshow: false
})
wx.setNavigationBarTitle({
title: '微课详情' //页面切换,更换页面标题
})
}
that.setData({
detailCon: res.activity,
detailAddr: res.activity.addr,
imgCourse: res.sign,
monthCon: res.mes,
lng: res.activity.latng[0],
lat: res.activity.latng[1],
is_write:res.is_write
})
console.log(that.data.detailCon)
}).catch((errMsg) => {})
},
//链接去地图
gomap() {
console.log(88)
let that = this;
console.log(that.data.lat)
console.log(that.data.lng)
wx.getLocation({//获取当前经纬度
type: 'wgs84', //返回可以用于wx.openLocation的经纬度,官方提示bug: iOS 6.3.30 type 参数不生效,只会返回 wgs84 类型的坐标信息
success: function (res) {
wx.openLocation({//​使用微信内置地图查看位置。
latitude: Number(that.data.lat),//要去的纬度-地址
longitude: Number(that.data.lng),//要去的经度-地址
name: that.data.detailCon.addr.addr,
address: that.data.detailCon.addr.addr,
})
}
})
console.log(that.data.lng)
},
// 点击切换
clickTab: function (e) {
var that = this;
if (that.data.currTab === e.target.dataset.current) {
return false;
} else {
that.setData({
currTab: e.target.dataset.current
})
}
},
// 跳转到 活动报名
activityTap:function(){
wx.navigateTo({
url: '../activityName/activityName?activeid=' + this.data.activeid,
})
},
//微课报名
listenlesson(){
let is_write = this.data.is_write;
if(is_write==1){
wx.navigateTo({
url: '../WeChatCulum/WeChatCulum?activeid=' + this.data.activeid,
})
}else{
wx.navigateTo({
url: '../../home/stageofpregnancy/stageofpregnancy',
})
}
},
submit: function (e) {
console.log(e)
console.log(typeof(e.detail.formId));
let that=this;
// let formId = e.detail.formId;
let is_write = that.data.is_write;
if (is_write == 1) {
var url = '/api/portal/Activity/joinCourse';
var params = {
token: wx.getStorageSync('token'),
activityId: this.data.activeid,
formId: e.detail.formId
}
app.post(url, params).then((res) => {
console.log(res);
wx.navigateTo({
url: '../WeChatCulum/WeChatCulum?activeid=' + this.data.activeid,
})
}).catch((err) => {
})
} else {
wx.navigateTo({
url: '../../home/stageofpregnancy/stageofpregnancy',
})
}
},
// 跳转到 报名名单
listTap:function(){
wx.navigateTo({
url: '../nameList/nameList?activeid=' + this.data.activeid,
})
},
// 跳转到 发表点评
markTap:function(){
wx.navigateTo({
url: '../remark/remark?activeid=' + this.data.activeid,
})
},
// 跳转到 微信直播课程
lectureTap: function(){
wx.navigateTo({
url: '../WeChatCulum/WeChatCulum?activeid=' + this.data.activeid,
})
},
// 点击收藏成功
favoriteTab: function (e) {
let that = this;
let isFocus = that.data.isFocus;
let url = "/api/portal/Activity/save";
let params = {
token: wx.getStorageSync('token'),
activityId: that.data.activeid
}
app.post(url, params).then((res) => {
wx.showToast({
title: "收藏成功",
icon: 'success',
duration: 1000
});
that.setData({
isFocus: true
})
}).catch((errMsg) => {})
},
// 取消收藏
cancelCollect: function(e){
let that = this;
let isFocus = that.data.isFocus;
let url = "/api/portal/Activity/saveDel";
let params = {
token: wx.getStorageSync('token'),
activityId: that.data.activeid
}
app.post(url, params).then((res) => {
wx.showToast({
title: "取消收藏",
icon: 'success',
duration: 1000
});
that.setData({
isFocus: false
})
}).catch((errMsg) => { })
},
//微课二维码
seecode(){
let that = this;
that.setData({
code:true
})
var url = '/api/portal/Activity/pic';
var params = {
token: wx.getStorageSync('token'),
activityId: that.data.activeid
}
app.post(url, params).then((res) => {
console.log(res);
that.setData({
codeimg:res.url
})
}).catch((err) => {
})
},
hidecode(){
this.setData({
code:false
})
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady: function () {
},
/**
* 生命周期函数--监听页面显示
*/
onShow: function () {
this.getDetail()
},
/**
* 生命周期函数--监听页面隐藏
*/
onHide: function () {
},
/**
* 生命周期函数--监听页面卸载
*/
onUnload: function () {
},
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh: function () {
},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom: function () {
},
/**
* 用户点击右上角分享
*/
onShareAppMessage: function () {
let that = this;
let activeid = that.data.activeid;
console.log(activeid)
return {
title: '活动详情分享', // 转发后 所显示的title
// path: '/pages/home/buildtextdetail/buildtextdetail?buildid='+buildid+'&gettoken='+newtoken, // 相对的路径
path:'/pages/index/index?activeid='+activeid +'&status='+5,//微课详情
// path: '/pages/index/index?childrenid',
success: (res) =>{ // 成功后要做的事情
console.log(res)
// console.log(res.shareTickets[0])
// console.log
// wx.getShareInfo({
// shareTicket: res.shareTickets[0],
// success: (res)=> {
// that.setData({
// isShow:true
// })
// console.log(that.setData.isShow)
// },
// fail: function (res) { console.log(res) },
// complete: function (res) { console.log(res) }
// })
},
fail: function (res) {
// 分享失败
console.log(res)
}
}
}
})
... ...
{
"navigationBarTitleText": "活动详情",
"navigationBarTextStyle": "white"
}
\ No newline at end of file
... ...
<view class="register" wx:if="{{code}}" bindtap="hidecode">
<view class="registerwrap">
<image src="{{codeimg}}"></image>
</view>
</view>
<!-- 月子会所活动详情页面 -->
<import src="../../../wxParse/wxParse.wxml"/>
<view class='detail_head'>
<image class='detail_img' src='{{detailCon.pic}}'></image>
<view class='detail_witer'>
<view class='detail_title'>{{detailCon.title}}</view>
<view class='detail_free' wx:if="{{detailCon.money==0}}">免费</view>
<view class='detail_free' wx:else>{{detailCon.money}}</view>
<!-- begin:判断是否显示日期 -->
<view class='detail_flex' wx:if="{{talkpeople}}">
<view class='detail_date'>
<image class='date_img' src='http://bronet.ibaby88.cn/dicon12@2x.png'></image>
{{detailCon.start_time}}
</view>
<view class='detail_name' >主讲人:{{detailCon.talking}}</view>
</view>
<view class='detail_flex' wx:else>
<view class='detail_date'>
<image class='date_img' src='http://bronet.ibaby88.cn/dicon12@2x.png'></image>
{{detailCon.start_time}} - {{detailCon.end_time}}
</view>
</view>
</view>
</view>
<!-- begin:判断是活动或者微课 是否显示地址 -->
<view class='month_addres' wx:if="{{addrestatus}}" bindtap="gomap">
<view class='addres_img'><image src='http://bronet.ibaby88.cn/dicon10@2x.png'></image></view>
<view class='addres_box'>
<text class='addres_txt'>{{detailAddr.addr}}</text>
<image class='interest_arrow' src='http://bronet.ibaby88.cn/bicon08@2x.png'></image>
</view>
</view>
<view wx:else></view>
<view class='interest_box' bindtap='listTap'>
<view class='interest_right'>
<image class='interest_img' src='http://bronet.ibaby88.cn/dicon11@2x.png'></image>
<text class='interest_txt'>{{detailCon.interest}}兴趣 . {{detailCon.sign}}报名</text>
</view>
<!-- begin:判断条件,如果头像大于3 -->
<view class='interest_left' wx:if='{{imgCourse.length>=3}}'>
<view class='interest_menu'>
<view class='interest_pic' wx:for='{{imgCourse}}' wx:key="name">
<image src='{{item.pic}}'></image>
</view>
</view>
<view>...</view>
<image class='interest_arrow' src='http://bronet.ibaby88.cn/bicon08@2x.png'></image>
</view>
<!-- begin:否则 -->
<view class="intreimg" wx:else>
<view class='interest_menu interest_wid'>
<view class='interest_pic' wx:for='{{imgCourse}}' wx:key="name">
<image src='{{item.pic}}'></image>
</view>
</view>
<image class='interest_arrow' src='http://bronet.ibaby88.cn/bicon08@2x.png'></image>
</view>
</view>
<!-- begin:切换头部 -->
<view class='nav_head'>
<view class="nav_item {{currTab==0?'active':''}}" data-current="0" bindtap='clickTab'>
<text class="iconfont intro {{iconshow==true?'icon-qiqiu':''}}" data-current="0" bindtap='clickTab' wx:if="{{iconshow}}">活动介绍</text>
<text class="iconfont intro{{iconshow==true?'icon-qiqiu':''}}" data-current="0" bindtap='clickTab' wx:else>详情</text>
<!--<text wx:else>详情</text>-->
</view>
<view class="nav_item {{currTab==1?'active':''}}" data-current="1" bindtap='clickTab'>
<text class="iconfont {{iconshow==true?'icon-liaotian':''}}" data-current="1" bindtap='clickTab'></text>交流
</view>
</view>
<!-- begin:切换内容 -->
<view class='month_info' wx:if="{{currTab==0}}">
<template is="wxParse" data="{{wxParseData:article.nodes}}"/>
<!-- <image class='test_img' src='http://bronet.ibaby88.cn/cpic03@2x.png'></image> -->
<!-- begin:活动介绍底部 -->
<view class='foot_page'>
<view class='foot_info'>
<view class='foot_list' bindtap='cancelCollect' wx:if="{{isFocus}}">
<image class='coll_img' src='http://bronet.ibaby88.cn/bicon29@2x.png'></image>
<view class='foot_text'>收藏</view>
</view>
<view class='foot_list' bindtap='favoriteTab' wx:else>
<image class='coll_img' src='http://bronet.ibaby88.cn/bicon28@2x.png'></image>
<view class='foot_text'>收藏</view>
</view>
<view class='foot_list' >
<view class="meshare">
<image class='collect' src='http://bronet.ibaby88.cn/share.png' ></image>
<view class='foot_text sharetext' >分享</view>
</view>
<button class="sharebtn" open-type="share"></button>
</view>
</view>
<block wx:if="{{activeStau==1}}"><view class='foot_btn' bindtap='activityTap'>我要报名</view></block>
<block wx:if="{{activeStau==2}}">
<!-- <view class='foot_btn' bindtap='listenlesson'>我要听课</view> -->
<form bindsubmit="submit" report-submit='true' >
<view class='foot_btn'>
我要听课
<button form-type="submit" type="default" class="want"></button>
</view>
</form>
</block>
<block wx:if="{{activeStau==3}}"><view class='foot_btn'>已报名</view></block>
<block wx:if="{{activeStau==4}}"><view class='foot_btn' bindtap='lectureTap'>已报名,查看二维码</view></block>
</view>
</view>
<!-- begin:交流 -->
<view class='month_foot' wx:if="{{currTab==1}}">
<block wx:if="{{monthCon.length == 0}}">
<view class='month_pic'><image src='http://bronet.ibaby88.cn/nopic.png'></image></view>
<view class='month_txt'>暂无交流,来做第一个吧</view>
</block>
<view class='month_tab' wx:else>
<view class='month_box' wx:for="{{monthCon}}" wx:key="">
<view class='month_img'><image src='{{item.user_pic}}'></image></view>
<view class='month_menu'>
<view class='month_name'>{{item.user_name}}</view>
<view class='month_date'>{{item.create_time}}</view>
<view class='month_con'>{{item.content}}</view>
<view wx:if="{{item.is_commoned==2}}"></view>
<view wx:else class='comm_box'>平台回复:{{item.commoned}}</view>
</view>
</view>
</view>
<view class='warp_btn' bindtap='markTap'>发表点评</view>
</view>
... ...