Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
5
51business
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
方斌
51business
Commits
cf35a54d
Commit
cf35a54d
authored
Jun 13, 2019
by
Hsinli
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
addd
parent
e62be838
Pipeline
#8898
passed with stage
in 13 seconds
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
11 additions
and
1 deletion
+11
-1
search_history.js
app/controller/house/v2/search_history.js
+10
-1
house.js
app/router/house.js
+1
-0
No files found.
app/controller/house/v2/search_history.js
View file @
cf35a54d
...
...
@@ -5,7 +5,7 @@ const Controller = require('egg').Controller;
class
searchHistoryController
extends
Controller
{
/**
* 获取
预约列表
* 获取
搜索历史
*/
async
getSearchHistory
()
{
const
{
ctx
}
=
this
;
...
...
@@ -50,6 +50,15 @@ class searchHistoryController extends Controller {
ctx
.
success
(
ret
);
}
/**
* 获取热门问题搜索历史
*/
async
getHotQuestionSearchHistory
()
{
const
{
ctx
}
=
this
;
let
type
=
3
;
let
ret
=
await
ctx
.
service
.
house
.
v2
.
searchHistory
.
getSearchHistory
(
type
);
ctx
.
success
(
ret
);
}
}
...
...
app/router/house.js
View file @
cf35a54d
...
...
@@ -84,6 +84,7 @@ module.exports = app => {
//搜索历史
router
.
get
(
'/v2/search_history/:city_code'
,
'house.v2.searchHistory.getSearchHistory'
);
//搜索历史
router
.
put
(
'/v2/search_history/:type'
,
'house.v2.searchHistory.cleanSearchHistory'
);
//用户点击清除搜索记录
router
.
get
(
'/v2/hot_question/search_history'
,
'house.v2.searchHistory.getHotQuestionSearchHistory'
);
//热门问题搜索历史
//我的
router
.
get
(
'/v2/mine'
,
'house.v2.mine.getMineInfo'
);
//获取用户的头像昵称和关注等信息
...
...
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