作者 刘晓艳

穿搭小程序bug 修改

@@ -2,9 +2,9 @@ @@ -2,9 +2,9 @@
2 App({ 2 App({
3 post: function (url, data, headerParams) { 3 post: function (url, data, headerParams) {
4 wx.showNavigationBarLoading() 4 wx.showNavigationBarLoading()
5 - wx.showLoading({  
6 - title: '',  
7 - }) 5 + // wx.showLoading({
  6 + // title: '',
  7 + // })
8 var promise = new Promise((resolve, reject) => { 8 var promise = new Promise((resolve, reject) => {
9 let that = this; 9 let that = this;
10 let postData = data; 10 let postData = data;
@@ -40,6 +40,15 @@ App({ @@ -40,6 +40,15 @@ App({
40 wx.hideLoading() 40 wx.hideLoading()
41 return promise; 41 return promise;
42 }, 42 },
  43 +
  44 + nowDate(later) {
  45 + let date = new Date();
  46 + date.setDate(date.getDate() + later);
  47 + let month = date.getMonth() + 1;
  48 + let day = date.getDate();
  49 + return date.getFullYear() + '/' + (month > 9 ? month : ('0' + month)) + '/' + (day > 9 ? day : ('0' + day));
  50 + },
  51 +
43 globalData: { 52 globalData: {
44 userInfo: null 53 userInfo: null
45 } 54 }
@@ -14,7 +14,18 @@ Page({ @@ -14,7 +14,18 @@ Page({
14 list: [], 14 list: [],
15 state: false, 15 state: false,
16 name: '', 16 name: '',
17 - comment_text: '' 17 + comment_text: '',
  18 + user_id: '',
  19 + },
  20 +
  21 +
  22 + //评论
  23 + review(e) {
  24 + var id = e.currentTarget.dataset.id
  25 + var type = e.currentTarget.dataset.type
  26 + wx.navigateTo({
  27 + url: '/pages/index/comment/comment?id=' + id + '&type=' + type,
  28 + })
18 }, 29 },
19 30
20 showPoster(e) { 31 showPoster(e) {
@@ -22,19 +33,12 @@ Page({ @@ -22,19 +33,12 @@ Page({
22 var that = this 33 var that = this
23 var list = that.data.list 34 var list = that.data.list
24 list.showMore = false 35 list.showMore = false
25 - wx.hideTabBar({})  
26 wx.showToast({ 36 wx.showToast({
27 title: '加载中', 37 title: '加载中',
28 icon: 'loading', 38 icon: 'loading',
29 - // success: (res) => {  
30 - // setTimeout((res) => {  
31 -  
32 - // }, 2000)  
33 -  
34 - // }, 39 + duration: 2000
35 }) 40 })
36 - that.setData({  
37 - poster_state: true, 41 + this.setData({
38 more_state: false 42 more_state: false
39 }) 43 })
40 this.getPoster(id) 44 this.getPoster(id)
@@ -70,6 +74,22 @@ Page({ @@ -70,6 +74,22 @@ Page({
70 this.setData({ 74 this.setData({
71 poster: res.data.data.url, 75 poster: res.data.data.url,
72 }) 76 })
  77 + setTimeout((res) => {
  78 + that.setData({
  79 + poster_state: true
  80 + })
  81 + wx.hideTabBar({})
  82 + })
  83 + } else if (res.data.code == 30001) {
  84 + wx.showToast({
  85 + title: '上传图片才可生成海报',
  86 + icon: 'none',
  87 + duration: 2000
  88 + })
  89 + that.setData({
  90 + poster_state: false
  91 + })
  92 + wx.showTabBar({})
73 } 93 }
74 94
75 }) 95 })
@@ -273,9 +293,10 @@ Page({ @@ -273,9 +293,10 @@ Page({
273 * 生命周期函数--监听页面加载 293 * 生命周期函数--监听页面加载
274 */ 294 */
275 onLoad: function(options) { 295 onLoad: function(options) {
276 - options.id ? (this.setData({  
277 - id: options.id  
278 - }), this.getData()) : '' 296 + this.setData({
  297 + id: options.id ? options.id : '',
  298 + user_id: wx.getStorageSync('user_id')
  299 + })
279 }, 300 },
280 301
281 /** 302 /**
@@ -289,7 +310,7 @@ Page({ @@ -289,7 +310,7 @@ Page({
289 * 生命周期函数--监听页面显示 310 * 生命周期函数--监听页面显示
290 */ 311 */
291 onShow: function() { 312 onShow: function() {
292 - 313 + this.getData()
293 }, 314 },
294 315
295 /** 316 /**
@@ -9,8 +9,8 @@ @@ -9,8 +9,8 @@
9 <view class='list_head_box2'> 9 <view class='list_head_box2'>
10 <view class='user_name' catchtap='showModal' data-index="{{index}}">{{list.user_nickname}}</view> 10 <view class='user_name' catchtap='showModal' data-index="{{index}}">{{list.user_nickname}}</view>
11 <view class='state_box'> 11 <view class='state_box'>
12 - <block>  
13 - <view class="collect_box {{list.user_host==1?'active':''}}" bindtap='attention' data-id='{{list.open_user_id}}'> 12 + <block wx:if='{{list.open_user_id!=user_id}}'>
  13 + <view class="collect_box {{list.user_host==1?'active':''}}" bindtap='attention' data-id='{{list.open_user_id}}'>
14 <text class='iconfont icon-shoucang0 star2'></text> 14 <text class='iconfont icon-shoucang0 star2'></text>
15 <text class="collect_word">{{list.user_host==1?'取消关注':'关注TA'}}</text> 15 <text class="collect_word">{{list.user_host==1?'取消关注':'关注TA'}}</text>
16 </view> 16 </view>
@@ -38,7 +38,7 @@ @@ -38,7 +38,7 @@
38 <text class='iconfont icon-huida pinglun1' wx:else></text> 38 <text class='iconfont icon-huida pinglun1' wx:else></text>
39 <text class=''>{{list.support}}</text> 39 <text class=''>{{list.support}}</text>
40 </view> 40 </view>
41 - <view > 41 + <view catchtap='review' data-id='{{list.id}}' data-type='review'>
42 <text class='iconfont icon-pinglun pinglun1'></text> 42 <text class='iconfont icon-pinglun pinglun1'></text>
43 <text>{{list.table_num}}</text> 43 <text>{{list.table_num}}</text>
44 </view> 44 </view>
@@ -10,8 +10,14 @@ @@ -10,8 +10,14 @@
10 </view> 10 </view>
11 </view> 11 </view>
12 </view> 12 </view>
13 - <view class="list_label" catchtap='showMask' data-id='{{item.id}}' data-status='1' wx:if='{{status==2}}'>添加关注</view>  
14 - <view class="list_label list_active" catchtap='showMask' data-id='{{item.id}}' data-status='2' wx:if='{{status==1}}'>取消关注</view> 13 + <block wx:if='{{status==2}}'>
  14 + <view class="list_label" catchtap='showMask' data-id='{{item.id}}' data-status='1' wx:if='{{item.status!=1}}'>添加关注</view>
  15 + <view class="list_label list_active" catchtap='showMask' data-id='{{item.id}}' data-status='2' wx:if='{{item.status==1}}'>取消关注</view>
  16 + </block>
  17 + <block wx:else>
  18 + <view class="list_label" catchtap='showMask' data-id='{{item.id}}' data-status='1' wx:if='{{status==2}}'>添加关注</view>
  19 + <view class="list_label list_active" catchtap='showMask' data-id='{{item.id}}' data-status='2' wx:if='{{status==1}}'>取消关注</view>
  20 + </block>
15 </view> 21 </view>
16 </view> 22 </view>
17 23
@@ -37,7 +37,21 @@ Page({ @@ -37,7 +37,21 @@ Page({
37 list2: [], 37 list2: [],
38 last_page: '', 38 last_page: '',
39 state: true, 39 state: true,
40 - tempHeight: '' 40 + release_state: false,
  41 + release_state1: false,
  42 + user_id:''
  43 + },
  44 +
  45 + goInfo() {
  46 + wx.navigateTo({
  47 + url: '/pages/index/info/info',
  48 + })
  49 + },
  50 +
  51 + cancleInfo() {
  52 + this.setData({
  53 + release_state1: false
  54 + })
41 }, 55 },
42 56
43 saveImg(e) { 57 saveImg(e) {
@@ -70,9 +84,16 @@ Page({ @@ -70,9 +84,16 @@ Page({
70 84
71 goUserInfo(e) { 85 goUserInfo(e) {
72 var id = e.currentTarget.dataset.id 86 var id = e.currentTarget.dataset.id
73 - wx.navigateTo({  
74 - url: '/pages/my/userInfo/userInfo?id=' + id,  
75 - }) 87 + var user_id = wx.getStorageSync('user_id')
  88 + if (id != user_id) {
  89 + wx.navigateTo({
  90 + url: '/pages/my/userInfo/userInfo?id=' + id,
  91 + })
  92 + } else {
  93 + wx.switchTab({
  94 + url: '/pages/my/my',
  95 + })
  96 + }
76 }, 97 },
77 98
78 viewImg(e) { 99 viewImg(e) {
@@ -81,7 +102,6 @@ Page({ @@ -81,7 +102,6 @@ Page({
81 var list = this.data.list 102 var list = this.data.list
82 var imgs = list[mindex].img 103 var imgs = list[mindex].img
83 var current = e.currentTarget.dataset.src 104 var current = e.currentTarget.dataset.src
84 - // console.log(imgs)  
85 this.setData({ 105 this.setData({
86 imgUrl: current, 106 imgUrl: current,
87 img_text: e.currentTarget.dataset.text, 107 img_text: e.currentTarget.dataset.text,
@@ -208,7 +228,7 @@ Page({ @@ -208,7 +228,7 @@ Page({
208 } 228 }
209 app.post(url, params, header).then((res) => { 229 app.post(url, params, header).then((res) => {
210 if (res.data.code == 20000) { 230 if (res.data.code == 20000) {
211 - var page = parseInt(this.data.page)-1 231 + var page = parseInt(this.data.page) - 1
212 that.setData({ 232 that.setData({
213 list: [], 233 list: [],
214 page: page, 234 page: page,
@@ -248,7 +268,6 @@ Page({ @@ -248,7 +268,6 @@ Page({
248 'XX-Device-Type': 'wxapp' 268 'XX-Device-Type': 'wxapp'
249 } 269 }
250 app.post(url, params, header).then((res) => { 270 app.post(url, params, header).then((res) => {
251 - console.log(res)  
252 if (res.data.code == 20000) { 271 if (res.data.code == 20000) {
253 this.setData({ 272 this.setData({
254 list: [], 273 list: [],
@@ -274,6 +293,7 @@ Page({ @@ -274,6 +293,7 @@ Page({
274 classify_state: !(this.data.classify_state) 293 classify_state: !(this.data.classify_state)
275 }) 294 })
276 }, 295 },
  296 +
277 cancleClassify() { 297 cancleClassify() {
278 this.setData({ 298 this.setData({
279 classify_state: false 299 classify_state: false
@@ -293,13 +313,16 @@ Page({ @@ -293,13 +313,16 @@ Page({
293 showPoster(e) { 313 showPoster(e) {
294 var id = e.currentTarget.dataset.id 314 var id = e.currentTarget.dataset.id
295 var that = this 315 var that = this
296 - wx.hideTabBar({}) 316 + var index = e.currentTarget.dataset.index
  317 + var list = this.data.list
  318 + list[index].more_state = false
  319 + this.setData({
  320 + list: list
  321 + })
297 wx.showToast({ 322 wx.showToast({
298 title: '加载中', 323 title: '加载中',
299 - icon: 'loading'  
300 - })  
301 - that.setData({  
302 - poster_state: true 324 + icon: 'loading',
  325 + duration: 2000
303 }) 326 })
304 this.getPoster(id) 327 this.getPoster(id)
305 }, 328 },
@@ -327,35 +350,29 @@ Page({ @@ -327,35 +350,29 @@ Page({
327 'XX-Device-Type': 'wxapp' 350 'XX-Device-Type': 'wxapp'
328 } 351 }
329 app.post(url, param, header).then((res) => { 352 app.post(url, param, header).then((res) => {
330 - console.log(res)  
331 -  
332 if (res.data.code == 20000) { 353 if (res.data.code == 20000) {
333 that.setData({ 354 that.setData({
334 poster: res.data.data.url, 355 poster: res.data.data.url,
335 }) 356 })
336 - that.setData({  
337 - state: true 357 + setTimeout((res) => {
  358 + that.setData({
  359 + poster_state: true
  360 + })
  361 + wx.hideTabBar({})
338 }) 362 })
339 } else if (res.data.code == 30001) { 363 } else if (res.data.code == 30001) {
340 wx.showToast({ 364 wx.showToast({
341 title: '上传图片才可生成海报', 365 title: '上传图片才可生成海报',
342 - icon: 'none' 366 + icon: 'none',
  367 + duration: 2000
343 }) 368 })
344 - setTimeout(function() {  
345 - that.setData({  
346 - poster_state: false  
347 - })  
348 - wx.showTabBar({  
349 -  
350 - })  
351 - }, 2000)  
352 that.setData({ 369 that.setData({
353 - state: false 370 + poster_state: false
354 }) 371 })
  372 + wx.showTabBar({})
355 } 373 }
356 -  
357 }) 374 })
358 - }, 375 + },
359 376
360 complain(e) { 377 complain(e) {
361 var id = e.currentTarget.dataset.id 378 var id = e.currentTarget.dataset.id
@@ -379,10 +396,9 @@ Page({ @@ -379,10 +396,9 @@ Page({
379 }, 396 },
380 397
381 releaseInfo() { 398 releaseInfo() {
382 - if (this.data.tempHeight == '') {  
383 - wx.showToast({  
384 - title: '请去完善身份信息',  
385 - icon: 'none' 399 + if (this.data.release_state) {
  400 + this.setData({
  401 + release_state1: true
386 }) 402 })
387 } else { 403 } else {
388 wx.navigateTo({ 404 wx.navigateTo({
@@ -445,10 +461,14 @@ Page({ @@ -445,10 +461,14 @@ Page({
445 }, 461 },
446 462
447 confirmData() { 463 confirmData() {
448 - this.getData()  
449 this.setData({ 464 this.setData({
450 - classify_state: false 465 + classify_state: false,
  466 + list:[],
  467 + page:1
451 }) 468 })
  469 + this.getData()
  470 +
  471 +
452 }, 472 },
453 473
454 getStyle() { 474 getStyle() {
@@ -490,9 +510,6 @@ Page({ @@ -490,9 +510,6 @@ Page({
490 console.log('data', res) 510 console.log('data', res)
491 if (res.data.code == 20000) { 511 if (res.data.code == 20000) {
492 var list = this.data.list 512 var list = this.data.list
493 - // for (var i = 0; i < list.length; i++) {  
494 - // list[i].more_state = false  
495 - // }  
496 if (res.data.data.list != '') { 513 if (res.data.data.list != '') {
497 that.setData({ 514 that.setData({
498 list: list.concat(res.data.data.list), 515 list: list.concat(res.data.data.list),
@@ -526,34 +543,36 @@ Page({ @@ -526,34 +543,36 @@ Page({
526 'XX-Device-Type': 'wxapp' 543 'XX-Device-Type': 'wxapp'
527 } 544 }
528 app.post(url, params, header).then((res) => { 545 app.post(url, params, header).then((res) => {
529 - console.log('userinfo', res)  
530 if (res.data.code == 20000) { 546 if (res.data.code == 20000) {
531 - this.setData({  
532 - // avatar: res.data.data.avatar,  
533 - // birthday: birthday,  
534 - // constellation: res.data.data.constellation,  
535 - // sex_index: sex_index,  
536 - // signature: res.data.data.signature,  
537 - tempHeight: res.data.data.stature,  
538 - // user_name: res.data.data.user_nickname,  
539 - // weight: res.data.data.weight,  
540 - }) 547 + var height = res.data.data.stature
  548 + var weight = res.data.data.weight
  549 + var sex_index = res.data.data.sex
  550 + if (height == null || weight == null) {
  551 + this.setData({
  552 + release_state: true
  553 + })
  554 + }
  555 +
541 } 556 }
542 557
543 }) 558 })
544 }, 559 },
545 onLoad: function() { 560 onLoad: function() {
546 - // this.getData()  
547 this.getStyle() 561 this.getStyle()
548 this.getUserInfo() 562 this.getUserInfo()
  563 + this.setData({
  564 + user_id:wx.getStorageSync('user_id')
  565 + })
549 }, 566 },
550 567
551 onShow() { 568 onShow() {
552 this.setData({ 569 this.setData({
553 list: [], 570 list: [],
554 - page: 1 571 + page: 1,
  572 + user_id: wx.getStorageSync('user_id')
555 }) 573 })
556 this.getData() 574 this.getData()
  575 + this.getUserInfo()
557 }, 576 },
558 577
559 onReachBottom: function() { 578 onReachBottom: function() {
@@ -23,7 +23,7 @@ @@ -23,7 +23,7 @@
23 <view class='item_list'> 23 <view class='item_list'>
24 <view class='list_head_box'> 24 <view class='list_head_box'>
25 <view class='user_name'>{{item.user_nickname}}</view> 25 <view class='user_name'>{{item.user_nickname}}</view>
26 - <view class=' state_box'> 26 + <view class=' state_box' wx:if='{{item.open_user_id!=user_id}}'>
27 <view class="collect_box {{item.user_host==1?'active':''}}" catchtap='showMask' data-index="{{mindex}}" data-id='{{item.open_user_id}}' data-host='{{item.user_host}}'> 27 <view class="collect_box {{item.user_host==1?'active':''}}" catchtap='showMask' data-index="{{mindex}}" data-id='{{item.open_user_id}}' data-host='{{item.user_host}}'>
28 <text class="collect_word">{{item.user_host==1?'取消关注':'关注TA'}}</text> 28 <text class="collect_word">{{item.user_host==1?'取消关注':'关注TA'}}</text>
29 </view> 29 </view>
@@ -61,7 +61,7 @@ @@ -61,7 +61,7 @@
61 <view class='more_box'> 61 <view class='more_box'>
62 <text class='iconfont icon-gengduo' catchtap='showMore' data-index='{{mindex}}'></text> 62 <text class='iconfont icon-gengduo' catchtap='showMore' data-index='{{mindex}}'></text>
63 <view class='more_label_box' wx:if='{{item.more_state}}'> 63 <view class='more_label_box' wx:if='{{item.more_state}}'>
64 - <view class='more_item' catchtap='showPoster' data-id="{{item.id}}"> 64 + <view class='more_item' catchtap='showPoster' data-id="{{item.id}}" data-index='{{mindex}}'>
65 <text class='iconfont icon-haibao more'></text> 65 <text class='iconfont icon-haibao more'></text>
66 <text>生成分享海报</text> 66 <text>生成分享海报</text>
67 </view> 67 </view>
@@ -78,7 +78,8 @@ @@ -78,7 +78,8 @@
78 </view> 78 </view>
79 </view> 79 </view>
80 <view class='iconfont icon-jia' bindtap='releaseInfo'></view> 80 <view class='iconfont icon-jia' bindtap='releaseInfo'></view>
81 -<view class="mask_box2 {{!state?'mask3':''}}" wx:if='{{poster_state}}'> 81 + <!-- {{!state?'mask3':''}} -->
  82 +<view class="mask_box2" wx:if='{{poster_state}}'>
82 <!-- <view class="canvasBox"> --> 83 <!-- <view class="canvasBox"> -->
83 <!-- <canvas canvas-id='myCanvas' style=''></canvas> --> 84 <!-- <canvas canvas-id='myCanvas' style=''></canvas> -->
84 <!-- </view> --> 85 <!-- </view> -->
@@ -101,7 +102,7 @@ @@ -101,7 +102,7 @@
101 <view class='popup_img'> 102 <view class='popup_img'>
102 <image src='{{poster}}'></image> 103 <image src='{{poster}}'></image>
103 </view> 104 </view>
104 - <view class='popup_icon_box' wx:if='{{state}}'> 105 + <view class='popup_icon_box'>
105 <view class='popup_btn_box2' bindtap='saveImg' data-src='{{poster}}'> 106 <view class='popup_btn_box2' bindtap='saveImg' data-src='{{poster}}'>
106 <view class='popup_btn2'>保存图片</view> 107 <view class='popup_btn2'>保存图片</view>
107 </view> 108 </view>
@@ -110,7 +111,7 @@ @@ -110,7 +111,7 @@
110 </view> 111 </view>
111 </view> 112 </view>
112 </view> 113 </view>
113 - <view class='iconfont icon-quxiao' bindtap='canclePopup' wx:if='{{state}}'></view> 114 + <view class='iconfont icon-quxiao' bindtap='canclePopup'></view>
114 </view> 115 </view>
115 </view> 116 </view>
116 117
@@ -170,4 +171,14 @@ @@ -170,4 +171,14 @@
170 <view class='popup_btn' bindtap='attentionInfo'>确定</view> 171 <view class='popup_btn' bindtap='attentionInfo'>确定</view>
171 </view> 172 </view>
172 </view> 173 </view>
  174 +</view>
  175 +
  176 +<view class='mask_box' wx:if='{{release_state1}}' catchtap='cancleInfo'>
  177 + <view class='popup_box'>
  178 + <view class='popup_title'>完善资料</view>
  179 + <view>请先完善资料再进行发布</view>
  180 + <view class='popup_btn_box'>
  181 + <view class='popup_btn' style='margin:0 auto;' bindtap='goInfo'>去完善</view>
  182 + </view>
  183 + </view>
173 </view> 184 </view>
@@ -294,7 +294,7 @@ page { @@ -294,7 +294,7 @@ page {
294 .user_name { 294 .user_name {
295 font-size: 30rpx; 295 font-size: 30rpx;
296 color: #000; 296 color: #000;
297 - width: 40%; 297 + /* width: 40%; */
298 } 298 }
299 299
300 .collect_box { 300 .collect_box {
@@ -502,7 +502,7 @@ page { @@ -502,7 +502,7 @@ page {
502 margin-top: 30rpx; 502 margin-top: 30rpx;
503 position: absolute; 503 position: absolute;
504 left: 0; 504 left: 0;
505 - bottom: 0; 505 + bottom:30rpx;
506 } 506 }
507 507
508 .popup_title2 { 508 .popup_title2 {
@@ -21,11 +21,34 @@ Page({ @@ -21,11 +21,34 @@ Page({
21 }) 21 })
22 }, 22 },
23 23
24 - goDetail(e){ 24 + goDetail(e) {
25 var id = e.currentTarget.dataset.id 25 var id = e.currentTarget.dataset.id
  26 + var news_id = e.currentTarget.dataset.news_id
  27 + this.setData({
  28 + news_id: news_id
  29 + })
26 wx.navigateTo({ 30 wx.navigateTo({
27 url: '/pages/index/detail/detail?id=' + id, 31 url: '/pages/index/detail/detail?id=' + id,
28 }) 32 })
  33 +
  34 + },
  35 +
  36 + checkInfo(id) {
  37 + let url = '/home/index/checkNewsType'
  38 + let params = {
  39 + status: this.data.status,
  40 + news_id: this.data.news_id
  41 + }
  42 + let header = {
  43 + "XX-Token": wx.getStorageSync('token'),
  44 + 'XX-Device-Type': 'wxapp'
  45 + }
  46 + app.post(url, params, header).then((res) => {
  47 + console.log(res)
  48 + if (res.data.code == 20000) {
  49 + this.getData()
  50 + }
  51 + })
29 }, 52 },
30 53
31 readState(e) { 54 readState(e) {
@@ -38,7 +61,6 @@ Page({ @@ -38,7 +61,6 @@ Page({
38 } else { 61 } else {
39 this.getData2() 62 this.getData2()
40 } 63 }
41 - console.log(this.data.status)  
42 }, 64 },
43 65
44 getData() { 66 getData() {
@@ -52,7 +74,7 @@ Page({ @@ -52,7 +74,7 @@ Page({
52 'XX-Device-Type': 'wxapp' 74 'XX-Device-Type': 'wxapp'
53 } 75 }
54 app.post(url, params, header).then((res) => { 76 app.post(url, params, header).then((res) => {
55 - console.log(res) 77 + console.log('1',res)
56 if (res.data.code == 20000) { 78 if (res.data.code == 20000) {
57 this.setData({ 79 this.setData({
58 list1: res.data.data.list, 80 list1: res.data.data.list,
@@ -101,7 +123,7 @@ Page({ @@ -101,7 +123,7 @@ Page({
101 * 生命周期函数--监听页面显示 123 * 生命周期函数--监听页面显示
102 */ 124 */
103 onShow: function() { 125 onShow: function() {
104 - 126 + this.checkInfo()
105 }, 127 },
106 128
107 /** 129 /**
@@ -14,11 +14,11 @@ @@ -14,11 +14,11 @@
14 <view> 14 <view>
15 <text wx:if='{{status==1}}'>评论了你的</text> 15 <text wx:if='{{status==1}}'>评论了你的</text>
16 <text wx:elif='{{status==2}}'>点赞了你的</text> 16 <text wx:elif='{{status==2}}'>点赞了你的</text>
17 - <text class='list_hint' catchtap='goDetail' data-id='{{item.list_id}}' >{{item.title}}</text> 17 + <text class='list_hint' catchtap='goDetail' data-id='{{item.list_id}}' data-news_id='{{item.news_id}}'>{{item.title}}</text>
18 </view> 18 </view>
19 </view> 19 </view>
20 </view> 20 </view>
21 - <view class='point' wx:if='{{status==2}}'></view> 21 + <view class='point' wx:if='{{item.status!=1}}'></view>
22 </view> 22 </view>
23 </block> 23 </block>
24 <!-- <block wx:if='{{status==2}} '> 24 <!-- <block wx:if='{{status==2}} '>
@@ -159,8 +159,6 @@ Page({ @@ -159,8 +159,6 @@ Page({
159 var minutes = date.getMinutes() 159 var minutes = date.getMinutes()
160 var seconds = date.getSeconds() 160 var seconds = date.getSeconds()
161 var release_time = this.data.release_time 161 var release_time = this.data.release_time
162 - console.log(release_time)  
163 -  
164 if (week == 0) { 162 if (week == 0) {
165 info = "周日"; 163 info = "周日";
166 } else if (week == 1) { 164 } else if (week == 1) {
@@ -178,18 +176,14 @@ Page({ @@ -178,18 +176,14 @@ Page({
178 } 176 }
179 177
180 var lastMonth = []; 178 var lastMonth = [];
181 - for (var i = 0; i < 30; i++) {  
182 - lastMonth.push(new Date(new Date()  
183 - .setDate(new Date().getDate() + i))  
184 - .toLocaleString().substring(0, 9)) 179 + for (var i = 0; i < 8; i++) {
  180 + lastMonth.push(app.nowDate(i))
  181 + // new Date(new Date().setDate(new Date().getDate() + i)).toLocaleString().substring(0, 9)
185 } 182 }
186 -  
187 this.setData({ 183 this.setData({
188 release_time: release_time, 184 release_time: release_time,
189 lastMonth: lastMonth, 185 lastMonth: lastMonth,
190 - // open_time: year + '/' + month + '/' + day + ' ' + hours + ':00',  
191 }) 186 })
192 -  
193 }, 187 },
194 188
195 tempTime() { 189 tempTime() {
@@ -206,10 +200,17 @@ Page({ @@ -206,10 +200,17 @@ Page({
206 var open_time = time + ' ' + temp_time 200 var open_time = time + ' ' + temp_time
207 var open_time2 = time2 + ' ' + temp_time 201 var open_time2 = time2 + ' ' + temp_time
208 console.log(open_time) 202 console.log(open_time)
209 - this.setData({  
210 - open_time: open_time,  
211 - time_info: open_time2 + ' 发送'  
212 - }) 203 + if (temp_time == '') {
  204 + wx.showToast({
  205 + title: '请选择具体时间段',
  206 + icon: 'none'
  207 + })
  208 + } else {
  209 + this.setData({
  210 + open_time: open_time,
  211 + time_info: open_time2 + ' 发送'
  212 + })
  213 + }
213 }, 214 },
214 215
215 showMask1() { 216 showMask1() {
1 <!--pages/release/release.wxml--> 1 <!--pages/release/release.wxml-->
2 -<view class='banner_box'>  
3 - <view>  
4 - <view class='type_box' bindtap="showPicker">  
5 - <input placeholder='标题' value='{{title}}' bindinput='setTitle' maxlength="{{max}}"></input>  
6 - <text class="input_num">{{currentWordNumber|0}}/{{max}}</text>  
7 - </view>  
8 - <view class='textarea_box'>  
9 - <textarea class='textarea' placeholder='同大家分享一下你的穿搭秘籍吧~' maxlength='{{max2}}' value='{{text}}' bindinput='setText'>  
10 - <text class="number">{{number|0}}/{{max2}}</text>  
11 - </textarea> 2 +<block wx:if='{{!img_state}}'>
  3 + <view class='banner_box'>
  4 + <view>
  5 + <view class='type_box' bindtap="showPicker">
  6 + <input placeholder='标题' value='{{title}}' bindinput='setTitle' maxlength="{{max}}"></input>
  7 + <text class="input_num">{{currentWordNumber|0}}/{{max}}</text>
  8 + </view>
  9 + <view class='textarea_box'>
  10 + <textarea class='textarea' placeholder='同大家分享一下你的穿搭秘籍吧~' maxlength='{{max2}}' value='{{text}}' bindinput='setText'>
  11 + <text class="number">{{number|0}}/{{max2}}</text>
  12 + </textarea>
  13 + </view>
12 </view> 14 </view>
13 - </view>  
14 - <view class='upload_box'>  
15 - <block wx:for="{{images}}" wx:for-item="image" wx:key="index">  
16 - <view class='upload_img'>  
17 - <view class='icon_box'>  
18 - <view class='iconfont icon-jian' catchtap="showMask" data-index="{{index}}"></view>  
19 - <view class="edit_label" catchtap="goEdit" data-index="{{index}}" data-url='{{image.url}}'>编辑</view> 15 + <view class='upload_box'>
  16 + <block wx:for="{{images}}" wx:for-item="image" wx:key="index">
  17 + <view class='upload_img'>
  18 + <view class='icon_box'>
  19 + <view class='iconfont icon-jian' catchtap="showMask" data-index="{{index}}"></view>
  20 + <view class="edit_label" catchtap="goEdit" data-index="{{index}}" data-url='{{image.url}}'>编辑</view>
  21 + </view>
  22 + <image src='{{image.url}}' data-index="{{index}}" mode="aspectFill" bindtap="previewImg"></image>
20 </view> 23 </view>
21 - <image src='{{image.url}}' data-index="{{index}}" mode="aspectFill" bindtap="previewImg"></image> 24 + </block>
  25 + <view class='upload_img' bindtap="choose">
  26 + <view class='iconfont icon-jia2'></view>
22 </view> 27 </view>
23 - </block>  
24 - <view class='upload_img' bindtap="choose">  
25 - <view class='iconfont icon-jia2'></view>  
26 </view> 28 </view>
27 - </view>  
28 - <view class='hint_box'>  
29 - <view class='hint_label' bindtap='showMask1'>{{time_info}}</view>  
30 - <view class='hint_label more_box'>  
31 - <text catchtap='showMore'>{{more_info}}</text>  
32 - <view class='more_label_box' wx:if='{{more_state}}'>  
33 - <view class='more_item' bindtap='setOpen' data-open='1'>  
34 - <text>公开</text>  
35 - </view>  
36 - <!-- <view class='more_line'></view> -->  
37 - <view class='more_item' catchtap='setOpen' data-open='3'>  
38 - <text>仅自己可见</text>  
39 - </view>  
40 - <!-- <view class='more_line'></view> -->  
41 - <view class='more_item' catchtap='setOpen' data-open='2'>  
42 - <text>粉丝可见</text>  
43 - </view>  
44 - <!-- <view class='more_line'></view> -->  
45 - <view class='more_item' catchtap='setOpen' data-open='4'>  
46 - <text>草稿箱</text> 29 + <view class='hint_box'>
  30 + <view class='hint_label' bindtap='showMask1'>{{time_info}}</view>
  31 + <view class='hint_label more_box'>
  32 + <text catchtap='showMore'>{{more_info}}</text>
  33 + <view class='more_label_box' wx:if='{{more_state}}'>
  34 + <view class='more_item' bindtap='setOpen' data-open='1'>
  35 + <text>公开</text>
  36 + </view>
  37 + <!-- <view class='more_line'></view> -->
  38 + <view class='more_item' catchtap='setOpen' data-open='3'>
  39 + <text>仅自己可见</text>
  40 + </view>
  41 + <!-- <view class='more_line'></view> -->
  42 + <view class='more_item' catchtap='setOpen' data-open='2'>
  43 + <text>粉丝可见</text>
  44 + </view>
  45 + <!-- <view class='more_line'></view> -->
  46 + <view class='more_item' catchtap='setOpen' data-open='4'>
  47 + <text>草稿箱</text>
  48 + </view>
47 </view> 49 </view>
48 </view> 50 </view>
49 </view> 51 </view>
50 </view> 52 </view>
51 -</view>  
52 -<view class='content_box'>  
53 - <view class='tab_box'>  
54 - <scroll-view scroll-x>  
55 - <text class='classify_title'>风格</text>  
56 - <view class="tab_item {{item.state?'bgc-active':''}}" wx:for='{{classify}}' wx:key='index' data-index="{{index}}" bindtap="setClassify">{{item.name}}</view>  
57 - </scroll-view> 53 + <view class='content_box'>
  54 + <view class='tab_box'>
  55 + <scroll-view scroll-x>
  56 + <text class='classify_title'>风格</text>
  57 + <view class="tab_item {{item.state?'bgc-active':''}}" wx:for='{{classify}}' wx:key='index' data-index="{{index}}" bindtap="setClassify">{{item.name}}</view>
  58 + </scroll-view>
  59 + </view>
  60 + <view class='null_box'></view>
  61 + <view class='bottom_box'>
  62 + <view class='bottom_btn1' bindtap='submitInfo'>确定发布</view>
  63 + </view>
58 </view> 64 </view>
59 - <view class='null_box'></view>  
60 - <view class='bottom_box'>  
61 - <view class='bottom_btn1' bindtap='submitInfo'>确定发布</view> 65 +</block>
  66 +
  67 +<!-- 编辑图片信息 -->
  68 +<view class='mask_box2' wx:else>
  69 + <view class='item_list2'>
  70 + <image class='list_img' src='{{url}}'></image>
  71 + <view class='list_content_box'>
  72 + <textarea class="areas" placeholder='请输入简要描述' minlength="{{min}}" value='{{imgInfo}}' maxlength="{{max3}}" bindinput="setImgText">
  73 + <text class="currentWordNumber">{{imgInfoNum}}/{{max3}}</text>
  74 + </textarea>
  75 + </view>
62 </view> 76 </view>
  77 + <view class='bottom_btn2' bindtap='goCheck'>确定</view>
63 </view> 78 </view>
64 79
65 -  
66 -  
67 <!-- 定时发送 --> 80 <!-- 定时发送 -->
68 <view class='mask_box' wx:if='{{relsese_state}}' catchtap='cancleMask1'> 81 <view class='mask_box' wx:if='{{relsese_state}}' catchtap='cancleMask1'>
69 <view class='release_box'> 82 <view class='release_box'>
@@ -86,18 +99,7 @@ @@ -86,18 +99,7 @@
86 </view> 99 </view>
87 </view> 100 </view>
88 101
89 -<!-- 编辑图片信息 -->  
90 -<view class='mask_box2' wx:if='{{img_state}}'>  
91 - <view class='item_list2'>  
92 - <image class='list_img' src='{{url}}'></image>  
93 - <view class='list_content_box'>  
94 - <textarea class="areas" placeholder='请输入简要描述' minlength="{{min}}" value='{{imgInfo}}' maxlength="{{max3}}" bindinput="setImgText">  
95 - <text class="currentWordNumber">{{imgInfoNum}}/{{max3}}</text>  
96 - </textarea>  
97 - </view>  
98 - </view>  
99 - <view class='bottom_btn2' bindtap='goCheck'>确定</view>  
100 -</view> 102 +
101 103
102 <!-- 草稿箱 --> 104 <!-- 草稿箱 -->
103 <view class='mask_box' wx:if='{{box_state}}' catchtap='cancleMask3'> 105 <view class='mask_box' wx:if='{{box_state}}' catchtap='cancleMask3'>
@@ -94,7 +94,6 @@ Page({ @@ -94,7 +94,6 @@ Page({
94 }) 94 })
95 }, 95 },
96 96
97 -  
98 goDetail(e) { 97 goDetail(e) {
99 var id = e.currentTarget.dataset.id 98 var id = e.currentTarget.dataset.id
100 wx.navigateTo({ 99 wx.navigateTo({
@@ -117,15 +116,11 @@ Page({ @@ -117,15 +116,11 @@ Page({
117 'XX-Device-Type': 'wxapp' 116 'XX-Device-Type': 'wxapp'
118 } 117 }
119 app.post(url, params, header).then((res) => { 118 app.post(url, params, header).then((res) => {
120 - console.log('sz', res)  
121 if (res.data.code == 20000) { 119 if (res.data.code == 20000) {
122 - if (status == 3) {  
123 - list[index].secret_state = true  
124 - console.log(list)  
125 - this.setData({  
126 - list: list  
127 - })  
128 - } 120 + this.getData()
  121 + wx.showToast({
  122 + title: '设置成功',
  123 + })
129 }else{ 124 }else{
130 wx.showToast({ 125 wx.showToast({
131 title: '设置失败', 126 title: '设置失败',
@@ -175,44 +170,6 @@ Page({ @@ -175,44 +170,6 @@ Page({
175 }) 170 })
176 }, 171 },
177 172
178 - // likeCharge(e) {  
179 - // var id = e.currentTarget.dataset.id  
180 - // var status = e.currentTarget.dataset.status  
181 - // let url = '/home/index/support'  
182 - // let params = {  
183 - // list_id: id,  
184 - // status: status  
185 - // }  
186 - // let header = {  
187 - // "XX-Token": wx.getStorageSync('token'),  
188 - // 'XX-Device-Type': 'wxapp'  
189 - // }  
190 - // app.post(url, params, header).then((res) => {  
191 - // if (res.data.code == 20000) {  
192 - // this.getData()  
193 - // }  
194 - // })  
195 - // },  
196 -  
197 - // collectInfo(e) {  
198 - // var id = e.currentTarget.dataset.id  
199 - // var status = e.currentTarget.dataset.status  
200 - // let url = '/home/index/collect'  
201 - // let params = {  
202 - // list_id: id,  
203 - // status: status  
204 - // }  
205 - // let header = {  
206 - // "XX-Token": wx.getStorageSync('token'),  
207 - // 'XX-Device-Type': 'wxapp'  
208 - // }  
209 - // app.post(url, params, header).then((res) => {  
210 - // if (res.data.code == 20000) {  
211 - // this.getData()  
212 - // }  
213 - // })  
214 - // },  
215 -  
216 //评论 173 //评论
217 review(e) { 174 review(e) {
218 var id = e.currentTarget.dataset.id 175 var id = e.currentTarget.dataset.id
@@ -263,13 +220,14 @@ Page({ @@ -263,13 +220,14 @@ Page({
263 'XX-Device-Type': 'wxapp' 220 'XX-Device-Type': 'wxapp'
264 } 221 }
265 app.post(url, params, header).then((res) => { 222 app.post(url, params, header).then((res) => {
  223 + var user_id = res.data.data.open_user_id
  224 + wx.setStorageSync('user_id', user_id)
266 if (res.data.code == 20000) { 225 if (res.data.code == 20000) {
267 this.setData({ 226 this.setData({
268 avatar: res.data.data.avatar, 227 avatar: res.data.data.avatar,
269 fans_num: res.data.data.fans_num, 228 fans_num: res.data.data.fans_num,
270 host: res.data.data.host, 229 host: res.data.data.host,
271 host_num: res.data.data.host_num, 230 host_num: res.data.data.host_num,
272 - // list: res.data.data.list,  
273 signature: res.data.data.signature, 231 signature: res.data.data.signature,
274 user_nickname: res.data.data.user_nickname 232 user_nickname: res.data.data.user_nickname
275 }) 233 })
@@ -8,7 +8,7 @@ @@ -8,7 +8,7 @@
8 <text class='iconfont icon-xiaoxi'></text> 8 <text class='iconfont icon-xiaoxi'></text>
9 <text>消息</text> 9 <text>消息</text>
10 </view> 10 </view>
11 - </view> 11 + </view>
12 <view class='head_img'> 12 <view class='head_img'>
13 <image class='banner_img' src='{{avatar}}'></image> 13 <image class='banner_img' src='{{avatar}}'></image>
14 <view class='edit_box' bindtap='editInfo'> 14 <view class='edit_box' bindtap='editInfo'>
@@ -49,7 +49,8 @@ @@ -49,7 +49,8 @@
49 </view> 49 </view>
50 </view> 50 </view>
51 <block wx:if='{{list.length==0}}'> 51 <block wx:if='{{list.length==0}}'>
52 - <text class='no_data'>暂无信息</text> 52 + <!-- <text class='no_data' wx:if='{{tab_current==1}}'>该用户还未发布信息哦~</text> -->
  53 + <text class='no_data'>暂无数据</text>
53 </block> 54 </block>
54 <block wx:else> 55 <block wx:else>
55 <view class='item_list' wx:key='' wx:for='{{list}}' wx:key bindtap='goDetail' data-id='{{item.list_id}}'> 56 <view class='item_list' wx:key='' wx:for='{{list}}' wx:key bindtap='goDetail' data-id='{{item.list_id}}'>
@@ -64,18 +65,18 @@ @@ -64,18 +65,18 @@
64 </block> 65 </block>
65 <view class='content_item_box' data-id='{{item.id}}' bindtap='messageDetail'> 66 <view class='content_item_box' data-id='{{item.id}}' bindtap='messageDetail'>
66 <view class='list_content_box'> 67 <view class='list_content_box'>
67 - <view class='list_img'> 68 + <view class='list_img' wx:if="{{item.img!=''}}">
68 <image src='{{item.img.img}}' wx:key=''></image> 69 <image src='{{item.img.img}}' wx:key=''></image>
69 </view> 70 </view>
70 - <view class='list_content'> 71 + <view class='list_content' style="{{item.img==''?'width:100%;':''}}">
71 <view class='content'> 72 <view class='content'>
72 <view class='content_info'>{{item.title}}</view> 73 <view class='content_info'>{{item.title}}</view>
73 <view class='list_label'>{{item.style}}</view> 74 <view class='list_label'>{{item.style}}</view>
74 </view> 75 </view>
75 - <view class='list_state_box'> 76 + <view class='list_state_box' style="{{item.img==''?'margin-top:20rpx;':''}}">
76 <view class='time'>{{item.open_time}}</view> 77 <view class='time'>{{item.open_time}}</view>
77 <view class='list_icon'> 78 <view class='list_icon'>
78 - <view catchtap='likeCharge' data-index="{{index}}" data-id='{{item.list_id}}' wx:if='{{status!=4}}'> 79 + <view catchtap='likeCharge' data-index="{{index}}" data-id='{{item.list_id}}' >
79 <text class='iconfont icon-dianzan2 zan' wx:if="{{item.user_support==1}}"></text> 80 <text class='iconfont icon-dianzan2 zan' wx:if="{{item.user_support==1}}"></text>
80 <text class='iconfont icon-huida pinglun1' wx:else></text> 81 <text class='iconfont icon-huida pinglun1' wx:else></text>
81 <text class=''>{{item.support}}</text> 82 <text class=''>{{item.support}}</text>
@@ -84,7 +85,7 @@ @@ -84,7 +85,7 @@
84 <text class='iconfont icon-pinglun pinglun1'></text> 85 <text class='iconfont icon-pinglun pinglun1'></text>
85 <text>{{item.table}}</text> 86 <text>{{item.table}}</text>
86 </view> 87 </view>
87 - <view catchtap='collectInfo' data-index="{{index}}" data-id='{{item.list_id}}'> 88 + <view catchtap='collectInfo' data-index="{{index}}" data-id='{{item.list_id}}' wx:if='{{status!=4}}'>
88 <text class='iconfont icon-shoucang2 zan' wx:if='{{item.user_collect==1}}'></text> 89 <text class='iconfont icon-shoucang2 zan' wx:if='{{item.user_collect==1}}'></text>
89 <text class='iconfont icon-shoucang4 pinglun1' wx:else></text> 90 <text class='iconfont icon-shoucang4 pinglun1' wx:else></text>
90 <text class=''>{{item.collect}}</text> 91 <text class=''>{{item.collect}}</text>
@@ -118,7 +119,7 @@ @@ -118,7 +119,7 @@
118 </view> 119 </view>
119 </block> 120 </block>
120 </view> 121 </view>
121 - <text class='iconfont icon-suo' wx:if='{{item.secret_state}}'></text> 122 + <text class='iconfont icon-suo' wx:if='{{item.open==3}}'></text>
122 </view> 123 </view>
123 </view> 124 </view>
124 </view> 125 </view>
@@ -128,14 +129,3 @@ @@ -128,14 +129,3 @@
128 </block> 129 </block>
129 </view> 130 </view>
130 131
131 -  
132 -<view class='mask_box' wx:if='{{}}' catchtap='cancleMask'>  
133 - <view class='popup_box'>  
134 - <view class='popup_title'>取消关注</view>  
135 - <view>确认取消关注?</view>  
136 - <view class='popup_btn_box'>  
137 - <view class='popup_btn'>再想想</view>  
138 - <view class='popup_btn'>再想想</view>  
139 - </view>  
140 - </view>  
141 -</view>  
@@ -138,7 +138,7 @@ page { @@ -138,7 +138,7 @@ page {
138 } 138 }
139 139
140 .list_title { 140 .list_title {
141 - width: 25%; 141 + width: 18%;
142 font-size: 32rpx; 142 font-size: 32rpx;
143 font-weight: bold; 143 font-weight: bold;
144 color: #010000; 144 color: #010000;
@@ -179,16 +179,14 @@ page { @@ -179,16 +179,14 @@ page {
179 width: 100%; 179 width: 100%;
180 } 180 }
181 181
182 -.content_item_box {  
183 - width: 100%;  
184 - height: 100%;  
185 -}  
186 182
187 .add-bg { 183 .add-bg {
188 background: #f2f2f2; 184 background: #f2f2f2;
189 padding: 10rpx 10rpx 0 10rpx; 185 padding: 10rpx 10rpx 0 10rpx;
190 } 186 }
191 - 187 +.content_item_box{
  188 + width: 80%;
  189 +}
192 .list_content_box { 190 .list_content_box {
193 display: flex; 191 display: flex;
194 align-items: flex-start; 192 align-items: flex-start;
@@ -206,7 +204,7 @@ page { @@ -206,7 +204,7 @@ page {
206 } 204 }
207 205
208 .content_info { 206 .content_info {
209 - width: 74%; 207 + width: 60%;
210 height: 85rpx; 208 height: 85rpx;
211 display: -webkit-box; 209 display: -webkit-box;
212 -webkit-box-orient: vertical; 210 -webkit-box-orient: vertical;
@@ -293,7 +291,7 @@ page { @@ -293,7 +291,7 @@ page {
293 background: #f5f5f5; 291 background: #f5f5f5;
294 border-radius: 8rpx; 292 border-radius: 8rpx;
295 height: 40rpx; 293 height: 40rpx;
296 - padding: 0 20rpx; 294 + padding: 0 10rpx;
297 display: flex; 295 display: flex;
298 align-items: center; 296 align-items: center;
299 justify-content: center; 297 justify-content: center;
@@ -369,7 +367,7 @@ page { @@ -369,7 +367,7 @@ page {
369 justify-content: space-between; 367 justify-content: space-between;
370 font-size: 26rpx; 368 font-size: 26rpx;
371 color: #999; 369 color: #999;
372 - margin-top: 70rpx; 370 + margin-top: 35rpx;
373 } 371 }
374 372
375 .time { 373 .time {
@@ -142,7 +142,6 @@ Page({ @@ -142,7 +142,6 @@ Page({
142 wx.navigateTo({ 142 wx.navigateTo({
143 url: '/pages/index/comment/comment?id=' + id + '&type=' + type, 143 url: '/pages/index/comment/comment?id=' + id + '&type=' + type,
144 }) 144 })
145 -  
146 }, 145 },
147 getData() { 146 getData() {
148 let url = '/home/index/userPage' 147 let url = '/home/index/userPage'
@@ -31,7 +31,8 @@ @@ -31,7 +31,8 @@
31 </view> 31 </view>
32 </view> 32 </view>
33 <block wx:if='{{list.length==0}}'> 33 <block wx:if='{{list.length==0}}'>
34 - <text class='no_data'>暂无信息</text> 34 + <!-- <text class='no_data' wx:if='{{status==1}}'>该用户还未发布信息哦~</text> -->
  35 + <text class='no_data'>暂无数据</text>
35 </block> 36 </block>
36 <block wx:else> 37 <block wx:else>
37 <block wx:if='{{status==1}}'> 38 <block wx:if='{{status==1}}'>
@@ -39,23 +40,23 @@ @@ -39,23 +40,23 @@
39 <view class='list_title'>{{item.open_time}}</view> 40 <view class='list_title'>{{item.open_time}}</view>
40 <view class='content_item_box'> 41 <view class='content_item_box'>
41 <view class='list_content_box'> 42 <view class='list_content_box'>
42 - <view class='list_img'> 43 + <view class='list_img' wx:if="{{item.img!=''}}">
43 <image src='{{item.img.img}}' wx:key=''></image> 44 <image src='{{item.img.img}}' wx:key=''></image>
44 </view> 45 </view>
45 - <view class='list_content'> 46 + <view class='list_content' style="{{item.img==''?'width:100%;':''}}">
46 <view class='content'> 47 <view class='content'>
47 <view class='content_info'>{{item.title}}</view> 48 <view class='content_info'>{{item.title}}</view>
48 <view class='list_label'>{{item.style}}</view> 49 <view class='list_label'>{{item.style}}</view>
49 </view> 50 </view>
50 - <view class='list_state_box'> 51 + <view class='list_state_box' style="{{item.img==''?'margin-top:20rpx;':''}}">
51 <view class='time'>{{item.open_time}}</view> 52 <view class='time'>{{item.open_time}}</view>
52 <view class='list_icon'> 53 <view class='list_icon'>
53 - <view bindtap='likeCharge' data-index="{{index}}" data-id='{{item.list_id}}' wx:if='{{status!=4}}'> 54 + <view catchtap='likeCharge' data-index="{{index}}" data-id='{{item.list_id}}' wx:if='{{status!=4}}'>
54 <text class='iconfont icon-dianzan2 zan' wx:if="{{item.user_support==1}}"></text> 55 <text class='iconfont icon-dianzan2 zan' wx:if="{{item.user_support==1}}"></text>
55 <text class='iconfont icon-huida pinglun1' wx:else></text> 56 <text class='iconfont icon-huida pinglun1' wx:else></text>
56 <text class=''>{{item.support}}</text> 57 <text class=''>{{item.support}}</text>
57 </view> 58 </view>
58 - <view bindtap='review' data-id='{{item.list_id}}' data-type='review'> 59 + <view catchtap='review' data-id='{{item.list_id}}' data-type='review'>
59 <text class='iconfont icon-pinglun pinglun1'></text> 60 <text class='iconfont icon-pinglun pinglun1'></text>
60 <text>{{item.table}}</text> 61 <text>{{item.table}}</text>
61 </view> 62 </view>
@@ -84,11 +85,14 @@ @@ -84,11 +85,14 @@
84 </view> 85 </view>
85 <view catchtap='goDetail' data-id='{{item.id}}' data-index="{{index}}"> 86 <view catchtap='goDetail' data-id='{{item.id}}' data-index="{{index}}">
86 <view class='list_content1'>{{item.title}}</view> 87 <view class='list_content1'>{{item.title}}</view>
87 - <view class='list_img_box'> 88 + <view class='list_img_box' wx:if="{{item.img!=''}}">
88 <block wx:for='{{item.img}}' wx:for-item='items' wx:key='' wx:for-index='sindex'> 89 <block wx:for='{{item.img}}' wx:for-item='items' wx:key='' wx:for-index='sindex'>
89 <image src='{{items.img}}' catchtap='viewImg' data-src='{{items.img}}' data-text='{{items.text}}' data-mindex="{{mindex}}" data-sindex='{{sindex}}'></image> 90 <image src='{{items.img}}' catchtap='viewImg' data-src='{{items.img}}' data-text='{{items.text}}' data-mindex="{{mindex}}" data-sindex='{{sindex}}'></image>
90 </block> 91 </block>
91 </view> 92 </view>
  93 + <!-- <view class='list_img' wx:if="{{item.img!=''}}">
  94 + <image src='{{item.img.img}}' wx:key=''></image>
  95 + </view> -->
92 <view class='list_content'> 96 <view class='list_content'>
93 <!-- {{item.text}} --> 97 <!-- {{item.text}} -->
94 <text wx:for='{{item.styles}}' wx:for-item='its' wx:key>#{{its}}</text> 98 <text wx:for='{{item.styles}}' wx:for-item='its' wx:key>#{{its}}</text>
@@ -104,7 +108,7 @@ @@ -104,7 +108,7 @@
104 </view> 108 </view>
105 <view bindtap='review' data-id='{{item.id}}' data-type='review'> 109 <view bindtap='review' data-id='{{item.id}}' data-type='review'>
106 <text class='iconfont icon-pinglun pinglun1'></text> 110 <text class='iconfont icon-pinglun pinglun1'></text>
107 - <text>{{item.table_num}}</text> 111 + <text>{{item.table}}</text>
108 </view> 112 </view>
109 <view catchtap='collectInfo' data-index="{{mindex}}" data-id='{{item.id}}'> 113 <view catchtap='collectInfo' data-index="{{mindex}}" data-id='{{item.id}}'>
110 <text class='iconfont icon-shoucang2 zan' wx:if='{{item.user_collect==1}}'></text> 114 <text class='iconfont icon-shoucang2 zan' wx:if='{{item.user_collect==1}}'></text>
@@ -119,7 +123,6 @@ @@ -119,7 +123,6 @@
119 </block> 123 </block>
120 </view> 124 </view>
121 125
122 -  
123 <view class='mask_box' wx:if='{{mask_state}}' catchtap='cancleMask'> 126 <view class='mask_box' wx:if='{{mask_state}}' catchtap='cancleMask'>
124 <view class='popup_box'> 127 <view class='popup_box'>
125 <view class='popup_title'>提示</view> 128 <view class='popup_title'>提示</view>
@@ -8,6 +8,9 @@ page { @@ -8,6 +8,9 @@ page {
8 align-items: flex-start; 8 align-items: flex-start;
9 margin-bottom: 16rpx; 9 margin-bottom: 16rpx;
10 background: #fff; 10 background: #fff;
  11 + border-bottom: 1rpx solid #ebebeb;
  12 + padding: 0 10rpx;
  13 + padding-bottom: 20rpx;
11 } 14 }
12 15
13 .content_item:last-child { 16 .content_item:last-child {
@@ -47,6 +50,7 @@ page { @@ -47,6 +50,7 @@ page {
47 font-size: 30rpx; 50 font-size: 30rpx;
48 color: #000; 51 color: #000;
49 width: 40%; 52 width: 40%;
  53 + margin-bottom: 10rpx;
50 } 54 }
51 55
52 .collect_box { 56 .collect_box {
@@ -342,7 +346,7 @@ page { @@ -342,7 +346,7 @@ page {
342 } 346 }
343 347
344 .content_info { 348 .content_info {
345 - width: 74%; 349 + width: 66%;
346 height: 85rpx; 350 height: 85rpx;
347 display: -webkit-box; 351 display: -webkit-box;
348 -webkit-box-orient: vertical; 352 -webkit-box-orient: vertical;
@@ -512,7 +516,7 @@ page { @@ -512,7 +516,7 @@ page {
512 justify-content: space-between; 516 justify-content: space-between;
513 font-size: 26rpx; 517 font-size: 26rpx;
514 color: #999; 518 color: #999;
515 - margin-top: 70rpx; 519 + margin-top: 38rpx;
516 } 520 }
517 521
518 .time { 522 .time {
@@ -29,9 +29,7 @@ Page({ @@ -29,9 +29,7 @@ Page({
29 url: '/pages/index/index', 29 url: '/pages/index/index',
30 }) 30 })
31 } 31 }
32 -  
33 }).catch((errMsg) => { }) 32 }).catch((errMsg) => { })
34 -  
35 }, 33 },
36 34
37 //获取启动页图片 35 //获取启动页图片
1 <!--pages/topic/topic.wxml--> 1 <!--pages/topic/topic.wxml-->
2 <view class='content_box'> 2 <view class='content_box'>
3 <view class='item_list'> 3 <view class='item_list'>
4 - <image src='{{img}}'></image> 4 + <!-- <image src='{{img}}'></image> -->
5 <view class='list_title'>{{title}}</view> 5 <view class='list_title'>{{title}}</view>
6 <view class='list_content'> 6 <view class='list_content'>
7 <import src="../../../wxParse/wxParse.wxml" /> 7 <import src="../../../wxParse/wxParse.wxml" />
@@ -47,3 +47,20 @@ @@ -47,3 +47,20 @@
47 color: #999; 47 color: #999;
48 text-align: right; 48 text-align: right;
49 } 49 }
  50 +
  51 +.list_content {
  52 + display: inline-block !important;
  53 +}
  54 +
  55 +.wxParse-p {
  56 + text-indent: 0 !important;
  57 + word-spacing: normal;
  58 + word-wrap: normal;
  59 + display: block !important;
  60 +}
  61 +
  62 +.wxParse-img {
  63 + width: 100% !important;
  64 + height: 100%;
  65 + margin-top: 16rpx!important;
  66 +}