Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
D
doublescreen-front
Project
Project
Details
Activity
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
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
pengguangpu
doublescreen-front
Commits
04c9a704
Commit
04c9a704
authored
Feb 27, 2020
by
jiangjiantao
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
bugfixed
parent
cd844259
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
89 additions
and
15 deletions
+89
-15
app.json
app.json
+2
-2
home.acss
pages/home/home.acss
+46
-10
home.axml
pages/home/home.axml
+1
-1
home.js
pages/home/home.js
+40
-2
No files found.
app.json
View file @
04c9a704
{
"pages"
:
[
"pages/login/login"
,
"pages/home/home"
,
"pages/paysuccess/paysuccess"
,
"pages/balance/balance"
,
"pages/scan/scan"
,
"pages/home/home"
"pages/scan/scan"
],
"window"
:
{
"defaultTitle"
:
""
...
...
pages/home/home.acss
View file @
04c9a704
page
{
.page
{
display: flex;
flex-direction: column;
width: 100%;
...
...
@@ -6,20 +6,20 @@ page{
align-items: center;
}
.bg{
position:fixed;
width:100%;
height:100%;
left:0rpx;
top:0rpx;
bottom:0rpx;
.bg
{
position:
fixed;
width:
100%;
height:
100%;
left:
0rpx;
top:
0rpx;
bottom:
0rpx;
/* background:url(/images/bg_home.png) no-repeat fixed top; */
background-size:100% 100%;
background-size:
100% 100%;
/* border: 2px solid red; */
box-sizing: border-box;
}
.container{
.container
{
position: relative;
width: 750rpx;
height: 430rpx;
...
...
@@ -80,3 +80,39 @@ page{
display: flex;
flex-direction: column;
}
/* 提货商品布局 */
.page-pick-goods {
display: flex;
flex-direction: column;
align-items: center;
width: 100%;
height: 100%;
background: white;
position: absolute
}
/* 提货商品布局top部分 */
.pick-goods-header {
width: 100%;
height: 200rpx;
display: flex;
flex-direction: column;
font-size: 42px;
align-items: center;
justify-content: center;
font-size: 40rpx;
font-family: PingFangSC-Medium, PingFang SC;
font-weight: 500;
background: url(/images/scan_header_bg.png) no-repeat fixed top;
background-size: 100% 200rpx;
color: rgba(255, 255, 255, 1);
}
/* 提货商品body部分 */
.pick-goods-body {
width: 700rpx;
height: 100%;
background: transparent
}
\ No newline at end of file
pages/home/home.axml
View file @
04c9a704
...
...
@@ -3,7 +3,7 @@
<image mode="scaleToFill" style="width:100%;height:100%;" src="{{adUrl}}"/>
</view>
<!-- 提货布局 -->
<view class="page-pick-goods" a:if="{{}}">
<view class="page-pick-goods" a:if="{{
pickGoodsState == 3
}}">
<view class="pick-goods-header">
提货商品如下
</view>
...
...
pages/home/home.js
View file @
04c9a704
...
...
@@ -26,6 +26,10 @@ Page({
dialogResultFailureText
:
"兑换失败,请稍后重试!"
,
adUrl
:
"/images/img_ad1.png"
,
toSetting
:
false
,
//提货
pickGoodsState
:
3
,
pickGoodsMsg
:
"录入失败!无效的提货码"
,
pickGoods
:
[],
},
onLoad
()
{
...
...
@@ -194,7 +198,14 @@ Page({
}
});
}
//隐藏提货页面
if
(
res
.
data
==
0
){
context
.
setData
({
pickGoodsState
:
0
,
pickGoods
:[]
})
}
}
}
});
...
...
@@ -498,9 +509,36 @@ Page({
//提货商品
pickGoods
(
code
)
{
let
context
=
this
;
this
.
setData
({
scanDialogDisplay
:
2
})
setTimeout
(()
=>
{
//模拟提货数据
let
pickgoodsTemp
=
[]
for
(
var
i
=
0
;
i
<
3
;
i
++
){
var
good
=
{};
good
.
name
=
"SK-II R.N.A.超肌能紧致弹力精华"
good
.
price
=
"1098"
good
.
quantity
=
1
pickgoodsTemp
.
push
(
good
)
}
let
pickGoodsReq
=
{}
pickGoodsReq
.
pickGoodsState
=
3
;
pickGoodsReq
.
pickGoods
=
pickgoodsTemp
;
my
.
ix
.
sendBuddyMessage
({
target
:
getApp
().
globalData
.
backScreenAppId
,
data
:
{
action
:
ACTION_PICK_UP_GOODS
,
data
:
pickGoodsReq
},
success
:
(
sres
)
=>
{
context
.
setData
({
pickGoods
:
pickgoodsTemp
,
pickGoodsState
:
3
,
scanDialogDisplay
:
0
})
},
fail
:
(
fres
)
=>
{
console
.
info
(
`sendBuddyMessage failed:
${
JSON
.
stringify
(
res
)}
`
);
}
});
},
700
);
},
...
...
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