liukang преди 11 месеца
родител
ревизия
b383804ca5
променени са 66 файла, в които са добавени 5005 реда и са изтрити 1857 реда
  1. 1 1
      App.vue
  2. 95 49
      components/comment/index.vue
  3. 1 1
      components/j-calendar/j-calendar.vue
  4. 398 30
      components/list-info/index.vue
  5. 21 7
      components/qiandao/index.vue
  6. 31 14
      components/richtext-editor/richtext-editor.vue
  7. 14 10
      components/swiper-list/index.vue
  8. 176 16
      components/yx-vip/index.vue
  9. 9 7
      manifest.json
  10. 66 21
      pageA/add-luntan.vue
  11. 254 42
      pageA/add-wenzhang.vue
  12. 48 37
      pageA/chat-list.vue
  13. 100 40
      pageA/chat.vue
  14. 35 45
      pageA/dianzan-list.vue
  15. 23 10
      pageA/huati.vue
  16. 252 32
      pageA/info-detail.vue
  17. 78 23
      pageA/message.vue
  18. 103 38
      pageA/pinglun-list.vue
  19. 53 23
      pageA/publish.vue
  20. 12 7
      pageA/search.vue
  21. 35 45
      pageA/shoucang-list.vue
  22. 41 13
      pageB/components/addressbox.vue
  23. 6 2
      pageB/components/time-box.vue
  24. 47 17
      pageB/components/youhui.vue
  25. 53 20
      pageB/good-detail.vue
  26. 94 25
      pageB/order-confirm.vue
  27. 75 53
      pageB/order-detail.vue
  28. 42 19
      pageB/order-list.vue
  29. 50 26
      pageB/totaobao.vue
  30. 20 7
      pageB/yuyue-capture.vue
  31. 55 12
      pageB/yuyue-list.vue
  32. 70 45
      pageB/yuyue-vip.vue
  33. 97 48
      pageB/zulin-add.vue
  34. 63 18
      pageB/zulin-list.vue
  35. 27 6
      pageC/about.vue
  36. 39 6
      pageC/account.vue
  37. 245 29
      pageC/calendar.vue
  38. 95 37
      pageC/collect-list.vue
  39. 92 30
      pageC/drafts.vue
  40. 49 11
      pageC/edit-pwd.vue
  41. 56 9
      pageC/error.vue
  42. 40 13
      pageC/guanzhu-list.vue
  43. 22 3
      pageC/invite-bind.vue
  44. 60 19
      pageC/invite-list.vue
  45. 87 20
      pageC/invite.vue
  46. 74 17
      pageC/jianli.vue
  47. 18 10
      pageC/jifen-list.vue
  48. 75 16
      pageC/jifen-qianbao.vue
  49. 26 19
      pageC/paihang.vue
  50. 11 13
      pageC/setting.vue
  51. 78 48
      pageC/tuisong.vue
  52. 76 31
      pageC/userinfo.vue
  53. 6 12
      pageC/video-detail.vue
  54. 6 5
      pageC/video-list.vue
  55. 267 16
      pageC/vip.vue
  56. 9 7
      pageC/xieyi.vue
  57. 40 14
      pageC/youhuiquan.vue
  58. 2 2
      pageC/zhiwei-detail.vue
  59. 26 15
      pageC/zhiwei-list.vue
  60. 69 24
      pageC/zuji-list.vue
  61. 431 437
      pages.json
  62. 157 80
      pages/index/index.vue
  63. 72 23
      pages/luntan/index.vue
  64. 181 69
      pages/mine/index.vue
  65. 49 12
      pages/shangdian/index.vue
  66. 2 1
      static/js/api.js

+ 1 - 1
App.vue

@@ -190,7 +190,7 @@
 	}
 	.text_hide3 {
 		text-overflow: -o-ellipsis-lastline;
-		overflow: hidden;				//溢出内容隐藏
+		overflow: hidden !important;				//溢出内容隐藏
 		text-overflow: ellipsis;		//文本溢出部分用省略号表示
 		display: -webkit-box;			//特别显示模式
 		-webkit-line-clamp: 3;			//行数

+ 95 - 49
components/comment/index.vue

@@ -1,7 +1,7 @@
 <template>
 	<view class="pinglun">
 		<view class="pinglun-title">
-			全部评论 
+			全部评论
 		</view>
 		<view class="pinglun-item hflex jbetween" v-for="(item,index) in pinglunlist" :key="index">
 			<image class="user-img" :src="item.user.avatar" mode="aspectFill"></image>
@@ -19,11 +19,11 @@
 						<text>{{item.date}}</text>
 						<text @click="reply(item)">回复</text>
 					</view>
-					<view class="hflex acenter pinglun-dianzan">
+					<view class="hflex acenter pinglun-dianzan" @click="like(index,'-1')">
 						<image v-if="item.is_like == 0" src="@/static/images/dianzan.png" mode="aspectFill"></image>
-						<image v-else src="@/static/images/dianzan.png" mode="aspectFill"></image>
+						<image v-else src="@/static/images/dianzan2.png" mode="aspectFill"></image>
 						<text>{{item.like_count || '0'}}</text>
-						<image src="@/static/images/cai.png" mode="aspectFill"></image>
+						<!-- <image src="@/static/images/cai.png" mode="aspectFill"></image> -->
 					</view>
 				</view>
 				<view v-if="item.children.length > 0">
@@ -45,11 +45,12 @@
 									<text>{{a.date}}</text>
 									<text @click="reply(a)">回复</text>
 								</view>
-								<view class="hflex acenter pinglun-dianzan">
-									<image v-if="a.is_like == 0" src="@/static/images/dianzan.png" mode="aspectFill"></image>
+								<view class="hflex acenter pinglun-dianzan" @click="like(index,b)">
+									<image v-if="a.is_like == 0" src="@/static/images/dianzan.png" mode="aspectFill">
+									</image>
 									<image v-else src="@/static/images/dianzan.png" mode=""></image>
 									<text>{{a.like_count || '0'}}</text>
-									<image src="@/static/images/cai.png" mode="aspectFill"></image>
+									<!-- <image src="@/static/images/cai.png" mode="aspectFill"></image> -->
 								</view>
 							</view>
 						</view>
@@ -81,20 +82,18 @@
 				typeof: String,
 				default: ''
 			},
-			user: {
-				typeof: Object,
-				default: {}
-			}
+			
 		},
-		
-		
+
+
 		watch: {
-			show_jianpan(newval,oldval) {
+			show_jianpan(newval, oldval) {
 				this.show = newval
 			},
 		},
 		data() {
 			return {
+				user: {},
 				comment: '',
 				pinglunlist: [],
 				show: false,
@@ -103,17 +102,46 @@
 			}
 		},
 		mounted() {
+			this.getuser()
 			setTimeout(() => {
 				this.getlist()
-			},300)
+			}, 300)
 		},
 		methods: {
+			getuser() {
+				var that = this
+				$api.req({
+					url: 'user/info',
+				}, function(res) {
+					that.user = res.data
+				})
+			},
+			like(index,type) {
+				var that = this
+				$api.req({
+					url: 'like',
+					method: 'post',
+					data: {
+						source_type: 'comment',
+						source_id: type == '-1' ? this.pinglunlist[index].id : this.pinglunlist[index].children[type].id
+					}
+				}, function(res) {
+					$api.info(res.msg)
+					if(type == '-1') {
+						that.pinglunlist[index].is_like = 1
+						that.pinglunlist[index].like_count += 1
+					} else {
+						that.pinglunlist[index].children[type].is_like = 1
+						that.pinglunlist[index].children[type].like_count += 1
+					}
+				})
+			},
 			reply(item) {
 				this.show = true
 				this.parent_id = item.id
 			},
 			send() {
-				if(this.comment == '') {
+				if (this.comment == '') {
 					uni.$u.toast('请先输入内容')
 					return
 				}
@@ -123,13 +151,14 @@
 					method: 'post',
 					data: {
 						source_type: _this.type,
-						source_id:  _this.id,
+						source_id: _this.id,
 						content: _this.comment,
 						parent_id: _this.parent_id
 					}
-				},function(res) {
-					if(res.code == 10000) {
+				}, function(res) {
+					if (res.code == 10000) {
 						uni.$u.toast('评论成功')
+						_this.comment = ''
 						_this.getlist()
 					}
 				})
@@ -146,7 +175,7 @@
 						order_type: 'desc'
 					}
 				}, function(res) {
-					if(res.code == 10000) {
+					if (res.code == 10000) {
 						_this.pinglunlist = res.data
 					}
 				})
@@ -159,6 +188,7 @@
 	.pinglun::v-deep {
 		padding: 0 32rpx;
 		box-sizing: border-box;
+
 		.huifu {
 			position: fixed;
 			bottom: 0;
@@ -170,12 +200,14 @@
 			padding: 20rpx 28rpx;
 			box-sizing: border-box;
 			width: 100%;
+
 			image {
 				width: 56rpx !important;
 				height: 56rpx;
 				border-radius: 50%;
 				margin: 0 20rpx 0 0;
 			}
+
 			text {
 				font-size: 32rpx;
 				font-family: PingFangSC, PingFang SC;
@@ -183,15 +215,17 @@
 				color: #999999;
 			}
 		}
+
 		.pinglun-item {
 			box-sizing: border-box;
 			width: 100%;
-	
+
 			.pinglun-right {
 				width: calc(100% - 88rpx);
+
 				.pinglun-time {
 					margin-bottom: 28rpx;
-	
+
 					text:first-child {
 						font-size: 24rpx;
 						font-family: PingFangSC-Regular, PingFang SC;
@@ -199,7 +233,7 @@
 						color: #777777;
 						margin-right: 24rpx;
 					}
-	
+
 					text:nth-child(2) {
 						font-size: 24rpx;
 						font-family: PingFangSC-Regular, PingFang SC;
@@ -207,7 +241,7 @@
 						color: #222222;
 					}
 				}
-	
+
 				.pinglun-text {
 					padding: 0 36rpx 0 0;
 					font-size: 28rpx;
@@ -216,14 +250,16 @@
 					color: #333333;
 					margin-bottom: 20rpx;
 				}
+
 				.pinglun-dianzan {
 					margin-bottom: 28rpx;
+
 					image {
 						width: 32rpx;
 						height: 32rpx;
 						// margin-right: 4rpx;
 					}
-					
+
 					text {
 						font-size: 24rpx;
 						font-family: ArialMT;
@@ -231,46 +267,51 @@
 						color: #777777;
 					}
 				}
+
 				.pinglun-user {
 					margin-bottom: 24rpx;
-	
-					
-	
-	
-	
+
+
+
+
+
 					.pinglun-user-center {
 						height: 68rpx;
+
 						.u-icon {
 							padding: 0 16rpx;
 						}
+
 						text {
 							font-size: 28rpx;
 							font-weight: 500;
 							color: #222222;
 						}
-	
-						
+
+
 					}
 				}
 			}
-	
+
 			.user-img {
 				width: 68rpx;
 				height: 68rpx;
 				border-radius: 50%;
 				margin-right: 20rpx;
 			}
-	
+
 		}
+
 		.pinglun-item2 {
 			box-sizing: border-box;
 			width: 100%;
-			
+
 			.pinglun-right {
 				width: calc(100% - 88rpx);
+
 				.pinglun-time {
 					margin-bottom: 28rpx;
-			
+
 					text:first-child {
 						font-size: 24rpx;
 						font-family: PingFangSC-Regular, PingFang SC;
@@ -278,7 +319,7 @@
 						color: #777777;
 						margin-right: 24rpx;
 					}
-			
+
 					text:nth-child(2) {
 						font-size: 24rpx;
 						font-family: PingFangSC-Regular, PingFang SC;
@@ -286,7 +327,7 @@
 						color: #222222;
 					}
 				}
-			
+
 				.pinglun-text {
 					padding: 0 36rpx 0 0;
 					font-size: 28rpx;
@@ -295,14 +336,16 @@
 					color: #333333;
 					margin-bottom: 20rpx;
 				}
+
 				.pinglun-dianzan {
 					margin-bottom: 28rpx;
+
 					image {
 						width: 32rpx;
 						height: 32rpx;
 						// margin-right: 4rpx;
 					}
-					
+
 					text {
 						font-size: 24rpx;
 						font-family: ArialMT;
@@ -310,38 +353,41 @@
 						color: #777777;
 					}
 				}
+
 				.pinglun-user {
 					margin-bottom: 24rpx;
-			
-					
-			
-			
-			
+
+
+
+
+
 					.pinglun-user-center {
 						height: 68rpx;
+
 						.u-icon {
 							padding: 0 16rpx;
 						}
+
 						text {
 							font-size: 28rpx;
 							font-weight: 500;
 							color: #222222;
 						}
-			
-						
+
+
 					}
 				}
 			}
-			
+
 			.user-img2 {
 				width: 68rpx;
 				height: 68rpx;
 				border-radius: 50%;
 				margin-right: 20rpx;
 			}
-			
+
 		}
-	
+
 		.pinglun-title {
 			font-size: 32rpx;
 			font-family: PingFangSC-Medium, PingFang SC;

+ 1 - 1
components/j-calendar/j-calendar.vue

@@ -8,7 +8,7 @@
 				<!-- <button class="barbtn">{{langType=='ch'?'上一月':'Last'}}</button> -->
 			</view>
 			<!-- 显示年月 -->
-			<view class="date">{{nowYear || "--"}} 年 {{nowMonth || "--"}} 月</view>
+			<view class="date" style="font-weight: bold;">{{nowYear || "--"}} 年 {{nowMonth || "--"}} 月</view>
 			<!-- 下一个月 -->
 			<view class="next" @click="changeMonth(1)">
 				<u-icon name="play-right-fill"></u-icon>

+ 398 - 30
components/list-info/index.vue

@@ -2,13 +2,16 @@
 	<view class="list-info" @click="toinfo">
 		<view class="info-header hflex acenter jbetween">
 			<view class="hflex acenter">
-				<image :src="data.user.avatar" mode="aspectFill" class="headera-avatar"></image>
+				<image :src="data.user.avatar" v-if="data.user.avatar" mode="aspectFill" class="headera-avatar" @click.stop="touser"></image>
 				<view class="avatar-right">
 					<view class="name hflex acenter">
 						<text>{{data.user.username}}</text>
-						<image src="@/static/images/zuozhe1.png" v-if="data.type == 1" mode="aspectFill" class="type-icon"></image>
-						<image src="@/static/images/zuozhe2.png" v-if="data.type == 2" mode="aspectFill" class="type-icon"></image>
-						<image src="@/static/images/zuozhe3.png" v-if="data.type == 3" mode="aspectFill" class="type-icon"></image>
+						<!-- <image src="@/static/images/zuozhe1.png" v-if="data.type == 1" mode="aspectFill"
+							class="type-icon"></image>
+						<image src="@/static/images/zuozhe2.png" v-if="data.type == 2" mode="aspectFill"
+							class="type-icon"></image>
+						<image src="@/static/images/zuozhe3.png" v-if="data.type == 3" mode="aspectFill"
+							class="type-icon"></image> -->
 					</view>
 					<view class="time">{{data.published_at}}</view>
 				</view>
@@ -17,43 +20,108 @@
 				<u-icon name="more-dot-fill" color="#777777" size="20"></u-icon>
 			</view>
 		</view>
-		<view class="info-content" v-if="type == 'post'">
-			<u-swiper :indicator="true" indicatorMode="dot" :list="data.images" height="452rpx" radius="12rpx" v-if="data.images.length > 0">
+		<view class="info-content" v-if="type == 'post' || data.source_type == 'post'">
+			<u-swiper :indicator="true" indicatorMode="dot" :list="data.images" height="452rpx" radius="12rpx"
+				v-if="data.images.length > 0">
 			</u-swiper>
-			<text v-if="data.content">{{data.content}}</text>
+			<u-swiper :indicator="true" indicatorMode="dot" :list="data.source.images" height="452rpx" radius="12rpx"
+				v-else-if="data.source.images.length > 0">
+			</u-swiper>
+			<view class="text_hide3" v-if="data.content" style="margin: 20rpx 0 0;">{{data.content}}</view>
+			<view class="text_hide3" v-else-if="data.source.content" style="margin: 20rpx 0 0;">{{data.source.content}}</view>
 		</view>
-		<view class="info-content" v-if="type != 'post'">
+		<view class="info-content" v-else>
+			
 			<image :src="data.image" mode="aspectFill" class="content-img" v-if="data.image"></image>
-			<!-- <video :src="data.image" controls enable-danmu danmu-btn class="content-img" v-if="data.video"></video> -->
+			<image :src="data.source.image" mode="aspectFill" class="content-img" v-if="data.source.image"></image>
 			<view class="content-title" v-if="data.title">{{data.title}}</view>
-			<u-parse :content="data.content" class="text_hide3"></u-parse>
+			<view class="content-title" v-else-if="data.source.title">{{data.source.title}}</view>
+			<view class="text_hide3" v-if="data.content">
+				<u-parse :content="data.content" class="text_hide3" ></u-parse>
+			</view>
+			<u-parse :content="data.source.content" class="text_hide3" v-else-if="data.source.content"></u-parse>
+			<!-- <rich-text class="text_hide3" :nodes="data.content" v-if="data.content"></rich-text>
+			<rich-text class="text_hide3" :nodes="data.source.content" v-if="data.source.content"></rich-text> -->
 		</view>
 		<view class="info-circle hflex acenter" v-if="data.topic_id != 0 && data.topic">
 			<!-- <image :src="data.circle.img" mode="aspectFill"></image> -->
 			<text>{{data.topic.title}}</text>
 		</view>
-		<view class="info-bottom hflex acenter jbetween" v-if="type != 'post'">
+		<view class="info-bottom hflex acenter jbetween" v-if="type != 'post' || data.source_type != 'post'">
 			<view class="hflex acenter">
-				<text>{{data.collect_count || 0}}喜欢 · </text>
+				<text>{{data.like_count || 0}}喜欢 · </text>
 				<text>{{data.comment_count || 0}}评论</text>
 			</view>
 		</view>
-		<view class="info-bottom hflex acenter jbetween" v-if="type =='post'">
+		<view class="info-bottom hflex acenter jbetween" v-if="type =='post' || data.source_type == 'post'">
 			<view class="hflex acenter">
-				<image src="@/static/images/dianzan.png" mode="aspectFill" v-if="!data.is_like" @click.stop="tolike(data)"></image>
+				<image src="@/static/images/dianzan.png" mode="aspectFill" v-if="!data.is_like"
+					@click.stop="tolike(data)"></image>
 				<image src="@/static/images/dianzan2.png" mode="aspectFill" v-else @click.stop="tolike(data)"></image>
 				<text class="num" @click.stop="tolike(data)">{{data.like_count}}</text>
 				<image src="@/static/images/pinglun.png" mode="aspectFill"></image>
 				<text class="num">{{data.comment_count}}</text>
-				<image src="@/static/images/shoucang.png" mode="aspectFill" v-if="!data.is_collect" @click.stop="tocollect(data)"></image>
-				<image src="@/static/images/shoucang2.png" mode="aspectFill" v-else @click.stop="tocollect(data)"></image>
+				<image src="@/static/images/shoucang.png" mode="aspectFill" v-if="!data.is_collect"
+					@click.stop="tocollect(data)"></image>
+				<image src="@/static/images/shoucang2.png" mode="aspectFill" v-else @click.stop="tocollect(data)">
+				</image>
 				<text class="num" @click.stop="tocollect(data)">{{data.collect_count}}</text>
 			</view>
-			<image src="@/static/images/fenxiang.png" mode="aspectFill"></image>
+			<image src="@/static/images/fenxiang.png" mode="aspectFill" @click.stop="openShare(data)"></image>
 		</view>
 		<u-popup :show="show_more" @close="toclose">
-			<view class="popu">
-				
+			<view class="popu hflex acenter">
+				<view class="vflex acenter jcenter top-item" @click="show_jubao = true" v-if="data.user.id != userid">
+					<view class="img-bg vflex acenter jcenter" style="background: #E9E9E9;">
+						<image src="@/static/images/warn.png" mode="aspectFill"></image>
+					</view>
+					<text>举报</text>
+				</view>
+				<view class="vflex acenter jcenter top-item" @click="delItem" v-if="data.user.id == userid">
+					<view class="img-bg vflex acenter jcenter" style="background: #E9E9E9;">
+						<image src="@/static/images/warn.png" mode="aspectFill"></image>
+					</view>
+					<text>删除</text>
+				</view>
+			</view>
+		</u-popup>
+		<u-popup :show="show_share" @close="toclose">
+			<view class="popu_share">
+				<view class="list hflex acenter jaround">
+					<view class="item vflex acenter jcenter" @click="shareWX">
+						<image src="@/static/images/wx.png" mode="aspectFill"></image>
+						<text>微信</text>
+					</view>
+					<view class="item vflex acenter jcenter" @click="sharePYQ">
+						<image src="@/static/images/pyq.png" mode="aspectFill"></image>
+						<text>朋友圈</text>
+					</view>
+					<view class="item vflex acenter jcenter" @click="copy">
+						<view class="img-bg vflex acenter jcenter">
+							<image src="@/static/images/lianjie.png" mode="aspectFill"></image>
+						</view>
+						<text>复制链接</text>
+					</view>
+				</view>
+			</view>
+		</u-popup>
+		<u-popup :show="show_jubao" @close="toclose" mode="bottom" :round="10">
+			<view class="popu1">
+				<view class="title hflex acenter jbetween">
+					<text>内容描述</text>
+					<u-icon name="close" color="#000000" size="14" @click="toclose"></u-icon>
+				</view>
+				<u--textarea v-model="jubao" placeholder="请对您举报的内容进行文字描述"></u--textarea>
+				<view class="title">
+					<text>辅助图片</text>
+				</view>
+				<u-upload :fileList="fileList1" @afterRead="afterRead" @delete="deletePic" name="1" :maxCount="9"
+					width="160rpx" height="160rpx">
+					<view class="upload-bg hflex acenter jcenter">
+						<u-icon name="plus" color="#CCCCCC" size="20"></u-icon>
+					</view>
+				</u-upload>
+				<view class="btn" :class="jubao != '' ? 'btn2' : ''" @click="tojubao">确定</view>
 			</view>
 		</u-popup>
 	</view>
@@ -75,22 +143,178 @@
 		data() {
 			return {
 				show_more: false,
+				show_jubao: false,
+				show_share: false,
+				share: {},
+				jubao: '',
+				fileList1: [],
+				userid: '',
+				login: false
 			}
 		},
+		mounted() {
+			this.userid = uni.getStorageSync('userid')
+			this.login = uni.getStorageSync('token') ? true : false
+		},
 		methods: {
+			delItem() {
+				var that = this
+				that.show_more = false
+				uni.showModal({
+					title: '删除',
+					content: '是否确定要删除?',
+					success: function (res) {
+						if (res.confirm) {
+							let url = ''
+							if(that.type) {
+								url = that.type + '/' + that.data.id
+							} else {
+								url = that.data.source_type + '/' + that.data.id
+							}
+							$api.req({
+								url: url,
+								method: 'DELETE'
+							}, function(res) {
+								$api.info(res.msg)
+								that.$emit('del',1)
+							})
+						}
+					},
+				})
+				
+			},
+			touser() {
+				uni.navigateTo({
+					url: '/pageC/otherInfo?id=' + this.data.user.id
+				})
+			},
+			tojubao() {
+				var that = this
+				let image = []
+				if(that.fileList1.length>0) {
+					for(var i=0;i<that.fileList1.length;i++) {
+						image.push(that.fileList1[i].url)
+					}
+				}
+				
+				$api.req({
+					url: 'report',
+					method: 'post',
+					data: {
+						source_type: that.type ? that.type : that.data.source_type,
+						source_id: that.data.id,
+						content: that.jubao,
+						images: image
+					}
+				}, function(res) {
+					$api.info('举报成功')
+					that.toclose()
+				})
+			},
+			// 删除图片
+			deletePic(event) {
+				this[`fileList${event.name}`].splice(event.index, 1)
+			},
+			// 新增图片
+			async afterRead(event) {
+				// 当设置 multiple 为 true 时, file 为数组格式,否则为对象格式
+				let lists = [].concat(event.file)
+				let fileListLen = this[`fileList${event.name}`].length
+				lists.map((item) => {
+					this[`fileList${event.name}`].push({
+						...item,
+						status: 'uploading',
+						message: '上传中'
+					})
+				})
+				for (let i = 0; i < lists.length; i++) {
+					const result = await this.uploadFilePromise(lists[i].url)
+					let item = this[`fileList${event.name}`][fileListLen]
+					this[`fileList${event.name}`].splice(fileListLen, 1, Object.assign(item, {
+						status: 'success',
+						message: '',
+						url: result
+					}))
+					fileListLen++
+				}
+			},
+			uploadFilePromise(url) {
+				return new Promise((resolve, reject) => {
+					let a = uni.uploadFile({
+						url: $api.config.baseUrl + 'upload/image', // 仅为示例,非真实的接口地址
+						filePath: url,
+						name: 'image',
+						formData: {
+							user: 'test'
+						},
+						success: (res) => {
+							let data = JSON.parse(res.data)
+							setTimeout(() => {
+								resolve(data.data.url)
+							}, 1000)
+						}
+					});
+				})
+			},
+			shareWX() {
+				uni.share({
+					provider: "weixin",
+					scene: "WXSceneSession",
+					type: 1,
+					href: "",
+					title: "亿象",
+					summary: this.share.content,
+					success: function(res) {
+						console.log("success:" + JSON.stringify(res));
+					},
+					fail: function(err) {
+						console.log("fail:" + JSON.stringify(err));
+					}
+				});
+			},
+			sharePYQ() {
+				uni.share({
+					provider: "weixin",
+					scene: "WXSceneTimeline",
+					type: 1,
+					summary: this.share.content,
+					success: function(res) {
+						console.log("success:" + JSON.stringify(res));
+					},
+					fail: function(err) {
+						console.log("fail:" + JSON.stringify(err));
+					}
+				});
+			},
+			copy() {
+				uni.setClipboardData({
+					data: '/pageA/info-detail?id=' + this.share.id + '&type=post',
+					success() {
+						uni.$u.toast('复制成功')
+					}
+				})
+			},
+			openShare(item) {
+				this.show_share = true
+				this.share = item
+			},
 			tocollect(item) {
 				var _this = this
+				if(!this.login) {
+					$api.info('请先登录')
+					return
+				}
 				$api.req({
 					url: 'collect',
 					method: 'POST',
 					data: {
-						source_type: _this.type,
+						source_type: _this.type ? _this.type : _this.data.source_type,
 						source_id: item.id
 					}
 				}, function(res) {
-					if(res.code == 10000) {
+					if (res.code == 10000) {
 						uni.$u.toast(res.msg)
-						if(_this.data.is_collect == 0) {
+						if (_this.data.is_collect == 0) {
 							_this.data.is_collect = item.id
 							_this.data.collect_count += 1
 						} else {
@@ -102,17 +326,21 @@
 			},
 			tolike(item) {
 				var _this = this
+				if(!this.login) {
+					$api.info('请先登录')
+					return
+				}
 				$api.req({
 					url: 'like',
 					method: 'POST',
 					data: {
-						source_type: _this.type,
+						source_type: _this.type ? _this.type : _this.data.source_type,
 						source_id: item.id
 					}
 				}, function(res) {
-					if(res.code == 10000) {
+					if (res.code == 10000) {
 						uni.$u.toast(res.msg)
-						if(_this.data.is_like == 0) {
+						if (_this.data.is_like == 0) {
 							_this.data.is_like = item.id
 							_this.data.like_count += 1
 						} else {
@@ -123,11 +351,14 @@
 				})
 			},
 			toclose() {
-				show_more = false
+				this.show_more = false
+				this.show_jubao = false
+				this.show_share = false
 			},
 			toinfo() {
+				let type = this.type ? this.type : this.data.source_type
 				uni.navigateTo({
-					url: '/pageA/info-detail?id=' + this.data.id + '&type=' + this.type
+					url: '/pageA/info-detail?id=' + this.data.id + '&type=' + type
 				})
 				// this.$emit('toinfo',this.data)
 			}
@@ -139,26 +370,152 @@
 	.list-info {
 		padding: 28rpx;
 		background: #FFFFFF;
-		margin:  0 0 20rpx;
+		margin: 0 0 20rpx;
+
+		.popu {
+			background: #FFFFFF;
+			border-radius: 20rpx 20rpx 0rpx 0rpx;
+			padding: 82rpx 30rpx;
+
+			.top-item {
+				padding: 0 0 0 108rpx;
+
+				.img-bg {
+					width: 96rpx;
+					height: 96rpx;
+					background: #00B0B0;
+					border-radius: 50%;
+
+					image {
+						width: 36rpx;
+						height: 36rpx;
+					}
+				}
+
+				text {
+					padding: 16rpx 0 0;
+					font-size: 22rpx;
+					font-family: PingFangSC, PingFang SC;
+					font-weight: 400;
+					color: #444444;
+				}
+
+			}
+
+		}
+
+		.popu1 {
+			background: #FFFFFF;
+			border-radius: 20rpx 20rpx 0rpx 0rpx;
+			box-sizing: border-box;
+			padding: 0 28rpx;
+
+			.title {
+				padding: 36rpx 0 28rpx;
+				width: 100%;
+
+				text {
+					font-size: 32rpx;
+					font-weight: 500;
+					color: #333333;
+				}
+			}
+
+			.u-textarea {
+				width: 694rpx;
+				height: 236rpx;
+				background: #F5F5F5;
+				border-radius: 12rpx;
+				padding: 28rpx 20rpx !important;
+				box-sizing: border-box;
+				border: none;
+			}
+
+			.upload-bg {
+				width: 160rpx;
+				height: 160rpx;
+				background: #F5F5F5;
+				border-radius: 12rpx;
+			}
+
+			.btn2 {
+				opacity: 1 !important;
+			}
+
+			.btn {
+				margin: 156rpx 0 54rpx;
+				width: 694rpx;
+				height: 88rpx;
+				background: #00B0B0;
+				border-radius: 44rpx;
+				opacity: 0.2;
+				font-size: 32rpx;
+				font-family: PingFangSC, PingFang SC;
+				font-weight: 500;
+				color: #FFFFFF;
+				line-height: 88rpx;
+				text-align: center;
+			}
+		}
+
+		.popu_share {
+			padding: 54rpx 0;
+
+			.list {
+				padding: 0 0 46rpx;
+				border-bottom: 1px solid #979797;
+
+				.item {
+					image {
+						width: 84rpx;
+						height: 84rpx;
+					}
+
+					.img-bg {
+						width: 84rpx;
+						height: 84rpx;
+						background: #00B0B0;
+						border-radius: 50%;
+
+						image {
+							width: 36rpx;
+							height: 36rpx;
+						}
+					}
+
+					text {
+						padding: 22rpx 0 0;
+						font-size: 22rpx;
+						color: #333333;
+						line-height: 32rpx;
+					}
+				}
+			}
+		}
+
 		.info-header {
 			.headera-avatar {
 				width: 72rpx;
 				height: 72rpx;
 				border-radius: 50%;
 			}
+
 			.avatar-right {
 				margin: 0 0 0 16rpx;
+
 				.name {
 					font-size: 28rpx;
 					font-family: PingFangSC, PingFang SC;
 					font-weight: 500;
 					color: #333333;
 				}
+
 				.type-icon {
 					width: 124rpx;
 					height: 32rpx;
 					margin: 0 0 0 12rpx;
 				}
+
 				.time {
 					font-size: 20rpx;
 					font-family: PingFangSC, PingFang SC;
@@ -168,13 +525,16 @@
 				}
 			}
 		}
+
 		.info-content {
 			box-sizing: border-box;
 			padding: 20rpx 0;
+
 			.content-img {
 				width: 100%;
-				margin:  0 0 16rpx;
+				margin: 0 0 16rpx;
 			}
+
 			.content-title {
 				font-size: 32rpx;
 				font-family: PingFangSC, PingFang SC;
@@ -182,6 +542,7 @@
 				color: #222222;
 				padding: 0 0 8rpx;
 			}
+
 			text {
 				font-size: 30rpx;
 				font-family: PingFangSC, PingFang SC;
@@ -191,16 +552,19 @@
 				box-sizing: border-box;
 			}
 		}
+
 		.info-circle {
 			padding: 24rpx 0 0;
 			background: rgba(0, 176, 176, .1);
 			border-radius: 26rpx;
 			padding: 8rpx 20rpx;
 			max-width: max-content;
+
 			image {
 				width: 34rpx;
 				height: 34rpx;
 			}
+
 			text {
 				padding: 0 0 0 5rpx;
 				font-size: 24rpx;
@@ -208,20 +572,24 @@
 				color: #00B0B0;
 			}
 		}
+
 		.info-bottom {
 			padding: 40rpx 0 0;
+
 			image {
 				width: 36rpx;
 				height: 36rpx;
 			}
+
 			text {
 				font-size: 20rpx;
 				font-family: SFPro, SFPro;
 				font-weight: 400;
 				color: #555555;
 			}
+
 			.num {
-				
+
 				padding: 0 50rpx 0 12rpx;
 			}
 		}

+ 21 - 7
components/qiandao/index.vue

@@ -2,7 +2,7 @@
 	<view class="qiandao vflex acenter jcenter">
 		<image src="/static/images/qiandao.png" mode="aspectFill"></image>
 		<text>签到成功</text>
-		<text>获得积分+ {{}}</text>
+		<text>获得积分+ {{jifen}}</text>
 		<view class="btn" @click="close">确定</view>
 	</view>
 </template>
@@ -12,22 +12,33 @@
 	export default {
 		data() {
 			return {
-				
+				jifen: 0
 			}
 		},
 		onLoad() {
-			
+
 		},
 		onShow() {
-			
+
+		},
+		mounted() {
+			this.getdata()
 		},
 		onPullDownRefresh() {
-			
+
 		},
 		onReachBottom() {
-			
+
 		},
 		methods: {
+			getdata() {
+				var that = this
+				$api.req({
+					url: 'config?module=sign'
+				}, function(res) {
+					that.jifen = res.data.integral_num
+				})
+			},
 			close() {
 				this.$emit('close')
 			}
@@ -38,11 +49,13 @@
 <style lang="scss">
 	.qiandao {
 		width: 550rpx;
+
 		image {
 			width: 270rpx;
 			height: 260rpx;
 			padding: 40rpx;
 		}
+
 		text {
 			font-size: 28rpx;
 			font-family: SFPro, SFPro;
@@ -50,6 +63,7 @@
 			color: #222222;
 			padding: 14rpx 0 0;
 		}
+
 		.btn {
 			margin: 48rpx 0 60rpx;
 			width: 250rpx;
@@ -65,4 +79,4 @@
 			text-align: center;
 		}
 	}
-</style>
+</style>

+ 31 - 14
components/richtext-editor/richtext-editor.vue

@@ -3,7 +3,7 @@
 		<!-- 编辑器内容@focus="modeShow" -->
 		<view class="main">
 			<!-- //如果不需要跟随键盘弹出注释:style="{ 'height': editorHeight + 'px' }"  mode默认改为true即可 -->
-			<editor @focus="modeShow" :style="{ 'height': editorHeight + 'px' }" @statuschange="selected"
+			<editor @focus="modeShow" :style="{ 'height': editorHeight + 'px' }" @statuschange="selected" :mode="false"
 				class="myEditor" placeholder="写点什么儿~" show-img-size show-img-toolbar show-img-resize
 				@ready="onEditorReady" @blur="onsuccess"></editor>
 		</view>
@@ -13,18 +13,22 @@
 			<!-- 功能选项  :style="{position: 'relative',bottom:keyboardHeight+'px'}"-->
 			<view class="tabName hflex acenter jbetween" @click="ontabtap">
 				<view class="hflex acenter">
-					<image @click="changeImg" v-show="!img" src="@/static/richtext/img.png" :data-current="3" mode="aspectFill"></image>
-					<image @click="changeImg" v-show="img" src="@/static/richtext/imgselect.png" :data-current="3" mode="aspectFill">
+					<image @click="changeImg" v-show="!img" src="@/static/richtext/img.png" :data-current="3"
+						mode="aspectFill"></image>
+					<image @click="changeImg" v-show="img" src="@/static/richtext/imgselect.png" :data-current="3"
+						mode="aspectFill">
 					</image>
-					<image @click="changeFont" v-show="!font" src="@/static/richtext/font.png" :data-current="1" mode="aspectFill"></image>
-					<image @click="changeFont" v-show="font" src="@/static/richtext/fontselect.png" :data-current="1" mode="aspectFill">
+					<image @click="changeFont" v-show="!font" src="@/static/richtext/font.png" :data-current="1"
+						mode="aspectFill"></image>
+					<image @click="changeFont" v-show="font" src="@/static/richtext/fontselect.png" :data-current="1"
+						mode="aspectFill">
 					</image>
 				</view>
 				<!-- <image @click="changeAlign" v-show="!align" src="@/static/richtext/leftcenter.png" :data-current="2" mode="">
 				</image>
 				<image @click="changeAlign" v-show="align" src="@/static/richtext/leftcenterSelect.png" :data-current="2"
 					mode=""></image> -->
-				
+
 				<view class="hflex acenter">
 					<image @click="repeal" src="@/static/richtext/backone.png" mode=""></image>
 					<image @click="recover" src="@/static/richtext/afterone.png" mode=""></image>
@@ -212,13 +216,19 @@
 		<!-- 利用rich-text来回显html内容 data是富文本编辑器html的内容-->
 		<!-- <rich-text class="ql-editor" :nodes="data"></rich-text> -->
 		<!-- uparse解析 -->
-		<!--  <u-parse :content="data" @preview="preview" @navigate="navigate" ></u-parse> -->
+		<!-- <u-parse :content="data" @preview="preview" @navigate="navigate"></u-parse> -->
 	</view>
 </template>
 
 <script>
 	import $api from '@/static/js/api.js'
 	export default {
+		props: {
+			init: {
+				typeof: String,
+				default: ''
+			}
+		},
 		data() {
 			return {
 				mode: false, //显示模块 //如果不需要跟随键盘弹出 改为true默认显示
@@ -273,6 +283,7 @@
 		},
 		mounted() {
 			var _this = this
+
 			uni.getSystemInfo({
 				success: function(res) {
 					_this.Height = res.windowHeight;
@@ -314,6 +325,7 @@
 				this.tabIndex = index;
 			},
 			onEditorReady(e) { //初始化
+				this.data = this.init
 				uni.createSelectorQuery().in(this).select('.myEditor').fields({
 					context: true
 				}, res => {
@@ -635,7 +647,7 @@
 							// 	'user': 'test'
 							// },
 							success: (uploadFileRes) => {
-								
+
 								let res = JSON.parse(uploadFileRes.data)
 								for (let i = 0; i < tempFilePaths.length; i++) {
 									_this.editorCtx.insertImage({
@@ -699,7 +711,7 @@
 						//这里把编辑器里的视频封面截图替换成了视频
 						//uniapp富文本编辑器内不支持video无法显示视频,rich-text可以显示但需要uparse插件解析
 						//https://ext.dcloud.net.cn/plugin?id=183 这里有详细教程
-						
+
 						// let reg = /<img[^>]*class=['videothumb"]([^'"]+)[^>]*>/g
 						// that.data = data.html.replace(reg,
 						// 	'<video id="myVideo" class="videosrc" src="https://mp-2a0f3e44-b47a-4bd5-a925-ba63d3e2a8ab.cdn.bspapp.com/add_file/2023-09-17 172002.mp4"></video>'
@@ -722,9 +734,10 @@
 		height: 60upx;
 		line-height: 60upx;
 		padding: 15upx 28rpx;
-		
+
 		border-top: 1upx solid #d9e4f9;
 		border-bottom: 1upx solid #d9e4f9;
+
 		image {
 			width: 40rpx;
 			height: 40rpx;
@@ -1119,16 +1132,20 @@
 	/*  */
 	.main {
 		width: 100%;
-		min-height: 820upx;
-		max-height: max-content;
+		min-height: 500rpx;
+		max-height: 500rpx;
+		overflow: auto;
 		/* height: max-content; */
 	}
+
 	.modes {
 		height: 500rpx;
 	}
+
 	.myEditor {
-		min-height: 820upx;
-		max-height: max-content;
+		min-height: 500rpx;
+		max-height: 500rpx;
+		overflow: auto;
 		/* height: max-content; */
 		padding: 0 20upx;
 		font-size: 36upx;

+ 14 - 10
components/swiper-list/index.vue

@@ -1,6 +1,7 @@
 <template>
 	<view class="swiper">
-		<u-swiper :list="swiper_list" keyName="image" height="300rpx" radius="12rpx" @change="e => swiper_current = e.current" @click="swiperclick">
+		<u-swiper :list="swiper_list" keyName="image" height="300rpx" radius="12rpx"
+			@change="e => swiper_current = e.current" @click="swiperclick">
 			<view slot="indicator" class="indicator">
 				<view class="indicator__dot" v-for="(item, index) in swiper_list" :key="index"
 					:class="[index === swiper_current && 'indicator__dot--active']">
@@ -29,16 +30,16 @@
 			this.getlist()
 		},
 		onLoad() {
-			
+
 		},
 		onShow() {
-			
+
 		},
 		onPullDownRefresh() {
-			
+
 		},
 		onReachBottom() {
-			
+
 		},
 		methods: {
 			getlist() {
@@ -51,16 +52,19 @@
 						limit: 5
 					}
 				}, function(res) {
-					if(res.code == 10000) {
+					if (res.code == 10000) {
 						_this.swiper_list = res.data
 					}
 				})
 			},
 			swiperclick(e) {
 				var data = this.swiper_list[e]
-				if(data.is_jump == 1) {
-					if(data.jump_type == 'external') {
-						window.location.href = data.jump_url
+				if (data.is_jump == 1) {
+					if (data.jump_type == 'external') {
+						// window.location.href = data.jump_url
+						uni.navigateTo({
+							url: '/pages/webview/index?url=' + data.jump_url
+						})
 					} else {
 						uni.navigateTo({
 							url: data.jump_url
@@ -74,4 +78,4 @@
 
 <style lang="scss">
 
-</style>
+</style>

+ 176 - 16
components/yx-vip/index.vue

@@ -10,17 +10,18 @@
 			</view>
 			<view class="btn hflex acenter" v-if="showsign" @click="tosign">
 				<image src="/static/images/rili.png" mode="aspectFill"></image>
-				<text>{{user.is_qiandao ? '已签到' : '签到'}}</text>
+				<text>{{is_qiandao == 1 ? '已签到' : '签到'}}</text>
 			</view>
 		</view>
 		<view class="level hflex acenter jbetween" v-if="showlevel">
 			<text>LV{{user.level || 1}}</text>
-			<u-line-progress :percentage="user.already_upgrade_rate * 100" inactiveColor="#CCCCCC" height="2" activeColor="#FFFFFF"></u-line-progress>
+			<u-line-progress :percentage="user.already_upgrade_rate * 100" inactiveColor="#CCCCCC" height="2"
+				activeColor="#FFFFFF"></u-line-progress>
 			<text>LV{{Number(user.level) + 1 || 2}}</text>
 		</view>
 		<view class="bottom hflex acenter jbetween">
 			<text>{{user.is_vip ? user.vip_expired_at : '开通会员享福利'}}</text>
-			<text @click="show_buy = false">{{user.is_vip ? '立即续费' : '立即开通'}}</text>
+			<text @click="show_buy = true">{{user.is_vip ? '立即续费' : '立即开通'}}</text>
 		</view>
 		<u-popup :show="show" mode="center" @close="toclose">
 			<view class="qiandao vflex acenter jcenter">
@@ -34,11 +35,12 @@
 			<view class="vip-buy">
 				<view class="buy-title">会员充值</view>
 				<view class="buy-list hflex acenter jbetween">
-					<view class="buy-item vflex acenter jcenter" :class="buy_active == index ? 'buy-active' : ''" v-for="(item,index) in buylist" :key="index">
-						<text>{{item.name}}</text>
-						<text><span>¥</span>{{item.price}}</text>
+					<view class="buy-item vflex acenter jcenter" :class="buy_active == index ? 'buy-active' : ''"
+						v-for="(item,index) in buylist" :key="index">
+						<text class="name">{{item.name}}</text>
+						<text class="price"><span>¥</span>{{item.price}}</text>
 						<view class="text">额外获得{{item.integral}}积分</view>
-						<view class="text">额外免费拍摄{{item.sell_count}}次</view>
+						<view class="text">额外免费拍摄{{item.coupon_count}}次</view>
 						<view class="text">升级领福利</view>
 						<view class="text">积分商城折扣</view>
 					</view>
@@ -49,8 +51,9 @@
 						<image src="../../static/images/ali-pay.png" mode="aspectFill" class="pay-icon"></image>
 						<text>支付宝支付</text>
 					</view>
-					<view class="">
-						<image src="../../static/images/check-active.png" mode="aspectFill" class="pay-select" v-if="pay_active == 1"></image>
+					<view class="" @click="pay_active = 1">
+						<image src="../../static/images/check-active.png" mode="aspectFill" class="pay-select"
+							v-if="pay_active == 1"></image>
 						<image src="../../static/images/check.png" mode="aspectFill" class="pay-select" v-else></image>
 					</view>
 				</view>
@@ -59,11 +62,15 @@
 						<image src="../../static/images/wx-pay.png" mode="aspectFill" class="pay-icon"></image>
 						<text>微信支付</text>
 					</view>
-					<view class="">
-						<image src="../../static/images/check-active.png" mode="aspectFill" class="pay-select" v-if="pay_active == 2"></image>
+					<view class="" @click="pay_active = 2">
+						<image src="../../static/images/check-active.png" mode="aspectFill" class="pay-select"
+							v-if="pay_active == 2"></image>
 						<image src="../../static/images/check.png" mode="aspectFill" class="pay-select" v-else></image>
 					</view>
 				</view>
+				<view class="bottom-buy" @click="topay">
+					确认支付
+				</view>
 			</view>
 		</u-popup>
 	</view>
@@ -90,15 +97,68 @@
 			return {
 				show: false,
 				show_buy: false,
-				jifen: 2,
+				jifen: 0,
 				buylist: [],
-				pay_active: 0
+				pay_active: 0,
+				buy_active: 0,
+				is_qiandao: 0
 			}
 		},
 		mounted() {
-			
+			this.getlist()
+			this.getdata()
+			this.getsign()
 		},
 		methods: {
+			getsign() {
+				var that = this
+				$api.req({
+					url: 'sign/is-sign'
+				}, function(res) {
+					that.is_qiandao = res.data
+				})
+			},
+			getdata() {
+				var that = this
+				$api.req({
+					url: 'config?module=sign'
+				}, function(res) {
+					that.jifen = res.data.integral_num
+				})
+			},
+			topay() {
+				var that = this
+				let pay_type = ''
+				if (that.pay_active == '1') {
+					pay_type = 'alipay'
+				} else if (that.pay_active == '2') {
+					pay_type = 'wechat'
+				} else {
+					pay_type = 'integral'
+				}
+				$api.req({
+					url: 'vip/order',
+					method: 'post',
+					data: {
+						vip_id: that.buylist[that.buy_active].id,
+						pay_type: pay_type,
+						platform: 'app'
+					}
+				}, function(res) {
+					if (res.code == 10000) {
+						$api.info('支付成功')
+						that.show_buy = false
+					}
+				})
+			},
+			getlist() {
+				var that = this
+				$api.req({
+					url: 'vip/product',
+				}, function(res) {
+					that.buylist = res.data
+				})
+			},
 			toclose() {
 				this.show = false
 				this.show_buy = false
@@ -109,9 +169,10 @@
 					url: 'sign',
 					method: 'POST'
 				}, function(res) {
-					if(res.code == 10000) {
+					if (res.code == 10000) {
 						_this.show = true
-					} else if(res.code == 20001) {
+						_this.is_qiandao = 1
+					} else if (res.code == 20001) {
 						uni.$u.toast('请先登录')
 					}
 				})
@@ -126,13 +187,16 @@
 		border-radius: 16rpx;
 		box-sizing: border-box;
 		padding: 28rpx 20rpx;
+
 		.qiandao {
 			width: 550rpx;
+
 			image {
 				width: 270rpx;
 				height: 260rpx;
 				padding: 40rpx;
 			}
+
 			text {
 				font-size: 28rpx;
 				font-family: SFPro, SFPro;
@@ -140,6 +204,7 @@
 				color: #222222;
 				padding: 14rpx 0 0;
 			}
+
 			.btn {
 				margin: 48rpx 0 60rpx;
 				width: 250rpx;
@@ -155,6 +220,7 @@
 				text-align: center;
 			}
 		}
+
 		.bottom {
 			text {
 				font-size: 24rpx;
@@ -162,34 +228,42 @@
 				font-weight: 400;
 				color: #FFFFFF;
 			}
+
 			text:last-child {
 				color: #FF7B15;
 			}
 		}
+
 		.level {
 			padding: 44rpx 0;
+
 			text {
 				font-size: 32rpx;
 				font-family: Silom;
 				color: #FFFFFF;
 			}
+
 			text:first-child {
 				padding-right: 16rpx;
 			}
+
 			text:last-child {
 				padding-left: 16rpx;
 			}
 		}
+
 		.vip_top {
 			.btn {
 				background: #00B0B0;
 				border-radius: 40rpx;
 				padding: 8rpx 18rpx;
+
 				image {
 					width: 36rpx;
 					height: 36rpx;
 					margin: 8rpx;
 				}
+
 				text {
 					font-size: 24rpx;
 					font-family: PingFangSC, PingFang SC;
@@ -197,6 +271,7 @@
 					color: #FFFFFF;
 				}
 			}
+
 			.vip_uesr {
 				image {
 					width: 80rpx;
@@ -204,6 +279,7 @@
 					border-radius: 50%;
 					margin: 0 12rpx 0 0;
 				}
+
 				.name {
 					text:first-child {
 						font-size: 28rpx;
@@ -211,6 +287,7 @@
 						font-weight: 400;
 						color: #FFFFFF;
 					}
+
 					text:last-child {
 						font-size: 24rpx;
 						font-family: PingFangSC, PingFang SC;
@@ -221,5 +298,88 @@
 				}
 			}
 		}
+
+		.vip-buy {
+			padding: 34rpx 24rpx;
+
+			.buy-title {
+				font-size: 32rpx;
+				color: #222222;
+				line-height: 44rpx;
+
+			}
+
+			.pay-item {
+				padding: 42rpx 0 0;
+
+				image {
+					width: 44rpx;
+					height: 44rpx;
+				}
+
+				text {
+					font-size: 30rpx;
+					color: #333333;
+					line-height: 42rpx;
+					padding-left: 28rpx;
+				}
+			}
+
+			.bottom-buy {
+				margin: 180rpx 0 88rpx;
+				width: 694rpx;
+				height: 88rpx;
+				background: #00B0B0;
+				border-radius: 48rpx;
+				font-size: 32rpx;
+				color: #FFFFFF;
+				line-height: 88rpx;
+				text-align: center;
+
+			}
+
+			.buy-list {
+				padding: 34rpx 12rpx;
+
+				.buy-item {
+					width: 320rpx;
+					height: 392rpx;
+					background: #F8F8F8;
+					border-radius: 16rpx;
+					border: 2rpx solid #D3D3D3;
+
+					.name {
+						font-size: 28rpx;
+						color: #222222;
+						line-height: 40rpx;
+						text-align: center;
+					}
+
+					.price {
+						padding: 30rpx 0 24rpx;
+						font-size: 60rpx;
+						color: #222222;
+						line-height: 30rpx;
+						text-align: center;
+					}
+
+					span {
+						font-size: 24rpx;
+					}
+
+					.text {
+						font-size: 20rpx;
+						color: #222222;
+						line-height: 24rpx;
+						padding: 0 0 20rpx;
+					}
+				}
+
+				.buy-active {
+					border: 2rpx solid #DD6838;
+					background: #FFF9F4;
+				}
+			}
+		}
 	}
 </style>

+ 9 - 7
manifest.json

@@ -1,6 +1,6 @@
 {
     "name" : "忆象",
-    "appid" : "__UNI__97674D1",
+    "appid" : "__UNI__0800F61",
     "description" : "",
     "versionName" : "1.0.0",
     "versionCode" : "100",
@@ -17,7 +17,9 @@
             "delay" : 0
         },
         /* 模块配置 */
-        "modules" : {},
+        "modules" : {
+            "VideoPlayer" : {}
+        },
         /* 应用发布信息 */
         "distribute" : {
             /* android打包配置 */
@@ -53,10 +55,10 @@
         },
         "nativePlugins" : {
             "JG-JCore" : {
-                "JPUSH_APPKEY_IOS" : "07ca3eaf2d56b37620c4ab86",
-                "JPUSH_CHANNEL_IOS" : "",
-                "JPUSH_APPKEY_ANDROID" : "07ca3eaf2d56b37620c4ab86",
-                "JPUSH_CHANNEL_ANDROID" : "",
+                "JPUSH_APPKEY_IOS" : "06c8f294f766914b092c8069",
+                "JPUSH_CHANNEL_IOS" : "developer-default",
+                "JPUSH_APPKEY_ANDROID" : "06c8f294f766914b092c8069",
+                "JPUSH_CHANNEL_ANDROID" : "developer-default",
                 "__plugin_info__" : {
                     "name" : "JG-JCore",
                     "description" : "极光推送JCore插件",
@@ -94,7 +96,7 @@
             "JG-JPush" : {
                 "JPUSH_ISPRODUCTION_IOS" : "",
                 "JPUSH_ADVERTISINGID_IOS" : "",
-                "JPUSH_DEFAULTINITJPUSH_IOS" : "",
+                "JPUSH_DEFAULTINITJPUSH_IOS" : "true",
                 "JPUSH_OPPO_APPKEY" : "",
                 "JPUSH_OPPO_APPID" : "",
                 "JPUSH_OPPO_APPSECRET" : "",

+ 66 - 21
pageA/add-luntan.vue

@@ -1,12 +1,16 @@
 <template>
 	<view class="content">
-		<u-navbar title="" leftText="取消" @leftClick="leftclick" placeholder leftIconSize="0">
+		<u-navbar title="" placeholder :autoBack="false"  leftIconSize="0">
+			<view class="u-nav-left" slot="left">
+				<text @click="leftclick">取消</text>
+			</view>
 			<view class="u-nav-right" slot="right">
-				<text @click="publish('normal')">下一步</text>
+				<text @click="publish('normal')">发布</text>
 			</view>
 		</u-navbar>
 		<view class="form">
-			<u-upload :fileList="fileList1" @afterRead="afterRead" @delete="deletePic" name="1" multiple :maxCount="9" maxSize="5242880" width="192rpx" height="192rpx">
+			<u-upload :fileList="fileList1" @afterRead="afterRead" @delete="deletePic" name="1" multiple :maxCount="9"
+				maxSize="5242880" width="192rpx" height="192rpx">
 				<image src="static/upload.png" mode="aspectFill" class="upload-icon"></image>
 			</u-upload>
 			<view class="text">
@@ -41,21 +45,37 @@
 				fileList1: [],
 				content: '',
 				topic: {},
+				is_edit: 0,
+				id: 0,
+				data: {}
 			}
 		},
 		onLoad(option) {
-			if(option.topic) {
+			if (option.topic) {
 				this.topic = JSON.parse(option.topic)
 			}
+			if(option.data) {
+				this.is_edit = option.edit
+				this.data = JSON.parse(decodeURIComponent(option.data))
+				this.content = this.data.content
+				for(var i=0;i<this.data.images.length;i++) {
+					let temp = {
+						url : this.data.images[i]
+					}
+					this.fileList1.push(temp)
+				}
+				// this.topic ={
+				// 	id: this.data.topic_id
+				// }
+			}
 		},
 		onShow() {
-			
 		},
 		onPullDownRefresh() {
-			
+
 		},
 		onReachBottom() {
-			
+
 		},
 		methods: {
 			toback() {
@@ -75,11 +95,9 @@
 					}
 				})
 			},
-			// 删除图片
 			deletePic(event) {
 				this[`fileList${event.name}`].splice(event.index, 1)
 			},
-			// 新增图片
 			async afterRead(event) {
 				uni.showLoading({
 					title: '上传中',
@@ -104,7 +122,7 @@
 						url: result
 					}))
 					fileListLen++
-					if(lists.length - 1 == i) {
+					if (lists.length - 1 == i) {
 						uni.hideLoading()
 					}
 				}
@@ -132,27 +150,41 @@
 			},
 			publish(type) {
 				var _this = this
+				let url = 'post'
+				let method="post"
 				var images = []
-				if(this.fileList1.length > 0) {
-					for(var i=0;i<this.fileList1.length;i++) {
+				if (this.fileList1.length > 0) {
+					for (var i = 0; i < this.fileList1.length; i++) {
 						images.push(this.fileList1[i].url)
 					}
-				} 
+				}
+				if(this.is_edit == 1) {
+					this.url = 'post/' +this.data.id
+					this.method = 'put'
+				}
 				$api.req({
-					url: 'post',
-					method: 'POST',
+					url: url,
+					method: method,
 					data: {
 						content: _this.content,
 						topic_id: _this.topic.id,
 						status: type,
-						images: images
-						
+						images: images,
+						id: this.is_edit == 1 ? this.data.id : '0'
 					}
 				}, function(res) {
-					if(res.code == 10000) {
-						uni.$u.toast('发布成功')
+					if (res.code == 10000) {
+						uni.$u.toast(res.msg)
 						setTimeout(() => {
-							uni.navigateBack()
+							if(type == 'normal') {
+								uni.switchTab({
+									url: '/pages/index/index'
+								})
+							} else {
+								uni.navigateTo({
+									url: '/pageC/drafts'
+								})
+							}
 						}, 800)
 					}
 				})
@@ -164,18 +196,22 @@
 <style lang="scss">
 	.content::v-deep {
 		background: #FFFFFF;
+
 		.text {
 			padding: 32rpx 0 0;
+
 			.u-textarea {
 				border: none;
 				padding: 0;
 			}
 		}
+
 		.popu {
 			background: #FFFFFF;
 			border-radius: 16rpx;
 			padding: 48rpx;
 			box-sizing: border-box;
+
 			text:first-child {
 				font-size: 32rpx;
 				font-family: PingFangSC, PingFang SC;
@@ -183,6 +219,7 @@
 				color: #333333;
 				padding: 0;
 			}
+
 			text {
 				font-size: 24rpx;
 				font-family: PingFangSC, PingFang SC;
@@ -190,6 +227,7 @@
 				color: #333333;
 				padding: 18rpx 0;
 			}
+
 			.btn1 {
 				width: 414rpx;
 				height: 72rpx;
@@ -203,6 +241,7 @@
 				text-align: center;
 				margin: 28rpx;
 			}
+
 			.btn2 {
 				width: 414rpx;
 				height: 72rpx;
@@ -217,6 +256,7 @@
 				margin: 28rpx;
 			}
 		}
+
 		.fixed {
 			position: fixed;
 			left: 28rpx;
@@ -224,11 +264,13 @@
 			background: rgba(0, 176, 176, .1);
 			border-radius: 40rpx;
 			padding: 8rpx 16rpx;
+
 			image {
 				width: 36rpx;
 				height: 36rpx;
 				margin: 0 16rpx 0 0;
 			}
+
 			text {
 				font-size: 24rpx;
 				font-family: PingFangSC, PingFang SC;
@@ -236,9 +278,11 @@
 				color: #00B0B0;
 			}
 		}
+
 		.form {
 			padding: 58rpx 28rpx 28rpx;
 			border-bottom: 1px solid #EDEDED;
+
 			.upload-icon {
 				width: 64rpx;
 				height: 64rpx;
@@ -247,6 +291,7 @@
 				padding: 64rpx;
 			}
 		}
+
 		.u-nav-right {
 			text {
 				font-size: 32rpx;
@@ -256,4 +301,4 @@
 			}
 		}
 	}
-</style>
+</style>

+ 254 - 42
pageA/add-wenzhang.vue

@@ -2,26 +2,52 @@
 	<view class="content">
 		<u-navbar title="" leftText="取消" @leftClick="leftclick" placeholder leftIconSize="0">
 			<view class="u-nav-right" slot="right">
-				<text :style="data.title&&data.content ? 'color: #00B0B0' : ''" @click="next">下一步</text>
+				<text :style="data.title&&data.content ? 'color: #00B0B0' : ''" @click="next">{{type == 'post'?'发布':'下一步'}}</text>
 			</view>
 		</u-navbar>
-		<view class="video" v-if="type == 'video'">
-			<u-input v-model="data.video_title" placeholder="请添加关联视频标题(最多输入100个字)" border="none" fontSize="36rpx"></u-input>
-			<u--textarea v-model="data.video_url" placeholder="请添加关联视频链接" border="none" autoHeight fontSize="28rpx"></u--textarea>
-		</view>
-		<view class="title">
-			<u-input v-model="data.title" placeholder="输入标题(最多输入100个字)" border="none" fontSize="44rpx"></u-input>
-		</view>
-		<view class="center">
-			<richtext-editor @onsuccess="onsuccess"></richtext-editor>
-		</view>
-		<view class="fixed hflex acenter" v-if="JSON.stringify(data.topic) == '{}'" @click="selecttopic">
-			<image src="static/add.png" mode="aspectFill"></image>
-			<text>添加话题</text>
-		</view>
-		<view class="fixed" v-else>
-			<text>{{data.topic.title}}</text>
-		</view>
+		<block v-if="index == 1">
+			<view class="video" v-if="type == 'video'">
+				<u-input v-model="data.video_title" placeholder="请添加关联视频标题(最多输入100个字)" border="none"
+					fontSize="40rpx"></u-input>
+				<u--textarea v-model="data.video_url" placeholder="请添加关联视频链接" border="none" autoHeight
+					fontSize="28rpx"></u--textarea>
+			</view>
+			<view class="title">
+				<u-input v-model="data.title" placeholder="输入标题(最多输入100个字)" border="none" fontSize="44rpx"></u-input>
+			</view>
+			<view class="center">
+				<richtext-editor :init="data.content" @onsuccess="onsuccess"></richtext-editor>
+			</view>
+			<view class="fixed hflex acenter" v-if="JSON.stringify(data.topic) == '{}'" @click="selecttopic">
+				<image src="static/add.png" mode="aspectFill"></image>
+				<text>添加话题</text>
+			</view>
+			<view class="fixed" v-else>
+				<text>{{data.topic.title}}</text>
+			</view>
+		</block>
+		<block v-if="index == 2">
+			<view class="top">
+				<text>{{data.title}}</text>
+				<view class="text">
+					<u-parse :content="data.content"></u-parse>
+				</view>
+			</view>
+			<view class="hflex imgs">
+				<text>封面</text>
+				<view class="img vflex acenter jcenter" v-if="image == ''" @click="chooseimg">
+					<image src="/pageA/static/upload.png" mode="aspectFill" class="icon"></image>
+				</view>
+				<view class="img" v-else>
+					<image :src="image" mode="aspectFill"></image>
+					<text @click="chooseimg">替换</text>
+				</view>
+			</view>
+			<view class="bottom hflex acenter jcenter">
+				<view class="btn1" @click="topublish('draft')">存草稿</view>
+				<view class="btn2" @click="topublish('normal')">发布</view>
+			</view>
+		</block>
 	</view>
 </template>
 
@@ -41,16 +67,101 @@
 					content: '',
 					topic: {}
 				},
-				
+				index: 1,
 				type: '',
+				image: '',
+				is_edit: 0
 			}
 		},
 		onLoad(option) {
-			if(option.type) {
+			if (option.type) {
 				this.type = option.type
 			}
+			if(option.edit) {
+				this.is_edit = option.edit
+			}
+			if (option.data) {
+				console.log(JSON.parse(decodeURIComponent(option.data)));
+				this.data = JSON.parse(decodeURIComponent(option.data))
+				let data = {
+					id: this.data.topic_id
+				}
+				this.image = this.data.image
+				this.data.topic = data
+				console.log(this.data);
+			}
 		},
 		methods: {
+			topublish(status) {
+				var url = ''
+				let method= 'post'
+				
+				var form = {}
+				form = {
+					title: this.data.title,
+					content: this.data.content,
+					topic_id: this.data.topic.id,
+					status: status,
+					image: this.image
+				}
+				if (this.type == 'info') {
+					url = 'info'
+				} else if (this.type == 'article') {
+					url = 'article'
+				} else if (this.type == 'video') {
+					url = 'video'
+					form.video_title = this.data.video_title
+					form.video_url = this.data.video_url
+				}
+				if(this.is_edit == 1) {
+					method = 'put'
+					// form.id = this.data.id
+					url = url + '/' + this.data.id
+				}
+				console.log(form, '上传数据', url);
+				$api.req({
+					url: url,
+					method: method,
+					data: form
+				}, function(res) {
+					console.log(res);
+					$api.info(res.msg)
+					if (res.code == 10000) {
+						setTimeout(() => {
+							if(status == 'normal') {
+								uni.switchTab({
+									url: '/pages/index/index'
+								})
+							} else {
+								uni.navigateTo({
+									url: '/pageC/drafts'
+								})
+							}
+						},1000)
+					}
+				})
+			},
+			chooseimg() {
+				uni.chooseImage({
+					success: (chooseImageRes) => {
+						uni.showLoading({
+							title: '上传中...'
+						})
+						const tempFilePaths = chooseImageRes.tempFilePaths;
+						uni.uploadFile({
+							url: $api.config.baseUrl + 'upload/image', //仅为示例,非真实的接口地址
+							filePath: tempFilePaths[0],
+							name: 'image',
+							success: (uploadFileRes) => {
+			
+								let res = JSON.parse(uploadFileRes.data)
+								this.image = res.data.url
+								uni.hideLoading()
+							}
+						});
+					}
+				});
+			},
 			leftclick() {
 				uni.navigateBack()
 			},
@@ -58,27 +169,8 @@
 				this.data.content = e
 			},
 			next() {
-				if(this.type == 'video') {
-					if(this.data.video_title == '') {
-						uni.$u.toast('请先输入视频标题')
-						return
-					}
-					if(this.data.video_url == '') {
-						uni.$u.toast('请先输入视频链接')
-						return
-					}
-				}
-				if(this.data.title == '') {
-					uni.$u.toast('请先输入标题')
-					return
-				}
-				/* if(this.data.content == '') {
-					uni.$u.toast('请先输入正文')
-					return
-				} */
-				uni.navigateTo({
-					url: '/pageA/publish?data=' + JSON.stringify(this.data) + '&type=' + this.type
-				})
+				this.index = 2
+				console.log(this.index);
 			},
 			selecttopic() {
 				var _this = this
@@ -98,22 +190,136 @@
 <style lang="scss">
 	.content::v-deep {
 		background: #FFFFFF;
+.top {
+			width: 100%;
+			box-sizing: border-box;
+			padding: 28rpx;
+			border-bottom: 1px solid #F2F2F2;
+
+			text:first-child {
+				font-size: 40rpx;
+				font-family: SFPro, SFPro;
+				font-weight: 400;
+				color: #222222;
+			}
+
+			.text {
+				width: 100%;
+				height: 96rpx;
+				overflow: hidden;
+				padding: 10rpx 0 0;
+			}
+		}
+
+		.imgs {
+			padding: 34rpx 28rpx;
+
+			text {
+				font-size: 32rpx;
+				font-family: PingFangSC, PingFang SC;
+				font-weight: 400;
+				color: #222222;
+				padding-right: 42rpx;
+			}
+
+			.img {
+				width: 574rpx;
+				height: 334rpx;
+				background: #F5F5F5;
+				border-radius: 12rpx;
+				overflow: hidden;
+				position: relative;
+
+				.icon {
+					width: 86rpx;
+					height: 86rpx;
+				}
+
+				image {
+					width: 100%;
+					height: 100%;
+				}
+
+				text {
+					position: absolute;
+					bottom: 24rpx;
+					left: 232rpx;
+					width: 110rpx;
+					height: 60rpx;
+					background: rgba(0, 0, 0, 0.8);
+					border-radius: 30rpx;
+					font-size: 26rpx;
+					font-family: PingFangSC, PingFang SC;
+					font-weight: 400;
+					color: #FFFFFF;
+					line-height: 60rpx;
+					text-align: center;
+					padding: 0;
+				}
+			}
+		}
+
+		.bottom {
+			width: 750rpx;
+			height: 166rpx;
+			background: #FFFFFF;
+			box-shadow: 0rpx 0rpx 0rpx 0rpx rgba(0, 0, 0, 0.1);
+			position: fixed;
+			bottom: 0;
+			left: 0;
+			box-sizing: border-box;
+			padding: 16rpx 28rpx 62rpx;
+			border-top: 1px solid rgba(0, 0, 0, 0.1);
+
+			.btn1 {
+				width: 340rpx;
+				height: 88rpx;
+				border-radius: 44rpx;
+				border: 2rpx solid #E2E2E2;
+				font-size: 32rpx;
+				font-family: PingFangSC, PingFang SC;
+				font-weight: 400;
+				color: #222222;
+				line-height: 88rpx;
+				text-align: center;
+				margin-right: 14rpx;
+			}
+
+			.btn2 {
+				width: 340rpx;
+				height: 88rpx;
+				background: #00B0B0;
+				border-radius: 44rpx;
+				font-size: 32rpx;
+				font-family: PingFangSC, PingFang SC;
+				font-weight: 400;
+				color: #FFFFFF;
+				line-height: 88rpx;
+				text-align: center;
+			}
+		}
+	
 		.video {
 			padding: 36rpx 28rpx;
 			border-bottom: 1px solid #F2F2F2;
 		}
+
 		.fixed {
 			position: fixed;
 			left: 28rpx;
-			bottom: 632rpx;
+			bottom: 132rpx;
 			background: rgba(0, 176, 176, .1);
 			border-radius: 40rpx;
 			padding: 8rpx 16rpx;
+			max-width: max-content;
+			margin: 20rpx 28rpx;
+
 			image {
 				width: 36rpx;
 				height: 36rpx;
 				margin: 0 16rpx 0 0;
 			}
+
 			text {
 				font-size: 24rpx;
 				font-family: PingFangSC, PingFang SC;
@@ -121,16 +327,22 @@
 				color: #00B0B0;
 			}
 		}
+
 		.title {
 			padding: 36rpx 28rpx;
+
 			.u-input {
 				font-size: 44rpx;
 				line-height: 60rpx;
 			}
 		}
+
 		.center {
+			max-height: 1000rpx;
+			overflow: auto;
 			// padding: 0 28rpx;
 		}
+
 		.u-nav-right {
 			text {
 				font-size: 32rpx;

+ 48 - 37
pageA/chat-list.vue

@@ -4,10 +4,14 @@
 			<view class="list-item" v-for="(item,index) in list" :key="index">
 				<view class="time">{{item.time}}</view>
 				<view class=" hflex acenter jbetween">
-					<image :src="other_user.avatar" style="margin-right: 12rpx;" mode="aspectFill" v-if="item.id == other_user.id"></image>
+					<image :src="other_user.avatar" style="margin-right: 12rpx;" mode="aspectFill"
+						v-if="item.id == other_user.id"></image>
 					<view v-else style="width: 68rpx;"></view>
-					<view class="text" :style="item.id == user.id ? 'background: #00B0B0;color: #FFFFFF' : ''">{{item.content}}</view>
-					<image :src="user.avatar" style="margin-left: 12rpx;" mode="aspectFill" v-if="item.id == user.id"></image>
+					<view class="text" :style="item.id == user.id ? 'background: #00B0B0;color: #FFFFFF' : ''">
+						{{item.content}}
+					</view>
+					<image :src="user.avatar" style="margin-left: 12rpx;" mode="aspectFill" v-if="item.id == user.id">
+					</image>
 					<view v-else style="width: 68rpx;"></view>
 				</view>
 			</view>
@@ -20,50 +24,44 @@
 	export default {
 		data() {
 			return {
-				user: {
-					id: 2,
-					avatar: 'https://dummyimage.com/279x155/e3e3e3/fff',
-					
-				},
-				other_user: {
-					id: 1,
-					name: '爱思考的大黄猫',
-					avatar: 'https://dummyimage.com/279x155/e3e3e3/fff'
-				},
-				list: [
-					{
-						id: 1,
-						time: '15:59',
-						content:'下个月初,也就是TGA呗。估计还是主机独占那么是买PS5还是XSX'
-					},
-					{
-						id: 2,
-						time: '15:59',
-						content:'国内的网络条件使用ps5会比xsx方便一些,特别是下载和更新'
-					},
-				],
+				user: {},
+				other_user: {},
+				chat_user_id: '',
+				userid: '',
+				list: [],
 				text: '',
 				show_menu: false,
+				page: 1,
+				last_page: 1
 			}
 		},
-		onLoad() {
-			
+		onLoad(option) {
+			this.chat_user_id = option.id
+			this.userid = uni.getStorageSync('userid')
+			this.getlist()
 		},
 		onShow() {
-			
+
 		},
 		onPullDownRefresh() {
-			
+
 		},
 		onReachBottom() {
-			
+
 		},
 		methods: {
-			tolist() {
-				uni.navigateTo({
-					url: '/pageA/chat-list'
+			getlist() {
+				var that = this
+				$api.req({
+					url: 'chat/detail',
+					data: {
+						is_page: 0,
+						chat_user_id: that.chat_user_id
+					}
+				}, function(res) {
+					that.list = res.data
 				})
-			},
+			}
 		}
 	}
 </script>
@@ -72,8 +70,10 @@
 	.content::v-deep {
 		background: #FFFFFF;
 		padding: 20rpx 28rpx;
+
 		.u-nav-right {
 			position: relative;
+
 			.menu {
 				position: absolute;
 				right: 0;
@@ -81,16 +81,19 @@
 				width: 188rpx;
 				height: 144rpx;
 				background: #FFFFFF;
-				box-shadow: 0rpx 4rpx 20rpx -4rpx rgba(0,0,0,0.2);
+				box-shadow: 0rpx 4rpx 20rpx -4rpx rgba(0, 0, 0, 0.2);
 				border-radius: 8rpx;
 				box-sizing: border-box;
 				padding: 26rpx 24rpx 0;
+
 				.menu-item {
 					padding: 0 0 32rpx;
+
 					image {
 						width: 36rpx;
 						height: 36rpx;
 					}
+
 					.menu-text {
 						padding-left: 12rpx;
 						font-size: 24rpx;
@@ -101,6 +104,7 @@
 				}
 			}
 		}
+
 		.bottom {
 			border-top: 1px solid #E5E5E5;
 			width: 100%;
@@ -110,6 +114,7 @@
 			background: #FFFFFF;
 			padding: 14rpx 28rpx 76rpx;
 			box-sizing: border-box;
+
 			.u-input {
 				width: 528rpx !important;
 				height: 76rpx;
@@ -118,9 +123,11 @@
 				border-radius: 40rpx;
 				padding: 18rpx 40rpx !important;
 			}
+
 			.btn2 {
 				opacity: 1 !important;
 			}
+
 			.btn {
 				margin-left: 20rpx;
 				width: 146rpx;
@@ -134,12 +141,14 @@
 				color: #FFFFFF;
 				text-align: center;
 				line-height: 76rpx;
-				
+
 			}
 		}
+
 		.list {
 			.list-item {
 				margin: 0 0 44rpx;
+
 				.time {
 					width: 100%;
 					text-align: center;
@@ -149,11 +158,13 @@
 					color: #999999;
 					padding-bottom: 24rpx;
 				}
+
 				image {
 					width: 68rpx;
 					height: 68rpx;
 					border-radius: 50%;
 				}
+
 				.text {
 					width: 512rpx;
 					background: #F5F5F5;
@@ -167,4 +178,4 @@
 			}
 		}
 	}
-</style>
+</style>

+ 100 - 40
pageA/chat.vue

@@ -19,17 +19,21 @@
 			<view class="list-item" v-for="(item,index) in list" :key="index">
 				<view class="time">{{item.time}}</view>
 				<view class=" hflex acenter jbetween">
-					<image :src="other_user.avatar" style="margin-right: 12rpx;" mode="aspectFill" v-if="item.id == other_user.id"></image>
+					<image :src="other_user.avatar" style="margin-right: 12rpx;" mode="aspectFill"
+						v-if="item.id == other_user.id"></image>
 					<view v-else style="width: 68rpx;"></view>
-					<view class="text" :style="item.id == user.id ? 'background: #00B0B0;color: #FFFFFF' : ''">{{item.content}}</view>
-					<image :src="user.avatar" style="margin-left: 12rpx;" mode="aspectFill" v-if="item.id == user.id"></image>
+					<view class="text" :style="item.id == user.id ? 'background: #00B0B0;color: #FFFFFF' : ''">
+						{{item.content}}
+					</view>
+					<image :src="user.avatar" style="margin-left: 12rpx;" mode="aspectFill" v-if="item.id == user.id">
+					</image>
 					<view v-else style="width: 68rpx;"></view>
 				</view>
 			</view>
 		</view>
 		<view class="bottom hflex acenter jbetween">
 			<u-input v-model="text" placeholder="输入消息" border="none"></u-input>
-			<view class="btn" :class="text != '' ? 'btn2' : ''">发送</view>
+			<view class="btn" :class="text != '' ? 'btn2' : ''" @click="send">发送</view>
 		</view>
 		<u-popup :show="show_jubao" @close="toclose" mode="bottom" :round="10">
 			<view class="popu">
@@ -37,16 +41,17 @@
 					<text>内容描述</text>
 					<u-icon name="close" color="#000000" size="14" @click="toclose"></u-icon>
 				</view>
-				<u--textarea v-model="jubao" placeholder="请对您举报的内容进行文字描述" ></u--textarea>
+				<u--textarea v-model="jubao" placeholder="请对您举报的内容进行文字描述"></u--textarea>
 				<view class="title">
 					<text>辅助图片</text>
 				</view>
-				<u-upload :fileList="fileList" @afterRead="afterRead" @delete="deletePic" name="1" :maxCount="9" width="160rpx" height="160rpx">
+				<u-upload :fileList="fileList1" @afterRead="afterRead" @delete="deletePic" name="1" :maxCount="9"
+					width="160rpx" height="160rpx">
 					<view class="upload-bg hflex acenter jcenter">
 						<u-icon name="plus" color="#CCCCCC" size="20"></u-icon>
 					</view>
 				</u-upload>
-				<view class="btn" :class="jubao != '' ? 'btn2' : ''">确定</view>
+				<view class="btn" :class="jubao != '' ? 'btn2' : ''" @click="submit">确定</view>
 			</view>
 		</u-popup>
 	</view>
@@ -57,49 +62,83 @@
 	export default {
 		data() {
 			return {
-				user: {
-					id: 2,
-					avatar: 'https://dummyimage.com/279x155/e3e3e3/fff',
-					
-				},
-				other_user: {
-					id: 1,
-					name: '爱思考的大黄猫',
-					avatar: 'https://dummyimage.com/279x155/e3e3e3/fff'
-				},
-				list: [
-					{
-						id: 1,
-						time: '15:59',
-						content:'下个月初,也就是TGA呗。估计还是主机独占那么是买PS5还是XSX'
-					},
-					{
-						id: 2,
-						time: '15:59',
-						content:'国内的网络条件使用ps5会比xsx方便一些,特别是下载和更新'
-					},
-				],
+				user: {},
+				other_user: {},
+				list: [],
 				text: '',
 				show_menu: false,
-				show_jubao:false,
+				show_jubao: false,
 				jubao: '',
 				imgs: '',
-				fileList: []
+				fileList1: [],
+				chat_user_id: '',
+				userid: '',
 			}
 		},
-		onLoad() {
-			
+		onLoad(options) {
+			this.chat_user_id = options.chat_user_id
+			this.userid = uni.getStorageSync('userid')
+			this.getdata()
 		},
 		onShow() {
-			
+
 		},
 		onPullDownRefresh() {
-			
+
 		},
 		onReachBottom() {
-			
+
 		},
 		methods: {
+			submit() {
+				var that = this
+				let image = []
+				if(that.fileList1.length>0) {
+					for(var i=0;i<that.fileList1.length;i++) {
+						image.push(that.fileList1[i].url)
+					}
+				}
+				$api.req({
+					url: 'report',
+					method: 'post',
+					data: {
+						source_type: 'chat',
+						source_id: this.chat_user_id,
+						content: this.jubao,
+						images: image
+					}
+				}, function(res) {
+					$api.info('举报成功')
+					that.toclose()
+				})
+			},
+			send() {
+				var that = this
+				$api.req({
+					url: 'chat',
+					method: 'post',
+					data: {
+						chat_user_id: this.chat_user_id,
+						content: this.text
+					}
+				}, function(res) {
+					$api.info('发送成功')
+				})
+			},
+			getdata() {
+				var that = this
+				$api.req({
+					url: 'chat/detail',
+					data: {
+						is_page: 1,
+						page: 1,
+						limit: 25,
+						chat_user_id: this.chat_user_id
+					}
+				}, function(res) {
+					that.list = res.data.list
+				})
+			},
 			// 删除图片
 			deletePic(event) {
 				this[`fileList${event.name}`].splice(event.index, 1)
@@ -137,8 +176,9 @@
 							user: 'test'
 						},
 						success: (res) => {
+							let data = JSON.parse(res.data)
 							setTimeout(() => {
-								resolve(res.data.data)
+								resolve(data.data.url)
 							}, 1000)
 						}
 					});
@@ -160,20 +200,24 @@
 	.content::v-deep {
 		background: #FFFFFF;
 		padding: 20rpx 28rpx;
+
 		.popu {
 			background: #FFFFFF;
 			border-radius: 20rpx 20rpx 0rpx 0rpx;
 			box-sizing: border-box;
 			padding: 0 28rpx;
+
 			.title {
 				padding: 36rpx 0 28rpx;
 				width: 100%;
+
 				text {
 					font-size: 32rpx;
 					font-weight: 500;
 					color: #333333;
 				}
 			}
+
 			.u-textarea {
 				width: 694rpx;
 				height: 236rpx;
@@ -183,15 +227,18 @@
 				box-sizing: border-box;
 				border: none;
 			}
+
 			.upload-bg {
 				width: 160rpx;
 				height: 160rpx;
 				background: #F5F5F5;
 				border-radius: 12rpx;
 			}
+
 			.btn2 {
 				opacity: 1 !important;
 			}
+
 			.btn {
 				margin: 156rpx 0 54rpx;
 				width: 694rpx;
@@ -207,8 +254,10 @@
 				text-align: center;
 			}
 		}
+
 		.u-nav-right {
 			position: relative;
+
 			.menu {
 				position: absolute;
 				right: 0;
@@ -216,16 +265,19 @@
 				width: 188rpx;
 				height: 144rpx;
 				background: #FFFFFF;
-				box-shadow: 0rpx 4rpx 20rpx -4rpx rgba(0,0,0,0.2);
+				box-shadow: 0rpx 4rpx 20rpx -4rpx rgba(0, 0, 0, 0.2);
 				border-radius: 8rpx;
 				box-sizing: border-box;
 				padding: 26rpx 24rpx 0;
+
 				.menu-item {
 					padding: 0 0 32rpx;
+
 					image {
 						width: 36rpx;
 						height: 36rpx;
 					}
+
 					.menu-text {
 						padding-left: 12rpx;
 						font-size: 24rpx;
@@ -236,6 +288,7 @@
 				}
 			}
 		}
+
 		.bottom {
 			border-top: 1px solid #E5E5E5;
 			width: 100%;
@@ -245,6 +298,7 @@
 			background: #FFFFFF;
 			padding: 14rpx 28rpx 76rpx;
 			box-sizing: border-box;
+
 			.u-input {
 				width: 528rpx !important;
 				height: 76rpx;
@@ -253,9 +307,11 @@
 				border-radius: 40rpx;
 				padding: 18rpx 40rpx !important;
 			}
+
 			.btn2 {
 				opacity: 1 !important;
 			}
+
 			.btn {
 				margin-left: 20rpx;
 				width: 146rpx;
@@ -269,12 +325,14 @@
 				color: #FFFFFF;
 				text-align: center;
 				line-height: 76rpx;
-				
+
 			}
 		}
+
 		.list {
 			.list-item {
 				margin: 0 0 44rpx;
+
 				.time {
 					width: 100%;
 					text-align: center;
@@ -284,11 +342,13 @@
 					color: #999999;
 					padding-bottom: 24rpx;
 				}
+
 				image {
 					width: 68rpx;
 					height: 68rpx;
 					border-radius: 50%;
 				}
+
 				.text {
 					width: 512rpx;
 					background: #F5F5F5;
@@ -302,4 +362,4 @@
 			}
 		}
 	}
-</style>
+</style>

+ 35 - 45
pageA/dianzan-list.vue

@@ -1,11 +1,11 @@
 <template>
 	<view class="content">
 		<view class="list-item hflex acenter" v-for="(item,index) in list" :key="index">
-			<image :src="item.img" mode="aspectFill"></image>
+			<image :src="item.image" mode="aspectFill"></image>
 			<view class="img-right">
 				<view class="hflex acenter jbetween right-top">
-					<text>{{item.name}}</text>
-					<text>{{item.time}}</text>
+					<text>{{item.title}}</text>
+					<text>{{item.created_at}}</text>
 				</view>
 				<view class="text">{{item.content}}</view>
 			</view>
@@ -18,61 +18,44 @@
 	export default {
 		data() {
 			return {
-				list: []
+				list: [],
+				page: 1,
+				last_page: 1,
 			}
 		},
 		onLoad() {
 			this.getlist()
 		},
 		onShow() {
-			
+
 		},
 		onPullDownRefresh() {
-			
+
 		},
 		onReachBottom() {
-			
+			if (this.last_page == this.page) {
+				uni.$u.toast('已经到底了')
+				return
+			} else {
+				this.page++
+				this.getlist()
+			}
 		},
 		methods: {
 			getlist() {
-				this.list = [
-					{
-						img: 'https://dummyimage.com/279x155/e3e3e3/fff',
-						name: '爱思考的大黄猫',
-						content: `点赞了你的文章“文章标题显示文章标题显示文…”`,
-						time: '1小时前'
-					},
-					{
-						img: 'https://dummyimage.com/279x155/e3e3e3/fff',
-						name: '爱思考的大黄猫',
-						content: `点赞了你的文章“文章标题显示文章标题显示文…”`,
-						time: '1小时前'
-					},
-					{
-						img: 'https://dummyimage.com/279x155/e3e3e3/fff',
-						name: '爱思考的大黄猫',
-						content: `点赞了你的文章“文章标题显示文章标题显示文…”`,
-						time: '1小时前'
-					},
-					{
-						img: 'https://dummyimage.com/279x155/e3e3e3/fff',
-						name: '爱思考的大黄猫',
-						content: `点赞了你的文章“文章标题显示文章标题显示文…”`,
-						time: '1小时前'
-					},
-					{
-						img: 'https://dummyimage.com/279x155/e3e3e3/fff',
-						name: '爱思考的大黄猫',
-						content: `点赞了你的文章“文章标题显示文章标题显示文…”`,
-						time: '1小时前'
-					},
-					{
-						img: 'https://dummyimage.com/279x155/e3e3e3/fff',
-						name: '爱思考的大黄猫',
-						content: `点赞了你的文章“文章标题显示文章标题显示文…”`,
-						time: '1小时前'
+				var that = this
+				$api.req({
+					url: 'notification',
+					data: {
+						is_page: 1,
+						page: that.page,
+						limit: 10,
+						type: 'like'
 					}
-				]
+				}, function(res) {
+					that.list = that.list.concat(res.data.list)
+					that.last_page = res.data.last_page
+				})
 			},
 		}
 	}
@@ -82,25 +65,31 @@
 	.content {
 		background-color: #FFFFFF;
 		padding: 0 28rpx;
+
 		.list-item {
 			padding: 28rpx 0 32rpx;
 			border-bottom: 1px solid #F5F5F5;
+
 			image {
 				width: 92rpx;
 				height: 92rpx;
 				border-radius: 50%;
 			}
+
 			.img-right {
 				width: calc(100% - 92rpx);
 				padding: 0 0 0 20rpx;
+
 				.right-top {
 					width: 100%;
+
 					text:first-child {
 						font-size: 32rpx;
 						font-family: PingFangSC, PingFang SC;
 						font-weight: 600;
 						color: #333333;
 					}
+
 					text:last-child {
 						font-size: 22rpx;
 						font-family: PingFangSC, PingFang SC;
@@ -108,6 +97,7 @@
 						color: #999999;
 					}
 				}
+
 				.text {
 					font-size: 24rpx;
 					font-family: PingFangSC, PingFang SC;
@@ -118,4 +108,4 @@
 			}
 		}
 	}
-</style>
+</style>

+ 23 - 10
pageA/huati.vue

@@ -5,7 +5,8 @@
 		</view>
 		<view class="hflex center">
 			<scroll-view class="left" :scroll-y="true">
-				<view class="left-item" :class="left_active == index ? 'left-active' : ''" v-for="(item,index) in left_list" :key="index" @click="toleft(index)">
+				<view class="left-item" :class="left_active == index ? 'left-active' : ''"
+					v-for="(item,index) in left_list" :key="index" @click="toleft(index)">
 					<text>{{item.name}}</text>
 				</view>
 			</scroll-view>
@@ -33,27 +34,31 @@
 			}
 		},
 		onLoad(option) {
-			if(option.type) {
+			if (option.type) {
 				this.type = option.type
 			}
 			this.getleft()
 		},
 		onShow() {
-			
+
 		},
 		onPullDownRefresh() {
-			
+
 		},
 		onReachBottom() {
-			
+
 		},
 		methods: {
 			toinfo(item) {
-				
-				if(this.type == 'select') {
+
+				if (this.type == 'select') {
 					const eventChannel = this.getOpenerEventChannel();
 					eventChannel.emit('getitem', item);
 					uni.navigateBack()
+				} else {
+					uni.navigateTo({
+						url: '/pageA/topic-detail?id=' + item.id
+					})
 				}
 			},
 			toleft(index) {
@@ -77,7 +82,7 @@
 						category_id: _this.left_list[_this.left_active].id
 					}
 				}, function(res) {
-					if(res.code == 10000) {
+					if (res.code == 10000) {
 						_this.list = res.data.list
 					}
 				})
@@ -88,7 +93,7 @@
 					url: 'topic/category',
 					method: 'GET',
 				}, function(res) {
-					if(res.code == 10000) {
+					if (res.code == 10000) {
 						_this.left_list = res.data
 						_this.getlist()
 					}
@@ -101,6 +106,7 @@
 <style lang="scss">
 	.content::v-deep {
 		background: #FFFFFF;
+
 		.search {
 			width: 694rpx;
 			height: 76rpx;
@@ -108,24 +114,30 @@
 			border-radius: 16rpx;
 			margin: 0 auto;
 		}
+
 		.center {
 			box-sizing: border-box;
 			padding: 36rpx 0 0;
+
 			.right {
 				box-sizing: border-box;
 				padding: 0 28rpx 0 60rpx;
+
 				.right-item {
 					padding: 34rpx 0;
 					border-bottom: 1px solid #F4F4F4;
 				}
+
 				.right-item:last-child {
 					border: none;
 				}
 			}
+
 			.left {
 				height: calc(100vh - 192rpx);
 				width: 204rpx;
 				background: #F5F5F5;
+
 				.left-item {
 					width: 100%;
 					padding: 26rpx 0;
@@ -137,6 +149,7 @@
 					color: #999999;
 					text-align: center;
 				}
+
 				.left-active {
 					color: #222222;
 					background: #FFFFFF;
@@ -144,4 +157,4 @@
 			}
 		}
 	}
-</style>
+</style>

+ 252 - 32
pageA/info-detail.vue

@@ -13,18 +13,19 @@
 				<image src="../static/images/arrow-right.png" mode="aspectFill" class="icon"></image>
 			</view>
 			<view v-if="type == 'post'">
-				<u-swiper :indicator="true" indicatorMode="dot" :list="detail.images" height="452rpx" radius="12rpx" v-if="detail.images.length > 0">
+				<u-swiper :indicator="true" indicatorMode="dot" :list="detail.images" height="452rpx" radius="12rpx"
+					v-if="detail.images && detail.images.length > 0">
 				</u-swiper>
 			</view>
 			<view class="title" v-if="detail.title">{{detail.title}}</view>
 			<view class="user hflex acenter jbetween" v-if="detail.user">
-				<view class="hflex acenter" >
-					<image :src="detail.user.avatar" mode="aspectFill"></image>
+				<view class="hflex acenter">
+					<image :src="detail.user.avatar" mode="aspectFill" @click="touser"></image>
 					<view class="user-name">{{detail.user.username}}</view>
 				</view>
-				<view class="user-btn hflex acenter jcenter" v-if="detail.user.id == userid">
+				<view class="user-btn hflex acenter jcenter" v-if="detail.user.id != userid" @click="toFollow">
 					<image src="./static/like.png" mode="aspectFill"></image>
-					<text>{{item.is_like == 0 ? '关注' : '已关注'}}</text>
+					<text>{{detail.is_follow == 0 ? '关注' : '已关注'}}</text>
 				</view>
 			</view>
 			<view class="detail">
@@ -34,11 +35,12 @@
 			<view class="circle hflex acenter" v-if="detail.topic_id != 0 && detail.topic">
 				<text>{{detail.topic.title}}</text>
 			</view>
-			<comment-list :show_jianpan="show_jianpan" :type="type" :id="detail.id" :user="detail.user" v-if="detail.user"></comment-list>
+			<comment-list :show_jianpan="show_jianpan" :type="type" :id="detail.id" :user="detail.user"
+				v-if="detail.user"></comment-list>
 		</view>
 		<view style="height: 166rpx;"></view>
 		<view class="bottom hflex acneter jbetween">
-			<u--input v-model="comment" border="none" placeholder="添加新评论"></u--input>
+			<u-input v-model="comment" border="none" placeholder="添加新评论"></u-input>
 			<view class="hflex acenter jbetween bottom-right">
 				<view class="vflex acenter jbetween bottom-item" @click="tolike">
 					<image src="/static/images/dianzan.png" mode="aspectFill" v-if="detail.is_like == 0"></image>
@@ -65,7 +67,7 @@
 						</view>
 						<text>复制链接</text>
 					</view>
-					<view class="vflex acenter jcenter top-item">
+					<view class="vflex acenter jcenter top-item" @click="show_jubao = true">
 						<view class="img-bg vflex acenter jcenter" style="background: #E9E9E9;">
 							<image src="/pageA/static/warn.png" mode="aspectFill"></image>
 						</view>
@@ -75,6 +77,25 @@
 				<view class="btn hflex acenter jcenter" @click="toclose">取消</view>
 			</view>
 		</u-popup>
+		<u-popup :show="show_jubao" @close="toclose" mode="bottom" :round="10">
+			<view class="popu1">
+				<view class="title hflex acenter jbetween">
+					<text>内容描述</text>
+					<u-icon name="close" color="#000000" size="14" @click="toclose"></u-icon>
+				</view>
+				<u--textarea v-model="jubao" placeholder="请对您举报的内容进行文字描述"></u--textarea>
+				<view class="title">
+					<text>辅助图片</text>
+				</view>
+				<u-upload :fileList="fileList1" @afterRead="afterRead" @delete="deletePic" name="1" :maxCount="9"
+					width="160rpx" height="160rpx">
+					<view class="upload-bg hflex acenter jcenter">
+						<u-icon name="plus" color="#CCCCCC" size="20"></u-icon>
+					</view>
+				</u-upload>
+				<view class="btn" :class="jubao != '' ? 'btn2' : ''" @click="tojubao">确定</view>
+			</view>
+		</u-popup>
 	</view>
 </template>
 
@@ -94,26 +115,32 @@
 				show_jianpan: false,
 				type: '',
 				userid: '',
-				show: false
+				show: false,
+				fileList1: [],
+				jubao: '',
+				show_jubao: false,
+				login: false,
 			}
 		},
 		onLoad(option) {
-			this.userid = uni.getStorageSync('id')
-			if(option.id) {
+			this.userid = uni.getStorageSync('userid')
+			this.login = uni.getStorageSync('token') ? true: false
+			console.log(this.userid);
+			if (option.id) {
 				this.id = option.id
 			}
-			if(option.type) {
+			if (option.type) {
 				this.type = option.type
-				if(this.type == 'info') {
+				if (this.type == 'info') {
 					this.title = '资讯'
 				}
-				if(this.type == 'article') {
+				if (this.type == 'article') {
 					this.title = '文章'
 				}
-				if(this.type == 'video') {
+				if (this.type == 'video') {
 					this.title = '视频'
 				}
-				if(this.type == 'post') {
+				if (this.type == 'post') {
 					this.title = '论坛'
 				}
 			}
@@ -121,13 +148,110 @@
 			uni.onKeyboardHeightChange(this.onKeyboardHeightChange);
 		},
 		onUnload() {
-		  uni.offKeyboardHeightChange(this.onKeyboardHeightChange);
+			uni.offKeyboardHeightChange(this.onKeyboardHeightChange);
 		},
 		methods: {
+			touser() {
+				uni.navigateTo({
+					url: '/pageC/otherInfo?id=' + this.detail.user.id
+				})
+			},
+			toFollow() {
+				if(!this.login) {
+					$api.info('请先登录')
+					return
+				}
+				var that = this
+				$api.req({
+					url: 'user/' + that.detail.user.id + '/follow',
+					method: 'post'
+				}, function(res) {
+					$api.info(res.msg)
+					that.getdata()
+				})
+			},
+			tojubao() {
+				if(!this.login) {
+					$api.info('请先登录')
+					return
+				}
+				var that = this
+				let image = []
+				if(that.fileList1.length>0) {
+					for(var i=0;i<that.fileList1.length;i++) {
+						image.push(that.fileList1[i].url)
+					}
+				}
+				$api.req({
+					url: 'report',
+					method: 'post',
+					data: {
+						source_type: that.type,
+						source_id: that.id,
+						content: that.jubao,
+						images: image
+					}
+				}, function(res) {
+					$api.info('举报成功')
+					that.toclose()
+				})
+			},
+			// 删除图片
+			deletePic(event) {
+				this[`fileList${event.name}`].splice(event.index, 1)
+			},
+			// 新增图片
+			async afterRead(event) {
+				// 当设置 multiple 为 true 时, file 为数组格式,否则为对象格式
+				let lists = [].concat(event.file)
+				let fileListLen = this[`fileList${event.name}`].length
+				lists.map((item) => {
+					this[`fileList${event.name}`].push({
+						...item,
+						status: 'uploading',
+						message: '上传中'
+					})
+				})
+				for (let i = 0; i < lists.length; i++) {
+					const result = await this.uploadFilePromise(lists[i].url)
+					let item = this[`fileList${event.name}`][fileListLen]
+					this[`fileList${event.name}`].splice(fileListLen, 1, Object.assign(item, {
+						status: 'success',
+						message: '',
+						url: result
+					}))
+					fileListLen++
+				}
+			},
+			uploadFilePromise(url) {
+				return new Promise((resolve, reject) => {
+					let a = uni.uploadFile({
+						url: $api.config.baseUrl + 'upload/image', // 仅为示例,非真实的接口地址
+						filePath: url,
+						name: 'image',
+						formData: {
+							user: 'test'
+						},
+						success: (res) => {
+							let data = JSON.parse(res.data)
+							setTimeout(() => {
+								resolve(data.data.url)
+							}, 1000)
+						}
+					});
+				})
+			},
 			copy() {
-				
+				let text = $api.config.luck
+				if(this.type == 'info') {
+					text += 'news?id=' + this.id
+				} else if(this.type == 'articles') {
+					text += 'Articles?id=' + this.id
+				} else if(this.type == 'video') {
+					text += 'videos?id=' + this.id + '&type=common'
+				}
 				uni.setClipboardData({
-					data: '/pageA/info-detail?id=' + this.id + '&type=' + this.type,
+					data: text,
 					success() {
 						uni.$u.toast('复制成功')
 					}
@@ -138,8 +262,13 @@
 			},
 			toclose() {
 				this.show = false
+				this.show_jubao = false
 			},
 			tocollect() {
+				if(!this.login) {
+					$api.info('请先登录')
+					return
+				}
 				var _this = this
 				$api.req({
 					url: 'collect',
@@ -149,16 +278,20 @@
 						source_id: _this.id
 					}
 				}, function(res) {
-					if(res.code == 10000) {
+					if (res.code == 10000) {
 						uni.$u.toast(res.msg)
 						setTimeout(() => {
 							_this.getdata()
-						},800)
+						}, 800)
 					}
 				})
 			},
 			tolike() {
 				var _this = this
+				if(!this.login) {
+					$api.info('请先登录')
+					return
+				}
 				$api.req({
 					url: 'like',
 					method: 'POST',
@@ -167,17 +300,20 @@
 						source_id: _this.id
 					}
 				}, function(res) {
-					if(res.code == 10000) {
+					if (res.code == 10000) {
 						uni.$u.toast(res.msg)
 						setTimeout(() => {
 							_this.getdata()
-						},800)
+						}, 800)
 					}
 				})
 			},
 			onKeyboardHeightChange(e) {
-				const { height, duration } = e;
-				if(height > 0) {
+				const {
+					height,
+					duration
+				} = e;
+				if (height > 0) {
 					this.show_jianpan = true
 				} else {
 					this.show_jianpan = false
@@ -203,10 +339,66 @@
 	.info-detail::v-deep {
 		background: #FFFFFF;
 		min-height: 100vh;
+
+		.popu1 {
+			background: #FFFFFF;
+			border-radius: 20rpx 20rpx 0rpx 0rpx;
+			box-sizing: border-box;
+			padding: 0 28rpx;
+
+			.title {
+				padding: 36rpx 0 28rpx;
+				width: 100%;
+
+				text {
+					font-size: 32rpx;
+					font-weight: 500;
+					color: #333333;
+				}
+			}
+
+			.u-textarea {
+				width: 694rpx;
+				height: 236rpx;
+				background: #F5F5F5;
+				border-radius: 12rpx;
+				padding: 28rpx 20rpx !important;
+				box-sizing: border-box;
+				border: none;
+			}
+
+			.upload-bg {
+				width: 160rpx;
+				height: 160rpx;
+				background: #F5F5F5;
+				border-radius: 12rpx;
+			}
+
+			.btn2 {
+				opacity: 1 !important;
+			}
+
+			.btn {
+				margin: 156rpx 0 54rpx;
+				width: 694rpx;
+				height: 88rpx;
+				background: #00B0B0;
+				border-radius: 44rpx;
+				opacity: 0.2;
+				font-size: 32rpx;
+				font-family: PingFangSC, PingFang SC;
+				font-weight: 500;
+				color: #FFFFFF;
+				line-height: 88rpx;
+				text-align: center;
+			}
+		}
+
 		.popu {
 			background: #FFFFFF;
 			border-radius: 20rpx 20rpx 0rpx 0rpx;
-			padding: 82rpx 0;
+			padding: 82rpx 30rpx;
+
 			.btn {
 				padding: 24rpx 0 0;
 				font-size: 32rpx;
@@ -214,21 +406,26 @@
 				font-weight: 400;
 				color: #444444;
 			}
+
 			.top {
 				padding-bottom: 40rpx;
 				border-bottom: 1px solid #F7F7F7;
+
 				.top-item {
 					padding: 0 0 0 108rpx;
+
 					.img-bg {
 						width: 96rpx;
 						height: 96rpx;
 						background: #00B0B0;
 						border-radius: 50%;
+
 						image {
 							width: 36rpx;
 							height: 36rpx;
 						}
 					}
+
 					text {
 						padding: 16rpx 0 0;
 						font-size: 22rpx;
@@ -236,28 +433,32 @@
 						font-weight: 400;
 						color: #444444;
 					}
-					
+
 				}
-				
+
 			}
 		}
+
 		.bottom {
 			width: 100%;
 			position: fixed;
 			bottom: 0;
 			left: 0;
 			background: #FFFFFF;
-			box-shadow: 0rpx 0rpx 0rpx 0rpx rgba(0,0,0,0.1);
+			box-shadow: 0rpx 0rpx 0rpx 0rpx rgba(0, 0, 0, 0.1);
 			padding: 14rpx 24rpx 80rpx;
 			box-sizing: border-box;
+
 			.bottom-right {
 				.bottom-item {
 					margin-left: 38rpx;
 					height: 72rpx;
+
 					image {
 						width: 40rpx;
 						height: 38rpx;
 					}
+
 					text {
 						padding-top: 8rpx;
 						font-size: 20rpx;
@@ -267,27 +468,32 @@
 					}
 				}
 			}
+
 			.u-input {
 				background: #F5F5F5;
 				border-radius: 40rpx;
 				width: 446rpx !important;
-				height: 72rpx ;
+				height: 72rpx;
 				padding: 0 32rpx !important;
 			}
-			
+
 		}
+
 		.cover {
 			width: 100%;
+
 			.video {
 				width: 100%;
 				box-sizing: border-box;
 				padding: 28rpx;
 				// height: 182rpx;
 				background: #F5F5F5;
+
 				.img {
 					width: 224rpx;
 					height: 126rpx;
 				}
+
 				text {
 					font-size: 28rpx;
 					font-family: SFPro, SFPro;
@@ -295,14 +501,17 @@
 					color: #333333;
 					width: 354rpx;
 				}
+
 				.icon {
 					width: 24rpx;
 					height: 24rpx;
 				}
 			}
+
 			image {
 				width: 100%;
 			}
+
 			.title {
 				padding: 28rpx 32rpx;
 				font-size: 36rpx;
@@ -310,13 +519,16 @@
 				font-weight: 600;
 				color: #333333;
 			}
+
 			.user {
-				padding: 0 28rpx 30rpx;
+				padding: 30rpx 28rpx 30rpx;
+
 				image {
 					width: 68rpx;
 					height: 68rpx;
 					border-radius: 50%;
 				}
+
 				.user-name {
 					font-size: 28rpx;
 					font-family: PingFangSC, PingFang SC;
@@ -324,15 +536,18 @@
 					color: #333333;
 					padding-left: 20rpx;
 				}
+
 				.user-btn {
 					width: 140rpx;
 					height: 60rpx;
 					background: #00B0B0;
 					border-radius: 30rpx;
+
 					image {
 						width: 36rpx;
 						height: 36rpx;
 					}
+
 					text {
 						font-size: 28rpx;
 						font-family: PingFangSC, PingFang SC;
@@ -342,9 +557,11 @@
 					}
 				}
 			}
+
 			.detail {
 				padding: 0 28rpx;
 			}
+
 			.time {
 				padding: 32rpx 28rpx;
 				font-size: 28rpx;
@@ -352,16 +569,19 @@
 				font-weight: 400;
 				color: #999999;
 			}
+
 			.circle {
 				margin: 0 28rpx 48rpx;
 				background: rgba(0, 176, 176, .1);
 				border-radius: 34rpx;
 				padding: 14rpx 20rpx;
 				max-width: max-content;
+
 				image {
 					width: 40rpx;
 					height: 40rpx;
 				}
+
 				text {
 					font-size: 28rpx;
 					font-family: AppleColorEmoji;

+ 78 - 23
pageA/message.vue

@@ -26,8 +26,8 @@
 		<view class="list" v-if="list.length> 0 && current == 1">
 			<view class="list-item" v-for="(item,index) in list" :key="index">
 				<view class="item-top hflex acenter jbetween">
-					<text class="text_hide">{{item.name}}</text>
-					<text>{{item.time}}</text>
+					<text class="text_hide">{{item.title}}</text>
+					<text>{{item.created_at}}</text>
 				</view>
 				<view class="text">{{item.content}}</view>
 			</view>
@@ -37,15 +37,15 @@
 		</view>
 		<view class="list" v-if="list.length > 0 && current == 2">
 			<view class="list-item2 hflex acenter" v-for="(item,index) in list" :key="index" @click="tochat(item)">
-				<image :src="item.img" mode="aspectFill"></image>
+				<image :src="item.chat_user.avatar" mode="aspectFill"></image>
 				<view class="img-right">
 					<view class="hflex acenter jbetween right-top">
-						<text>{{item.name}}</text>
-						<text>{{item.time}}</text>
+						<text>{{item.chat_user.username}}</text>
+						<text>{{item.created_at}}</text>
 					</view>
 					<view class="hflex acneter jbetween">
 						<view class="text text_hide">{{item.content}}</view>
-						<view class="num" v-if="item.num > 0">{{item.num}}</view>
+						<view class="num" v-if="item.unread_count > 0">{{item.unread_count}}</view>
 					</view>
 				</view>
 			</view>
@@ -55,37 +55,69 @@
 
 <script>
 	import $api from '@/static/js/api.js'
+	var that = ''
 	export default {
 		data() {
 			return {
 				current: 1,
-				list: [
-					{
-						img: 'https://dummyimage.com/279x155/e3e3e3/fff',
-						num: 19,
-						name: '滋···叮!点赞大佬勋章解锁成功!',
-						time: '1个月前',
-						content: '恭喜!你已成功领取“点赞大佬”勋章~想赶紧把它装备起来吗?请猛戳 成就勋章'
-					}
-				]
+				list: [],
+				page: 1,
+				last_page: 1
 			}
 		},
 		onLoad() {
-			
+			that = this
 		},
 		onShow() {
-			
+			this.list = []
+			this.page = 1
+			this.getlist()
 		},
 		onPullDownRefresh() {
-			
+
 		},
 		onReachBottom() {
-			
+			if (this.last_page == this.page) {
+				uni.$u.toast('已经到底了')
+				return
+			} else {
+				this.page++
+				this.getlist()
+			}
 		},
 		methods: {
+			getlist() {
+				if (this.current == 1) {
+					$api.req({
+						url: 'notification',
+						data: {
+							is_page: 1,
+							page: that.page,
+							limit: 10,
+							type: 'system'
+						}
+					}, function(res) {
+						that.list = that.list.concat(res.data.list)
+						that.last_page = res.data.last_page
+					})
+				} else {
+					$api.req({
+						url: 'chat',
+						data: {
+							is_page: 1,
+							page: that.page,
+							limit: 10,
+						}
+					}, function(res) {
+						that.list = that.list.concat(res.data)
+						that.last_page = res.data.last_page
+					})
+				}
+
+			},
 			tochat(item) {
 				uni.navigateTo({
-					url: '/pageA/chat'
+					url: '/pageA/chat?chat_user_id=' + item.chat_user_id
 				})
 			},
 			topinglun() {
@@ -105,7 +137,10 @@
 			},
 			tochangetab(index) {
 				this.current = index
-			} 
+				this.list = []
+				this.page = 1
+				this.getlist()
+			}
 		}
 	}
 </script>
@@ -113,17 +148,21 @@
 <style lang="scss">
 	.content {
 		background: #F5F5F5;
+
 		.list {
 			width: 100%;
 			min-height: calc(100vh - 400rpx);
 			background: #FFFFFF;
 			box-sizing: border-box;
 			padding: 0 28rpx;
+
 			.list-item {
 				padding: 28rpx 0 32rpx;
 				border-bottom: 1px solid #F5F5F5;
+
 				.item-top {
 					width: 100%;
+
 					text:first-child {
 						font-size: 32rpx;
 						font-family: PingFangSC, PingFang SC;
@@ -131,6 +170,7 @@
 						color: #333333;
 						max-width: 550rpx;
 					}
+
 					text:last-child {
 						font-size: 22rpx;
 						font-family: PingFangSC, PingFang SC;
@@ -138,6 +178,7 @@
 						color: #666666;
 					}
 				}
+
 				.text {
 					font-size: 24rpx;
 					font-family: PingFangSC, PingFang SC;
@@ -146,25 +187,31 @@
 					padding: 20rpx 0 0;
 				}
 			}
+
 			.list-item2 {
 				padding: 28rpx 0 32rpx;
 				border-bottom: 1px solid #F5F5F5;
+
 				image {
 					width: 92rpx;
 					height: 92rpx;
 					border-radius: 50%;
 				}
+
 				.img-right {
 					width: calc(100% - 92rpx);
 					padding: 0 0 0 20rpx;
+
 					.right-top {
 						width: 100%;
+
 						text:first-child {
 							font-size: 32rpx;
 							font-family: PingFangSC, PingFang SC;
 							font-weight: 600;
 							color: #333333;
 						}
+
 						text:last-child {
 							font-size: 22rpx;
 							font-family: PingFangSC, PingFang SC;
@@ -172,6 +219,7 @@
 							color: #999999;
 						}
 					}
+
 					.text {
 						max-width: 500rpx;
 						font-size: 24rpx;
@@ -180,6 +228,7 @@
 						color: #666666;
 						padding: 14rpx 0 0;
 					}
+
 					.num {
 						background: #F34025;
 						font-size: 20rpx;
@@ -192,6 +241,7 @@
 					}
 				}
 			}
+
 			.empty {
 				width: 264rpx;
 				padding-top: 264rpx;
@@ -202,17 +252,20 @@
 				color: rgba(34, 34, 34, .5);
 			}
 		}
+
 		.top {
 			width: 100%;
 			box-sizing: border-box;
 			padding: 44rpx 72rpx 34rpx;
 			background: #FFFFFF;
 			margin: 0 0 20rpx;
+
 			.item {
 				image {
 					width: 96rpx;
 					height: 96rpx;
 				}
+
 				text {
 					font-size: 24rpx;
 					font-family: PingFangSC, PingFang SC;
@@ -221,8 +274,9 @@
 					padding: 16rpx 0 0;
 				}
 			}
-			
+
 		}
+
 		.u-nav-center {
 			.item {
 				font-size: 36rpx;
@@ -231,9 +285,10 @@
 				color: rgba(34, 34, 34, .4);
 				padding-right: 46rpx;
 			}
+
 			.active {
 				color: #222222;
 			}
 		}
 	}
-</style>
+</style>

+ 103 - 38
pageA/pinglun-list.vue

@@ -2,24 +2,30 @@
 	<view class="content">
 		<view class="list-item" v-for="(item,index) in list" :key="index">
 			<view class="top hflex acenter jbetween">
-				<view class="user hflex acenter">
+				<view class="user hflex acenter" v-if="item.user">
 					<image :src="item.user.avatar" mode="aspectFill"></image>
 					<view class="user-name vflex">
-						<text>{{item.user.name}}</text>
-						<text>{{item.time}}</text>
+						<text>{{item.user.username}}</text>
+						<text>{{item.created_at}}</text>
 					</view>
 				</view>
-				<view class="reply-btn">回复</view>
+				<view class="reply-btn" @click="toreply(item)">回复</view>
 			</view>
 			<view class="text">{{item.content}}</view>
 			<view class="vflex item">
-				<view class="pinglun" v-if="item.pinglun">{{item.pinglun.name}}:<span style="color: #444444;padding-left: 8rpx;">{{item.pinglun.content}}</span></view>
+				<view class="pinglun" v-if="item.parent">{{item.parent_user.username}}:<span
+						style="color: #444444;padding-left: 8rpx;">{{item.parent.content}}</span></view>
 				<view class="hflex acenter">
-					<image :src="item.img" mode="aspectFill"></image>
-					<text class="text_hide2">{{item.name}}</text>
+					<image :src="item.source.image" mode="aspectFill"></image>
+					<text class="text_hide2">{{item.source.title}}</text>
 				</view>
 			</view>
 		</view>
+		<view class="huifu hflex acenter jbetween" v-if="show">
+			<!-- <image :src="user.avatar" mode="aspectFill"></image> -->
+			<u-input v-model="content" placeholder="添加新评论" border="none" adjustPosition focus></u-input>
+			<text @click="reply">发送</text>
+		</view>
 	</view>
 </template>
 
@@ -28,49 +34,69 @@
 	export default {
 		data() {
 			return {
-				list: []
+				list: [],
+				page: 1,
+				last_page: 1,
+				user_id: '',
+				content: '',
+				data: {},
+				show: false
 			}
 		},
 		onLoad() {
+			this.user_id = uni.getStorageSync('userid')
 			this.getlist()
 		},
 		onShow() {
-			
+
 		},
 		onPullDownRefresh() {
-			
+
 		},
 		onReachBottom() {
-			
+
 		},
 		methods: {
+			toreply(item) {
+				this.data = item
+				this.show = true
+			},
+			reply() {
+				let item = this.data
+				var that = this
+				$api.req({
+					url: 'comment',
+					method: 'post',
+					data: {
+						source_type: item.source_type,
+						source_id: item.source_id,
+						content: this.content,
+						parent_id: item.parent_id
+						
+					}
+				}, function(res) {
+					$api.info(res.msg)
+					that.content = ''
+					that.show = false
+					setTimeout(()=> {
+						that.getlist()
+					})
+				})
+			},
 			getlist() {
-				this.list = [
-					{
-						user: {
-							avatar: 'https://dummyimage.com/279x155/e3e3e3/fff',
-							name: '可可布丁w'
-						},
-						time: '1小时前',
-						content: '在过去两年,VR全景成为比较热门的话题,在疫情来袭期间,VR全景制作给…',
-						img: 'https://dummyimage.com/279x155/e3e3e3/fff',
-						name:'这袜子卖么?办公出行好伴侣,这次全靠他们了!丨恰到好处',
-						pinglun: {
-							name: '熊吉吉',
-							content: '太短了,不够看'
-						}
-					},
-					{
-						user: {
-							avatar: 'https://dummyimage.com/279x155/e3e3e3/fff',
-							name: '可可布丁w'
-						},
-						time: '1小时前',
-						content: '在过去两年,VR全景成为比较热门的话题,在疫情来袭期间,VR全景制作给…',
-						img: 'https://dummyimage.com/279x155/e3e3e3/fff',
-						name:'这袜子卖么?办公出行好伴侣,这次全靠他们了!丨恰到好处',
+				var that = this
+				$api.req({
+					url: 'comment/my-list',
+					data: {
+						limit: 10,
+						is_page: 1,
+						page: that.page
 					}
-				]
+				}, function(res) {
+					that.list = that.list.concat(res.data.list)
+					that.last_page = res.data.last_page
+
+				})
 			},
 		}
 	}
@@ -78,15 +104,19 @@
 
 <style lang="scss">
 	.content {
-		
+
 		background: #F5F5F5;
+
 		.list-item {
 			padding: 0 0 20rpx;
 			margin: 0 0 20rpx;
 			background: #FFFFFF;
+
 			.top {
 				padding: 26rpx 28rpx;
+
 				.user {
+
 					// padding: 20rpx 0 0 ;
 					image {
 						width: 80rpx;
@@ -94,6 +124,7 @@
 						border-radius: 50%;
 						margin-right: 20rpx;
 					}
+
 					.user-name {
 						text:first-child {
 							font-size: 28rpx;
@@ -101,6 +132,7 @@
 							font-weight: 500;
 							color: #333333;
 						}
+
 						text:last-child {
 							font-size: 22rpx;
 							font-family: PingFangSC, PingFang SC;
@@ -110,6 +142,7 @@
 						}
 					}
 				}
+
 				.reply-btn {
 					width: 104rpx;
 					height: 52rpx;
@@ -123,6 +156,7 @@
 					text-align: center;
 				}
 			}
+
 			.text {
 				padding: 0 28rpx 20rpx;
 				font-size: 28rpx;
@@ -130,10 +164,12 @@
 				font-weight: 400;
 				color: #333333;
 			}
+
 			.item {
 				background: #F5F5F5;
 				padding: 20rpx 28rpx;
 				box-sizing: border-box;
+
 				.pinglun {
 					font-size: 26rpx;
 					font-family: PingFangSC, PingFang SC;
@@ -141,10 +177,12 @@
 					color: #00B0B0;
 					padding: 0 0 20rpx;
 				}
+
 				image {
 					width: 160rpx;
 					height: 90rpx;
 				}
+
 				text {
 					font-size: 24rpx;
 					font-family: PingFangSC, PingFang SC;
@@ -157,5 +195,32 @@
 				}
 			}
 		}
+		.huifu {
+			position: fixed;
+			bottom: 0;
+			left: 0;
+			height: 160rpx;
+			z-index: 999;
+			background: #FFFFFF;
+			// box-shadow: 0rpx 0rpx 0rpx 0rpx rgba(0,0,0,0.1);
+			padding: 20rpx 28rpx;
+			box-sizing: border-box;
+			width: 100%;
+		
+			image {
+				width: 56rpx !important;
+				height: 56rpx;
+				border-radius: 50%;
+				margin: 0 20rpx 0 0;
+			}
+		
+			text {
+				font-size: 32rpx;
+				font-family: PingFangSC, PingFang SC;
+				font-weight: 500;
+				color: #999999;
+			}
+		}
+		
 	}
-</style>
+</style>

+ 53 - 23
pageA/publish.vue

@@ -37,17 +37,28 @@
 			}
 		},
 		onLoad(options) {
-			this.data = JSON.parse(options.data)
+			if (options.data) {
+				this.data = JSON.parse(decodeURIComponent(options.data))
+			}
 			this.type = options.type
+			if (options.edit == '1') {
+				this.image = this.data.image
+				let data = {
+					id: this.data.topic_id
+				}
+				this.data.topic = data
+			}
+			console.log(this.data, this.type);
 		},
+
 		onShow() {
-			
+
 		},
 		onPullDownRefresh() {
-			
+
 		},
 		onReachBottom() {
-			
+
 		},
 		methods: {
 			topublish(status) {
@@ -60,27 +71,35 @@
 					status: status,
 					image: this.image
 				}
-				if(this.type == 'zixun') {
+				if (this.type == 'info') {
 					url = 'info'
-				} else if(this.type == 'wenzhang') {
+				} else if (this.type == 'article') {
 					url = 'article'
-				} else if(this.type == 'video') {
+				} else if (this.type == 'video') {
 					url = 'video'
-					this.form.video_title = this.data.video_title
-					this.form.video_url = this.data.video_url
+					form.video_title = this.data.video_title
+					form.video_url = this.data.video_url
 				}
-				console.log(form,'上传数据',url);
+				console.log(form, '上传数据', url);
 				$api.req({
 					url: url,
 					method: 'POST',
 					data: form
 				}, function(res) {
 					console.log(res);
-					if(res.code == 10000) {
-						uni.$u.toast('发布成功')
-						uni.navigateBack({
-							delta: 2
-						})
+					$api.info(res.msg)
+					if (res.code == 10000) {
+						setTimeout(() => {
+							if(status == 'normal') {
+								uni.switchTab({
+									url: '/pages/index/index'
+								})
+							} else {
+								uni.navigateTo({
+									url: '/pageC/drafts'
+								})
+							}
+						},1000)
 					}
 				})
 			},
@@ -96,7 +115,7 @@
 							filePath: tempFilePaths[0],
 							name: 'image',
 							success: (uploadFileRes) => {
-								
+
 								let res = JSON.parse(uploadFileRes.data)
 								this.image = res.data.url
 								uni.hideLoading()
@@ -112,26 +131,31 @@
 <style lang="scss">
 	.content {
 		background: #FFFFFF;
+
 		.top {
 			width: 100%;
 			box-sizing: border-box;
 			padding: 28rpx;
 			border-bottom: 1px solid #F2F2F2;
+
 			text:first-child {
-				font-size: 36rpx;
+				font-size: 40rpx;
 				font-family: SFPro, SFPro;
 				font-weight: 400;
 				color: #222222;
 			}
+
 			.text {
 				width: 100%;
 				height: 96rpx;
 				overflow: hidden;
-				padding: 10rpx 0 0 ;
+				padding: 10rpx 0 0;
 			}
 		}
+
 		.imgs {
 			padding: 34rpx 28rpx;
+
 			text {
 				font-size: 32rpx;
 				font-family: PingFangSC, PingFang SC;
@@ -139,6 +163,7 @@
 				color: #222222;
 				padding-right: 42rpx;
 			}
+
 			.img {
 				width: 574rpx;
 				height: 334rpx;
@@ -146,21 +171,24 @@
 				border-radius: 12rpx;
 				overflow: hidden;
 				position: relative;
+
 				.icon {
 					width: 86rpx;
 					height: 86rpx;
 				}
+
 				image {
 					width: 100%;
 					height: 100%;
 				}
+
 				text {
 					position: absolute;
 					bottom: 24rpx;
 					left: 232rpx;
 					width: 110rpx;
 					height: 60rpx;
-					background: rgba(0,0,0,0.8);
+					background: rgba(0, 0, 0, 0.8);
 					border-radius: 30rpx;
 					font-size: 26rpx;
 					font-family: PingFangSC, PingFang SC;
@@ -172,17 +200,19 @@
 				}
 			}
 		}
+
 		.bottom {
 			width: 750rpx;
 			height: 166rpx;
 			background: #FFFFFF;
-			box-shadow: 0rpx 0rpx 0rpx 0rpx rgba(0,0,0,0.1);
+			box-shadow: 0rpx 0rpx 0rpx 0rpx rgba(0, 0, 0, 0.1);
 			position: fixed;
 			bottom: 0;
 			left: 0;
 			box-sizing: border-box;
 			padding: 16rpx 28rpx 62rpx;
-			border-top: 1px solid rgba(0,0,0,0.1);
+			border-top: 1px solid rgba(0, 0, 0, 0.1);
+
 			.btn1 {
 				width: 340rpx;
 				height: 88rpx;
@@ -196,6 +226,7 @@
 				text-align: center;
 				margin-right: 14rpx;
 			}
+
 			.btn2 {
 				width: 340rpx;
 				height: 88rpx;
@@ -210,5 +241,4 @@
 			}
 		}
 	}
-	
-</style>
+</style>

+ 12 - 7
pageA/search.vue

@@ -59,10 +59,10 @@
 									<u-cell-group :border="false">
 										<u-cell size="large" :border="false" isLink v-for="(item,index) in user_list" :key="index">
 											<view class="user hflex acenter" slot="title">
-												<image :src="item.img" mode="aspectFill"></image>
+												<image :src="item.avatar" mode="aspectFill" @click="touser(item)"></image>
 												<view class="vflex name">
-													<text>{{item.name}}</text>
-													<text>{{item.intro}}</text>
+													<text>{{item.username}}</text>
+													<text>{{item.introduction}}</text>
 												</view>
 											</view>
 										</u-cell>
@@ -121,10 +121,10 @@
 							<u-cell-group :border="false">
 								<u-cell size="large" :border="false" isLink v-for="(item,index) in list" :key="index">
 									<view class="user hflex acenter" slot="title">
-										<image :src="item.img" mode="aspectFill"></image>
+										<image :src="item.avatar" mode="aspectFill" @click="touser(item)"></image>
 										<view class="vflex name">
-											<text>{{item.name}}</text>
-											<text>{{item.intro}}</text>
+											<text>{{item.username}}</text>
+											<text>{{item.introduction}}</text>
 										</view>
 									</view>
 								</u-cell>
@@ -155,7 +155,7 @@
 				hotlist: [],
 				tabs: [
 					{
-						id: '',
+						id: 'all',
 						name: '综合'
 					},
 					{
@@ -210,6 +210,11 @@
 			}
 		},
 		methods: {
+			touser(item) {
+				uni.navigateTo({
+					url: '/pageC/otherInfo?id=' + item.id
+				})
+			},
 			tosearch() {
 				var _this = this
 				_this.show = false

+ 35 - 45
pageA/shoucang-list.vue

@@ -1,11 +1,11 @@
 <template>
 	<view class="content">
 		<view class="list-item hflex acenter" v-for="(item,index) in list" :key="index">
-			<image :src="item.img" mode="aspectFill"></image>
+			<image :src="item.image" mode="aspectFill"></image>
 			<view class="img-right">
 				<view class="hflex acenter jbetween right-top">
-					<text>{{item.name}}</text>
-					<text>{{item.time}}</text>
+					<text>{{item.title}}</text>
+					<text>{{item.created_at}}</text>
 				</view>
 				<view class="text">{{item.content}}</view>
 			</view>
@@ -18,61 +18,44 @@
 	export default {
 		data() {
 			return {
-				list: []
+				list: [],
+				last_page: 1,
+				page: 1
 			}
 		},
 		onLoad() {
 			this.getlist()
 		},
 		onShow() {
-			
+
 		},
 		onPullDownRefresh() {
-			
+
 		},
 		onReachBottom() {
-			
+			if (this.last_page == this.page) {
+				uni.$u.toast('已经到底了')
+				return
+			} else {
+				this.page++
+				this.getlist()
+			}
 		},
 		methods: {
 			getlist() {
-				this.list = [
-					{
-						img: 'https://dummyimage.com/279x155/e3e3e3/fff',
-						name: '爱思考的大黄猫',
-						content: `收藏了你的文章“文章标题显示文章标题显示文…”`,
-						time: '1小时前'
-					},
-					{
-						img: 'https://dummyimage.com/279x155/e3e3e3/fff',
-						name: '爱思考的大黄猫',
-						content: `收藏了你的文章“文章标题显示文章标题显示文…”`,
-						time: '1小时前'
-					},
-					{
-						img: 'https://dummyimage.com/279x155/e3e3e3/fff',
-						name: '爱思考的大黄猫',
-						content: `收藏了你的文章“文章标题显示文章标题显示文…”`,
-						time: '1小时前'
-					},
-					{
-						img: 'https://dummyimage.com/279x155/e3e3e3/fff',
-						name: '爱思考的大黄猫',
-						content: `收藏了你的文章“文章标题显示文章标题显示文…”`,
-						time: '1小时前'
-					},
-					{
-						img: 'https://dummyimage.com/279x155/e3e3e3/fff',
-						name: '爱思考的大黄猫',
-						content: `收藏了你的文章“文章标题显示文章标题显示文…”`,
-						time: '1小时前'
-					},
-					{
-						img: 'https://dummyimage.com/279x155/e3e3e3/fff',
-						name: '爱思考的大黄猫',
-						content: `收藏了你的文章“文章标题显示文章标题显示文…”`,
-						time: '1小时前'
+				var that = this
+				$api.req({
+					url: 'notification',
+					data: {
+						is_page: 1,
+						page: that.page,
+						limit: 10,
+						type: 'collect'
 					}
-				]
+				}, function(res) {
+					that.list = that.list.concat(res.data.list)
+					that.last_page = res.data.last_page
+				})
 			},
 		}
 	}
@@ -82,25 +65,31 @@
 	.content {
 		background-color: #FFFFFF;
 		padding: 0 28rpx;
+
 		.list-item {
 			padding: 28rpx 0 32rpx;
 			border-bottom: 1px solid #F5F5F5;
+
 			image {
 				width: 92rpx;
 				height: 92rpx;
 				border-radius: 50%;
 			}
+
 			.img-right {
 				width: calc(100% - 92rpx);
 				padding: 0 0 0 20rpx;
+
 				.right-top {
 					width: 100%;
+
 					text:first-child {
 						font-size: 32rpx;
 						font-family: PingFangSC, PingFang SC;
 						font-weight: 600;
 						color: #333333;
 					}
+
 					text:last-child {
 						font-size: 22rpx;
 						font-family: PingFangSC, PingFang SC;
@@ -108,6 +97,7 @@
 						color: #999999;
 					}
 				}
+
 				.text {
 					font-size: 24rpx;
 					font-family: PingFangSC, PingFang SC;
@@ -118,4 +108,4 @@
 			}
 		}
 	}
-</style>
+</style>

+ 41 - 13
pageB/components/addressbox.vue

@@ -6,8 +6,8 @@
 			<image src="../static/close.png" mode="aspectFill" @click="close"></image>
 		</view>
 		<view class="list vflex">
-			<u-radio-group  placement="column" @change="selectaddress">
-				<view class="list-item hflex acenter jbetween" v-for="(item,index) in list" :key="index" @click="select(index)">
+			<u-radio-group placement="column" @change="selectaddress">
+				<view class="list-item hflex acenter jbetween" v-for="(item,index) in list" :key="index">
 					<view class="hflex acenter jcenter">
 						<u-radio shape="circle" :name="index" activeColor="#00B0B0"></u-radio>
 						<view class="left vflex">
@@ -16,16 +16,19 @@
 								<text>{{item.name}}</text>
 								<text class="mobile">{{item.mobile}}</text>
 								<view class="default" v-if="item.is_default == 1">默认</view>
-							</view> 
+							</view>
 						</view>
 					</view>
 					<image src="../static/edit.png" mode="aspectFill" @click="edit(item)"></image>
-				</view>	
+				</view>
 			</u-radio-group>
-		</view>	
-		<view class="btns" @click="toadd">
+		</view>
+		<view class="btns" @click="toadd" v-if="active == -1">
 			新增收货地址
 		</view>
+		<view class="btns" @click="sure" v-else>
+			确定
+		</view>
 	</view>
 </template>
 
@@ -36,30 +39,42 @@
 			list: {
 				typeof: Array,
 				default: []
+			},
+			index: {
+				typeof: Number,
+				default: -1
 			}
 		},
 		data() {
 			return {
+				active: this.default
 			}
 		},
 		onLoad() {
 			// this.getlist()
 		},
 		onShow() {
-			
+
 		},
 		onPullDownRefresh() {
-			
+
 		},
 		onReachBottom() {
-			
+
 		},
 		methods: {
+			edit(item) {
+				uni.navigateTo({
+					url: '/pageC/address-add?id=' + item.id
+				})
+			},
 			selectaddress(e) {
-				this.$emit('select',e)
+				console.log('w', e);
+				this.active = e
 			},
-			select(index) {
-				this.$emit('select',index)
+			sure() {
+				console.log(this.active);
+				this.$emit('select', this.active)
 			},
 			toadd() {
 				uni.navigateTo({
@@ -82,6 +97,7 @@
 		border-radius: 28rpx 26rpx 0rpx 0rpx;
 		padding: 36rpx 28rpx;
 		position: relative;
+
 		.btns {
 			position: fixed;
 			bottom: 44rpx;
@@ -97,28 +113,35 @@
 			color: #FFFFFF;
 			line-height: 84rpx;
 		}
+
 		.list {
 			padding: 0 0 144rpx;
+
 			.list-item {
 				padding: 32rpx 0 28rpx;
 				border-bottom: 1px solid #F1F7FE;
+
 				.left {
 					max-width: 578rpx;
 					padding: 0 52rpx 0 20rpx;
+
 					.address2 {
 						font-size: 30rpx;
 						font-family: PingFangSC, PingFang SC;
 						font-weight: 600;
 						color: #222222;
 					}
+
 					.item-bottom {
 						padding: 14rpx 0 0;
+
 						text:first-child {
 							font-size: 24rpx;
 							font-family: PingFangSC, PingFang SC;
 							font-weight: 400;
 							color: #666666;
 						}
+
 						.mobile {
 							font-size: 24rpx;
 							font-family: JDZhengHT, JDZhengHT;
@@ -126,6 +149,7 @@
 							color: #666666;
 							padding: 0 16rpx 0 28rpx
 						}
+
 						.default {
 							background: #57C3C2;
 							border-radius: 4rpx;
@@ -137,24 +161,28 @@
 						}
 					}
 				}
+
 				image {
 					width: 28rpx;
 					height: 28rpx;
 				}
 			}
 		}
+
 		.top {
 			padding: 0 0 28rpx;
+
 			.title {
 				font-size: 32rpx;
 				font-family: PingFangSC, PingFang SC;
 				font-weight: 500;
 				color: #333333;
 			}
+
 			image {
 				width: 44rpx;
 				height: 44rpx;
 			}
 		}
 	}
-</style>
+</style>

+ 6 - 2
pageB/components/time-box.vue

@@ -55,10 +55,13 @@
 </script>
 
 <style lang="scss">
-	.time-box {
+	.time-box::v-deep {
 		background: #FFFFFF;
 		border-radius: 28rpx 28rpx 0rpx 0rpx;
 		padding: 0 28rpx 86rpx;
+		.uni-picker-view-content {
+			padding-bottom: 0 !important;
+		}
 		.list{
 			.picker-view {
 				width: 100%;
@@ -71,7 +74,8 @@
 			}
 		}
 		.bottom {
-			// margin: 50rpx 0 0;
+			margin: 50rpx 0 0;
+			z-index: 999;
 			.btn1 {
 				width: 276rpx;
 				height: 80rpx;

+ 47 - 17
pageB/components/youhui.vue

@@ -5,26 +5,29 @@
 			<view class="title">优惠券</view>
 			<image src="../static/close.png" mode="aspectFill" @click="close"></image>
 		</view>
-		<view class="list vflex">
+		<scroll-view :scroll-y="true" class="list vflex">
 			<u-radio-group v-model="active" placement="column" @change="selectaddress">
-				<view class="list-item hflex acenter jbetween" :class="active == index ? 'active-item' : ''" v-for="(item,index) in list" :key="index" @click="select(index)">
-					<image src="../static/youhuiquan.png" mode="aspectFill"></image>
+				<view class="list-item hflex acenter jbetween" :class="active == index ? 'active-item' : ''"
+					v-for="(item,index) in list" :key="index" @click="select(index)">
+					<image :src="item.coupon.image" mode="aspectFill"></image>
 					<view class="left vflex jbetween">
-						<text>{{item.title}}</text>
-						<text>{{item.intro}}</text>
+						<text class="text_hide">{{item.coupon.name}}</text>
+						<text class="text_hide" v-if="item.coupon.description">{{item.coupon.description}}</text>
 					</view>
 					<u-radio shape="circle" :name="index" activeColor="#00B0B0"></u-radio>
-				</view>	
-				<view class="list-item hflex acenter jbetween" :class="active == 0 ? 'active-item' : ''" @click="select('0')" v-if="type == 'vip'">
+				</view>
+				<view class="list-item hflex acenter jbetween" :class="active == 0 ? 'active-item' : ''"
+					@click="select('0')" v-if="type == 'vip' && user.is_vip == 1">
 					<view class="name">使用</view>
 					<u-radio shape="circle" :name="0" activeColor="#00B0B0"></u-radio>
 				</view>
-				<view class="list-item hflex acenter jbetween" :class="active == -1 ? 'active-item' : ''" @click="select('-1')">
+				<view class="list-item hflex acenter jbetween" :class="active == -1 ? 'active-item' : ''"
+					@click="select('-1')">
 					<view class="name">不使用</view>
 					<u-radio shape="circle" :name="-1" activeColor="#00B0B0"></u-radio>
 				</view>
 			</u-radio-group>
-		</view>
+		</scroll-view>
 		<view class="btns" @click="sure">
 			确定
 		</view>
@@ -51,22 +54,36 @@
 		data() {
 			return {
 				active: this.index,
+				user: {},
 			}
 		},
-		
+		mounted() {
+			this.getuser()
+		},
 		onLoad() {
-			
+
 		},
 		onShow() {
-			
+
 		},
 		onPullDownRefresh() {
-			
+
 		},
 		onReachBottom() {
-			
+
 		},
 		methods: {
+			getuser() {
+				var _this = this
+				$api.req({
+					url: 'user/info',
+					method: 'GET'
+				}, function(res) {
+					if (res.code == 10000) {
+						_this.user = res.data
+					}
+				})
+			},
 			selectaddress(e) {
 				this.active = e
 			},
@@ -74,7 +91,7 @@
 				this.active = index
 			},
 			sure() {
-				this.$emit('select',this.active)
+				this.$emit('select', this.active)
 			},
 			close() {
 				this.$emit('close')
@@ -91,6 +108,7 @@
 		border-radius: 28rpx 26rpx 0rpx 0rpx;
 		padding: 36rpx 28rpx;
 		position: relative;
+
 		.btns {
 			position: fixed;
 			bottom: 44rpx;
@@ -106,32 +124,40 @@
 			color: #FFFFFF;
 			line-height: 84rpx;
 		}
+
 		.list {
+			max-height: 500rpx;
 			padding: 0 0 144rpx;
+
 			.active-item {
-				background: rgba(0,176,176,0.06) !important;
+				background: rgba(0, 176, 176, 0.06) !important;
 			}
+
 			.list-item {
 				padding: 32rpx 30rpx 28rpx;
 				border-bottom: 1px solid #F1F7FE;
 				background: #F8F8F8;
 				border-radius: 16rpx;
 				margin: 0 0 20rpx;
+
 				.name {
 					font-size: 32rpx;
 					font-family: PingFangSC, PingFang SC;
 					font-weight: 500;
 					color: #222222;
 				}
+
 				.left {
 					width: 450rpx;
 					padding: 0 52rpx 0 20rpx;
+
 					text:first-child {
 						font-size: 32rpx;
 						font-family: PingFangSC, PingFang SC;
 						font-weight: 600;
 						color: #222222;
 					}
+
 					text:last-child {
 						font-size: 24rpx;
 						font-family: PingFangSC, PingFang SC;
@@ -140,6 +166,7 @@
 						padding: 14rpx 0 0;
 					}
 				}
+
 				image {
 					width: 104rpx;
 					height: 104rpx;
@@ -147,18 +174,21 @@
 				}
 			}
 		}
+
 		.top {
 			padding: 0 0 28rpx;
+
 			.title {
 				font-size: 32rpx;
 				font-family: PingFangSC, PingFang SC;
 				font-weight: 500;
 				color: #333333;
 			}
+
 			image {
 				width: 44rpx;
 				height: 44rpx;
 			}
 		}
 	}
-</style>
+</style>

+ 53 - 20
pageB/good-detail.vue

@@ -1,8 +1,10 @@
 <template>
 	<view class="good-detail">
-		<u-swiper :list="detail.images" @change="e => currentNum = e.current" height="375" :autoplay="false" indicatorStyle="right: 20px">
+		<u-swiper :list="detail.images" @change="e => currentNum = e.current" height="375" :autoplay="false"
+			indicatorStyle="right: 20px">
 			<view slot="indicator" class="indicator-num">
-				<text class="indicator-num__text hflex acenter jcenter">{{ currentNum + 1 }}/{{ detail.images.length || 0 }}</text>
+				<text
+					class="indicator-num__text hflex acenter jcenter">{{ currentNum + 1 }}/{{ detail.images.length || 0 }}</text>
 			</view>
 		</u-swiper>
 		<view class="detail">
@@ -15,7 +17,7 @@
 			<view class="box hflex acenter jbetween" @click="spec_show = true">
 				<view class="label">选择</view>
 				<view class="text" v-if="active != -1">已选:{{detail.speclist[active].name}}</view>
-				<view class="text" v-else>请先选择规格</view>
+				<view class="text" v-else>请先选择数量</view>
 				<u-icon name="arrow-right" color="#000" size="20"></u-icon>
 			</view>
 			<u-parse :content="detail.detail"></u-parse>
@@ -34,17 +36,18 @@
 					<image :src="detail.image" mode="aspectFill"></image>
 					<view class="vflex jbetween top-center">
 						<view class="spec-price">{{detail.price}}<text>积分</text></view>
-						<view class="spec-text" v-if="active != -1">已选择:“{{detail.speclist[active].name}}”</view>
-						<view class="spec-text" v-else>请选择规格</view>
+						<!-- <view class="spec-text" v-if="active != -1">已选择:“{{detail.speclist[active].name}}”</view>
+						<view class="spec-text" v-else>请选择规格</view> -->
 					</view>
 					<image src="static/close.png" mode="aspectFill" @click="toclose"></image>
 				</view>
-				<view class="spec-list hflex acenter fwrap">
+				<!-- <view class="spec-list hflex acenter fwrap">
 					<view class="spec-title">类型</view>
-					<view class="spec-item" :class="active == index ? 'item-active' : ''" v-for="(item,index) in detail.speclist" :key="index" @click="select(index)">
+					<view class="spec-item" :class="active == index ? 'item-active' : ''"
+						v-for="(item,index) in detail.speclist" :key="index" @click="select(index)">
 						<text>{{item.name}}</text>
 					</view>
-				</view>
+				</view> -->
 				<view class="spec-num hflex acenter jbetween">
 					<view class="spec-title">数量</view>
 					<u-number-box v-model="num" :integer="true">
@@ -86,10 +89,10 @@
 			tocollect() {
 				var _this = this
 				$api.req({
-					url: 'integral/goods/'+ _this.id + '/collect',
+					url: 'integral/goods/' + _this.id + '/collect',
 					method: 'POST',
 				}, function(res) {
-					if(res.code == 10000) {
+					if (res.code == 10000) {
 						uni.$u.toast(res.msg)
 						_this.detail.is_collect = !_this.detail.is_collect
 					} else {
@@ -103,13 +106,14 @@
 					return
 				} */
 				uni.navigateTo({
-					url: '/pageB/order-confirm?good=' + JSON.stringify(this.detail) + '&num=' + this.num
+					url: '/pageB/order-confirm?good=' + encodeURIComponent(JSON.stringify(this.detail)) +
+						'&num=' + this.num
 				})
 			},
 			/* 点击确定 */
 			sure() {
 				this.spec_show = false
-				
+
 			},
 			/* 选择规格 */
 			select(index) {
@@ -126,17 +130,17 @@
 					url: 'integral/goods/' + this.id,
 					method: 'GET',
 				}, function(res) {
-					if(res.code == 10000) {
+					if (res.code == 10000) {
 						_this.detail = res.data
-						for(var i=0;i<_this.detail.images.length;i++) {
-							if(_this.detail.images[i].indexOf('http') == -1) {
+						for (var i = 0; i < _this.detail.images.length; i++) {
+							if (_this.detail.images[i].indexOf('http') == -1) {
 								_this.detail.images[i] = $api.config.baseUrl + _this.detail.images[i]
 							}
 						}
 						console.log(JSON.parse(JSON.stringify(_this.detail)));
 					}
 				})
-				
+
 			},
 		}
 	}
@@ -145,6 +149,7 @@
 <style lang="scss">
 	.good-detail {
 		min-height: 100vh;
+
 		.spec-popu {
 			background: #FFFFFF;
 			border-radius: 32rpx 32rpx 0rpx 0rpx;
@@ -152,25 +157,30 @@
 			padding: 40rpx 28rpx;
 			max-height: 65vh;
 			overflow: auto;
+
 			.spec-top {
 				image:first-child {
 					width: 180rpx;
 					height: 180rpx;
 				}
+
 				.top-center {
 					padding-left: 20rpx;
 					width: 450rpx;
 					height: 180rpx;
+
 					.spec-price {
 						font-size: 40rpx;
 						font-family: SFPro, SFPro;
 						font-weight: 600;
 						color: #FF4954;
+
 						text {
 							font-size: 26rpx;
 							font-weight: 500;
 						}
 					}
+
 					.spec-text {
 						font-size: 26rpx;
 						font-family: PingFangSC, PingFang SC;
@@ -178,15 +188,17 @@
 						color: #222222;
 					}
 				}
-				
+
 				image:last-child {
 					width: 36rpx;
 					height: 36rpx;
 				}
 			}
+
 			.spec-list {
 				padding: 28rpx 0 96rpx;
 				border-bottom: 2rpx solid #F2F2F2;
+
 				.spec-title {
 					width: 100%;
 					font-size: 28rpx;
@@ -194,12 +206,14 @@
 					font-weight: 400;
 					color: #222222;
 				}
+
 				.spec-item {
 					margin: 24rpx 30rpx 0 0;
 					background: #F3F3F3;
 					border-radius: 30rpx;
 					box-sizing: border-box;
 					padding: 12rpx 55rpx;
+
 					text {
 						font-size: 24rpx;
 						font-family: SFPro, SFPro;
@@ -207,22 +221,27 @@
 						color: #222222;
 					}
 				}
+
 				.item-active {
-					background: rgba(0,176,176,0.06);
+					background: rgba(0, 176, 176, 0.06);
 					border: 2rpx solid #00B0B0;
+
 					text {
 						color: #00B0B0;
 					}
 				}
 			}
+
 			.spec-num {
 				padding: 38rpx 0;
+
 				.spec-title {
 					font-size: 28rpx;
 					font-family: PingFangSC, PingFang SC;
 					font-weight: 400;
 					color: #222222;
 				}
+
 				.minus {
 					width: 40rpx;
 					height: 40rpx;
@@ -234,19 +253,22 @@
 					@include flex;
 					justify-content: center;
 					align-items: center;
-					
+
 				}
+
 				.minus2 {
 					background: #ebebeb;
 					border-color: #ebebeb;
 				}
+
 				input {
 					width: 50rpx;
 					text-align: center;
 					padding: 0 10px;
 				}
-				
+
 			}
+
 			.spec-btn {
 				width: 702rpx;
 				height: 80rpx;
@@ -260,6 +282,7 @@
 				line-height: 80rpx;
 			}
 		}
+
 		.bottom {
 			position: fixed;
 			bottom: 0;
@@ -269,6 +292,7 @@
 			background: #FFFFFF;
 			box-sizing: border-box;
 			padding: 16rpx 24rpx 66rpx;
+
 			.collect {
 				text {
 					font-size: 20rpx;
@@ -277,6 +301,7 @@
 					padding: 6rpx 0 0;
 				}
 			}
+
 			.btn {
 				width: 620rpx;
 				height: 84rpx;
@@ -290,27 +315,32 @@
 				text-align: center;
 			}
 		}
+
 		.detail {
 			min-height: calc(100vh - 750rpx);
 			background: #F5F5F5;
 			box-sizing: border-box;
 			padding: 20rpx 24rpx 0;
+
 			.box {
 				background: #FFFFFF;
 				border-radius: 20rpx;
 				margin: 0 0 20rpx;
 				padding: 24rpx 20rpx;
 				box-sizing: border-box;
+
 				.price {
 					font-size: 44rpx;
 					font-family: SFPro, SFPro;
 					font-weight: 600;
 					color: #FF4954;
+
 					text {
 						font-size: 28rpx;
 						font-weight: 500;
 					}
 				}
+
 				.name {
 					font-size: 32rpx;
 					font-family: SFPro, SFPro;
@@ -318,6 +348,7 @@
 					color: #222222;
 					padding: 16rpx 0 0;
 				}
+
 				.label {
 					font-size: 26rpx;
 					font-family: PingFangSC, PingFang SC;
@@ -325,6 +356,7 @@
 					color: #666666;
 					padding-right: 20rpx;
 				}
+
 				.text {
 					font-size: 28rpx;
 					font-family: SFPro, SFPro;
@@ -334,6 +366,7 @@
 				}
 			}
 		}
+
 		.indicator-num__text {
 			width: 80rpx;
 			height: 40rpx;

+ 94 - 25
pageB/order-confirm.vue

@@ -15,7 +15,7 @@
 				<image :src="detail.image" mode="aspectFill"></image>
 				<view class="vflex center jbetween">
 					<view class="name text_hide2">{{detail.name}}</view>
-					<view class="spec">{{detail.spec}}</view>
+					<view class="spec" v-if="detail.spec">{{detail.spec}}</view>
 				</view>
 				<view class="right vflex aend">
 					<view class="price">{{detail.price}}积分</view>
@@ -25,7 +25,7 @@
 			<view class="cell hflex acenter jbetween">
 				<view class="label">优惠券</view>
 				<view class="hflex acenter" @click="show_youhui = true">
-					<view class="value">{{youhui_active == -1 ? '不使用' : youhui_list[youhui_active].tiaojian}}</view>
+					<view class="value">{{youhui_active == -1 ? '不使用' : youhui_list[youhui_active].coupon.name}}</view>
 					<image src="static/down.png" mode="aspectFill"></image>
 				</view>
 			</view>
@@ -65,7 +65,7 @@
 			<view class="btn" @click="submit">提交订单</view>
 		</view>
 		<u-popup :show="show_address" @close="toclose" mode="bottom" :round="13">
-			<addressBox :list="address_list" @close="toclose" @select="selectAddress"></addressBox>
+			<addressBox :index="select_address" :list="address_list" @close="toclose" @select="selectAddress"></addressBox>
 		</u-popup>
 		<u-popup :show="show_youhui" @close="toclose" mode="bottom" :round="13">
 			<youhui :index="youhui_active" :list="youhui_list" @close="toclose" @select="selectyouhui"></youhui>
@@ -116,21 +116,51 @@
 				remarks: '',
 				show_submit: false,
 				show_wx: false,
-				wxcode: 'https://dummyimage.com/750x750/e3e3e3/fff',
+				wxcode: '',
 				num: 1,
 				total: 0,
-				youhui: 0
+				youhui: 0,
+				order: {},
+				select_address: -1,
 			}
 		},
 		onLoad(options) {
-			this.detail = JSON.parse(options.good)
-			console.log(this.detail)
+			this.detail = JSON.parse(decodeURIComponent(options.good))
 			this.num = options.num
-			console.log(this.num);
+			// this.getlist()
+			// this.getcode()
+			this.getyouhui()
+		},
+		onShow() {
 			this.getlist()
-			// this.getdata()
 		},
 		methods: {
+			getyouhui() {
+				var that = this
+				$api.req({
+					url: 'user/coupon',
+					data: {
+						is_page: 0,
+						is_expire: 0,
+						is_use: 0,
+						type: 'integral',
+						goods_id: that.detail.id
+					}
+				}, function(res) {
+					that.youhui_list = res.data
+				})
+			},
+			getwxcode() {
+				var that = this
+				$api.req({
+					url: 'config',
+					data: {
+						module: 'basic'
+					}
+				}, function(res) {
+					that.wxcode = res.data.customer_service_qrcode
+				})
+			},
 			count() {
 				var _this = this
 				$api.req({
@@ -144,28 +174,28 @@
 						address_id: _this.address ? _this.address.id : '0'
 					}
 				}, function(res) {
-					if(res.code == 10000) {
-						_this.total = res.data.price_data.total_price
-						_this.youhui = res.data.price_data.total_discount
+					if (res.code == 10000) {
+						_this.total = res.data.price_data.pay_price
+						_this.youhui = res.data.price_data.coupon_discount
 					}
 				})
 			},
 			tosubmit() {
 				this.toclose()
 				uni.redirectTo({
-					url: '/pageB/order-detail'
+					url: '/pageB/order-detail?id=' + this.order.id
 				})
 			},
 			submit() {
 				var _this = this
-				if(JSON.stringify(this.address) == '{}') {
+				if (JSON.stringify(this.address) == '{}') {
 					$api.info('请先选择收货地址')
 					return
 				}
 				uni.showModal({
 					title: '',
 					content: '是否提交订单',
-					success: function (res) {
+					success: function(res) {
 						if (res.confirm) {
 							$api.req({
 								url: 'integral/order',
@@ -173,34 +203,39 @@
 								data: {
 									goods_id: _this.detail.id,
 									goods_count: _this.num,
-									coupon_id: _this.youhui_active == -1 ? '0' : _this.youhui_list[_this.youhui_active].id,
+									coupon_id: _this.youhui_active == -1 ? '0' : _this.youhui_list[
+										_this.youhui_active].id,
 									is_level_discount: _this.vip_active == -1 ? '0' : '1',
 									address_id: _this.address ? _this.address.id : '0'
 								}
 							}, function(res) {
-								if(res.code == 10000) {
+								if (res.code == 10000) {
 									_this.show_submit = true
+									_this.order = res.data
+									_this.getwxcode()
 								}
 							})
-							
+
 						}
 					}
 				});
 			},
+
 			selectyouhui(e) {
 				this.youhui_active = e
 				this.count()
 				this.toclose()
-			}, 
+			},
 			selectvip(e) {
 				this.vip_active = e
 				this.count()
 				this.toclose()
-			}, 
+			},
 			getdata() {
-				
+
 			},
 			selectAddress(e) {
+				this.select_address = e
 				this.address = this.address_list[e]
 				this.toclose()
 			},
@@ -220,9 +255,9 @@
 						is_page: 0
 					}
 				}, function(res) {
-					if(res.code == 10000) {
+					if (res.code == 10000) {
 						_this.address_list = res.data
-						if(_this.address_list.length > 0) {
+						if (_this.address_list.length > 0) {
 							_this.address = _this.address_list[0]
 						}
 					}
@@ -239,12 +274,14 @@
 		padding: 20rpx 24rpx;
 		box-sizing: border-box;
 		min-height: 100vh;
-		
+
 		.popu1 {
 			width: 510rpx;
 			padding: 46rpx 0;
+
 			.top {
 				width: 100%;
+
 				.top-title {
 					font-size: 32rpx;
 					font-family: PingFangSC, PingFang SC;
@@ -253,16 +290,19 @@
 					text-align: center;
 					padding-left: 100rpx;
 				}
+
 				image {
 					width: 36rpx;
 					height: 36rpx;
 				}
 			}
+
 			.center {
 				image {
 					width: 310rpx;
 					height: 310rpx;
 				}
+
 				text {
 					font-size: 22rpx;
 					font-family: PingFangSC, PingFang SC;
@@ -270,17 +310,20 @@
 					color: rgba(0, 0, 0, .42);
 				}
 			}
+
 			image {
 				width: 78rpx;
 				height: 78rpx;
 				margin: 12rpx 36rpx;
 			}
+
 			.success {
 				font-size: 30rpx;
 				font-family: PingFangSC, PingFang SC;
 				font-weight: 400;
 				color: #000000;
 			}
+
 			.success-text {
 				font-size: 24rpx;
 				font-family: PingFangSC, PingFang SC;
@@ -288,6 +331,7 @@
 				color: rgba(0, 0, 0, .6);
 				padding: 8rpx 0 42rpx;
 			}
+
 			.btns {
 				.btn1 {
 					width: 204rpx;
@@ -301,6 +345,7 @@
 					line-height: 72rpx;
 					text-align: center;
 				}
+
 				.btn2 {
 					width: 204rpx;
 					height: 72rpx;
@@ -316,6 +361,7 @@
 				}
 			}
 		}
+
 		.bottom {
 			position: fixed;
 			bottom: 0;
@@ -325,11 +371,13 @@
 			background: #FFFFFF;
 			box-sizing: border-box;
 			padding: 12rpx 28rpx 68rpx;
+
 			.money {
 				font-size: 24rpx;
 				font-family: PingFangSC, PingFang SC;
 				font-weight: 400;
 				color: #222222;
+
 				.money-text {
 					font-size: 40rpx;
 					font-family: SFPro, SFPro;
@@ -338,6 +386,7 @@
 					padding: 0 20rpx 0 12rpx;
 				}
 			}
+
 			.btn {
 				width: 232rpx;
 				height: 86rpx;
@@ -351,25 +400,30 @@
 				text-align: center;
 			}
 		}
+
 		.box {
 			background: #FFFFFF;
 			border-radius: 16rpx;
 			margin: 0 0 20rpx;
 			padding: 28rpx 20rpx 0;
+
 			.cell {
 				padding: 0 0 36rpx;
+
 				.label {
 					font-size: 28rpx;
 					font-family: PingFangSC, PingFang SC;
 					font-weight: 400;
 					color: #222222;
 				}
+
 				.value {
 					font-size: 28rpx;
 					font-family: PingFangSC, PingFang SC;
 					font-weight: 400;
 					color: #333333;
 				}
+
 				image {
 					width: 28rpx;
 					height: 28rpx;
@@ -377,9 +431,11 @@
 				}
 			}
 		}
+
 		.good {
 			padding: 24rpx 20rpx;
 			box-sizing: border-box;
+
 			.title {
 				font-size: 32rpx;
 				font-family: PingFangSC, PingFang SC;
@@ -387,8 +443,10 @@
 				color: #222222;
 				padding: 0 0 26rpx;
 			}
+
 			.good-detail {
 				padding: 0 0 40rpx;
+
 				.right {
 					.price {
 						font-size: 28rpx;
@@ -396,6 +454,7 @@
 						font-weight: 500;
 						color: #FF4954;
 					}
+
 					.num {
 						font-size: 24rpx;
 						font-family: SFPro, SFPro;
@@ -404,19 +463,23 @@
 						padding: 18rpx 0 0;
 					}
 				}
+
 				image {
 					width: 160rpx;
 					height: 160rpx;
 					margin: 0 20rpx 0 0;
 				}
+
 				.center {
 					width: 330rpx;
+
 					.name {
 						font-size: 28rpx;
 						font-family: PingFangSC, PingFang SC;
 						font-weight: 400;
 						color: #222222;
 					}
+
 					.spec {
 						max-width: max-content;
 						background: #F3F3F3;
@@ -431,31 +494,37 @@
 				}
 			}
 		}
+
 		.address {
 			padding: 28rpx;
 			width: 100%;
 			box-sizing: border-box;
+
 			image {
 				width: 32rpx;
 				height: 32rpx;
 				margin: 0 16rpx 0 0;
 			}
+
 			.address-box {
 				width: 550rpx;
+
 				text:first-child {
 					font-size: 30rpx;
 					font-family: PingFangSC, PingFang SC;
 					font-weight: 600;
 					color: #222222;
 				}
+
 				text:last-child {
 					font-size: 24rpx;
 					font-family: JDZhengHT, JDZhengHT;
 					font-weight: 300;
 					color: #666666;
-					padding: 10rpx 0 0 ;
+					padding: 10rpx 0 0;
 				}
 			}
+
 			.address-text {
 				width: 550rpx;
 				font-size: 28rpx;

+ 75 - 53
pageB/order-detail.vue

@@ -1,53 +1,62 @@
 <template>
 	<view class="content">
 		<view class="top vflex acenter jcenter">
-			<text v-if="type == '1'">已提交,请添加客服</text>
-			<text v-else>兑换成功</text>
-			<text v-if="type == '1'">已兑换请与客服沟通</text>
-			<text v-else>恭喜您成功兑换商品</text>
+			<text v-if="detail.status == 'applied'">已提交,请添加客服</text>
+			<text v-if="detail.status == 'passed'">兑换成功</text>
+			<text v-if="detail.status == 'applied'">已兑换请与客服沟通</text>
+			<text v-if="detail.status == 'passed'">恭喜您成功兑换商品</text>
 		</view>
 		<view class="box address vflex">
-			<text>{{detail.address.province}}{{detail.address.city}}{{detail.address.area}}{{detail.address.address}}</text>
-			<text>{{detail.address.name}} {{detail.address.mobile}}</text>
+			<text>{{detail.province_name}}{{detail.city_name}}{{detail.district_name}}{{detail.address}}</text>
+			<text>{{detail.name}} {{detail.mobile}}</text>
 		</view>
 		<view class="box good">
 			<view class="hflex good-detail">
-				<image :src="detail.img" mode="aspectFill"></image>
+				<image :src="detail.goods.image" mode="aspectFill"></image>
 				<view class="vflex center jbetween">
-					<view class="name text_hide2">{{detail.name}}</view>
-					<view class="spec">{{detail.spec}}</view>
+					<view class="name text_hide2">{{detail.goods.name}}</view>
+					<!-- <view class="spec">{{detail.goods.spec}}</view> -->
 				</view>
 				<view class="right vflex aend">
-					<view class="price">{{detail.price}}积分</view>
-					<view class="num">X{{detail.num}}</view>
+					<view class="price">{{detail.goods.price}}积分</view>
+					<!-- <view class="num">X{{detail.goods.num}}</view> -->
 				</view>
 			</view>
 			<view class="cell hflex acenter jbetween">
 				<view class="label">商品积分</view>
-				<view class="value">{{detail.price}}</view>
+				<view class="value">{{detail.goods.price}}</view>
 			</view>
 			<view class="cell hflex acenter jbetween">
 				<view class="label">运费</view>
 				<view class="value">免邮</view>
 			</view>
 			<view class="cell hflex acenter jbetween">
+				<view class="label">优惠券</view>
+				<view class="value text_hide">{{detail.coupon_name || '-'}}</view>
+			</view>
+			<view class="cell hflex acenter jbetween">
+				<view class="label">优惠积分</view>
+				<view class="value" style="color: #EE5850;">{{detail.coupon_discount_amount || 0}}</view>
+			</view>
+			<view class="cell hflex acenter jbetween">
 				<view class="label">实付积分</view>
-				<view class="value" style="color: #EE5850;">{{detail.pay}}</view>
+				<view class="value" style="color: #EE5850;">{{detail.pay_amount}}</view>
 			</view>
 			<view class="cell hflex acenter jbetween" style="border-top: 1px solid #F1F8FE; padding-top: 30rpx;">
 				<view class="label">订单编号</view>
-				<view class="value">{{detail.order}} | <span style="padding-left: 10rpx;" @click="copy(detail.order)">复制</span></view>
+				<view class="value">{{detail.order_no}} | <span style="padding-left: 10rpx;"
+						@click="copy(detail.order)">复制</span></view>
 			</view>
 			<view class="cell hflex acenter jbetween">
 				<view class="label">下单时间</view>
-				<view class="value">{{detail.order_time}}</view>
+				<view class="value">{{detail.created_at}}</view>
 			</view>
 			<view class="cell hflex acenter jbetween" style="padding-bottom: 0;">
 				<view class="label">兑换时间</view>
-				<view class="value">{{detail.duihuan_time}}</view>
+				<view class="value">{{detail.created_at}}</view>
 			</view>
 		</view>
-		<view class="btn hflex acenter jcenter" v-if="type == '1'" @click="show_wx = true">
+		<view class="btn hflex acenter jcenter" @click="show_wx = true">
 			<image src="static/kefu.png" mode="aspectFill"></image>
 			<text>添加客服</text>
 		</view>
@@ -60,32 +69,34 @@
 <script>
 	import $api from '@/static/js/api.js'
 	import kefuWx from './components/kefu-wx.vue'
+	var that = ''
 	export default {
 		components: {
 			kefuWx
 		},
 		data() {
 			return {
-				type: '1',
+				id: '',
 				detail: {},
-				show_wx:false,
+				show_wx: false,
 				wxcode: ''
 			}
 		},
 		onLoad(option) {
-			if(option.type) {
-				this.type = option.type
+			that = this
+			if (option.id) {
+				this.id = option.id
 			}
 			this.getdata()
 		},
 		onShow() {
-			
+
 		},
 		onPullDownRefresh() {
-			
+
 		},
 		onReachBottom() {
-			
+
 		},
 		methods: {
 			toclose() {
@@ -94,38 +105,25 @@
 			copy(val) {
 				uni.setClipboardData({
 					data: val,
-					success: function () {
+					success: function() {
 						$api.info('复制成功')
 					}
 				});
 			},
 			getdata() {
-				this.detail = {
-					address: {
-						id: 1,
-						province: '湖南省',
-						city: '湘西土家族苗族自治州',
-						area: '吉首市',
-						address: '李时珍大道503号',
-						name: '牧茜梅',
-						mobile: '19876523456',
-						is_default: 1,
-					},
-					img: 'https://dummyimage.com/750x750/e3e3e3/fff',
-					cover: 'https://dummyimage.com/750x750/e3e3e3/fff',
-					price: 13850,
-					name: 'Apple iPhone 15 Pro Max (A3108) 256GB 原色钛金属 支持移动联通电信5G 双卡双待手机',
-					is_collect: false,
-					num: 1,
-					content: ``,
-					spec: '原色钛金属+256GB',
-					total: 13825,
-					youhui: 1000,
-					pay: 12825,
-					order: '1624914624039902680',
-					order_time: '2022-07-21 18:23:12',
-					duihuan_time: '2022-07-21 18:23:12'
-				}
+				$api.req({
+					url: 'integral/order/' + that.id
+				}, function(res) {
+					that.detail = res.data
+				})
+				$api.req({
+					url: 'config',
+					data: {
+						module: 'basic'
+					}
+				}, function(res) {
+					that.wxcode = res.data.customer_service_qrcode
+				})
 			}
 		}
 	}
@@ -135,24 +133,28 @@
 	.content {
 		padding: 0 24rpx;
 		background: #f4f4f4;
+
 		.btn {
 			width: 702rpx;
 			height: 88rpx;
 			background: #00B0B0;
 			border-radius: 44rpx;
 			margin: 40rpx 0 0;
+
 			text {
 				font-size: 28rpx;
 				font-family: PingFangSC, PingFang SC;
 				font-weight: 400;
 				color: #ffffff;
 			}
+
 			image {
 				width: 48rpx;
 				height: 48rpx;
 				margin: 0 12rpx 0 0;
 			}
 		}
+
 		.box {
 			background: #FFFFFF;
 			border-radius: 20rpx;
@@ -160,9 +162,11 @@
 			box-sizing: border-box;
 			margin: 0 0 20rpx;
 		}
+
 		.good {
 			padding: 24rpx 20rpx;
 			box-sizing: border-box;
+
 			.title {
 				font-size: 32rpx;
 				font-family: PingFangSC, PingFang SC;
@@ -170,8 +174,10 @@
 				color: #222222;
 				padding: 0 0 26rpx;
 			}
+
 			.good-detail {
 				padding: 0 0 40rpx;
+
 				.right {
 					.price {
 						font-size: 28rpx;
@@ -179,6 +185,7 @@
 						font-weight: 500;
 						color: #222222;
 					}
+
 					.num {
 						font-size: 24rpx;
 						font-family: SFPro, SFPro;
@@ -187,44 +194,54 @@
 						padding: 18rpx 0 0;
 					}
 				}
+
 				image {
 					width: 160rpx;
 					height: 160rpx;
 					margin: 0 20rpx 0 0;
 				}
+
 				.center {
 					width: 330rpx;
+
 					.name {
 						font-size: 28rpx;
 						font-family: PingFangSC, PingFang SC;
 						font-weight: 400;
 						color: #222222;
 					}
+
 					.spec {
 						max-width: max-content;
 						font-size: 22rpx;
 						font-family: PingFangSC, PingFang SC;
 						font-weight: 400;
 						color: #888888;
-						
+
 						margin: 16rpx 0 0;
 					}
 				}
 			}
+
 			.cell {
 				padding: 0 0 36rpx;
+
 				.label {
 					font-size: 28rpx;
 					font-family: PingFangSC, PingFang SC;
 					font-weight: 400;
 					color: #666666;
 				}
+
 				.value {
+					white-space: nowrap;
+					max-width: 350rpx;
 					font-size: 28rpx;
 					font-family: SFPro, SFPro;
 					font-weight: 400;
 					color: #222222;
 				}
+
 				image {
 					width: 28rpx;
 					height: 28rpx;
@@ -232,6 +249,7 @@
 				}
 			}
 		}
+
 		.address {
 			text:first-child {
 				font-size: 30rpx;
@@ -239,6 +257,7 @@
 				font-weight: 600;
 				color: #222222;
 			}
+
 			text:last-child {
 				font-size: 24rpx;
 				font-family: SFPro, SFPro;
@@ -247,15 +266,18 @@
 				padding: 16rpx 0 0;
 			}
 		}
+
 		.top {
 			width: 100%;
 			padding: 40rpx 0 28rpx;
+
 			text:first-child {
 				font-size: 36rpx;
 				font-family: PingFangSC, PingFang SC;
 				font-weight: 600;
 				color: #222222;
 			}
+
 			text:last-child {
 				font-size: 24rpx;
 				font-family: PingFangSC, PingFang SC;
@@ -264,4 +286,4 @@
 			}
 		}
 	}
-</style>
+</style>

+ 42 - 19
pageB/order-list.vue

@@ -3,12 +3,14 @@
 		<view class="list">
 			<view class="list-item hflex acenter" v-for="(item,index) in list" :key="index" @click="toinfo(item)">
 				<view class="item-left">
-					<image :src="item.img" class="img" mode="aspectFill"></image>
-					<image src="static/yitijioa.png" class="img-top" mode="aspectFill" v-if="item.type == '1'"></image>
-					<image src="static/duihuanchenggong.png" class="img-top" mode="aspectFill" v-if="item.type == '2'"></image>
+					<image :src="item.goods.image" class="img" mode="aspectFill"></image>
+					<image src="static/yitijioa.png" class="img-top" mode="aspectFill" v-if="item.status == 'applied'">
+					</image>
+					<image src="static/duihuanchenggong.png" class="img-top" mode="aspectFill"
+						v-if="item.status == 'passed'"></image>
 				</view>
 				<view class="vflex item-right jbetween">
-					<text class="text_hide2">{{item.name}}</text>
+					<text class="text_hide2">{{item.goods.name}}</text>
 					<text>{{item.price}}<span style="font-size: 26rpx;">积分</span></text>
 				</view>
 			</view>
@@ -18,40 +20,52 @@
 
 <script>
 	import $api from '@/static/js/api.js'
+	var that = ''
 	export default {
 		data() {
 			return {
 				list: [],
+				page: 1,
+				last_page: 1,
 			}
 		},
 		onLoad() {
+			that = this
 			this.getlist()
 		},
 		onShow() {
-			
+
 		},
 		onPullDownRefresh() {
-			
+
 		},
 		onReachBottom() {
-			
+			if (this.page < this.last_page) {
+				this.page++
+				this.getlist()
+			} else {
+				uni.$u.toast('已经到底了')
+				return
+			}
 		},
 		methods: {
 			toinfo(item) {
 				uni.navigateTo({
-					url: '/pageB/order-detail?type=' + item.type
+					url: '/pageB/order-detail?id=' + item.id
 				})
 			},
 			getlist() {
-				for(var i=0;i<5;i++) {
-					var data = {
-						img: 'https://dummyimage.com/750x750/e3e3e3/fff',
-						type: '2',
-						name: '兰蔻小黑瓶50ml全新肌底液精华液化妆品护肤全套礼盒…',
-						price: 385,
+				$api.req({
+					url: 'integral/order',
+					data: {
+						is_page: 1,
+						page: that.page,
+						limit: 10,
 					}
-					this.list.push(data)
-				}
+				}, function(res) {
+					that.list = that.list.concat(res.data.list)
+					that.last_page = res.data.last_page
+				})
 			},
 		}
 	}
@@ -60,23 +74,27 @@
 <style lang="scss">
 	.content {
 		padding: 24rpx;
+
 		.list {
-			
+
 			.list-item {
 				background: #FFFFFF;
 				border-radius: 16rpx;
-				margin: 0 0 20rpx 0 ;
+				margin: 0 0 20rpx 0;
 				padding: 20rpx;
 				box-sizing: border-box;
+
 				.item-left {
 					position: relative;
 					padding-right: 20rpx;
+
 					.img {
 						width: 196rpx;
 						height: 196rpx;
 						border-radius: 16rpx;
 						overflow: hidden;
 					}
+
 					.img-top {
 						position: absolute;
 						width: 144rpx;
@@ -85,17 +103,22 @@
 						left: 26rpx;
 					}
 				}
+
 				.item-right {
 					height: 196rpx;
 					padding: 10rpx 0;
 					box-sizing: border-box;
 					width: calc(100% - 216rpx);
+
+
+
 					text:first-child {
 						font-size: 32rpx;
 						font-family: PingFangSC, PingFang SC;
 						font-weight: 400;
 						color: #222222;
 					}
+
 					text:last-child {
 						font-size: 44rpx;
 						font-family: SFPro, SFPro;
@@ -106,4 +129,4 @@
 			}
 		}
 	}
-</style>
+</style>

+ 50 - 26
pageB/totaobao.vue

@@ -10,42 +10,61 @@
 </template>
 
 <script>
+	import $api from '@/static/js/api.js'
 	export default {
 		data() {
 			return {
 				img: 'https://dummyimage.com/279x155/e3e3e3/fff',
+				src: ''
 			}
 		},
 		onLoad() {
-			
+			this.getdata()
 		},
 		methods: {
+			getdata() {
+				var that = this
+				$api.req({
+					url: 'config',
+					data: {
+						module: 'shop'
+					}
+				}, function(res) {
+					if(res.data.shop_images.length > 0) {
+						that.img = res.data.shop_images[0]	
+					}
+					that.src = res.data.shop_url
+					console.log(res);
+				})
+			},
 			jump() {
-				// 判断平台
-				if (plus.os.name == 'Android') {  
-					plus.runtime.launchApplication({
-						pname: 'com.taobao.taobao'  ,
-					},  function(e) {
-						uni.showModal({
-						    content:'本机未检测到淘宝客户端,请先下载淘宝APP',  
-						    success:function(res){  
-						        
-						    }  
-						})  
-					});
-				} else if (plus.os.name == 'iOS') {
-					plus.runtime.launchApplication({
-						action: 'taobao://' ,
-					}, function(e) {
-						uni.showModal({
-						    content:'本机未检测到淘宝客户端,请先下载淘宝APP',  
-						    success:function(res){  
-						        
-						    }  
-						})  
-					})
-				}
-				
+				uni.navigateTo({
+					url: '/pages/webview/index?url=' + this.src
+				})
+				// if (plus.os.name == 'Android') {
+				// 	plus.runtime.launchApplication({
+				// 		pname: 'com.taobao.taobao',
+				// 	}, function(e) {
+				// 		uni.showModal({
+				// 			content: '本机未检测到淘宝客户端,请先下载淘宝APP',
+				// 			success: function(res) {
+
+				// 			}
+				// 		})
+				// 	});
+				// } else if (plus.os.name == 'iOS') {
+				// 	plus.runtime.launchApplication({
+				// 		action: 'taobao://',
+				// 	}, function(e) {
+				// 		uni.showModal({
+				// 			content: '本机未检测到淘宝客户端,请先下载淘宝APP',
+				// 			success: function(res) {
+
+				// 			}
+				// 		})
+				// 	})
+				// }
+
 			}
 		}
 	}
@@ -55,17 +74,20 @@
 	.content {
 		background: #F5F5F5;
 		height: 100vh;
+
 		.box {
 			background: #FFFFFF;
 			border-radius: 20rpx;
 			box-sizing: border-box;
 			padding: 40rpx;
+
 			.title {
 				font-size: 32rpx;
 				font-family: PingFangSC, PingFang SC;
 				font-weight: 600;
 				color: #333333;
 			}
+
 			.text {
 				font-size: 28rpx;
 				font-family: PingFangSC, PingFang SC;
@@ -73,11 +95,13 @@
 				color: #999999;
 				padding: 24rpx 0 76rpx;
 			}
+
 			image {
 				width: 510rpx;
 				height: 510rpx;
 			}
 		}
+
 		.btn {
 			width: 662rpx;
 			height: 88rpx;

+ 20 - 7
pageB/yuyue-capture.vue

@@ -19,36 +19,44 @@
 </template>
 
 <script>
+	import $api from '@/static/js/api.js'
 	export default {
 		data() {
 			return {
-				show: false
+				show: false,
+				url: '',
 			}
 		},
 		onLoad() {
-			
+
 		},
 		methods: {
 			sure() {
 				uni.navigateTo({
-					url: '/pageB/totaobao'
+					url: '/pages/webview/index?url=' + this.url
 				})
 				this.show = false
 			},
 			close() {
 				this.show = false
 			},
-			/* 立即预约 */
 			towai() {
-				this.show = true
+				var that = this
+				$api.req({
+					url: 'config',
+					data: {
+						module: 'shoot'
+					}
+				}, function(res) {
+					that.url = res.data.appointment_url
+					that.show = true
+				})
 			},
-			/* 会员预约 */
 			toyuyue() {
 				uni.navigateTo({
 					url: '/pageB/yuyue-vip'
 				})
 			},
-			/* 预约记录 */
 			tojilu() {
 				uni.navigateTo({
 					url: '/pageB/yuyue-list'
@@ -62,14 +70,17 @@
 	.content {
 		background: #FFFFFF;
 		padding: 0 40rpx;
+
 		.popu {
 			background: #FFFFFF;
 			border-radius: 20rpx;
 			padding: 44rpx 38rpx;
+
 			image {
 				width: 78rpx;
 				height: 78rpx;
 			}
+
 			text {
 				font-size: 30rpx;
 				font-family: PingFangSC, PingFang SC;
@@ -77,6 +88,7 @@
 				color: #000000;
 				padding: 26rpx 0 44rpx;
 			}
+
 			.btns {
 				.btn1 {
 					width: 204rpx;
@@ -91,6 +103,7 @@
 					text-align: center;
 					margin: 0 26rpx 0 0;
 				}
+
 				.btn2 {
 					width: 204rpx;
 					height: 72rpx;

+ 55 - 12
pageB/yuyue-list.vue

@@ -3,42 +3,79 @@
 		<view class="list-item hflex acenter jbetween" v-for="(item,index) in list" :key="index">
 			<view class="left">
 				<view class="hflex aend left-top">
-					<text>预约成功</text>
+					<text>{{item.status == 'refused' ? '预约失败' : '预约成功'}}</text>
 					<text>{{item.date}}</text>
 				</view>
 				<view class="left-bottom">恭喜!你已成功的提交了预约拍摄</view>
 			</view>
 			<view class="right">
-				<view class="btn1" v-if="item.status == 'applied'">添加客服</view>
-				<view class="btn2" v-if="item.status == ''">已完成</view>
+				<view class="btn1" v-if="item.status == 'applied'" @click="show_wx = true">添加客服</view>
+				<view class="btn1" v-else-if="item.status == 'refused'" @click="toyuyue">重新预约</view>
+				<view class="btn2" v-else>已完成</view>
 			</view>
 		</view>
+		<u-popup :show="show_wx" @close="tosubmit" mode="center" :round="10">
+			<kefu-wx :wxcode="wxcode" @submit="tosubmit"></kefu-wx>
+		</u-popup>
 	</view>
 </template>
 
 <script>
+	import kefuWx from './components/kefu-wx.vue'
 	import $api from '@/static/js/api.js'
 	export default {
+		components: {
+			kefuWx
+		},
 		data() {
 			return {
 				list: [],
 				page: 1,
-				last_page: 1
+				last_page: 1,
+				wxcode: '',
+				show_wx: false,
 			}
 		},
 		onLoad() {
 			this.getlist()
+			this.getcode()
 		},
 		onShow() {
-			
+
 		},
 		onPullDownRefresh() {
-			
+
 		},
 		onReachBottom() {
-			
+			if (this.page < this.last_page) {
+				this.page++
+				this.getlist()
+			} else {
+				uni.$u.toast('已经到底了')
+				return
+			}
 		},
 		methods: {
+			getcode() {
+				var that = this
+				$api.req({
+					url: 'config',
+					data: {
+						module: 'basic'
+					}
+				}, function(res) {
+					that.wxcode = res.data.customer_service_qrcode
+				})
+			},
+			tosubmit() {
+				this.show_wx = false
+
+			},
+			toyuyue() {
+				uni.navigateTo({
+					url: '/pageB/yuyue-vip'
+				})
+			},
 			getlist() {
 				var _this = this
 				$api.req({
@@ -50,13 +87,13 @@
 						limit: 10
 					}
 				}, function(res) {
-					if(res.code == 10000) {
+					if (res.code == 10000) {
 						_this.list = _this.list.concat(res.data.list)
 						_this.last_page = res.data.last_page
-						console.log('list=',_this.list);
+						console.log('list=', _this.list);
 					}
 				})
-				
+
 			}
 		}
 	}
@@ -65,11 +102,13 @@
 <style lang="scss">
 	.content {
 		padding: 20rpx 28rpx;
+
 		.list-item {
 			background: #FFFFFF;
 			border-radius: 20rpx;
-			margin:  0 0 20rpx;
+			margin: 0 0 20rpx;
 			padding: 32rpx 20rpx;
+
 			.right {
 				.btn1 {
 					width: 160rpx;
@@ -83,6 +122,7 @@
 					line-height: 64rpx;
 					text-align: center;
 				}
+
 				.btn2 {
 					width: 160rpx;
 					height: 64rpx;
@@ -96,6 +136,7 @@
 					text-align: center;
 				}
 			}
+
 			.left {
 				.left-top {
 					text:first-child {
@@ -104,6 +145,7 @@
 						font-weight: 600;
 						color: #333333;
 					}
+
 					text:last-child {
 						font-size: 24rpx;
 						font-family: SFPro, SFPro;
@@ -112,6 +154,7 @@
 						padding-left: 24rpx;
 					}
 				}
+
 				.left-bottom {
 					padding: 20rpx 0 0;
 					font-size: 24rpx;
@@ -122,4 +165,4 @@
 			}
 		}
 	}
-</style>
+</style>

+ 70 - 45
pageB/yuyue-vip.vue

@@ -3,28 +3,33 @@
 		<view class="box">
 			<view class="cell hflex acenter">
 				<view class="label">姓名</view>
-				<u-input placeholder="请输入您的姓名" v-model="name" border="none" > </u-input>
+				<u-input placeholder="请输入您的姓名" v-model="name" border="none"> </u-input>
 			</view>
 			<view class="cell hflex acenter">
 				<view class="label">手机号</view>
-				<u-input placeholder="请输入您的手机号" v-model="mobile" border="none" > </u-input>
+				<u-input placeholder="请输入您的手机号" v-model="mobile" border="none"> </u-input>
 			</view>
 			<view class="cell hflex acenter jbetween" @click="show_time = true">
 				<view class="label">拍摄时间</view>
-				<u-input placeholder="请输入您的拍摄时间" v-model="time" border="none" :disabled="true" disabledColor="#FFFFFF"> </u-input>
+				<u-input placeholder="请输入您的拍摄时间" v-model="time" border="none" :disabled="true" disabledColor="#FFFFFF">
+				</u-input>
 				<image src="static/down.png" mode="aspectFill"></image>
 			</view>
 			<view class="cell hflex acenter">
 				<view class="label">拍摄地点</view>
-				<u-input placeholder="请输入您要拍摄的地方" v-model="address" border="none" > </u-input>
+				<u-input placeholder="请输入您要拍摄的地方" v-model="address" border="none"> </u-input>
 			</view>
 			<view class="cell hflex acenter">
 				<view class="label">拍摄预算</view>
-				<u-input placeholder="请输入您的预算资金" v-model="price" border="none" > </u-input>
+				<u-input placeholder="请输入您的预算资金" v-model="price" border="none"> </u-input>
 			</view>
 			<view class="cell hflex acenter jbetween" @click="show_youhui = true">
 				<view class="label">优惠券</view>
-				<u-input placeholder="不使用" v-model="coupon.name || '不使用'" border="none" :disabled="true" disabledColor="#FFFFFF" > </u-input>
+				<!-- <u-input placeholder="不使用" v-model="coupon.name || '不使用'" border="none" :disabled="true"
+					disabledColor="#FFFFFF"> </u-input> -->
+				<view class="coupon" :style="coupon.coupon.name ? '' : 'color:#222'">
+					{{coupon.coupon.name || '不使用'}}
+				</view>
 				<image src="static/down.png" mode="aspectFill"></image>
 			</view>
 		</view>
@@ -63,8 +68,9 @@
 				youhui_list: [],
 				timelist: [],
 				coupon: {
-					id: '',
-					name: ''
+					coupon: {
+						name: ''
+					}
 				},
 			}
 		},
@@ -72,13 +78,13 @@
 			this.getlist()
 		},
 		onShow() {
-			
+
 		},
 		onPullDownRefresh() {
-			
+
 		},
 		onReachBottom() {
-			
+
 		},
 		methods: {
 			submit() {
@@ -95,51 +101,59 @@
 						coupon_id: _this.coupon.id ? _this.coupon.id : '0',
 					}
 				}, function(res) {
-					if(res.code == 10000) {
-						$api.info(res.msg)
+					$api.info(res.msg)
+					if (res.code == 10000) {
+
 						uni.navigateBack()
 					}
 				})
 			},
 			selectyouhui(e) {
-				this.youhui = this.youhui_list[e].title
+				console.log(e);
+				if(e != -1) {
+					this.coupon = this.youhui_list[e]
+				}
 				this.toclose()
 			},
 			getlist() {
-				for(var i=0;i<5;i++) {
-					var youhui = {
-						title: '租赁设备优惠券',
-						price: '50',
-						tiaojian: '满1000元可用',
-						intro: '仅用于租赁设备时抵扣',
-						status: '1',
-						time: '2023.12.23',
-						type: '1'
+				var _this = this
+				$api.req({
+					url: 'user/coupon',
+					data: {
+						is_page: 0,
+						is_expire: 0,
+						is_use: 0,
+						type: 'shoot'
 					}
-					this.youhui_list.push(youhui)
-				}
-				
+				}, function(res) {
+					if (res.code == 10000) {
+						_this.youhui_list = res.data
+					}
+				})
+
 				const days = 7; // 近7天
 				const week = ['日', '一', '二', '三', '四', '五', '六']; // 星期
-				 
-				const dateList = Array.from({ length: days }, (v, i) => i).map(day => {
-				  const date = new Date();
-				  date.setDate(date.getDate() + day);
-				  let month = date.getMonth() + 1
-				  if(month < 10) {
-					  month = '0' + month
-				  }
-				  let today = date.getDate()
-				  if(today<10) {
-					  today = '0' + today
-				  }
-				  return date.getFullYear() + '-' + month + '-' + today + ' 星期' + week[date.getDay()];
+
+				const dateList = Array.from({
+					length: days
+				}, (v, i) => i).map(day => {
+					const date = new Date();
+					date.setDate(date.getDate() + day);
+					let month = date.getMonth() + 1
+					if (month < 10) {
+						month = '0' + month
+					}
+					let today = date.getDate()
+					if (today < 10) {
+						today = '0' + today
+					}
+					return date.getFullYear() + '-' + month + '-' + today + ' 星期' + week[date.getDay()];
 				});
-				for(var i=0;i<dateList.length;i++) {
+				for (var i = 0; i < dateList.length; i++) {
 					this.timelist.push({
-						id: i+1,
+						id: i + 1,
 						name: dateList[i],
-						value: dateList[i].slice(0,10)
+						value: dateList[i].slice(0, 10)
 					})
 				}
 			},
@@ -160,12 +174,15 @@
 <style lang="scss">
 	.content {
 		padding: 20rpx 28rpx;
+
 		.box {
 			background: #FFFFFF;
 			border-radius: 20rpx;
+
 			.cell {
 				padding: 32rpx 20rpx;
 				border-bottom: 1px solid #F5F5F5;
+
 				.label {
 					font-size: 30rpx;
 					font-family: PingFangSC, PingFang SC;
@@ -174,15 +191,23 @@
 					width: 170rpx;
 					padding-right: 16rpx;
 				}
+
+				.coupon {
+					width: calc(100% - 220rpx);
+					color: rgb(192, 196, 204);
+				}
+
 				image {
 					width: 30rpx;
 					height: 30rpx;
 				}
 			}
-			.cell:last-child{
+
+			.cell:last-child {
 				border: none;
 			}
 		}
+
 		.bottom {
 			position: fixed;
 			bottom: 0;
@@ -192,7 +217,7 @@
 			background: #FFFFFF;
 			box-sizing: border-box;
 			padding: 16rpx 24rpx 66rpx;
-			
+
 			.btn {
 				width: 694rpx;
 				height: 84rpx;
@@ -207,4 +232,4 @@
 			}
 		}
 	}
-</style>
+</style>

+ 97 - 48
pageB/zulin-add.vue

@@ -3,24 +3,28 @@
 		<view class="box">
 			<view class="cell hflex acenter">
 				<view class="label">姓名</view>
-				<u-input placeholder="请输入您的姓名" v-model="name" border="none" > </u-input>
+				<u-input placeholder="请输入您的姓名" v-model="name" border="none"> </u-input>
 			</view>
 			<view class="cell hflex acenter">
 				<view class="label">手机号</view>
-				<u-input placeholder="请输入您的手机号" v-model="mobile" border="none" > </u-input>
+				<u-input placeholder="请输入您的手机号" v-model="mobile" border="none"> </u-input>
 			</view>
 			<view class="cell hflex acenter jbetween" @click="show_time = true">
 				<view class="label">租赁时间</view>
-				<u-input placeholder="请输入您的租赁时间" v-model="time" border="none" :disabled="true" disabledColor="#FFFFFF"> </u-input>
+				<u-input placeholder="请输入您的租赁时间" v-model="time" border="none" :disabled="true" disabledColor="#FFFFFF">
+				</u-input>
 				<image src="static/down.png" mode="aspectFill"></image>
 			</view>
 			<view class="cell hflex acenter">
 				<view class="label">收货地址</view>
-				<u-input placeholder="请输入您的收货地址" v-model="address" border="none" > </u-input>
+				<u-input placeholder="请输入您的收货地址" v-model="address" border="none"> </u-input>
 			</view>
 			<view class="cell hflex acenter jbetween" @click="show_youhui = true">
 				<view class="label">优惠券</view>
-				<u-input placeholder="不使用" v-model="youhui" border="none" :disabled="true" disabledColor="#FFFFFF" > </u-input>
+				<!-- <u-input placeholder="不使用" v-model="youhui" border="none" :disabled="true" disabledColor="#FFFFFF" > </u-input> -->
+				<view class="coupon" :style="coupon.coupon.name == '' ? '' : 'color:#222'">
+					{{coupon.coupon.name || '不使用'}}
+				</view>
 				<image src="static/down.png" mode="aspectFill"></image>
 			</view>
 		</view>
@@ -29,7 +33,7 @@
 			<text>{{content}}</text>
 		</view>
 		<view class="bottom hflex acenter jcenter">
-			<view class="btn">提交表单</view>
+			<view class="btn" @click="submit">提交表单</view>
 		</view>
 		<u-popup :show="show_time" mode="bottom" :round="14" @close="toclose">
 			<time-box :list="timelist" @sure="selecttime" @close="toclose"></time-box>
@@ -54,75 +58,107 @@
 				name: '',
 				mobile: '',
 				time: '',
+				date: '',
 				address: '',
 				money: '',
-				youhui: '',
+				coupon: {
+					coupon: {
+						name: ''
+					}
+				},
 				show_time: false,
 				show_youhui: false,
 				youhui_list: [],
 				timelist: [],
 				content: `1、负责境外上市公司的研究与分析,对重点公司进行调研、跟踪与经营预测,并撰写研究报告,提供投资建议;
 							2、结合国家和地方相关经济政策,对行业发展进行前瞻性研究,准确判断行业发展趋势,提供行业研究报告和投资策略;
-							`	
+							`
 			}
 		},
 		onLoad() {
 			this.getlist()
 		},
 		onShow() {
-			
+
 		},
 		onPullDownRefresh() {
-			
+
 		},
 		onReachBottom() {
-			
+
 		},
 		methods: {
+			submit() {
+				var _this = this
+				$api.req({
+					url: 'shoot-equipment-lease',
+					method: 'POST',
+					data: {
+						name: _this.name,
+						mobile: _this.mobile,
+						date: _this.date,
+						address: _this.address,
+						coupon_id: _this.coupon.id ? _this.coupon.id : '0',
+					}
+				}, function(res) {
+					if (res.code == 10000) {
+						$api.info(res.msg)
+						uni.navigateBack()
+					}
+				})
+			},
 			selectyouhui(e) {
-				this.youhui = this.youhui_list[e].title
+				if(e != -1) {
+					this.coupon = this.youhui_list[e]
+				}
 				this.toclose()
 			},
 			getlist() {
-				for(var i=0;i<5;i++) {
-					var youhui = {
-						title: '租赁设备优惠券',
-						price: '50',
-						tiaojian: '满1000元可用',
-						intro: '仅用于租赁设备时抵扣',
-						status: '1',
-						time: '2023.12.23',
-						type: '1'
+				var _this = this
+				$api.req({
+					url: 'user/coupon',
+					data: {
+						is_page: 0,
+						is_expire: 0,
+						is_use: 0,
+						type: 'shoot'
 					}
-					this.youhui_list.push(youhui)
-				}
+				}, function(res) {
+					if (res.code == 10000) {
+						_this.youhui_list = res.data
+					}
+				})
+
+				const days = 7; // 近7天
+				const week = ['日', '一', '二', '三', '四', '五', '六']; // 星期
 				
-				this.timelist = [
-					{
-						id: 1,
-						name: '11月7日 星期二'
-					},
-					{
-						id: 2,
-						name: '11月8日 星期三'
-					},
-					{
-						id: 3,
-						name: '11月9日 星期四'
-					},
-					{
-						id: 4,
-						name: '11月10日 星期五'
-					},
-					{
-						id: 5,
-						name: '11月11日 星期六'
-					},
-				]
+				const dateList = Array.from({
+					length: days
+				}, (v, i) => i).map(day => {
+					const date = new Date();
+					date.setDate(date.getDate() + day);
+					let month = date.getMonth() + 1
+					if (month < 10) {
+						month = '0' + month
+					}
+					let today = date.getDate()
+					if (today < 10) {
+						today = '0' + today
+					}
+					return date.getFullYear() + '-' + month + '-' + today + ' 星期' + week[date.getDay()];
+				});
+				for (var i = 0; i < dateList.length; i++) {
+					this.timelist.push({
+						id: i + 1,
+						name: dateList[i],
+						value: dateList[i].slice(0, 10)
+					})
+				}
 			},
 			selecttime(e) {
 				console.log(e);
 				this.time = this.timelist[e].name
+				this.date = this.timelist[e].value
 				this.toclose()
 			},
 			toclose() {
@@ -136,12 +172,15 @@
 <style lang="scss">
 	.content {
 		padding: 20rpx 28rpx;
+
 		.box {
 			background: #FFFFFF;
 			border-radius: 20rpx;
+
 			.cell {
 				padding: 32rpx 20rpx;
 				border-bottom: 1px solid #F5F5F5;
+
 				.label {
 					font-size: 30rpx;
 					font-family: PingFangSC, PingFang SC;
@@ -150,15 +189,23 @@
 					width: 170rpx;
 					padding-right: 16rpx;
 				}
+
+				.coupon {
+					width: calc(100% - 220rpx);
+					color: rgb(192, 196, 204);
+				}
+
 				image {
 					width: 30rpx;
 					height: 30rpx;
 				}
 			}
-			.cell:last-child{
+
+			.cell:last-child {
 				border: none;
 			}
 		}
+
 		.texts {
 			text:first-child {
 				font-size: 26rpx;
@@ -167,6 +214,7 @@
 				color: #222222;
 				padding: 28rpx 0 20rpx;
 			}
+
 			text:last-child {
 				font-size: 24rpx;
 				font-family: PingFangSC, PingFang SC;
@@ -174,6 +222,7 @@
 				color: #666666;
 			}
 		}
+
 		.bottom {
 			position: fixed;
 			bottom: 0;
@@ -183,7 +232,7 @@
 			background: #FFFFFF;
 			box-sizing: border-box;
 			padding: 16rpx 24rpx 66rpx;
-			
+
 			.btn {
 				width: 694rpx;
 				height: 84rpx;
@@ -198,4 +247,4 @@
 			}
 		}
 	}
-</style>
+</style>

+ 63 - 18
pageB/zulin-list.vue

@@ -9,45 +9,84 @@
 				<view class="left-bottom">恭喜!你已成功的提交了设备租赁</view>
 			</view>
 			<view class="right">
-				<view class="btn1" v-if="item.status == 1">添加客服</view>
-				<view class="btn2" v-if="item.status == 2">已完成</view>
+				<view class="btn1" v-if="item.status == 'applied'" @click="show_wx = true">添加客服</view>
+				<view class="btn2" v-else>已完成</view>
 			</view>
 		</view>
+		<u-popup :show="show_wx" @close="tosubmit" mode="center" :round="10">
+			<kefu-wx :wxcode="wxcode" @submit="tosubmit"></kefu-wx>
+		</u-popup>
 	</view>
 </template>
 
 <script>
+	import kefuWx from './components/kefu-wx.vue'
 	import $api from '@/static/js/api.js'
 	export default {
+		components: {
+			kefuWx
+		},
 		data() {
 			return {
-				list: []
+				list: [],
+				page: 1,
+				last_page: 1,
+				wxcode: '',
+				show_wx: false
 			}
 		},
 		onLoad() {
 			this.getlist()
+			this.getcode()
 		},
 		onShow() {
-			
+
 		},
 		onPullDownRefresh() {
-			
+
 		},
 		onReachBottom() {
-			
+			if (this.page < this.last_page) {
+				this.page++
+				this.getlist()
+			} else {
+				uni.$u.toast('已经到底了')
+				return
+			}
 		},
 		methods: {
+			getcode() {
+				var that = this
+				$api.req({
+					url: 'config',
+					data: {
+						module: 'basic'
+					}
+				}, function(res) {
+					that.wxcode = res.data.customer_service_qrcode
+				})
+			},
+			tosubmit() {
+				this.show_wx = false
+			
+			},
 			getlist() {
-				this.list = [
-					{
-						time: '2023-10-30 周三',
-						status: 1
-					},
-					{
-						time: '2023-10-30 周三',
-						status: 2
-					},
-				]
+				var _this = this
+				$api.req({
+					url: 'shoot-equipment-lease',
+					method: 'GET',
+					data: {
+						is_page: 1,
+						page: _this.page,
+						limit: 10,
+					}
+				}, function(res) {
+					if (res.code == 10000) {
+						_this.list = _this.list.concat(res.data.list)
+						_this.last_page = res.data.last_page
+					}
+
+				})
 			}
 		}
 	}
@@ -56,11 +95,13 @@
 <style lang="scss">
 	.content {
 		padding: 20rpx 28rpx;
+
 		.list-item {
 			background: #FFFFFF;
 			border-radius: 20rpx;
-			margin:  0 0 20rpx;
+			margin: 0 0 20rpx;
 			padding: 32rpx 20rpx;
+
 			.right {
 				.btn1 {
 					width: 160rpx;
@@ -74,6 +115,7 @@
 					line-height: 64rpx;
 					text-align: center;
 				}
+
 				.btn2 {
 					width: 160rpx;
 					height: 64rpx;
@@ -87,6 +129,7 @@
 					text-align: center;
 				}
 			}
+
 			.left {
 				.left-top {
 					text:first-child {
@@ -95,6 +138,7 @@
 						font-weight: 600;
 						color: #333333;
 					}
+
 					text:last-child {
 						font-size: 24rpx;
 						font-family: SFPro, SFPro;
@@ -103,6 +147,7 @@
 						padding-left: 24rpx;
 					}
 				}
+
 				.left-bottom {
 					padding: 20rpx 0 0;
 					font-size: 24rpx;
@@ -113,4 +158,4 @@
 			}
 		}
 	}
-</style>
+</style>

+ 27 - 6
pageC/about.vue

@@ -13,7 +13,8 @@
 			</u-cell-group>
 			<u-collapse :border="false">
 				<u-collapse-item title="联系我们">
-					 <text class="u-collapse-content">手机号:13642510729;邮箱:liu@3346.com</text>
+					<text class="u-collapse-content">手机号:{{mobile}};</text>
+					<text class="u-collapse-content">邮箱:{{email}}</text>
 				</u-collapse-item>
 			</u-collapse>
 		</view>
@@ -30,6 +31,8 @@
 		data() {
 			return {
 				version: '',
+				mobile: '',
+				email: '',
 			}
 		},
 		onLoad() {
@@ -40,21 +43,32 @@
 			// #ifndef H5
 			this.version = systemInfo.appWgtVersion;
 			// #endif
+			this.getdata()
 		},
 		onShow() {
-			
+
 		},
 		onPullDownRefresh() {
-			
+
 		},
 		onReachBottom() {
-			
+
 		},
 		methods: {
+			getdata() {
+				var that = this
+				$api.req({
+					url: 'config?module=basic'
+				}, function(res) {
+					that.mobile = res.data.contact_phone
+					that.email = res.data.contact_email
+				})
+			},
 			toshop() {
 				if (plus.os.name == "Android") {
 					// 跳转安卓应用市场
-					let appurl = "market://details?id=com.autonavi.minimap" //这个是通用应用市场,如果想指定某个应用商店,需要单独查这个应用商店的包名或scheme及参数
+					let appurl =
+						"market://details?id=com.autonavi.minimap" //这个是通用应用市场,如果想指定某个应用商店,需要单独查这个应用商店的包名或scheme及参数
 					plus.runtime.openURL(appurl)
 				} else {
 					// 跳转AppStore
@@ -78,9 +92,11 @@
 		height: 100vh;
 		background: #FFFFFF;
 		padding: 0 28rpx;
+
 		.bottom {
 			position: absolute;
 			bottom: 64rpx;
+
 			text {
 				font-size: 24rpx;
 				font-family: PingFangSC, PingFang SC;
@@ -88,17 +104,21 @@
 				color: #333333;
 			}
 		}
+
 		.center {
 			width: 100%;
 		}
+
 		.top {
 			padding: 54rpx 0 78rpx;
+
 			image {
 				width: 150rpx;
 				height: 150rpx;
 				background: #D8D8D8;
 				border-radius: 50%;
 			}
+
 			.name {
 				font-size: 32rpx;
 				font-family: PingFangSC, PingFang SC;
@@ -106,6 +126,7 @@
 				color: #333333;
 				padding: 32rpx 0 16rpx;
 			}
+
 			.verison {
 				font-size: 28rpx;
 				font-family: SFPro, SFPro;
@@ -114,4 +135,4 @@
 			}
 		}
 	}
-</style>
+</style>

+ 39 - 6
pageC/account.vue

@@ -2,13 +2,14 @@
 	<view class="content">
 		<u-cell-group>
 			<u-cell size="large" title="手机号" :value="user.mobile" isLink></u-cell>
-			<u-cell size="large" title="微信号" :value="user.wx || '未绑定'" isLink @click="tobindwx"></u-cell>
+			<u-cell size="large" title="微信号" :value="user.wx_name || '未绑定'" isLink @click="tobindwx"></u-cell>
 			<u-cell size="large" title="登录密码" value="修改密码" isLink @click="topwd"></u-cell>
 		</u-cell-group>
 	</view>
 </template>
 
 <script>
+	import $api from '@/static/js/api.js'
 	export default {
 		data() {
 			return {
@@ -24,12 +25,44 @@
 					url: '/pageC/edit-pwd'
 				})
 			},
-			tobindwx() {},
+			tobindwx() {
+				var that = this
+				uni.login({
+					"provider": "weixin",
+					"onlyAuthorize": true, // 微信登录仅请求授权认证
+					success: function(event){
+						const {code} = event
+						//客户端成功获取授权临时票据(code),向业务服务器发起登录请求。
+						$api.req({
+							url: 'user/bind-wechat',
+							method: 'post',
+							data: {
+								code: event.code
+							}
+						}, function(res) {
+							if(res.code == 10000) {
+								$api.info('绑定成功')
+							}
+						})
+					},
+					fail: function (err) {
+						// 登录授权失败
+						// err.code是错误码
+					}
+				})
+			},
 			getuser() {
-				this.user = {
-					mobile: '178****3376',
-					wx: ''
-				}
+				var that = this
+				$api.req({
+					url: 'user/info',
+					method:'get',
+					
+				} ,function(res) {
+					if(res.code == 10000) {
+						that.user = res.data
+					}
+				})
+				
 			}
 		}
 	}

+ 245 - 29
pageC/calendar.vue

@@ -1,47 +1,83 @@
 <template>
 	<view class="content">
-		<u-navbar title="签到日历" bgColor="rgba(0,0,0,0)" safeAreaInsetTop autoBack height="44px"></u-navbar>
+		<u-navbar title="签到日历" :bgColor="bgColor" safeAreaInsetTop autoBack height="44px"></u-navbar>
 		<image src="static/jifen-bg.png" mode="aspectFill" class="top_bg"></image>
 		<view class="top vflex acenter jcenter">
-			<text>已连续签到2天</text>
+			<text class="text1">已连续签到{{succession_days}}天</text>
 			<jcalendar :dataSource="datalist" @dateChange="changedate"></jcalendar>
 		</view>
 		<view class="content-bg">
-			
+
 			<view class="box">
 				<view class="title">签到领福利</view>
-				<view class="list-item hflex acenter jbetween"  v-for="(item,index) in list" :key="index">
+				<view class="list-item hflex acenter jbetween" v-for="(item,index) in list" :key="index">
 					<view class="item-left hflex acenter">
-						<image :src="item.prize_image" mode="aspectFill"></image>
+						<view class="images">
+							<image :src="item.prize_image" mode="aspectFill" v-if="item.prize_type != 'integral'"></image>
+							<image src="@/static/images/jifen.png" mode="aspectFill" v-if="item.prize_type == 'integral'"></image>
+							<!-- <image src="@/static/images/yitijiao.png" mode="aspectFill" class="images-icon" v-if="item.is_receive == 1"></image> -->
+							<image src="@/static/images/yilingqu.png" mode="aspectFill" class="images-icon" v-if="item.is_receive == 1"></image>
+							<image src="@/static/images/dailingqu.png" mode="aspectFill" class="images-icon" v-if="item.can_receive == 1 && item.is_receive == 0"></image>
+						</view>
 						<view class="img-right vflex">
-							<text>当前连续签到{{item.days}}天</text>
-							<text>{{item.prize_name}}</text>
+							<text class="text2">当前连续签到{{item.days}}天</text>
+							<text class="text3">{{item.prize_name}}</text>
 						</view>
 					</view>
 					<view class="item-right">
-						<text v-if="item.can_receive == 0">未达成</text>
-						<view v-else-if="item.is_receive == 0" class="btn1">领取奖励</view>
-						<view v-else class="btn2">已领取</view>
+						<view class="text4" v-if="item.can_receive == 0">未达成</view>
+						<view v-if="item.can_receive != 0 && item.is_receive == 0" class="btn1" style="background: #00B0B0;color: #FFF"
+							@click="toreceive(item)">领取奖励</view>
+						<view v-if="item.can_receive != 0 && item.is_receive != 0" class="btn2">已领取</view>
 					</view>
 				</view>
 			</view>
 		</view>
+		<u-popup :show="show_address" @close="toclose" mode="bottom" :round="13">
+			<addressBox @close="toclose" @select="selectAddress"></addressBox>
+		</u-popup>
+		<u-popup :show="show_submit" @close="toclose" mode="center" :round="10">
+			<view class="popu1 vflex acenter">
+				<image src="static/success.png" mode="aspectFill"></image>
+				<view class="success">领取成功</view>
+				<view class="success-text">请前往添加客服微信</view>
+				<view class="hflex acenter btns">
+					<view class="btn1" @click="toclose">稍后添加</view>
+					<view class="btn2" @click="show_wx = true">添加客服</view>
+				</view>
+			</view>
+		</u-popup>
+		<u-popup :show="show_wx" @close="toclose" mode="center" :round="10">
+			<kefu-wx :wxcode="wxcode" @submit="toclose"></kefu-wx>
+		</u-popup>
 	</view>
 </template>
 
 <script>
 	import Jcalendar from '@/components/j-calendar/j-calendar.vue'
+	import addressBox from './components/addressbox.vue'
+	import kefuWx from './components/kefu-wx.vue'
 	import $api from '@/static/js/api.js'
 	export default {
 		components: {
-			Jcalendar
+			Jcalendar,
+			addressBox,
+			kefuWx
 		},
 		data() {
 			return {
 				user: {},
 				list: [],
 				datalist: [],
-				date: ''
+				date: '',
+				bgColor: 'rgba(0, 0, 0, 0)',
+				succession_days: '',
+				data: {},
+				show_address: false,
+				show_wx: false,
+				show_submit: false,
+				wxcode: '',
+				address_id: '',
 			}
 		},
 		onLoad() {
@@ -49,22 +85,84 @@
 			this.getlist()
 			var year = parseInt(new Date().getFullYear())
 			var month = parseInt(new Date().getMonth() + 1)
-			if(month<10) {
+			if (month < 10) {
 				month = '0' + month
 			}
 			var date = year + '-' + month
 			this.getdate(date)
 		},
 		onShow() {
-			
+
+		},
+		onPageScroll(e) {
+			console.log(e);
+			if (e.scrollTop > 0) {
+				this.bgColor = 'rgba(255,255,255)'
+			} else {
+				this.bgColor = 'rgba(0, 0, 0, 0)'
+			}
 		},
 		onPullDownRefresh() {
-			
+
 		},
 		onReachBottom() {
-			
+
 		},
 		methods: {
+			getcode() {
+				var that = this
+				$api.req({
+					url: 'config',
+					data: {
+						module: 'basic'
+					}
+				}, function(res) {
+					that.wxcode = res.data.customer_service_qrcode
+				})
+			},
+			toadd(item) {
+				if (item.prize_type == 'goods') {
+					this.show_submit = true
+					this.getcode()
+				} else {
+					return
+				}
+			},
+			selectAddress(e) {
+				this.address_id = e
+				this.receive(this.data.id)
+				this.toclose()
+			},
+			toclose() {
+				this.show_address = false
+				this.show_submit = false
+				this.show_wx = false
+			},
+			receive(id) {
+				var that = this
+				$api.req({
+					url: 'sign/prize/' + id + '/receive',
+					method: 'post',
+					data: {
+						address_id: this.address_id
+					}
+				}, function(res) {
+					$api.info(res.msg)
+					setTimeout(() => {
+						that.getlist()
+					})
+				})
+			},
+			toreceive(item) {
+				var that = this
+				if(item.prize_type == 'goods') {
+					this.data = item
+					this.show_address = true
+				} else {
+					this.receive(item.id)
+				}
+				
+			},
 			changedate(e) {
 				this.getdate(e)
 			},
@@ -77,8 +175,9 @@
 						date: date
 					}
 				}, function(res) {
-					if(res.code == 10000) {
+					if (res.code == 10000) {
 						_this.datalist = res.data.days
+						_this.succession_days = res.data.succession_days
 					}
 				})
 			},
@@ -92,11 +191,11 @@
 						is_page: 0
 					}
 				}, function(res) {
-					if(res.code == 10000) {
+					if (res.code == 10000) {
 						_this.list = res.data
 					}
 				})
-				
+
 			},
 			getuser() {
 				var _this = this
@@ -104,7 +203,7 @@
 					url: 'user/info',
 					methos: 'GET'
 				}, function(res) {
-					if(res.code == 10000) {
+					if (res.code == 10000) {
 						_this.user = res.data
 					}
 				})
@@ -114,12 +213,103 @@
 </script>
 
 <style lang="scss">
-	.content {
+	.content::v-deep {
+		.u-navbar--fixed {
+			z-index: 999;
+		}
+.popu1 {
+			width: 510rpx;
+			padding: 46rpx 0;
+
+			.top {
+				width: 100%;
+
+				.top-title {
+					font-size: 32rpx;
+					font-family: PingFangSC, PingFang SC;
+					font-weight: 600;
+					color: #000000;
+					text-align: center;
+					padding-left: 100rpx;
+				}
+
+				image {
+					width: 36rpx;
+					height: 36rpx;
+				}
+			}
+
+			.center {
+				image {
+					width: 310rpx;
+					height: 310rpx;
+				}
+
+				text {
+					font-size: 22rpx;
+					font-family: PingFangSC, PingFang SC;
+					font-weight: 400;
+					color: rgba(0, 0, 0, .42);
+				}
+			}
+
+			image {
+				width: 78rpx;
+				height: 78rpx;
+				margin: 12rpx 36rpx;
+			}
+
+			.success {
+				font-size: 30rpx;
+				font-family: PingFangSC, PingFang SC;
+				font-weight: 400;
+				color: #000000;
+			}
+
+			.success-text {
+				font-size: 24rpx;
+				font-family: PingFangSC, PingFang SC;
+				font-weight: 400;
+				color: rgba(0, 0, 0, .6);
+				padding: 8rpx 0 42rpx;
+			}
+
+			.btns {
+				.btn1 {
+					width: 204rpx;
+					height: 72rpx;
+					background: #E7E7E7;
+					border-radius: 40rpx;
+					font-size: 28rpx;
+					font-family: PingFangSC, PingFang SC;
+					font-weight: 400;
+					color: #666666;
+					line-height: 72rpx;
+					text-align: center;
+				}
+
+				.btn2 {
+					width: 204rpx;
+					height: 72rpx;
+					background: #00B0B0;
+					border-radius: 40rpx;
+					font-size: 28rpx;
+					font-family: PingFangSC, PingFang SC;
+					font-weight: 400;
+					color: #FFFFFF;
+					line-height: 72rpx;
+					text-align: center;
+					margin: 0 0 0 26rpx;
+				}
+			}
+		}
+
 		// background: unset;
 		.content-bg {
 			// background: #f5f5f5;
 			// min-height: 80vh;
 		}
+
 		.box {
 			margin: 20rpx auto;
 			width: 694rpx;
@@ -127,21 +317,27 @@
 			border-radius: 16rpx;
 			box-sizing: border-box;
 			padding: 28rpx;
+
 			.title {
 				font-size: 32rpx;
 				font-family: PingFangSC, PingFang SC;
 				font-weight: 600;
 				color: #333333;
 			}
+
 			.list-item {
 				margin-top: 40rpx;
+
 				.item-right {
-					text {
+					.text4 {
+						width: 148rpx;
 						font-size: 28rpx;
 						font-family: PingFangSC, PingFang SC;
 						font-weight: 400;
 						color: #999999;
+						text-align: center;
 					}
+
 					.btn1 {
 						width: 148rpx;
 						height: 56rpx;
@@ -154,6 +350,7 @@
 						line-height: 56rpx;
 						text-align: center;
 					}
+
 					.btn1 {
 						width: 128rpx;
 						height: 56rpx;
@@ -167,20 +364,36 @@
 						text-align: center;
 					}
 				}
+
 				.item-left {
-					image {
-						width: 100rpx;
-						height: 100rpx;
+					.images {
+						position: relative;
+						image {
+							width: 100rpx;
+							height: 100rpx;
+						}
+						.images-icon {
+							position: absolute;
+							top: 0;
+							left: 0;
+							width: 100rpx;
+							height: 100rpx;
+							background: rgba(0, 0, 0, .3);
+						}
 					}
+					
+
 					.img-right {
 						padding-left: 20rpx;
-						text:first-child {
+
+						.text2 {
 							font-size: 28rpx;
 							font-family: SFPro, SFPro;
 							font-weight: 500;
 							color: #333333;
 						}
-						text:last-child {
+
+						.text3 {
 							font-size: 24rpx;
 							font-family: PingFangSC, PingFang SC;
 							font-weight: 400;
@@ -191,6 +404,7 @@
 				}
 			}
 		}
+
 		.top_bg {
 			position: absolute;
 			width: 100%;
@@ -198,10 +412,12 @@
 			left: 0;
 			// z-index: -1;
 		}
+
 		.top {
 			width: 694rpx;
 			margin: 108rpx auto 20rpx;
-			text {
+
+			.text1 {
 				z-index: 99;
 				font-size: 32rpx;
 				font-family: PingFangSC, PingFang SC;
@@ -211,4 +427,4 @@
 			}
 		}
 	}
-</style>
+</style>

+ 95 - 37
pageC/collect-list.vue

@@ -13,17 +13,35 @@
 		<view class="list">
 			<u-swipe-action>
 				<u-checkbox-group v-model="select_all" placement="column" @change="selectitem">
-					<view class="list-item hflex acenter" v-for="(item,index) in list" :key="index">
-						<u-checkbox v-if="show_manager" activeColor="#57C3C2" shape="circle" :customStyle="{marginBottom: '8px'}" :name="item.id"></u-checkbox>
+					<view class="list-item hflex acenter" v-for="(item,index) in list" :key="index"
+						@click="toinfo(item)">
+						<u-checkbox v-if="show_manager" activeColor="#57C3C2" shape="circle"
+							:customStyle="{marginBottom: '8px'}" :name="item.id"></u-checkbox>
 						<u-swipe-action-item :options="options" @click="tocancel(item)">
-							<view class="hflex acenter" style="flex:1">
-								<image :src="item.img" mode="aspectFill"></image>
-								<view class="img-right">
-									<text class="name text_hide2">{{item.name}}</text>
-									<text class="num" v-if="current != 4">{{item.time}}  {{item.like_num || 0}}喜欢 · {{item.comment_num || 0}}评论</text>
+							<view class="hflex acenter" style="flex:1" v-if="current != 3">
+								<image :src="item.image" mode="aspectFill"></image>
+								<view class="img-right vflex jbetween">
+									<text class="name text_hide2">{{current == 4 ? item.name : item.title}}</text>
+									<view class="num hflex acenter" v-if="current != 4">
+										<text>{{item.created_at}}</text>
+										<text
+											style="padding-left: 20rpx;">{{item.like_count || 0}}喜欢·{{item.comment_count || 0}}评论</text>
+									</view>
 									<text class="price" v-else>{{item.price}}积分</text>
 								</view>
 							</view>
+							<view class="hflex acenter" style="flex:1" v-if="current == 3">
+								<image :src="item.images[0]" mode="aspectFill" v-if="item.images.length>0"></image>
+								<view class="img-right vflex jbetween">
+									<text class="name text_hide2">{{item.content}}</text>
+
+									<view class="num hflex acenter">
+										<text>{{item.created_at}}</text>
+										<text
+											style="padding-left: 20rpx;">{{item.like_count || 0}}喜欢·{{item.comment_count || 0}}评论</text>
+									</view>
+								</view>
+							</view>
 						</u-swipe-action-item>
 					</view>
 				</u-checkbox-group>
@@ -32,7 +50,8 @@
 		<view style="height: 186rpx;" v-if="show_manager"></view>
 		<view class="bottom hflex acenter jbetween" v-if="show_manager">
 			<u-checkbox-group placement="column">
-				<u-checkbox :checked="quanxuan" @change="selectall" activeColor="#57C3C2" shape="circle" :customStyle="{marginBottom: '8px'}" label="全选"></u-checkbox>
+				<u-checkbox :checked="quanxuan" @change="selectall" activeColor="#57C3C2" shape="circle"
+					:customStyle="{marginBottom: '8px'}" label="全选"></u-checkbox>
 			</u-checkbox-group>
 			<view class="btn">取消收藏</view>
 		</view>
@@ -40,30 +59,32 @@
 </template>
 
 <script>
+	import $api from '@/static/js/api.js'
 	export default {
 		data() {
-			return{
+			return {
 				list: [],
-				current:0,
-				tabs: [
-					{
-						id: 'zixun',
+				page: 1,
+				last_page: 1,
+				current: 0,
+				tabs: [{
+						id: 'info',
 						name: '资讯'
 					},
 					{
-						id: 'wenzhang',
+						id: 'article',
 						name: '文章'
 					},
 					{
-						id: 'shipin',
+						id: 'video',
 						name: '视频'
 					},
 					{
-						id: 'luntan',
+						id: 'post',
 						name: '论坛'
 					},
 					{
-						id: 'shangpin',
+						id: 'integral_goods',
 						name: '商品'
 					},
 				],
@@ -81,33 +102,52 @@
 		onLoad() {
 			this.getlist()
 		},
+		onReachBottom() {
+			if (this.page < this.last_page) {
+				this.page++
+				this.getlist()
+			} else {
+				uni.$u.toast('已经到底了')
+				return
+			}
+		},
 		methods: {
+			toinfo(item) {
+				if (this.current != 4) {
+					uni.navigateTo({
+						url: '/pageA/info-detail?id=' + item.id + '&type=' + this.tabs[this.current].id
+					})
+				} else {
+					uni.navigateTo({
+						url: '/pageB/good-detail?id=' + item.id
+					})
+				}
+
+			},
 			/* 全选 */
 			selectall() {
 				this.quanxuan = !this.quanxuan
 				console.log(this.quanxuan);
-				if(this.quanxuan) {
+				if (this.quanxuan) {
 					this.select_all = []
-					for(var i=0;i<this.list.length;i++) {
+					for (var i = 0; i < this.list.length; i++) {
 						this.select_all.push(this.list[i].id)
 					}
 				} else {
 					this.select_all = []
 				}
-				console.log(this.select_all);
 			},
 			/* 选择 */
 			selectitem(e) {
 				this.select_all = e
-				if(this.select_all.length == this.list.length) {
+				if (this.select_all.length == this.list.length) {
 					this.quanxuan = true
 				} else {
 					this.quanxuan = false
 				}
 			},
 			/* 取消收藏 */
-			tocancel(item) {
-			},
+			tocancel(item) {},
 			/* 切换tab */
 			changetabs(e) {
 				this.current = e.index
@@ -117,19 +157,24 @@
 				this.getlist()
 			},
 			getlist() {
-				
-				for(var i=0;i<10;i++) {
-					var data = {
-						id: '000' + i,
-						img: 'https://cdn.uviewui.com/uview/album/1.jpg',
-						name: '新传专题04 | 虚拟现实及其在新闻领域的运用',
-						time: '3小时前',
-						like_num: 10,
-						comment_num: 235,
-						price: 5156
+				var that = this
+				$api.req({
+					url: 'summary',
+					method: 'GET',
+					data: {
+						is_page: 1,
+						page: that.page,
+						limit: 10,
+						type: 'collect',
+						source_type: that.tabs[that.current].id
 					}
-					this.list.push(data)
-				}
+				}, function(res) {
+					if (res.code == 10000) {
+						that.list = that.list.concat(res.data.list)
+						that.last_page = res.data.last_page
+					}
+
+				})
 			},
 		},
 	}
@@ -139,15 +184,17 @@
 	.content::v-deep {
 		background: #FFFFFF;
 		position: relative;
+
 		.bottom {
 			position: fixed;
 			bottom: 0;
 			width: 750rpx;
 			height: 166rpx;
 			background: #FFFFFF;
-			padding: 12rpx 28rpx 80rpx; 
+			padding: 12rpx 28rpx 80rpx;
 			box-sizing: border-box;
 			z-index: 29;
+
 			.btn {
 				width: 184rpx;
 				height: 72rpx;
@@ -161,19 +208,25 @@
 				text-align: center;
 			}
 		}
-		.list{
+
+		.list {
 			width: 100%;
 			box-sizing: border-box;
 			padding: 28rpx 28rpx;
+
 			.list-item {
 				margin: 0 0 32rpx;
+
 				image {
 					width: 200rpx;
 					height: 128rpx;
 					border-radius: 6rpx;
 					margin: 0 20rpx 0 0;
 				}
+
 				.img-right {
+					height: 128rpx;
+
 					.name {
 						max-width: 452rpx;
 						font-size: 28rpx;
@@ -182,12 +235,14 @@
 						color: #333333;
 						padding: 0 0 14rpx;
 					}
+
 					.num {
 						font-size: 20rpx;
 						font-family: SFPro, SFPro;
 						font-weight: 400;
 						color: #666666;
 					}
+
 					.price {
 						font-size: 28rpx;
 						font-family: JDZhengHT, JDZhengHT;
@@ -195,16 +250,19 @@
 						color: #FF3333;
 					}
 				}
+
 				.u-checkbox {
 					margin: 0 32rpx 0 0;
 				}
 			}
 		}
+
 		.tabs {
 			width: 100%;
 			padding: 18rpx 0;
 			border-bottom: 2rpx solid #F5F5F5;
 		}
+
 		.u-nav-slot {
 			text {
 				font-size: 28rpx;

+ 92 - 30
pageC/drafts.vue

@@ -13,16 +13,30 @@
 		<view class="list" v-if="list.length > 0">
 			<u-checkbox-group v-model="select_all" placement="column" @change="selectitem">
 				<view class="list-item hflex acenter" v-for="(item,index) in list" :key="index">
-					<u-checkbox v-if="show_manager" activeColor="#57C3C2" shape="circle" :customStyle="{marginBottom: '8px'}" :name="item.id"></u-checkbox>
-					<view class="hflex acenter" style="flex:1">
-						<image :src="item.img" mode="aspectFill"></image>
+					<u-checkbox v-if="show_manager" activeColor="#57C3C2" shape="circle"
+						:customStyle="{marginBottom: '8px'}" :name="item.id"></u-checkbox>
+					<view class="hflex acenter" style="flex:1" v-if="item.source_type != 'post'">
+						<image :src="item.source.image" mode="aspectFill"></image>
 						<view class="img-right">
-							<text class="name text_hide2">{{item.name}}</text>
-							<view class="hflex acenter jbetween">
-								<view class="num">{{item.time}}</view>
+							<text class="name text_hide2">{{item.source.title}}</text>
+							<view class="hflex acenter jbetween" style="width: 100%;">
+								<view class="num">{{item.created_at}}</view>
 								<view class="hflex acenter btns">
-									<text>编辑</text>
-									<text>删除</text>
+									<text @click="editItem(item)">编辑</text>
+									<text @click="delItem(item)">删除</text>
+								</view>
+							</view>
+						</view>
+					</view>
+					<view class="hflex acenter" style="flex:1" v-if="item.source_type == 'post'">
+						<image :src="item.source.images[0]" mode="aspectFill" v-if="item.source.images.length>0"></image>
+						<view class="img-right">
+							<text class="name text_hide2">{{item.source.content}}</text>
+							<view class="hflex acenter jbetween" style="width: 100%;">
+								<view class="num">{{item.created_at}}</view>
+								<view class="hflex acenter btns">
+									<text @click="editItem(item)">编辑</text>
+									<text @click="delItem(item)">删除</text>
 								</view>
 							</view>
 						</view>
@@ -36,7 +50,8 @@
 		<view style="height: 186rpx;" v-if="show_manager"></view>
 		<view class="bottom hflex acenter jbetween" v-if="show_manager">
 			<u-checkbox-group placement="column">
-				<u-checkbox :checked="quanxuan" @change="selectall" activeColor="#57C3C2" shape="circle" :customStyle="{marginBottom: '8px'}" label="全选"></u-checkbox>
+				<u-checkbox :checked="quanxuan" @change="selectall" activeColor="#57C3C2" shape="circle"
+					:customStyle="{marginBottom: '8px'}" label="全选"></u-checkbox>
 			</u-checkbox-group>
 			<view class="btn">批量删除</view>
 		</view>
@@ -47,14 +62,13 @@
 	import $api from '@/static/js/api.js'
 	export default {
 		data() {
-			return{
+			return {
 				list: [],
 				page: 1,
 				last_page: 1,
-				current:0,
-				tabs: [
-					{
-						id: ' ',
+				current: 0,
+				tabs: [{
+						id: '',
 						name: '全部'
 					},
 					{
@@ -73,7 +87,7 @@
 						id: 'post',
 						name: '论坛'
 					},
-					
+
 				],
 				options: [{
 					text: '批量删除',
@@ -86,14 +100,13 @@
 				quanxuan: false
 			}
 		},
-		onLoad() {
-		},
+		onLoad() {},
 		onShow() {
 			this.list = []
 			this.getlist()
 		},
 		onReachBottom() {
-			if(this.page == this.last_page) {
+			if (this.page == this.last_page) {
 				uni.$u.toast('已经到底了')
 				return
 			} else {
@@ -102,13 +115,52 @@
 			}
 		},
 		methods: {
-			/* 全选 */
+
+			editItem(item) {
+				var that = this
+				let data = {}
+				if (item.source_type == 'post') {
+					data = item.source
+					uni.navigateTo({
+						url: '/pageA/add-luntan?data=' + encodeURIComponent(JSON.stringify(data)) + '&edit=1'
+					})
+				} else {
+					let topic = {
+						id: item.source.topic_id
+					}
+					data = {
+						id: item.source.id,
+						video_title: item.source.video_title ? item.source.video_title : '',
+						video_url: item.source.video_url ? item.source.video_url : '',
+						title: item.source.title ? item.source.title : '',
+						content: item.source.content ? item.source.content : '',
+						topic: topic,
+						image: item.source.image ? item.source.image : ''
+					}
+					uni.navigateTo({
+						url: '/pageA/add-wenzhang?data=' + encodeURIComponent(JSON.stringify(data)) + '&type=' +item.source_type + '&edit=1'
+					})
+				}
+
+			},
+			delItem(item) {
+				var that = this
+				$api.req({
+					url: item.source_type + '/' + item.source_id,
+					method: 'DELETE'
+				}, function(res) {
+					$api.info(res.msg)
+					that.page = 1
+					that.list = []
+					that.getlist()
+				})
+			},
 			selectall() {
 				this.quanxuan = !this.quanxuan
 				console.log(this.quanxuan);
-				if(this.quanxuan) {
+				if (this.quanxuan) {
 					this.select_all = []
-					for(var i=0;i<this.list.length;i++) {
+					for (var i = 0; i < this.list.length; i++) {
 						this.select_all.push(this.list[i].id)
 					}
 				} else {
@@ -116,19 +168,14 @@
 				}
 				console.log(this.select_all);
 			},
-			/* 选择 */
 			selectitem(e) {
 				this.select_all = e
-				if(this.select_all.length == this.list.length) {
+				if (this.select_all.length == this.list.length) {
 					this.quanxuan = true
 				} else {
 					this.quanxuan = false
 				}
 			},
-			/* 取消收藏 */
-			tocancel(item) {
-			},
-			/* 切换tab */
 			changetabs(e) {
 				this.current = e.index
 				this.select_all = []
@@ -148,7 +195,7 @@
 						limit: 10,
 					}
 				}, function(res) {
-					if(res.code == 10000) {
+					if (res.code == 10000) {
 						_this.list = _this.list.concat(res.data.list)
 						_this.last_page = res.data.last_page
 					}
@@ -162,15 +209,17 @@
 	.content::v-deep {
 		background: #FFFFFF;
 		position: relative;
+
 		.bottom {
 			position: fixed;
 			bottom: 0;
 			width: 750rpx;
 			height: 166rpx;
 			background: #FFFFFF;
-			padding: 12rpx 28rpx 80rpx; 
+			padding: 12rpx 28rpx 80rpx;
 			box-sizing: border-box;
 			z-index: 29;
+
 			.btn {
 				width: 184rpx;
 				height: 72rpx;
@@ -184,19 +233,25 @@
 				text-align: center;
 			}
 		}
-		.list{
+
+		.list {
 			width: 100%;
 			box-sizing: border-box;
 			padding: 28rpx 28rpx;
+
 			.list-item {
 				margin: 0 0 32rpx;
+
 				image {
 					width: 200rpx;
 					height: 128rpx;
 					border-radius: 6rpx;
 					margin: 0 20rpx 0 0;
 				}
+
 				.img-right {
+					width: calc(100% - 220rpx);
+
 					.name {
 						max-width: 452rpx;
 						font-size: 28rpx;
@@ -205,18 +260,21 @@
 						color: #333333;
 						padding: 0 0 14rpx;
 					}
+
 					.num {
 						font-size: 20rpx;
 						font-family: SFPro, SFPro;
 						font-weight: 400;
 						color: #666666;
 					}
+
 					.price {
 						font-size: 28rpx;
 						font-family: JDZhengHT, JDZhengHT;
 						font-weight: 400;
 						color: #FF3333;
 					}
+
 					.btns {
 						text:first-child {
 							width: 96rpx;
@@ -230,6 +288,7 @@
 							line-height: 48rpx;
 							text-align: center;
 						}
+
 						text:last-child {
 							width: 96rpx;
 							height: 48rpx;
@@ -245,16 +304,19 @@
 						}
 					}
 				}
+
 				.u-checkbox {
 					margin: 0 32rpx 0 0;
 				}
 			}
 		}
+
 		.tabs {
 			width: 100%;
 			padding: 18rpx 0;
 			border-bottom: 2rpx solid #F5F5F5;
 		}
+
 		.u-nav-slot {
 			text {
 				font-size: 28rpx;

+ 49 - 11
pageC/edit-pwd.vue

@@ -2,40 +2,74 @@
 	<view class="content">
 		<view class="form">
 			<view class="item hflex acneter jbetween">
+				<text>原密码</text>
+				<u-input :password="show_pwd2" v-model="old_pwd" placeholder="请输入原密码" border="none" :clearable="true">
+					<template slot="suffix">
+						<image class="icon" src="static/open.png" mode="aspectFill" v-if="!show_pwd2"
+							@click="show_pwd2 = true"></image>
+						<image class="icon" src="static/close.png" mode="aspectFill" v-else @click="show_pwd2 = false">
+						</image>
+					</template>
+				</u-input>
+			</view>
+			<view class="item hflex acneter jbetween">
 				<text>新密码</text>
 				<u-input :password="show_pwd" v-model="pwd" placeholder="请输入新密码" border="none" :clearable="true">
 					<template slot="suffix">
-						<image class="icon" src="static/open.png" mode="aspectFill" v-if="!show_pwd" @click="show_pwd = true"></image>
-						<image class="icon" src="static/close.png" mode="aspectFill" v-else @click="show_pwd = false"></image>
+						<image class="icon" src="static/open.png" mode="aspectFill" v-if="!show_pwd"
+							@click="show_pwd = true"></image>
+						<image class="icon" src="static/close.png" mode="aspectFill" v-else @click="show_pwd = false">
+						</image>
 					</template>
 				</u-input>
 			</view>
 			<view class="item hflex acneter jbetween">
 				<text>确认新密码</text>
-				<u-input  :password="show_pwd1" v-model="new_pwd" placeholder="请输入新密码" border="none" :clearable="true">
+				<u-input :password="show_pwd1" v-model="new_pwd" placeholder="请输入新密码" border="none" :clearable="true">
 					<template slot="suffix">
-						<image class="icon" src="static/open.png" mode="aspectFill" v-if="!show_pwd1" @click="show_pwd1 = true"></image>
-						<image class="icon" src="static/close.png" mode="aspectFill" v-else @click="show_pwd1 = false"></image>
+						<image class="icon" src="static/open.png" mode="aspectFill" v-if="!show_pwd1"
+							@click="show_pwd1 = true"></image>
+						<image class="icon" src="static/close.png" mode="aspectFill" v-else @click="show_pwd1 = false">
+						</image>
 					</template>
 				</u-input>
 			</view>
 		</view>
-		<view class="btn" :class="pwd&&new_pwd ? 'btn-sure' : ''">确定</view>
+		<view class="btn" :class="pwd&&new_pwd ? 'btn-sure' : ''" @click="toedit">确定</view>
 	</view>
 </template>
 
 <script>
+	import $api from '@/static/js/api.js'
 	export default {
 		data() {
 			return {
 				pwd: '',
 				new_pwd: '',
+				old_pwd: '',
 				show_pwd: true,
-				show_pwd1: true
+				show_pwd1: true,
+				show_pwd2: false
 			}
 		},
 		methods: {
-			
+			toedit() {
+				var that = this
+				$api.req({
+					url: 'user/change-password',
+					method: 'post',
+					data: {
+						old_password: that.old_pwd,
+						password: that.pwd,
+						password_confirmation: that.new_pwd
+					}
+				}, function(res) {
+					if (res.code == 10000) {
+						$api.info('修改成功')
+					}
+				})
+			}
+
 		}
 	}
 </script>
@@ -43,10 +77,11 @@
 <style lang="scss">
 	.content {
 		background: #FFFFFF;
-		
+
 		.btn-sure {
 			opacity: 1 !important;
 		}
+
 		.btn {
 			width: 694rpx;
 			height: 88rpx;
@@ -61,12 +96,15 @@
 			text-align: center;
 			margin: 154rpx auto 0;
 		}
+
 		.form {
 			padding: 0 28rpx;
 			border-top: 1px solid #F5f5f5;
+
 			.item {
 				padding: 32rpx 0;
 				border-bottom: 1px solid #F5f5f5;
+
 				text {
 					font-size: 32rpx;
 					font-family: PingFangSC, PingFang SC;
@@ -74,6 +112,7 @@
 					color: #333333;
 					width: 200rpx;
 				}
+
 				.icon {
 					width: 36rpx;
 					height: 36rpx;
@@ -81,5 +120,4 @@
 			}
 		}
 	}
-
-</style>
+</style>

+ 56 - 9
pageC/error.vue

@@ -1,23 +1,25 @@
 <template>
 	<view class="content">
 		<view class="area">
-			<u-textarea v-model="detail" placeholder="请输入您要反馈的内容" count height="300" maxlength="200" border="none"></u-textarea>
+			<u-textarea v-model="detail" placeholder="请输入您要反馈的内容" count height="300" maxlength="200"
+				border="none"></u-textarea>
 		</view>
 		<view class="upload hflex acenter fwrap">
 			<view class="imgs" v-for="(item,index) in imglist" :key="index">
 				<image :src="item" mode="aspectFill"></image>
 			</view>
-			<view class="upload-bg hflex acenter jcenter" >
+			<view class="upload-bg hflex acenter jcenter" @click="uploadImg">
 				<image src="static/upload-img.png" mode="aspectFill"></image>
 			</view>
 			<text>添加图片(选填)</text>
 		</view>
-		<view class="btn" :class="detail ? 'btn-sure' : ''">提交反馈</view>
+		<view class="btn" :class="detail ? 'btn-sure' : ''" @click="sumbit">提交反馈</view>
 	</view>
 </template>
 
 <script>
 	import $api from '@/static/js/api.js'
+	var that = ''
 	export default {
 		data() {
 			return {
@@ -26,19 +28,55 @@
 			}
 		},
 		onLoad() {
-			
+			that = this
 		},
 		onShow() {
-			
+
 		},
 		onPullDownRefresh() {
-			
+
 		},
 		onReachBottom() {
-			
+
 		},
 		methods: {
-			
+			uploadImg() {
+				uni.chooseImage({
+					count: 1,
+					success: (chooseImageRes) => {
+						uni.showLoading({
+							title: '上传中...'
+						})
+						const tempFilePaths = chooseImageRes.tempFilePaths;
+						uni.uploadFile({
+							url: $api.config.baseUrl + 'upload/image', //仅为示例,非真实的接口地址
+							filePath: tempFilePaths[0],
+							name: 'image',
+							success: (uploadFileRes) => {
+
+								let res = JSON.parse(uploadFileRes.data)
+								this.imglist.push(res.data.url)
+								uni.hideLoading()
+							}
+						});
+					}
+				});
+			},
+			sumbit() {
+				$api.req({
+					url: 'feedback',
+					method: 'POST',
+					data: {
+						content: that.detail,
+						images: that.imglist
+					}
+				}, function(res) {
+					$api.info(res.msg)
+					uni.switchTab({
+						url: '/pages/mine/index'
+					})
+				})
+			},
 		}
 	}
 </script>
@@ -48,9 +86,11 @@
 		background: #FFFFFF;
 		border-top: 1px solid #f5f5f5;
 		padding: 0 28rpx;
+
 		.btn-sure {
 			opacity: 1 !important;
 		}
+
 		.btn {
 			width: 702rpx;
 			height: 88rpx;
@@ -64,8 +104,10 @@
 			color: #FFFFFF;
 			line-height: 88rpx;
 		}
+
 		.upload {
 			padding: 46rpx 0 86rpx;
+
 			.imgs {
 				image {
 					width: 112rpx;
@@ -73,16 +115,19 @@
 					margin: 0 16rpx 16rpx 0;
 				}
 			}
+
 			.upload-bg {
 				width: 112rpx;
 				height: 112rpx;
 				background: rgba(231, 231, 231, .6);
 				border-radius: 12rpx;
+
 				image {
 					width: 64rpx;
 					height: 64rpx;
 				}
 			}
+
 			text {
 				font-size: 24rpx;
 				font-family: PingFangSC, PingFang SC;
@@ -91,14 +136,16 @@
 				padding: 0 0 0 32rpx;
 			}
 		}
+
 		.area {
 			padding: 44rpx 0 28rpx;
 			width: 100%;
 			box-sizing: border-box;
 			border-bottom: 1px solid rgba(151, 151, 151, .1);
+
 			.u-textarea {
 				padding: 0;
 			}
 		}
 	}
-</style>
+</style>

+ 40 - 13
pageC/guanzhu-list.vue

@@ -3,25 +3,25 @@
 		<u-cell-group :border="false" v-if="list.length > 0">
 			<u-cell size="large" v-for="(item,index) in list" :key="index">
 				<view slot="title" class="u-slot-title hflex acenter">
-					<image :src="item.avatar" mode="aspectFill"></image>
+					<image :src="item.avatar" mode="aspectFill" @click="touser(item)"></image>
 					<view class="img-right vflex jbetween">
-						<text>{{item.name}}</text>
-						<text v-if="item.text">{{item.text}}</text>
+						<text>{{item.username}}</text>
+						<text v-if="item.introduction">{{item.introduction}}</text>
 					</view>
 				</view>
 				<view slot="value" class="u-slot-value" v-if="type == '1'">
-					<view class="btn">已关注</view>
+					<view class="btn" @click="follow(item)">已关注</view>
 				</view>
 				<view slot="value" class="u-slot-value" v-if="type == '2'">
 					<view class="btn" v-if="item.is_follow">互相关注</view>
-					<view class="add hflex acenter jcenter" v-else>
+					<view class="add hflex acenter jcenter" v-else @click="follow(item)">
 						<u-icon name="plus" color="#00B0B0" size="12"></u-icon>
 						<text>关注</text>
 					</view>
 				</view>
 			</u-cell>
 		</u-cell-group>
-		<view class="hflex acenter jcenter " style="height: 100vh;" v-else >
+		<view class="hflex acenter jcenter " style="height: 100vh;" v-else>
 			<u-empty mode="data"></u-empty>
 		</view>
 	</view>
@@ -42,7 +42,7 @@
 		onLoad(option) {
 			this.userid = uni.getStorageSync('userid')
 			this.type = option.type
-			if(this.type == '2') {
+			if (this.type == '2') {
 				uni.setNavigationBarTitle({
 					title: '被关注'
 				})
@@ -50,7 +50,7 @@
 			this.getlist()
 		},
 		onReachBottom() {
-			if(this.page < this.last_page) {
+			if (this.page < this.last_page) {
 				this.page++
 				this.getlist()
 			} else {
@@ -59,9 +59,28 @@
 			}
 		},
 		methods: {
+			touser(item) {
+				uni.navigateTo({
+					url: '/pageC/otherInfo?id=' + item.id
+				})
+			},
+			follow(item) {
+				var that = this
+				$api.req({
+					url: 'user/' + item.id + '/follow',
+					method: 'post'
+				}, function(res) {
+					$api.info(res.msg)
+					setTimeout(() => {
+						that.page = 1
+						that.list = []
+						that.getlist()
+					}, 1000)
+				})
+			},
 			getlist() {
 				var _this = this
-				if(_this.type == '1') {
+				if (_this.type == '1') {
 					$api.req({
 						url: 'user/follow',
 						data: {
@@ -70,7 +89,7 @@
 							limit: 10
 						}
 					}, function(res) {
-						if(res.code == 10000) {
+						if (res.code == 10000) {
 							_this.list = _this.list.concat(res.data.list)
 							_this.last_page = res.data.last_page
 						}
@@ -84,8 +103,8 @@
 							limit: 10
 						}
 					}, function(res) {
-						if(res.code == 10000) {
-							_this.list = _this.concat(res.data.list)
+						if (res.code == 10000) {
+							_this.list = _this.list.concat(res.data.list)
 							_this.last_page = res.data.last_page
 						}
 					})
@@ -98,29 +117,35 @@
 <style lang="scss">
 	.content::v-deep {
 		background: #FFFFFF;
+
 		.u-slot-title {
 			image {
 				width: 92rpx;
 				height: 92rpx;
 				border-radius: 50%;
 			}
+
 			.img-right {
 				padding-left: 20rpx;
+
 				text:first-child {
 					font-size: 32rpx;
 					font-family: PingFangSC, PingFang SC;
 					font-weight: 500;
 					color: #333333;
 				}
+
 				text:last-child {
 					font-size: 26rpx;
 					font-family: PingFangSC, PingFang SC;
 					font-weight: 400;
 					color: #999999;
 					padding-top: 12rpx;
+					max-width: 450rpx;
 				}
 			}
 		}
+
 		.u-slot-value {
 			.add {
 				width: 148rpx;
@@ -129,12 +154,14 @@
 				border-radius: 28rpx;
 				border: 2rpx solid #00B0B0;
 				font-size: 24rpx;
+
 				text {
 					font-weight: 400;
 					color: #00B0B0;
-					
+
 				}
 			}
+
 			.btn {
 				width: 148rpx;
 				height: 56rpx;

+ 22 - 3
pageC/invite-bind.vue

@@ -4,11 +4,12 @@
 			<text>邀请码</text>
 			<u-input v-model="code" border="none" placeholder="请填写邀请码" inputAlign="right"></u-input>
 		</view>
-		<view class="btn">确认</view>
+		<view class="btn" @click="sure">确认</view>
 	</view>
 </template>
 
 <script>
+	import $api from '@/static/js/api.js'
 	export default {
 		data() {
 			return {
@@ -16,7 +17,21 @@
 			}
 		},
 		methods: {
-			
+			sure() {
+				var that = this
+				$api.req({
+					url: 'user/bind-invite',
+					method: 'post',
+					data: {
+						invite_code: that.code
+					}
+				}, function(res) {
+					$api.info(res.msg)
+					setTimeout(() => {
+						uni.navigateBack()
+					}, 1000)
+				})
+			},
 		}
 	}
 </script>
@@ -24,6 +39,7 @@
 <style lang="scss">
 	.content::v-deep {
 		background: #FFFFFF;
+
 		.btn {
 			width: 702rpx;
 			height: 88rpx;
@@ -39,21 +55,24 @@
 			bottom: 62rpx;
 			left: 24rpx;
 		}
+
 		.top {
 			width: 100%;
 			box-sizing: border-box;
 			padding: 40rpx 28rpx;
 			border-top: 1px solid #F5F5F5;
 			border-bottom: 1px solid #F5F5F5;
+
 			text {
 				font-size: 32rpx;
 				font-family: PingFangSC, PingFang SC;
 				font-weight: 400;
 				color: #333333;
 			}
+
 			.u-input {
 				width: 550rpx;
 			}
 		}
 	}
-</style>
+</style>

+ 60 - 19
pageC/invite-list.vue

@@ -2,54 +2,84 @@
 	<view class="content">
 		<view class="top hflex acenter jbetween">
 			<text>邀请人</text>
-			<view class="name" v-if="user.invite">{{user.invite.name}}</view>
-			<text @click="tobind">{{user.invite ? '' : '绑定邀请人'}}</text>
+			<view class="name" v-if="user.invite_code">{{user.parent_username}}</view>
+			<text @click="tobind" v-else>绑定邀请人</text>
 		</view>
 		<view class="list">
 			<view class="title">我的邀请</view>
 			<view class="list-item hflex acenter jbetween" v-for="(item,index) in invite_list" :key="index">
 				<view class="hflex acenter user">
 					<image :src="item.avatar" mode="aspectFill"></image>
-					<text>{{item.name}}</text>
+					<text>{{item.username}}</text>
 				</view>
-				<view class="time">{{item.time}}</view>
+				<view class="time">{{item.created_at}}</view>
 			</view>
 		</view>
 	</view>
 </template>
 
 <script>
+	import $api from '@/static/js/api.js'
+	var that = ''
 	export default {
 		data() {
 			return {
-				user: {
-					
-				},
-				invite_list: []
+				user: {},
+				invite_list: [],
+				page: 1,
+				last_page: 1,
 			}
 		},
 		onLoad() {
+			that = this
+			
+		},
+		onShow() {
 			this.getuser()
+			this.page = 1
+			this.invite_list = []
 			this.getlist()
 		},
+		onReachBottom() {
+			if (this.page < this.last_page) {
+				this.page++
+				this.getlist()
+			} else {
+				uni.$u.toast('已经到底了')
+				return
+			}
+		},
 		methods: {
 			tobind() {
 				uni.navigateTo({
 					url: '/pageC/invite-bind'
 				})
 			},
-			getuser() {},
+			getuser() {
+				$api.req({
+					url: 'user/info',
+					method: 'GET'
+				}, function(res) {
+					if (res.code == 10000) {
+						that.user = res.data
+					}
+				})
+			},
 			getlist() {
-				for(var i=0;i<5;i++) {
-					var data = {
-						avatar: 'https://cdn.uviewui.com/uview/album/1.jpg',
-						name: '摄影爱好者',
-						time: '2023-10-30 ',
+				$api.req({
+					url: 'user/children',
+					method: 'get',
+					data: {
+						is_page: 1,
+						page: that.page,
+						limit: 10
 					}
-					this.invite_list.push(data)
-				}
+				}, function(res) {
+					that.invite_list = that.invite_list.concat(res.data.list)
+					that.last_page = res.data.last_page
+				})
 			}
-			
+
 		}
 	}
 </script>
@@ -57,12 +87,14 @@
 <style lang="scss">
 	.content {
 		background: #F5F5F5;
+
 		.top {
 			height: 124rpx;
 			box-sizing: border-box;
 			padding: 40rpx 28rpx;
 			background: #FFFFFF;
 			border-top: 1px solid #F5F5F5;
+
 			.name {
 				flex: 1;
 				font-size: 32rpx;
@@ -70,6 +102,7 @@
 				font-weight: 400;
 				color: #333333;
 			}
+
 			text:first-child {
 				padding-right: 16rpx;
 				font-size: 32rpx;
@@ -77,6 +110,7 @@
 				font-weight: 400;
 				color: #333333;
 			}
+
 			text:last-child {
 				font-size: 28rpx;
 				font-family: PingFangSC, PingFang SC;
@@ -84,12 +118,14 @@
 				color: #00B0B0;
 			}
 		}
+
 		.list {
 			margin-top: 20rpx;
 			min-height: calc(100vh - 144rpx);
 			background: #FFFFFF;
 			padding: 40rpx 28rpx;
 			box-sizing: border-box;
+
 			.title {
 				font-size: 32rpx;
 				font-family: PingFangSC, PingFang SC;
@@ -97,16 +133,19 @@
 				color: #333333;
 				padding: 0 0 10rpx;
 			}
+
 			.list-item {
 				padding: 32rpx 0;
 				border-bottom: 1px solid #F5F5F5;
+
 				.user {
 					image {
 						width: 80rpx;
 						height: 80rpx;
 						border-radius: 50%;
-						margin: 0 28rpx 0 0; 
+						margin: 0 28rpx 0 0;
 					}
+
 					text {
 						font-size: 32rpx;
 						font-family: PingFangSC, PingFang SC;
@@ -114,6 +153,7 @@
 						color: #333333;
 					}
 				}
+
 				.time {
 					font-size: 28rpx;
 					font-family: SFPro, SFPro;
@@ -121,9 +161,10 @@
 					color: #666666;
 				}
 			}
+
 			.list-item:last-child {
 				border: none
 			}
 		}
 	}
-</style>
+</style>

+ 87 - 20
pageC/invite.vue

@@ -1,69 +1,115 @@
 <template>
 	<view class="content">
-		<u-navbar title="邀请好友" @leftClick="leftClick" bgColor="rgba(0,0,0,0)" placeholder safeAreaInsetTop></u-navbar>
+		<u-navbar title="邀请好友" @leftClick="leftClick" :bgColor="bgColor" placeholder safeAreaInsetTop></u-navbar>
 		<view class="title">邀请好友加入忆象</view>
 		<view class="box vflex acenter jcenter">
 			<view class="user hflex acenter">
 				<image :src="user.avatar" mode="aspectFill"></image>
 				<view class="user-right vflex jbetween">
-					<text>{{user.name}}</text>
+					<text>{{user.username}}</text>
 					<text>分享邀请码或者链接给好友</text>
 				</view>
 			</view>
 			<view class="code-text vflex acenter">
 				<view class="hflex acenter jcenter">
 					<view class="text">邀请码</view>
-					<view class="text">{{user.code}}</view>
+					<view class="text">{{user.invite_code}}</view>
 				</view>
 				<view class="copy" @click="copy">复制邀请码</view>
 			</view>
 			<view class="img-box hflex acenter jcenter">
-				<yz-qr :qrPath.sync="qrPath" :text="text" :size="200" quality="L" colorDark="#000000"
+				<yz-qr :qrPath.sync="qrPath" :text="user.invite_code" :size="200" quality="L" colorDark="#000000"
 					colorLight="#ffffff"></yz-qr>
 			</view>
 		</view>
 		<view class="bottom hflex acenter jbetween">
 			<button class="save" @click="setimg">保存图片</button>
-			<button class="invite">邀请好友</button>
+			<button class="invite" @click="share">邀请好友</button>
 		</view>
+		<view class="poster-pop" v-if="posterImageStatus">
+			<image :src="posterImage"></image>
+		</view>
+		<view class="mask" v-if="posterImageStatus"></view>
+		<canvas class="canvas" canvas-id="myCanvas" v-if="canvasStatus"></canvas>
 	</view>
 </template>
 
 <script>
+	import $api from '@/static/js/api.js'
+	var that = ''
 	export default {
 		data() {
-			return{
+			return {
 				user: {},
 				qrPath: '',
 				text: 'hello',
+				posterImage: '',
+				posterImageStatus: false,
+				canvasStatus: false,
+				bgColor: 'rgba(0, 0, 0, 0)'
 			}
 		},
 		onLoad() {
+			that = this
 			this.getuser()
 		},
+		onPageScroll(e) {
+			console.log(e);
+			if (e.scrollTop > 0) {
+				this.bgColor = 'rgba(255,255,255)'
+			} else {
+				this.bgColor = 'rgba(0, 0, 0, 0)'
+			}
+		},
 		watch: {
 			qrPath(newVal, oldVal) {
 				return this.qrPath;
 			}
 		},
 		methods: {
-			
-			setimg() {},
+			share() {
+				// this.goPoster();
+				uni.share({
+					provider: "weixin",
+					scene: "WXSceneSession",
+					type: 2,
+					imageUrl: this.qrPath,
+					success: function (res) {
+						console.log("success:" + JSON.stringify(res));
+					},
+					fail: function (err) {
+						console.log("fail:" + JSON.stringify(err));
+					}
+				});
+			},
+			setimg() {
+				uni.saveImageToPhotosAlbum({
+					filePath: this.qrPath,
+					success: function () {
+						console.log('save success');
+					$api.info('保存成功')
+					}
+				});
+			},
+			goPoster() {
+
+			},
 			copy() {
 				uni.setClipboardData({
-					data: this.user.code,
-					success: function () {
+					data: this.user.invite_code,
+					success: function() {
 						this.$u.toasta('复制成功')
 					}
 				})
 			},
 			getuser() {
-				this.user = {
-					code: 'FGUOSK',
-					avatar: 'https://cdn.uviewui.com/uview/album/1.jpg',
-					name: 'David Smion',
-					code_img: 'https://cdn.uviewui.com/uview/album/1.jpg'
-				}
+				$api.req({
+					url: 'user/info',
+				}, function(res) {
+					if (res.code == 10000) {
+						that.user = res.data
+					}
+				})
 			},
 			leftClick() {
 				uni.navigateBack()
@@ -78,6 +124,11 @@
 		min-height: 100vh;
 		background-size: 100% 100%;
 		padding: 42rpx 34rpx;
+
+		.u-navbar--fixed {
+			z-index: 999;
+		}
+
 		.title {
 			width: 100%;
 			text-align: center;
@@ -85,30 +136,36 @@
 			font-family: PingFangSC, PingFang SC;
 			font-weight: 600;
 			color: #222222;
-			padding: 60rpx 0 38rpx;
+			padding: 88rpx 0 38rpx;
 		}
+
 		.box {
 			background: #FFFFFF;
 			border-radius: 20rpx;
 			box-sizing: border-box;
 			width: 100%;
 			padding: 48rpx 30rpx;
+
 			.user {
 				width: 100%;
+
 				image {
 					width: 92rpx;
 					height: 92rpx;
 					border-radius: 50%;
 				}
+
 				.user-right {
 					padding: 0 0 0 20rpx;
 					height: 92rpx;
+
 					text:first-child {
 						font-size: 32rpx;
 						font-family: SFPro, SFPro;
 						font-weight: 500;
 						color: #222222;
 					}
+
 					text:last-child {
 						font-size: 24rpx;
 						font-family: PingFangSC, PingFang SC;
@@ -116,14 +173,16 @@
 						color: #222222;
 					}
 				}
-				
+
 			}
+
 			.code-text {
 				width: 602rpx;
 				background: #F4F4F4;
 				border-radius: 12rpx;
 				padding: 40rpx 0;
 				margin: 36rpx 0 68rpx;
+
 				.text {
 					font-size: 36rpx;
 					font-family: PingFangSC, PingFang SC;
@@ -131,10 +190,12 @@
 					color: #222222;
 					padding: 0 48rpx 0 0;
 				}
+
 				.text:nth-child(2) {
 					padding: 0 0 0 48rpx;
 					border-left: 1px solid #E0E0E0;
 				}
+
 				.copy {
 					padding: 32rpx 0 0;
 					font-size: 24rpx;
@@ -142,23 +203,27 @@
 					font-weight: 400;
 					color: #0C66C2;
 				}
-				
+
 			}
+
 			.img-box {
 				width: 526rpx;
 				height: 526rpx;
 				background: url('static/code_bg.png') no-repeat;
 				background-size: 100% 100%;
 				margin: 0 0 34rpx;
+
 				image {
 					width: 422rpx;
 					height: 422rpx;
 				}
 			}
 		}
+
 		.bottom {
-			
+
 			padding: 28rpx 0 60rpx;
+
 			.save {
 				width: 296rpx;
 				height: 96rpx;
@@ -171,6 +236,7 @@
 				padding: 0;
 				line-height: 96rpx;
 			}
+
 			.invite {
 				width: 352rpx;
 				height: 96rpx;
@@ -184,6 +250,7 @@
 				line-height: 96rpx;
 			}
 		}
+
 		.u-navbar {
 			position: fixed;
 			top: 0;

+ 74 - 17
pageC/jianli.vue

@@ -15,50 +15,93 @@
 			</view>
 			<view class="item vflex" style="border: none;">
 				<view class="label">上传简历</view>
-				<view class="upload hflex acenter jcenter">
+				<view class="upload hflex acenter jcenter" @click="toupload">
 					<image src="static/upload.png" mode="aspectFill"></image>
 					<text>上传文件</text>
 				</view>
-				<view class="file hflex acenter" v-if="file">
+				<view class="file hflex acenter" v-if="resume">
 					<image src="static/lianjie.png" mode="aspectFill"></image>
-					<text>{{file}}</text>
+					<text>{{resume}}</text>
 				</view>
 			</view>
 		</view>
-		<view class="btn" :class="file && name && mobile ? 'btn-sure' : ''" @click="toupload">确认并上传</view>
+		<view class="btn" :class="resume && name && mobile ? 'btn-sure' : ''" @click="submit">确认并上传</view>
 	</view>
 </template>
 
 <script>
 	import $api from '@/static/js/api.js'
+	var that = ''
 	export default {
 		data() {
 			return {
-				file: 'asd',
+				resume: '',
 				name: '',
-				mobile: ''
+				mobile: '',
+				id: '',
 			}
 		},
-		onLoad() {
-			
+		onLoad(options) {
+			that = this
+			this.id = options.id
 		},
 		methods: {
-			toupload() {
-				if(!this.name) {
+			submit() {
+				if (!this.name) {
 					$api.info('请先输入您的姓名')
 					return
 				}
-				if(!this.mobile) {
+				if (!this.mobile) {
 					$api.info('请先输入您的联系方式')
 					return
 				}
-				if(!this.file) {
+				if (!this.file) {
 					$api.info('请先上传您的简历')
 					return
 				}
-				uni.redirectTo({
-					url: '/pageC/success'
+				$api.req({
+					url: 'job/' + that.id + '/delivery',
+					method: 'POST',
+					data: {
+						name: that.name,
+						mobile: that.mobile,
+						resume: that.resume
+					}
+				}, function(res) {
+					if (res.code == 10000) {
+						uni.redirectTo({
+							url: '/pageC/success'
+						})
+					}
 				})
+
+			},
+			toupload() {
+				var _this = this
+				uni.chooseFile({
+					count: 1, //默认100
+					extension: ['.doc', '.docx', '.pdf', '.xls'], //word、pdf、xls
+					success: function(res) {
+						uni.showLoading({
+							title: '上传中'
+						})
+						console.log(JSON.stringify(res.tempFilePaths));
+						let resume = JSON.stringify(res.tempFilePaths)
+						uni.uploadFile({
+							url: $api.config.baseUrl + 'upload/file', //仅为示例,非真实的接口地址
+							filePath: resume,
+							name: 'file',
+							formData: {
+								'user': 'test'
+							},
+							success: (uploadFileRes) => {
+								var data = JSON.parse(uploadFileRes.data)
+								_this.resume = data.data.url
+								uni.hideLoading()
+							}
+						});
+					}
+				});
 			},
 		}
 	}
@@ -67,33 +110,40 @@
 <style lang="scss">
 	.content::v-deep {
 		background: #FFFFFF;
+
 		.form {
 			padding: 0 28rpx;
+
 			.item {
 				padding: 28rpx 0;
 				border-bottom: 1px solid #F5F5F5;
+
 				.label {
 					font-size: 32rpx;
 					font-family: PingFangSC, PingFang SC;
 					font-weight: 400;
 					color: #333333;
 				}
+
 				.u-input {
 					max-width: 450rpx;
 				}
+
 				.file {
 					image {
 						width: 32rpx;
 						height: 32rpx;
 					}
+
 					text {
 						font-size: 28rpx;
 						font-family: PingFangSC, PingFang SC;
 						font-weight: 400;
-						color: rgba(0,0,0,0.85);
+						color: rgba(0, 0, 0, 0.85);
 						padding: 0 0 0 8rpx;
 					}
 				}
+
 				.upload {
 					background: #FFFFFF;
 					border-radius: 8rpx;
@@ -101,29 +151,34 @@
 					padding: 10rpx 32rpx;
 					max-width: max-content;
 					margin: 20rpx 0 16rpx;
+
 					image {
 						width: 28rpx;
 						height: 28rpx;
 					}
+
 					text {
 						font-size: 28rpx;
 						font-family: PingFangSC, PingFang SC;
 						font-weight: 400;
-						color: rgba(0,0,0,0.85);
+						color: rgba(0, 0, 0, 0.85);
 						padding: 0 0 0 16rpx;
 					}
 				}
 			}
 		}
+
 		.top {
 			width: 100%;
 			height: 60rpx;
 			background: #00B0B0;
+
 			image {
 				width: 28rpx;
 				height: 28rpx;
 				margin: 0 8rpx 0 0;
 			}
+
 			text {
 				font-size: 22rpx;
 				font-family: SFPro, SFPro;
@@ -131,9 +186,11 @@
 				color: #FFFFFF;
 			}
 		}
+
 		.btn-sure {
 			opacity: 1 !important;
 		}
+
 		.btn {
 			width: 702rpx;
 			height: 84rpx;
@@ -151,4 +208,4 @@
 			text-align: center;
 		}
 	}
-</style>
+</style>

+ 18 - 10
pageC/jifen-list.vue

@@ -3,13 +3,15 @@
 		<view class="list" v-if="list.length > 0">
 			<view class="list-item hflex acenter jbetween" v-for="(item,index) in list" :key="index">
 				<view class="item-left vflex">
-					<text>{{item.source_type_name}}</text>
+					<text>{{item.remark}}</text>
 					<text>{{item.created_at}}</text>
 				</view>
-				<view class="item-right">{{item.amount}}</view>
+				<view class="item-right" :class="item.amount > 0 ? '' : 'item-right2'">
+					{{item.amount > 0 ? '+' + item.amount : item.amount}}
+				</view>
 			</view>
 		</view>
-		<view class="hflex acenter jcenter " style="height: 100vh;" v-else >
+		<view class="hflex acenter jcenter " style="height: 100vh;" v-else>
 			<u-empty mode="data"></u-empty>
 		</view>
 	</view>
@@ -19,7 +21,7 @@
 	import $api from '@/static/js/api.js'
 	export default {
 		data() {
-			return{
+			return {
 				list: [],
 				page: 1,
 				last_page: 1
@@ -29,7 +31,7 @@
 			this.getlist()
 		},
 		onReachBottom() {
-			if(this.page < this.last_page) {
+			if (this.page < this.last_page) {
 				this.page++
 				this.getlist()
 			} else {
@@ -48,7 +50,7 @@
 						limit: 10,
 					}
 				}, function(res) {
-					if(res.code == 10000) {
+					if (res.code == 10000) {
 						_this.list = _this.list.concat(res.data.list)
 						_this.last_page = res.data.last_page
 					}
@@ -58,15 +60,18 @@
 	}
 </script>
 
-<style lang="scss"> 
+<style lang="scss">
 	.content {
 		min-height: 100vh;
 		background: #FFFFFF;
+
 		.list {
 			padding: 10rpx 28rpx;
+
 			.list-item {
 				padding: 22rpx 0;
 				border-bottom: 1px solid #F3F3F3;
+
 				.item-left {
 					text:first-child {
 						font-size: 32rpx;
@@ -74,28 +79,31 @@
 						font-weight: 400;
 						color: #222222;
 					}
+
 					text:last-child {
 						font-size: 24rpx;
 						font-family: SFPro, SFPro;
 						font-weight: 400;
 						color: #222222;
-						padding: 10rpx 0 0 ;
+						padding: 10rpx 0 0;
 					}
 				}
+
 				.item-right {
 					font-size: 36rpx;
 					font-family: JDZhengHT, JDZhengHT;
 					font-weight: 400;
 					color: #E02020;
 				}
+
 				.item-right2 {
 					font-size: 36rpx;
 					font-family: JDZhengHT, JDZhengHT;
 					font-weight: 400;
-					color: #B4B4B4;
+					color: #B4B4B4 !important;
 				}
 			}
-			
+
 		}
 	}
 </style>

+ 75 - 16
pageC/jifen-qianbao.vue

@@ -1,6 +1,7 @@
 <template>
 	<view class="content">
-		<u-navbar title="积分钱包" :autoBack="true" bgColor="rgba(0,0,0,0)" :fixed="true" :placeholder="true" @rightClick="torule">
+		<u-navbar title="积分钱包" :autoBack="true" bgColor="rgba(0,0,0,0)" :fixed="true" :placeholder="true"
+			@rightClick="torule">
 			<view class="u-nav-slot" slot="right">
 				<text>规则</text>
 			</view>
@@ -8,14 +9,14 @@
 		<image src="static/jifen-bg.png" mode="aspectFill" class="jinfen-bg"></image>
 		<view class="top hflex acenter">
 			<view class="top-item hflex aend fwrap" @click="tojifenlist">
-				<text>{{user.integral}}</text>
+				<text class="num">{{user.integral}}</text>
 				<view class="hflex acenter">
 					<text class="label">积分余额</text>
 					<u-icon name="arrow-right" color="#000000" size="12"></u-icon>
 				</view>
 			</view>
 			<view class="top-item hflex aend fwrap">
-				<text>{{user.integral_sum}}</text>
+				<text class="num">{{user.integral_sum}}</text>
 				<text class="label">积分总额</text>
 			</view>
 		</view>
@@ -31,7 +32,10 @@
 							<text>积分+{{item.integral}}</text>
 						</view>
 					</view>
-					<view class="btn" @click="totask(item)">{{ item.status == 'pending' ? '去完成': '领取奖励'}}</view>
+					<view class="btn" @click="totask(item)" v-if="item.status == 'pending'">去完成</view>
+					<view class="btn" @click="totask(item)" v-else-if="item.status == 'finished'">领取奖励</view>
+					<view class="btn" v-else-if="item.status == 'received'">已领取</view>
+
 				</view>
 			</view>
 		</view>
@@ -42,7 +46,7 @@
 	import $api from '@/static/js/api.js'
 	export default {
 		data() {
-			return{
+			return {
 				user: {},
 				list: [],
 				page: 1,
@@ -56,14 +60,48 @@
 		methods: {
 			totask(item) {
 				var _this = this
-				if(item.status == 'pending') {
-					
+				if (item.status == 'pending') {
+					if (item.source_type == 'share_post') {
+						uni.navigateTo({
+							url: '/pageA/jingxuan-list?type=article'
+						})
+					} else if (item.source_type == 'invite') {
+						uni.navigateTo({
+							url: '/pageC/invite'
+						})
+					} else if (item.source_type == 'create_post') {
+						uni.navigateTo({
+							url: '/pageA/add-luntan'
+						})
+					} else if (item.source_type == 'browse') {
+						uni.switchTab({
+							url: '/pages/luntan/index'
+						})
+					} else if (item.source_type == 'like') {
+						uni.switchTab({
+							url: '/pages/index/index'
+						})
+					} else if (item.source_type == 'vip') {
+						uni.navigateTo({
+							url: '/pageC/vip'
+						})
+					} else if (item.source_type == 'finish_info') {
+						uni.navigateTo({
+							url: '/pageC/userinfo'
+						})
+					}
+
 				} else {
 					$api.req({
-						url: 'task/' + item.id +'/receive'
+						url: 'task/' + item.id + '/receive',
+						method: 'post'
 					}, function(res) {
-						if(res.code == 10000) {
+						if (res.code == 10000) {
 							uni.$u.toast(res.msg)
+							setTimeout(() => {
+								_this.list = []
+								_this.getlist()
+							})
 						}
 					})
 				}
@@ -76,7 +114,7 @@
 						is_page: 0,
 					}
 				}, function(res) {
-					if(res.code == 10000) {
+					if (res.code == 10000) {
 						_this.list = res.data
 					}
 				})
@@ -97,7 +135,7 @@
 					url: 'user/info',
 					method: 'GET'
 				}, function(res) {
-					if(res.code == 10000) {
+					if (res.code == 10000) {
 						_this.user = res.data
 					}
 				})
@@ -107,9 +145,14 @@
 </script>
 
 <style lang="scss">
-	.content {
+	.content::v-deep {
 		min-height: 100vh;
 		background: unset;
+
+		.u-navbar__content__title {
+			font-weight: bold;
+		}
+
 		.jinfen-bg {
 			position: absolute;
 			top: 0;
@@ -118,11 +161,13 @@
 			height: 500rpx;
 			z-index: -1;
 		}
+
 		.box-bg {
 			background: #f5f5f5;
 			margin-top: 200rpx;
 			height: calc(100vh - 500rpx);
 			position: relative;
+
 			.box {
 				position: absolute;
 				top: -142rpx;
@@ -133,34 +178,42 @@
 				border-radius: 16rpx;
 				box-sizing: border-box;
 				padding: 28rpx 24rpx;
+
 				.title {
 					font-size: 32rpx;
 					font-family: PingFangSC, PingFang SC;
 					font-weight: 500;
 					color: #222222;
 				}
+
 				.cell {
 					margin: 32rpx 0 0;
+
 					image {
 						width: 100rpx;
 						height: 100rpx;
 						margin-right: 24rpx;
 					}
+
 					.cell-center {
 						flex: 1;
+
 						.name {
 							font-size: 32rpx;
 							font-family: PingFangSC, PingFang SC;
 							font-weight: 400;
 							color: #333333;
 						}
+
 						.center-bottom {
-							padding: 10rpx 0 0 ;
+							padding: 10rpx 0 0;
+
 							image {
 								width: 28rpx;
 								height: 28rpx;
 								margin: 0;
 							}
+
 							text {
 								padding-left: 8rpx;
 								font-size: 22rpx;
@@ -170,6 +223,7 @@
 							}
 						}
 					}
+
 					.btn {
 						margin: 0 0 0 24rpx;
 						width: 140rpx;
@@ -183,21 +237,25 @@
 						line-height: 56rpx;
 						text-align: center;
 					}
-					
+
 				}
 			}
 		}
+
 		.top {
-			padding: 84rpx 18rpx 50rpx; 
+			padding: 84rpx 18rpx 50rpx;
+
 			.top-item {
 				padding-right: 62rpx;
-				text {
+
+				.num {
 					font-size: 56rpx;
 					font-family: JDZhengHT, JDZhengHT;
 					font-weight: 400;
 					color: #00B0B0;
 					// line-height: 66rpx;
 				}
+
 				.label {
 					font-size: 24rpx;
 					font-family: PingFangSC, PingFang SC;
@@ -207,6 +265,7 @@
 				}
 			}
 		}
+
 		.u-nav-slot {
 			text {
 				font-size: 28rpx;

+ 26 - 19
pageC/paihang.vue

@@ -1,12 +1,10 @@
 <template>
 	<view class="content">
 		<view class="tabs">
-			<u-tabs :list="tabs" :scrollable="false" @click="tochangetab" lineWidth="0" :current="current"
-					:activeStyle="{
+			<u-tabs :list="tabs" :scrollable="false" @click="tochangetab" lineWidth="0" :current="current" :activeStyle="{
 			            color: '#00B0B0',
 			            fontWeight: 'bold'
-			        }"
-			        :inactiveStyle="{
+			        }" :inactiveStyle="{
 			            color: '#999999',
 			        }"></u-tabs>
 		</view>
@@ -27,9 +25,12 @@
 					<image src="/static/images/zuozhe3.png" class="img1" mode="aspectFill" v-if="index == 2"></image>
 				</view>
 				<view class="item-right" v-if="current == 1">
-					<image src="/static/images/dianzan-paihang1.png" class="img1" mode="aspectFill" v-if="index == 0"></image>
-					<image src="/static/images/dianzan-paihang2.png" class="img1" mode="aspectFill" v-if="index == 1"></image>
-					<image src="/static/images/dianzan-paihang3.png" class="img1" mode="aspectFill" v-if="index == 2"></image>
+					<image src="/static/images/dianzan-paihang1.png" class="img1" mode="aspectFill" v-if="index == 0">
+					</image>
+					<image src="/static/images/dianzan-paihang2.png" class="img1" mode="aspectFill" v-if="index == 1">
+					</image>
+					<image src="/static/images/dianzan-paihang3.png" class="img1" mode="aspectFill" v-if="index == 2">
+					</image>
 				</view>
 				<view class="item-right" v-if="current == 2">
 					<image src="/static/images/jifen1.png" class="img2" mode="aspectFill" v-if="index == 0"></image>
@@ -49,8 +50,7 @@
 	export default {
 		data() {
 			return {
-				tabs: [
-					{
+				tabs: [{
 						id: 'boutique',
 						name: '精品贴排行',
 					},
@@ -73,13 +73,13 @@
 			this.getlist()
 		},
 		onShow() {
-			
+
 		},
 		onPullDownRefresh() {
-			
+
 		},
 		onReachBottom() {
-			if(this.page == this.last_page) {
+			if (this.page == this.last_page) {
 				uni.$u.toast('已经到底了')
 				return
 			} else {
@@ -94,13 +94,13 @@
 					url: 'user/rank',
 					method: 'GET',
 					data: {
+						is_page: 1,
 						type: _this.tabs[_this.current].id,
 						page: _this.page,
 						limit: 10,
-						is_page: 1
 					}
 				}, function(res) {
-					if(res.code == 10000) {
+					if (res.code == 10000) {
 						_this.list = _this.list.concat(res.data.list)
 						_this.last_page = res.data.last_page
 					}
@@ -119,24 +119,27 @@
 <style lang="scss">
 	.content {
 		background: #FFFFFF;
-		.tabs {
-			
-		}
+
+		.tabs {}
+
 		.list {
 			.list-item {
 				padding: 32rpx 28rpx;
 				box-sizing: border-box;
 				width: 100%;
+
 				.item-right {
 					.img1 {
 						width: 188rpx;
 						height: 52rpx;
-						
+
 					}
+
 					.img2 {
 						width: 60rpx;
 						height: 38rpx;
 					}
+
 					text {
 						font-size: 32rpx;
 						font-family: SFPro, SFPro;
@@ -144,6 +147,7 @@
 						color: #666666;
 					}
 				}
+
 				.user {
 					image {
 						width: 100rpx;
@@ -151,14 +155,17 @@
 						border-radius: 50%;
 						margin-right: 20rpx;
 					}
+
 					.name {
 						max-width: 384rpx;
+
 						text:first-child {
 							font-size: 32rpx;
 							font-family: PingFangSC, PingFang SC;
 							font-weight: 500;
 							color: #333333;
 						}
+
 						text:last-child {
 							font-size: 24rpx;
 							font-family: PingFangSC, PingFang SC;
@@ -171,4 +178,4 @@
 			}
 		}
 	}
-</style>
+</style>

+ 11 - 13
pageC/setting.vue

@@ -9,8 +9,8 @@
 			<u-cell size="large" title="个人信息收集清单" :isLink="true" @click="toxieyi('geren')"></u-cell>
 			<u-cell size="large" title="开源软件声明" :isLink="true" @click="toxieyi('shengming')"></u-cell>
 			<u-cell size="large" title="错误反馈" :isLink="true" @click="toerror"></u-cell>
-			<u-cell size="large" title="清除缓存" :isLink="true"></u-cell>
-			<u-cell size="large" title="软件更新" value="4.16.1" :isLink="false"></u-cell>
+			<u-cell size="large" title="清除缓存" :isLink="true" @click="toclean"></u-cell>
+			<u-cell size="large" title="软件更新" :value="version" :isLink="false"></u-cell>
 			<u-cell size="large" title="关于忆象" :isLink="true" @click="toabout"></u-cell>
 		</u-cell-group>
 		<view class="btn" @click="exit">
@@ -24,28 +24,27 @@
 	export default {
 		data() {
 			return {
-				
+				version: ''
 			}
 		},
 		onLoad() {
-			
+			this.version = plus.runtime.version;
 		},
 		methods: {
-			/* 退出登录 */
 			exit() {
 				uni.showModal({
 					title: '提示',
 					content: '是否确定退出登录',
-					success: function (res) {
+					success: function(res) {
 						if (res.confirm) {
 							uni.removeStorageSync('token')
 							uni.removeStorageSync('userid')
 							uni.$u.toast('您已退出登录');
-							uni.navigateTo({
+							uni.reLaunch({
 								url: '/pages/login/index'
 							})
 						} else if (res.cancel) {
-							
+
 						}
 					}
 				});
@@ -55,31 +54,29 @@
 					url: '/pageC/xieyi?type=' + type
 				})
 			},
-			/* 推送通知 */
+			toclean() {
+				uni.clearStorageSync();
+			},
 			totuisong() {
 				uni.navigateTo({
 					url: '/pageC/tuisong'
 				})
 			},
-			/* 关于我们 */
 			toabout() {
 				uni.navigateTo({
 					url: '/pageC/about'
 				})
 			},
-			/* 错误反馈 */
 			toerror() {
 				uni.navigateTo({
 					url: '/pageC/error'
 				})
 			},
-			/* 账号安全 */
 			toaccount() {
 				uni.navigateTo({
 					url: '/pageC/account'
 				})
 			},
-			/* 邀请与推广 */
 			toinvite() {
 				uni.navigateTo({
 					url: '/pageC/invite-list'
@@ -93,6 +90,7 @@
 	.content {
 		background: #FFFFFF;
 		padding: 0 24rpx;
+
 		.btn {
 			width: 702rpx;
 			height: 88rpx;

+ 78 - 48
pageC/tuisong.vue

@@ -17,7 +17,8 @@
 		</view>
 		<view class="box">
 			<view class="title">谁能给我点赞</view>
- 			<view class="item hflex acenter jbetween" v-for="(item,index) in dianzan_list" :key="index" @click="dianzanselect(index)">
+			<view class="item hflex acenter jbetween" v-for="(item,index) in list" :key="index"
+				@click="dianzanselect(index)">
 				<text>{{item.name}}</text>
 				<image src="static/select.png" mode="aspectFill" v-if="dianzan_active != index"></image>
 				<image src="static/select_active.png" mode="aspectFill" v-else></image>
@@ -25,7 +26,8 @@
 		</view>
 		<view class="box">
 			<view class="title">谁能收藏我的内容</view>
-			<view class="item hflex acenter jbetween" v-for="(item,index) in collect_list" :key="index" @click="collectselect(index)">
+			<view class="item hflex acenter jbetween" v-for="(item,index) in list" :key="index"
+				@click="collectselect(index)">
 				<text>{{item.name}}</text>
 				<image src="static/select.png" mode="aspectFill" v-if="collect_active != index"></image>
 				<image src="static/select_active.png" mode="aspectFill" v-else></image>
@@ -33,7 +35,8 @@
 		</view>
 		<view class="box">
 			<view class="title">谁能评论回复我</view>
-			<view class="item hflex acenter jbetween" v-for="(item,index) in pinglun_list" :key="index" @click="pinglunselect(index)">
+			<view class="item hflex acenter jbetween" v-for="(item,index) in list" :key="index"
+				@click="pinglunselect(index)">
 				<text>{{item.name}}</text>
 				<image src="static/select.png" mode="aspectFill" v-if="pinglun_active != index"></image>
 				<image src="static/select_active.png" mode="aspectFill" v-else></image>
@@ -49,83 +52,105 @@
 			return {
 				xitong_tongzhi: false,
 				dianzan_tuisong: false,
-				dianzan_tuisong: false,
+				pinglun_tuisong: false,
 				dianzan_active: 0,
-				dianzan_list: [
-					{
-						id: '',
+				list: [{
+						id: 'all',
 						name: '任何人'
 					},
 					{
-						id: '',
+						id: 'follower',
 						name: '仅我关注的'
 					},
 					{
-						id: '',
+						id: 'fans',
 						name: '仅关注我的'
 					},
 				],
 				collect_active: 0,
-				collect_list: [
-					{
-						id: '',
-						name: '任何人'
-					},
-					{
-						id: '',
-						name: '仅我关注的'
-					},
-					{
-						id: '',
-						name: '仅关注我的'
-					},
-				],
+
 				pinglun_active: 0,
-				pinglun_list: [
-					{
-						id: '',
-						name: '任何人'
-					},
-					{
-						id: '',
-						name: '仅我关注的'
-					},
-					{
-						id: '',
-						name: '仅关注我的'
-					},
-				]
+
 			}
 		},
 		onLoad() {
-			
+			this.getdata()
 		},
 		onShow() {
-			
+
 		},
 		onPullDownRefresh() {
-			
+
 		},
 		onReachBottom() {
-			
+
 		},
 		methods: {
+			getdata() {
+				var that = this
+				$api.req({
+					url: 'user/config',
+					method: 'get',
+				}, function(res) {
+					that.xitong_tongzhi = res.data.is_system_notify == 1 ? true : false
+					that.dianzan_tuisong = res.data.is_like_notify == 1 ? true : false
+					that.pinglun_tuisong = res.data.is_comment_notify == 1 ? true : false
+					for (var i = 0; i < that.list.length; i++) {
+						if (res.data.who_can_like == that.list[i].id) {
+							that.dianzan_active = i
+						}
+						if (res.data.who_can_collect == that.list[i].id) {
+							that.collect_active = i
+						}
+						if (res.data.who_can_comment == that.list[i].id) {
+							that.pinglun_active = i
+						}
+					}
+				})
+			},
 			collectselect(index) {
 				this.collect_active = index
+				this.tochangge()
 			},
 			pinglunselect(index) {
 				this.pinglun_active = index
+				this.tochangge()
 			},
 			dianzanselect(index) {
 				this.dianzan_active = index
+				this.tochangge()
+			},
+			topinglun(e) {
+				this.pinglun_tuisong = e
+				this.tochangge()
 			},
-			topinglun() {},
-			
-			todianzan() {},
-			
-			toxitong() {
-				
+
+			todianzan(e) {
+				this.dianzan_tuisong = e
+				this.tochangge()
+			},
+
+			toxitong(e) {
+				this.xitong_tongzhi = e
+				this.tochangge()
 			},
+			tochangge() {
+				var that = this
+				$api.req({
+					url: 'user/config',
+					method: 'post',
+					data: {
+						is_system_notify: this.xitong_tongzhi ? 1 : 0,
+						is_like_notify: this.dianzan_tuisong ? 1 : 0,
+						is_comment_notify: this.pinglun_tuisong ? 1 : 0,
+						who_can_like: this.list[this.dianzan_active].id,
+						who_can_collect: this.list[this.collect_active].id,
+						who_can_comment: this.list[this.pinglun_active].id,
+					}
+				}, function(res) {
+					$api.info(res.msg)
+				})
+			}
 		}
 	}
 </script>
@@ -133,6 +158,7 @@
 <style lang="scss">
 	.content {
 		background: #F5F5F5;
+
 		.box {
 			box-sizing: border-box;
 			border-top: 1px solid #F5F5F5;
@@ -140,22 +166,26 @@
 			width: 100%;
 			background: #FFFFFF;
 			margin: 0 0 20rpx;
+
 			.title {
 				font-size: 24rpx;
 				font-family: PingFangSC, PingFang SC;
 				font-weight: 400;
 				color: #333333;
 			}
+
 			.item {
 				box-sizing: border-box;
 				padding: 32rpx 0;
 				border-bottom: 1px solid #F5F5F5;
+
 				text {
 					font-size: 30rpx;
 					font-family: PingFangSC, PingFang SC;
 					font-weight: 400;
 					color: #333333;
 				}
+
 				image {
 					width: 32rpx;
 					height: 32rpx;
@@ -163,4 +193,4 @@
 			}
 		}
 	}
-</style>
+</style>

+ 76 - 31
pageC/userinfo.vue

@@ -2,21 +2,22 @@
 	<view class="content">
 		<view class="box">
 			<u-cell-group :border="false">
-				 <u-cell title="头像" size="large">
-					 <view class="value" slot="value">
-						 <image :src="user.avatar" mode="aspectFill" @click="toavatar"></image>
-					 </view>
-				 </u-cell>
-				 <u-cell title="昵称" size="large" :value="user.username">
-					 <view class="value" slot="value">
-					 	<u-input v-model="user.username" border="none" inputAlign="right" placeholder="请您输入内容"></u-input>
-					 </view>
-				 </u-cell>
-				 <u-cell title="个人简介" size="large" :border="false" :isLink="true" @click="show_intro = true">
-					 <view class="value" slot="value">
-					 	<text class="text_hide">{{user.introduction || '介绍一下自己!'}}</text>
-					 </view>
-				 </u-cell>
+				<u-cell title="头像" size="large">
+					<view class="value" slot="value">
+						<image :src="user.avatar" mode="aspectFill" @click="toavatar"></image>
+					</view>
+				</u-cell>
+				<u-cell title="昵称" size="large" :value="user.username">
+					<view class="value" slot="value">
+						<u-input v-model="user.username" border="none" inputAlign="right"
+							placeholder="请您输入内容"></u-input>
+					</view>
+				</u-cell>
+				<u-cell title="个人简介" size="large" :border="false" :isLink="true" @click="show_intro = true">
+					<view class="value text_hide" slot="value"  style="max-width: 350rpx;">
+						<text class="text_hide" style="max-width: 200rpx;">{{user.introduction || '介绍一下自己!'}}</text>
+					</view>
+				</u-cell>
 			</u-cell-group>
 		</view>
 		<view class="box">
@@ -33,7 +34,7 @@
 			</u-cell-group>
 		</view>
 		<view class="bottom">
-			<view class="btn">保存</view>
+			<view class="btn" @click="save">保存</view>
 		</view>
 		<u-popup :show="show_intro" @close="toclose" mode="bottom" :round="14">
 			<view class="popu">
@@ -43,9 +44,10 @@
 					<u-icon name="close" color="#999" size="18" @click="toclose"></u-icon>
 				</view>
 				<view class="text">
-					<u-textarea v-model="user.intro" height="150" :autoHeight="true" placeholder="介绍一下自己!" count maxlength="70" border="none"></u-textarea>
+					<u-textarea v-model="user.introduction" height="150" :autoHeight="true" placeholder="介绍一下自己!" count
+						maxlength="70" border="none"></u-textarea>
 				</view>
-				<view class="btn" :class="user.intro != '' ? '' : 'btn2'">保存</view>
+				<view class="btn" :class="user.introduction != '' ? '' : 'btn2'" @click="save">保存</view>
 			</view>
 		</u-popup>
 	</view>
@@ -66,6 +68,29 @@
 			this.getlist()
 		},
 		methods: {
+			save() {
+				var that = this
+				let data = {
+					username: that.user.username,
+					avatar: that.user.avatar,
+					introduction: that.user.introduction
+				}
+				let list = []
+				for (var i = 0; i < that.list.length; i++) {
+					data[that.list[i].column_id] = that.list[i].value;
+				}
+				$api.req({
+					url: 'user',
+					method: 'PUT',
+					data: data
+				}, function(res) {
+					$api.info(res.msg)
+					that.toclose()
+					setTimeout(() => {
+						that.getuser()
+					}, 1000)
+				})
+			},
 			toavatar() {
 				var _this = this
 				uni.chooseImage({
@@ -94,12 +119,13 @@
 				this.show_intro = false
 			},
 			getlist() {
-				this.list = [
-					{
-						name: '预留字段1',
-						value: ''
-					}
-				]
+				var _this = this
+				$api.req({
+					url: 'user/extra',
+
+				}, function(res) {
+					_this.list = res.data
+				})
 			},
 			getuser() {
 				var _this = this
@@ -107,8 +133,11 @@
 					url: 'user/info',
 					method: 'GET'
 				}, function(res) {
-					if(res.code == 10000) {
+					if (res.code == 10000) {
 						_this.user = res.data
+						if (!_this.user.introduction) {
+							_this.user.introduction = ''
+						}
 					}
 				})
 			},
@@ -119,10 +148,13 @@
 <style lang="scss">
 	.content::v-deep {
 		background: #F4F4F4;
+
 		.popu {
 			padding: 40rpx 28rpx;
+
 			.top {
 				width: 100%;
+
 				.title {
 					font-size: 36rpx;
 					font-family: PingFangSC, PingFang SC;
@@ -130,6 +162,7 @@
 					color: #333333;
 				}
 			}
+
 			.btn {
 				margin: 48rpx 0 0;
 				width: 694rpx;
@@ -143,9 +176,11 @@
 				text-align: center;
 				line-height: 88rpx;
 			}
+
 			.btn2 {
 				opacity: 0.4;
 			}
+
 			.text {
 				margin: 38rpx 0 0;
 				width: 694rpx;
@@ -154,18 +189,20 @@
 				border-radius: 20rpx;
 				box-sizing: border-box;
 				padding: 32rpx 24rpx;
+
 				.u-textarea {
 					width: 100%;
 					height: 100%;
 					padding: 0;
 					background: #F4F4F4;
+
 					text {
 						background: #f4f4f4 !important;
 					}
 				}
 			}
 		}
-		
+
 		.bottom {
 			position: fixed;
 			bottom: 0;
@@ -175,7 +212,7 @@
 			background: #FFFFFF;
 			box-sizing: border-box;
 			padding: 16rpx 24rpx 66rpx;
-			
+
 			.btn {
 				width: 100%;
 				height: 84rpx;
@@ -189,25 +226,28 @@
 				text-align: center;
 			}
 		}
-		
-		.box{
+
+		.box {
 			width: 100%;
 			background: #FFFFFF;
 			box-sizing: border-box;
 			padding: 28rpx 28rpx;
 			margin: 0 0 20rpx;
+
 			.value {
 				image {
 					width: 100rpx;
 					height: 100rpx;
 					border-radius: 50%;
 				}
-				input {
-				}
+
+				input {}
+
 				text {
 					width: 450rpx;
 				}
 			}
+
 			.title {
 				text:first-child {
 					font-size: 32rpx;
@@ -215,6 +255,7 @@
 					font-weight: 600;
 					color: #333333;
 				}
+
 				text:last-child {
 					font-size: 24rpx;
 					font-family: PingFangSC, PingFang SC;
@@ -224,5 +265,9 @@
 				}
 			}
 		}
+
+		.u-cell__title {
+			white-space: nowrap;
+		}
 	}
 </style>

+ 6 - 12
pageC/video-detail.vue

@@ -1,9 +1,9 @@
 <template>
 	<view class="content">
-		<video :src="detail.src"></video>
+		<video :src="detail.url"></video>
 		<view class="box">
-			<view class="title">{{detail.name}}</view>
-			<view class="time">{{detail.time}}</view>
+			<view class="title">{{detail.title}}</view>
+			<view class="time">{{detail.created_at}}</view>
 			<view class="btn" @click="down">下载视频</view>
 		</view>
 	</view>
@@ -18,8 +18,8 @@
 				}
 			}
 		},
-		onLoad() {
-			this.getdata()
+		onLoad(options) {
+			this.detail = JSON.parse(decodeURIComponent(options.data))
 		},
 		methods: {
 			down() {
@@ -33,13 +33,7 @@
 					}
 				});
 			},
-			getdata() {
-				this.detail = {
-					src: 'https://qiniu-web-assets.dcloud.net.cn/unidoc/zh/2minute-demo.mp4',
-					name: '花火大会是一生必看?那必须是!|Vlog',
-					time: '2023.10.20 23:12'
-				}
-			},
+			
 		}
 	}
 </script>

+ 6 - 5
pageC/video-list.vue

@@ -10,10 +10,10 @@
 				<view class="list-item hflex acenter" v-for="(item,index) in list" :key="index" @click="toinfo(item)">
 					<u-checkbox v-if="show_manager" activeColor="#57C3C2" shape="circle" :customStyle="{marginBottom: '8px'}" :name="item.id"></u-checkbox>
 					<view class="hflex acenter" style="flex:1">
-						<image :src="item.img" mode="aspectFill"></image>
+						<image :src="item.image" mode="aspectFill"></image>
 						<view class="img-right">
-							<text class="name text_hide2">{{item.name}}</text>
-							<text class="num" v-if="current != 4">{{item.time}}</text>
+							<text class="name text_hide2">{{item.title}}</text>
+							<text class="num" v-if="current != 4">{{item.created_at}}</text>
 						</view>
 					</view>
 				</view>
@@ -27,7 +27,7 @@
 			<u-checkbox-group placement="column">
 				<u-checkbox :checked="quanxuan" @change="selectall" activeColor="#57C3C2" shape="circle" :customStyle="{marginBottom: '8px'}" label="全选"></u-checkbox>
 			</u-checkbox-group>
-			<view class="btn">批量下载</view>
+			<view class="btn" @click="downVideo">批量下载</view>
 		</view>
 	</view>
 </template>
@@ -61,7 +61,7 @@
 		methods: {
 			toinfo(item) {
 				uni.navigateTo({
-					url: '/pageC/video-detail'
+					url: '/pageC/video-detail?data=' + encodeURIComponent(JSON.stringify(item))
 				})
 			},
 			/* 全选 */
@@ -115,6 +115,7 @@
 				})
 				
 			},
+			downVideo() {}
 		},
 	}
 </script>

+ 267 - 16
pageC/vip.vue

@@ -1,60 +1,177 @@
 <template>
 	<view class="content">
-		<u-navbar title="会员福利" bgColor="rgba(0,0,0,0)" safeAreaInsetTop autoBack height="44px"></u-navbar>
+		<u-navbar title="会员福利" bgColor="rgba(0,0,0,0)" safeAreaInsetTop placeholder autoBack height="44px"></u-navbar>
 		<image src="static/jifen-bg.png" mode="aspectFill" class="top_bg"></image>
 		<view class="top">
-			<yxVip :user="user" :showsign="false" :showlevel="false"></yxVip>
+			<yxVip :user="user" :showsign="false" :showlevel="true"></yxVip>
 		</view>
 		<view class="content-bg">
-			
+
 			<view class="box">
 				<view class="title">升级领福利</view>
-				<view class="list-item vflex acenter jbetween"  v-for="(item,index) in list" :key="index">
+				<view class="list-item hflex acenter jbetween" v-for="(item,index) in list" :key="index">
 					<view class="item-left hflex acenter">
-						<image :src="item.prize_image" mode="aspectFill"></image>
-						<view class="img-right">
+						<image :src="item.prize_image" mode="aspectFill" v-if="item.prize_type != 'integral'"></image>
+						<image src="@/static/images/jifen.png" mode="aspectFill" v-else></image>
+						<view class="img-right vflex">
+							<text>当前等级达到{{item.level}}级</text>
+							<text>奖励:{{item.prize_name}}</text>
+						</view>
+						<!-- <view class="img-right vflex" v-if="item.prize_type == 'coupon'">
 							<text>当前等级达到{{item.level}}级</text>
-							<text>积分奖励+{{item.days}}</text>
+							<text>奖励:{{item.prize_name}}</text>
+						</view> -->
+					</view>
+					<view class="item-right">
+						<view class="button1" v-if="item.is_qualified == 0">
+							未达成
+						</view>
+
+						<view class="button2" v-if="item.is_qualified != 0 && item.is_received != 0"
+							@click="toadd(item)" :style="'color: ' + item.prize_type == 'goods' ? '#00B0B0;' : ''">
+							{{item.prize_type == 'goods' ? '添加客服' : '已领取'}}
+						</view>
+						<view class="button3" v-if="item.is_qualified != 0 && item.is_received == 0"
+							@click="toprize(item)">
+							领取奖励
 						</view>
+
 					</view>
-					<view class="item-right"></view>
 				</view>
 			</view>
 		</view>
-		
+		<u-popup :show="show_address" @close="toclose" mode="bottom" :round="13">
+			<addressBox @close="toclose" @select="selectAddress"></addressBox>
+		</u-popup>
+		<u-popup :show="show_submit" @close="toclose" mode="center" :round="10">
+			<view class="popu1 vflex acenter">
+				<image src="static/success.png" mode="aspectFill"></image>
+				<view class="success">领取成功</view>
+				<view class="success-text">请前往添加客服微信</view>
+				<view class="hflex acenter btns">
+					<view class="btn1" @click="toclose">稍后添加</view>
+					<view class="btn2" @click="show_wx = true">添加客服</view>
+				</view>
+			</view>
+		</u-popup>
+		<u-popup :show="show_wx" @close="toclose" mode="center" :round="10">
+			<kefu-wx :wxcode="wxcode" @submit="toclose"></kefu-wx>
+		</u-popup>
 	</view>
 </template>
 
 <script>
 	import yxVip from '@/components/yx-vip/index.vue'
+	import addressBox from './components/addressbox.vue'
+	import kefuWx from './components/kefu-wx.vue'
 	import $api from '@/static/js/api.js'
 	export default {
 		components: {
-			yxVip
+			yxVip,
+			addressBox,
+			kefuWx
 		},
 		data() {
 			return {
 				user: {},
 				list: [],
+				address_id: '',
+				show_address: false,
+				prize: {},
+				show_submit: false,
+				show_wx: false,
+				wxcode: '',
+				page: 1,
+				last_page: 1,
 			}
 		},
 		onLoad() {
+
+		},
+		onShow() {
 			this.getuser()
+			this.list = []
 			this.getlist()
 		},
+		onReachBottom() {
+			if (this.page < this.last_page) {
+				this.page++
+				this.getlist()
+			} else {
+				uni.$u.toast('已经到底了')
+				return
+			}
+		},
 		methods: {
+			getcode() {
+				var that = this
+				$api.req({
+					url: 'config',
+					data: {
+						module: 'basic'
+					}
+				}, function(res) {
+					that.wxcode = res.data.customer_service_qrcode
+				})
+			},
+			toadd(item) {
+				if (item.prize_type == 'goods') {
+					this.show_submit = true
+					this.getcode()
+				} else {
+					return
+				}
+			},
+			selectAddress(e) {
+				console.log(e, '---------');
+				this.address_id = e
+				this.toreceive(this.prize.id)
+				this.toclose()
+			},
+			toclose() {
+				this.show_address = false
+				this.show_submit = false
+				this.show_wx = false
+			},
+			toprize(item) {
+				var _this = this
+				if (item.prize_type == 'goods') {
+					this.prize = item
+					this.show_address = true
+				} else {
+					this.toreceive((item.id))
+				}
+
+			},
+			toreceive(id) {
+				var _this = this
+				$api.req({
+					url: 'level/prize/' + id + '/receive',
+					method: 'POST',
+					data: {
+						address_id: _this.address_id ? _this.address_id : '0'
+					}
+				}, function(res) {
+					if (res.code == 10000) {
+						$api.info('领取成功')
+						_this.getlist()
+					}
+				})
+			},
 			getlist() {
 				var _this = this
 				$api.req({
 					url: 'level/prize',
 					method: 'GET',
 					data: {
-						page: 1,
-						is_page: 0
+						page: _this.page,
+						limit: 10,
+						is_page: 1
 					}
 				}, function(res) {
-					if(res.code == 10000) {
-						_this.list = res.data
+					if (res.code == 10000) {
+						_this.list = _this.list.concat(res.data.list)
+						_this.last_page = res.data.last_page
 					}
 				})
 			},
@@ -64,7 +181,7 @@
 					url: 'user/info',
 					methos: 'GET'
 				}, function(res) {
-					if(res.code == 10000) {
+					if (res.code == 10000) {
 						_this.user = res.data
 					}
 				})
@@ -76,10 +193,99 @@
 <style lang="scss">
 	.content {
 		background: unset;
+
+		.popu1 {
+			width: 510rpx;
+			padding: 46rpx 0;
+
+			.top {
+				width: 100%;
+
+				.top-title {
+					font-size: 32rpx;
+					font-family: PingFangSC, PingFang SC;
+					font-weight: 600;
+					color: #000000;
+					text-align: center;
+					padding-left: 100rpx;
+				}
+
+				image {
+					width: 36rpx;
+					height: 36rpx;
+				}
+			}
+
+			.center {
+				image {
+					width: 310rpx;
+					height: 310rpx;
+				}
+
+				text {
+					font-size: 22rpx;
+					font-family: PingFangSC, PingFang SC;
+					font-weight: 400;
+					color: rgba(0, 0, 0, .42);
+				}
+			}
+
+			image {
+				width: 78rpx;
+				height: 78rpx;
+				margin: 12rpx 36rpx;
+			}
+
+			.success {
+				font-size: 30rpx;
+				font-family: PingFangSC, PingFang SC;
+				font-weight: 400;
+				color: #000000;
+			}
+
+			.success-text {
+				font-size: 24rpx;
+				font-family: PingFangSC, PingFang SC;
+				font-weight: 400;
+				color: rgba(0, 0, 0, .6);
+				padding: 8rpx 0 42rpx;
+			}
+
+			.btns {
+				.btn1 {
+					width: 204rpx;
+					height: 72rpx;
+					background: #E7E7E7;
+					border-radius: 40rpx;
+					font-size: 28rpx;
+					font-family: PingFangSC, PingFang SC;
+					font-weight: 400;
+					color: #666666;
+					line-height: 72rpx;
+					text-align: center;
+				}
+
+				.btn2 {
+					width: 204rpx;
+					height: 72rpx;
+					background: #00B0B0;
+					border-radius: 40rpx;
+					font-size: 28rpx;
+					font-family: PingFangSC, PingFang SC;
+					font-weight: 400;
+					color: #FFFFFF;
+					line-height: 72rpx;
+					text-align: center;
+					margin: 0 0 0 26rpx;
+				}
+			}
+		}
+
 		.content-bg {
 			background: #f5f5f5;
 			min-height: 80vh;
 		}
+
 		.box {
 			margin: 20rpx auto;
 			width: 694rpx;
@@ -87,27 +293,33 @@
 			border-radius: 16rpx;
 			box-sizing: border-box;
 			padding: 28rpx;
+
 			.title {
 				font-size: 32rpx;
 				font-family: PingFangSC, PingFang SC;
 				font-weight: 600;
 				color: #333333;
 			}
+
 			.list-item {
 				margin-top: 40rpx;
+
 				.item-left {
 					image {
 						width: 100rpx;
 						height: 100rpx;
 					}
+
 					.img-right {
 						padding-left: 20rpx;
+
 						text:first-child {
 							font-size: 28rpx;
 							font-family: SFPro, SFPro;
 							font-weight: 500;
 							color: #333333;
 						}
+
 						text:last-child {
 							font-size: 24rpx;
 							font-family: PingFangSC, PingFang SC;
@@ -117,8 +329,46 @@
 						}
 					}
 				}
+
+				.item-right {
+					.button1 {
+						width: 128rpx;
+						height: 56rpx;
+						font-family: PingFangSC, PingFang SC;
+						font-weight: 400;
+						font-size: 28rpx;
+						color: #999999;
+						line-height: 56rpx;
+						text-align: center;
+					}
+
+					.button2 {
+						width: 128rpx;
+						height: 56rpx;
+						background: #D8D8D8;
+						border-radius: 28rpx;
+						font-weight: 400;
+						font-size: 24rpx;
+						color: #FFFFFF;
+						line-height: 56rpx;
+						text-align: center;
+					}
+
+					.button3 {
+						width: 128rpx;
+						height: 56rpx;
+						background: rgba(0, 176, 176, .1);
+						border-radius: 28rpx;
+						font-weight: 400;
+						font-size: 24rpx;
+						color: #00B0B0;
+						line-height: 56rpx;
+						text-align: center;
+					}
+				}
 			}
 		}
+
 		.top_bg {
 			position: absolute;
 			width: 100%;
@@ -126,9 +376,10 @@
 			left: 0;
 			z-index: -1;
 		}
+
 		.top {
 			width: 694rpx;
 			margin: 108rpx auto 0;
 		}
 	}
-</style>
+</style>

+ 9 - 7
pageC/xieyi.vue

@@ -8,36 +8,36 @@
 	import $api from '@/static/js/api.js'
 	export default {
 		data() {
-			return{
+			return {
 				content: '',
 			}
 		},
 		onLoad(options) {
-			if(options.type == 'rule') {
+			if (options.type == 'rule') {
 				uni.setNavigationBarTitle({
 					title: '积分规则'
 				})
 				this.getdata('rule')
 			}
-			if(options.type == 'user') {
+			if (options.type == 'user') {
 				uni.setNavigationBarTitle({
 					title: '用户协议'
 				})
 				this.getdata('user')
 			}
-			if(options.type == 'yinsi') {
+			if (options.type == 'yinsi') {
 				uni.setNavigationBarTitle({
 					title: '隐私政策'
 				})
 				this.getdata('private')
 			}
-			if(options.type == 'geren') {
+			if (options.type == 'geren') {
 				uni.setNavigationBarTitle({
 					title: '个人信息收集清单'
 				})
 				this.getdata('personal')
 			}
-			if(options.type == 'shengming') {
+			if (options.type == 'shengming') {
 				uni.setNavigationBarTitle({
 					title: '开源软件声明'
 				})
@@ -54,7 +54,7 @@
 						code: val
 					}
 				}, function(res) {
-					if(res.code == 10000) {
+					if (res.code == 10000) {
 						_this.content = res.data.content
 					}
 				})
@@ -67,5 +67,7 @@
 	.content {
 		background-color: #fff;
 		min-height: 100vh;
+		box-sizing: border-box;
+		padding: 0 30rpx;
 	}
 </style>

+ 40 - 14
pageC/youhuiquan.vue

@@ -7,14 +7,27 @@
 		</view>
 		<view class="list" v-if="list.length> 0">
 			<view class="list-item hflex acenter jbetween" v-for="(item,index) in list" :key="index">
-				<view class="item-left vflex acenter jcenter" :class="item.is_use == 1 || item.is_expire == 1 ? 'left-bg' : ''">
+				<view class="item-left vflex acenter jcenter"
+					:class="item.is_use == 1 || item.is_expire == 1 ? 'left-bg' : ''"
+					v-if="item.coupon.type == 'integral_threshold' || item.coupon.type == 'integral_no_threshold'">
 					<view class="left-price">¥{{Number(item.coupon.amount).toFixed(0)}}</view>
-					<view class="left-text" v-if="item.coupon.type == 'integral_threshold'">满{{Number(item.coupon.threshold).toFixed(0)}}元可用</view>
+					<view class="left-text" v-if="item.coupon.type == 'integral_threshold'">
+						满{{Number(item.coupon.threshold).toFixed(0)}}元可用</view>
+				</view>
+				<view class="item-left vflex acenter jcenter"
+					:class="item.is_use == 1 || item.is_expire == 1 ? 'left-bg' : ''"
+					v-if="item.coupon.type == 'shoot'">
+					<view class="left-price">拍摄券</view>
+				</view>
+				<view class="item-left vflex acenter jcenter"
+					:class="item.is_use == 1 || item.is_expire == 1 ? 'left-bg' : ''"
+					v-if="item.coupon.type == 'lease'">
+					<view class="left-price">租赁券</view>
 				</view>
 				<view class="item-center vflex">
-					<text>{{item.coupon.name}}</text>
-					<text>{{item.coupon.description}}</text>
-					<text>到期时间:{{item.coupon.expired_at.slice(0,-9)}}</text>
+					<text class="text_hide" style="width: 300rpx;">{{item.coupon.name}}</text>
+					<text class="text_hide" style="width: 300rpx;">{{item.coupon.description}}</text>
+					<text>到期时间:{{item.expired_at.slice(0,-9)}}</text>
 				</view>
 				<view class="item-right hflex acenter jcenter">
 					<view class="btn" v-if="item.is_use == 0 && item.is_expire == 0">使用</view>
@@ -23,7 +36,7 @@
 				</view>
 			</view>
 		</view>
-		<view class="hflex acenter jcenter " style="height: 100vh;" v-else >
+		<view class="hflex acenter jcenter " style="height: 100vh;" v-else>
 			<u-empty mode="data"></u-empty>
 		</view>
 	</view>
@@ -34,8 +47,7 @@
 	export default {
 		data() {
 			return {
-				tabs: [
-					{
+				tabs: [{
 						name: '全部'
 					},
 					{
@@ -58,7 +70,7 @@
 			this.getlist()
 		},
 		onReachBottom() {
-			if(this.page < this.last_page) {
+			if (this.page < this.last_page) {
 				this.page++
 				this.getlist()
 			} else {
@@ -78,12 +90,12 @@
 				var _this = this
 				var is_expire = ''
 				var is_use = ''
-				if(_this.current == 1) {
+				if (_this.current == 1) {
 					is_expire = 0
 					is_use = 0
-				} else if(_this.current == 2) {
+				} else if (_this.current == 2) {
 					is_use = 1
-				} else if(_this.current == 3) {
+				} else if (_this.current == 3) {
 					is_expire = 1
 				}
 				$api.req({
@@ -96,7 +108,7 @@
 						is_use: is_use
 					}
 				}, function(res) {
-					if(res.code == 10000) {
+					if (res.code == 10000) {
 						_this.list = _this.list.concat(res.data.list)
 						_this.last_page = res.data.last_page
 					}
@@ -109,19 +121,23 @@
 <style lang="scss">
 	.content {
 		background: #F5F5F5;
+
 		.list {
 			width: 100%;
 			box-sizing: border-box;
 			padding: 0 28rpx;
+
 			.list-item {
 				margin: 20rpx 0 0;
 				width: 694rpx;
 				height: 160rpx;
 				border-radius: 8rpx;
 				background: #FFFFFF;
+
 				.item-right {
 					height: 100%;
 					padding: 0 28rpx 0 0;
+
 					.btn {
 						width: 124rpx;
 						height: 48rpx;
@@ -134,20 +150,24 @@
 						line-height: 48rpx;
 						text-align: center;
 					}
+
 					image {
 						width: 108rpx;
 						height: 108rpx;
 					}
 				}
+
 				.item-center {
 					padding: 16rpx 20rpx;
-					max-width: 362rpx;
+					width: 362rpx;
+
 					text {
 						font-size: 20rpx;
 						font-family: PingFangSC, PingFang SC;
 						font-weight: 400;
 						color: #333333;
 					}
+
 					text:first-child {
 						font-size: 28rpx;
 						font-family: PingFangSC, PingFang SC;
@@ -155,6 +175,7 @@
 						color: #333333;
 						padding: 0 0 8rpx;
 					}
+
 					text:last-child {
 						font-size: 18rpx;
 						font-family: SFPro, SFPro;
@@ -164,16 +185,19 @@
 						white-space: nowrap;
 					}
 				}
+
 				.item-left {
 					height: 100%;
 					width: 196rpx;
 					background: #00B0B0;
+
 					.left-price {
 						font-size: 32rpx;
 						font-family: PingFangSC, PingFang SC;
 						font-weight: 600;
 						color: #FFFFFF;
 					}
+
 					.left-text {
 						font-size: 20rpx;
 						font-family: PingFangSC, PingFang SC;
@@ -182,11 +206,13 @@
 						padding: 18rpx 0 0;
 					}
 				}
+
 				.left-bg {
 					background: #B2B2B2 !important;
 				}
 			}
 		}
+
 		.tabs {
 			background: #FFFFFF;
 		}

+ 2 - 2
pageC/zhiwei-detail.vue

@@ -2,10 +2,10 @@
 	<view class="content">
 		<view class="navbar">
 			<u-navbar title=" " :autoBack="true" :placeholder="true">
-				<view slot="right" class="u-nav-right hflex acenter">
+				<!-- <view slot="right" class="u-nav-right hflex acenter">
 					<image src="static/share.png" mode="aspectFill"></image>
 					<image src="static/sandian.png" mode="aspectFill"></image>
-				</view>
+				</view> -->
 			</u-navbar>
 		</view>
 		<view class="detail">

+ 26 - 15
pageC/zhiwei-list.vue

@@ -5,17 +5,18 @@
 				<text class="text_hide">{{item.title}}</text>
 				<text>{{item.salary_min}}-{{item.salary_max}}K·{{item.salary_month}}薪</text>
 			</view>
-			
+
 			<view class="hflex acetner">
 				<view class="text-box" v-if="item.education">{{item.education}}</view>
-				<view class="text-box" v-if="item.experience_min">{{item.experience_min}}-{{item.experience_max}}年</view>
+				<view class="text-box" v-if="item.experience_min">{{item.experience_min}}-{{item.experience_max}}年
+				</view>
 			</view>
 			<view class="bottom hflex acenter jbetween">
 				<text>{{item.name}} {{item.mobile}}</text>
 				<text>{{item.city}}</text>
 			</view>
 		</view>
-		<view class="hflex acenter jcenter " style="height: 100vh;" v-else >
+		<view class="hflex acenter jcenter " style="height: 100vh;" v-else>
 			<u-empty mode="data"></u-empty>
 		</view>
 	</view>
@@ -25,7 +26,7 @@
 	import $api from '@/static/js/api.js'
 	export default {
 		data() {
-			return{
+			return {
 				list: [],
 				page: 1,
 				last_page: 1,
@@ -35,7 +36,7 @@
 			this.getlist()
 		},
 		onReachBottom() {
-			if(this.page < this.last_page) {
+			if (this.page < this.last_page) {
 				this.page++
 				this.getlist()
 			} else {
@@ -55,16 +56,16 @@
 					url: 'job',
 					method: 'GET',
 					data: {
-							is_page: 1,
-							page: _this.page,
-							limit: 10,
-						}
-					}, function(res) {
-						if(res.code == 10000) {
-							_this.list = _this.list.concat(res.data.list)
-							_this.last_page = res.data.last_page
-						}
-					})
+						is_page: 1,
+						page: _this.page,
+						limit: 10,
+					}
+				}, function(res) {
+					if (res.code == 10000) {
+						_this.list = _this.list.concat(res.data.list)
+						_this.last_page = res.data.last_page
+					}
+				})
 			}
 		}
 	}
@@ -74,14 +75,17 @@
 	.content {
 		padding: 20rpx 24rpx;
 		background: #F4F4F4;
+
 		.list-item {
 			background: #FFFFFF;
 			border-radius: 16rpx;
 			margin: 0 0 20rpx;
 			box-sizing: border-box;
 			padding: 26rpx 20rpx;
+
 			.top {
 				padding-bottom: 20rpx;
+
 				text:first-child {
 					font-size: 32rpx;
 					font-family: PingFangSC, PingFang SC;
@@ -89,6 +93,7 @@
 					color: #222222;
 					max-width: 432rpx;
 				}
+
 				text:last-child {
 					font-size: 28rpx;
 					font-family: JDZhengHT, JDZhengHT;
@@ -96,8 +101,10 @@
 					color: #00B0B0;
 				}
 			}
+
 			.company {
 				padding: 16rpx 0;
+
 				text {
 					font-size: 24rpx;
 					font-family: PingFangSC, PingFang SC;
@@ -105,6 +112,7 @@
 					color: #666666;
 				}
 			}
+
 			.text-box {
 				background: #F4F4F4;
 				border-radius: 4rpx;
@@ -115,14 +123,17 @@
 				color: #555555;
 				margin: 0 16rpx 0 0;
 			}
+
 			.bottom {
 				padding: 26rpx 0 0;
+
 				text:first-child {
 					font-size: 20rpx;
 					font-family: SFPro, SFPro;
 					font-weight: 400;
 					color: #444444;
 				}
+
 				text:last-child {
 					font-size: 20rpx;
 					font-family: PingFangSC, PingFang SC;

+ 69 - 24
pageC/zuji-list.vue

@@ -13,18 +13,40 @@
 		<view class="list">
 			<u-swipe-action>
 				<u-checkbox-group v-model="select_all" placement="column" @change="selectitem">
-					<view class="list-item hflex acenter" v-for="(item,index) in list" :key="index">
-						<u-checkbox v-if="show_manager" activeColor="#57C3C2" shape="circle" :customStyle="{marginBottom: '8px'}" :name="item.id"></u-checkbox>
-						<u-swipe-action-item :options="options" @click="tocancel(item)">
-							<view class="hflex acenter" style="flex:1">
-								<image :src="item.img" mode="aspectFill"></image>
-								<view class="img-right">
-									<text class="name text_hide2">{{item.name}}</text>
-									<text class="num" v-if="current != 4">{{item.time}}  {{item.like_num || 0}}喜欢 · {{item.comment_num || 0}}评论</text>
-									<text class="price" v-else>{{item.price}}积分</text>
+					<view class="list-item" v-for="(a,b) in list" :key="b">
+						<view class="title">{{a.date}}</view>
+						<block v-for="(item,index) in a.list" :key="index">
+							<u-checkbox v-if="show_manager" activeColor="#57C3C2" shape="circle"
+								:customStyle="{marginBottom: '8px'}" :name="item.id"></u-checkbox>
+							<u-swipe-action-item :options="options" @click="tocancel(item)">
+								<view class="hflex acenter" style="flex:1" v-if="current != 3">
+									<image :src="item.source.image" mode="aspectFill"></image>
+									<view class="img-right vflex jbetween">
+										<text
+											class="name text_hide2">{{current == 4 ? item.source.name : item.source.title}}</text>
+										<view class="num hflex acenter" v-if="current != 4">
+											<text>{{item.source.created_at}}</text>
+											<text
+												style="padding-left: 20rpx;">{{item.source.like_count || 0}}喜欢·{{item.source.comment_count || 0}}评论</text>
+										</view>
+										<text class="price" v-else>{{item.source.price}}积分</text>
+									</view>
 								</view>
-							</view>
-						</u-swipe-action-item>
+								<view class="hflex acenter" style="flex:1" v-if="current == 3">
+									<image :src="item.source.images[0]" mode="aspectFill"
+										v-if="item.source.images.length>0"></image>
+									<view class="img-right vflex jbetween">
+										<text class="name text_hide2">{{item.source.content}}</text>
+
+										<view class="num hflex acenter">
+											<text>{{item.source.created_at}}</text>
+											<text
+												style="padding-left: 20rpx;">{{item.source.like_count || 0}}喜欢·{{item.source.comment_count || 0}}评论</text>
+										</view>
+									</view>
+								</view>
+							</u-swipe-action-item>
+						</block>
 					</view>
 				</u-checkbox-group>
 			</u-swipe-action>
@@ -32,7 +54,8 @@
 		<view style="height: 186rpx;" v-if="show_manager"></view>
 		<view class="bottom hflex acenter jbetween" v-if="show_manager">
 			<u-checkbox-group placement="column">
-				<u-checkbox :checked="quanxuan" @change="selectall" activeColor="#57C3C2" shape="circle" :customStyle="{marginBottom: '8px'}" label="全选"></u-checkbox>
+				<u-checkbox :checked="quanxuan" @change="selectall" activeColor="#57C3C2" shape="circle"
+					:customStyle="{marginBottom: '8px'}" label="全选"></u-checkbox>
 			</u-checkbox-group>
 			<view class="btn">删除</view>
 		</view>
@@ -43,11 +66,10 @@
 	import $api from '@/static/js/api.js'
 	export default {
 		data() {
-			return{
+			return {
 				list: [],
-				current:0,
-				tabs: [
-					{
+				current: 0,
+				tabs: [{
 						id: 'info',
 						name: '资讯'
 					},
@@ -64,7 +86,7 @@
 						name: '论坛'
 					},
 					{
-						id: 'goods',
+						id: 'integral_goods',
 						name: '商品'
 					},
 				],
@@ -85,7 +107,7 @@
 			this.getlist()
 		},
 		onReachBottom() {
-			if(this.page < this.last_page) {
+			if (this.page < this.last_page) {
 				this.page++
 				this.getlist()
 			} else {
@@ -98,9 +120,9 @@
 			selectall() {
 				this.quanxuan = !this.quanxuan
 				console.log(this.quanxuan);
-				if(this.quanxuan) {
+				if (this.quanxuan) {
 					this.select_all = []
-					for(var i=0;i<this.list.length;i++) {
+					for (var i = 0; i < this.list.length; i++) {
 						this.select_all.push(this.list[i].id)
 					}
 				} else {
@@ -111,7 +133,7 @@
 			/* 选择 */
 			selectitem(e) {
 				this.select_all = e
-				if(this.select_all.length == this.list.length) {
+				if (this.select_all.length == this.list.length) {
 					this.quanxuan = true
 				} else {
 					this.quanxuan = false
@@ -119,6 +141,7 @@
 			},
 			/* 取消收藏 */
 			tocancel(item) {
+
 			},
 			/* 切换tab */
 			changetabs(e) {
@@ -139,7 +162,7 @@
 						source_type: _this.tabs[_this.current].id
 					}
 				}, function(res) {
-					if(res.code == 10000) {
+					if (res.code == 10000) {
 						_this.list = _this.list.concat(res.data.list)
 						_this.last_page = res.data.last_page
 					}
@@ -153,15 +176,17 @@
 	.content::v-deep {
 		background: #FFFFFF;
 		position: relative;
+
 		.bottom {
 			position: fixed;
 			bottom: 0;
 			width: 750rpx;
 			height: 166rpx;
 			background: #FFFFFF;
-			padding: 12rpx 28rpx 80rpx; 
+			padding: 12rpx 28rpx 80rpx;
 			box-sizing: border-box;
 			z-index: 29;
+
 			.btn {
 				width: 184rpx;
 				height: 72rpx;
@@ -175,19 +200,34 @@
 				text-align: center;
 			}
 		}
-		.list{
+
+		.u-swipe-action-item {
+			margin: 0 0 32rpx;
+		}
+
+		.list {
 			width: 100%;
 			box-sizing: border-box;
 			padding: 28rpx 28rpx;
+
 			.list-item {
 				margin: 0 0 32rpx;
+
+				.title {
+					padding: 20rpx 0;
+					font-weight: bold;
+				}
+
 				image {
 					width: 200rpx;
 					height: 128rpx;
 					border-radius: 6rpx;
 					margin: 0 20rpx 0 0;
 				}
+
 				.img-right {
+					height: 128rpx;
+
 					.name {
 						max-width: 452rpx;
 						font-size: 28rpx;
@@ -196,12 +236,14 @@
 						color: #333333;
 						padding: 0 0 14rpx;
 					}
+
 					.num {
 						font-size: 20rpx;
 						font-family: SFPro, SFPro;
 						font-weight: 400;
 						color: #666666;
 					}
+
 					.price {
 						font-size: 28rpx;
 						font-family: JDZhengHT, JDZhengHT;
@@ -209,16 +251,19 @@
 						color: #FF3333;
 					}
 				}
+
 				.u-checkbox {
 					margin: 0 32rpx 0 0;
 				}
 			}
 		}
+
 		.tabs {
 			width: 100%;
 			padding: 18rpx 0;
 			border-bottom: 2rpx solid #F5F5F5;
 		}
+
 		.u-nav-slot {
 			text {
 				font-size: 28rpx;

+ 431 - 437
pages.json

@@ -49,474 +49,469 @@
 			}
 		},
 		{
-			"path" : "components/swiper-list/index",
-			"style" : 
-			{
-				"navigationBarTitleText" : "",
-				"enablePullDownRefresh" : false
+			"path": "components/swiper-list/index",
+			"style": {
+				"navigationBarTitleText": "",
+				"enablePullDownRefresh": false
+			}
+		},
+		{
+			"path": "pages/webview/index",
+			"style": {
+				"navigationBarTitleText": "",
+				"enablePullDownRefresh": false,
+				"navigationStyle": "custom"
 			}
 		}
 	],
-	"subPackages": [
-		{
+	"subPackages": [{
 			"root": "pageA",
-			"pages": [
-			{
-				"path": "info-detail",
-				"style": {
-					"navigationBarTitleText": "详情",
-					"navigationStyle": "custom"
-				}
-			},
-			{
-				"path": "add-wenzhang",
-				"style": {
-					"navigationBarTitleText": "发布文章",
-					"navigationStyle": "custom"
-				}
-			},
-			{
-				"path": "search",
-				"style": {
-					"navigationBarTitleText": "搜索页面",
-					"navigationStyle": "custom"
-				}
-			},
-			{
-				"path": "message",
-				"style": {
-					"navigationBarTitleText": "通知消息",
-					"navigationStyle": "custom"
-				}
-			},
-			{
-				"path": "dianzan-list",
-				"style": {
-					"navigationBarTitleText": "点赞",
-					"navigationBarBackgroundColor": "#FFFFFF"
-				}
-			},
-			{
-				"path": "shoucang-list",
-				"style": {
-					"navigationBarTitleText": "收藏",
-					"navigationBarBackgroundColor": "#FFFFFF"
-				}
-			},
-			{
-				"path": "pinglun-list",
-				"style": {
-					"navigationBarTitleText": "评论",
-					"navigationBarBackgroundColor": "#FFFFFF"
-				}
-			},
-			{
-				"path": "chat",
-				"style": {
-					"navigationBarTitleText": "聊天",
-					"navigationStyle": "custom"
-				}
-			},
-			{
-				"path": "chat-list",
-				"style": {
-					"navigationBarTitleText": "聊天记录",
-					"navigationBarBackgroundColor": "#FFFFFF"
-				}
-			},
-			{
-				"path" : "huati",
-				"style" : 
+			"pages": [{
+					"path": "info-detail",
+					"style": {
+						"navigationBarTitleText": "详情",
+						"navigationStyle": "custom"
+					}
+				},
 				{
-					"navigationBarTitleText" : "全部话题",
-					"enablePullDownRefresh" : false,
-					"navigationBarBackgroundColor": "#FFFFFF"
-				}
-			},
-			{
-				"path" : "huati-search",
-				"style" : 
+					"path": "add-wenzhang",
+					"style": {
+						"navigationBarTitleText": "发布文章",
+						"navigationStyle": "custom"
+					}
+				},
 				{
-					"navigationBarTitleText" : "全部话题",
-					"enablePullDownRefresh" : false,
-					"navigationBarBackgroundColor": "#FFFFFF"
-				}
-			},
-			/* 发布 */
-			{
-				"path" : "publish",
-				"style" : 
+					"path": "search",
+					"style": {
+						"navigationBarTitleText": "搜索页面",
+						"navigationStyle": "custom"
+					}
+				},
 				{
-					"navigationBarTitleText" : "",
-					"enablePullDownRefresh" : false,
-					"navigationBarBackgroundColor": "#FFFFFF"
-				}
-			},
-			{
-				"path" : "jingxuan-list",
-				"style" : 
+					"path": "message",
+					"style": {
+						"navigationBarTitleText": "通知消息",
+						"navigationStyle": "custom"
+					}
+				},
 				{
-					"navigationBarTitleText" : "精选",
-					"enablePullDownRefresh" : false,
-					"navigationBarBackgroundColor": "#FFFFFF"
-				}
-			},
-			{
-				"path" : "add-luntan",
-				"style" : 
+					"path": "dianzan-list",
+					"style": {
+						"navigationBarTitleText": "点赞",
+						"navigationBarBackgroundColor": "#FFFFFF"
+					}
+				},
 				{
-					"navigationBarTitleText" : "发布论坛",
-					"enablePullDownRefresh" : false,
-					"navigationStyle": "custom"
-				}
-			},
-			/* 话题详情 */
-			{
-				"path" : "topic-detail",
-				"style" : 
+					"path": "shoucang-list",
+					"style": {
+						"navigationBarTitleText": "收藏",
+						"navigationBarBackgroundColor": "#FFFFFF"
+					}
+				},
 				{
-					"navigationBarTitleText" : "",
-					"enablePullDownRefresh" : false,
-					"navigationBarBackgroundColor": "#FFFFFF"
-				}
-			}]
+					"path": "pinglun-list",
+					"style": {
+						"navigationBarTitleText": "评论",
+						"navigationBarBackgroundColor": "#FFFFFF"
+					}
+				},
+				{
+					"path": "chat",
+					"style": {
+						"navigationBarTitleText": "聊天",
+						"navigationStyle": "custom"
+					}
+				},
+				{
+					"path": "chat-list",
+					"style": {
+						"navigationBarTitleText": "聊天记录",
+						"navigationBarBackgroundColor": "#FFFFFF"
+					}
+				},
+				{
+					"path": "huati",
+					"style": {
+						"navigationBarTitleText": "全部话题",
+						"enablePullDownRefresh": false,
+						"navigationBarBackgroundColor": "#FFFFFF"
+					}
+				},
+				{
+					"path": "huati-search",
+					"style": {
+						"navigationBarTitleText": "全部话题",
+						"enablePullDownRefresh": false,
+						"navigationBarBackgroundColor": "#FFFFFF"
+					}
+				},
+				/* 发布 */
+				{
+					"path": "publish",
+					"style": {
+						"navigationBarTitleText": "",
+						"enablePullDownRefresh": false,
+						"navigationBarBackgroundColor": "#FFFFFF"
+					}
+				},
+				{
+					"path": "jingxuan-list",
+					"style": {
+						"navigationBarTitleText": "精选",
+						"enablePullDownRefresh": false,
+						"navigationBarBackgroundColor": "#FFFFFF"
+					}
+				},
+				{
+					"path": "add-luntan",
+					"style": {
+						"navigationBarTitleText": "发布论坛",
+						"enablePullDownRefresh": false,
+						"navigationStyle": "custom"
+					}
+				},
+				/* 话题详情 */
+				{
+					"path": "topic-detail",
+					"style": {
+						"navigationBarTitleText": "",
+						"enablePullDownRefresh": false,
+						"navigationBarBackgroundColor": "#FFFFFF"
+					}
+				}
+			]
 		},
 		{
 			"root": "pageB",
 			"pages": [{
-				"path": "good-detail",
-				"style": {
-					"navigationBarTitleText": "商品",
-					"navigationBarBackgroundColor": "#FFFFFF"
-				}
-			},
-			{
-				"path": "order-confirm",
-				"style": {
-					"navigationBarTitleText": "确认订单",
-					"navigationBarBackgroundColor": "#FFFFFF"
-				}
-			},
-			{
-				"path": "totaobao",
-				"style": {
-					"navigationBarTitleText": "跳转",
-					"navigationBarBackgroundColor": "#FFFFFF"
-				}
-			},
-			{
-				"path": "yuyue-capture",
-				"style": {
-					"navigationBarTitleText": "预约拍摄",
-					"navigationBarBackgroundColor": "#FFFFFF"
-				}
-			},
-			{
-				"path": "zulin",
-				"style": {
-					"navigationBarTitleText": "租赁设备",
-					"navigationBarBackgroundColor": "#FFFFFF"
-				}
-			},
-			{
-				"path": "zulin-add",
-				"style": {
-					"navigationBarTitleText": "设备租赁",
-					"navigationBarBackgroundColor": "#FFFFFF"
-				}
-			},
-			{
-				"path": "zulin-list",
-				"style": {
-					"navigationBarTitleText": "租赁记录",
-					"navigationBarBackgroundColor": "#FFFFFF"
-				}
-			},
-			{
-				"path" : "order-detail",
-				"style" : 
+					"path": "good-detail",
+					"style": {
+						"navigationBarTitleText": "商品",
+						"navigationBarBackgroundColor": "#FFFFFF"
+					}
+				},
 				{
-					"navigationBarTitleText" : "订单详情",
-					"enablePullDownRefresh" : false,
-					"navigationBarBackgroundColor": "#FFFFFF"
-				}
-			},
-			{
-				"path" : "order-list",
-				"style" : 
+					"path": "order-confirm",
+					"style": {
+						"navigationBarTitleText": "确认订单",
+						"navigationBarBackgroundColor": "#FFFFFF"
+					}
+				},
 				{
-					"navigationBarTitleText" : "兑换记录",
-					"enablePullDownRefresh" : false,
-					"navigationBarBackgroundColor": "#FFFFFF"
-				}
-			},
-			{
-				"path" : "yuyue-vip",
-				"style" : 
+					"path": "totaobao",
+					"style": {
+						"navigationBarTitleText": "跳转",
+						"navigationBarBackgroundColor": "#FFFFFF"
+					}
+				},
 				{
-					"navigationBarTitleText" : "会员预约",
-					"enablePullDownRefresh" : false,
-					"navigationBarBackgroundColor": "#FFFFFF"
-				}
-			},
-			{
-				"path" : "yuyue-list",
-				"style" : 
+					"path": "yuyue-capture",
+					"style": {
+						"navigationBarTitleText": "预约拍摄",
+						"navigationBarBackgroundColor": "#FFFFFF"
+					}
+				},
 				{
-					"navigationBarTitleText" : "预约记录",
-					"enablePullDownRefresh" : false,
-					"navigationBarBackgroundColor": "#FFFFFF"
-				}
-			}]
+					"path": "zulin",
+					"style": {
+						"navigationBarTitleText": "租赁设备",
+						"navigationBarBackgroundColor": "#FFFFFF"
+					}
+				},
+				{
+					"path": "zulin-add",
+					"style": {
+						"navigationBarTitleText": "设备租赁",
+						"navigationBarBackgroundColor": "#FFFFFF"
+					}
+				},
+				{
+					"path": "zulin-list",
+					"style": {
+						"navigationBarTitleText": "租赁记录",
+						"navigationBarBackgroundColor": "#FFFFFF"
+					}
+				},
+				{
+					"path": "order-detail",
+					"style": {
+						"navigationBarTitleText": "订单详情",
+						"enablePullDownRefresh": false,
+						"navigationBarBackgroundColor": "#FFFFFF"
+					}
+				},
+				{
+					"path": "order-list",
+					"style": {
+						"navigationBarTitleText": "兑换记录",
+						"enablePullDownRefresh": false,
+						"navigationBarBackgroundColor": "#FFFFFF"
+					}
+				},
+				{
+					"path": "yuyue-vip",
+					"style": {
+						"navigationBarTitleText": "会员预约",
+						"enablePullDownRefresh": false,
+						"navigationBarBackgroundColor": "#FFFFFF"
+					}
+				},
+				{
+					"path": "yuyue-list",
+					"style": {
+						"navigationBarTitleText": "预约记录",
+						"enablePullDownRefresh": false,
+						"navigationBarBackgroundColor": "#FFFFFF"
+					}
+				}
+			]
 		},
 		{
 			"root": "pageC",
 			"pages": [{
-				"path": "invite",
-				"style": {
-					"navigationBarTitleText": "邀请好友",
-					"navigationStyle": "custom"
-				}
-			},
-			{
-				"path": "setting",
-				"style": {
-					"navigationBarTitleText": "我的设置",
-					"navigationBarBackgroundColor": "#FFFFFF"
-				}
-			},
-			{
-				"path": "userinfo",
-				"style": {
-					"navigationBarTitleText": "账号资料",
-					"navigationBarBackgroundColor": "#FFFFFF"
-				}
-			},
-			{
-				"path": "guanzhu-list",
-				"style": {
-					"navigationBarTitleText": "已关注",
-					"navigationBarBackgroundColor": "#FFFFFF"
-				}
-			},
-			{
-				"path": "collect-list",
-				"style": {
-					"navigationBarTitleText": "我的收藏",
-					"navigationBarBackgroundColor": "#FFFFFF",
-					"navigationStyle": "custom"
-				}
-			},
-			{
-				"path": "youhuiquan",
-				"style": {
-					"navigationBarTitleText": "优惠券",
-					"navigationBarBackgroundColor": "#FFFFFF"
-				}
-			},
-			{
-				"path": "jifen-qianbao",
-				"style": {
-					"navigationBarTitleText": "积分钱包",
-					"navigationBarBackgroundColor": "#FFFFFF",
-					"navigationStyle": "custom"
-				}
-			},
-			{
-				"path": "jifen-list",
-				"style": {
-					"navigationBarTitleText": "积分明细",
-					"navigationBarBackgroundColor": "#FFFFFF"
-				}
-			},
-			{
-				"path": "zuji-list",
-				"style": {
-					"navigationBarTitleText": "我的足迹",
-					"navigationBarBackgroundColor": "#FFFFFF",
-					"navigationStyle": "custom"
-				}
-			},
-			{
-				"path": "video-list",
-				"style": {
-					"navigationBarTitleText": "视频管理",
-					"navigationBarBackgroundColor": "#FFFFFF",
-					"navigationStyle": "custom"
-				}
-			},
-			{
-				"path": "video-detail",
-				"style": {
-					"navigationBarTitleText": "视频详情",
-					"navigationBarBackgroundColor": "#FFFFFF"
-				}
-			},
-			{
-				"path": "address-list",
-				"style": {
-					"navigationBarTitleText": "地址管理",
-					"navigationBarBackgroundColor": "#FFFFFF"
-				}
-			},
-			{
-				"path": "address-add",
-				"style": {
-					"navigationBarTitleText": "收货地址",
-					"navigationBarBackgroundColor": "#FFFFFF",
-					"navigationStyle": "custom"
-				}
-			},
-			{
-				"path": "changjian-list",
-				"style": {
-					"navigationBarTitleText": "常见问题",
-					"navigationBarBackgroundColor": "#FFFFFF"
-				}
-			},
-			{
-				"path": "changjian-detail",
-				"style": {
-					"navigationBarTitleText": "常见问题",
-					"navigationBarBackgroundColor": "#FFFFFF"
-				}
-			},
-			{
-				"path": "zhiwei-list",
-				"style": {
-					"navigationBarTitleText": "加入忆象",
-					"navigationBarBackgroundColor": "#FFFFFF"
-				}
-			},
-			{
-				"path": "zhiwei-detail",
-				"style": {
-					"navigationBarTitleText": "职位详情",
-					"navigationBarBackgroundColor": "#FFFFFF",
-					"navigationStyle": "custom"
-				}
-			},
-			{
-				"path": "jianli",
-				"style": {
-					"navigationBarTitleText": "上传简历",
-					"navigationBarBackgroundColor": "#FFFFFF"
-				}
-			},
-			{
-				"path": "xieyi",
-				"style": {
-					"navigationBarTitleText": "协议",
-					"navigationBarBackgroundColor": "#FFFFFF"
-				}
-			},
-			{
-				"path" : "success",
-				"style" : 
+					"path": "invite",
+					"style": {
+						"navigationBarTitleText": "邀请好友",
+						"navigationStyle": "custom"
+					}
+				},
 				{
-					"navigationBarTitleText" : "上传简历",
-					"navigationBarBackgroundColor": "#FFFFFF"
-				}
-			},
-			{
-				"path" : "invite-list",
-				"style" : 
+					"path": "setting",
+					"style": {
+						"navigationBarTitleText": "我的设置",
+						"navigationBarBackgroundColor": "#FFFFFF"
+					}
+				},
 				{
-					"navigationBarTitleText" : "邀请与推广",
-					"navigationBarBackgroundColor": "#FFFFFF",
-					"enablePullDownRefresh" : false
-				}
-			},
-			{
-				"path" : "invite-bind",
-				"style" : 
+					"path": "userinfo",
+					"style": {
+						"navigationBarTitleText": "账号资料",
+						"navigationBarBackgroundColor": "#FFFFFF"
+					}
+				},
 				{
-					"navigationBarTitleText" : "绑定邀请人",
-					"navigationBarBackgroundColor": "#FFFFFF",
-					"enablePullDownRefresh" : false
-				}
-			},
-			{
-				"path" : "account",
-				"style" : 
+					"path": "guanzhu-list",
+					"style": {
+						"navigationBarTitleText": "已关注",
+						"navigationBarBackgroundColor": "#FFFFFF"
+					}
+				},
 				{
-					"navigationBarTitleText" : "账号安全",
-					"navigationBarBackgroundColor": "#FFFFFF",
-					"enablePullDownRefresh" : false
-				}
-			},
-			{
-				"path" : "edit-pwd",
-				"style" : 
+					"path": "collect-list",
+					"style": {
+						"navigationBarTitleText": "我的收藏",
+						"navigationBarBackgroundColor": "#FFFFFF",
+						"navigationStyle": "custom"
+					}
+				},
 				{
-					"navigationBarTitleText" : "修改密码",
-					"navigationBarBackgroundColor": "#FFFFFF",
-					"enablePullDownRefresh" : false
-				}
-			},
-			{
-				"path" : "tuisong",
-				"style" : 
+					"path": "youhuiquan",
+					"style": {
+						"navigationBarTitleText": "优惠券",
+						"navigationBarBackgroundColor": "#FFFFFF"
+					}
+				},
 				{
-					"navigationBarTitleText" : "推送通知",
-					"navigationBarBackgroundColor": "#FFFFFF",
-					"enablePullDownRefresh" : false
-				}
-			},
-			{
-				"path" : "drafts",
-				"style" : 
+					"path": "jifen-qianbao",
+					"style": {
+						"navigationBarTitleText": "积分钱包",
+						"navigationBarBackgroundColor": "#FFFFFF",
+						"navigationStyle": "custom"
+					}
+				},
 				{
-					"navigationBarTitleText" : "草稿箱",
-					"enablePullDownRefresh" : false,
-					"navigationStyle": "custom"
-				}
-			},
-			{
-				"path" : "error",
-				"style" : 
+					"path": "jifen-list",
+					"style": {
+						"navigationBarTitleText": "积分明细",
+						"navigationBarBackgroundColor": "#FFFFFF"
+					}
+				},
 				{
-					"navigationBarTitleText" : "错误反馈",
-					"navigationBarBackgroundColor": "#FFFFFF",
-					"enablePullDownRefresh" : false
-				}
-			},
-			{
-				"path" : "about",
-				"style" : 
+					"path": "zuji-list",
+					"style": {
+						"navigationBarTitleText": "我的足迹",
+						"navigationBarBackgroundColor": "#FFFFFF",
+						"navigationStyle": "custom"
+					}
+				},
 				{
-					"navigationBarTitleText" : "关于我们",
-					"navigationBarBackgroundColor": "#FFFFFF",
-					"enablePullDownRefresh" : false
-				}
-			},
-			{
-				"path" : "paihang",
-				"style" : 
+					"path": "video-list",
+					"style": {
+						"navigationBarTitleText": "视频管理",
+						"navigationBarBackgroundColor": "#FFFFFF",
+						"navigationStyle": "custom"
+					}
+				},
 				{
-					"navigationBarTitleText" : "排行榜",
-					"navigationBarBackgroundColor": "#FFFFFF",
-					"enablePullDownRefresh" : false
-				}
-			},
-			{
-				"path" : "vip",
-				"style" : 
+					"path": "video-detail",
+					"style": {
+						"navigationBarTitleText": "视频详情",
+						"navigationBarBackgroundColor": "#FFFFFF"
+					}
+				},
 				{
-					"navigationBarTitleText" : "会员福利",
-					"enablePullDownRefresh" : false,
-					"navigationStyle": "custom"
-				}
-			},
-			{
-				"path" : "calendar",
-				"style" : 
+					"path": "address-list",
+					"style": {
+						"navigationBarTitleText": "地址管理",
+						"navigationBarBackgroundColor": "#FFFFFF"
+					}
+				},
 				{
-					"navigationBarTitleText" : "签到日历",
-					"enablePullDownRefresh" : false,
-					"navigationStyle": "custom"
-				}
-			}]
+					"path": "address-add",
+					"style": {
+						"navigationBarTitleText": "收货地址",
+						"navigationBarBackgroundColor": "#FFFFFF",
+						"navigationStyle": "custom"
+					}
+				},
+				{
+					"path": "changjian-list",
+					"style": {
+						"navigationBarTitleText": "常见问题",
+						"navigationBarBackgroundColor": "#FFFFFF"
+					}
+				},
+				{
+					"path": "changjian-detail",
+					"style": {
+						"navigationBarTitleText": "常见问题",
+						"navigationBarBackgroundColor": "#FFFFFF"
+					}
+				},
+				{
+					"path": "zhiwei-list",
+					"style": {
+						"navigationBarTitleText": "加入忆象",
+						"navigationBarBackgroundColor": "#FFFFFF"
+					}
+				},
+				{
+					"path": "zhiwei-detail",
+					"style": {
+						"navigationBarTitleText": "职位详情",
+						"navigationBarBackgroundColor": "#FFFFFF",
+						"navigationStyle": "custom"
+					}
+				},
+				{
+					"path": "jianli",
+					"style": {
+						"navigationBarTitleText": "上传简历",
+						"navigationBarBackgroundColor": "#FFFFFF"
+					}
+				},
+				{
+					"path": "xieyi",
+					"style": {
+						"navigationBarTitleText": "协议",
+						"navigationBarBackgroundColor": "#FFFFFF"
+					}
+				},
+				{
+					"path": "success",
+					"style": {
+						"navigationBarTitleText": "上传简历",
+						"navigationBarBackgroundColor": "#FFFFFF"
+					}
+				},
+				{
+					"path": "invite-list",
+					"style": {
+						"navigationBarTitleText": "邀请与推广",
+						"navigationBarBackgroundColor": "#FFFFFF",
+						"enablePullDownRefresh": false
+					}
+				},
+				{
+					"path": "invite-bind",
+					"style": {
+						"navigationBarTitleText": "绑定邀请人",
+						"navigationBarBackgroundColor": "#FFFFFF",
+						"enablePullDownRefresh": false
+					}
+				},
+				{
+					"path": "account",
+					"style": {
+						"navigationBarTitleText": "账号安全",
+						"navigationBarBackgroundColor": "#FFFFFF",
+						"enablePullDownRefresh": false
+					}
+				},
+				{
+					"path": "edit-pwd",
+					"style": {
+						"navigationBarTitleText": "修改密码",
+						"navigationBarBackgroundColor": "#FFFFFF",
+						"enablePullDownRefresh": false
+					}
+				},
+				{
+					"path": "tuisong",
+					"style": {
+						"navigationBarTitleText": "推送通知",
+						"navigationBarBackgroundColor": "#FFFFFF",
+						"enablePullDownRefresh": false
+					}
+				},
+				{
+					"path": "drafts",
+					"style": {
+						"navigationBarTitleText": "草稿箱",
+						"enablePullDownRefresh": false,
+						"navigationStyle": "custom"
+					}
+				},
+				{
+					"path": "error",
+					"style": {
+						"navigationBarTitleText": "错误反馈",
+						"navigationBarBackgroundColor": "#FFFFFF",
+						"enablePullDownRefresh": false
+					}
+				},
+				{
+					"path": "about",
+					"style": {
+						"navigationBarTitleText": "关于我们",
+						"navigationBarBackgroundColor": "#FFFFFF",
+						"enablePullDownRefresh": false
+					}
+				},
+				{
+					"path": "paihang",
+					"style": {
+						"navigationBarTitleText": "排行榜",
+						"navigationBarBackgroundColor": "#FFFFFF",
+						"enablePullDownRefresh": false
+					}
+				},
+				{
+					"path": "vip",
+					"style": {
+						"navigationBarTitleText": "会员福利",
+						"enablePullDownRefresh": false,
+						"navigationStyle": "custom"
+					}
+				},
+				{
+					"path": "calendar",
+					"style": {
+						"navigationBarTitleText": "签到日历",
+						"enablePullDownRefresh": false,
+						"navigationStyle": "custom"
+					}
+				},
+				{
+					"path" : "otherInfo",
+					"style" : 
+					{
+						"navigationBarTitleText" : "",
+						"enablePullDownRefresh" : false,
+						"navigationStyle": "custom"
+					}
+				}
+			]
 		}
 	],
 	"tabBar": {
@@ -524,8 +519,7 @@
 		"fontSize": "10px",
 		"selectedColor": "#00B0B0",
 		"spacing": "4rpx",
-		"list": [
-			{
+		"list": [{
 				"iconPath": "static/images/home.png",
 				"selectedIconPath": "static/images/home1.png",
 				"pagePath": "pages/index/index",
@@ -558,4 +552,4 @@
 		"backgroundColor": "#F8F8F8"
 	},
 	"uniIdRouter": {}
-}
+}

+ 157 - 80
pages/index/index.vue

@@ -2,20 +2,21 @@
 	<view class="content" @click="show_add = false">
 		<u-navbar title=" " bgColor="#00B0B0" :autoBack="false" :placeholder="true" :fixed="true" height="44">
 			<view class="search" slot="left">
-				<u-search placeholder=""  v-model="search" :disabled="true" :showAction="false" @click="tosearch"></u-search>
+				<u-search placeholder="" v-model="search" :disabled="true" :showAction="false"
+					@click="tosearch"></u-search>
 			</view>
 			<view class="search-right hflex acenter" slot="right">
 				<view class="img" @click="tomessage">
 					<image src="@/static/images/message.png" mode="aspectFill"></image>
-					<u-badge type="error" :offset="[0,0]" :absolute="true" :value="news_number"></u-badge>
+					<u-badge type="error" :offset="[-10,-10]" :absolute="true" :value="news_number"></u-badge>
 				</view>
 				<image src="@/static/images/add.png" mode="aspectFill" @click.stop="show_add = !show_add"></image>
 				<view class="add-show" v-if="show_add">
-					<view class="hflex acenter show-item" @click="toadd('zixun')">
+					<view class="hflex acenter show-item" @click="toadd('info')">
 						<image src="@/static/images/add-zixun.png" mode="aspectFill"></image>
 						<text>发布资讯</text>
 					</view>
-					<view class="hflex acenter show-item" @click="toadd('wenzhang')">
+					<view class="hflex acenter show-item" @click="toadd('article')">
 						<image src="@/static/images/add-wenzhang.png" mode="aspectFill"></image>
 						<text>发布文章</text>
 					</view>
@@ -23,7 +24,7 @@
 						<image src="@/static/images/add-shipin.png" mode="aspectFill"></image>
 						<text>发布视频</text>
 					</view>
-					<view class="hflex acenter show-item" @click="toadd('luntan')">
+					<view class="hflex acenter show-item" @click="toadd('post')">
 						<image src="@/static/images/add-luntan.png" mode="aspectFill"></image>
 						<text>发布论坛</text>
 					</view>
@@ -32,11 +33,11 @@
 		</u-navbar>
 		<view class="tabs hflex acenter">
 			<u-sticky bgColor="#fff" offset-top="88" customNavHeight="44" zIndex="99">
-			    <u-tabs :list="tabs" lineWidth="0" @click="tochangetabs" :scrollable="true" :current="current"
-			     :inactiveStyle="{color: '#666666',fontSize: '30rpx',}"
-			     :activeStyle="{color: '#00B0B0',fontWeight: 'bold',fontSize: '32rpx',}"></u-tabs>
+				<u-tabs :list="tabs" lineWidth="0" @click="tochangetabs" :scrollable="true" :current="current"
+					:inactiveStyle="{color: '#666666',fontSize: '30rpx',}"
+					:activeStyle="{color: '#00B0B0',fontWeight: 'bold',fontSize: '32rpx',}"></u-tabs>
 			</u-sticky>
-			
+
 		</view>
 		<swiper class="index-swiper" :circular="false" :autoplay="false" :current="current" @change="swipertotabs">
 			<!-- 福利 -->
@@ -54,9 +55,11 @@
 							</view>
 						</view>
 						<view class="fuli-box">
-							<view class="box-title">当前等级<span style="font-size: 40rpx;color: #57C3C2;">{{user.level}}</span>级</view>
+							<view class="box-title">当前等级<span
+									style="font-size: 40rpx;color: #57C3C2;">{{user.level}}</span>级</view>
 							<view class="box-list hflex acenter">
-								<view class="list-item vflex acenter jcenter"  v-for="(item,index) in vip_list" :key="index">
+								<view class="list-item vflex acenter jcenter" v-for="(item,index) in vip_list"
+									:key="index">
 									<image :src="item.prize_image" mode="aspectFill"></image>
 									<text :style="item.is_receive == 1 ? 'color: #CCCCCC;' : ''">达到{{item.days}}级</text>
 								</view>
@@ -66,15 +69,17 @@
 					<view class="fuli">
 						<view class="title hflex acenter jbetween">
 							<text>签到领福利</text>
-							<view class="hflex acenter title-right">
+							<view class="hflex acenter title-right" @click="toqiandao">
 								<text>全部</text>
 								<image src="/static/images/arrow-right.png" mode="aspectFill"></image>
 							</view>
 						</view>
 						<view class="fuli-box">
-							<view class="box-title">已连续签到<span style="font-size: 40rpx;color: #57C3C2;">20</span>天</view>
+							<view class="box-title">已连续签到<span style="font-size: 40rpx;color: #57C3C2;">20</span>天
+							</view>
 							<view class="box-list hflex acenter">
-								<view class="list-item vflex acenter jcenter"  v-for="(item,index) in qiandao_list" :key="index">
+								<view class="list-item vflex acenter jcenter" v-for="(item,index) in qiandao_list"
+									:key="index">
 									<image :src="item.prize_image" mode="aspectFill"></image>
 									<text :style="item.is_receive == 1 ? 'color: #CCCCCC;' : ''">连签{{item.days}}天</text>
 								</view>
@@ -92,7 +97,8 @@
 						<u-button class="login-btn" @click="tologin" text="登录忆象" v-if="!login"></u-button>
 					</view>
 					<view class="list1" v-else>
-						<list-info type="post" :data="item" v-for="(item,index) in list" :key="index" @toinfo="toinfo(item)"></list-info>
+						<list-info :data="item" v-for="(item,index) in list" :key="index"
+							@toinfo="toinfo(item)"></list-info>
 					</view>
 				</view>
 			</swiper-item>
@@ -104,7 +110,8 @@
 						<view class="vflex" v-if="zixun_list.length>0">
 							<view class="title">精选资讯</view>
 							<view class="vflex">
-								<wenzhang-info type="info" :data="item" v-for="(item,index) in zixun_list.slice(0,3)" :key="index" @toinfo="toinfo(item)"></wenzhang-info>
+								<wenzhang-info type="info" :data="item" v-for="(item,index) in zixun_list.slice(0,3)"
+									:key="index" @toinfo="toinfo(item)"></wenzhang-info>
 								<view class="more-btn" @click="tomore('info')">查看更多资讯</view>
 							</view>
 						</view>
@@ -114,7 +121,8 @@
 								<view class="more-text" @click="tomore('topic')">查看更多</view>
 							</view>
 							<view class="vflex">
-								<view class="circle-item hflex acenter" v-for="(item,index) in circle_list" :key="index">
+								<view class="circle-item hflex acenter" v-for="(item,index) in circle_list"
+									:key="index">
 									<!-- <image :src="item.img" mode="aspectFill" class="circle-img"></image> -->
 									<text class="circle-text" @click="tohuati(item)">{{item.title}}</text>
 								</view>
@@ -125,20 +133,23 @@
 								<view class="title">精选文章</view>
 								<view class="more-text" @click="tomore('article')">查看更多</view>
 							</view>
-							<wenzhang-info type="article" :data="item" v-for="(item,index) in wenzhang_list.slice(0,3)" :key="index" @toinfo="toinfo(item)"></wenzhang-info>
+							<wenzhang-info type="article" :data="item" v-for="(item,index) in wenzhang_list.slice(0,3)"
+								:key="index" @toinfo="toinfo(item)"></wenzhang-info>
 						</view>
 						<view class="vflex" v-if="video_list.length>0">
 							<view class="hflex acenter jbetween">
 								<view class="title">精选视频</view>
 								<view class="more-text" @click="tomore('video')">查看更多</view>
 							</view>
-							<view class="videos hflex acenter" >
-								<video-list :item="item" v-for="(item,index) in video_list" :key="index" @toinfo="toinfo(item)"></video-list>
-							</view>
+							<scroll-view :scroll-x="true" style="white-space: nowrap;" class="videos hflex acenter">
+								<video-list :item="item" v-for="(item,index) in video_list" :key="index"
+									@toinfo="toinfo(item)"></video-list>
+							</scroll-view>
 						</view>
 					</view>
 					<view class="list1">
-						<list-info type="post" :data="item" v-for="(item,index) in list" :key="index" @toinfo="toinfo(item)"></list-info>
+						<list-info type="post" :data="item" v-for="(item,index) in list" :key="index"
+							@toinfo="toinfo(item)"></list-info>
 					</view>
 				</view>
 			</swiper-item>
@@ -152,11 +163,12 @@
 						<view class="vflex" v-for="(item,index) in zixun_list" :key="index">
 							<view class="title">{{item.date}}</view>
 							<view class="vflex">
-								<wenzhang-info type="info" :data="a" v-for="(a,b) in item.list" :key="index" @toinfo="toinfo(a)"></wenzhang-info>
+								<wenzhang-info type="info" :data="a" v-for="(a,b) in item.list" :key="index"
+									@toinfo="toinfo(a)"></wenzhang-info>
 							</view>
 						</view>
 					</view>
-					
+
 				</view>
 			</swiper-item>
 			<!-- 文章 -->
@@ -170,13 +182,15 @@
 								<view class="more-text" @click="tomore('article')">查看更多</view>
 							</view>
 						</view>
-						
+
 					</view>
-					<list-info type="article" :data="item" v-for="(item,index) in wenzhang_list" :key="index" @toinfo="toinfo(item)"></list-info>
+					<list-info type="article" :data="item" v-for="(item,index) in wenzhang_list" :key="index"
+						@toinfo="toinfo(item)"></list-info>
 					<view class="vflex" v-if="list.length>0">
 						<view class="list-title2">最新文章</view>
 					</view>
-					<list-info type="article" :data="item" v-for="(item,index) in list" :key="index" @toinfo="toinfo(item)"></list-info>
+					<list-info type="article" :data="item" v-for="(item,index) in list" :key="index"
+						@toinfo="toinfo(item)"></list-info>
 				</view>
 			</swiper-item>
 			<!-- 视频 -->
@@ -189,14 +203,16 @@
 								<view class="title">精选视频</view>
 								<view class="more-text" @click="tomore('video')">查看更多</view>
 							</view>
-							<view class="videos hflex acenter" >
-								<video-list :item="item" v-for="(item,index) in video_list" :key="index" @toinfo="toinfo(item)"></video-list>
+							<view class="videos hflex acenter">
+								<video-list :item="item" v-for="(item,index) in video_list" :key="index"
+									@toinfo="toinfo(item)"></video-list>
 							</view>
 						</view>
 					</view>
 					<view class="list1">
 						<view class="list-title">最新视频</view>
-						<list-info type="video" :data="item" v-for="(item,index) in list" :key="index" @toinfo="toinfo(item)"></list-info>
+						<list-info type="video" :data="item" v-for="(item,index) in list" :key="index"
+							@toinfo="toinfo(item)"></list-info>
 					</view>
 				</view>
 			</swiper-item>
@@ -222,8 +238,7 @@
 		data() {
 			return {
 				search: '',
-				tabs: [
-					{
+				tabs: [{
 						id: 0,
 						name: '福利'
 					},
@@ -251,8 +266,8 @@
 						name: '视频'
 					},
 				],
-				news_number: 1,//消息数量
-				guanzhu_num: 1,//关注的数量
+				news_number: 0, //消息数量
+				guanzhu_num: 1, //关注的数量
 				current: 2,
 				scrollable: false,
 				list: [],
@@ -271,19 +286,22 @@
 			}
 		},
 		onLoad() {
+
 		},
 		onShow() {
 			this.login = uni.getStorageSync('token') ? true : false
 			this.getuser()
+			this.page = 1
 			this.list = []
 			this.zixun_list = []
 			this.wenzhang_list = []
 			this.circle_list = []
 			this.video_list = []
 			this.getlist()
+			this.getNum()
 		},
 		onReachBottom() {
-			if(this.last_page > this.page) {
+			if (this.last_page > this.page) {
 				this.page++
 				this.getlist()
 			} else {
@@ -291,6 +309,20 @@
 			}
 		},
 		methods: {
+			
+			toqiandao() {
+				uni.navigateTo({
+					url: '/pageC/calendar'
+				})
+			},
+			getNum() {
+				var that = this
+				$api.req({
+					url: 'notification/sum',
+				}, function(res) {
+					that.news_number = res.data
+				})
+			},
 			tohuati(item) {
 				uni.navigateTo({
 					url: '/pageA/topic-detail?id=' + item.id
@@ -302,13 +334,13 @@
 					url: 'user/info',
 					methos: 'GET'
 				}, function(res) {
-					if(res.code == 10000) {
+					if (res.code == 10000) {
 						_this.user = res.data
 					}
 				})
 			},
 			tomore(type) {
-				if(type == 'topic') {
+				if (type == 'topic') {
 					uni.navigateTo({
 						url: '/pageA/huati'
 					})
@@ -325,7 +357,7 @@
 			},
 			/* 发布 */
 			toadd(val) {
-				if(val == 'luntan') {
+				if (val == 'post') {
 					uni.navigateTo({
 						url: '/pageA/add-luntan'
 					})
@@ -345,7 +377,7 @@
 			/* 点击切换tabs */
 			tochangetabs(item) {
 				this.current = item.id
-				
+
 			},
 			/* 滑动切换tabs */
 			swipertotabs(e) {
@@ -364,8 +396,8 @@
 			/* 轮播图点击事件 */
 			swiperclick(e) {
 				var data = this.swiper_list[e]
-				if(data.is_jump == 1) {
-					if(data.jump_type == 'external') {
+				if (data.is_jump == 1) {
+					if (data.jump_type == 'external') {
 						window.location.href = data.jump_url
 					} else {
 						uni.navigateTo({
@@ -375,20 +407,18 @@
 				}
 			},
 			getswiperlist() {
-				if(this.current == 0 || this.current == 1) {
-					return 
+				if (this.current == 0 || this.current == 1) {
+					return
 				}
 				var _this = this
 				var type = ''
-				if(_this.current == 2) {
+				if (_this.current == 2) {
 					type = 'index'
-				} else if(_this.current == 3) {
+				} else if (_this.current == 3) {
 					type = 'info'
-				}
-				else if(_this.current == 4) {
+				} else if (_this.current == 4) {
 					type = 'article'
-				}
-				else if(_this.current == 5) {
+				} else if (_this.current == 5) {
 					type = 'video'
 				}
 				$api.req({
@@ -398,7 +428,7 @@
 						limit: 5
 					}
 				}, function(res) {
-					if(res.code == 10000) {
+					if (res.code == 10000) {
 						_this.swiper_list = res.data
 					}
 				})
@@ -406,7 +436,7 @@
 			/* 获取列表 */
 			getlist() {
 				var _this = this
-				if(_this.current == 0) {
+				if (_this.current == 0) {
 					$api.req({
 						url: "sign/prize",
 						data: {
@@ -420,8 +450,8 @@
 						url: '',
 						
 					}) */
-				} 
-				if(_this.current == 1) {
+				}
+				if (_this.current == 1) {
 					$api.req({
 						url: 'summary',
 						method: 'GET',
@@ -434,13 +464,13 @@
 							order_type: 'desc'
 						}
 					}, function(res) {
-						if(res.code == 10000) {
+						if (res.code == 10000) {
 							_this.list = _this.list.concat(res.data.list)
 							_this.last_page = res.data.last_page
 						}
 					})
-				} 
-				if(_this.current == 2) {
+				}
+				if (_this.current == 2) {
 					/* $api.req({
 						url: 'info',
 						method: 'GET',
@@ -506,7 +536,7 @@
 							is_recommend: 1
 						}
 					}, function(res) {
-						if(res.code == 10000) {
+						if (res.code == 10000) {
 							_this.circle_list = res.data.list
 						}
 					})
@@ -520,7 +550,7 @@
 							is_boutique: 1
 						}
 					}, function(res) {
-						if(res.code == 10000) {
+						if (res.code == 10000) {
 							_this.zixun_list = res.data.info
 							_this.wenzhang_list = res.data.article
 							_this.video_list = res.data.video
@@ -536,13 +566,13 @@
 							status: 'normal'
 						}
 					}, function(res) {
-						if(res.code == 10000) {
+						if (res.code == 10000) {
 							_this.list = _this.list.concat(res.data.list)
 							_this.last_page = res.data.last_page
 						}
 					})
 				}
-				if(_this.current == 3) {
+				if (_this.current == 3) {
 					$api.req({
 						url: 'info',
 						method: 'GET',
@@ -555,7 +585,7 @@
 							is_boutique: 0
 						}
 					}, function(res) {
-						if(res.code == 10000) {
+						if (res.code == 10000) {
 							_this.zixun_list = _this.zixun_list.concat(res.data)
 							/* for(var i=0;i<_this.zixun_list.length;i++) {
 								if(_this.zixun_list[i].date == _this.zixun_list[i+1].date) {
@@ -567,7 +597,7 @@
 						}
 					})
 				}
-				if(_this.current == 4) {
+				if (_this.current == 4) {
 					$api.req({
 						url: 'article',
 						method: 'GET',
@@ -579,7 +609,7 @@
 							is_boutique: 1
 						}
 					}, function(res) {
-						if(res.code == 10000) {
+						if (res.code == 10000) {
 							_this.wenzhang_list = _this.wenzhang_list.concat(res.data.list)
 						}
 					})
@@ -593,13 +623,13 @@
 							status: 'normal'
 						}
 					}, function(res) {
-						if(res.code == 10000) {
+						if (res.code == 10000) {
 							_this.list = _this.list.concat(res.data.list)
 							_this.last_page = res.data.last_page
 						}
 					})
 				}
-				if(_this.current == 5) {
+				if (_this.current == 5) {
 					$api.req({
 						url: 'video',
 						method: 'GET',
@@ -610,7 +640,7 @@
 							is_boutique: 1
 						}
 					}, function(res) {
-						if(res.code == 10000) {
+						if (res.code == 10000) {
 							_this.video_list = _this.video_list.concat(res.data.list)
 						}
 					})
@@ -623,13 +653,13 @@
 							status: 'normal'
 						}
 					}, function(res) {
-						if(res.code == 10000) {
+						if (res.code == 10000) {
 							_this.list = _this.list.concat(res.data.list)
 							_this.last_page = res.data.last_page
 						}
 					})
 				}
-				
+
 			},
 			/* 去登录 */
 			tologin() {
@@ -637,7 +667,7 @@
 					url: '/pages/login/index'
 				})
 			},
-			
+
 			/* 点击左侧区域 */
 			leftClick() {
 				return
@@ -664,32 +694,46 @@
 			box-sizing: border-box;
 			background: #FFFFFF;
 		}
+
+		.uni-scroll-view-content {
+			display: flex;
+			flex-wrap: nowrap;
+		}
+
 		.index-swiper {
 			padding: 144rpx 0 0;
 			min-height: calc(100vh - 88rpx);
 			height: 1rpx;
+
 			.swiper-item {
 				height: 100%;
 				overflow: auto;
+
 				.vip {
 					background: #FFFFFF;
 					padding: 28rpx 24rpx 44rpx;
 				}
+
 				.fuli {
-					padding: 24rpx 28rpx ;
+					padding: 24rpx 28rpx;
+
 					.fuli-box {
 						margin: 24rpx 0 32rpx;
 						background: #FFFFFF;
 						border-radius: 16rpx;
 						padding: 16rpx 28rpx;
+
 						.box-list {
-							padding: 20rpx  0 0;
+							padding: 20rpx 0 0;
+
 							.list-item {
 								margin: 0 32rpx 0 0;
+
 								image {
 									width: 100rpx;
 									height: 100rpx;
 								}
+
 								text {
 									padding: 22rpx 0 0;
 									font-size: 24rpx;
@@ -698,11 +742,13 @@
 									color: #444444;
 								}
 							}
+
 							.list-item:last-child {
 								margin: 0;
 							}
-							
+
 						}
+
 						.box-title {
 							font-size: 28rpx;
 							font-family: PingFangSC, PingFang SC;
@@ -710,6 +756,7 @@
 							color: #333333;
 						}
 					}
+
 					.title {
 						text {
 							font-size: 32rpx;
@@ -717,31 +764,36 @@
 							font-weight: 600;
 							color: #222222;
 						}
+
 						.title-right {
 							text {
 								font-size: 24rpx;
 								font-family: PingFangSC, PingFang SC;
 								font-weight: 400;
 							}
+
 							image {
 								width: 28rpx;
 								height: 28rpx;
 							}
 						}
-						
+
 					}
 				}
 			}
 		}
+
 		.top {
 			padding: 20rpx 28rpx 24rpx;
 			margin-bottom: 20rpx;
 			background: #fff;
+
 			.videos {
 				width: 100%;
 				overflow: auto;
 				// white-space: nowrap;
 			}
+
 			.title {
 				font-size: 32rpx;
 				font-family: PingFangSC, PingFang SC;
@@ -749,6 +801,7 @@
 				color: #333333;
 				padding: 24rpx 0;
 			}
+
 			.more-btn {
 				width: 100%;
 				font-size: 26rpx;
@@ -760,22 +813,26 @@
 				padding: 22rpx 0;
 				text-align: center;
 			}
+
 			.more-text {
 				font-size: 24rpx;
 				font-family: PingFangSC, PingFang SC;
 				font-weight: 400;
 				color: #666666;
 			}
+
 			.circle-item {
 				// width: 100%;
 				background: #F1F4F4;
 				border-radius: 12rpx;
 				padding: 26rpx 0 26rpx 36rpx;
 				margin: 0 0 20rpx;
+
 				.circle-img {
 					width: 40rpx;
 					height: 40rpx;
 				}
+
 				.circle-text {
 					font-size: 28rpx;
 					font-family: AppleColorEmoji;
@@ -783,51 +840,64 @@
 				}
 			}
 		}
+
 		.search {
 			width: 572rpx;
-			background: rgba(255,255,255,.3);
+			background: rgba(255, 255, 255, .3);
 			border-radius: 32rpx;
+
 			.u-search__content {
-				background: rgba(255,255,255,.3)!important;
+				background: rgba(255, 255, 255, .3) !important;
 			}
+
 			.u-search__content__input {
 				background-color: unset !important;
 			}
+
 			.u-search__content__icon {
 				background-color: unset !important;
+
 				.u-icon__icon {
 					color: #fff !important;
 				}
 			}
+
 			input {
-				background: rgba(255,255,255,.3)
+				background: rgba(255, 255, 255, .3)
 			}
-			
+
 		}
+
 		.search-right {
+
 			// padding: 0 32rpx 0 0;
 			.img {
 				position: relative;
 			}
+
 			image {
 				width: 40rpx;
 				height: 40rpx;
 				margin-left: 20rpx;
 			}
+
 			.add-show {
 				position: absolute;
 				right: 30rpx;
 				top: 88rpx;
 				background: #FFFFFF;
-				box-shadow: 0rpx 4rpx 20rpx 0rpx rgba(0,0,0,0.1);
+				box-shadow: 0rpx 4rpx 20rpx 0rpx rgba(0, 0, 0, 0.1);
 				padding: 42rpx 32rpx 0;
+
 				.show-item {
 					margin-bottom: 40rpx;
+
 					image {
 						width: 36rpx;
 						height: 36rpx;
 						margin: 0;
 					}
+
 					text {
 						white-space: nowrap;
 						font-size: 26rpx;
@@ -839,6 +909,7 @@
 				}
 			}
 		}
+
 		.tabs {
 			position: fixed;
 			top: 144rpx;
@@ -847,13 +918,16 @@
 			background: #fff;
 			z-index: 9;
 			border-bottom: 1px solid #eee;
+
 			.u-tabs__wrapper__nav__item {
 				padding: 0 66rpx 0 0 !important;
 			}
 		}
+
 		.list {
 			background: #fff;
 			min-height: 90vh;
+
 			.title {
 				font-size: 32rpx;
 				font-family: SFPro, SFPro;
@@ -861,12 +935,14 @@
 				color: #333333;
 				padding-bottom: 20rpx;
 			}
+
 			.empty {
 				font-size: 40rpx;
 				font-family: PingFangSC, PingFang SC;
 				font-weight: 500;
 				color: #999999;
 			}
+
 			.empty-text {
 				font-size: 24rpx;
 				font-family: PingFangSC, PingFang SC;
@@ -874,6 +950,7 @@
 				color: #999999;
 				padding: 24rpx 0 40rpx;
 			}
+
 			.login-btn {
 				width: 198rpx;
 				height: 76rpx;
@@ -885,6 +962,7 @@
 				color: #FFFFFF;
 			}
 		}
+
 		.list1 {
 			.list-title {
 				width: 100%;
@@ -897,5 +975,4 @@
 			}
 		}
 	}
-
-</style>
+</style>

+ 72 - 23
pages/luntan/index.vue

@@ -2,18 +2,19 @@
 	<view class="luntan-index">
 		<u-navbar title=" " bgColor="#00B0B0" :autoBack="false" :placeholder="true" :fixed="true" height="44">
 			<view class="search" slot="left">
-				<u-search placeholder=""  v-model="search" :disabled="true" :showAction="false" @click="tosearch"></u-search>
+				<u-search placeholder="" v-model="search" :disabled="true" :showAction="false"
+					@click="tosearch"></u-search>
 				<!-- <u-search placeholder="" v-model="search" :showAction="false" @search="tosearch"></u-search> -->
 			</view>
 			<view class="search-right hflex acenter" slot="right">
 				<image src="@/static/images/menu.png" mode="aspectFill"></image>
 				<image src="@/static/images/add.png" mode="aspectFill" @click.stop="show_add = !show_add"></image>
 				<view class="add-show" v-if="show_add">
-					<view class="hflex acenter show-item" @click="toadd('zixun')">
+					<view class="hflex acenter show-item" @click="toadd('info')">
 						<image src="@/static/images/add-zixun.png" mode="aspectFill"></image>
 						<text>发布资讯</text>
 					</view>
-					<view class="hflex acenter show-item" @click="toadd('wenzhang')">
+					<view class="hflex acenter show-item" @click="toadd('article')">
 						<image src="@/static/images/add-wenzhang.png" mode="aspectFill"></image>
 						<text>发布文章</text>
 					</view>
@@ -21,7 +22,7 @@
 						<image src="@/static/images/add-shipin.png" mode="aspectFill"></image>
 						<text>发布视频</text>
 					</view>
-					<view class="hflex acenter show-item" @click="toadd('luntan')">
+					<view class="hflex acenter show-item" @click="toadd('post')">
 						<image src="@/static/images/add-luntan.png" mode="aspectFill"></image>
 						<text>发布论坛</text>
 					</view>
@@ -56,6 +57,10 @@
 		<view class="list">
 			<listinfo type="post" :data="item" v-for="(item,index) in list" :key="index"></listinfo>
 		</view>
+		<view class="fixed hflex acenter jcenter" @click="toadd('luntan')">
+			<u-icon name="edit-pen-fill" color="#00b0b0" size="20"></u-icon>
+			<text class="text">参与</text>
+		</view>
 	</view>
 </template>
 
@@ -84,15 +89,17 @@
 		},
 		onLoad() {
 			this.getswiper()
-		},
-		onShow() {
+			this.page = 1
 			this.list = []
 			this.getlist()
 			this.tuijian_list = []
 			this.gettuijian()
 		},
+		onShow() {
+			
+		},
 		onReachBottom() {
-			if(this.last_page == this.page) {
+			if (this.last_page == this.page) {
 				uni.$u.toast('已经到底了')
 				return
 			} else {
@@ -123,10 +130,12 @@
 						limit: 9,
 					}
 				}, function(res) {
-					if(res.code == 10000) {
+					if (res.code == 10000) {
 						var huati_list = res.data.list
-						_this.tuijian_list = Array.from({ length: Math.ceil(huati_list.length / 3) }, (_, i) => {
-						    return huati_list.slice(i * 3, i * 3 + 3);
+						_this.tuijian_list = Array.from({
+							length: Math.ceil(huati_list.length / 3)
+						}, (_, i) => {
+							return huati_list.slice(i * 3, i * 3 + 3);
 						});
 					}
 				})
@@ -141,7 +150,7 @@
 						limit: 5
 					}
 				}, function(res) {
-					if(res.code == 10000) {
+					if (res.code == 10000) {
 						_this.swiper_list = res.data
 					}
 				})
@@ -154,9 +163,9 @@
 			getlist() {
 				var _this = this
 				var order = 'id'
-				if(this.current == 1) {
+				if (this.current == 1) {
 					order = 'like_count'
-				} else if(this.current == 2) {
+				} else if (this.current == 2) {
 					order = 'comment_count'
 				}
 				$api.req({
@@ -168,7 +177,7 @@
 						order: order
 					}
 				}, function(res) {
-					if(res.code == 10000) {
+					if (res.code == 10000) {
 						_this.list = _this.list.concat(res.data.list)
 						_this.last_page = res.data.last_page
 					}
@@ -176,7 +185,7 @@
 			},
 			/* 发布 */
 			toadd(val) {
-				if(val == 'luntan') {
+				if (val == 'post') {
 					uni.navigateTo({
 						url: '/pageA/add-luntan'
 					})
@@ -201,11 +210,32 @@
 	.luntan-index::v-deep {
 		background: #F5F5F5;
 		min-height: 100vh;
+
+		.fixed {
+			position: fixed;
+			bottom: 152rpx;
+			left: 270rpx;
+			z-index: 999;
+			width: 210rpx;
+			height: 84rpx;
+			background: #FFFFFF;
+			box-shadow: 0rpx 0rpx 48rpx -12rpx rgba(0, 0, 0, 0.2);
+			border-radius: 42rpx;
+
+			.text {
+				font-size: 32rpx;
+				color: #00B0B0;
+				padding: 0 0 0 18rpx;
+				line-height: 44rpx;
+			}
+		}
+
 		.top {
 			box-sizing: border-box;
 			width: 100%;
 			background: #FFFFFF;
 			padding: 20rpx 28rpx;
+
 			.title {
 				font-size: 32rpx;
 				font-family: PingFangSC, PingFang SC;
@@ -213,22 +243,24 @@
 				color: #333333;
 				padding: 24rpx 0;
 			}
-			
+
 			.more-text {
 				font-size: 24rpx;
 				font-family: PingFangSC, PingFang SC;
 				font-weight: 400;
 				color: #666666;
 			}
+
 			.huati {
 				padding-bottom: 36rpx;
+
 				.tuijian {
 					width: 100%;
 					height: 248rpx;
 					overflow: auto;
 					height: 248rpx;
 					white-space: nowrap;
-					
+
 					.tuijian-item {
 						flex-shrink: 0;
 						width: 494rpx;
@@ -238,6 +270,7 @@
 						margin: 0 20rpx 0 0;
 						box-sizing: border-box;
 						padding: 28rpx 24rpx 0;
+
 						.item-box {
 							font-size: 28rpx;
 							color: #333333;
@@ -247,66 +280,82 @@
 					}
 				}
 			}
+
 			.tabs {
 				.line {
-					padding:  0 18rpx;
+					padding: 0 18rpx;
 				}
+
 				text {
 					font-size: 28rpx;
 					font-family: PingFangSC, PingFang SC;
 					font-weight: 400;
 					color: rgba(34, 34, 34, .6);
 				}
+
 				.tabs-active {
 					color: #222222 !important;
 				}
 			}
 		}
+
 		.search {
 			width: 572rpx;
-			background: rgba(255,255,255,.3);
+			background: rgba(255, 255, 255, .3);
 			border-radius: 32rpx;
+
 			.u-search__content {
-				background: rgba(255,255,255,.3)!important;
+				background: rgba(255, 255, 255, .3) !important;
 			}
+
 			.u-search__content__input {
 				background-color: unset !important;
 			}
+
 			.u-search__content__icon {
 				background-color: unset !important;
+
 				.u-icon__icon {
 					color: #fff !important;
 				}
 			}
+
 			input {
-				background: rgba(255,255,255,.3)
+				background: rgba(255, 255, 255, .3)
 			}
-			
+
 		}
+
 		.search-right {
+
 			// padding: 0 32rpx 0 0;
 			.img {
 				position: relative;
 			}
+
 			image {
 				width: 40rpx;
 				height: 40rpx;
 				margin-left: 20rpx;
 			}
+
 			.add-show {
 				position: absolute;
 				right: 30rpx;
 				top: 88rpx;
 				background: #FFFFFF;
-				box-shadow: 0rpx 4rpx 20rpx 0rpx rgba(0,0,0,0.1);
+				box-shadow: 0rpx 4rpx 20rpx 0rpx rgba(0, 0, 0, 0.1);
 				padding: 42rpx 32rpx 0;
+
 				.show-item {
 					margin-bottom: 40rpx;
+
 					image {
 						width: 36rpx;
 						height: 36rpx;
 						margin: 0;
 					}
+
 					text {
 						white-space: nowrap;
 						font-size: 26rpx;

+ 181 - 69
pages/mine/index.vue

@@ -1,9 +1,10 @@
 <template>
 	<view class="content">
 		<view class="top_bg">
-			<image :src="user.avatar || default_bg" mode="aspectFill" class="bg_img" @click="show_bg = true"></image>
+			<image :src="user.backgroud_image || default_bg" mode="aspectFill" class="bg_img" @click="show_bg = true"></image>
 			<view class="bg-click" @click="show_bg = true"></view>
-			<u-navbar title=" " @rightClick="tosetting"  bgColor="rgba(0,0,0,0)" placeholder :fixed="true"  :autoBack="true">
+			<u-navbar title=" " @rightClick="tosetting" bgColor="rgba(0,0,0,0)" placeholder :fixed="true"
+				:autoBack="true">
 				<view style="display: none;" slot="left"></view>
 				<view class="u-nav-slot" slot="right">
 					<image src="../../static/images/setting.png" mode="aspectFill"></image>
@@ -11,23 +12,28 @@
 			</u-navbar>
 			<view class="user">
 				<view class="user-top hflex acenter jbetween">
-					<view class="name vflex" >
-						<view class="hflex aend" v-if="user.username" @click.stop="touserinfo">
-							<text>{{user.username}}</text>
-							<text>LV{{user.level}}00</text>
+					<view class="name vflex">
+						<view class="hflex aend" v-if="user.id" @click.stop="touserinfo">
+							<text>{{user.username || '用户'}}</text>
+							<text>LV{{user.level}}</text>
 							<image src="../../static/images/vip.png" mode="aspectFill" v-if="user.is_vip != 0"></image>
 						</view>
 						<view v-else @click="tologin">
 							<view class="intro" style="font-size: 30rpx;font-weight: bold;color: #FFF;">去登陆</view>
 						</view>
 					</view>
-					<image :src="user.avatar || default_avatar" mode="aspectFill" class="user-avatar" @click.stop="touserinfo"></image>
+					<image :src="user.avatar || default_avatar" mode="aspectFill" class="user-avatar"
+						@click.stop="touserinfo"></image>
 				</view>
-				<view class="hflex acenter">
-					<image :src="user.shoot_badge" mode="aspectFill" v-if="user.shoot_badge"></image>
-					<image :src="user.post_badge" mode="aspectFill" v-if="user.post_badge"></image>
-					<image :src="user.like_badge" mode="aspectFill" v-if="user.like_badge"></image>
-					<image :src="user.boutique_post_badge" mode="aspectFill" v-if="user.boutique_post_badge"></image>
+				<view class="hflex acenter imgs">
+					<image :src="user.shoot_badge" mode="aspectFill" v-if="user.shoot_badge" @click="topaihang(0)">
+					</image>
+					<image :src="user.post_badge" mode="aspectFill" v-if="user.post_badge" @click="topaihang(0)">
+					</image>
+					<image :src="user.like_badge" mode="aspectFill" v-if="user.like_badge" @click="topaihang(1)">
+					</image>
+					<image :src="user.boutique_post_badge" mode="aspectFill" v-if="user.boutique_post_badge"
+						@click="topaihang(0)"></image>
 				</view>
 				<view class="intro">{{user.introduction}}</view>
 				<view class="hflex acenter jbetween user-bottom">
@@ -46,11 +52,12 @@
 						</view>
 					</view>
 					<view class="bottom-right hflex acenter" @click="tovip">
-						<text>积分待领取</text>
+						<image src="../../static/images/sign.png" mode="aspectFill" class="sign" v-if="is_sign == 0"></image>
+						<text class="text">积分待领取</text>
 						<u-icon name="arrow-right" color="#ffffff" size="14"></u-icon>
 					</view>
 				</view>
-			</view> 
+			</view>
 		</view>
 		<view class="box">
 			<view class="vip hflex acenter jbetween" @click="tovip">
@@ -118,14 +125,18 @@
 		</view>
 		<view class="list">
 			<view class="menu hflex acenter">
-				<view class="menu-item" :class="active == index ? 'active-item' : ''" v-for="(item,index) in menu" :key="index" @click="tochangemenu(index)">
+				<view class="menu-item" :class="active == index ? 'active-item' : ''" v-for="(item,index) in menu"
+					:key="index" @click="tochangemenu(index)">
 					<text>{{item.name}}</text>
 				</view>
 			</view>
-			<view v-if="list.length>0">
-				<list-info :data="item" v-for="(item,index) in list" :key="index"></list-info>
+			<view v-if="list.length>0 && active == 0">
+				<list-info :data="item" v-for="(item,index) in list" :key="index" @del="del"></list-info>
+			</view>
+			<view v-if="list.length>0 && active > 0">
+				<list-info :type="menu[active].id" :data="item" v-for="(item,index) in list" :key="index" @del="del"></list-info>
 			</view>
-			<view v-else class="empty">
+			<view v-if="list.length == 0" class="empty">
 				<u-empty mode="data"></u-empty>
 			</view>
 		</view>
@@ -138,7 +149,8 @@
 				<view class="bg-list hflex acenter">
 					<view class="bg-item" v-for="(item,index) in bg_list" :key="index" @click="selectbg(index)">
 						<image :src="item" mode="aspectFill" class="item-img"></image>
-						<image src="../../static/images/select.png" mode="aspectFill" class="item-icon" v-if="bg_active == index"></image>
+						<image src="../../static/images/select.png" mode="aspectFill" class="item-icon"
+							v-if="bg_active == index"></image>
 					</view>
 				</view>
 			</view>
@@ -163,47 +175,71 @@
 				user: {},
 				active: 0,
 				list: [],
-				menu: [
-					{
-						id: '',
+				menu: [{
+						id: 'all',
 						name: '全部'
 					},
 					{
-						id: 'luntan',
+						id: 'post',
 						name: '论坛'
 					},
 					{
-						id: 'shipin',
+						id: 'video',
 						name: '视频'
 					},
 					{
-						id: 'wenzhang',
+						id: 'article',
 						name: '文章'
 					},
 					{
-						id: 'zixun',
+						id: 'info',
 						name: '资讯'
 					},
 				],
+				page: 1,
+				last_page: 1,
+				is_sign: 0,
 			}
 		},
 		onLoad() {
-			this.getuser()
-			this.getlist()
-			this.getbg()
+
 		},
 		onShow() {
+			this.getbg()
+			this.page = 1
+			this.list = []
 			this.getuser()
-			this.getlist()
+			this.getsign()
+			// this.getlist()
+		},
+		onReachBottom() {
+			if (this.page < this.last_page) {
+				this.page++
+				this.getlist()
+			} else {
+				uni.$u.toast('已经到底了')
+				return
+			}
 		},
 		methods: {
-			/* 签到奖励 */
+			getsign() {
+				var that = this
+				$api.req({
+					url: 'sign/is-sign'
+				}, function(res) {
+					that.is_sign = res.data
+				})
+			},
+			topaihang(index) {
+				uni.navigateTo({
+					url: '/pageC/paihang'
+				})
+			},
 			toqiandao() {
 				uni.navigateTo({
 					url: '/pageC/calendar'
 				})
 			},
-			/* 会员 */
 			tovip() {
 				uni.navigateTo({
 					url: '/pageC/vip'
@@ -214,137 +250,154 @@
 					url: '/pages/login/index'
 				})
 			},
-			/* 草稿箱 */
 			todrafts() {
 				uni.navigateTo({
 					url: '/pageC/drafts'
 				})
 			},
-			/* 加入忆象 */
 			toadd() {
 				uni.navigateTo({
 					url: '/pageC/zhiwei-list'
 				})
 			},
-			/* 常见问题 */
 			tochangjian() {
 				uni.navigateTo({
 					url: '/pageC/changjian-list'
 				})
 			},
-			/* 设备租赁 */
 			tozulin() {
 				uni.navigateTo({
 					url: '/pageB/zulin'
 				})
 			},
-			/* 预约拍摄 */
 			toyuyue() {
 				uni.navigateTo({
 					url: '/pageB/yuyue-capture'
 				})
 			},
-			/* 地址管理 */
 			toaddress() {
 				uni.navigateTo({
 					url: '/pageC/address-list'
 				})
 			},
-			/* 视频管理 */
 			tovideo() {
 				uni.navigateTo({
 					url: '/pageC/video-list'
 				})
 			},
-			/* 我的足迹 */
 			tozuji() {
 				uni.navigateTo({
 					url: '/pageC/zuji-list'
 				})
 			},
-			/* 积分钱包 */
 			tojifen() {
 				uni.navigateTo({
 					url: '/pageC/jifen-qianbao'
 				})
 			},
-			/* 优惠券 */
 			toyouhui() {
 				uni.navigateTo({
 					url: '/pageC/youhuiquan'
 				})
 			},
-			/* 收藏列表 */
 			tocollect() {
 				uni.navigateTo({
 					url: '/pageC/collect-list'
 				})
 			},
-			/* 关注列表 */
 			toguanzhu(type) {
 				uni.navigateTo({
 					url: '/pageC/guanzhu-list?type=' + type
 				})
 			},
-			/* 去编辑资料 */
 			touserinfo() {
 				uni.navigateTo({
 					url: '/pageC/userinfo'
 				})
 			},
-			/* 选择背景图 */
 			selectbg(index) {
 				this.bg_active = index
 			},
-			/* 更换背景图 */
 			tochangebg() {
 				this.mine_bg = this.bg_list[this.bg_active]
-				this.toclose()
+				var _this = this
+				$api.req({
+					url: 'user',
+					method: 'PUT',
+					data: {
+						backgroud_image: this.mine_bg
+					}
+				}, function(res) {
+					$api.info(res.msg)
+					_this.toclose()
+					setTimeout(() => {
+						_this.getuser()
+					}, 1000)
+				})
+			},
+			del(e) {
+				console.log(e,'---------');
+				this.page = 1
+				this.list = []
+				this.getlist()
 			},
-			/* 关闭 */
 			toclose() {
 				this.show_bg = false
 			},
-			/* 获取背景图 */
 			getbg() {
-				this.bg_list = [
-					'https://cdn.uviewui.com/uview/album/1.jpg',
-					'https://cdn.uviewui.com/uview/swiper/swiper1.png',
-					'https://cdn.uviewui.com/uview/swiper/swiper2.png',
-					'https://cdn.uviewui.com/uview/swiper/swiper3.png',
-				]
+				var that = this
+				$api.req({
+					url: 'config',
+					data: {
+						module: 'user'
+					}
+				}, function(res) {
+					that.bg_list = res.data.backgroud_images
+				})
+				
 			},
-			/* 邀请好友 */
 			toinvite() {
 				uni.navigateTo({
 					url: '/pageC/invite'
 				})
 			},
-			/* 获取列表 */
 			getlist() {
-				
+				var that = this
+				$api.req({
+					url: 'summary',
+					data: {
+						page: that.page,
+						limit: 10,
+						is_page: 1,
+						type: that.active == 0 ? 'all' : 'single',
+						source_type: that.menu[that.active].id,
+						author_id: that.user.id
+					}
+				}, function(res) {
+					that.list = that.list.concat(res.data.list)
+					that.last_page = res.data.last_page
+				})
 			},
-			/* 切换菜单 */
 			tochangemenu(index) {
 				this.active = index
+				this.page = 1
 				this.list = []
 				this.getlist()
 			},
-			/* 去设置 */
 			tosetting() {
 				uni.navigateTo({
 					url: '/pageC/setting'
 				})
 			},
-			/* 获取用户信息 */
 			getuser() {
 				var _this = this
 				$api.req({
 					url: 'user/info',
 					method: 'GET'
 				}, function(res) {
-					if(res.code == 10000) {
+					if (res.code == 10000) {
 						_this.user = res.data
+						_this.getlist()
 					}
 				})
 			},
@@ -355,18 +408,22 @@
 <style lang="scss">
 	.content::v-deep {
 		background: unset;
+
 		.popu {
 			background: #FFFFFF;
 			border-radius: 28rpx 28rpx 0rpx 0rpx;
 			padding: 38rpx 28rpx;
+
 			.top {
 				width: 100%;
+
 				text:first-child {
 					font-size: 36rpx;
 					font-family: PingFangSC, PingFang SC;
 					font-weight: 600;
 					color: #333333;
 				}
+
 				text:last-child {
 					font-size: 32rpx;
 					font-family: PingFangSC, PingFang SC;
@@ -374,19 +431,23 @@
 					color: #333333;
 				}
 			}
+
 			.bg-list {
 				width: 100%;
 				overflow: auto;
 				margin: 36rpx 0 0;
+
 				.bg-item {
 					width: 248rpx;
 					height: 248rpx;
 					margin: 0 10rpx 0 0;
 					position: relative;
+
 					.item-img {
 						width: 248rpx;
 						height: 100%;
 					}
+
 					.item-icon {
 						position: absolute;
 						width: 32rpx;
@@ -397,14 +458,17 @@
 				}
 			}
 		}
+
 		.list {
 			width: 100%;
 			background: #F4F4F4;
 			padding: 20rpx 0;
-			.menu{
+
+			.menu {
 				background: #fff;
 				box-sizing: border-box;
 				padding: 28rpx;
+
 				.menu-item {
 					width: 96rpx;
 					height: 56rpx;
@@ -412,27 +476,32 @@
 					border-radius: 36rpx;
 					margin: 0 20rpx 0 0;
 					text-align: center;
+
 					text {
 						font-size: 26rpx;
 						font-family: PingFangSC, PingFang SC;
 						font-weight: 500;
 						color: #444444;
 						line-height: 56rpx;
-						
+
 					}
 				}
+
 				.active-item {
 					background: #00B0B0;
+
 					text {
 						color: #FFFFFF !important;
 					}
 				}
 			}
+
 			.empty {
 				background: #FFF;
 				padding: 40rpx 0;
 			}
 		}
+
 		.box {
 			// margin: 30rpx 0 0;
 			box-sizing: border-box;
@@ -440,6 +509,7 @@
 			width: 100%;
 			background: #FFFFFF;
 			border-radius: 28rpx 28rpx 0rpx 0rpx;
+
 			.vip {
 				width: 694rpx;
 				height: 148rpx;
@@ -448,12 +518,15 @@
 				border-radius: 20rpx;
 				box-sizing: border-box;
 				padding: 20rpx;
+
 				.left {
 					height: 100%;
+
 					image {
 						width: 60rpx;
 						height: 60rpx;
 					}
+
 					.vip-text {
 						font-size: 32rpx;
 						font-family: PingFangSC, PingFang SC;
@@ -461,6 +534,7 @@
 						color: #FFFFFF;
 						padding: 0 10rpx 0 16rpx;
 					}
+
 					.vip-time {
 						font-size: 20rpx;
 						font-family: SFPro, SFPro;
@@ -468,6 +542,7 @@
 						color: #FFFFFF;
 						padding-top: 10rpx;
 					}
+
 					text {
 						font-size: 22rpx;
 						font-family: PingFangSC, PingFang SC;
@@ -475,6 +550,7 @@
 						color: #999999;
 					}
 				}
+
 				.btn {
 					width: 144rpx;
 					height: 60rpx;
@@ -488,14 +564,17 @@
 					line-height: 60rpx;
 				}
 			}
+
 			.tabs {
 				.tabs-item {
 					margin: 48rpx 100rpx 0 0;
+
 					image {
 						width: 44rpx;
 						height: 44rpx;
 						margin: 0 0 12rpx;
 					}
+
 					text {
 						font-size: 24rpx;
 						font-family: PingFangSC, PingFang SC;
@@ -503,16 +582,19 @@
 						color: #222222;
 					}
 				}
+
 				.tabs-item:nth-child(4n+4) {
 					margin: 48rpx 0 0;
 				}
 			}
 		}
+
 		.top_bg {
 			width: 100%;
 			// height: ;
 			background: rgba(0, 0, 0, 0.5);
 			position: relative;
+
 			.bg-click {
 				position: absolute;
 				top: 0;
@@ -522,6 +604,7 @@
 				background: rgba(0, 0, 0, 0);
 				// z-index: -1;
 			}
+
 			.bg_img {
 				position: absolute;
 				top: 0;
@@ -530,28 +613,34 @@
 				width: 100%;
 				z-index: -1;
 			}
+
 			.u-navbar {
 				height: 88rpx;
 				width: 100%;
+
 				image {
 					width: 44rpx;
 					height: 44rpx;
 				}
 			}
+
 			.user {
-				
+
 				width: 100%;
 				box-sizing: border-box;
 				padding: 56rpx 24rpx;
+
 				.user-top {
 					.name {
 						position: relative;
+
 						text:first-child {
 							font-size: 44rpx;
 							font-family: PingFangSC, PingFang SC;
 							font-weight: 500;
 							color: #FFFFFF;
 						}
+
 						text:last-child {
 							font-size: 20rpx;
 							font-family: Silom;
@@ -561,29 +650,43 @@
 							background: url('../../static/images/level-bg.png') no-repeat;
 							background-size: 100% 100%;
 						}
+
 						image {
 							width: 40rpx;
 							height: 40rpx;
 						}
 					}
+
 					.user-avatar {
 						width: 104rpx;
 						height: 104rpx;
 						border-radius: 50%;
 					}
 				}
+
+				.imgs {
+					image {
+						width: 36rpx;
+						height: 36rpx;
+						padding-right: 10rpx;
+					}
+				}
+
 				.intro {
 					padding: 32rpx 0;
 					font-size: 24rpx;
 					font-family: PingFangSC, PingFang SC;
 					font-weight: 400;
-					color:rgba(255, 255, 255, .7);
+					color: rgba(255, 255, 255, .7);
 				}
+
 				.user-bottom {
 					.bottom-left {
 						position: relative;
+
 						.bottom-item {
 							padding: 0 44rpx 0 0;
+
 							text:first-child {
 								font-size: 32rpx;
 								font-family: JDZhengHT, JDZhengHT;
@@ -593,6 +696,7 @@
 								letter-spacing: 1px;
 								padding: 0 0 12rpx;
 							}
+
 							text:last-child {
 								font-size: 20rpx;
 								font-family: PingFangSC, PingFang SC;
@@ -602,13 +706,21 @@
 							}
 						}
 					}
+
 					.bottom-right {
 						position: relative;
 						padding: 6rpx 20rpx;
-						background: rgba(255,255,255,0.1);
+						background: rgba(255, 255, 255, 0.1);
 						border-radius: 22rpx;
 						text-align: center;
-						text:first-child {
+						.sign {
+							position: absolute;
+							top: -44rpx;
+							left: 20rpx;
+							width: 128rpx;
+							height: 48rpx;
+						}
+						.text {
 							font-size: 22rpx;
 							font-weight: 400;
 							color: #FFFFFF;

+ 49 - 12
pages/shangdian/index.vue

@@ -55,11 +55,16 @@
 			}
 		},
 		onLoad() {
+
+		},
+		onShow() {
 			this.getswiper()
+			this.page = 1
+			this.list = []
 			this.getlist()
 		},
 		methods: {
-			
+
 			getswiper() {
 				var _this = this
 				$api.req({
@@ -69,7 +74,7 @@
 						limit: 5
 					}
 				}, function(res) {
-					if(res.code == 10000) {
+					if (res.code == 10000) {
 						_this.swiper_list = res.data
 					}
 				})
@@ -113,10 +118,11 @@
 					data: {
 						is_page: 1,
 						page: _this.page,
-						limit: 10
+						limit: 10,
+						name: this.search
 					}
 				}, function(res) {
-					if(res.code == 10000) {
+					if (res.code == 10000) {
 						_this.list = _this.list.concat(res.data.list)
 						_this.last_page = res.data.last_page
 					}
@@ -125,10 +131,14 @@
 			/* 轮播图点击事件 */
 			swiperclick() {},
 			/* 搜索 */
-			tosearch() {},
+			tosearch() {
+				this.page = 1
+				this.list = []
+				this.getlist()
+			},
 		},
 		onReachBottom() {
-			if(this.last_page > this.page) {
+			if (this.last_page > this.page) {
 				this.page++;
 				this.getlist()
 			} else {
@@ -144,37 +154,46 @@
 		padding: 20rpx 28rpx;
 		box-sizing: border-box;
 		background: #F5F5F5;
+
 		.list {
 			.list-item {
 				background: #FFFFFF;
 				border-radius: 8rpx;
 				width: 340rpx;
 				margin: 0 14rpx 16rpx 0;
+
 				image {
 					width: 100%;
 					height: 340rpx;
 				}
+
 				.name {
 					font-size: 26rpx;
 					font-family: SFPro, SFPro;
 					font-weight: 400;
 					color: #222222;
-					padding: 20rpx;
+					padding: 0 20rpx;
+					margin: 20rpx 0;
 					box-sizing: border-box;
+					height: 68rpx;
 				}
+
 				.bottom {
 					box-sizing: border-box;
 					padding: 0 20rpx 22rpx;
+
 					.price {
 						font-size: 36rpx;
 						font-family: SFPro, SFPro;
 						font-weight: 600;
 						color: #FF4954;
+
 						text {
 							font-weight: 500;
 							font-size: 24rpx;
 						}
 					}
+
 					.btn {
 						width: 108rpx;
 						height: 52rpx;
@@ -187,22 +206,27 @@
 					}
 				}
 			}
+
 			.list-item:nth-child(2n+2) {
 				margin: 0 0 16rpx;
 			}
 		}
+
 		.tabs {
 			padding: 20rpx 0 28rpx;
+
 			.tabs-item {
 				width: 218rpx;
 				height: 72rpx;
 				background: #00B0B0;
 				border-radius: 8rpx;
+
 				image {
 					width: 32rpx;
 					height: 32rpx;
 					margin: 0 10rpx 0 0;
 				}
+
 				text {
 					font-size: 28rpx;
 					font-family: PingFangSC, PingFang SC;
@@ -211,51 +235,64 @@
 				}
 			}
 		}
+
 		.search {
 			width: 572rpx;
-			background: rgba(255,255,255,.3);
+			background: rgba(255, 255, 255, .3);
 			border-radius: 32rpx;
+
 			.u-search__content {
-				background: rgba(255,255,255,.3)!important;
+				background: rgba(255, 255, 255, .3) !important;
 			}
+
 			.u-search__content__input {
 				background-color: unset !important;
 			}
+
 			.u-search__content__icon {
 				background-color: unset !important;
+
 				.u-icon__icon {
 					color: #fff !important;
 				}
 			}
+
 			input {
-				background: rgba(255,255,255,.3)
+				background: rgba(255, 255, 255, .3)
 			}
-			
+
 		}
+
 		.search-right {
+
 			// padding: 0 32rpx 0 0;
 			.img {
 				position: relative;
 			}
+
 			image {
 				width: 40rpx;
 				height: 40rpx;
 				margin-left: 20rpx;
 			}
+
 			.add-show {
 				position: absolute;
 				right: 30rpx;
 				top: 88rpx;
 				background: #FFFFFF;
-				box-shadow: 0rpx 4rpx 20rpx 0rpx rgba(0,0,0,0.1);
+				box-shadow: 0rpx 4rpx 20rpx 0rpx rgba(0, 0, 0, 0.1);
 				padding: 42rpx 32rpx 0;
+
 				.show-item {
 					margin-bottom: 40rpx;
+
 					image {
 						width: 36rpx;
 						height: 36rpx;
 						margin: 0;
 					}
+
 					text {
 						white-space: nowrap;
 						font-size: 26rpx;

+ 2 - 1
static/js/api.js

@@ -20,7 +20,8 @@ module.exports = {
 		version: 'xcx',
 		baseUrl: 'https://vr.hdlkeji.com/api/',
 		qqMap: false,
-		loading: false
+		loading: false,
+		luck: 'https://vr.hdlkeji.com/web/#/'
 	},
 
 	/**