Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
黄成意
/
yunxin
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
156e103c
authored
Mar 07, 2019
by
PRY5YKGJ82EZEPX\Administrator
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
更新云芯对接
parent
62ff82f8
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
11 additions
and
11 deletions
app/Http/Controllers/ApiController.php
app/Model/Server/ServerFinanceModel.php
app/Http/Controllers/ApiController.php
View file @
156e103c
...
...
@@ -62,8 +62,10 @@ class ApiController extends Controller
(
new
ServerFinanceModel
(
$request
->
appid
,
$request
->
key
))
->
accountCheckingDetail
(
$request
->
input
());
}
//退货列表明细
private
function
ApiAbnormalDetail
(
$request
,
$id
){
(
new
ServerFinanceModel
(
$request
->
appid
,
$request
->
key
))
->
accountChangeChecking
(
$request
->
input
());
private
function
ApiAccountChangeChecking
(
$request
,
$id
){
$input
=
$request
->
input
();
$input
[
'checking_name'
]
=
$request
->
supplier_name
;
(
new
ServerFinanceModel
(
$request
->
appid
,
$request
->
key
))
->
accountChangeChecking
(
$input
);
}
...
...
app/Model/Server/ServerFinanceModel.php
View file @
156e103c
...
...
@@ -8,13 +8,13 @@ use DB;
//跟财务接口通讯模型
class
ServerFinanceModel
{
private
$
pur
_url
;
//采购网址
private
$
finance
_url
;
//采购网址
private
$appid
;
//APPID
private
$key
;
//密钥
const
IS_DEBUG
=
0
;
//是否调试
public
function
__construct
(
$appid
,
$key
)
{
$this
->
pur_url
=
Config
(
'website.URL_PUR
'
);
$this
->
finance_url
=
Config
(
'website.URL_FINANCE
'
);
// $this->financeUrl = 'http://szfinance.ichunt.net';
$this
->
appid
=
$appid
;
$this
->
key
=
$key
;
...
...
@@ -22,7 +22,7 @@ class ServerFinanceModel
//发送请求
public
function
push
(
$url
,
$data
,
$type
=
1
){
$data
=
ExcessEncryption
(
$data
,
$this
->
appid
,
$this
->
key
);
$urls
=
$this
->
pur
_url
.
$url
;
$urls
=
$this
->
finance
_url
.
$url
;
$res
=
(
curl
(
$urls
,
$data
));
if
(
self
::
IS_DEBUG
){
...
...
@@ -42,18 +42,15 @@ class ServerFinanceModel
}
//获取对账单列表
public
function
accountCheckingList
(
$input
){
$url
=
$this
->
financeUrl
.
'/webapi/accountCheckingList'
;
return
$this
->
push
(
$url
,
$input
);
return
$this
->
push
(
'/thrid/accountCheckingList'
,
$input
);
}
//获取对账单列表明细
public
function
accountCheckingDetail
(
$input
){
$url
=
$this
->
financeUrl
.
'/webapi/accountCheckingDetail'
;
return
$this
->
push
(
$url
,
$input
);
return
$this
->
push
(
'/thrid/accountCheckingDetail'
,
$input
);
}
//对账确定
public
function
accountChangeChecking
(
$input
){
$url
=
$this
->
financeUrl
.
'/webapi/accountChangeChecking'
;
return
$this
->
push
(
$url
,
$input
);
return
$this
->
push
(
'/thrid/accountChangeChecking'
,
$input
);
}
}
\ 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