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
3c12889d
Commit
3c12889d
authored
Jun 28, 2020
by
gaodapeng
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
格式化
parent
e8a373c7
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
17 additions
and
17 deletions
+17
-17
app.js
app.js
+9
-10
scan.js
pages/scan/scan.js
+8
-7
No files found.
app.js
View file @
3c12889d
...
...
@@ -2,9 +2,9 @@ var fundebug = require('./utils/fundebug.0.2.0.min.js');
import
monitor
from
'/utils/alipayLogger'
;
fundebug
.
init
(
{
apikey
:
'c0c5937571f82aecab3f7578bea5d8163455cd2407863f94829bee12324f57b4'
})
{
apikey
:
'c0c5937571f82aecab3f7578bea5d8163455cd2407863f94829bee12324f57b4'
})
App
(
monitor
.
hookApp
({
globalData
:
{
version
:
"1.0.1.20200311"
,
...
...
@@ -16,14 +16,14 @@ App(monitor.hookApp({
RELEASE_URL
:
"https://cashier.miyahub.com/"
,
BASE_URL
:
"https://cashier.miyahub.com/"
,
appId
:
"2021001107603212"
,
backScreenAppId
:
"2021001107617164"
,
backScreenAppId
:
"2021001107617164"
,
//小程序容器版本
containerVersionCode
:
null
,
localAccountInfo
:
null
,
//模拟器上需要sn有值
sn
:
"xx"
,
//是否登录完成
isLoginOk
:
false
isLoginOk
:
false
},
...
...
@@ -136,8 +136,7 @@ App(monitor.hookApp({
});
},
onError
(
err
)
{
onError
(
err
)
{
fundebug
.
onError
(
err
);
},
...
...
pages/scan/scan.js
View file @
3c12889d
...
...
@@ -184,7 +184,8 @@ Page({
var
scanGoodRequest
=
api
.
createCommonRequest
();
scanGoodRequest
.
goodsId
=
barcode
;
//管理员需要额外传一个storeid 但是目前这个设备是没有
console
.
log
(
"扫商品的请求 ==>"
+
JSON
.
stringify
(
scanGoodRequest
));
console
.
log
(
"扫商品的请求url: ==>"
+
getApp
().
globalData
.
BASE_URL
+
API_SCAN
);
console
.
log
(
"扫商品的请求content ==>"
+
JSON
.
stringify
(
scanGoodRequest
));
my
.
request
({
url
:
getApp
().
globalData
.
BASE_URL
+
API_SCAN
,
method
:
'POST'
,
...
...
@@ -201,13 +202,13 @@ Page({
duration
:
2000
});
}
else
{
if
(
res
.
data
.
data
==
null
||
res
.
data
.
data
.
barcode
==
null
)
{
if
(
res
.
data
.
data
==
null
||
res
.
data
.
data
.
barcode
==
null
)
{
my
.
showToast
({
type
:
'fail'
,
content
:
"该商品没有对应的活动"
,
duration
:
2000
});
}
else
{
}
else
{
//识别商品成功
this
.
parseGoodInfo
(
res
.
data
.
data
);
console
.
log
(
"识别商品信息成功"
);
...
...
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