作者 朱振飞

1213

正在显示 52 个修改的文件 包含 1225 行增加167 行删除
... ... @@ -59,7 +59,11 @@ App({
} else if (res.data.code == '201') {
resolve(res.data);
} else {
console.log(res)
wx.showToast({
title: res.data.msg,
duration: 1200,
icon:'none'
})
reject(res)
}
... ... @@ -151,6 +155,7 @@ App({
},
globalData: {
userInfo: null,
url:'http://winesbook.cn/static/images_mini/'
url:'http://winesbook.cn/static/images_mini/',
baseUrl:'https://winesbook.cn/api'
}
})
\ No newline at end of file
... ...
... ... @@ -39,7 +39,14 @@
"pages/findblock/zhuanjiapinjiudetail/zhuanjiapinjiudetail",
"pages/findblock/niangjiushi/niangjiushi",
"pages/findblock/jiudandetail/jiudandetail",
"pages/myblock/history/history"
"pages/myblock/history/history",
"pages/myblock/jiupin/jiupin",
"pages/myblock/pinpai/pinpai",
"pages/myblock/company/company",
"pages/myblock/message/message",
"pages/myblock/feedback/feedback",
"pages/myblock/rule/rule",
"pages/myblock/about/about"
],
"window": {
"backgroundTextStyle": "light",
... ...
@font-face {font-family: "iconfont";
@font-face {
font-family: "iconfont";
src: url('//at.alicdn.com/t/font_1185667_ds07xvngh3k.eot?t=1557490149623'); /* IE9 */
src: url('//at.alicdn.com/t/font_1185667_ds07xvngh3k.eot?t=1557490149623#iefix') format('embedded-opentype'), /* IE6-IE8 */
url('data:application/x-font-woff2;charset=utf-8;base64,d09GMgABAAAAAAJ4AAsAAAAABiAAAAItAAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAHEIGVgCCcAooRwE2AiQDCAsGAAQgBYRtBzEbbgXInpo8CQBIEAKw5OZZAMTD9/v9b+1zz1NNXxTzaBJFExlPJNEqFptWpnvEM0P7d//nMgdo757P88fyFNGAfSG/5fSl6QDVnJ5SE3ITbm/9Qwq8v752fZ5r6iXQgeQHmmsHRSUlBdDeeEAD7MLRkW0gQ98wdsELfE6gaU5P6ejxkxtoyux1gbhx1bOgWYjKMivUhWrD0Sxeqainx+kDXkbfj792RZ2kUrBbTl1auzD7wSkpHpWPXAwIMQI6XUGBLUAmzjVmT6gIxlU0s1VL4FiNwQ9lGXjEUZ2C/XV2fRvMwFzwg7dWgASPRRluT1KAqN49Re6l1+3sX7v38OPlfx0EKN+ntcoB8qvg1rf+6+39V29l8PFPvkfh8n02zA/q6/mC91cPHMiG1nanrKkbx5Pqftuamijh4NDvVNvkZMVQN5ngr5nNUKhbITO7BRUte1BVdwBNm21Pt4yIisgNbPIJEPq+kHS9RqHvm8zsDyqm/lDVjwJNF2J0Zcu6uNo8cpMsJRftJwwcTo3r1XbceEVeEVuS10b8HUkeJHC8bUe5sKWUZIkd+b03UTVohBPcgNcojhkz4ZAcHfiq2XS4/VKTQgOHE2g7QhCLIi5ke4ICDpYywWTVrnz+CvEUYhbp6Kur3iEiF8yOxgZGA8itKR3U9yjv5O55JpQykCFYAm3AIhKLMZQ1LwoRhxrwJ6QzU0NnlBlqGmxvSf7uFDTZ9hTO3ELt2lUrVS4AAAA=') format('woff2'),
src: url('//at.alicdn.com/t/font_1185667_ds07xvngh3k.eot?t=1557490149623#iefix') format('embedded-opentype'),
/* IE6-IE8 */ url('data:application/x-font-woff2;charset=utf-8;base64,d09GMgABAAAAAAJ4AAsAAAAABiAAAAItAAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAHEIGVgCCcAooRwE2AiQDCAsGAAQgBYRtBzEbbgXInpo8CQBIEAKw5OZZAMTD9/v9b+1zz1NNXxTzaBJFExlPJNEqFptWpnvEM0P7d//nMgdo757P88fyFNGAfSG/5fSl6QDVnJ5SE3ITbm/9Qwq8v752fZ5r6iXQgeQHmmsHRSUlBdDeeEAD7MLRkW0gQ98wdsELfE6gaU5P6ejxkxtoyux1gbhx1bOgWYjKMivUhWrD0Sxeqainx+kDXkbfj792RZ2kUrBbTl1auzD7wSkpHpWPXAwIMQI6XUGBLUAmzjVmT6gIxlU0s1VL4FiNwQ9lGXjEUZ2C/XV2fRvMwFzwg7dWgASPRRluT1KAqN49Re6l1+3sX7v38OPlfx0EKN+ntcoB8qvg1rf+6+39V29l8PFPvkfh8n02zA/q6/mC91cPHMiG1nanrKkbx5Pqftuamijh4NDvVNvkZMVQN5ngr5nNUKhbITO7BRUte1BVdwBNm21Pt4yIisgNbPIJEPq+kHS9RqHvm8zsDyqm/lDVjwJNF2J0Zcu6uNo8cpMsJRftJwwcTo3r1XbceEVeEVuS10b8HUkeJHC8bUe5sKWUZIkd+b03UTVohBPcgNcojhkz4ZAcHfiq2XS4/VKTQgOHE2g7QhCLIi5ke4ICDpYywWTVrnz+CvEUYhbp6Kur3iEiF8yOxgZGA8itKR3U9yjv5O55JpQykCFYAm3AIhKLMZQ1LwoRhxrwJ6QzU0NnlBlqGmxvSf7uFDTZ9hTO3ELt2lUrVS4AAAA=') format('woff2'),
url('//at.alicdn.com/t/font_1185667_ds07xvngh3k.woff?t=1557490149623') format('woff'),
url('//at.alicdn.com/t/font_1185667_ds07xvngh3k.ttf?t=1557490149623') format('truetype'), /* chrome, firefox, opera, Safari, Android, iOS 4.2+ */
url('//at.alicdn.com/t/font_1185667_ds07xvngh3k.svg?t=1557490149623#iconfont') format('svg'); /* iOS 4.1- */
url('//at.alicdn.com/t/font_1185667_ds07xvngh3k.ttf?t=1557490149623') format('truetype'),
/* chrome,
firefox,
opera,
Safari,
Android,
iOS 4.2+ */ url('//at.alicdn.com/t/font_1185667_ds07xvngh3k.svg?t=1557490149623#iconfont') format('svg'); /* iOS 4.1- */
}
.iconfont {
font-family: "iconfont" !important;
font-size: 16px;
... ... @@ -23,65 +25,66 @@
content: "\e63f";
}
image{
width:100%;
height:100%;
image {
width: 100%;
height: 100%;
}
/* 遮罩层 */
.register{
.register {
width: 100%;
height: 100%;
background-color: rgba(0,0,0,0.5);
position:fixed;
top:180rpx;
left:0;
right:0;
background-color: rgba(0, 0, 0, 0.5);
position: fixed;
top: 180rpx;
left: 0;
right: 0;
z-index: 5;
}
}
/* 箭头样式 */
/* 箭头样式 */
.listrow{
color:#999999;
.listrow {
color: #999;
font-size: 24rpx;
}
/* 星星图片 */
.starimg{
width:34rpx;
height:32rpx;
font-size: 0
}
.redrow{
width:12rpx;
height:25rpx;
font-size: 0
.starimg {
width: 34rpx;
height: 32rpx;
font-size: 0;
}
.redrow {
width: 12rpx;
height: 25rpx;
font-size: 0;
}
/* 关注 */
.atten{
.atten {
/* width:100rpx; */
padding: 0 20rpx;
height:50rpx;
background:rgba(232,24,37,1);
border-radius:2rpx;
height: 50rpx;
background: rgba(232, 24, 37, 1);
border-radius: 2rpx;
font-size: 26rpx;
color:#fff;
color: #fff;
text-align: center;
line-height: 50rpx;
}
/* 上三角 */
.boxright{
width:26rpx;
height:15rpx;
font-size: 0
}
.noData{
}
/* 上三角 */
.boxright {
width: 26rpx;
height: 15rpx;
font-size: 0;
}
.noData {
height: 360rpx;
width: 750rpx;
text-align: center;
... ... @@ -90,5 +93,15 @@ image{
font-size: 26rpx;
color: #999;
justify-content: center;
}
}
.showall {
color: #999;
font-size: 26rpx;
margin-top: 60rpx;
text-align: center;
}
.nambottom .namebottomitem:first-child {
padding-left: 0;
}
... ...
<view class="wineblock">
<view class="winetitle">浓香酒酿酒大师:沈才宏</view>
<view class="wineimg">
<image src="{{url}}aicon_64.png"></image>
</view>
<view class="winebottom">
<view class="winebottomleft">
<view class="winebottomleftimg">
... ... @@ -14,7 +11,6 @@
<view class="wineeng">WinesBook</view>
</view>
<view class="winebottonright">
<view class="winerighttou">
<view class="winerighttouimg">
<image src="{{url}}aicon_66x.png"></image>
... ... @@ -27,17 +23,13 @@
</view>
<view class="winezan">54</view>
</view>
<view class="winerighttou">
<view class="winerighttouimg">
<image src="{{url}}aicon_68x.png"></image>
</view>
</view>
</view>
</view>
</view>
<view class="wineblock">
... ...
... ... @@ -8,19 +8,30 @@
width:686rpx;
height:300rpx;
margin:30rpx auto 0;
position: relative;
}
.video_play{
position: absolute;
top: 50%;
left: 50%;
width: 80rpx;
height: 80rpx;
transform: translate(-50%,-50%);
-webkit-transform: translate(-50%,-50%);
}
.winebottom{
display:flex;
justify-content: space-between;
align-items: center;
padding: 0 32rpx;
box-sizing: border-box;
margin-top:30rpx;
}
.winebottomleftimg{
width:60rpx;
height:60rpx;
font-size: 0
font-size: 0;
border-radius: 50%;
overflow: hidden;
}
.winebottomleft{
display:flex;
... ... @@ -30,7 +41,7 @@
width:345rpx;
display:flex;
align-items: center;
justify-content: space-around
justify-content: space-between
}
.winerighttouimg{
width:30rpx;
... ... @@ -54,7 +65,8 @@
.wineblock{
border-bottom: 1rpx solid #f5f5f5;
padding-bottom: 30rpx;
margin-top:33rpx;
margin: 33rpx auto 0;
}
.pin{
width:16rpx;
... ...
... ... @@ -126,6 +126,7 @@ image{
padding: 37rpx 31rpx;
box-sizing: border-box;
border-bottom: 1rpx solid #f5f5f5;
background: #FFF;
}
.searchitemleft{
display:flex;
... ...
{
"navigationStyle": "custom",
"usingComponents": {}
"usingComponents": {},
"navigationBarTitleText": "关于我们"
}
\ No newline at end of file
... ...
<view class="headimg">
<image src="{{url}}aicon_87x.png"></image>
<navigator class="peopleinfo" url=''>
<navigator class="peopleinfo" url='/pages/myblock/personpage/personpage'>
<view class="peoplecontent">
<view class="peopleleft">
<image src="{{userInfo.avatar||url+'aicon_77@2x.png'}}"></image>
... ... @@ -44,23 +44,23 @@
<view class="collect">
<view class="mycollect">我的收藏</view>
<view class="collectnum">
<view class="collectitem">
<view class="collectitemnum">19</view>
<navigator url='/pages/myblock/jiupin/jiupin' class="collectitem">
<view class="collectitemnum">{{userInfo.wine_count}}</view>
<view class="collectitemtitle">酒品</view>
</view>
<view class="collectitem">
<view class="collectitemnum">19</view>
</navigator>
<navigator url='/pages/myblock/pinpai/pinpai' class="collectitem">
<view class="collectitemnum">{{userInfo.brand_count}}</view>
<view class="collectitemtitle">品牌</view>
</view>
<view class="collectitem">
<view class="collectitemnum">19</view>
</navigator>
<navigator url='/pages/myblock/jiupin/jiupin' class="collectitem">
<view class="collectitemnum">{{userInfo.wine_rec_count}}</view>
<view class="collectitemtitle">酒企</view>
</view>
</navigator>
</view>
</view>
<view class="mylist">
<navigator class="mylistitem" url="/pages/myblock/personpage/personpage" hover-class="none">
<navigator class="mylistitem" url="/pages/myblock/message/message" hover-class="none">
<view class="mylistleft">
<view class="mylistimage">
<image src="{{url}}aicon_82x.png"></image>
... ... @@ -87,7 +87,7 @@
</view>
<view class="iconfont icon-jiantou listrow"></view>
</navigator>
<navigator class="mylistitem">
<navigator class="mylistitem" url='/pages/myblock/rule/rule'>
<view class="mylistleft">
<view class="mylistimage">
<image src="{{url}}aicon_85x.png"></image>
... ... @@ -96,7 +96,7 @@
</view>
<view class="iconfont icon-jiantou listrow"></view>
</navigator>
<navigator class="mylistitem">
<navigator class="mylistitem" url='/pages/myblock/about/about'>
<view class="mylistleft">
<view class="mylistimage">
<image src="{{url}}aicon_86x.png"></image>
... ...
// pages/myblock/rule/rule.js
let WxParse = require('../../../wxParse/wxParse.js');
const app = getApp();
Page({
/**
* 页面的初始数据
*/
data: {
},
/**
* 生命周期函数--监听页面加载
*/
onLoad: function (options) {
this.getRule();
},
getRule() {
let url = '/index/Common/about';
app.post(url, {}).then(r => {
WxParse.wxParse('contentHtml', 'html', r.content, this, 5)
})
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady: function () {
},
/**
* 生命周期函数--监听页面显示
*/
onShow: function () {
},
/**
* 生命周期函数--监听页面隐藏
*/
onHide: function () {
},
/**
* 生命周期函数--监听页面卸载
*/
onUnload: function () {
},
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh: function () {
},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom: function () {
},
/**
* 用户点击右上角分享
*/
onShareAppMessage: function () {
}
})
\ No newline at end of file
... ...
{
"usingComponents": {},
"navigationBarTitleText": "关于我们"
}
\ No newline at end of file
... ...
<!--pages/myblock/rule/rule.wxml-->
<view class='content'>
<import src="/wxParse/wxParse.wxml" />
<template is="wxParse" data="{{wxParseData:contentHtml.nodes}}" />
</view>
... ...
.content{
font-size: 30rpx;
padding: 30rpx;
color: #666;
}
\ No newline at end of file
... ...
// pages/myblock/company/company.js
Page({
/**
* 页面的初始数据
*/
data: {
},
/**
* 生命周期函数--监听页面加载
*/
onLoad: function (options) {
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady: function () {
},
/**
* 生命周期函数--监听页面显示
*/
onShow: function () {
},
/**
* 生命周期函数--监听页面隐藏
*/
onHide: function () {
},
/**
* 生命周期函数--监听页面卸载
*/
onUnload: function () {
},
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh: function () {
},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom: function () {
},
/**
* 用户点击右上角分享
*/
onShareAppMessage: function () {
}
})
\ No newline at end of file
... ...
{
"usingComponents": {}
}
\ No newline at end of file
... ...
<!--pages/myblock/company/company.wxml-->
<text>pages/myblock/company/company.wxml</text>
... ...
/* pages/myblock/company/company.wxss */
\ No newline at end of file
... ...
// pages/myblock/feedback/feedback.js
const app = getApp();
Page({
/**
* 页面的初始数据
*/
data: {
},
/**
* 生命周期函数--监听页面加载
*/
onLoad: function (options) {
},
inputFeedback(e){
this.setData({
content:e.detail.value
})
},
subFeedBack(){
let url = 'user/Center/feedback',params = {
content:this.data.content
};
params.content?app.post(url,params).then(r=>{
wx.showToast({
title: '提交成功',
icon:'none'
})
setTimeout(r=>{
wx.navigateBack({})
},1200)
}):wx.showToast({
title: '请输入您要反馈的内容',
icon:'none'
})
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady: function () {
},
/**
* 生命周期函数--监听页面显示
*/
onShow: function () {
},
/**
* 生命周期函数--监听页面隐藏
*/
onHide: function () {
},
/**
* 生命周期函数--监听页面卸载
*/
onUnload: function () {
},
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh: function () {
},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom: function () {
},
/**
* 用户点击右上角分享
*/
onShareAppMessage: function () {
}
})
\ No newline at end of file
... ...
{
"usingComponents": {},
"navigationBarTitleText": "用户反馈"
}
\ No newline at end of file
... ...
<!--pages/myblock/feedback/feedback.wxml-->
<view>
<textarea class='feedback_box' bindinput='inputFeedback' placeholder='请输入您的意见,我们会积极处理并改正的~'></textarea>
<view class='submit_btn' bindtap='subFeedBack'>提交</view>
</view>
... ...
/* pages/myblock/feedback/feedback.wxss */
.feedback_box{
margin: 40rpx 32rpx 0 32rpx;
background-color: #F2F2F2;
border-radius: 10rpx;
padding: 25rpx;
font-size: 28rpx;
display: block;
width: auto;
}
.submit_btn{
height: 80rpx;
width: 660rpx;
color: #FFF;
font-size: 28rpx;
background-color: #E81825;
display: flex;
align-items: center;
justify-content: center;
border-radius: 40rpx;
margin: 40rpx auto;
}
... ...
... ... @@ -114,7 +114,7 @@
<view class='wine_list' wx:if='{{selectindex==3}}' bindtap='closeShareAction'>
<view class='list_item' wx:for='{{list}}' wx:key=''>
<view class='img_box'>
<image src='{{item.thumb}}' mode='widthFix'></image>
<image src='{{item.avatar}}' mode='widthFix'></image>
</view>
<view class='wine_title'>{{item.title}}</view>
<view class='wine_name'>{{item.user_nickname}}</view>
... ... @@ -136,42 +136,82 @@
<image src='/img/gengduo.png' mode='widthFix' class='moreIcon'></image>
<view class='min_action_box'>
<view class='action_btn {{item.is_favorite?"active":""}}'>{{!item.is_favorite?"收藏":"已收藏"}}</view>
<view class='action_btn'>分享 <button open-type='share'></button></view>
<view class='action_btn'>分享
<button open-type='share'></button>
</view>
</view>
</view>
</view>
<!-- <view class='list_item'>
<view class='img_box'>
<image src='/img/aicon_65.png'></image>
</view>
<view class='wine_title'>万丈红尘一人醉</view>
<view class='wine_name'>唐国强</view>
<view class='wine_leavel'>lv12</view>
<view class='action_box'>
<view class='single_action'>
<view class='zan_icon'>
<image src='/img/aicon_47.png' mode='widthFix'></image>
</view>
618
<!-- 专家品酒 -->
<view class='wine_list' wx:if='{{selectindex==4}}'>
<view class="wineblock" wx:for='{{list}}' wx:key=''>
<view class="winetitle">{{item.title}}</view>
<view class="wineimg">
<image src="{{item.video_image}}"></image>
<image src='/img/aicon_70.png' class='video_play'></image>
</view>
<view class='single_action'>
<view class='zan_icon'>
<view class="winebottom">
<view class="winebottomleft">
<view class="winebottomleftimg">
<image src="{{item.avatar}}"></image>
</view>
<view class="wineeng">{{item.name}}</view>
</view>
<view class="winebottonright">
<view class="winerighttou">
<view class="winerighttouimg">
<image src='{{!item.is_good?"/img/aicon_47.png":"/img/aicon_46.png"}}' mode='widthFix'></image>
</view>
<view class="winezan">{{item.good_count}}</view>
</view>
<view class="winerighttou">
<view class="winerighttouimg">
<image src='/img/aicon_67.png' mode='widthFix'></image>
</view>
54
<view class="winezan">{{item.comment_count}}</view>
</view>
<view class="winerighttou">
<view class="winerighttouimg">
<image src="/img/aicon_74.png"></image>
</view>
</view>
</view>
</view>
</view>
</view>
<view class="niangjiulist" wx:if='{{selectindex==5}}'>
<view class="niangjiuitem" wx:for='{{list}}' wx:key=''>
<view class="teachimg">
<image src="{{item.avatar}}"></image>
</view>
<view class="jiuname">{{item.name}}</view>
<view class="atten">{{item.is_concern==0?'关注':'已关注'}}</view>
<view class="jiubottom">
<view class="jiuleft">
<view class="jiuleftimg">
<image src='{{!item.is_good?"/img/aicon_47.png":"/img/aicon_46.png"}}' mode='widthFix'></image>
</view>
<view class="jiuzan">{{item.good_count}}</view>
</view>
<view class='single_action'>
<image src='/img/gengduo.png' mode='widthFix' class='more'></image>
<view class="jiumiddle">
<view class="middleimg">
<image src='/img/aicon_67.png' mode='widthFix'></image>
</view>
<view class="tiao">{{item.comment_count}}</view>
</view>
<view class="jiuright">
<image src="/img/aicon_68.png"></image>
</view>
</view>
</view>
</view> -->
</view>
<view class='showall' wx:if='{{noMore&&noData}}'>已显示全部内容</view>
</view>
</view>
<view class='showall' wx:if='{{noMore&&noData}}'>已显示全部内容</view>
<view class='noData' wx:if='{{!noData}}'>
暂无相关数据
</view>
\ No newline at end of file
... ...
@import '../../homeblock/zhinengselect/zhinengselect.wxss';
@import '../../jiudan/jiudan.wxss';
@import '../../findblock/zhuanjiapinjiu/zhuanjiapinjiu.wxss';
@import '../../findblock/niangjiushi/niangjiushi.wxss';
page{
width: 100%;
... ... @@ -236,10 +238,7 @@ page{
background: #E81825;
color: #FFF;
}
.img_box{
overflow: auto;
border-radius: 0;
}
.shareAction .more{
margin-right: 0!important;
}
\ No newline at end of file
... ...
// pages/myblock/huanbangshouji/huanbangshouji.js
const app = getApp();
Page({
/**
* 页面的初始数据
*/
data: {
params:{
},
getting: true,
code: 60
},
/**
* 生命周期函数--监听页面加载
... ... @@ -14,6 +19,66 @@ Page({
onLoad: function (options) {
},
getCode(){
let phone = this.data.params.mobile, url ='/user/Profile/getNewCode',that = this;
if (!(/^1[3456789]\d{9}$/.test(phone))){
wx.showToast({
title: '请输入正确的手机号',
icon:'none'
})
}else{
let params = {
mobile: this.data.params.mobile
},code=60;
app.post(url,params).then(r=>{
that.setData({
getting: false
})
let interval = setInterval(()=>{
that.setData({
code: code
})
code--;
if (code == 0) {
that.setData({
getting: true,
code: 60
})
clearInterval(interval);
}
},1000)
})
}
},
inputCode(e){
let type = e.currentTarget.dataset.type;
this.data.params[type]=e.detail.value;
this.setData({
params:this.data.params
})
},
subBand(){
let phone = this.data.params.mobile, url ='/user/Profile/bind_new_mobile';
if (!(/^1[3456789]\d{9}$/.test(phone))) {
wx.showToast({
title: '请输入正确的手机号',
icon: 'none'
})
} else {
app.post(url, this.data.params).then(r => {
wx.showToast({
title: '换绑手机号成功',
icon:'none'
})
setTimeout(()=>{
wx.navigateBack({
})
},1500)
})
}
},
/**
* 生命周期函数--监听页面初次渲染完成
... ...
<view class="bangshouji">
<view class="huanbangleft">
<input password type="number" placeholder='请输入手机号' placeholder-class='enterphone'/>
<input type="number" placeholder='请输入手机号' placeholder-class='enterphone' maxlength='11' bindinput='inputCode' data-type='mobile' />
</view>
<view class="huanbangright" bindtap='getCode' wx:if='{{getting}}' >获取验证码</view>
<view class="huanbangright" wx:else>{{code}}S</view>
</view>
<view class="bangshouji enteryan">
<input type="number" placeholder='请输入验证码' maxlength='6' placeholder-class='enterphone' value='{{verification_code}}' bindinput='inputCode' data-type='verification_code' />
</view>
<view class="huanbangright">获取验证码</view>
<view class='sub_btn' wx:if='{{!params.verification_code}}'>
验证后绑定新手机号
</view>
<view class="bangshouji enteryan">
<input password type="number" placeholder='请输入验证码' placeholder-class='enterphone'/>
<view class='sub_btn active' wx:else bindtap='subBand'>
确认绑定
</view>
\ No newline at end of file
... ...
... ... @@ -54,3 +54,19 @@ page{
color:#1A1A1A;
font-size: 30rpx;
}
.sub_btn{
width: 540rpx;
height: 100rpx;
background: #CCC;
font-size: 30rpx;
margin: 0 auto;
margin-top: 130rpx;
color: #FFF;
border-radius: 50rpx;
align-items: center;
display: flex;
justify-content: center;
}
.sub_btn.active{
background: #E81825;
}
\ No newline at end of file
... ...
// pages/myblock/jiupin/jiupin.js
const app = getApp();
Page({
/**
* 页面的初始数据
*/
data: {
page:1,
noData: true,
noMore: false,
list:[]
},
/**
* 生命周期函数--监听页面加载
*/
onLoad: function (options) {
this.getList();
},
getList() {
let url = 'user/Center/favorite_wine' , params = {
page: this.data.page
};
app.post(url, params).then(r => {
var list = this.data.page == 1 ? r.list : this.data.list.concat(r.list);
this.setData({
list: list,
totalPage: r.total_page,
noData: list.length > 0 ? true : false,
noMore: r.totalPage == r.page ? !0 : !1
})
})
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady: function () {
},
/**
* 生命周期函数--监听页面显示
*/
onShow: function () {
},
/**
* 生命周期函数--监听页面隐藏
*/
onHide: function () {
},
/**
* 生命周期函数--监听页面卸载
*/
onUnload: function () {
},
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh: function () {
},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom: function () {
!this.data.noMore ?(this.setData({
page: page + 1
}), this.list()) : wx.showToast({
title: '没有更多了',
icon: 'none'
})
},
/**
* 用户点击右上角分享
*/
onShareAppMessage: function () {
}
})
\ No newline at end of file
... ...
{
"usingComponents": {},
"navigationBarTitleText": "酒品"
}
\ No newline at end of file
... ...
<view class='list_box'>
<view class="searchitem" wx:for='{{list}}' wx:key=''>
<view class="searchitemleft">
<view class="itemleftimg">
<image src="{{item.logo}}"></image>
</view>
<view class="itemiddle">
<view class="itemidelename">{{item.name}}</view>
<view class="nambottom">
<text class="namebottomitem">{{item.degree_name}}</text>
<text class="namebottomitem">{{item.odor_name}}</text>
<text class="namebottomitem">{{item.price}}</text>
<text class="namebottomitem">{{item.ml}}</text>
</view>
</view>
</view>
<view class="starimg">
<!-- aicon_010x.png -->
<image src="{{item.is_favorite==0?'/img/aicon_09.png':'/img/aicon_10.png'}}"></image>
</view>
</view>
</view>
<view class='showall' wx:if='{{noMore&&noData}}'>已显示全部内容</view>
<view class='noData' wx:if='{{!noData}}'>
暂无相关数据
</view>
\ No newline at end of file
... ...
/* pages/myblock/jiupin/jiupin.wxss */
@import '../../homeblock/search/search.wxss';
\ No newline at end of file
... ...
// pages/myblock/message/message.js
const formMate = require('../../../utils/util.js');
const app = getApp();
Page({
/**
* 页面的初始数据
*/
data: {
page: 1,
list: [],
noData: true,
noMore: !1,
},
/**
* 生命周期函数--监听页面加载
*/
onLoad: function (options) {
this.getList();
},
getList() {
let url = 'user/Center/my_message', params = {
page: this.data.page
};
app.post(url, params).then(r => {
for(var obj of r.list){
obj.create_time = formMate.formatTime(new Date(obj.create_time))
}
var list = this.data.page == 1 ? r.list : this.data.list.concat(r.list);
this.setData({
list: list,
totalPage: r.total_page,
noData: list.length > 0 ? true : false,
noMore: r.totalPage == r.page ? !0 : !1
})
})
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady: function () {
},
/**
* 生命周期函数--监听页面显示
*/
onShow: function () {
},
/**
* 生命周期函数--监听页面隐藏
*/
onHide: function () {
},
/**
* 生命周期函数--监听页面卸载
*/
onUnload: function () {
},
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh: function () {
},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom: function () {
this.data.page < this.data.totalPage ? this.list()
: wx.showToast({
title: '没有更多了',
icon: 'none'
})
},
/**
* 用户点击右上角分享
*/
onShareAppMessage: function () {
}
})
\ No newline at end of file
... ...
{
"usingComponents": {},
"navigationBarTitleText": "消息通知"
}
\ No newline at end of file
... ...
<!--pages/myblock/message/message.wxml-->
<view class='message_list'>
<view class='message_item' wx:for='{{list}}' wx:key=''>
<view class='time'>{{item.create_time}}</view>
<view class='message_content'>
{{item.content}}
</view>
</view>
</view>
... ...
/* pages/myblock/message/message.wxss */
page{
background: #F2F2F2;
}
.message_item{
}
.message_item .time{
color: #999999;
font-size: 24rpx;
text-align: center;
padding: 36rpx 0;
}
.message_content{
margin: 0 67rpx;
padding: 38rpx 44rpx;
background-color: #FFF;
font-size:26rpx;
color: #333;
border-radius: 5rpx;
}
\ No newline at end of file
... ...
... ... @@ -12,7 +12,8 @@ Page({
sexarray:['男','女'],
birthday:'',
reginname: '北京 北京市 东城区',
region: ['北京', '北京市', '东城区']
region: ['北京', '北京市', '东城区'],
xingzuo:['']
},
/**
... ... @@ -24,20 +25,75 @@ Page({
birthday: app.newnowDate()
})
this.getUserInfo();
},
uploadImg(e){
let that = this;
wx.chooseImage({
count: 1,
sizeType: [],
sourceType: [],
success: function(res) {
wx.uploadFile({
url: app.globalData.baseUrl +'/user/upload/one',
filePath: res.tempFilePaths[0],
name: 'file',
header: {
'XX-Token':wx.getStorageSync('token'),
'XX-Device-Type':'wxapp'
},
formData: {
file: res.tempFilePaths[0]
},
success: function(res) {
let data = JSON.parse(res.data)
that.setData({
'userInfo.avatar': data.data.url
});
that.saveUserInfo();
},
fail: function(res) {},
complete: function(res) {},
})
},
fail: function(res) {},
complete: function(res) {},
})
},
getUserInfo(){
let url = '/user/Center/get_userinfo';
app.post(url,{}).then(r=>{
this.setData({
userInfo: r,
sexindex: r.sex == 1 ?0:2,
sexname: r.sex == 1?'男':'女'
})
})
},
saveUserInfo(){
let url = 'user/Center/set_userinfo';
app.post(url,this.data.userInfo).then(r=>{})
},
inputUserInfo(e){
let type = e.currentTarget.dataset.type;
this.data.userInfo[type] = e.detail.value
this.setData({
userInfo: this.data.userInfo
});
this.saveUserInfo();
},
bindhospitaltypeChange(e) {
let that = this;
that.setData({
sexindex: e.detail.value,
sexname: that.data.sexarray[e.detail.value]
sexname: that.data.sexarray[e.detail.value],
'userInfo.sex': that.data.sexarray[e.detail.value]=='男'?1:2
})
},
//生日选择
bindDateChange: function (e) {
this.setData({
birthday: e.detail.value
})
... ...
<view class="headtop">
<view class="headtopitem">
<view class="headtopleft">我的头像</view>
<view class="touxiang">
<image src="{{url}}/aicon_77@2x.png"></image>
<view class="touxiang" bindtap='uploadImg'>
<image src="{{userInfo.avatar}}"></image>
</view>
</view>
<view class="headtopitem">
<view class="headtopleft">昵称</view>
<view class="entername">
<input placeholder='请输入昵称' placeholder-class='enterming' />
<input placeholder='请输入昵称' placeholder-class='enterming' value='{{userInfo.user_nickname}}' bindinput='inputUserInfo' data-type='user_nickname' />
</view>
</view>
... ... @@ -34,91 +34,78 @@
</view>
<view class="headtopitem">
<view class="headtopleft">生日</view>
<picker mode="date" value="{{date}}" start="2015-09-01" end="2017-09-01" bindchange="bindDateChange">
<picker mode="date" value="{{userInfo.birthday}}" bindchange="bindDateChange">
<view class="selectoption">
<view class="sexname">
{{birthday}}
</view>
<view class="rowimg">
<image src="/img/aicon_61.png"></image>
</view>
</view>
</picker>
</view>
<view class="headtopitem">
<view class="headtopleft">地区</view>
<picker mode="region" bindchange="bindRegionChange" value="{{region}}" custom-item="{{customItem}}">
<picker mode="region" bindchange="bindRegionChange" value="{{userInfo.region}}" custom-item="{{customItem}}">
<view class="selectoption">
<view class="sexname">
{{reginname}}
</view>
<view class="rowimg">
<image src="/img/aicon_61.png"></image>
</view>
</view>
</picker>
</view>
<view class="headtopitem">
<view class="headtopleft">个人签名</view>
<view class="entername qianming">
<input placeholder='请输入个性签名' placeholder-class='enterming' />
<input placeholder='请输入个性签名' placeholder-class='enterming' value='{{userInfo.sign}}' bindinput='inputUserInfo' data-type='sign' />
</view>
</view>
</view>
<view class="headtop">
<view class="headtopitem">
<view class="headtopleft">星座</view>
<view class="entername">
<input placeholder='请输入星座' placeholder-class='enterming' />
<input placeholder='请输入星座' placeholder-class='enterming' value='{{userInfo.constellation}}' bindinput='getUserInfo' data-type='constellation' />
</view>
</view>
<view class="headtopitem">
<view class="headtopleft">身高</view>
<view class="entername">
<input placeholder='请输入身高' placeholder-class='enterming' />
<input placeholder='请输入身高' placeholder-class='enterming' value='{{userInfo.height}}' bindinput='inputUserInfo' data-type='height'/>
</view>
</view>
<view class="headtopitem">
<view class="headtopleft">体重</view>
<view class="entername">
<input placeholder='请输入体重' placeholder-class='enterming' />
<input placeholder='请输入体重' placeholder-class='enterming' value='{{userInfo.weight}}' bindinput='inputUserInfo' data-type='weight'/>
</view>
</view>
</view>
<view class="headtop">
<view class="headtopitem">
<view class="headtopleft">职业</view>
<view class="entername">
<input placeholder='请输入职业' placeholder-class='enterming' />
<input placeholder='请输入职业' placeholder-class='enterming' value='{{userInfo.major}}' bindinput='inputUserInfo' data-type='major'/>
</view>
</view>
<view class="headtopitem">
<view class="headtopleft">收入</view>
<view class="entername">
<input placeholder='请输入收入' placeholder-class='enterming' />
<input placeholder='请输入收入' placeholder-class='enterming' value='{{userInfo.income}}' bindinput='inputUserInfo' data-type='income'/>
</view>
</view>
<view class="headtopitem">
<view class="headtopleft">兴趣爱好</view>
<view class="entername">
<input placeholder='请输入兴趣爱好' placeholder-class='enterming' />
<input placeholder='请输入兴趣爱好' placeholder-class='enterming' value='{{userInfo.interest}}' bindinput='inputUserInfo' data-type='interest'/>
</view>
</view>
</view>
\ No newline at end of file
... ...
... ... @@ -35,7 +35,7 @@
text-align: right
}
.enterming{
color:#999999;
color:#666;
font-size:28rpx;
text-align: right
}
... ... @@ -47,7 +47,7 @@
height:48rpx;
line-height: 48rpx;
text-align: right;
color:#999999;
color:#666;
font-size:28rpx;
margin-right:22rpx;
... ... @@ -61,3 +61,6 @@
display:flex;
align-items: center;
}
input{
color: #666
}
\ No newline at end of file
... ...
// pages/myblock/jiupin/jiupin.js
const app = getApp();
Page({
/**
* 页面的初始数据
*/
data: {
page: 1,
noData: true,
noMore: false,
list: []
},
/**
* 生命周期函数--监听页面加载
*/
onLoad: function (options) {
this.getList();
},
collect(e) {
let id = e.currentTarget.id, url = '/index/Common/favorite', index = e.currentTarget.dataset.index, params = {
sort: 2,
id: id
};
app.post(url, params).then(r => {
this.data.list.splice(index,1);
wx.showToast({
title: '操作成功',
icon:'none',
duration: 1300
})
this.setData({
list: this.data.list
})
})
},
getList() {
let url = 'user/Center/favorite_brand', params = {
page: this.data.page
};
app.post(url, params).then(r => {
var list = this.data.page == 1 ? r.list : this.data.list.concat(r.list);
this.setData({
list: list,
totalPage: r.total_page,
noData: list.length > 0 ? true : false,
noMore: r.totalPage == r.page ? !0 : !1
})
})
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady: function () {
},
/**
* 生命周期函数--监听页面显示
*/
onShow: function () {
},
/**
* 生命周期函数--监听页面隐藏
*/
onHide: function () {
},
/**
* 生命周期函数--监听页面卸载
*/
onUnload: function () {
},
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh: function () {
},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom: function () {
!this.data.noMore ? (this.setData({
page: page + 1
}), this.list()) : wx.showToast({
title: '没有更多了',
icon: 'none'
})
},
/**
* 用户点击右上角分享
*/
onShareAppMessage: function () {
}
})
\ No newline at end of file
... ...
{
"usingComponents": {},
"navigationBarTitleText": "品牌"
}
\ No newline at end of file
... ...
<view class='list_box'>
<view class="searchitem" wx:for='{{list}}' wx:key=''>
<view class="searchitemleft">
<view class="itemleftimg">
<image src="{{item.logo}}" mode='widthFix'></image>
</view>
<view class="itemiddle">
<view class="itemidelename">{{item.name}}</view>
<view class="nambottom">
<text class="namebottomitem">{{item.sort_name}}</text>
<text class="namebottomitem">{{item.country}}</text>
<text class="namebottomitem">{{item.city}}</text>
<text class="namebottomitem">{{item.odor_name}}</text>
</view>
</view>
</view>
<view class="starimg" id='{{item.id}}' data-index='{{index}}' bindtap='collect'>
<!-- aicon_010x.png -->
<image src="{{item.is_favorite==0?'/img/aicon_09.png':'/img/aicon_10.png'}}"></image>
</view>
</view>
</view>
<view class='showall' wx:if='{{noMore&&noData}}'>已显示全部内容</view>
<view class='noData' wx:if='{{!noData}}'>
暂无相关数据
</view>
\ No newline at end of file
... ...
/* pages/myblock/jiupin/jiupin.wxss */
@import '../../homeblock/search/search.wxss';
\ No newline at end of file
... ...
// pages/myblock/rule/rule.js
let WxParse = require('../../../wxParse/wxParse.js');
const app = getApp();
Page({
/**
* 页面的初始数据
*/
data: {
},
/**
* 生命周期函数--监听页面加载
*/
onLoad: function (options) {
this.getRule();
},
getRule(){
let url = '/index/Common/protocol';
app.post(url,{}).then(r=>{
WxParse.wxParse('contentHtml', 'html', r.content, this, 5)
})
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady: function () {
},
/**
* 生命周期函数--监听页面显示
*/
onShow: function () {
},
/**
* 生命周期函数--监听页面隐藏
*/
onHide: function () {
},
/**
* 生命周期函数--监听页面卸载
*/
onUnload: function () {
},
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh: function () {
},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom: function () {
},
/**
* 用户点击右上角分享
*/
onShareAppMessage: function () {
}
})
\ No newline at end of file
... ...
{
"usingComponents": {},
"navigationBarTitleText": "协议规则"
}
\ No newline at end of file
... ...
<!--pages/myblock/rule/rule.wxml-->
<view class='content'>
<import src="/wxParse/wxParse.wxml" />
<template is="wxParse" data="{{wxParseData:contentHtml.nodes}}" />
</view>
... ...
/* pages/myblock/rule/rule.wxss */
.content{
font-size: 30rpx;
padding: 30rpx;
color: #666;
}
\ No newline at end of file
... ...
... ... @@ -18,7 +18,32 @@ Page({
})
},
inputPass(e){
this.setData({
password: e.detail.value
})
},
confirmPassWord(){
let params = {
password: this.data.password
}, url ='/user/Profile/set_password';
if(params.password.length<6){
wx.showToast({
title: '请输入6位数以上的密码',
})
}else{
app.post(url,params).then(r=>{
wx.showToast({
title: '设置成功',
duration: 1300
})
setTimeout(()=>{
wx.navigateBack({
})
},1200)
})
}
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
... ...
<view class="setmima">
<view class="setmimaleft">
<input placeholder='设置密码' placeholder-class='shemi'/>
<input password placeholder='设置密码' bindinput='inputPass' />
</view>
<view class="mimaeye">
<image src="{{url}}/bicon_14x.png"></image>
</view>
</view>
<view class="que">确认</view>
<view class="que" bindtap='confirmPassWord'>确认</view>
<view class="needmi">需要有6-20位数字、字母或符号组成,至少两种</view>
<view class="mimasuccess">密码设置成功</view>
... ...
// pages/myblock/zhanghaobangding/zhanghaobangding.js
const app = getApp();
Page({
/**
* 页面的初始数据
*/
data: {
info:{}
},
/**
* 生命周期函数--监听页面加载
*/
onLoad: function (options) {
this.getBindInfo();
},
getBindInfo(){
let url = '/user/Center/user_bind';
app.post(url,{}).then(r=>{
this.setData({
info:r
})
})
},
changeBind(){
wx.showToast({
title: '由于功能限制请前往APP进行相关操作',
icon: 'none'
})
},
getUserInfo(e){
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
... ...
<view class="zhanghao">
<view class="zhanghaoitem">
<view class="zhanghaoleft">手机号绑定</view>
<view class="zhanghaoright">
<view class="zhanghaoname">136****7686</view>
<navigator class="zhanghaoright" url='/pages/myblock/huanbangshouji/huanbangshouji'>
<view class="zhanghaoname">{{info.mobile}}</view>
<view class="rowimg">
<image src="/img/aicon_61.png"></image>
</view>
</view>
</navigator>
</view>
<view class="zhanghaoitem">
<view class="zhanghaoleft">微信绑定</view>
<view class="zhanghaoright">
<view class="zhanghaoname">好时光</view>
<view class="zhanghaoright" bindtap='changeBind'>
<view class="zhanghaoname" wx:if='{{info.wechat}}'>{{info.wechat}}</view>
<view class="zhanghaoname bangname" wx:else>去绑定</view>
<view class="rowimg">
<image src="/img/aicon_61.png"></image>
</view>
</view>
</view>
<view class="zhanghaoitem">
<view class="zhanghaoleft">QQ绑定</view>
<view class="zhanghaoright">
<view class="zhanghaoname bangname">去绑定</view>
<view class="zhanghaoright" bindtap='changeBind'>
<view class="zhanghaoname" wx:if='{{info.qq}}'>{{info.qq}}</view>
<view class="zhanghaoname bangname" wx:else>去绑定</view>
<view class="rowimg">
<image src="/img/aicon_61.png"></image>
</view>
... ... @@ -33,8 +33,9 @@
<view class="zhanghaoitem">
<view class="zhanghaoleft">新浪微博绑定</view>
<view class="zhanghaoright">
<view class="zhanghaoname bangname">去绑定</view>
<view class="zhanghaoright" bindtap='changeBind'>
<view class="zhanghaoname" wx:if='{{info.weibo}}'>{{info.weibo}}</view>
<view class="zhanghaoname bangname" wx:else>去绑定</view>
<view class="rowimg">
<image src="/img/aicon_61.png"></image>
</view>
... ...
... ... @@ -34,6 +34,15 @@ page{
.zhanghaoright{
display:flex;
align-items: center;
position: relative;
}
.authInfo{
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
opacity: 0;
}
.zhanghaoname{
color:#999999;
... ...
<view class="zhanghao">
<view class="zhanghaoitem">
<navigator class="zhanghaoitem" url='/pages/myblock/zhanghaobangding/zhanghaobangding'>
<view class="zhanghaoleft">账号绑定</view>
<view class="rowimg">
<image src="/img/aicon_61.png"></image>
</view>
</view>
</navigator>
<view class="zhanghaoitem">
<navigator class="zhanghaoitem" url='/pages/myblock/shezhimima/shezhimima'>
<view class="zhanghaoleft">设置密码</view>
<view class="rowimg">
<image src="/img/aicon_61.png"></image>
</view>
</view>
</navigator>
</view>
<view class="question">常见问题</view>
\ No newline at end of file
... ...
... ... @@ -49,7 +49,7 @@
"list": []
},
"miniprogram": {
"current": 35,
"current": 43,
"list": [
{
"id": -1,
... ... @@ -300,6 +300,63 @@
"id": -1,
"name": "酒单详情",
"pathName": "pages/findblock/jiudandetail/jiudandetail",
"query": "",
"scene": null
},
{
"id": -1,
"name": "历史",
"pathName": "pages/myblock/history/history",
"query": "",
"scene": null
},
{
"id": -1,
"name": "个人中心收藏品牌",
"pathName": "pages/myblock/pinpai/pinpai",
"query": "",
"scene": null
},
{
"id": 38,
"name": "消息",
"pathName": "pages/myblock/message/message",
"query": "",
"scene": null
},
{
"id": 39,
"name": "用户反馈",
"pathName": "pages/myblock/feedback/feedback",
"query": "",
"scene": null
},
{
"id": -1,
"name": "账号绑定",
"pathName": "pages/myblock/zhanghaobangding/zhanghaobangding",
"query": "",
"scene": null
},
{
"id": -1,
"name": "换绑手机",
"pathName": "pages/myblock/huanbangshouji/huanbangshouji",
"query": "",
"scene": null
},
{
"id": -1,
"name": "设置密码",
"pathName": "pages/myblock/shezhimima/shezhimima",
"query": "",
"scene": null
},
{
"id": -1,
"name": "协议规则",
"pathName": "pages/myblock/rule/rule",
"query": "",
"scene": null
}
]
... ...