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
86a0775d
Commit
86a0775d
authored
Mar 05, 2020
by
gaodapeng
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix bugs
parent
e7242221
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
8 deletions
+13
-8
balance.js
pages/balance/balance.js
+11
-6
home.js
pages/home/home.js
+2
-2
No files found.
pages/balance/balance.js
View file @
86a0775d
...
...
@@ -31,10 +31,12 @@ Page({
data
:
null
},
success
:
(
res
)
=>
{
e
.
preventDefault
();
console
.
log
(
`sendBuddyMessage success:
${
JSON
.
stringify
(
res
)}
`
);
// e.preventDefault();
my
.
navigateBack
();
},
fail
:
(
res
)
=>
{
console
.
info
(
`sendBuddyMessage failed:
${
JSON
.
stringify
(
res
)}
`
);
console
.
log
(
`sendBuddyMessage failed:
${
JSON
.
stringify
(
res
)}
`
);
}
});
}
...
...
@@ -48,6 +50,7 @@ Page({
},
onLoad
(
options
)
{
console
.
log
(
"balance onLoad==>"
+
JSON
.
stringify
(
options
));
var
totalQuantity
=
options
.
totalQuantity
var
totalPrice
=
options
.
totalPrice
...
...
@@ -108,10 +111,6 @@ Page({
}
});
},
onShow
()
{
console
.
log
(
"balance onShow"
);
my
.
ix
.
onBuddyMessage
({
success
:
(
res
)
=>
{
console
.
info
(
`onBuddyMessage success:
${
JSON
.
stringify
(
res
)}
`
);
...
...
@@ -129,6 +128,12 @@ Page({
}
}
});
},
onShow
()
{
console
.
log
(
"balance onShow"
);
//这个界面接受事件是在onLoad,去除监听是在onUnload
},
onHide
()
{
...
...
pages/home/home.js
View file @
86a0775d
...
...
@@ -363,7 +363,7 @@ Page({
printer
.
printNowDate
(),
];
if
(
null
!=
printLastOrder_goodsList
&&
printLastOrder_goodsList
.
length
>
0
)
{
cmds
.
push
(
printer
.
printDivide
(
"-"
)),
cmds
.
push
(
printer
.
printDivide
(
"-"
)),
cmds
.
push
(
printer
.
printText
(
"活动商品"
)),
cmds
.
push
(
printer
.
printText
(
"商品名称 "
+
" 编码 "
+
" 数量"
))
for
(
var
i
=
0
;
i
<
printLastOrder_goodsList
.
length
;
i
++
)
{
...
...
@@ -373,7 +373,7 @@ Page({
cmds
.
push
(
printer
.
printTwoText
(
printLastOrder_goodsList
[
i
].
barcode
,
printLastOrder_goodsList
[
i
].
quantity
+
""
));
}
}
cmds
.
push
(
printer
.
setAlign
(
printer
.
ALIGN_LEFT
));
cmds
.
push
(
printer
.
printDivide
(
"-"
));
cmds
.
push
(
printer
.
printText
(
"应收金额:"
+
printLastOrder_orderPriceYuan
));
...
...
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