Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
S
sbkpay
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
zhenfei.zhang
sbkpay
Commits
de9bde93
Commit
de9bde93
authored
Nov 27, 2017
by
NitefullWind
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1. roastery版,由POS扫码。
parent
216ee36f
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
6 additions
and
8 deletions
+6
-8
sbkpay/control.cpp
+2
-5
sbkpay/hostwidget.cpp
+1
-0
sbkpay/rspfactory.h
+1
-1
sbkpay/version.h
+1
-1
tests/TestSimphony/tst_testsimphony.cpp
+1
-1
No files found.
sbkpay/control.cpp
View file @
de9bde93
...
@@ -292,19 +292,16 @@ bool Control::HttpPost(QString url, QByteArray &outdata, const QByteArray &indat
...
@@ -292,19 +292,16 @@ bool Control::HttpPost(QString url, QByteArray &outdata, const QByteArray &indat
QLOG_INFO
()
<<
"HttpPost url: "
<<
url
<<
" content: "
<<
content
<<
" accept: "
<<
accept
<<
" timeout: "
<<
timeout
;
QLOG_INFO
()
<<
"HttpPost url: "
<<
url
<<
" content: "
<<
content
<<
" accept: "
<<
accept
<<
" timeout: "
<<
timeout
;
Q
NetworkReply
*
reply
=
manger
.
post
(
request
,
indata
);
Q
SharedPointer
<
QNetworkReply
>
reply
=
QSharedPointer
<
QNetworkReply
>
(
manger
.
post
(
request
,
indata
)
);
connect
(
&
timer
,
&
QTimer
::
timeout
,
&
loop
,
&
QEventLoop
::
quit
);
connect
(
&
timer
,
&
QTimer
::
timeout
,
&
loop
,
&
QEventLoop
::
quit
);
connect
(
&
manger
,
&
QNetworkAccessManager
::
finished
,
&
loop
,
&
QEventLoop
::
quit
);
connect
(
&
manger
,
&
QNetworkAccessManager
::
finished
,
&
loop
,
&
QEventLoop
::
quit
);
connect
(
_widget
,
&
HostWidget
::
Interrupt
,
&
loop
,
&
QEventLoop
::
quit
);
connect
(
_widget
,
&
HostWidget
::
Interrupt
,
&
loop
,
&
QEventLoop
::
quit
);
connect
(
reply
,
static_cast
<
void
(
QNetworkReply
::*
)(
QNetworkReply
::
NetworkError
)
>
(
&
QNetworkReply
::
error
),
&
loop
,
&
QEventLoop
::
quit
);
connect
(
reply
.
data
()
,
static_cast
<
void
(
QNetworkReply
::*
)(
QNetworkReply
::
NetworkError
)
>
(
&
QNetworkReply
::
error
),
&
loop
,
&
QEventLoop
::
quit
);
timer
.
start
(
timeout
*
1000
);
timer
.
start
(
timeout
*
1000
);
loop
.
exec
();
loop
.
exec
();
reply
->
deleteLater
();
#ifdef FM_TEST
#ifdef FM_TEST
QEventLoop
test_loop
;
QEventLoop
test_loop
;
QTimer
test_timer
;
QTimer
test_timer
;
...
...
sbkpay/hostwidget.cpp
View file @
de9bde93
...
@@ -406,6 +406,7 @@ void HostWidget::ShowWithRequest(POSType posType, QJsonObject requestObj)
...
@@ -406,6 +406,7 @@ void HostWidget::ShowWithRequest(POSType posType, QJsonObject requestObj)
QStringList
list
;
QStringList
list
;
list
.
append
(
FMTool
::
GetJsonValue
(
requestObj
,
JSON_KEY_FMID
).
toString
());
list
.
append
(
FMTool
::
GetJsonValue
(
requestObj
,
JSON_KEY_FMID
).
toString
());
_runing
=
true
;
ui
->
label_pay_title
->
setText
(
QString
::
fromLocal8Bit
(
"支付宝退款中..."
));
ui
->
label_pay_title
->
setText
(
QString
::
fromLocal8Bit
(
"支付宝退款中..."
));
emit
RequestWithType
(
refund
,
list
);
emit
RequestWithType
(
refund
,
list
);
...
...
sbkpay/rspfactory.h
View file @
de9bde93
...
@@ -372,7 +372,7 @@ private:
...
@@ -372,7 +372,7 @@ private:
QString
filePath
=
dir
.
absolutePath
();
QString
filePath
=
dir
.
absolutePath
();
if
(
!
filePath
.
endsWith
(
'/'
)
&&
!
filePath
.
endsWith
(
'\\'
))
{
if
(
!
filePath
.
endsWith
(
'/'
)
&&
!
filePath
.
endsWith
(
'\\'
))
{
filePath
.
append
(
'
\\
'
);
filePath
.
append
(
'
/
'
);
}
}
filePath
.
append
(
printFileName
);
filePath
.
append
(
printFileName
);
response
[
JSON_KEY_PRINTPATH
]
=
filePath
;
response
[
JSON_KEY_PRINTPATH
]
=
filePath
;
...
...
sbkpay/version.h
View file @
de9bde93
...
@@ -3,7 +3,7 @@
...
@@ -3,7 +3,7 @@
#define VER_MAJOR 0
#define VER_MAJOR 0
#define VER_MINOR 2
#define VER_MINOR 2
#define VER_REVISION
4
#define VER_REVISION
6
#define VER_BUILD 0
#define VER_BUILD 0
...
...
tests/TestSimphony/tst_testsimphony.cpp
View file @
de9bde93
...
@@ -220,7 +220,7 @@ void TestSimphony::test_POSRequest_data()
...
@@ -220,7 +220,7 @@ void TestSimphony::test_POSRequest_data()
"
\"
storeId
\"
:
\"
1713
\"
, "
"
\"
storeId
\"
:
\"
1713
\"
, "
"
\"
transAmount
\"
: %3, "
"
\"
transAmount
\"
: %3, "
"
\"
transId
\"
: 301439 "
"
\"
transId
\"
: 301439 "
"
\"
code
\"
:
\"
12312
\"
"
"
\"
code
\"
:
\"\"
"
"}"
)
"}"
)
.
arg
(
QDate
::
currentDate
().
toString
(
"yyyyMMdd"
))
.
arg
(
QDate
::
currentDate
().
toString
(
"yyyyMMdd"
))
.
arg
(
CreatePartnerOrderId
())
.
arg
(
CreatePartnerOrderId
())
...
...
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