默认提交
Showing
16 changed files
with
118 additions
and
54 deletions
| ... | @@ -97,6 +97,19 @@ button { | ... | @@ -97,6 +97,19 @@ button { |
| 97 | border-bottom: none; | 97 | border-bottom: none; |
| 98 | } | 98 | } |
| 99 | 99 | ||
| 100 | // 红包 | ||
| 101 | .red-p { | ||
| 102 | .comp { | ||
| 103 | bottom: auto; | ||
| 104 | top: 15%; | ||
| 105 | } | ||
| 106 | } | ||
| 107 | |||
| 108 | .van-tab { | ||
| 109 | font-size: 32px !important; | ||
| 110 | font-weight: bold !important; | ||
| 111 | color: #444444 !important; | ||
| 112 | } | ||
| 100 | 113 | ||
| 101 | 114 | ||
| 102 | // web font icon | 115 | // web font icon |
| ... | @@ -366,4 +379,3 @@ button { | ... | @@ -366,4 +379,3 @@ button { |
| 366 | .iconwechat:before { | 379 | .iconwechat:before { |
| 367 | content: "\e600"; | 380 | content: "\e600"; |
| 368 | } | 381 | } |
| 369 | ... | ... |
| ... | @@ -4,9 +4,9 @@ | ... | @@ -4,9 +4,9 @@ |
| 4 | <!-- <view class="logo"> | 4 | <!-- <view class="logo"> |
| 5 | <image mode="widthFix" src="../../image/logo.png" /> | 5 | <image mode="widthFix" src="../../image/logo.png" /> |
| 6 | </view> --> | 6 | </view> --> |
| 7 | <view class="tit">深士照明</view> | 7 | <view class="tit">家有儿孙</view> |
| 8 | <view class="tips"> | 8 | <view class="tips"> |
| 9 | <text>需要获取您的微信昵称等信息才可以获取积分和兑换奖品哦</text> | 9 | <text>需要获取您的微信昵称等信息才可以体验更多哦</text> |
| 10 | </view> | 10 | </view> |
| 11 | </view> | 11 | </view> |
| 12 | <view class="btn-wrap"> | 12 | <view class="btn-wrap"> | ... | ... |
| ... | @@ -19,7 +19,7 @@ Component({ | ... | @@ -19,7 +19,7 @@ Component({ |
| 19 | }, | 19 | }, |
| 20 | pics: { | 20 | pics: { |
| 21 | type: Array, | 21 | type: Array, |
| 22 | value: ["red-package"] | 22 | value: [] |
| 23 | } | 23 | } |
| 24 | }, | 24 | }, |
| 25 | data: { | 25 | data: { |
| ... | @@ -33,7 +33,7 @@ Component({ | ... | @@ -33,7 +33,7 @@ Component({ |
| 33 | // 点击按按钮 | 33 | // 点击按按钮 |
| 34 | onTapHandler(evt) { | 34 | onTapHandler(evt) { |
| 35 | let curType = getBindtapData(evt); | 35 | let curType = getBindtapData(evt); |
| 36 | console.log("curType:", curType); | 36 | |
| 37 | switch (curType) { | 37 | switch (curType) { |
| 38 | case "home": | 38 | case "home": |
| 39 | app.router.push({ | 39 | app.router.push({ | ... | ... |
| ... | @@ -6,10 +6,11 @@ module.exports = { | ... | @@ -6,10 +6,11 @@ module.exports = { |
| 6 | bannerList: '/banner/list', // 轮播图 | 6 | bannerList: '/banner/list', // 轮播图 |
| 7 | tabList: '/tab/list', // 获取标签 | 7 | tabList: '/tab/list', // 获取标签 |
| 8 | videoList: '/video/list', // 视频列表 | 8 | videoList: '/video/list', // 视频列表 |
| 9 | videoAcccout: '/video/acccout', // 帐号下的视频 | 9 | videoAcccout: '/video/account', // 帐号下的视频 |
| 10 | videoDetail: '/video/detail', // 视频详情 | 10 | videoDetail: '/video/detail', // 视频详情 |
| 11 | rewardDetail: '/hide/order', // 获得打赏视频 | 11 | rewardDetail: '/hide/order', // 获得打赏视频 |
| 12 | videoMore: '/video/more', // 更多推荐 | 12 | videoMore: '/video/more', // 更多推荐 |
| 13 | accountDetail: '/account/detail', // 帐号详情 | ||
| 13 | 14 | ||
| 14 | /** | 15 | /** |
| 15 | * 通用接口 | 16 | * 通用接口 | ... | ... |
| ... | @@ -98,6 +98,16 @@ Page({ | ... | @@ -98,6 +98,16 @@ Page({ |
| 98 | }, | 98 | }, |
| 99 | 99 | ||
| 100 | /** | 100 | /** |
| 101 | * 返回首页 | ||
| 102 | */ | ||
| 103 | toIndex() { | ||
| 104 | app.router.push({ | ||
| 105 | openType: "reLaunch", | ||
| 106 | path: "index" | ||
| 107 | }) | ||
| 108 | }, | ||
| 109 | |||
| 110 | /** | ||
| 101 | * 请求DataList | 111 | * 请求DataList |
| 102 | */ | 112 | */ |
| 103 | queryVideoMore() { | 113 | queryVideoMore() { | ... | ... |
| ... | @@ -48,6 +48,7 @@ | ... | @@ -48,6 +48,7 @@ |
| 48 | justify-content: center; | 48 | justify-content: center; |
| 49 | align-items: center; | 49 | align-items: center; |
| 50 | color: #ffffff; | 50 | color: #ffffff; |
| 51 | font-weight: bold; | ||
| 51 | 52 | ||
| 52 | .iconfont { | 53 | .iconfont { |
| 53 | font-size: 48px; | 54 | font-size: 48px; |
| ... | @@ -55,6 +56,7 @@ | ... | @@ -55,6 +56,7 @@ |
| 55 | 56 | ||
| 56 | .t1 { | 57 | .t1 { |
| 57 | padding: 0 6px; | 58 | padding: 0 6px; |
| 59 | font-weight: bold; | ||
| 58 | } | 60 | } |
| 59 | } | 61 | } |
| 60 | 62 | ||
| ... | @@ -129,6 +131,7 @@ | ... | @@ -129,6 +131,7 @@ |
| 129 | 131 | ||
| 130 | .t1 { | 132 | .t1 { |
| 131 | padding: 0 6px; | 133 | padding: 0 6px; |
| 134 | |||
| 132 | } | 135 | } |
| 133 | 136 | ||
| 134 | &:last-child { | 137 | &:last-child { | ... | ... |
| ... | @@ -59,12 +59,16 @@ | ... | @@ -59,12 +59,16 @@ |
| 59 | </view> | 59 | </view> |
| 60 | </view> | 60 | </view> |
| 61 | <!-- 返回首页按钮 --> | 61 | <!-- 返回首页按钮 --> |
| 62 | <view class="index-btn"> | 62 | <view bindtap="toIndex" class="index-btn"> |
| 63 | <span class="t1 iconfont iconhome"></span> | 63 | <span class="t1 iconfont iconhome"></span> |
| 64 | <span>返回首页</span> | 64 | <span>返回首页</span> |
| 65 | </view> | 65 | </view> |
| 66 | </view> | 66 | </view> |
| 67 | </view> | 67 | </view> |
| 68 | </view> | 68 | </view> |
| 69 | <!-- <shortcut types="{{[]}}" pics="{{['red-package']}}"></shortcut> --> | 69 | |
| 70 | <van-popup show="{{ authorizeVisible }}"> | ||
| 71 | <authorize-comp bind:evtcomp="evtcomp"></authorize-comp> | ||
| 72 | </van-popup> | ||
| 73 | <shortcut class="red-p" types="{{[]}}" pics="{{['red-package']}}"></shortcut> | ||
| 70 | <shortcut ></shortcut> | 74 | <shortcut ></shortcut> | ... | ... |
| ... | @@ -40,7 +40,6 @@ Page({ | ... | @@ -40,7 +40,6 @@ Page({ |
| 40 | * 做加载更多操作 | 40 | * 做加载更多操作 |
| 41 | */ | 41 | */ |
| 42 | onReachBottom() { | 42 | onReachBottom() { |
| 43 | console.log("onReachBottom"); | ||
| 44 | if (this.data.dataList.length < this.data.total) { | 43 | if (this.data.dataList.length < this.data.total) { |
| 45 | this.setData({ | 44 | this.setData({ |
| 46 | page: this.data.page + 1 | 45 | page: this.data.page + 1 |
| ... | @@ -57,16 +56,8 @@ Page({ | ... | @@ -57,16 +56,8 @@ Page({ |
| 57 | queueCode: "", | 56 | queueCode: "", |
| 58 | }) | 57 | }) |
| 59 | }, | 58 | }, |
| 60 | onTabsChange(event) { | 59 | |
| 61 | // console.log("this.data.tabList:", this.data.tabList); | 60 | // 点击tabs |
| 62 | // if (this.data.tabList && this.data.tabList.length > 0) { | ||
| 63 | // this.setData({ | ||
| 64 | // curTab: this.data.tabList[event.detail.index] | ||
| 65 | // }) | ||
| 66 | // this.resetPage(); | ||
| 67 | // this.queryVideoList(); | ||
| 68 | // } | ||
| 69 | }, | ||
| 70 | onVanTabsHandler(event) { | 61 | onVanTabsHandler(event) { |
| 71 | let { | 62 | let { |
| 72 | index, | 63 | index, |
| ... | @@ -77,6 +68,7 @@ Page({ | ... | @@ -77,6 +68,7 @@ Page({ |
| 77 | curTab: this.data.tabList[event.detail.index] | 68 | curTab: this.data.tabList[event.detail.index] |
| 78 | }) | 69 | }) |
| 79 | this.resetPage(); | 70 | this.resetPage(); |
| 71 | this.queryBannerList(); | ||
| 80 | this.queryVideoList(); | 72 | this.queryVideoList(); |
| 81 | } | 73 | } |
| 82 | }, | 74 | }, |
| ... | @@ -89,6 +81,21 @@ Page({ | ... | @@ -89,6 +81,21 @@ Page({ |
| 89 | } | 81 | } |
| 90 | }) | 82 | }) |
| 91 | }, | 83 | }, |
| 84 | |||
| 85 | /** | ||
| 86 | * 到个人列表页面 | ||
| 87 | */ | ||
| 88 | toPersonalList(evt) { | ||
| 89 | let detailData = getBindtapData(evt); | ||
| 90 | if (detailData && detailData.accountCode) { | ||
| 91 | detailData.c = detailData.accountCode; | ||
| 92 | app.router.push({ | ||
| 93 | path: "personalList", | ||
| 94 | query: detailData | ||
| 95 | }) | ||
| 96 | } | ||
| 97 | }, | ||
| 98 | |||
| 92 | /** | 99 | /** |
| 93 | * 获取tab列表 | 100 | * 获取tab列表 |
| 94 | */ | 101 | */ |
| ... | @@ -137,7 +144,7 @@ Page({ | ... | @@ -137,7 +144,7 @@ Page({ |
| 137 | queryVideoList() { | 144 | queryVideoList() { |
| 138 | return new Promise((resolve, reject) => { | 145 | return new Promise((resolve, reject) => { |
| 139 | app.post({ | 146 | app.post({ |
| 140 | sid: true, | 147 | sid: false, |
| 141 | url: app.api.videoList, | 148 | url: app.api.videoList, |
| 142 | data: { | 149 | data: { |
| 143 | page: this.data.page, | 150 | page: this.data.page, | ... | ... |
| ... | @@ -78,7 +78,6 @@ | ... | @@ -78,7 +78,6 @@ |
| 78 | @include border-top-radius(16px); | 78 | @include border-top-radius(16px); |
| 79 | width: $contentWidth; | 79 | width: $contentWidth; |
| 80 | pointer-events: none; | 80 | pointer-events: none; |
| 81 | |||
| 82 | } | 81 | } |
| 83 | 82 | ||
| 84 | .tit { | 83 | .tit { |
| ... | @@ -102,7 +101,7 @@ | ... | @@ -102,7 +101,7 @@ |
| 102 | position: absolute; | 101 | position: absolute; |
| 103 | left: 0; | 102 | left: 0; |
| 104 | right: 0; | 103 | right: 0; |
| 105 | top: 100px; | 104 | top: 160px; |
| 106 | margin: 0 auto; | 105 | margin: 0 auto; |
| 107 | text-align: center; | 106 | text-align: center; |
| 108 | font-weight: bold; | 107 | font-weight: bold; |
| ... | @@ -171,10 +170,3 @@ | ... | @@ -171,10 +170,3 @@ |
| 171 | } | 170 | } |
| 172 | } | 171 | } |
| 173 | 172 | ||
| 174 | .red-p { | ||
| 175 | .comp { | ||
| 176 | bottom: auto; | ||
| 177 | top: 15%; | ||
| 178 | } | ||
| 179 | |||
| 180 | } | ... | ... |
| ... | @@ -5,7 +5,7 @@ | ... | @@ -5,7 +5,7 @@ |
| 5 | <view class="app__content main"> | 5 | <view class="app__content main"> |
| 6 | <view class="top-space"></view> | 6 | <view class="top-space"></view> |
| 7 | <van-sticky> | 7 | <van-sticky> |
| 8 | <van-tabs ellipsis="{{ false }}" active="{{ active }}" bind:click="onVanTabsHandler" bind:change="onTabsChange"> | 8 | <van-tabs ellipsis="{{ false }}" active="{{ active }}" bind:click="onVanTabsHandler"> |
| 9 | <van-tab wx:for="{{tabList}}" wx:key="{{index}}" title="{{item.tabName}}"></van-tab> | 9 | <van-tab wx:for="{{tabList}}" wx:key="{{index}}" title="{{item.tabName}}"></van-tab> |
| 10 | </van-tabs> | 10 | </van-tabs> |
| 11 | </van-sticky> | 11 | </van-sticky> |
| ... | @@ -29,7 +29,7 @@ | ... | @@ -29,7 +29,7 @@ |
| 29 | <span class="iconfont iconicon-test16"></span> | 29 | <span class="iconfont iconicon-test16"></span> |
| 30 | </view> | 30 | </view> |
| 31 | <view class="list-item-func"> | 31 | <view class="list-item-func"> |
| 32 | <view class="user"> | 32 | <view bindtap="toPersonalList" data-data="{{item}}" data-index="{{index}}" class="user"> |
| 33 | <image class="portrait" mode="aspectFill" src="{{item.headImage}}" /> | 33 | <image class="portrait" mode="aspectFill" src="{{item.headImage}}" /> |
| 34 | <text class="name">{{item.accountName || ""}}</text> | 34 | <text class="name">{{item.accountName || ""}}</text> |
| 35 | </view> | 35 | </view> |
| ... | @@ -60,4 +60,7 @@ | ... | @@ -60,4 +60,7 @@ |
| 60 | </view> | 60 | </view> |
| 61 | </view> | 61 | </view> |
| 62 | 62 | ||
| 63 | <van-popup show="{{ authorizeVisible }}"> | ||
| 64 | <authorize-comp bind:evtcomp="evtcomp"></authorize-comp> | ||
| 65 | </van-popup> | ||
| 63 | <shortcut class="red-p" types="{{[]}}" pics="{{['red-package']}}"></shortcut> | 66 | <shortcut class="red-p" types="{{[]}}" pics="{{['red-package']}}"></shortcut> | ... | ... |
| ... | @@ -12,6 +12,7 @@ Page({ | ... | @@ -12,6 +12,7 @@ Page({ |
| 12 | size: 10, | 12 | size: 10, |
| 13 | dataList: [], | 13 | dataList: [], |
| 14 | options: {}, | 14 | options: {}, |
| 15 | personInfo: {} | ||
| 15 | }, | 16 | }, |
| 16 | onShareAppMessage() { | 17 | onShareAppMessage() { |
| 17 | let detailData = this.data.detailData; | 18 | let detailData = this.data.detailData; |
| ... | @@ -34,10 +35,12 @@ Page({ | ... | @@ -34,10 +35,12 @@ Page({ |
| 34 | this.setData({ | 35 | this.setData({ |
| 35 | options: tempOptions | 36 | options: tempOptions |
| 36 | }); | 37 | }); |
| 38 | console.log("tempOptions:", tempOptions); | ||
| 37 | this.initData(); | 39 | this.initData(); |
| 38 | }, | 40 | }, |
| 39 | initData() { | 41 | initData() { |
| 40 | this.resetPage(); | 42 | this.resetPage(); |
| 43 | this.queryAccountDetail(); | ||
| 41 | this.queryVideoList(); | 44 | this.queryVideoList(); |
| 42 | }, | 45 | }, |
| 43 | /** | 46 | /** |
| ... | @@ -72,6 +75,27 @@ Page({ | ... | @@ -72,6 +75,27 @@ Page({ |
| 72 | }, | 75 | }, |
| 73 | 76 | ||
| 74 | /** | 77 | /** |
| 78 | * 账号星期 | ||
| 79 | */ | ||
| 80 | queryAccountDetail() { | ||
| 81 | return new Promise((resolve, reject) => { | ||
| 82 | app.post({ | ||
| 83 | url: app.api.accountDetail, | ||
| 84 | data: { | ||
| 85 | accountCode: this.data.options.c | ||
| 86 | } | ||
| 87 | }).then((result) => { | ||
| 88 | this.setData({ | ||
| 89 | personInfo: result | ||
| 90 | }) | ||
| 91 | resolve(result); | ||
| 92 | }).catch((err) => { | ||
| 93 | reject(err) | ||
| 94 | }); | ||
| 95 | }); | ||
| 96 | }, | ||
| 97 | |||
| 98 | /** | ||
| 75 | * 获取视频列表 | 99 | * 获取视频列表 |
| 76 | */ | 100 | */ |
| 77 | queryVideoList() { | 101 | queryVideoList() { | ... | ... |
| ... | @@ -64,6 +64,7 @@ | ... | @@ -64,6 +64,7 @@ |
| 64 | justify-content: center; | 64 | justify-content: center; |
| 65 | position: relative; | 65 | position: relative; |
| 66 | width: $contentWidth; | 66 | width: $contentWidth; |
| 67 | background-color: #dddddd; | ||
| 67 | 68 | ||
| 68 | .vid { | 69 | .vid { |
| 69 | @include border-top-radius(16px); | 70 | @include border-top-radius(16px); |
| ... | @@ -86,6 +87,19 @@ | ... | @@ -86,6 +87,19 @@ |
| 86 | @include ellipsis(1); | 87 | @include ellipsis(1); |
| 87 | 88 | ||
| 88 | } | 89 | } |
| 90 | |||
| 91 | .iconfont { | ||
| 92 | font-size: 160px; | ||
| 93 | position: absolute; | ||
| 94 | left: 0; | ||
| 95 | right: 0; | ||
| 96 | top: 160px; | ||
| 97 | margin: 0 auto; | ||
| 98 | text-align: center; | ||
| 99 | font-weight: bold; | ||
| 100 | // color: #efefef; | ||
| 101 | color: #ffffff; | ||
| 102 | } | ||
| 89 | } | 103 | } |
| 90 | 104 | ||
| 91 | &-func { | 105 | &-func { | ... | ... |
| ... | @@ -3,22 +3,25 @@ | ... | @@ -3,22 +3,25 @@ |
| 3 | <view class="app__bg bg"></view> | 3 | <view class="app__bg bg"></view> |
| 4 | <!-- <view class="app__top-shadow"></view> --> | 4 | <!-- <view class="app__top-shadow"></view> --> |
| 5 | <view class="app__content main"> | 5 | <view class="app__content main"> |
| 6 | <view class="top-space"></view> | ||
| 6 | <view class="personal"> | 7 | <view class="personal"> |
| 7 | <view class="top-space"></view> | 8 | <view class="name">{{personInfo.accountName}} 的视频列表</view> |
| 8 | <view class="name">{{options.accountName}} 的视频列表</view> | 9 | <image class="portrait" mode="aspectFill" src="{{personInfo.headImage}}" /> |
| 9 | <image class="portrait" mode="aspectFill" src="{{options.headImage}}" /> | ||
| 10 | </view> | 10 | </view> |
| 11 | <view class="content"> | 11 | <view class="content"> |
| 12 | <view class="list"> | 12 | <view class="list"> |
| 13 | <view wx:for="{{dataList}}" wx:key="index" class="list-item"> | 13 | <view wx:for="{{dataList}}" wx:key="index" class="list-item"> |
| 14 | <view bindtap="onDetailHandler" data-data="{{item}}" data-index="{{index}}" class="list-item-video"> | 14 | <view bindtap="onDetailHandler" data-data="{{item}}" data-index="{{index}}" class="list-item-video"> |
| 15 | <video objectFit="cover" class="vid" poster="{{item.thumbnail}}" src="{{item.videoUrl}}" /> | 15 | <!-- <video objectFit="cover" class="vid" poster="{{item.thumbnail}}" src="{{item.videoUrl}}" /> |
| 16 | <view class="tit">{{item.videoName}}</view> --> | ||
| 17 | <image src="{{item.thumbnail}}" mode="aspectFill" /> | ||
| 16 | <view class="tit">{{item.videoName}}</view> | 18 | <view class="tit">{{item.videoName}}</view> |
| 19 | <span class="iconfont iconicon-test16"></span> | ||
| 17 | </view> | 20 | </view> |
| 18 | <view class="list-item-func"> | 21 | <view class="list-item-func"> |
| 19 | <view class="user"> | 22 | <view class="user"> |
| 20 | <image class="portrait" mode="aspectFill" src="{{item.headImage}}" /> | 23 | <image class="portrait" mode="aspectFill" src="{{personInfo.headImage}}" /> |
| 21 | <text class="name">{{item.accountName || ""}}</text> | 24 | <text class="name">{{personInfo.accountName || ""}}</text> |
| 22 | </view> | 25 | </view> |
| 23 | <button class="share" open-type="share"> | 26 | <button class="share" open-type="share"> |
| 24 | <span class="t1 iconfont iconwechat"></span> | 27 | <span class="t1 iconfont iconwechat"></span> |
| ... | @@ -26,24 +29,12 @@ | ... | @@ -26,24 +29,12 @@ |
| 26 | </button> | 29 | </button> |
| 27 | </view> | 30 | </view> |
| 28 | </view> | 31 | </view> |
| 29 | <!-- <view bindtap="onVideoHandler" wx:for="{{8}}" wx:key="index" data-data="{{item}}" data-index="{{index}}" class="list-item"> | ||
| 30 | <view class="list-item-video"> | ||
| 31 | <video objectFit="cover" class="vid" poster="https://kd.cdn.xyiyang.com/pro/mzczcradmin/008194acee794506aac4c7200ce654dc.jpg" src="https://kd.cdn.xyiyang.com/pro/mzczcradmin/7e91e8a4c7b84e6fa4bada7c8617c9cf.mp4" /> | ||
| 32 | <view class="tit">这是一个视频</view> | ||
| 33 | </view> | ||
| 34 | <view class="list-item-func"> | ||
| 35 | <view class="user"> | ||
| 36 | <image class="portrait" mode="aspectFill" src="https://kd.cdn.xyiyang.com/pro/mzczcradmin/008194acee794506aac4c7200ce654dc.jpg" /> | ||
| 37 | <text class="name">我爱我家</text> | ||
| 38 | </view> | ||
| 39 | <button class="share"> | ||
| 40 | <span class="t1 iconfont iconwechat"></span> | ||
| 41 | <span class="t1">分享</span> | ||
| 42 | </button> | ||
| 43 | </view> | ||
| 44 | </view> --> | ||
| 45 | </view> | 32 | </view> |
| 46 | </view> | 33 | </view> |
| 47 | </view> | 34 | </view> |
| 48 | </view> | 35 | </view> |
| 36 | |||
| 37 | <van-popup show="{{ authorizeVisible }}"> | ||
| 38 | <authorize-comp bind:evtcomp="evtcomp"></authorize-comp> | ||
| 39 | </van-popup> | ||
| 49 | <shortcut></shortcut> | 40 | <shortcut></shortcut> | ... | ... |
| ... | @@ -64,7 +64,6 @@ Page({ | ... | @@ -64,7 +64,6 @@ Page({ |
| 64 | * 请求DataList | 64 | * 请求DataList |
| 65 | */ | 65 | */ |
| 66 | queryDataList() { | 66 | queryDataList() { |
| 67 | return; | ||
| 68 | return new Promise((resolve, reject) => { | 67 | return new Promise((resolve, reject) => { |
| 69 | app.post({ | 68 | app.post({ |
| 70 | sid: false, | 69 | sid: false, | ... | ... |
-
Please register or sign in to post a comment