发表于: 2017-06-19 22:41:52

5 1149


一、今天完成的事情:、

重新思考定义接口:(红色为改动)

 

首页

Banner图是后端定义,跳转指定链接

点击找职位,跳转找职位页面

点击找精英,跳转到找精英界面

点击最新职位的更多跳转到最新职位界面

点击职位跳转职位详情

 

首页:

GET    /a/home

最新职位接口GET /a/profession/new

 

最新职位推荐按照更新时间排序

select id,name,c_name c_id from profession order by update_at DESC

找职位  GET  /a/work

找精英  GET  /a/elite

 

最新职位详情页 GET /a/profession/new

排序按照最新发布时间排序

select id from profession order by update_at DESC

搜索条件

GET    /a/profession/search

动态sql语句,查询按发布时间倒序排序

select  id  from profession where {} = {value} order by update_at DESC

 

推荐职位

 /a/profession/new

按照是否推荐,发布时间倒序排序

select  id  from profession order by isRecommand,update_at DESC

搜索

  Get /a/profession/search 按照是否推荐排序

select  id  from profession where {} = {value} order by isRecommand,update_at DESC

 

找职位页面GET /a/work

 

找职位职位列表接口

/a/work/{type}/{subtype}

 

 

 

搜索功能

GET    /a/profession/search

动态sql语句,查询按发布时间倒序排序

select  id  from profession where isRecommand=1 order by update_at DESC

 

点击最新职位切换到最新职位,排序按照最新职位定义接口排序

/a/profession/new Get

 

 

 

搜索公司

GET  /a/company/list/search

 

Select id from company order by update_at desc

 

公司详情页

公司详情页  

                     接口  GET  /a/company/{id}  

                 select  id  from company where id={id}

                     接口        GET a/company/label/{id}

                     select  id  from companyLabel where id={id}

二、遇到的问题:标签表是否需要新建呢?前端传值直接村在字段行不行,我觉得可行又不可行,问题很大。

三、明天计划的事情:无

四、收获:写接口很多接口可以重复使用,这需要自己定义,和参考很多规范。


返回列表 返回列表
评论

    分享到