新增协议:推荐列表
This commit is contained in:
@@ -29,6 +29,11 @@ export class GirlService implements IGirlService {
|
||||
return this.impl.reqDailyRecommend(req);
|
||||
}
|
||||
|
||||
// 推荐列表
|
||||
public async reqRecommendList(req: proto.cs.ICSRecommendReq): Promise<ApiResponse<proto.cs.ICSRecommendRes>> {
|
||||
return this.impl.reqRecommendList(req);
|
||||
}
|
||||
|
||||
// 获取技师列表
|
||||
public async reqGetGirlList(req: proto.cs.ICSGetGirlListReq): Promise<ApiResponse<proto.cs.ICSGetGirlListRes>> {
|
||||
return this.impl.reqGetGirlList(req);
|
||||
|
||||
@@ -18,6 +18,17 @@ export class HttpGirlService implements IGirlService {
|
||||
return this.api.call(epData, req);
|
||||
}
|
||||
|
||||
// 推荐列表
|
||||
async reqRecommendList(req: proto.cs.ICSRecommendReq): Promise<ApiResponse<proto.cs.ICSRecommendRes>> {
|
||||
let epData: Endpoint<proto.cs.ICSRecommendReq, proto.cs.ICSRecommendRes> = {
|
||||
path: "api/logic/recommend",
|
||||
method: "POST",
|
||||
codec: "json",
|
||||
needsAuth: true
|
||||
};
|
||||
return this.api.call(epData, req);
|
||||
}
|
||||
|
||||
// 获取技师列表
|
||||
async reqGetGirlList(req: proto.cs.ICSGetGirlListReq): Promise<ApiResponse<proto.cs.ICSGetGirlListRes>> {
|
||||
let epData: Endpoint<proto.cs.ICSGetGirlListReq, proto.cs.ICSGetGirlListRes> = {
|
||||
|
||||
@@ -4,6 +4,8 @@ import proto from "db://assets/Scripts/proto/proto.pb.js";
|
||||
export interface IGirlService {
|
||||
// 每日推荐
|
||||
reqDailyRecommend(req: proto.cs.ICSDailyRecommendReq): Promise<ApiResponse<proto.cs.ICSDailyRecommendRes>>;
|
||||
// 推荐列表
|
||||
reqRecommendList(req: proto.cs.ICSRecommendReq): Promise<ApiResponse<proto.cs.ICSRecommendRes>>;
|
||||
// 获取技师列表
|
||||
reqGetGirlList(req: proto.cs.ICSGetGirlListReq): Promise<ApiResponse<proto.cs.ICSGetGirlListRes>>;
|
||||
// 获取技师详细信息
|
||||
|
||||
@@ -102,6 +102,20 @@ export class MockGirlService implements IGirlService {
|
||||
return this.ok(res);
|
||||
}
|
||||
|
||||
// 推荐列表
|
||||
async reqRecommendList(req: proto.cs.ICSRecommendReq): Promise<ApiResponse<proto.cs.ICSRecommendRes>> {
|
||||
// 延时
|
||||
await this.delay(180);
|
||||
|
||||
// TODO
|
||||
|
||||
// 返回数据
|
||||
const res: proto.cs.ICSRecommendRes = {
|
||||
girls: [],
|
||||
};
|
||||
return this.ok(res);
|
||||
}
|
||||
|
||||
// 获取技师列表
|
||||
async reqGetGirlList(req: proto.cs.ICSGetGirlListReq): Promise<ApiResponse<proto.cs.ICSGetGirlListRes>> {
|
||||
// 延时
|
||||
@@ -304,6 +318,9 @@ export class MockGirlService implements IGirlService {
|
||||
|
||||
// 获取可聊天的技师数据
|
||||
async reqCanChatGirlData(req: proto.cs.ICSGetLastChatListReq): Promise<ApiResponse<proto.cs.ICSGetLastChatListRes>> {
|
||||
// 延时
|
||||
await this.delay(180);
|
||||
|
||||
// TODO
|
||||
|
||||
// 返回数据
|
||||
@@ -326,6 +343,9 @@ export class MockGirlService implements IGirlService {
|
||||
|
||||
// 查看图片或者视频上报,用于排行榜
|
||||
async reqViewGirl(req: proto.cs.ICSViewGirlReq): Promise<ApiResponse<proto.cs.ICSViewGirlRes>> {
|
||||
// 延时
|
||||
await this.delay(180);
|
||||
|
||||
// TODO
|
||||
|
||||
// 返回数据
|
||||
@@ -337,6 +357,9 @@ export class MockGirlService implements IGirlService {
|
||||
|
||||
// 收藏技师
|
||||
async reqBookmarkGirl(req: proto.cs.ICSBookmarkReq): Promise<ApiResponse<proto.cs.ICSBookmarkRes>> {
|
||||
// 延时
|
||||
await this.delay(180);
|
||||
|
||||
// TODO
|
||||
|
||||
// 返回数据
|
||||
@@ -348,6 +371,9 @@ export class MockGirlService implements IGirlService {
|
||||
|
||||
// 获取收藏列表
|
||||
async reqBookmarkGirlList(req: proto.cs.ICSGetBookmarkReq): Promise<ApiResponse<proto.cs.ICSGetBookmarkRes>> {
|
||||
// 延时
|
||||
await this.delay(180);
|
||||
|
||||
// TODO
|
||||
|
||||
// 返回数据
|
||||
|
||||
Reference in New Issue
Block a user