作者 wumengyu

注释掉console

@@ -39,23 +39,23 @@ App({ @@ -39,23 +39,23 @@ App({
39 return new Promise(function (resolve, reject) { 39 return new Promise(function (resolve, reject) {
40 wx.getUserInfo({ 40 wx.getUserInfo({
41 success: function (user) { 41 success: function (user) {
42 - console.log('获取用户信息', user);// gender:性别 0:未知、1:男、2:女 42 + // console.log('获取用户信息', user);// gender:性别 0:未知、1:男、2:女
43 // 登录 43 // 登录
44 let url = '/portal/Login/getToken'; 44 let url = '/portal/Login/getToken';
45 wx.login({ 45 wx.login({
46 success: function (res) { 46 success: function (res) {
47 if (self.loginCallback) { 47 if (self.loginCallback) {
48 - console.log('onlaunch-callback'); 48 + // console.log('onlaunch-callback');
49 self.loginCallback(user) 49 self.loginCallback(user)
50 } 50 }
51 - console.log('获取code', res); 51 + // console.log('获取code', res);
52 self.post(url, { 52 self.post(url, {
53 code: res.code, 53 code: res.code,
54 user_nickname: user.userInfo.nickName, 54 user_nickname: user.userInfo.nickName,
55 avatar: user.userInfo.avatarUrl, 55 avatar: user.userInfo.avatarUrl,
56 sex: user.userInfo.gender, 56 sex: user.userInfo.gender,
57 }, {}).then((ret) => { 57 }, {}).then((ret) => {
58 - console.log('获取token', ret); 58 + // console.log('获取token', ret);
59 wx.setStorageSync('token', ret.data.token); 59 wx.setStorageSync('token', ret.data.token);
60 self.globalData.userInfo = user.userInfo; 60 self.globalData.userInfo = user.userInfo;
61 resolve(ret.data); 61 resolve(ret.data);
@@ -111,10 +111,10 @@ App({ @@ -111,10 +111,10 @@ App({
111 if (+res.data.code == 1) { 111 if (+res.data.code == 1) {
112 resolve(res.data); 112 resolve(res.data);
113 } else if (res.data.code == '20000') { 113 } else if (res.data.code == '20000') {
114 - console.log('20000'); 114 + // console.log('20000');
115 resolve(res.data.data); 115 resolve(res.data.data);
116 } else if (res.data.data.code == '10001') { //未获取授权 116 } else if (res.data.data.code == '10001') { //未获取授权
117 - console.log('10001'); 117 + // console.log('10001');
118 wx.showModal({ 118 wx.showModal({
119 title: '提示', 119 title: '提示',
120 content: res.data.data.msg, 120 content: res.data.data.msg,
@@ -130,8 +130,8 @@ App({ @@ -130,8 +130,8 @@ App({
130 }); 130 });
131 resolve(res.data.data); 131 resolve(res.data.data);
132 } else if (+res.data.code === 0) { 132 } else if (+res.data.code === 0) {
133 - console.log('code=0');  
134 - console.log(res.data); 133 + // console.log('code=0');
  134 + // console.log(res.data);
135 wx.showModal({ 135 wx.showModal({
136 title: '提示', 136 title: '提示',
137 content: res.data.message, 137 content: res.data.message,
@@ -177,15 +177,15 @@ App({ @@ -177,15 +177,15 @@ App({
177 let H = (hours > 9 ? hours : ('0' + hours)) + ':' + (minutes > 9 ? minutes : ('0' + minutes)); 177 let H = (hours > 9 ? hours : ('0' + hours)) + ':' + (minutes > 9 ? minutes : ('0' + minutes));
178 // let time = []; 178 // let time = [];
179 // time.push(H); 179 // time.push(H);
180 - console.log('time', H); 180 + // console.log('time', H);
181 // let new_time = time.join(' '); 181 // let new_time = time.join(' ');
182 return H; 182 return H;
183 }, 183 },
184 //获取截止时间的前几个小时 184 //获取截止时间的前几个小时
185 preTime(over_time, n) { 185 preTime(over_time, n) {
186 - console.log('over_time', over_time); 186 + // console.log('over_time', over_time);
187 var time = new Date(new Date(over_time).getTime() - n * 60 * 60 * 1000); 187 var time = new Date(new Date(over_time).getTime() - n * 60 * 60 * 1000);
188 - console.log('time', time); 188 + // console.log('time', time);
189 var y = time.getFullYear(), 189 var y = time.getFullYear(),
190 m = time.getMonth() + 1, 190 m = time.getMonth() + 1,
191 d = time.getDate(), 191 d = time.getDate(),
@@ -195,7 +195,7 @@ App({ @@ -195,7 +195,7 @@ App({
195 d = d < 10 ? '0' + d : d; 195 d = d < 10 ? '0' + d : d;
196 h = h < 10 ? '0' + h : h; 196 h = h < 10 ? '0' + h : h;
197 mi = mi < 10 ? '0' + mi : mi; 197 mi = mi < 10 ? '0' + mi : mi;
198 - console.log('截止时间', time, m, d, h, mi); 198 + // console.log('截止时间', time, m, d, h, mi);
199 return y + '-' + m + '-' + d + ' ' + h + ':' + mi; 199 return y + '-' + m + '-' + d + ' ' + h + ':' + mi;
200 }, 200 },
201 timeFormat(param) { //小于10的格式化函数 201 timeFormat(param) { //小于10的格式化函数
@@ -8,7 +8,7 @@ Page({ @@ -8,7 +8,7 @@ Page({
8 data: {}, 8 data: {},
9 //获取授权 9 //获取授权
10 login(e) { 10 login(e) {
11 - console.log('e', e); 11 + // console.log('e', e);
12 let url = '/portal/Login/getToken'; 12 let url = '/portal/Login/getToken';
13 wx.login({ 13 wx.login({
14 success: function (res) { 14 success: function (res) {
@@ -32,7 +32,7 @@ Page({ @@ -32,7 +32,7 @@ Page({
32 keyword:self.data.searchValue, 32 keyword:self.data.searchValue,
33 }; 33 };
34 app.post(url, params, header).then((res) => { 34 app.post(url, params, header).then((res) => {
35 - console.log('搜索历史列表', res); 35 + // console.log('搜索历史列表', res);
36 // wx.hideLoading(); 36 // wx.hideLoading();
37 if(+res.code === 1) { 37 if(+res.code === 1) {
38 if(res.data.length === 0) { 38 if(res.data.length === 0) {
@@ -69,7 +69,7 @@ Page({ @@ -69,7 +69,7 @@ Page({
69 const self = this; 69 const self = this;
70 let url = '/portal/Index/cityList'; 70 let url = '/portal/Index/cityList';
71 app.post(url, {}, {}).then((res) => { 71 app.post(url, {}, {}).then((res) => {
72 - console.log('获取城市列表', res); 72 + // console.log('获取城市列表', res);
73 if (+res.code === 1) { 73 if (+res.code === 1) {
74 const arr = []; 74 const arr = [];
75 res.data.list.forEach((item) => { 75 res.data.list.forEach((item) => {
@@ -93,7 +93,7 @@ Page({ @@ -93,7 +93,7 @@ Page({
93 token: wx.getStorageSync('token'), 93 token: wx.getStorageSync('token'),
94 }; 94 };
95 app.post(url, params, {}).then((res) => { 95 app.post(url, params, {}).then((res) => {
96 - console.log('获取国外列表', res); 96 + // console.log('获取国外列表', res);
97 if (+res.code === 1) { 97 if (+res.code === 1) {
98 const arr = []; 98 const arr = [];
99 res.data.forEach((item) => { 99 res.data.forEach((item) => {
@@ -113,7 +113,7 @@ Page({ @@ -113,7 +113,7 @@ Page({
113 const lat = this.data.cityList[current].latng.split(',')[1]; 113 const lat = this.data.cityList[current].latng.split(',')[1];
114 const lng = this.data.cityList[current].latng.split(',')[0]; 114 const lng = this.data.cityList[current].latng.split(',')[0];
115 const addr = this.data.cityList[current].title; 115 const addr = this.data.cityList[current].title;
116 - console.log('addr', addr); 116 + // console.log('addr', addr);
117 this.setData({current_city:current}); 117 this.setData({current_city:current});
118 wx.setStorageSync('lat',lat); 118 wx.setStorageSync('lat',lat);
119 wx.setStorageSync('lng',lng); 119 wx.setStorageSync('lng',lng);
@@ -61,7 +61,7 @@ Page({ @@ -61,7 +61,7 @@ Page({
61 this.setData({show_gold_modal: false, show_normal_modal: false,is_showResult:false}); 61 this.setData({show_gold_modal: false, show_normal_modal: false,is_showResult:false});
62 try { 62 try {
63 wx.removeStorageSync('score'); 63 wx.removeStorageSync('score');
64 - console.log('删除后score', wx.getStorageSync('score')); 64 + // console.log('删除后score', wx.getStorageSync('score'));
65 } catch (e) { 65 } catch (e) {
66 // Do something when catch error 66 // Do something when catch error
67 } 67 }
@@ -100,7 +100,6 @@ Page({ @@ -100,7 +100,6 @@ Page({
100 disableScroll() { 100 disableScroll() {
101 }, 101 },
102 handleBackground() { 102 handleBackground() {
103 - console.log('dianji');  
104 this.setData({ 103 this.setData({
105 is_showAnswer: false, 104 is_showAnswer: false,
106 is_showUserInfo: false, 105 is_showUserInfo: false,
@@ -150,7 +149,7 @@ Page({ @@ -150,7 +149,7 @@ Page({
150 }, 149 },
151 //进入拼餐详情 150 //进入拼餐详情
152 goMealDetail(e) { 151 goMealDetail(e) {
153 - console.log('拼餐详情e', e); 152 + // console.log('拼餐详情e', e);
154 const id = e.currentTarget.dataset.id; 153 const id = e.currentTarget.dataset.id;
155 wx.navigateTo({ 154 wx.navigateTo({
156 url: '/pages/meal/detail/detail?id=' + id, 155 url: '/pages/meal/detail/detail?id=' + id,
@@ -158,7 +157,7 @@ Page({ @@ -158,7 +157,7 @@ Page({
158 }, 157 },
159 //进入拼活动详情 158 //进入拼活动详情
160 goActivityDetail(e) { 159 goActivityDetail(e) {
161 - console.log('活动详情e', e); 160 + // console.log('活动详情e', e);
162 const id = e.detail.activity_id; 161 const id = e.detail.activity_id;
163 wx.navigateTo({ 162 wx.navigateTo({
164 url: '/pages/activity/detail/detail?id=' + id, 163 url: '/pages/activity/detail/detail?id=' + id,
@@ -171,7 +170,7 @@ Page({ @@ -171,7 +170,7 @@ Page({
171 }) 170 })
172 }, 171 },
173 bannerChange(e) { 172 bannerChange(e) {
174 - console.log(e, 'current', current); 173 + // console.log(e, 'current', current);
175 const current = e.detail.current; 174 const current = e.detail.current;
176 this.setData({currentBannerIndex: current}) 175 this.setData({currentBannerIndex: current})
177 }, 176 },
@@ -190,7 +189,7 @@ Page({ @@ -190,7 +189,7 @@ Page({
190 _doRefreshMasonry(items) { 189 _doRefreshMasonry(items) {
191 this.masonryListComponent = this.selectComponent('#masonry'); 190 this.masonryListComponent = this.selectComponent('#masonry');
192 this.masonryListComponent.start(items).then(() => { 191 this.masonryListComponent.start(items).then(() => {
193 - console.log('refresh completed') 192 + // console.log('refresh completed')
194 }) 193 })
195 }, 194 },
196 195
@@ -198,7 +197,7 @@ Page({ @@ -198,7 +197,7 @@ Page({
198 this.masonryListComponent = this.selectComponent('#masonry'); 197 this.masonryListComponent = this.selectComponent('#masonry');
199 // 获取接口数据后使用瀑布流组件append方法,当append完成后调用then,是否可触底价在的标志位可以在这里处理 198 // 获取接口数据后使用瀑布流组件append方法,当append完成后调用then,是否可触底价在的标志位可以在这里处理
200 this.masonryListComponent.append(items).then(() => { 199 this.masonryListComponent.append(items).then(() => {
201 - console.log('refresh completed,加载更多') 200 + // console.log('refresh completed,加载更多')
202 }) 201 })
203 }, 202 },
204 //首页-导航 203 //首页-导航
@@ -206,10 +205,10 @@ Page({ @@ -206,10 +205,10 @@ Page({
206 var tindex = e.currentTarget.dataset.tindex; 205 var tindex = e.currentTarget.dataset.tindex;
207 var tabcurrent = this.data.tabcurrent.tab; 206 var tabcurrent = this.data.tabcurrent.tab;
208 if (tabcurrent == tindex) { 207 if (tabcurrent == tindex) {
209 - console.log('点击本页'); 208 + // console.log('点击本页');
210 return false 209 return false
211 } else { 210 } else {
212 - console.log('其他页'); 211 + // console.log('其他页');
213 this.setData({ 212 this.setData({
214 tabcurrent: tindex 213 tabcurrent: tindex
215 }) 214 })
@@ -239,7 +238,7 @@ Page({ @@ -239,7 +238,7 @@ Page({
239 }, 238 },
240 //发布按钮 239 //发布按钮
241 release(e) { 240 release(e) {
242 - console.log('发布', app.globalData.isLogin); 241 + // console.log('发布', app.globalData.isLogin);
243 const self = this; 242 const self = this;
244 // self.setData({ 243 // self.setData({
245 // is_showAnswer: true, //弹出 去答题弹框 244 // is_showAnswer: true, //弹出 去答题弹框
@@ -266,7 +265,7 @@ Page({ @@ -266,7 +265,7 @@ Page({
266 is_showRelease: false, 265 is_showRelease: false,
267 }); 266 });
268 } else if (+self.data.is_write === 1 && wx.getStorageSync('is_canSend') === 1 && wx.getStorageSync('is_answer') === 1) { //已填写且可以发布 =>去发布 267 } else if (+self.data.is_write === 1 && wx.getStorageSync('is_canSend') === 1 && wx.getStorageSync('is_answer') === 1) { //已填写且可以发布 =>去发布
269 - console.log('可以发布'); 268 + // console.log('可以发布');
270 self.setData({ 269 self.setData({
271 is_showRelease: true //弹出 发布弹框 270 is_showRelease: true //弹出 发布弹框
272 }); 271 });
@@ -331,25 +330,25 @@ Page({ @@ -331,25 +330,25 @@ Page({
331 // }, 330 // },
332 getPosition() { 331 getPosition() {
333 const self = this; 332 const self = this;
334 - console.log('2获取当前经纬度'); 333 + // console.log('2获取当前经纬度');
335 wx.getLocation({ //获取当前经纬度 334 wx.getLocation({ //获取当前经纬度
336 type: 'wgs84', //返回可以用于wx.openLocation的经纬度,官方提示bug: iOS 6.3.30 type 参数不生效,只会返回 wgs84 类型的坐标信息 335 type: 'wgs84', //返回可以用于wx.openLocation的经纬度,官方提示bug: iOS 6.3.30 type 参数不生效,只会返回 wgs84 类型的坐标信息
337 success: function (res) { 336 success: function (res) {
338 - console.log('获取当前经纬度', res); 337 + // console.log('获取当前经纬度', res);
339 self.setData({lat: res.latitude, lng: res.longitude}); 338 self.setData({lat: res.latitude, lng: res.longitude});
340 // app.loginCallback(); 339 // app.loginCallback();
341 // app.loginCallback = res => { 340 // app.loginCallback = res => {
342 // console.log('show-callback-res', res); 341 // console.log('show-callback-res', res);
343 app.getLogin().then(function (res) { 342 app.getLogin().then(function (res) {
344 - console.log('res', res);  
345 - console.log('1'); 343 + // console.log('res', res);
  344 + // console.log('1');
346 self.getIndex(res.token);//获取首页 345 self.getIndex(res.token);//获取首页
347 self.getIsWrite(); //判断是否已填写个人信息 346 self.getIsWrite(); //判断是否已填写个人信息
348 }); 347 });
349 // }; 348 // };
350 }, 349 },
351 fail: function (res) { 350 fail: function (res) {
352 - console.log('定位失败', res) 351 + // console.log('定位失败', res)
353 console.log('重新调起授权,获取当前城市'); 352 console.log('重新调起授权,获取当前城市');
354 wx.getSetting({ 353 wx.getSetting({
355 success: (res) => { 354 success: (res) => {
@@ -407,17 +406,17 @@ Page({ @@ -407,17 +406,17 @@ Page({
407 //获取经纬度 406 //获取经纬度
408 getLat() { 407 getLat() {
409 const self = this; 408 const self = this;
410 - console.log('没有经纬度', wx.getStorageSync('lat') === ''); 409 + // console.log('没有经纬度', wx.getStorageSync('lat') === '');
411 if (wx.getStorageSync('lat') !== '' && 410 if (wx.getStorageSync('lat') !== '' &&
412 wx.getStorageSync('lng') !== '' && 411 wx.getStorageSync('lng') !== '' &&
413 wx.getStorageSync('addr') !== '') { 412 wx.getStorageSync('addr') !== '') {
414 return 413 return
415 } else { 414 } else {
416 - console.log('1获取当前经纬度'); 415 + // console.log('1获取当前经纬度');
417 self.getPosition() 416 self.getPosition()
418 } 417 }
419 // wx.setStorageSync('score',30); 418 // wx.setStorageSync('score',30);
420 - console.log('score', wx.getStorageSync('score')); 419 + // console.log('score', wx.getStorageSync('score'));
421 if (wx.getStorageSync('score') !== '' && wx.getStorageSync('score') >= 80) { 420 if (wx.getStorageSync('score') !== '' && wx.getStorageSync('score') >= 80) {
422 self.setData({show_gold_modal: true,}); 421 self.setData({show_gold_modal: true,});
423 } else if (wx.getStorageSync('score') !== '' && wx.getStorageSync('score') < 80) { 422 } else if (wx.getStorageSync('score') !== '' && wx.getStorageSync('score') < 80) {
@@ -426,7 +425,7 @@ Page({ @@ -426,7 +425,7 @@ Page({
426 }, 425 },
427 //获取首页内容 426 //获取首页内容
428 getIndex(res) { 427 getIndex(res) {
429 - console.log('token', res, wx.getStorageSync('token')); 428 + // console.log('token', res, wx.getStorageSync('token'));
430 const self = this; 429 const self = this;
431 let url = '/portal/Index/index'; 430 let url = '/portal/Index/index';
432 let params = { 431 let params = {
@@ -440,7 +439,7 @@ Page({ @@ -440,7 +439,7 @@ Page({
440 "token": wx.getStorageSync('token') 439 "token": wx.getStorageSync('token')
441 }; 440 };
442 app.post(url, params, {}).then((res) => { 441 app.post(url, params, {}).then((res) => {
443 - console.log('获取首页', res); 442 + // console.log('获取首页', res);
444 if (+res.code === 1) { 443 if (+res.code === 1) {
445 wx.hideLoading(); 444 wx.hideLoading();
446 self.setData({ 445 self.setData({
@@ -452,7 +451,7 @@ Page({ @@ -452,7 +451,7 @@ Page({
452 items: res.data.active, 451 items: res.data.active,
453 is_canSend: res.data.is_canSend, 452 is_canSend: res.data.is_canSend,
454 }); 453 });
455 - console.log('meal',res.data.meal); 454 + // console.log('meal',res.data.meal);
456 wx.setStorageSync('is_canSend', res.data.is_canSend);//1:可以发布2:不可以发布 455 wx.setStorageSync('is_canSend', res.data.is_canSend);//1:可以发布2:不可以发布
457 wx.setStorageSync('is_answer', res.data.is_answer);//1:已答题2:未答题 456 wx.setStorageSync('is_answer', res.data.is_answer);//1:已答题2:未答题
458 // is_answer 457 // is_answer
@@ -472,7 +471,7 @@ Page({ @@ -472,7 +471,7 @@ Page({
472 "token": wx.getStorageSync('token') 471 "token": wx.getStorageSync('token')
473 }; 472 };
474 app.post(url, params, {}).then((res) => { 473 app.post(url, params, {}).then((res) => {
475 - console.log('是否填写个人信息', res); 474 + // console.log('是否填写个人信息', res);
476 if (+res.code === 1) { 475 if (+res.code === 1) {
477 self.setData({ 476 self.setData({
478 is_write: res.data.is_write,//1:已填写2:未填写 477 is_write: res.data.is_write,//1:已填写2:未填写
@@ -497,7 +496,7 @@ Page({ @@ -497,7 +496,7 @@ Page({
497 if (wx.getStorageSync('lat') !== '' && 496 if (wx.getStorageSync('lat') !== '' &&
498 wx.getStorageSync('lng') !== '' && 497 wx.getStorageSync('lng') !== '' &&
499 wx.getStorageSync('addr') !== '') { 498 wx.getStorageSync('addr') !== '') {
500 - console.log('已选择城市'); 499 + // console.log('已选择城市');
501 this.setData({ 500 this.setData({
502 is_city_change: true, 501 is_city_change: true,
503 lat: wx.getStorageSync('lat'), 502 lat: wx.getStorageSync('lat'),
@@ -521,7 +520,7 @@ Page({ @@ -521,7 +520,7 @@ Page({
521 // name: "", 520 // name: "",
522 // address: "" 521 // address: ""
523 // }) 522 // })
524 - console.log('index-show-isLogin', wx.getStorageSync('isLogin')); 523 + // console.log('index-show-isLogin', wx.getStorageSync('isLogin'));
525 // console.log(app.globalData.userInfo); 524 // console.log(app.globalData.userInfo);
526 }, 525 },
527 onPageScroll(e) { 526 onPageScroll(e) {
@@ -15,7 +15,7 @@ Page({ @@ -15,7 +15,7 @@ Page({
15 token: wx.getStorageSync('token'), 15 token: wx.getStorageSync('token'),
16 }; 16 };
17 app.post(url, {}, {}).then((res) => { 17 app.post(url, {}, {}).then((res) => {
18 - console.log('获取推荐列表', res); 18 + // console.log('获取推荐列表', res);
19 if (+res.code === 1) { 19 if (+res.code === 1) {
20 var article = res.data.content; 20 var article = res.data.content;
21 WxParse.wxParse('article', 'html', article, self, 5); 21 WxParse.wxParse('article', 'html', article, self, 5);
@@ -22,7 +22,7 @@ Page({ @@ -22,7 +22,7 @@ Page({
22 }, 22 },
23 //选择性别 23 //选择性别
24 sexPickerChange(e) { 24 sexPickerChange(e) {
25 - console.log('picker发送选择改变,携带值为', e.detail.value) 25 + // console.log('picker发送选择改变,携带值为', e.detail.value)
26 this.setData({ 26 this.setData({
27 current_sex: e.detail.value, 27 current_sex: e.detail.value,
28 is_sex_change: true 28 is_sex_change: true
@@ -38,18 +38,18 @@ Page({ @@ -38,18 +38,18 @@ Page({
38 if(!(/^1[0-9]{10}$/.test(this.data.phone_number))){ 38 if(!(/^1[0-9]{10}$/.test(this.data.phone_number))){
39 wx.showToast({title:'手机号格式错误',icon:'none'}); 39 wx.showToast({title:'手机号格式错误',icon:'none'});
40 this.setData({is_wrong_phone:true,phone_number_params:''}); 40 this.setData({is_wrong_phone:true,phone_number_params:''});
41 - console.log('params', this.data.phone_number_params); 41 + // console.log('params', this.data.phone_number_params);
42 }else { 42 }else {
43 this.setData({ 43 this.setData({
44 phone_number_params: this.data.phone_number, 44 phone_number_params: this.data.phone_number,
45 'user.tel':this.data.phone_number, 45 'user.tel':this.data.phone_number,
46 is_wrong_phone:false, 46 is_wrong_phone:false,
47 }); 47 });
48 - console.log('params', this.data.phone_number_params); 48 + // console.log('params', this.data.phone_number_params);
49 } 49 }
50 } 50 }
51 if(e.detail.value === '') { 51 if(e.detail.value === '') {
52 - console.log('手机号为空',this.data.is_wrong_phone,this.data.phone_number_params,this.data.is_choose_phone); 52 + // console.log('手机号为空',this.data.is_wrong_phone,this.data.phone_number_params,this.data.is_choose_phone);
53 this.setData({is_change:false});//按钮置灰 53 this.setData({is_change:false});//按钮置灰
54 } 54 }
55 if((this.data.is_choose_phone&&this.data.phone_number_params !== '') && 55 if((this.data.is_choose_phone&&this.data.phone_number_params !== '') &&
@@ -57,7 +57,7 @@ Page({ @@ -57,7 +57,7 @@ Page({
57 this.data.user.city !== null && 57 this.data.user.city !== null &&
58 this.data.user.introduce !== null 58 this.data.user.introduce !== null
59 ){ 59 ){
60 - console.log(2); 60 + // console.log(2);
61 this.setData({is_change:true}); 61 this.setData({is_change:true});
62 } 62 }
63 }, 63 },
@@ -67,7 +67,7 @@ Page({ @@ -67,7 +67,7 @@ Page({
67 if(!(/^1[0-9]{10}$/.test(this.data.phone_number))){ 67 if(!(/^1[0-9]{10}$/.test(this.data.phone_number))){
68 wx.showToast({title:'手机号格式错误',icon:'none'}); 68 wx.showToast({title:'手机号格式错误',icon:'none'});
69 this.setData({is_wrong_phone:true,phone_number_params:''}); 69 this.setData({is_wrong_phone:true,phone_number_params:''});
70 - console.log('params', this.data.phone_number_params); 70 + // console.log('params', this.data.phone_number_params);
71 } 71 }
72 // } 72 // }
73 }, 73 },
@@ -83,7 +83,7 @@ Page({ @@ -83,7 +83,7 @@ Page({
83 iv:e.detail.iv, 83 iv:e.detail.iv,
84 }; 84 };
85 app.post(url, params, {}).then((res) => { 85 app.post(url, params, {}).then((res) => {
86 - console.log('自动获取手机号', res); 86 + // console.log('自动获取手机号', res);
87 if (+res.code === 1) { 87 if (+res.code === 1) {
88 this.setData({'user.tel':res.data,phone_number:res.data,is_wrong_phone:false,is_choose_phone:true}) 88 this.setData({'user.tel':res.data,phone_number:res.data,is_wrong_phone:false,is_choose_phone:true})
89 } 89 }
@@ -103,7 +103,7 @@ Page({ @@ -103,7 +103,7 @@ Page({
103 this.data.user.tel !== null && 103 this.data.user.tel !== null &&
104 this.data.user.introduce !== null 104 this.data.user.introduce !== null
105 ){ 105 ){
106 - console.log(2); 106 + // console.log(2);
107 this.setData({is_change:true}); 107 this.setData({is_change:true});
108 } 108 }
109 }, 109 },
@@ -121,7 +121,7 @@ Page({ @@ -121,7 +121,7 @@ Page({
121 this.data.user.tel !== null && 121 this.data.user.tel !== null &&
122 this.data.user.introduce !== null 122 this.data.user.introduce !== null
123 ){ 123 ){
124 - console.log(2); 124 + // console.log(2);
125 this.setData({is_change:true}); 125 this.setData({is_change:true});
126 } 126 }
127 }, 127 },
@@ -139,7 +139,7 @@ Page({ @@ -139,7 +139,7 @@ Page({
139 this.data.user.tel !== null && 139 this.data.user.tel !== null &&
140 this.data.user.introduce !== null 140 this.data.user.introduce !== null
141 ){ 141 ){
142 - console.log(2); 142 + // console.log(2);
143 this.setData({is_change:true}); 143 this.setData({is_change:true});
144 } 144 }
145 }, 145 },
@@ -164,14 +164,14 @@ Page({ @@ -164,14 +164,14 @@ Page({
164 if(e.detail.value === '') { 164 if(e.detail.value === '') {
165 this.setData({is_change:false}); 165 this.setData({is_change:false});
166 } 166 }
167 - console.log('textcontent', textcontent); 167 + // console.log('textcontent', textcontent);
168 if((this.data.is_choose_introduce&&this.data.introduce !== '') && 168 if((this.data.is_choose_introduce&&this.data.introduce !== '') &&
169 this.data.user.city !== null && 169 this.data.user.city !== null &&
170 this.data.user.tel !== null && 170 this.data.user.tel !== null &&
171 this.data.user.country !== null && 171 this.data.user.country !== null &&
172 this.data.user.wx !== null 172 this.data.user.wx !== null
173 ){ 173 ){
174 - console.log(2); 174 + // console.log(2);
175 this.setData({is_change:true}); 175 this.setData({is_change:true});
176 } 176 }
177 if((this.data.is_choose_country&&this.data.country !== '')&& 177 if((this.data.is_choose_country&&this.data.country !== '')&&
@@ -180,14 +180,14 @@ Page({ @@ -180,14 +180,14 @@ Page({
180 (this.data.is_choose_introduce&&this.data.introduce !== '') && 180 (this.data.is_choose_introduce&&this.data.introduce !== '') &&
181 (this.data.is_choose_wx&&this.data.wx_num !== '') 181 (this.data.is_choose_wx&&this.data.wx_num !== '')
182 ) { 182 ) {
183 - console.log(1); 183 + // console.log(1);
184 this.setData({is_change:true}); 184 this.setData({is_change:true});
185 } 185 }
186 } 186 }
187 }, 187 },
188 //保存 188 //保存
189 submit() { 189 submit() {
190 - console.log('this.data.phone_number.length', this.data.phone_number.length,this.data.is_sex_change); 190 + // console.log('this.data.phone_number.length', this.data.phone_number.length,this.data.is_sex_change);
191 if(this.data.userInfo.gender == '未知' && this.data.is_sex_change === undefined) { 191 if(this.data.userInfo.gender == '未知' && this.data.is_sex_change === undefined) {
192 wx.showToast({title:'请选择性别',icon:'none'}) 192 wx.showToast({title:'请选择性别',icon:'none'})
193 }else if(this.data.country === '' && this.data.user.country === null) { 193 }else if(this.data.country === '' && this.data.user.country === null) {
@@ -217,7 +217,7 @@ Page({ @@ -217,7 +217,7 @@ Page({
217 introduce:this.data.is_choose_introduce?this.data.introduce:this.data.user.introduce 217 introduce:this.data.is_choose_introduce?this.data.introduce:this.data.user.introduce
218 }; 218 };
219 app.post(url, params, {}).then((res) => { 219 app.post(url, params, {}).then((res) => {
220 - console.log('保存', res); 220 + // console.log('保存', res);
221 if (+res.code === 1) { 221 if (+res.code === 1) {
222 wx.showToast({title:res.message,icon:'none', 222 wx.showToast({title:res.message,icon:'none',
223 success:function () { 223 success:function () {
@@ -236,7 +236,7 @@ Page({ @@ -236,7 +236,7 @@ Page({
236 token: wx.getStorageSync('token'), 236 token: wx.getStorageSync('token'),
237 }; 237 };
238 app.post(url, params, {}).then((res) => { 238 app.post(url, params, {}).then((res) => {
239 - console.log('获取个人信息', res); 239 + // console.log('获取个人信息', res);
240 if (+res.code === 1) { 240 if (+res.code === 1) {
241 this.setData({user:res.data}); 241 this.setData({user:res.data});
242 if(this.data.user.country === null || 242 if(this.data.user.country === null ||
@@ -263,7 +263,7 @@ Page({ @@ -263,7 +263,7 @@ Page({
263 if(this.data.userInfo.tel !== null) { 263 if(this.data.userInfo.tel !== null) {
264 this.setData({is_wrong_phone:false}) 264 this.setData({is_wrong_phone:false})
265 } 265 }
266 - console.log('userInfo', this.data.userInfo); 266 + // console.log('userInfo', this.data.userInfo);
267 this.getDetail(); 267 this.getDetail();
268 268
269 }, 269 },
@@ -13,7 +13,7 @@ Page({ @@ -13,7 +13,7 @@ Page({
13 goPostDetail(e) { 13 goPostDetail(e) {
14 const id = +e.currentTarget.dataset.activity_id; 14 const id = +e.currentTarget.dataset.activity_id;
15 const type = +e.currentTarget.dataset.type; 15 const type = +e.currentTarget.dataset.type;
16 - console.log('type', type); 16 + // console.log('type', type);
17 if(type === 1) { //1是活动,2是拼餐 17 if(type === 1) { //1是活动,2是拼餐
18 wx.navigateTo({ 18 wx.navigateTo({
19 url: '/pages/activity/detail/detail?id=' + id, 19 url: '/pages/activity/detail/detail?id=' + id,
@@ -31,7 +31,7 @@ Page({ @@ -31,7 +31,7 @@ Page({
31 token: wx.getStorageSync('token'), 31 token: wx.getStorageSync('token'),
32 }; 32 };
33 app.post(url, params, {}).then((res) => { 33 app.post(url, params, {}).then((res) => {
34 - console.log('获取收藏列表', res); 34 + // console.log('获取收藏列表', res);
35 if (+res.code === 1) { 35 if (+res.code === 1) {
36 this.setData({ 36 this.setData({
37 collectList: this.data.collectList.concat(res.data), 37 collectList: this.data.collectList.concat(res.data),
@@ -20,7 +20,7 @@ Page({ @@ -20,7 +20,7 @@ Page({
20 token: wx.getStorageSync('token'), 20 token: wx.getStorageSync('token'),
21 }; 21 };
22 app.post(url, params, {}).then((res) => { 22 app.post(url, params, {}).then((res) => {
23 - console.log('获取我的钱包', res); 23 + // console.log('获取我的钱包', res);
24 if (+res.code === 1) { 24 if (+res.code === 1) {
25 this.setData({ 25 this.setData({
26 list: res.data.list, 26 list: res.data.list,