Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
F
familyMart_takeaway
Overview
Overview
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
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
guanghui.cui
familyMart_takeaway
Commits
a0d9c64d
Commit
a0d9c64d
authored
Aug 27, 2018
by
guanghui.cui
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
增加空值判断
parent
166f20c2
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
1 deletions
+7
-1
src/main.cpp
+7
-1
No files found.
src/main.cpp
View file @
a0d9c64d
...
...
@@ -233,6 +233,12 @@ void* listen_pos_func(void* arg)
int
main
(
int
argc
,
char
*
argv
[])
{
////--------test------------
//JsonModule jsonTest;
//std::string json = "{\"alertTime\":1534416551000,\"channel\":\"201\",\"id\":117049102732151083,\"pcId\":\"10\",\"qty\":0,\"saftQty\":1,\"selfMacId\":\"2027490121\",\"shelfNo\":\"20274901210405\",\"sku\":\"20627836\",\"storeId\":\"202749\",\"pk_id\":1}";
//std::string rltTest;
//jsonTest.convertDataOds2Pos(json, rltTest);
////-------------------------
if
(
2
==
argc
&&
0
==
strcmp
(
"-v"
,
argv
[
1
]))
{
printf
(
"version:%s
\n
"
,
VERSION
);
return
0
;
...
...
@@ -387,7 +393,7 @@ int main(int argc,char *argv[])
{
LOG
(
INFO
)
<<
"----------- PLUGIN ===>> POS ------------"
;
LOG
(
INFO
)
<<
pushPosData
;
if
(
!
order_send_to_pos
(
pushPosData
,
odsPushData
,
responseData
))
{
if
(
!
pushPosData
.
empty
()
&&
!
order_send_to_pos
(
pushPosData
,
odsPushData
,
responseData
))
{
jsonTool
.
getOdsResponseData
(
101
,
"send to pos failed or receive data illegal!"
,
odsPushData
,
responseData
);
}
}
else
...
...
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