Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
T
tl_estate
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
hujun
tl_estate
Commits
290366ea
Commit
290366ea
authored
Dec 17, 2018
by
zw
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
财务日报
parent
c3e87c3d
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
72 additions
and
7 deletions
+72
-7
DailyPaper.php
application/api_broker/controller/DailyPaper.php
+3
-3
DailyPaperService.php
application/api_broker/service/DailyPaperService.php
+6
-2
DailyPaper.php
application/index/controller/DailyPaper.php
+58
-0
ODaily.php
application/model/ODaily.php
+3
-0
route.php
application/route.php
+2
-2
No files found.
application/api_broker/controller/DailyPaper.php
View file @
290366ea
...
@@ -31,12 +31,12 @@ class DailyPaper extends Basic
...
@@ -31,12 +31,12 @@ class DailyPaper extends Basic
*/
*/
public
function
dailyDetail
(){
public
function
dailyDetail
(){
$params
=
$this
->
params
;
$params
=
$this
->
params
;
/*
$params = array(
$params
=
array
(
"store_id" => 73,//门店id
"store_id"
=>
73
0
,
//门店id
"is_store"
=>
0
,
//身份是否是店长,财务显示不一样 0店长 1财务
"is_store"
=>
0
,
//身份是否是店长,财务显示不一样 0店长 1财务
"daily_data"
=>
"2018-12-01"
"daily_data"
=>
"2018-12-01"
);
);
$this->agentId =
74;*/
$this
->
agentId
=
5775
;
if
(
!
isset
(
$params
[
"store_id"
])
||
!
isset
(
$params
[
"is_store"
])
||
!
isset
(
$params
[
"daily_data"
])){
if
(
!
isset
(
$params
[
"store_id"
])
||
!
isset
(
$params
[
"is_store"
])
||
!
isset
(
$params
[
"daily_data"
])){
return
$this
->
response
(
"101"
,
"请求参数错误"
);
return
$this
->
response
(
"101"
,
"请求参数错误"
);
}
}
...
...
application/api_broker/service/DailyPaperService.php
View file @
290366ea
...
@@ -222,8 +222,9 @@ class DailyPaperService
...
@@ -222,8 +222,9 @@ class DailyPaperService
);
);
//调整出账
//调整出账
$field_adjustment
=
"b.id,c.house_id,a.agent_id,a.income_time,b.type,a.receipt_number,a.create_time"
;
$field_adjustment
=
"b.id,c.house_id,a.agent_id,a.income_time,b.type,a.receipt_number,a.create_time"
;
$params_adjustment
[
"a.agent_id"
]
=
array
(
"in"
,
(
$ids
));
$params_adjustment
[
"a.agent_id"
]
=
array
(
"in"
,
(
$ids
));
$params_adjustment
[
"a.is_del"
]
=
0
;
$params_adjustment
[
"a.is_del"
]
=
0
;
$params_adjustment
[
"b.create_time"
]
=
array
(
"between"
,
array
(
$daily_data
,
$daily_data
.
" 23:59:59"
));
$info
[
"adjustment"
]
=
$this
->
getHouseAndAgentInfo
(
$info
[
"adjustment"
]
=
$this
->
getHouseAndAgentInfo
(
$payLogModel
->
selectAdjustmentList
(
$field_adjustment
,
$params_adjustment
)
$payLogModel
->
selectAdjustmentList
(
$field_adjustment
,
$params_adjustment
)
);
);
...
@@ -255,6 +256,9 @@ class DailyPaperService
...
@@ -255,6 +256,9 @@ class DailyPaperService
$house_arr
=
$this
->
houseInfo
(
$house_id_str
);
$house_arr
=
$this
->
houseInfo
(
$house_id_str
);
foreach
(
$data
as
$k
=>
$v
)
{
foreach
(
$data
as
$k
=>
$v
)
{
$data
[
$k
][
"agent_name"
]
=
""
;
$data
[
$k
][
"store_name"
]
=
""
;
$data
[
$k
][
"house_address"
]
=
""
;
foreach
(
$agent_arr
as
$value
)
{
foreach
(
$agent_arr
as
$value
)
{
if
(
$v
[
"agent_id"
]
==
$value
[
"id"
])
{
if
(
$v
[
"agent_id"
]
==
$value
[
"id"
])
{
$data
[
$k
][
"agent_name"
]
=
$value
[
"name"
];
$data
[
$k
][
"agent_name"
]
=
$value
[
"name"
];
...
...
application/index/controller/DailyPaper.php
0 → 100644
View file @
290366ea
<?php
namespace
app\index\controller
;
use
app\api_broker\extend\Basic
;
use
app\api_broker\service\DailyPaperService
;
use
think\Request
;
/**
* Created by PhpStorm.
* User : zw
* Date : 2018/12/17
* Time : 11:09 AM
* Intro:
*/
class
DailyPaper
extends
Basic
{
private
$service_
;
public
function
__construct
(
Request
$request
=
null
)
{
parent
::
__construct
(
$request
);
$this
->
service_
=
new
DailyPaperService
();
}
/**
* 财务日报
* @return \think\Response
* @throws \think\db\exception\DataNotFoundException
* @throws \think\db\exception\ModelNotFoundException
* @throws \think\exception\DbException
*/
public
function
dailyDetail
(){
$params
=
$this
->
params
;
/* $params = array(
"store_id" => 730,//门店id
"is_store" => 0,//身份是否是店长,财务显示不一样 0店长 1财务
"daily_data" => "2018-12-01"
);
$this->agentId = 5775;*/
if
(
!
isset
(
$params
[
"store_id"
])
||
!
isset
(
$params
[
"is_store"
])
||
!
isset
(
$params
[
"daily_data"
])){
return
$this
->
response
(
"101"
,
"请求参数错误"
);
}
$store_id
=
$params
[
"store_id"
];
$is_store
=
$params
[
"is_store"
];
$daily_data
=
$params
[
"daily_data"
];
$result
=
$this
->
service_
->
getDaily
(
$this
->
agentId
,
$store_id
,
$is_store
,
$daily_data
);
if
(
$result
[
"code"
]
==
101
){
return
$this
->
response
(
"101"
,
$result
[
"msg"
]);
}
else
{
return
$this
->
response
(
"200"
,
"success"
,
$result
[
"data"
]);
}
}
}
\ No newline at end of file
application/model/ODaily.php
View file @
290366ea
...
@@ -37,6 +37,9 @@ class ODaily extends BaseModel{
...
@@ -37,6 +37,9 @@ class ODaily extends BaseModel{
if
(
isset
(
$params
[
"agent_id"
])){
if
(
isset
(
$params
[
"agent_id"
])){
$where_
[
"agent_id"
]
=
$params
[
"agent_id"
];
$where_
[
"agent_id"
]
=
$params
[
"agent_id"
];
}
}
if
(
isset
(
$params
[
"daily_date"
])){
$where_
[
"daily_date"
]
=
$params
[
"daily_date"
];
}
$where_
[
"is_del"
]
=
0
;
$where_
[
"is_del"
]
=
0
;
return
$this
->
db_
return
$this
->
db_
->
field
(
$field
)
->
field
(
$field
)
...
...
application/route.php
View file @
290366ea
...
@@ -392,7 +392,7 @@ Route::group('index', [
...
@@ -392,7 +392,7 @@ Route::group('index', [
'getBlackListInfo'
=>
[
'index/broker/getBlackListInfo'
,
[
'method'
=>
'GET|POST'
]
],
//黑名单详情
'getBlackListInfo'
=>
[
'index/broker/getBlackListInfo'
,
[
'method'
=>
'GET|POST'
]
],
//黑名单详情
'delAgentsBlackListImg'
=>
[
'index/broker/delAgentsBlackListImg'
,
[
'method'
=>
'GET|POST'
]
],
//黑名单删除图片
'delAgentsBlackListImg'
=>
[
'index/broker/delAgentsBlackListImg'
,
[
'method'
=>
'GET|POST'
]
],
//黑名单删除图片
'dailyDetail'
=>
[
'index/DailyPaper/dailyDetail'
,
[
'method'
=>
'get|post'
]],
]);
]);
...
@@ -738,7 +738,7 @@ Route::group('broker', [
...
@@ -738,7 +738,7 @@ Route::group('broker', [
'getBeForNum'
=>
[
'api_broker/PayLog/getBeForNum'
,
[
'method'
=>
'get|post'
]],
'getBeForNum'
=>
[
'api_broker/PayLog/getBeForNum'
,
[
'method'
=>
'get|post'
]],
'adjustment'
=>
[
'api_broker/PayLog/adjustment'
,
[
'method'
=>
'get|post'
]],
'adjustment'
=>
[
'api_broker/PayLog/adjustment'
,
[
'method'
=>
'get|post'
]],
'dailyDetail'
=>
[
'api_broker/DailyPaper/dailyDetail'
,
[
'method'
=>
'get|post'
]],
]);
]);
...
...
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