Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
M
mallapp
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
viitto
mallapp
Commits
0c84d628
Commit
0c84d628
authored
Nov 03, 2020
by
黄奎
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
页面修改
parent
b2887f7f
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
779 additions
and
864 deletions
+779
-864
integral-detail.vue
pages/user-center/integral-detail/integral-detail.vue
+170
-207
user-center.vue
pages/user-center/user-center.vue
+566
-601
index.vue
pages/video/index.vue
+31
-43
webbox.vue
pages/webbox/webbox.vue
+12
-13
No files found.
pages/user-center/integral-detail/integral-detail.vue
View file @
0c84d628
<
template
>
<view
class=
"integralDStyle"
:style=
"
{ height: contentHeight }">
<u-tabs
:list=
"list"
:is-scroll=
"false"
:current=
"current"
@
change=
"change"
:active-color=
"mainColor"
></u-tabs>
<u-empty
v-if=
"g.length == 0"
text=
"暂无积分明细"
mode=
"list"
></u-empty>
<view
v-if=
"g.length > 0"
style=
"
height: calc(100vh - 50px);
width: calc(100vw);
overflow: hidden;
"
>
<scroll-view
:scroll-y=
"true"
:enable-back-to-top=
"true"
:enable-flex=
"true"
@
scrolltolower=
"lower"
:style=
"
{ height: '100%' }"
>
<view
class=
"interDList"
v-for=
"(x, i) in g"
:key=
"i"
>
<Text>
{{
x
.
Description
}}
</Text>
<view
style=
"display: flex;align-items: center;justify-content: space-between;width: 100%;margin-top: 5px;"
>
<Text
:style=
"
{color:x.Type==1?mainColor:secondary}">
{{
x
.
Type
==
1
?
'+'
:
'-'
}}{{
x
.
Integral
}}
积分
</Text>
<Text
style=
'font-size: 12px; color: #B5B5B5;'
>
时间:
{{
x
.
CreateDate
}}
</Text>
</view>
</view>
<u-loadmore
:status=
"status"
:load-text=
"loadText"
:font-size=
"24"
:margin-top=
"20"
:margin-bottom=
"20"
bg-color=
"#f3f4f6"
/>
</scroll-view>
</view>
<!-- 加载中 -->
<view
class=
"loading"
v-if=
"loading"
>
<u-loading
mode=
"flower"
size=
"48"
>
>
</u-loading>
<Text
style=
"color: #fff; margin-top: 10rpx;"
>
加载中...
</Text>
</view>
<!-- 取消提示 -->
<u-toast
ref=
"uToast"
/>
<auth
v-if=
"showAuth"
@
changeuserinfo=
"reloadUserinfo"
@
gbAuth=
'gbAuth'
></auth>
</view>
<view
class=
"integralDStyle"
:style=
"
{ height: contentHeight }">
<u-tabs
:list=
"list"
:is-scroll=
"false"
:current=
"current"
@
change=
"change"
:active-color=
"mainColor"
></u-tabs>
<u-empty
v-if=
"g.length == 0"
text=
"暂无积分明细"
mode=
"list"
></u-empty>
<view
v-if=
"g.length > 0"
style=
"height: calc(100vh - 50px);width: calc(100vw);overflow: hidden; "
>
<scroll-view
:scroll-y=
"true"
:enable-back-to-top=
"true"
:enable-flex=
"true"
@
scrolltolower=
"lower"
:style=
"
{ height: '100%' }">
<view
class=
"interDList"
v-for=
"(x, i) in g"
:key=
"i"
>
<Text>
{{
x
.
Description
}}
</Text>
<view
style=
"display: flex;align-items: center;justify-content: space-between;width: 100%;margin-top: 5px;"
>
<Text
:style=
"
{color:x.Type==1?mainColor:secondary}">
{{
x
.
Type
==
1
?
'+'
:
'-'
}}{{
x
.
Integral
}}
积分
</Text>
<Text
style=
'font-size: 12px; color: #B5B5B5;'
>
时间:
{{
x
.
CreateDate
}}
</Text>
</view>
</view>
<u-loadmore
:status=
"status"
:load-text=
"loadText"
:font-size=
"24"
:margin-top=
"20"
:margin-bottom=
"20"
bg-color=
"#f3f4f6"
/>
</scroll-view>
</view>
<!-- 加载中 -->
<view
class=
"loading"
v-if=
"loading"
>
<u-loading
mode=
"flower"
size=
"48"
>
>
</u-loading>
<Text
style=
"color: #fff; margin-top: 10rpx;"
>
加载中...
</Text>
</view>
<!-- 取消提示 -->
<u-toast
ref=
"uToast"
/>
<auth
v-if=
"showAuth"
@
changeuserinfo=
"reloadUserinfo"
@
gbAuth=
'gbAuth'
></auth>
</view>
</
template
>
<
script
>
import
auth
from
"../../../components/auth/index.vue"
;
export
default
{
components
:
{
auth
},
data
()
{
return
{
pageTitle
:
"积分明细"
,
current
:
0
,
list
:
[
{
name
:
"收入"
},
{
name
:
"支出"
},
],
showAuth
:
false
,
msg
:{
pageIndex
:
1
,
pageSize
:
10
,
Type
:
0
},
mainColor
:
""
,
secondary
:
''
,
contentHeight
:
0
,
page
:
1
,
page_count
:
1
,
g
:
[],
loading
:
false
,
isover
:
false
,
status
:
"loadmore"
,
loadText
:
{
loadmore
:
"轻轻上拉,加载更多"
,
loading
:
"努力加载中"
,
nomore
:
"没有更多了"
,
},
};
},
created
()
{
this
.
contentHeight
=
this
.
$utils
.
calcContentHeight
(
-
40
)
+
"px"
;
this
.
mainColor
=
this
.
$uiConfig
.
mainColor
;
this
.
secondary
=
this
.
$uiConfig
.
secondary
;
},
mounted
()
{
let
currentPages
=
getCurrentPages
();
let
u
=
"/"
+
currentPages
[
currentPages
.
length
-
1
].
route
;
let
pages
=
wx
.
getStorageSync
(
"basedata"
)
?
wx
.
getStorageSync
(
"basedata"
).
bar_title
:
[];
pages
.
forEach
((
x
)
=>
{
if
(
x
.
value
==
u
)
{
this
.
pageTitle
=
x
.
new_name
?
x
.
new_name
:
x
.
name
;
}
});
uni
.
setNavigationBarTitle
({
title
:
this
.
pageTitle
,
});
},
onLoad
(){
this
.
u
=
uni
.
getStorageSync
(
"mall_UserInfo"
);
if
(
!
this
.
u
)
{
this
.
u
=
{
nickName
:
"未登录"
,
avatarUrl
:
""
};
this
.
showAuth
=
true
;
}
else
{
this
.
init
();
}
},
methods
:
{
change
(
index
)
{
this
.
current
=
index
;
this
.
msg
.
pageIndex
=
1
;
this
.
g
=
[];
this
.
loading
=
true
;
this
.
init
();
},
init
()
{
this
.
loading
=
true
;
this
.
msg
.
Type
=
this
.
current
+
1
this
.
request2
(
{
url
:
'/api/AppletUser/GetMemberIntegralPageList'
,
data
:
this
.
msg
},
res
=>
{
if
(
res
.
resultCode
==
1
){
this
.
loading
=
false
;
this
.
g
=
this
.
g
.
concat
(
res
.
data
.
pageData
);
this
.
page_count
=
res
.
data
.
pageCount
;
if
(
this
.
page_count
==
1
)
{
this
.
status
=
"nomore"
;
}
}
}
);
},
lower
(
e
)
{
if
(
this
.
msg
.
pageIndex
<
this
.
page_count
)
{
this
.
msg
.
pageIndex
++
;
this
.
status
=
"loading"
;
this
.
init
();
}
else
{
this
.
status
=
"nomore"
;
}
},
reloadUserinfo
()
{
this
.
u
=
uni
.
getStorageSync
(
"mall_UserInfo"
);
// this.showAuth=false;
this
.
init
();
},
//关闭登录窗口
gbAuth
(){
uni
.
navigateBack
()
}
},
};
import
auth
from
"../../../components/auth/index.vue"
;
export
default
{
components
:
{
auth
},
data
()
{
return
{
pageTitle
:
"积分明细"
,
current
:
0
,
list
:
[{
name
:
"收入"
},
{
name
:
"支出"
},
],
showAuth
:
false
,
msg
:
{
pageIndex
:
1
,
pageSize
:
10
,
Type
:
0
},
mainColor
:
""
,
secondary
:
''
,
contentHeight
:
0
,
page
:
1
,
page_count
:
1
,
g
:
[],
loading
:
false
,
isover
:
false
,
status
:
"loadmore"
,
loadText
:
{
loadmore
:
"轻轻上拉,加载更多"
,
loading
:
"努力加载中"
,
nomore
:
"没有更多了"
,
},
};
},
created
()
{
this
.
contentHeight
=
this
.
$utils
.
calcContentHeight
(
-
40
)
+
"px"
;
this
.
mainColor
=
this
.
$uiConfig
.
mainColor
;
this
.
secondary
=
this
.
$uiConfig
.
secondary
;
},
mounted
()
{
let
currentPages
=
getCurrentPages
();
let
u
=
"/"
+
currentPages
[
currentPages
.
length
-
1
].
route
;
let
pages
=
wx
.
getStorageSync
(
"basedata"
)
?
wx
.
getStorageSync
(
"basedata"
).
bar_title
:
[];
pages
.
forEach
((
x
)
=>
{
if
(
x
.
value
==
u
)
{
this
.
pageTitle
=
x
.
new_name
?
x
.
new_name
:
x
.
name
;
}
});
uni
.
setNavigationBarTitle
({
title
:
this
.
pageTitle
,
});
},
onLoad
()
{
this
.
u
=
uni
.
getStorageSync
(
"mall_UserInfo"
);
if
(
!
this
.
u
)
{
this
.
u
=
{
nickName
:
"未登录"
,
avatarUrl
:
""
};
this
.
showAuth
=
true
;
}
else
{
this
.
init
();
}
},
methods
:
{
change
(
index
)
{
this
.
current
=
index
;
this
.
msg
.
pageIndex
=
1
;
this
.
g
=
[];
this
.
loading
=
true
;
this
.
init
();
},
init
()
{
this
.
loading
=
true
;
this
.
msg
.
Type
=
this
.
current
+
1
this
.
request2
({
url
:
'/api/AppletUser/GetMemberIntegralPageList'
,
data
:
this
.
msg
},
res
=>
{
if
(
res
.
resultCode
==
1
)
{
this
.
loading
=
false
;
this
.
g
=
this
.
g
.
concat
(
res
.
data
.
pageData
);
this
.
page_count
=
res
.
data
.
pageCount
;
if
(
this
.
page_count
==
1
)
{
this
.
status
=
"nomore"
;
}
}
}
);
},
lower
(
e
)
{
if
(
this
.
msg
.
pageIndex
<
this
.
page_count
)
{
this
.
msg
.
pageIndex
++
;
this
.
status
=
"loading"
;
this
.
init
();
}
else
{
this
.
status
=
"nomore"
;
}
},
reloadUserinfo
()
{
this
.
u
=
uni
.
getStorageSync
(
"mall_UserInfo"
);
this
.
init
();
},
//关闭登录窗口
gbAuth
()
{
uni
.
navigateBack
()
}
},
};
</
script
>
<
style
>
.integralDStyle
{
width
:
100%
;
height
:
100%
;
background
:
#f3f4f6
;
}
.integralDStyle
{
width
:
100%
;
height
:
100%
;
background
:
#f3f4f6
;
}
.integralDStyle
.loading
{
width
:
200
rpx
;
height
:
200
rpx
;
background
:
#000000
;
opacity
:
0.7
;
border-radius
:
10
rpx
;
display
:
flex
;
flex-direction
:
column
;
align-items
:
center
;
justify-content
:
center
;
position
:
fixed
;
left
:
50%
;
top
:
30%
;
margin-left
:
-100
rpx
;
z-index
:
999
;
}
.integralDStyle
.interDList
{
width
:
100%
;
padding
:
20px
15px
;
display
:
fle
x
;
flex-direction
:
column
;
background
:
#fff
;
border-top
:
1px
solid
#f5f5f5
;
}
.integralDStyle
.loading
{
width
:
200
rpx
;
height
:
200
rpx
;
background
:
#000000
;
opacity
:
0.7
;
border-radius
:
10
rpx
;
display
:
flex
;
flex-direction
:
column
;
align-items
:
center
;
justify-content
:
center
;
position
:
fixed
;
left
:
50%
;
top
:
30%
;
margin-left
:
-100
rpx
;
z-index
:
999
;
}
.integralDStyle
.interDList
{
width
:
100%
;
padding
:
20px
15p
x
;
display
:
flex
;
flex-direction
:
column
;
background
:
#fff
;
border-top
:
1px
solid
#f5f5f5
;
}
</
style
>
pages/user-center/user-center.vue
View file @
0c84d628
This diff is collapsed.
Click to expand it.
pages/video/index.vue
View file @
0c84d628
...
...
@@ -197,7 +197,7 @@
return
{
vlist
:
[],
videoIndex
:
0
,
swiperHeight
:
0
,
//高度
swiperHeight
:
0
,
//高度
GoodsId
:
0
,
//商品id
nav
:
0
,
goodObj
:
{},
//商品对象
...
...
@@ -214,7 +214,7 @@
comGoodImg
:
''
,
//商品缩小图
comGoodTitle
:
''
,
//商品名称
comGoodPrice
:
''
,
//商品价格
showSku
:
false
,
//是否显示商品SKU
showSku
:
false
,
//是否显示商品SKU
sku
:
{},
showAuth
:
false
,
u
:
{},
...
...
@@ -234,23 +234,20 @@
this
.
GoodsId
=
option
.
GoodsId
;
this
.
sysheight
=
uni
.
getSystemInfoSync
().
windowHeight
;
this
.
swiperHeight
=
`
${
this
.
sysheight
}
px`
;
this
.
videoIndex
=
0
;
//默认加载第一条
this
.
videoIndex
=
0
;
//默认加载第一条
this
.
vlist
=
[];
wx
.
showShareMenu
({
withShareTicket
:
true
,
menus
:
[
"shareAppMessage"
,
"shareTimeline"
],
withShareTicket
:
true
,
menus
:
[
"shareAppMessage"
,
"shareTimeline"
],
});
},
methods
:
{
//获取商品视频
getVideoHeight
(
type
)
{
getVideoHeight
(
type
)
{
//视频填充方式(0默认,1-填充)
if
(
type
==
0
)
{
if
(
type
==
0
)
{
return
'contain'
}
else
{
}
else
{
return
'fill'
}
},
...
...
@@ -273,14 +270,11 @@
this
.
videoContextList
[
curIndex
].
seek
(
0
)
this
.
isPlay
=
true
this
.
videoIndex
=
curIndex
;
this
.
comGoodImg
=
this
.
vlist
[
curIndex
].
picUrl
;
this
.
comGoodTitle
=
this
.
vlist
[
curIndex
].
name
;
this
.
comGoodPrice
=
this
.
vlist
[
curIndex
].
price
;
this
.
GoodsId
=
this
.
vlist
[
curIndex
].
id
;
this
.
sku
=
this
.
vlist
[
curIndex
];
let
xz
=
this
.
vlist
.
length
-
e
.
detail
.
current
;
if
(
xz
==
1
)
{
this
.
msg
.
pageIndex
++
;
...
...
@@ -355,7 +349,7 @@
picUrl
:
data
[
0
].
cover_pic
,
price
:
this
.
goodObj
.
price
,
video_url
:
data
[
0
].
video_url
,
VideoType
:
data
[
0
].
video_type
VideoType
:
data
[
0
].
video_type
}
this
.
vlist
.
push
(
obj
);
this
.
videoContextList
=
[]
...
...
@@ -402,43 +396,37 @@
};
},
onShareTimeline
()
{
setTimeout
(()
=>
{
this
.
getReceive
();
},
2500
);
let
uid
=
uni
.
getStorageSync
(
"mall_UserInfo"
)
?
uni
.
getStorageSync
(
"mall_UserInfo"
).
UserId
:
0
;
if
(
uid
==
0
){
uid
=
uni
.
getStorageSync
(
"pid"
)?
uni
.
getStorageSync
(
"pid"
).
pid
:
0
}
let
SmallShopId
=
uni
.
getStorageSync
(
"mall_UserInfo"
)
?
uni
.
getStorageSync
(
"mall_UserInfo"
).
SmallShopId
:
0
;
if
(
SmallShopId
==
0
){
//如果微店id为0 去找所属微店id
SmallShopId
=
uni
.
getStorageSync
(
"mall_UserInfo"
)
?
uni
.
getStorageSync
(
"mall_UserInfo"
).
UserSmallShopId
:
0
;
setTimeout
(()
=>
{
this
.
getReceive
();
},
2500
);
let
uid
=
uni
.
getStorageSync
(
"mall_UserInfo"
)
?
uni
.
getStorageSync
(
"mall_UserInfo"
).
UserId
:
0
;
if
(
uid
==
0
)
{
uid
=
uni
.
getStorageSync
(
"pid"
)
?
uni
.
getStorageSync
(
"pid"
).
pid
:
0
}
return
{
title
:
this
.
comGoodTitle
,
query
:
"GoodsId="
+
this
.
GoodsId
+
"&user_id="
+
uid
+
"&SmallShopId="
+
SmallShopId
,
imageUrl
:
this
.
comGoodImg
,
};
let
SmallShopId
=
uni
.
getStorageSync
(
"mall_UserInfo"
)
?
uni
.
getStorageSync
(
"mall_UserInfo"
).
SmallShopId
:
0
;
if
(
SmallShopId
==
0
)
{
//如果微店id为0 去找所属微店id
SmallShopId
=
uni
.
getStorageSync
(
"mall_UserInfo"
)
?
uni
.
getStorageSync
(
"mall_UserInfo"
).
UserSmallShopId
:
0
;
}
return
{
title
:
this
.
comGoodTitle
,
query
:
"GoodsId="
+
this
.
GoodsId
+
"&user_id="
+
uid
+
"&SmallShopId="
+
SmallShopId
,
imageUrl
:
this
.
comGoodImg
,
};
},
//点击商品
getShowInfo
()
{
this
.
isShowInfo
=
!
this
.
isShowInfo
;
}
},
mounted
()
{},
created
()
{
this
.
nav
=
uni
.
getMenuButtonBoundingClientRect
().
top
;
},
}
</
script
>
<
style
>
</
style
>
</
script
>
\ No newline at end of file
pages/webbox/webbox.vue
View file @
0c84d628
<
template
>
<web-view
:src=
"url"
></web-view>
<web-view
:src=
"url"
></web-view>
</
template
>
<
script
>
export
default
{
data
()
{
return
{
url
:
""
}
},
onLoad
:
function
(
option
)
{
//option为object类型,会序列化上个页面传递的参数
this
.
url
=
decodeURIComponent
(
option
.
u
)
}
}
export
default
{
data
()
{
return
{
url
:
""
}
},
onLoad
:
function
(
option
)
{
//option为object类型,会序列化上个页面传递的参数
this
.
url
=
decodeURIComponent
(
option
.
u
)
}
}
</
script
>
<
style
>
</
style
>
\ No newline at end of file
</
style
>
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