Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
shop_mobile_uni
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
郑秀明
shop_mobile_uni
Commits
26d540c0
Commit
26d540c0
authored
Aug 10, 2020
by
王建威
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' into wjw_monthly
parents
722653ef
a4d647d5
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
64 additions
and
40 deletions
+64
-40
manifest.json
manifest.json
+2
-2
package.json
package.json
+1
-1
home.vue
pages/home/home.vue
+61
-37
No files found.
manifest.json
View file @
26d540c0
...
...
@@ -2,7 +2,7 @@
"name"
:
"shop_mobile_uni"
,
"appid"
:
"__UNI__F904656"
,
"description"
:
""
,
"versionName"
:
"1.0.
19
"
,
"versionName"
:
"1.0.
23
"
,
"versionCode"
:
"100"
,
"transformPx"
:
false
,
"app-plus"
:
{
...
...
@@ -51,7 +51,7 @@
"mode"
:
"history"
,
"base"
:
"/uni"
},
"publicPath"
:
"https://dbc-static.oss-cn-beijing.aliyuncs.com/dbc-shop/uni/
mirror/1.0.19
/"
,
"publicPath"
:
"https://dbc-static.oss-cn-beijing.aliyuncs.com/dbc-shop/uni/
prod/1.0.23
/"
,
"optimization"
:
{
"treeShaking"
:
{
"enable"
:
true
...
...
package.json
View file @
26d540c0
{
"name"
:
"shop_mobile_uni"
,
"version"
:
"1.0.
19
"
,
"version"
:
"1.0.
23
"
,
"description"
:
"谛宝多多商城"
,
"scripts"
:
{
"test"
:
"echo
\"
Error: no test specified
\"
&& exit 1"
,
...
...
pages/home/home.vue
View file @
26d540c0
...
...
@@ -13,6 +13,9 @@
>
<view
class=
"homeContent"
style=
"padding: 100rpx 0 110rpx;background-color: #f8f8f8;"
>
<component
v-for=
"(item, index) in data"
:key=
"index"
:is=
"item.name"
:wrapper_props=
"item.wrapper_props"
:isLogin=
"isLogin"
:ref=
"item.name"
></component>
<view
class=
"protocol"
>
<text
@
click=
"jumpPhp('app=member&act=register_agree')"
>
《服务协议》
</text>
|
<text
@
click=
"jumpPhp('app=member&act=register_privacy')"
>
《隐私政策》
</text>
</view>
<BottomBar
/>
<uni-popup
ref=
"popup"
type=
"center"
:maskClick=
"true"
>
<view
class=
'coupon_dialog'
>
...
...
@@ -21,30 +24,32 @@
</view>
</uni-popup>
</view>
</skeleton>
</
template
>
<
script
>
import
SearchBar
from
'./components/searchbar.vue'
;
import
Navigation
from
'./components/navigation.vue'
;
import
Slide
from
'./components/slide.vue'
;
import
MainTitle
from
'./components/maintitle.vue'
;
import
GoodsList
from
'./components/goodslist.vue'
;
import
FunctionMenu
from
'./components/functionmenu.vue'
;
import
Promotion
from
'./components/promotion.vue'
;
import
HotRecommd
from
'./components/hotrecommd.vue'
;
import
CustomStyle
from
'./components/custowstyle.vue'
;
</skeleton>
</
template
>
<
script
>
import
SearchBar
from
'./components/searchbar.vue'
;
import
Navigation
from
'./components/navigation.vue'
;
import
Slide
from
'./components/slide.vue'
;
import
MainTitle
from
'./components/maintitle.vue'
;
import
GoodsList
from
'./components/goodslist.vue'
;
import
FunctionMenu
from
'./components/functionmenu.vue'
;
import
Promotion
from
'./components/promotion.vue'
;
import
HotRecommd
from
'./components/hotrecommd.vue'
;
import
CustomStyle
from
'./components/custowstyle.vue'
;
import
MultImage
from
'./components/multimage.vue'
;
import
BottomBar
from
"@/components/BottomBar/BottomBar.vue"
;
import
uniPopup
from
'@/components/uni-popup/uni-popup.vue'
;
import
Skeleton
from
'@/components/J-skeleton/J-skeleton.vue'
;
export
default
{
data
()
{
return
{
import
Skeleton
from
'@/components/J-skeleton/J-skeleton.vue'
;
import
{
php
}
from
'../../common/host.js'
;
export
default
{
data
()
{
return
{
data
:
[],
isLogin
:
0
,
fixFlag
:
false
,
loading
:
true
,
from_login
:
0
,
skeleton1
:
{
avatarSize
:
'160rpx'
,
row
:
2
,
...
...
@@ -56,10 +61,12 @@
avatarShape
:
'square'
,
titleWidth
:
'100%'
},
COUPON_ID
:
'185'
//优惠券ID
}
COUPON_ID
:
'185'
//优惠券ID
}
},
onLoad
()
{
onLoad
(
option
)
{
const
{
from_login
}
=
option
;
this
.
from_login
=
from_login
;
this
.
loading
=
true
;
this
.
getData
();
// uni.showLoading({
...
...
@@ -98,6 +105,10 @@
// 获取是否领取优惠券
if
(
res
.
data
.
login_flg
===
1
){
this
.
get_coupon
(
res
.
data
.
reg_time
);
}
else
{
// if(!this.from_login){
// window.location.href = `${php}app=member&act=login`
// }
}
}
else
{
uni
.
showToast
({
...
...
@@ -121,6 +132,9 @@
this
.
$jump
(
`
${
origin
}
/mobile/index.php?app=coupon&act=view&id=
${
this
.
COUPON_ID
}
`
);
this
.
$refs
.
popup
.
close
();
},
jumpPhp
(
url
){
window
.
location
.
href
=
`
${
php
}${
url
}
`
;
},
// 向小程序发送数据
postData
(){
jWeixin
.
miniProgram
.
getEnv
(
function
(
res
)
{
...
...
@@ -156,30 +170,40 @@
}
})
}
},
},
components
:
{
BottomBar
,
SearchBar
,
Navigation
,
Slide
,
MainTitle
,
GoodsList
,
FunctionMenu
,
Promotion
,
HotRecommd
,
CustomStyle
,
BottomBar
,
SearchBar
,
Navigation
,
Slide
,
MainTitle
,
GoodsList
,
FunctionMenu
,
Promotion
,
HotRecommd
,
CustomStyle
,
MultImage
,
uniPopup
,
Skeleton
}
}
</
script
>
Skeleton
}
}
</
script
>
<
style
lang=
"scss"
scoped
>
.homeContent
{
padding
:
100rpx
0
110rpx
;
background-color
:
#f8f8f8
;
}
.protocol
{
font-size
:
24rpx
;
text-align
:
center
;
height
:
46rpx
;
line-height
:
46rpx
;
text
{
color
:
#B1825A
;
font-size
:
24rpx
;
}
}
.coupon_dialog
{
width
:
600rpx
;
height
:
786rpx
;
...
...
@@ -203,5 +227,5 @@
text-align
:
center
;
border-radius
:
84rpx
;
}
}
}
</
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