Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
U
uniapp_vedio
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
android
uniapp_vedio
Commits
6313ff3d
Commit
6313ff3d
authored
May 29, 2024
by
mengcuiguang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
代码优化
parent
8889a254
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
109 additions
and
40 deletions
+109
-40
coin-popup.vue
vedio/components/coin-popup/coin-popup.vue
+3
-3
my.vue
vedio/components/home/my.vue
+73
-35
my.vue
vedio/pages/my/my.vue
+1
-1
watchRecord.vue
vedio/pagesD/watchRecord/watchRecord.vue
+1
-1
ReadCount.js
vedio/utils/ReadCount.js
+31
-0
No files found.
vedio/components/coin-popup/coin-popup.vue
View file @
6313ff3d
...
...
@@ -28,13 +28,13 @@
<view
style=
"display: flex;flex-direction: column;align-items: center;margin-bottom: 20rpx;"
>
<view
style=
"font-size: 38rpx;color: black;"
>
{{
titleText
}}
</view>
<view
class=
"flex"
>
<view
v-if=
"point>0"
style=
"display: flex;flex-direction: row;margin-top: 10rpx;"
>
<
!--
<
view
v-if=
"point>0"
style=
"display: flex;flex-direction: row;margin-top: 10rpx;"
>
<view
style=
"font-size: 28rpx;color: #644238;margin-top: 12rpx;"
>
解锁本集:
</view>
<view
style=
"font-size: 42rpx;color: red;font-weight: 777;"
>
{{
point
}}
</view>
<view
style=
"font-size: 28rpx;color: #644238;margin-top: 12rpx;margin-left: 6rpx;"
>
书豆
</view>
</view>
</view>
-->
<view
v-if=
"point>0"
style=
"width: 60rpx;"
></view>
<view
style=
"display: flex;flex-direction: row;margin-top: 10rpx;"
>
<view
style=
"font-size: 28rpx;color: #644238;margin-top: 12rpx;"
>
账户余额:
</view>
...
...
@@ -49,7 +49,7 @@
<view
class=
"section"
>
<view
class=
"pack-box"
>
<view
class=
"pack-item"
:style=
"item.largeType !=='vip' ?'background: #f5f5f5;':'background: #f
4c98b
;'"
:style=
"item.largeType !=='vip' ?'background: #f5f5f5;':'background: #f
5f5f5
;'"
:class=
"[
{active: index==selectedIndex}]" v-for='(item, index) in vipList'
:key='index' @click="choosePack(item, index)">
<view
style=
"display: flex;flex-direction: column;align-items: center;"
>
...
...
vedio/components/home/my.vue
View file @
6313ff3d
...
...
@@ -6,40 +6,13 @@
:style=
"'display: flex;flex-direction: row;align-items: center;margin: 20rpx;padding-left: 10rpx;margin-top:'+10+'px;'"
>
<image
class=
"avatar"
src=
"@/static/logo-about.png"
></image>
<view>
<view
style=
"font-size: 32rpx;color: black;margin-left: 20rpx;"
>
用户ID:
{{
userBean
.
idcode
}}
</view>
<view
style=
"font-size: 34rpx;color: black;margin-left: 30rpx;"
>
用户ID:
{{
userBean
.
idcode
}}
</view>
<view
style=
"font-size: 26rpx;color: #b5b5b5;margin-left: 30rpx;margin-top: 10rpx;"
>
书中自有颜如玉,书中自有黄金屋,书中自有千钟黍
</view>
</view>
<!--
<button
text=
"微信用户一键登录"
open-type=
"getPhoneNumber"
bindgetphonenumber=
"getPhoneNumber"
>
123123
</button>
-->
</view>
<view
v-if=
"userBean.showVipInner "
style=
"display: flex;flex-direction: row;background: #f5ca86;margin: 20rpx;padding: 40rpx;border-radius:20rpx;align-items: center;justify-content:space-between;"
>
<view
style=
"display: flex;flex-direction: column;justify-content: center;"
>
<view
style=
"font-size: 36rpx;color: #5b1500;font-weight: 777;"
>
{{
userBean
.
expireTime
<=
0
?
'开通VIP会员'
:
'VIP会员'
}}
</view>
<view
v-if=
"userBean.expireTime
<
=
0
"
style=
"font-size: 30rpx;color: #5b1500;margin-top: 12rpx;"
>
解锁全部小说
</view>
<view
v-else
style=
"font-size: 30rpx;color: #5b1500;margin-top: 12rpx;"
>
到期时间:
{{
userBean
.
expireTime
*
1000
|
formatDate
(
'yyyy-MM-dd'
)
}}
</view>
<view
v-if=
"userBean.expireTime
<
=
0
"
@
click=
"handleCoinPay"
style=
"width: 210rpx;height: 60rpx;background-color: #5b1500;border-radius:30rpx;color: white;font-size: 26rpx;justify-content: center;align-items: center;display: flex;padding-bottom: 4rpx;margin-top: 30rpx;"
>
立即开通
</view>
<view
v-else
style=
"width: 210rpx;height: 60rpx;padding-bottom: 4rpx;margin-top: 30rpx;"
>
</view>
</view>
<image
style=
"border-radius:10rpx; width: 130rpx;height: 100rpx;margin-right: 20rpx;"
src=
"https://mints-pkg.oss-cn-beijing.aliyuncs.com/pkg/bg_my_vip.png"
mode=
"scaleToFill"
></image>
</view>
<view
style=
"display: flex;height: 200rpx;margin:
20rpx;background: #f5ca86
;border-radius: 20rpx;"
>
style=
"display: flex;height: 200rpx;margin:
30rpx 20rpx;background: #263358
;border-radius: 20rpx;"
>
<view
style=
"flex-grow: 2; margin-left: 20rpx;"
>
<view
style=
"width: 100%;height: 100%;display: flex;flex-direction: column;justify-content: center;"
>
...
...
@@ -47,18 +20,19 @@
<image
style=
"width: 50rpx;height: 50rpx;display: flex;align-items: right;margin-right: 10rpx;"
src=
"https://mints-pkg.oss-cn-beijing.aliyuncs.com/pkg/img/ic_my_coin.png"
></image>
<view
style=
"font-size: 36rpx;font-weight: 777;
"
>
书豆充值
</view>
<view
style=
"font-size: 36rpx;font-weight: 777;
color: white;"
>
我的书豆
{{
userBean
.
point
}}
</view>
</view>
<view
style=
"font-size: 28rpx;color: #5b1500;margin-top: 20rpx;"
>
海量书豆狂洒中,小说等你来解锁
</view>
<view
v-if=
"userBean.expireTime
<
=
0
"
style=
"font-size: 28rpx;color: #b5b5b5;margin-top: 20rpx;"
>
开通会员畅读VIP享更多福利
</view>
<view
v-else
style=
"font-size: 28rpx;color: #b5b5b5;margin-top: 20rpx;"
>
到期时间:
{{
userBean
.
expireTime
*
1000
|
formatDate
(
'yyyy-MM-dd'
)
}}
</view>
</view>
</view>
<view
style=
"width: 220rpx;"
>
<view
style=
"width: 100%;height: 100%;display: flex;flex-direction: column;align-items: center;justify-content: center;"
>
<view
style=
"font-size: 30rpx;color: #5b1500;margin-bottom: 20rpx;"
>
{{
userBean
.
point
}}
</view>
<view
@
click=
"handleCoinPay"
style=
"width: 160rpx;height: 60rpx;background-color: #
5b1500;border-radius:30rpx;color: white
;font-size: 26rpx;justify-content: center;align-items: center;display: flex;padding-bottom: 4rpx;"
>
去
充值
style=
"width: 160rpx;height: 60rpx;background-color: #
fff;border-radius:30rpx;color: 263358
;font-size: 26rpx;justify-content: center;align-items: center;display: flex;padding-bottom: 4rpx;"
>
去
开通
</view>
</view>
</view>
...
...
@@ -262,4 +236,68 @@
overflow
:
hidden
;
//box-shadow: 0 2px 12px 0 rgba(0, 0, 0, 0.1)
}
.vip-item
{
width
:
100%
;
padding
:
10rpx
40rpx
;
.content
{
width
:
90%
;
margin
:
auto
;
display
:
flex
;
flex-direction
:
row
;
justify-content
:
space-between
;
padding
:
20rpx
40rpx
;
background
:
#263358
;
color
:
#fff
;
border-radius
:
18rpx
;
}
.item
{
display
:
flex
;
flex-direction
:
column
;
align-items
:
flex-start
;
justify-content
:
center
;
margin-right
:
20rpx
;
}
.item
:last-child
{
margin-right
:
0
;
}
.row
{
display
:
flex
;
flex-direction
:
row
;
align-items
:
center
;
margin-bottom
:
15rpx
;
}
.row
:last-child
{
margin-bottom
:
0
;
}
.title
{
font-size
:
38rpx
;
font-weight
:
700
;
font-style
:
italic
;
}
.desc
{
font-size
:
26rpx
;
color
:
#b5b5b5
;
}
.button
{
height
:
40rpx
;
line-height
:
70rpx
;
border-radius
:
35rpx
;
width
:
160rpx
;
background
:
#fff
;
color
:
#263358
;
text-align
:
center
;
font-size
:
30rpx
;
font-weight
:
700
;
font-style
:
italic
;
}
}
</
style
>
\ No newline at end of file
vedio/pages/my/my.vue
View file @
6313ff3d
...
...
@@ -20,7 +20,7 @@
</view>
<view
v-if=
"userBean.expireTime
<
=
0
"
style=
"font-size: 30rpx;color: #5b1500;margin-top: 12rpx;"
>
解锁全部
短剧
解锁全部
小说
</view>
<view
v-else
style=
"font-size: 30rpx;color: #5b1500;margin-top: 12rpx;"
>
到期时间:
{{
userBean
.
expireTime
*
1000
|
formatDate
(
'yyyy-MM-dd'
)
}}
...
...
vedio/pagesD/watchRecord/watchRecord.vue
View file @
6313ff3d
...
...
@@ -25,7 +25,7 @@
src=
"../../static/home_collect_img_1.png"
></image>
<view
style=
"font-size: 22rpx;color: gray;margin-top: 10rpx;display: flex;justify-content: center;"
>
追剧
</view>
小说
</view>
</view>
</view>
</view>
...
...
vedio/utils/ReadCount.js
0 → 100644
View file @
6313ff3d
export
default
class
ReadCount
{
constructor
(
param
)
{
const
{
count
}
=
param
||
{}
this
.
count
=
count
;
let
result
=
initWithCount
(
count
);
const
{
hour
,
minute
,
second
}
=
result
;
this
.
hour
=
hour
;
this
.
minute
=
minute
;
this
.
second
=
second
;
}
}
function
initWithCount
(
count
)
{
if
(
!
count
)
return
{};
let
second
=
parseInt
(
count
/
1000
);
// 秒数
let
minute
=
parseInt
(
second
/
60
);
// 分钟数
second
=
second
%
60
;
// 更新秒数
let
hour
=
parseInt
(
minute
/
60
);
// 小时数
minute
=
minute
%
60
;
// 更新分钟数
return
{
hour
,
minute
,
second
}
}
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment