Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
W
wxh_internal_api
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
杨培培
wxh_internal_api
Commits
75dda2f2
Commit
75dda2f2
authored
May 29, 2019
by
谈海涛
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
标签分类优化
parent
9f0f3652
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
22 additions
and
19 deletions
+22
-19
Label.php
src/ucenter/Label.php
+22
-19
No files found.
src/ucenter/Label.php
View file @
75dda2f2
...
@@ -15,35 +15,38 @@ use internalApi\base\Client;
...
@@ -15,35 +15,38 @@ use internalApi\base\Client;
class
Label
extends
Client
class
Label
extends
Client
{
{
//类型 1=>认证 2=>品类 3=>品牌 4=>热门事件 5=>现象 6=>故障点 7=>专题
const
TYPE_AUTH
=
1
;
// 认证
const
TYPE_CATEGORY
=
2
;
// 品类
const
TYPE_BRAND
=
3
;
// 品牌
const
TYPE_HOT_EVENTS
=
4
;
// 热门事件
const
TYPE_PHENOMENON
=
5
;
// 现象
const
TYPE_FAULT
=
6
;
// 故障点
const
TYPE_SPECIAL_TOPIC
=
7
;
// 专题
//类型 1=>认证 2=>品类 3=>品牌
/**
const
TYPE_AUTH
=
1
;
//认证
* @param array/int $type 1=>认证 2=>品类 3=>品牌
const
TYPE_CATEGORY
=
2
;
//品类
*
const
TYPE_BRAND
=
3
;
//品牌
* @return mixed
* @throws \internalApi\base\ApiException
/**
* @throws \internalApi\base\ClientException
* @param array/int $type 1=>认证 2=>品类 3=>品牌
*/
* @return mixed
public
static
function
getLabels
(
$type
=
null
){
* @throws \internalApi\base\ApiException
return
self
::
call
(
'label.getLabels'
,
compact
(
'type'
));
* @throws \internalApi\base\ClientException
}
*/
public
static
function
getLabels
(
$type
=
null
)
{
return
self
::
call
(
'label.getLabels'
,
compact
(
'type'
));
}
/**
/**
* 标签分类
* 标签分类
*
* @param array $labels 标签
* @param array $labels 标签
* @param array $types //类型 1=>认证 2=>品类 3=>品牌 4=>热门事件 5=>现象 6=>故障点 7=>专题
* @param array $types
//类型 1=>认证 2=>品类 3=>品牌 4=>热门事件 5=>现象 6=>故障点 7=>专题
*
*
* @return array
* @return array
* @throws \internalApi\base\ApiException
* @throws \internalApi\base\ApiException
* @throws \internalApi\base\ClientException
* @throws \internalApi\base\ClientException
*/
*/
public
static
function
getListByLabels
(
$labels
,
$types
=
[
2
,
3
,
5
,
6
])
public
static
function
getListByLabels
(
$labels
,
$types
=
[
self
::
TYPE_CATEGORY
,
self
::
TYPE_BRAND
,
self
::
TYPE_PHENOMENON
,
self
::
TYPE_FAULT
]){
{
return
self
::
call
(
'label.getListByLabels'
,
compact
(
'labels'
,
'types'
));
return
self
::
call
(
'label.getListByLabels'
,
compact
(
'labels'
,
'types'
));
}
}
}
}
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