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
bc9d4462
Commit
bc9d4462
authored
Mar 23, 2018
by
clone
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
我的成单bug
parent
75ff65cc
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
69 additions
and
10 deletions
+69
-10
OrderLog.php
application/api_broker/controller/OrderLog.php
+0
-0
Performance.php
application/api_broker/controller/Performance.php
+2
-2
Statement.php
application/api_broker/controller/Statement.php
+2
-2
Basic.php
application/api_broker/extend/Basic.php
+1
-1
AgentVerifyService.php
application/api_broker/service/AgentVerifyService.php
+53
-0
OrderLogService.php
application/api_broker/service/OrderLogService.php
+0
-0
OBargainModel.php
application/model/OBargainModel.php
+11
-5
No files found.
application/api_broker/controller/OrderLog.php
View file @
bc9d4462
This diff is collapsed.
Click to expand it.
application/api_broker/controller/Performance.php
View file @
bc9d4462
...
...
@@ -30,10 +30,10 @@ class Performance extends Basic{
*/
public
function
selectPerformanceByTime
(){
$params
=
$this
->
params
;
$params
=
array
(
/*
$params = array(
"agent_id" => 1,
"type" => 1, //1表示个人业绩排行 2门店 3区域
);
);
*/
if
(
!
isset
(
$params
[
"agent_id"
])
||
!
isset
(
$params
[
"type"
])){
return
$this
->
response
(
"101"
,
"请求参数错误"
);
}
...
...
application/api_broker/controller/Statement.php
View file @
bc9d4462
...
...
@@ -62,14 +62,14 @@ class Statement extends Basic
}
$img_title
=
""
;
$img
=
""
;
$img
=
""
;
//单图
$base64_image_content
=
$this
->
params
[
"img"
];
if
(
preg_match
(
'/^(data:\s*image\/(\w+);base64,)/'
,
$base64_image_content
,
$array
))
{
$img_title
=
$array
[
2
];
//jpeg
$img
=
base64_decode
(
str_replace
(
$array
[
1
],
''
,
$base64_image_content
));
//返回文件流
$img
=
base64_decode
(
str_replace
(
$array
[
1
],
''
,
$base64_image_content
));
//返回文件流
}
$tmp_file
=
time
();
...
...
application/api_broker/extend/Basic.php
View file @
bc9d4462
...
...
@@ -80,7 +80,7 @@ class Basic extends Controller
$requestPath
=
$this
->
request
->
routeInfo
()[
"rule"
][
0
]
.
"/"
.
$this
->
request
->
routeInfo
()[
"rule"
][
1
];
//过滤掉不需要验证token的接口
if
(
!
in_array
(
trim
(
$requestPath
),
$this
->
filterVerify
))
{
$this
->
tokenVerify
();
//
$this->tokenVerify();
}
unset
(
$this
->
params
[
"AuthToken"
]);
}
...
...
application/api_broker/service/AgentVerifyService.php
0 → 100644
View file @
bc9d4462
<?php
namespace
app\api_broker\service
;
use
app\model\AAgents
;
/**
* Created by PhpStorm.
* User : zw
* Date : 2018/3/23
* Time : 14:11
* Intro:
*/
class
AgentVerifyService
{
private
$agentModel
;
public
function
__construct
()
{
$this
->
agentModel
=
new
AAgents
();
}
public
function
getAgentsByAgentId
(
$agent_id
)
{
$params
[
"id"
]
=
$agent_id
;
$result
=
$this
->
agentModel
->
searchAgentsByKeyword
(
"id,store_id,district_id,level"
,
$params
);
if
(
count
(
$result
)
>
0
)
{
$arr_list
=
[];
switch
(
$result
[
0
][
"level"
])
{
case
10
:
return
$result
[
0
][
"id"
];
case
20
:
$arr_list
=
$this
->
agentModel
->
searchAgentsByKeyword
(
"id"
,
[
"store_id"
=>
$result
[
0
][
"store_id"
]
]);
break
;
case
30
:
case
40
:
$arr_list
=
$this
->
agentModel
->
searchAgentsByKeyword
(
"id"
,
[
"district_id"
=>
$result
[
0
][
"district_id"
]
]);
break
;
}
$ids
=
""
;
if
(
count
(
$arr_list
)
>
0
){
foreach
(
$arr_list
as
$item
)
{
$ids
.=
$item
[
"id"
]
.
","
;
}
}
$ids
=
rtrim
(
$ids
,
","
);
return
$ids
;
}
return
null
;
}
}
\ No newline at end of file
application/api_broker/service/OrderLogService.php
View file @
bc9d4462
This diff is collapsed.
Click to expand it.
application/model/OBargainModel.php
View file @
bc9d4462
...
...
@@ -114,16 +114,20 @@ class OBargainModel extends Model
*/
public
function
selectBargainList
(
$filed
,
$params
,
$pageNo
,
$pageSize
){
$where_
=
[];
if
(
isset
(
$params
[
"submit_agent_id"
]))
{
$where_
[
"a.submit_agent_id"
]
=
$params
[
"submit_agent_id"
];
}
if
(
isset
(
$params
[
"status"
]))
{
$where_
[
"a.status"
]
=
$params
[
"status"
];
}
$where_
[
"a.father_id"
]
=
0
;
if
(
isset
(
$params
[
"ids"
]))
{
$where_
[
"a.agent_id"
]
=
array
(
"in"
,
$params
[
"ids"
]);
}
if
(
isset
(
$params
[
"keyword"
]))
{
$where_
[
"b.user_phone|b.user_name|d.internal_address"
]
=
array
(
"like"
,
"%"
.
$params
[
"keyword"
]
.
"%"
)
;
}
$where_
[
"b.status"
]
=
0
;
$where_
[
"c.is_del"
]
=
0
;
return
$this
->
db_
$result
=
$this
->
db_
->
field
(
$filed
)
->
alias
(
"a"
)
->
join
(
"o_report b"
,
"a.report_id = b.id"
,
"left"
)
...
...
@@ -134,6 +138,8 @@ class OBargainModel extends Model
->
limit
(
$pageSize
)
->
page
(
$pageNo
)
->
select
();
echo
$this
->
db_
->
getLastSql
();
return
$result
;
}
/**
...
...
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