Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
M
my-yaf-project
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
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
chenchuanwen
my-yaf-project
Commits
3382e583
Commit
3382e583
authored
Dec 27, 2018
by
chenchuanwen
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master_dev' of git.shenbd.com:qm-develop/shenbd into ccw
parents
93b60724
aaab1d04
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
10 additions
and
7 deletions
+10
-7
Pay.php
application/library/Payment/Pay.php
+3
-4
TencentPay.php
application/library/Payment/TencentPay.php
+0
-1
WxLitePay.php
application/library/Payment/WxLitePay.php
+7
-2
No files found.
application/library/Payment/Pay.php
View file @
3382e583
...
...
@@ -45,11 +45,10 @@ class Pay {
$orderInfo
[
'openid'
]
=
$authInfo
[
'openid'
];
$wxLitePay
=
WxLitePay
::
getInstance
();
$return
=
$wxLitePay
->
doPay
(
$orderInfo
);
$prepayId
=
$
wxLitePay
->
getPrepayId
()
;
file_put_contents
(
\Our\Common
::
getConfig
(
'out.config'
)
.
\Our\PathConst
::
ktestTime
,
$prepayId
.
'|'
.
$orderInfo
[
'paySn'
]
);
$prepayId
=
$
return
[
'prepay_id'
]
;
unset
(
$return
[
'prepay_id'
]);
// \Our\Log::getInstance()->write($prepayId,'/data/log/apptest'
);
if
(
$prepayId
)
{
$dbName
=
\Our\DbNameConst
::
masterDBConnectName
;
\DAO\Order\OrderModel
::
getInstance
(
$dbName
)
->
update
(
array
(
'pay_sn'
=>
$orderInfo
[
'paySn'
]),
array
(
'prepay_id'
=>
$prepayId
));
}
...
...
application/library/Payment/TencentPay.php
View file @
3382e583
...
...
@@ -104,7 +104,6 @@ class TencentPay {
{
$this
->
postXml
();
$this
->
result
=
$this
->
xmlToArray
(
$this
->
response
);
\Our\Log
::
getInstance
()
->
write
(
json_encode
(
$this
->
result
),
'/data/log/apptest'
);
$prepay_id
=
isset
(
$this
->
result
[
"prepay_id"
])
?
$this
->
result
[
"prepay_id"
]
:
\Our\ApiConst
::
zero
;
return
$prepay_id
;
}
...
...
application/library/Payment/WxLitePay.php
View file @
3382e583
...
...
@@ -35,9 +35,12 @@ class WxLitePay extends \Payment\TencentPay{
}
//$this->setRequestParams($orderInfo);
$wxAppParameters
=
$this
->
getParameters
();
$prepayId
=
$wxAppParameters
[
'prepay_id'
];
unset
(
$wxAppParameters
[
'prepay_id'
]);
$returnData
=
array
(
'credential'
=>
array
(
\Our\NameConst
::
wxLiteChannel
=>
$wxAppParameters
),
'app_id'
=>
$this
->
appid
'app_id'
=>
$this
->
appid
,
'prepay_id'
=>
$prepayId
);
return
$returnData
;
}
...
...
@@ -50,6 +53,8 @@ class WxLitePay extends \Payment\TencentPay{
$wxApiObj
[
'package'
]
=
'prepay_id='
.
$this
->
prepay_id
;
$wxApiObj
[
'signType'
]
=
'MD5'
;
$wxApiObj
[
"paySign"
]
=
$this
->
getSign
(
$wxApiObj
);
$wxApiObj
[
"prepay_id"
]
=
$this
->
prepay_id
;
return
$wxApiObj
;
}
...
...
@@ -143,4 +148,4 @@ class WxLitePay extends \Payment\TencentPay{
return
self
::
$_instance
;
}
}
\ No newline at end of file
}
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