|
|
# 查询资讯分类资源
|
|
|
|
|
|
> 接口名: `/guang/api/*/category/get
|
|
|
> 接口名: `/guang/article/sort/getList
|
|
|
|
|
|
### 方法
|
|
|
|
|
|
> GET JSONRAW
|
|
|
> GET
|
|
|
|
|
|
### 入参
|
|
|
### 无参
|
|
|
|
|
|
-------------------------
|
|
|
|属性名称|类型|例子|说明|是否必填|长度限制|
|
|
|
|--------|----|----|---|----|--------|
|
|
|
|client_type|string|iphone|客户端类型|否|100
|
|
|
|gender|string|1,3|生成码|否|11
|
|
|
|
|
|
|
|
|
### 对应SQL的操作库表
|
|
|
|
|
|
```xml
|
|
|
select
|
|
|
<include refid="Base_Column_List" />
|
|
|
<select id="selectAllSortList" resultMap="BaseResultMap">
|
|
|
select
|
|
|
<include refid="Base_Column_List" />
|
|
|
from article_sort
|
|
|
where 1=1
|
|
|
<if test="id != null">
|
|
|
and id = #{id,jdbcType=INTEGER}
|
|
|
</if>
|
|
|
<if test="parentId != null">
|
|
|
and parent_id = #{parentId,jdbcType=INTEGER}
|
|
|
</if>
|
|
|
<if test="name != null">
|
|
|
and name = #{name,jdbcType=VARCHAR}
|
|
|
</if>
|
|
|
<if test="status != null and status != ''">
|
|
|
and status = #{status,jdbcType=TINYINT}
|
|
|
</if>
|
|
|
order by order_by desc
|
|
|
order by order_by DESC
|
|
|
</select>
|
|
|
```
|
|
|
|
|
|
### 错误编码
|
...
|
...
|
@@ -51,27 +35,33 @@ |
|
|
"code": 200,
|
|
|
"data": [
|
|
|
{
|
|
|
"id": "0",
|
|
|
"name":"推荐"
|
|
|
},
|
|
|
{
|
|
|
"id": "1",
|
|
|
"name":"话题"
|
|
|
"orderBy": "1",
|
|
|
"status":"1"
|
|
|
"name":"推荐"
|
|
|
},
|
|
|
{
|
|
|
"id": "2",
|
|
|
"orderBy": "2",
|
|
|
"status":"1"
|
|
|
"name":"搭配"
|
|
|
},
|
|
|
{
|
|
|
"id": "3",
|
|
|
"orderBy": "3",
|
|
|
"status":"1"
|
|
|
"name":"潮人"
|
|
|
},
|
|
|
{
|
|
|
"id": "4",
|
|
|
"orderBy": "4",
|
|
|
"status":"1"
|
|
|
"name":"潮品"
|
|
|
},
|
|
|
{
|
|
|
"id": "5",
|
|
|
"orderBy": "5",
|
|
|
"status":"1"
|
|
|
"name":"专题"
|
|
|
}
|
|
|
],
|
...
|
...
|
|