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
f0d80c7f
Commit
f0d80c7f
authored
Mar 01, 2018
by
zfc
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
标签列表接口
parent
8c84d9ba
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
50 additions
and
5 deletions
+50
-5
Client.php
application/api_broker/controller/Client.php
+25
-0
Label.php
application/index/controller/Label.php
+12
-4
Basic.php
application/index/extend/Basic.php
+0
-1
u_label_index.html
application/index/view/label/u_label_index.html
+11
-0
route.php
application/route.php
+2
-0
No files found.
application/api_broker/controller/Client.php
View file @
f0d80c7f
...
@@ -4,6 +4,7 @@ namespace app\api_broker\controller;
...
@@ -4,6 +4,7 @@ namespace app\api_broker\controller;
use
app\api_broker\extend\Basic
;
use
app\api_broker\extend\Basic
;
use
app\model\Agents
;
use
app\model\Agents
;
use
app\model\ULabels
;
use
app\model\Users
;
use
app\model\Users
;
use
app\model\UPhoneFollowPp
;
use
app\model\UPhoneFollowPp
;
...
@@ -197,4 +198,28 @@ class Client extends Basic
...
@@ -197,4 +198,28 @@ class Client extends Basic
$data
[
'page'
]
=
$pageNo
;
$data
[
'page'
]
=
$pageNo
;
return
$this
->
response
(
200
,
'成功'
,
$data
);
return
$this
->
response
(
200
,
'成功'
,
$data
);
}
}
/**
* 客户标签
* @return \think\Response
* @throws \think\db\exception\DataNotFoundException
* @throws \think\db\exception\ModelNotFoundException
* @throws \think\exception\DbException
*/
public
function
getULabelsListApp
()
{
$result
[
'code'
]
=
200
;
$result
[
'msg'
]
=
''
;
$pageNo
=
empty
(
$this
->
params
[
'pageNo'
])
?
1
:
$this
->
params
[
'pageNo'
];
$pageSize
=
empty
(
$this
->
params
[
'pageSize'
])
?
10
:
$this
->
params
[
'pageSize'
];
$labels
=
new
ULabels
();
$field
=
'id,name,create_time'
;
$where
[
'type'
]
=
1
;
$result
[
'data'
][
'list'
]
=
$labels
->
getList
(
$pageNo
,
$pageSize
,
'id DESC'
,
$field
,
$where
);
$result
[
'data'
][
'total'
]
=
$labels
->
getTotal
(
$where
);
return
$this
->
response
(
$result
[
'code'
],
$result
[
'msg'
],
$result
[
'data'
]);
}
}
}
application/index/controller/Label.php
View file @
f0d80c7f
...
@@ -96,10 +96,13 @@ class Label extends Basic
...
@@ -96,10 +96,13 @@ class Label extends Basic
*/
*/
public
function
updateULabel
(){
public
function
updateULabel
(){
$group_id
=
$this
->
request
->
param
(
'id'
);
$group_id
=
$this
->
request
->
param
(
'id'
);
$table
=
New
ULabels
;
$table
=
New
ULabels
;
if
(
$this
->
request
->
isPost
())
{
if
(
$this
->
request
->
isPost
())
{
$data
=
input
(
'post.'
);
$data
=
input
(
'post.'
);
$data
[
'operation_id'
]
=
Session
::
get
(
"userinfo.id"
);
//操作人id
if
(
$table
->
repetition
(
'name'
,
$data
[
'name'
])
&&
empty
(
$data
[
'id'
])){
if
(
$table
->
repetition
(
'name'
,
$data
[
'name'
])
&&
empty
(
$data
[
'id'
])){
return
$this
->
response
(
100
,
'url存在重复值'
);
return
$this
->
response
(
100
,
'url存在重复值'
);
}
}
...
@@ -113,7 +116,6 @@ class Label extends Basic
...
@@ -113,7 +116,6 @@ class Label extends Basic
$id
=
$data
[
'id'
];
$id
=
$data
[
'id'
];
}
}
//新增或者编辑数据
//新增或者编辑数据
//prt($data)
if
(
$table
->
editData
(
$data
,
$id
))
{
if
(
$table
->
editData
(
$data
,
$id
))
{
return
$this
->
response
(
200
,
'成功'
);
return
$this
->
response
(
200
,
'成功'
);
}
else
{
}
else
{
...
@@ -140,15 +142,20 @@ class Label extends Basic
...
@@ -140,15 +142,20 @@ class Label extends Basic
public
function
getULabelsList
()
{
public
function
getULabelsList
()
{
$result
[
'code'
]
=
200
;
$result
[
'code'
]
=
200
;
$result
[
'msg'
]
=
''
;
$result
[
'msg'
]
=
''
;
//获取当前模块可操作按钮start********************************
$userRule
=
Session
::
get
(
'userRule'
);
$result
[
'data'
][
'cz'
]
=
$userRule
[
'cz'
];
//获取当前模块可操作按钮end**********************************
$pageNo
=
empty
(
$this
->
params
[
'pageNo'
])
?
1
:
$this
->
params
[
'pageNo'
];
$pageNo
=
empty
(
$this
->
params
[
'pageNo'
])
?
1
:
$this
->
params
[
'pageNo'
];
$pageSize
=
empty
(
$this
->
params
[
'pageSize'
])
?
1
0
:
$this
->
params
[
'pageSize'
];
$pageSize
=
empty
(
$this
->
params
[
'pageSize'
])
?
1
5
:
$this
->
params
[
'pageSize'
];
$labels
=
new
GLabels
()
;
$labels
=
New
ULabels
;
$field
=
'id,name,create_time'
;
$field
=
'id,name,create_time'
;
$where
[
'type'
]
=
0
;
$where
[
'type'
]
=
1
;
$result
[
'data'
][
'list'
]
=
$labels
->
getList
(
$pageNo
,
$pageSize
,
'id DESC'
,
$field
,
$where
);
$result
[
'data'
][
'list'
]
=
$labels
->
getList
(
$pageNo
,
$pageSize
,
'id DESC'
,
$field
,
$where
);
$result
[
'data'
][
'total'
]
=
$labels
->
getTotal
(
$where
);
$result
[
'data'
][
'total'
]
=
$labels
->
getTotal
(
$where
);
return
$this
->
response
(
$result
[
'code'
],
$result
[
'msg'
],
$result
[
'data'
]);
return
$this
->
response
(
$result
[
'code'
],
$result
[
'msg'
],
$result
[
'data'
]);
}
}
}
}
\ No newline at end of file
application/index/extend/Basic.php
View file @
f0d80c7f
...
@@ -76,7 +76,6 @@ class Basic extends Controller
...
@@ -76,7 +76,6 @@ class Basic extends Controller
public
function
userAuth
(
$requestPath
){
public
function
userAuth
(
$requestPath
){
$session
=
Session
::
get
(
"userinfo.nav"
);
$session
=
Session
::
get
(
"userinfo.nav"
);
//prt($session);
$rule
=
0
;
$rule
=
0
;
if
(
$session
!=
NULL
)
{
if
(
$session
!=
NULL
)
{
//判断当前控制器用户是否拥有进入权限
//判断当前控制器用户是否拥有进入权限
...
...
application/index/view/label/u_label_index.html
0 → 100644
View file @
f0d80c7f
<!DOCTYPE html>
<html
lang=
"en"
>
<head>
<meta
charset=
"UTF-8"
>
<title>
Title
</title>
</head>
<body>
</body>
</html>
\ No newline at end of file
application/route.php
View file @
f0d80c7f
...
@@ -222,6 +222,8 @@ Route::group('api', [
...
@@ -222,6 +222,8 @@ Route::group('api', [
'agentUserTb'
=>
[
'api_broker/Client/agentUserTb'
,
[
'method'
=>
'get'
]
],
//客户列表
'agentUserTb'
=>
[
'api_broker/Client/agentUserTb'
,
[
'method'
=>
'get'
]
],
//客户列表
'agentUserFollow'
=>
[
'api_broker/Client/agentUserFollow'
,
[
'method'
=>
'get'
]
],
//客户列表
'agentUserFollow'
=>
[
'api_broker/Client/agentUserFollow'
,
[
'method'
=>
'get'
]
],
//客户列表
'agentSearch'
=>
[
'api_broker/Client/agentSearch'
,
[
'method'
=>
'get'
]
],
//经纪人搜索
'agentSearch'
=>
[
'api_broker/Client/agentSearch'
,
[
'method'
=>
'get'
]
],
//经纪人搜索
'getULabelsListApp'
=>
[
'api_broker/Client/getULabelsListApp'
,
[
'method'
=>
'get'
]
],
//客户标签
]);
]);
Route
::
group
(
'task'
,[
Route
::
group
(
'task'
,[
...
...
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