- 将GetRecords接口替换为GetCalendar接口获取日历数据 - 重构首页日历数据显示逻辑,支持年月维度的数据获取 - 优化打卡记录流程,合并选酒和记量步骤为单一添加酒水步骤 - 移除登录页面的游客模式选项,简化首次启动逻辑 - 调整引导页逻辑,移除登录跳转改为直接进入首页 - 优化记录页面UI布局,添加状态栏安全距离适配 - 新增酒水列表管理功能,支持添加和删除已选酒水 - 更新依赖包HaveADrink至v1.0.3版本,同步API变更
2762 lines
61 KiB
TypeScript
2762 lines
61 KiB
TypeScript
/*
|
||
* 喝酒了么 - 后端接口 API
|
||
* 小程序:喝酒了么(uni-app 微信小程序)
|
||
* 基础URL: /api/v1
|
||
*
|
||
* 主要功能模块:
|
||
* 1. 用户模块 - 微信登录、用户信息管理
|
||
* 2. 打卡记录模块 - 饮酒记录创建、查询、日历数据
|
||
* 3. 照片上传模块 - 单张/批量照片上传
|
||
* 4. 统计模块 - 用户统计、月度统计、酒类分布
|
||
* 5. 成就模块 - 成就列表和进度
|
||
* 6. 社交模块 - 朋友圈动态、点赞
|
||
*/
|
||
|
||
export declare interface option {
|
||
value: number | string;
|
||
text: string;
|
||
}
|
||
|
||
/**
|
||
* 枚举类型基类
|
||
*/
|
||
export declare class Enum {
|
||
constructor(value: number|string);
|
||
toString(): number|string;
|
||
toJSON(): number|string;
|
||
valueOf(): number|string;
|
||
}
|
||
|
||
/**
|
||
* 成就条件类型
|
||
*/
|
||
export declare class AchievementConditionType extends Enum {
|
||
/**
|
||
* 总记录数
|
||
*/
|
||
static TotalRecords: AchievementConditionType;
|
||
/**
|
||
* 累计标准杯
|
||
*/
|
||
static TotalStandardCups: AchievementConditionType;
|
||
/**
|
||
* 连续打卡天数
|
||
*/
|
||
static StreakDays: AchievementConditionType;
|
||
/**
|
||
* 某酒类打卡次数
|
||
*/
|
||
static CategoryRecords: AchievementConditionType;
|
||
/**
|
||
* 尝试酒类品种数
|
||
*/
|
||
static CategoryVariety: AchievementConditionType;
|
||
|
||
static entries(): Array<option>;
|
||
static getLabel(v: number|string): string;
|
||
}
|
||
|
||
/**
|
||
* 酒类分类
|
||
*/
|
||
export declare class Category extends Enum {
|
||
/**
|
||
* 白酒
|
||
*/
|
||
static Baijiu: Category;
|
||
/**
|
||
* 啤酒
|
||
*/
|
||
static Beer: Category;
|
||
/**
|
||
* 红酒
|
||
*/
|
||
static Wine: Category;
|
||
/**
|
||
* 洋酒
|
||
*/
|
||
static Whisky: Category;
|
||
/**
|
||
* 黄酒
|
||
*/
|
||
static Huangjiu: Category;
|
||
/**
|
||
* 清酒
|
||
*/
|
||
static Sake: Category;
|
||
/**
|
||
* 果酒
|
||
*/
|
||
static Fruit: Category;
|
||
/**
|
||
* 调酒
|
||
*/
|
||
static Cocktail: Category;
|
||
/**
|
||
* 其他
|
||
*/
|
||
static Other: Category;
|
||
|
||
static entries(): Array<option>;
|
||
static getLabel(v: number|string): string;
|
||
}
|
||
|
||
/**
|
||
* 饮用量单位
|
||
*/
|
||
export declare class Unit extends Enum {
|
||
/**
|
||
* 毫升
|
||
*/
|
||
static Ml: Unit;
|
||
/**
|
||
* 两
|
||
*/
|
||
static Liang: Unit;
|
||
/**
|
||
* 瓶
|
||
*/
|
||
static Bottle: Unit;
|
||
/**
|
||
* 杯
|
||
*/
|
||
static Cup: Unit;
|
||
/**
|
||
* 听
|
||
*/
|
||
static Can: Unit;
|
||
/**
|
||
* shot
|
||
*/
|
||
static Shot: Unit;
|
||
|
||
static entries(): Array<option>;
|
||
static getLabel(v: number|string): string;
|
||
}
|
||
|
||
/**
|
||
* 配餐分类
|
||
*/
|
||
export declare class FoodCategory extends Enum {
|
||
/**
|
||
* 火锅
|
||
*/
|
||
static Hotpot: FoodCategory;
|
||
/**
|
||
* 烧烤
|
||
*/
|
||
static Bbq: FoodCategory;
|
||
/**
|
||
* 炒菜
|
||
*/
|
||
static Stirfry: FoodCategory;
|
||
/**
|
||
* 海鲜
|
||
*/
|
||
static Seafood: FoodCategory;
|
||
/**
|
||
* 日料
|
||
*/
|
||
static Japanese: FoodCategory;
|
||
/**
|
||
* 西餐
|
||
*/
|
||
static Western: FoodCategory;
|
||
/**
|
||
* 小吃卤味
|
||
*/
|
||
static Snack: FoodCategory;
|
||
/**
|
||
* 零食
|
||
*/
|
||
static Junk: FoodCategory;
|
||
/**
|
||
* 无配餐
|
||
*/
|
||
static None: FoodCategory;
|
||
|
||
static entries(): Array<option>;
|
||
static getLabel(v: number|string): string;
|
||
}
|
||
|
||
/**
|
||
* 饮用感受
|
||
*/
|
||
export declare class Feeling extends Enum {
|
||
/**
|
||
* 微醺
|
||
*/
|
||
static Tipsy: Feeling;
|
||
/**
|
||
* 到位
|
||
*/
|
||
static Buzzed: Feeling;
|
||
/**
|
||
* 醉了
|
||
*/
|
||
static Drunk: Feeling;
|
||
/**
|
||
* 断片
|
||
*/
|
||
static Blackout: Feeling;
|
||
|
||
static entries(): Array<option>;
|
||
static getLabel(v: number|string): string;
|
||
}
|
||
|
||
/**
|
||
* 可见范围
|
||
*/
|
||
export declare class Visibility extends Enum {
|
||
/**
|
||
* 公开
|
||
*/
|
||
static Public: Visibility;
|
||
/**
|
||
* 仅好友
|
||
*/
|
||
static Friends: Visibility;
|
||
/**
|
||
* 仅自己
|
||
*/
|
||
static Private: Visibility;
|
||
|
||
static entries(): Array<option>;
|
||
static getLabel(v: number|string): string;
|
||
}
|
||
|
||
/**
|
||
* 打卡模式
|
||
*/
|
||
export declare class Mode extends Enum {
|
||
/**
|
||
* 今日喝了
|
||
*/
|
||
static Drank: Mode;
|
||
/**
|
||
* 今日未喝
|
||
*/
|
||
static Abstain: Mode;
|
||
|
||
static entries(): Array<option>;
|
||
static getLabel(v: number|string): string;
|
||
}
|
||
|
||
/**
|
||
* 饮酒频率
|
||
*/
|
||
export declare class Frequency extends Enum {
|
||
/**
|
||
* 很少
|
||
*/
|
||
static Rarely: Frequency;
|
||
/**
|
||
* 有时
|
||
*/
|
||
static Sometimes: Frequency;
|
||
/**
|
||
* 经常
|
||
*/
|
||
static Often: Frequency;
|
||
|
||
static entries(): Array<option>;
|
||
static getLabel(v: number|string): string;
|
||
}
|
||
|
||
|
||
/**
|
||
* 手机号
|
||
*/
|
||
export declare class Phone {
|
||
[key: string]: any;
|
||
/**
|
||
* 区号 (cn +86)
|
||
*/
|
||
regin: string
|
||
/**
|
||
* 手机号
|
||
*/
|
||
number: string
|
||
|
||
/**
|
||
* @param regin string
|
||
* @param number string
|
||
*/
|
||
constructor(regin: string, number: string);
|
||
}
|
||
|
||
/**
|
||
* 分页请求参数
|
||
*/
|
||
export declare class PageReq {
|
||
[key: string]: any;
|
||
/**
|
||
* 页码
|
||
*/
|
||
page: number;
|
||
/**
|
||
* 每页数量,默认1-100
|
||
*/
|
||
pageSize: number;
|
||
|
||
/**
|
||
* @param page number 页码
|
||
* @param pageSize number 每页数量,默认1-100
|
||
*/
|
||
constructor(page: number,pageSize: number,);
|
||
/**
|
||
* 从对象创建 PageReq
|
||
*
|
||
* @param o Object
|
||
* - page: number, // 页码
|
||
* - pageSize: number, // 每页数量,默认1-100
|
||
*/
|
||
static fromObject(o: Object): PageReq;
|
||
}
|
||
|
||
/**
|
||
* 分页响应结构
|
||
*/
|
||
export declare class PageResp {
|
||
[key: string]: any;
|
||
/**
|
||
* 总数
|
||
*/
|
||
total: number;
|
||
/**
|
||
* 当前页码
|
||
*/
|
||
page: number;
|
||
/**
|
||
* 每页数量
|
||
*/
|
||
pageSize: number;
|
||
|
||
/**
|
||
* @param total number 总数
|
||
* @param page number 当前页码
|
||
* @param pageSize number 每页数量
|
||
*/
|
||
constructor(total: number,page: number,pageSize: number,);
|
||
/**
|
||
* 从对象创建 PageResp
|
||
*
|
||
* @param o Object
|
||
* - total: number, // 总数
|
||
* - page: number, // 当前页码
|
||
* - pageSize: number, // 每页数量
|
||
*/
|
||
static fromObject(o: Object): PageResp;
|
||
}
|
||
|
||
/**
|
||
*
|
||
*/
|
||
export declare class Ok {
|
||
[key: string]: any;
|
||
/**
|
||
* 是否成功
|
||
*/
|
||
ok: boolean;
|
||
|
||
/**
|
||
* @param ok boolean 是否成功
|
||
*/
|
||
constructor(ok: boolean,);
|
||
/**
|
||
* 从对象创建 Ok
|
||
*
|
||
* @param o Object
|
||
* - ok: boolean, // 是否成功
|
||
*/
|
||
static fromObject(o: Object): Ok;
|
||
}
|
||
|
||
/**
|
||
* 微信登录请求参数
|
||
*/
|
||
export declare class WechatLoginReq {
|
||
[key: string]: any;
|
||
/**
|
||
* 登录时获取的 code, 可通过 wx.login 获取
|
||
*/
|
||
code: string;
|
||
/**
|
||
* 用户昵称
|
||
*/
|
||
nickName: string;
|
||
/**
|
||
* 头像URL
|
||
*/
|
||
avatarUrl: string;
|
||
|
||
/**
|
||
* @param code string 登录时获取的 code, 可通过 wx.login 获取
|
||
* @param nickName string 用户昵称
|
||
* @param avatarUrl string 头像URL
|
||
*/
|
||
constructor(code: string,nickName: string,avatarUrl: string,);
|
||
/**
|
||
* 从对象创建 WechatLoginReq
|
||
*
|
||
* @param o Object
|
||
* - code: string, // 登录时获取的 code, 可通过 wx.login 获取
|
||
* - nickName: string, // 用户昵称
|
||
* - avatarUrl: string, // 头像URL
|
||
*/
|
||
static fromObject(o: Object): WechatLoginReq;
|
||
}
|
||
|
||
/**
|
||
* 微信登录返回值
|
||
*/
|
||
export declare class WechatLoginResp {
|
||
[key: string]: any;
|
||
/**
|
||
* JWT Token
|
||
*/
|
||
token: string;
|
||
/**
|
||
* 用户信息
|
||
*/
|
||
user: User;
|
||
/**
|
||
* 是否新用户
|
||
*/
|
||
isNew: boolean;
|
||
/**
|
||
* 会话密钥
|
||
*/
|
||
session_key: string;
|
||
/**
|
||
* 用户唯一标识
|
||
*/
|
||
open_id: string;
|
||
/**
|
||
* 用户在开放平台的唯一标识符,若当前小程序已绑定到微信开放平台账号下会返回,详见 UnionID 机制说明。
|
||
*/
|
||
union_id: string;
|
||
/**
|
||
* 错误码
|
||
*/
|
||
errcode: number;
|
||
/**
|
||
* 错误信息
|
||
*/
|
||
errmsg: string;
|
||
/**
|
||
* 刷新token
|
||
*/
|
||
refresh_token: string;
|
||
|
||
/**
|
||
* @param token string JWT Token
|
||
* @param user User 用户信息
|
||
* @param isNew boolean 是否新用户
|
||
* @param session_key string 会话密钥
|
||
* @param open_id string 用户唯一标识
|
||
* @param union_id string 用户在开放平台的唯一标识符,若当前小程序已绑定到微信开放平台账号下会返回,详见 UnionID 机制说明。
|
||
* @param errcode number 错误码
|
||
* @param errmsg string 错误信息
|
||
* @param refresh_token string 刷新token
|
||
*/
|
||
constructor(token: string,user: User,isNew: boolean,session_key: string,open_id: string,union_id: string,errcode: number,errmsg: string,refresh_token: string,);
|
||
/**
|
||
* 从对象创建 WechatLoginResp
|
||
*
|
||
* @param o Object
|
||
* - token: string, // JWT Token
|
||
* - user: User, // 用户信息
|
||
* - isNew: boolean, // 是否新用户
|
||
* - session_key: string, // 会话密钥
|
||
* - open_id: string, // 用户唯一标识
|
||
* - union_id: string, // 用户在开放平台的唯一标识符,若当前小程序已绑定到微信开放平台账号下会返回,详见 UnionID 机制说明。
|
||
* - errcode: number, // 错误码
|
||
* - errmsg: string, // 错误信息
|
||
* - refresh_token: string, // 刷新token
|
||
*/
|
||
static fromObject(o: Object): WechatLoginResp;
|
||
}
|
||
|
||
/**
|
||
* 获取微信手机号
|
||
*/
|
||
export declare class WechatGetPhoneNumberReq {
|
||
[key: string]: any;
|
||
/**
|
||
* 手机号获取凭证
|
||
*/
|
||
code: string;
|
||
|
||
/**
|
||
* @param code string 手机号获取凭证
|
||
*/
|
||
constructor(code: string,);
|
||
/**
|
||
* 从对象创建 WechatGetPhoneNumberReq
|
||
*
|
||
* @param o Object
|
||
* - code: string, // 手机号获取凭证
|
||
*/
|
||
static fromObject(o: Object): WechatGetPhoneNumberReq;
|
||
}
|
||
|
||
/**
|
||
* 获取微信手机号返回值
|
||
*/
|
||
export declare class WechatGetPhoneNumberResp {
|
||
[key: string]: any;
|
||
/**
|
||
* 错误码
|
||
*/
|
||
errcode: number;
|
||
/**
|
||
* 错误信息
|
||
*/
|
||
errmsg: string;
|
||
/**
|
||
* token:api使用
|
||
*/
|
||
token: string;
|
||
/**
|
||
* token 超时时间,单位(秒)
|
||
*/
|
||
expires_in: number;
|
||
/**
|
||
* refresh_token:刷新token
|
||
*/
|
||
refresh_token: string;
|
||
|
||
/**
|
||
* @param errcode number 错误码
|
||
* @param errmsg string 错误信息
|
||
* @param token string token:api使用
|
||
* @param expires_in number token 超时时间,单位(秒)
|
||
* @param refresh_token string refresh_token:刷新token
|
||
*/
|
||
constructor(errcode: number,errmsg: string,token: string,expires_in: number,refresh_token: string,);
|
||
/**
|
||
* 从对象创建 WechatGetPhoneNumberResp
|
||
*
|
||
* @param o Object
|
||
* - errcode: number, // 错误码
|
||
* - errmsg: string, // 错误信息
|
||
* - token: string, // token:api使用
|
||
* - expires_in: number, // token 超时时间,单位(秒)
|
||
* - refresh_token: string, // refresh_token:刷新token
|
||
*/
|
||
static fromObject(o: Object): WechatGetPhoneNumberResp;
|
||
}
|
||
|
||
/**
|
||
* 刷新token请求参数
|
||
*/
|
||
export declare class RefreshTokenReq {
|
||
[key: string]: any;
|
||
/**
|
||
* 签发 token 时生成的 refresh_token
|
||
*/
|
||
refresh_token: string;
|
||
|
||
/**
|
||
* @param refresh_token string 签发 token 时生成的 refresh_token
|
||
*/
|
||
constructor(refresh_token: string,);
|
||
/**
|
||
* 从对象创建 RefreshTokenReq
|
||
*
|
||
* @param o Object
|
||
* - refresh_token: string, // 签发 token 时生成的 refresh_token
|
||
*/
|
||
static fromObject(o: Object): RefreshTokenReq;
|
||
}
|
||
|
||
/**
|
||
* 刷新 token 返回值
|
||
*/
|
||
export declare class RefreshTokenResp {
|
||
[key: string]: any;
|
||
/**
|
||
* 生成的新token
|
||
*/
|
||
token: string;
|
||
/**
|
||
* token 超时时间,单位(秒)
|
||
*/
|
||
expire_in: number;
|
||
/**
|
||
* refresh_token:刷新token
|
||
*/
|
||
refresh_token: string;
|
||
|
||
/**
|
||
* @param token string 生成的新token
|
||
* @param expire_in number token 超时时间,单位(秒)
|
||
* @param refresh_token string refresh_token:刷新token
|
||
*/
|
||
constructor(token: string,expire_in: number,refresh_token: string,);
|
||
/**
|
||
* 从对象创建 RefreshTokenResp
|
||
*
|
||
* @param o Object
|
||
* - token: string, // 生成的新token
|
||
* - expire_in: number, // token 超时时间,单位(秒)
|
||
* - refresh_token: string, // refresh_token:刷新token
|
||
*/
|
||
static fromObject(o: Object): RefreshTokenResp;
|
||
}
|
||
|
||
/**
|
||
* 成就条件
|
||
*/
|
||
export declare class AchievementCondition {
|
||
[key: string]: any;
|
||
/**
|
||
* 条件类型
|
||
*/
|
||
type: AchievementConditionType;
|
||
/**
|
||
* 目标值
|
||
*/
|
||
value: number;
|
||
|
||
/**
|
||
* @param type AchievementConditionType 条件类型
|
||
* @param value number 目标值
|
||
*/
|
||
constructor(type: AchievementConditionType,value: number,);
|
||
/**
|
||
* 从对象创建 AchievementCondition
|
||
*
|
||
* @param o Object
|
||
* - type: AchievementConditionType, // 条件类型
|
||
* - value: number, // 目标值
|
||
*/
|
||
static fromObject(o: Object): AchievementCondition;
|
||
}
|
||
|
||
/**
|
||
* 成就信息
|
||
*/
|
||
export declare class Achievement {
|
||
[key: string]: any;
|
||
/**
|
||
* 成就ID
|
||
*/
|
||
id: string;
|
||
/**
|
||
* 成就名称
|
||
*/
|
||
name: string;
|
||
/**
|
||
* 成就描述
|
||
*/
|
||
desc: string;
|
||
/**
|
||
* 成就图标
|
||
*/
|
||
icon: string;
|
||
/**
|
||
* 是否已解锁
|
||
*/
|
||
unlocked: boolean;
|
||
/**
|
||
* 解锁时间
|
||
*/
|
||
unlockedAt: string;
|
||
/**
|
||
* 成就条件
|
||
*/
|
||
condition: AchievementCondition;
|
||
/**
|
||
* 进度(0-1)
|
||
*/
|
||
progress: number;
|
||
|
||
/**
|
||
* @param id string 成就ID
|
||
* @param name string 成就名称
|
||
* @param desc string 成就描述
|
||
* @param icon string 成就图标
|
||
* @param unlocked boolean 是否已解锁
|
||
* @param unlockedAt string 解锁时间
|
||
* @param condition AchievementCondition 成就条件
|
||
* @param progress number 进度(0-1)
|
||
*/
|
||
constructor(id: string,name: string,desc: string,icon: string,unlocked: boolean,unlockedAt: string,condition: AchievementCondition,progress: number,);
|
||
/**
|
||
* 从对象创建 Achievement
|
||
*
|
||
* @param o Object
|
||
* - id: string, // 成就ID
|
||
* - name: string, // 成就名称
|
||
* - desc: string, // 成就描述
|
||
* - icon: string, // 成就图标
|
||
* - unlocked: boolean, // 是否已解锁
|
||
* - unlockedAt: string, // 解锁时间
|
||
* - condition: AchievementCondition, // 成就条件
|
||
* - progress: number, // 进度(0-1)
|
||
*/
|
||
static fromObject(o: Object): Achievement;
|
||
}
|
||
|
||
/**
|
||
*
|
||
*/
|
||
export declare class GetAchievementsReq {
|
||
[key: string]: any;
|
||
|
||
/**
|
||
*/
|
||
constructor();
|
||
/**
|
||
* 从对象创建 GetAchievementsReq
|
||
*
|
||
* @param o Object
|
||
*/
|
||
static fromObject(o: Object): GetAchievementsReq;
|
||
}
|
||
|
||
/**
|
||
* 获取成就列表响应
|
||
*/
|
||
export declare class GetAchievementsResp {
|
||
[key: string]: any;
|
||
/**
|
||
* 成就列表数据
|
||
*/
|
||
data: AchievementsData;
|
||
|
||
/**
|
||
* @param data AchievementsData 成就列表数据
|
||
*/
|
||
constructor(data: AchievementsData,);
|
||
/**
|
||
* 从对象创建 GetAchievementsResp
|
||
*
|
||
* @param o Object
|
||
* - data: AchievementsData, // 成就列表数据
|
||
*/
|
||
static fromObject(o: Object): GetAchievementsResp;
|
||
}
|
||
|
||
/**
|
||
* 成就列表数据
|
||
*/
|
||
export declare class AchievementsData {
|
||
[key: string]: any;
|
||
/**
|
||
* 成就列表
|
||
*/
|
||
achievements: Array<Achievement>;
|
||
|
||
/**
|
||
* @param achievements Array<Achievement> 成就列表
|
||
*/
|
||
constructor(achievements: Array<Achievement>,);
|
||
/**
|
||
* 从对象创建 AchievementsData
|
||
*
|
||
* @param o Object
|
||
* - achievements: Array<Achievement>, // 成就列表
|
||
*/
|
||
static fromObject(o: Object): AchievementsData;
|
||
}
|
||
|
||
/**
|
||
* 朋友圈动态项
|
||
*/
|
||
export declare class FeedItem {
|
||
[key: string]: any;
|
||
/**
|
||
* 记录ID
|
||
*/
|
||
id: string|number;
|
||
/**
|
||
* 用户信息
|
||
*/
|
||
user: FeedUser;
|
||
/**
|
||
* 日期
|
||
*/
|
||
date: string;
|
||
/**
|
||
* 打卡模式
|
||
*/
|
||
mode: Mode;
|
||
/**
|
||
* 酒水列表
|
||
*/
|
||
drinks: Array<DrinkItem>;
|
||
/**
|
||
* 配餐信息
|
||
*/
|
||
food: FoodInfo;
|
||
/**
|
||
* 感受
|
||
*/
|
||
feeling: Feeling;
|
||
/**
|
||
* 照片URL数组
|
||
*/
|
||
photos: Array<string>;
|
||
/**
|
||
* 标准杯总数
|
||
*/
|
||
standardCupsTotal: number;
|
||
/**
|
||
* 酒言酒语
|
||
*/
|
||
quote: string;
|
||
/**
|
||
* 点赞数
|
||
*/
|
||
likeCount: number;
|
||
/**
|
||
* 评论数
|
||
*/
|
||
commentCount: number;
|
||
/**
|
||
* 当前用户是否已点赞
|
||
*/
|
||
liked: boolean;
|
||
/**
|
||
* 创建时间
|
||
*/
|
||
createdAt: string;
|
||
|
||
/**
|
||
* @param id string|number 记录ID
|
||
* @param user FeedUser 用户信息
|
||
* @param date string 日期
|
||
* @param mode Mode 打卡模式
|
||
* @param drinks Array<DrinkItem> 酒水列表
|
||
* @param food FoodInfo 配餐信息
|
||
* @param feeling Feeling 感受
|
||
* @param photos Array<string> 照片URL数组
|
||
* @param standardCupsTotal number 标准杯总数
|
||
* @param quote string 酒言酒语
|
||
* @param likeCount number 点赞数
|
||
* @param commentCount number 评论数
|
||
* @param liked boolean 当前用户是否已点赞
|
||
* @param createdAt string 创建时间
|
||
*/
|
||
constructor(id: string|number,user: FeedUser,date: string,mode: Mode,drinks: Array<DrinkItem>,food: FoodInfo,feeling: Feeling,photos: Array<string>,standardCupsTotal: number,quote: string,likeCount: number,commentCount: number,liked: boolean,createdAt: string,);
|
||
/**
|
||
* 从对象创建 FeedItem
|
||
*
|
||
* @param o Object
|
||
* - id: string|number, // 记录ID
|
||
* - user: FeedUser, // 用户信息
|
||
* - date: string, // 日期
|
||
* - mode: Mode, // 打卡模式
|
||
* - drinks: Array<DrinkItem>, // 酒水列表
|
||
* - food: FoodInfo, // 配餐信息
|
||
* - feeling: Feeling, // 感受
|
||
* - photos: Array<string>, // 照片URL数组
|
||
* - standardCupsTotal: number, // 标准杯总数
|
||
* - quote: string, // 酒言酒语
|
||
* - likeCount: number, // 点赞数
|
||
* - commentCount: number, // 评论数
|
||
* - liked: boolean, // 当前用户是否已点赞
|
||
* - createdAt: string, // 创建时间
|
||
*/
|
||
static fromObject(o: Object): FeedItem;
|
||
}
|
||
|
||
/**
|
||
* 朋友圈用户信息
|
||
*/
|
||
export declare class FeedUser {
|
||
[key: string]: any;
|
||
/**
|
||
* 用户ID
|
||
*/
|
||
id: string|number;
|
||
/**
|
||
* 用户昵称
|
||
*/
|
||
nickname: string;
|
||
/**
|
||
* 头像URL
|
||
*/
|
||
avatar: string;
|
||
|
||
/**
|
||
* @param id string|number 用户ID
|
||
* @param nickname string 用户昵称
|
||
* @param avatar string 头像URL
|
||
*/
|
||
constructor(id: string|number,nickname: string,avatar: string,);
|
||
/**
|
||
* 从对象创建 FeedUser
|
||
*
|
||
* @param o Object
|
||
* - id: string|number, // 用户ID
|
||
* - nickname: string, // 用户昵称
|
||
* - avatar: string, // 头像URL
|
||
*/
|
||
static fromObject(o: Object): FeedUser;
|
||
}
|
||
|
||
/**
|
||
* 获取朋友圈动态请求
|
||
*/
|
||
export declare class GetFeedReq {
|
||
[key: string]: any;
|
||
/**
|
||
* 游标分页,上一页最后一条ID
|
||
*/
|
||
lastId: string|number;
|
||
|
||
/**
|
||
* @param lastId string|number 游标分页,上一页最后一条ID
|
||
*/
|
||
constructor(lastId: string|number,);
|
||
/**
|
||
* 从对象创建 GetFeedReq
|
||
*
|
||
* @param o Object
|
||
* - lastId: string|number, // 游标分页,上一页最后一条ID
|
||
*/
|
||
static fromObject(o: Object): GetFeedReq;
|
||
}
|
||
|
||
/**
|
||
* 获取朋友圈动态响应
|
||
*/
|
||
export declare class GetFeedResp {
|
||
[key: string]: any;
|
||
/**
|
||
* 朋友圈动态分页数据
|
||
*/
|
||
data: FeedPageData;
|
||
|
||
/**
|
||
* @param data FeedPageData 朋友圈动态分页数据
|
||
*/
|
||
constructor(data: FeedPageData,);
|
||
/**
|
||
* 从对象创建 GetFeedResp
|
||
*
|
||
* @param o Object
|
||
* - data: FeedPageData, // 朋友圈动态分页数据
|
||
*/
|
||
static fromObject(o: Object): GetFeedResp;
|
||
}
|
||
|
||
/**
|
||
* 朋友圈动态分页数据
|
||
*/
|
||
export declare class FeedPageData {
|
||
[key: string]: any;
|
||
/**
|
||
* 动态列表
|
||
*/
|
||
list: Array<FeedItem>;
|
||
|
||
/**
|
||
* @param list Array<FeedItem> 动态列表
|
||
*/
|
||
constructor(list: Array<FeedItem>,);
|
||
/**
|
||
* 从对象创建 FeedPageData
|
||
*
|
||
* @param o Object
|
||
* - list: Array<FeedItem>, // 动态列表
|
||
*/
|
||
static fromObject(o: Object): FeedPageData;
|
||
}
|
||
|
||
/**
|
||
* 点赞/取消点赞请求
|
||
*/
|
||
export declare class LikeRecordReq {
|
||
[key: string]: any;
|
||
/**
|
||
* 记录ID
|
||
*/
|
||
id: string|number;
|
||
|
||
/**
|
||
* @param id string|number 记录ID
|
||
*/
|
||
constructor(id: string|number,);
|
||
/**
|
||
* 从对象创建 LikeRecordReq
|
||
*
|
||
* @param o Object
|
||
* - id: string|number, // 记录ID
|
||
*/
|
||
static fromObject(o: Object): LikeRecordReq;
|
||
}
|
||
|
||
/**
|
||
* 点赞/取消点赞响应
|
||
*/
|
||
export declare class LikeRecordResp {
|
||
[key: string]: any;
|
||
|
||
/**
|
||
*/
|
||
constructor();
|
||
/**
|
||
* 从对象创建 LikeRecordResp
|
||
*
|
||
* @param o Object
|
||
*/
|
||
static fromObject(o: Object): LikeRecordResp;
|
||
}
|
||
|
||
/**
|
||
* 上传照片请求
|
||
*/
|
||
export declare class UploadPhotoReq {
|
||
[key: string]: any;
|
||
/**
|
||
* 图片Url
|
||
*/
|
||
url: string;
|
||
/**
|
||
* 关联记录ID
|
||
*/
|
||
recordId: string|number;
|
||
|
||
/**
|
||
* @param url string 图片Url
|
||
* @param recordId string|number 关联记录ID
|
||
*/
|
||
constructor(url: string,recordId: string|number,);
|
||
/**
|
||
* 从对象创建 UploadPhotoReq
|
||
*
|
||
* @param o Object
|
||
* - url: string, // 图片Url
|
||
* - recordId: string|number, // 关联记录ID
|
||
*/
|
||
static fromObject(o: Object): UploadPhotoReq;
|
||
}
|
||
|
||
/**
|
||
* 上传照片响应
|
||
*/
|
||
export declare class UploadPhotoResp {
|
||
[key: string]: any;
|
||
|
||
/**
|
||
*/
|
||
constructor();
|
||
/**
|
||
* 从对象创建 UploadPhotoResp
|
||
*
|
||
* @param o Object
|
||
*/
|
||
static fromObject(o: Object): UploadPhotoResp;
|
||
}
|
||
|
||
/**
|
||
* 批量上传照片请求
|
||
*/
|
||
export declare class UploadPhotosReq {
|
||
[key: string]: any;
|
||
/**
|
||
* 图片URL数组(最多9张)
|
||
*/
|
||
urls: Array<string>;
|
||
/**
|
||
* 关联记录ID
|
||
*/
|
||
recordId: string|number;
|
||
|
||
/**
|
||
* @param urls Array<string> 图片URL数组(最多9张)
|
||
* @param recordId string|number 关联记录ID
|
||
*/
|
||
constructor(urls: Array<string>,recordId: string|number,);
|
||
/**
|
||
* 从对象创建 UploadPhotosReq
|
||
*
|
||
* @param o Object
|
||
* - urls: Array<string>, // 图片URL数组(最多9张)
|
||
* - recordId: string|number, // 关联记录ID
|
||
*/
|
||
static fromObject(o: Object): UploadPhotosReq;
|
||
}
|
||
|
||
/**
|
||
* 批量上传照片响应
|
||
*/
|
||
export declare class UploadPhotosResp {
|
||
[key: string]: any;
|
||
|
||
/**
|
||
*/
|
||
constructor();
|
||
/**
|
||
* 从对象创建 UploadPhotosResp
|
||
*
|
||
* @param o Object
|
||
*/
|
||
static fromObject(o: Object): UploadPhotosResp;
|
||
}
|
||
|
||
/**
|
||
* 酒水项
|
||
*/
|
||
export declare class DrinkItem {
|
||
[key: string]: any;
|
||
/**
|
||
* 酒类分类ID
|
||
*/
|
||
category: Category;
|
||
/**
|
||
* 品牌名称
|
||
*/
|
||
brand: string;
|
||
/**
|
||
* 产品名
|
||
*/
|
||
product: string;
|
||
/**
|
||
* 饮用量数值
|
||
*/
|
||
amount: number;
|
||
/**
|
||
* 单位
|
||
*/
|
||
unit: Unit;
|
||
/**
|
||
* 酒精度数(%)
|
||
*/
|
||
degree: number;
|
||
/**
|
||
* 标准杯数(前端计算,后端应校验)
|
||
*/
|
||
standardCups: number;
|
||
|
||
/**
|
||
* @param category Category 酒类分类ID
|
||
* @param brand string 品牌名称
|
||
* @param product string 产品名
|
||
* @param amount number 饮用量数值
|
||
* @param unit Unit 单位
|
||
* @param degree number 酒精度数(%)
|
||
* @param standardCups number 标准杯数(前端计算,后端应校验)
|
||
*/
|
||
constructor(category: Category,brand: string,product: string,amount: number,unit: Unit,degree: number,standardCups: number,);
|
||
/**
|
||
* 从对象创建 DrinkItem
|
||
*
|
||
* @param o Object
|
||
* - category: Category, // 酒类分类ID
|
||
* - brand: string, // 品牌名称
|
||
* - product: string, // 产品名
|
||
* - amount: number, // 饮用量数值
|
||
* - unit: Unit, // 单位
|
||
* - degree: number, // 酒精度数(%)
|
||
* - standardCups: number, // 标准杯数(前端计算,后端应校验)
|
||
*/
|
||
static fromObject(o: Object): DrinkItem;
|
||
}
|
||
|
||
/**
|
||
* 配餐信息
|
||
*/
|
||
export declare class FoodInfo {
|
||
[key: string]: any;
|
||
/**
|
||
* 配餐分类ID
|
||
*/
|
||
category: FoodCategory;
|
||
/**
|
||
* 具体菜名
|
||
*/
|
||
name: string;
|
||
|
||
/**
|
||
* @param category FoodCategory 配餐分类ID
|
||
* @param name string 具体菜名
|
||
*/
|
||
constructor(category: FoodCategory,name: string,);
|
||
/**
|
||
* 从对象创建 FoodInfo
|
||
*
|
||
* @param o Object
|
||
* - category: FoodCategory, // 配餐分类ID
|
||
* - name: string, // 具体菜名
|
||
*/
|
||
static fromObject(o: Object): FoodInfo;
|
||
}
|
||
|
||
/**
|
||
* 创建打卡记录请求
|
||
*/
|
||
export declare class CreateRecordReq {
|
||
[key: string]: any;
|
||
/**
|
||
* 日期 YYYY-MM-DD
|
||
*/
|
||
date: string;
|
||
/**
|
||
* 打卡模式
|
||
*/
|
||
mode: Mode;
|
||
/**
|
||
* 酒水列表(mode=abstain时为空数组)
|
||
*/
|
||
drinks: Array<DrinkItem>;
|
||
/**
|
||
* 配餐信息
|
||
*/
|
||
food: FoodInfo;
|
||
/**
|
||
* 感受ID
|
||
*/
|
||
feeling: Feeling;
|
||
/**
|
||
* 照片URL数组(最多9张)
|
||
*/
|
||
photos: Array<string>;
|
||
/**
|
||
* 可见范围
|
||
*/
|
||
visibility: Visibility;
|
||
/**
|
||
* 酒言酒语
|
||
*/
|
||
quote: string;
|
||
|
||
/**
|
||
* @param date string 日期 YYYY-MM-DD
|
||
* @param mode Mode 打卡模式
|
||
* @param drinks Array<DrinkItem> 酒水列表(mode=abstain时为空数组)
|
||
* @param food FoodInfo 配餐信息
|
||
* @param feeling Feeling 感受ID
|
||
* @param photos Array<string> 照片URL数组(最多9张)
|
||
* @param visibility Visibility 可见范围
|
||
* @param quote string 酒言酒语
|
||
*/
|
||
constructor(date: string,mode: Mode,drinks: Array<DrinkItem>,food: FoodInfo,feeling: Feeling,photos: Array<string>,visibility: Visibility,quote: string,);
|
||
/**
|
||
* 从对象创建 CreateRecordReq
|
||
*
|
||
* @param o Object
|
||
* - date: string, // 日期 YYYY-MM-DD
|
||
* - mode: Mode, // 打卡模式
|
||
* - drinks: Array<DrinkItem>, // 酒水列表(mode=abstain时为空数组)
|
||
* - food: FoodInfo, // 配餐信息
|
||
* - feeling: Feeling, // 感受ID
|
||
* - photos: Array<string>, // 照片URL数组(最多9张)
|
||
* - visibility: Visibility, // 可见范围
|
||
* - quote: string, // 酒言酒语
|
||
*/
|
||
static fromObject(o: Object): CreateRecordReq;
|
||
}
|
||
|
||
/**
|
||
* 打卡记录详情
|
||
*/
|
||
export declare class Record {
|
||
[key: string]: any;
|
||
/**
|
||
* 记录ID
|
||
*/
|
||
id: string|number;
|
||
/**
|
||
* 日期
|
||
*/
|
||
date: string;
|
||
/**
|
||
* 打卡模式
|
||
*/
|
||
mode: Mode;
|
||
/**
|
||
* 酒水列表
|
||
*/
|
||
drinks: Array<DrinkItem>;
|
||
/**
|
||
* 配餐信息
|
||
*/
|
||
food: FoodInfo;
|
||
/**
|
||
* 感受
|
||
*/
|
||
feeling: Feeling;
|
||
/**
|
||
* 照片URL数组
|
||
*/
|
||
photos: Array<string>;
|
||
/**
|
||
* 可见范围
|
||
*/
|
||
visibility: Visibility;
|
||
/**
|
||
* 酒言酒语
|
||
*/
|
||
quote: string;
|
||
/**
|
||
* 标准杯总数
|
||
*/
|
||
standardCupsTotal: number;
|
||
/**
|
||
* 创建时间
|
||
*/
|
||
createdAt: string;
|
||
|
||
/**
|
||
* @param id string|number 记录ID
|
||
* @param date string 日期
|
||
* @param mode Mode 打卡模式
|
||
* @param drinks Array<DrinkItem> 酒水列表
|
||
* @param food FoodInfo 配餐信息
|
||
* @param feeling Feeling 感受
|
||
* @param photos Array<string> 照片URL数组
|
||
* @param visibility Visibility 可见范围
|
||
* @param quote string 酒言酒语
|
||
* @param standardCupsTotal number 标准杯总数
|
||
* @param createdAt string 创建时间
|
||
*/
|
||
constructor(id: string|number,date: string,mode: Mode,drinks: Array<DrinkItem>,food: FoodInfo,feeling: Feeling,photos: Array<string>,visibility: Visibility,quote: string,standardCupsTotal: number,createdAt: string,);
|
||
/**
|
||
* 从对象创建 Record
|
||
*
|
||
* @param o Object
|
||
* - id: string|number, // 记录ID
|
||
* - date: string, // 日期
|
||
* - mode: Mode, // 打卡模式
|
||
* - drinks: Array<DrinkItem>, // 酒水列表
|
||
* - food: FoodInfo, // 配餐信息
|
||
* - feeling: Feeling, // 感受
|
||
* - photos: Array<string>, // 照片URL数组
|
||
* - visibility: Visibility, // 可见范围
|
||
* - quote: string, // 酒言酒语
|
||
* - standardCupsTotal: number, // 标准杯总数
|
||
* - createdAt: string, // 创建时间
|
||
*/
|
||
static fromObject(o: Object): Record;
|
||
}
|
||
|
||
/**
|
||
* 创建打卡记录响应
|
||
*/
|
||
export declare class CreateRecordResp {
|
||
[key: string]: any;
|
||
/**
|
||
* 创建的记录详情
|
||
*/
|
||
data: Record;
|
||
|
||
/**
|
||
* @param data Record 创建的记录详情
|
||
*/
|
||
constructor(data: Record,);
|
||
/**
|
||
* 从对象创建 CreateRecordResp
|
||
*
|
||
* @param o Object
|
||
* - data: Record, // 创建的记录详情
|
||
*/
|
||
static fromObject(o: Object): CreateRecordResp;
|
||
}
|
||
|
||
/**
|
||
* 获取记录列表请求
|
||
*/
|
||
export declare class GetRecordsReq {
|
||
[key: string]: any;
|
||
/**
|
||
* 页码
|
||
*/
|
||
page: number;
|
||
/**
|
||
* 每页数量,默认1-100
|
||
*/
|
||
pageSize: number;
|
||
/**
|
||
* 月份筛选 YYYY-MM
|
||
*/
|
||
month: string;
|
||
/**
|
||
* 打卡模式筛选
|
||
*/
|
||
mode: Mode;
|
||
|
||
/**
|
||
* @param page number 页码
|
||
* @param pageSize number 每页数量,默认1-100
|
||
* @param month string 月份筛选 YYYY-MM
|
||
* @param mode Mode 打卡模式筛选
|
||
*/
|
||
constructor(page: number,pageSize: number,month: string,mode: Mode,);
|
||
/**
|
||
* 从对象创建 GetRecordsReq
|
||
*
|
||
* @param o Object
|
||
* - page: number, // 页码
|
||
* - pageSize: number, // 每页数量,默认1-100
|
||
* - month: string, // 月份筛选 YYYY-MM
|
||
* - mode: Mode, // 打卡模式筛选
|
||
*/
|
||
static fromObject(o: Object): GetRecordsReq;
|
||
}
|
||
|
||
/**
|
||
* 获取记录列表响应
|
||
*/
|
||
export declare class GetRecordsResp {
|
||
[key: string]: any;
|
||
/**
|
||
* 分页数据
|
||
*/
|
||
list: Array<Record>;
|
||
|
||
/**
|
||
* @param list Array<Record> 分页数据
|
||
*/
|
||
constructor(list: Array<Record>,);
|
||
/**
|
||
* 从对象创建 GetRecordsResp
|
||
*
|
||
* @param o Object
|
||
* - list: Array<Record>, // 分页数据
|
||
*/
|
||
static fromObject(o: Object): GetRecordsResp;
|
||
}
|
||
|
||
/**
|
||
* 获取单条记录详情请求
|
||
*/
|
||
export declare class GetRecordDetailReq {
|
||
[key: string]: any;
|
||
/**
|
||
* 记录ID
|
||
*/
|
||
id: string|number;
|
||
|
||
/**
|
||
* @param id string|number 记录ID
|
||
*/
|
||
constructor(id: string|number,);
|
||
/**
|
||
* 从对象创建 GetRecordDetailReq
|
||
*
|
||
* @param o Object
|
||
* - id: string|number, // 记录ID
|
||
*/
|
||
static fromObject(o: Object): GetRecordDetailReq;
|
||
}
|
||
|
||
/**
|
||
* 获取单条记录详情响应
|
||
*/
|
||
export declare class GetRecordDetailResp {
|
||
[key: string]: any;
|
||
/**
|
||
* 记录详情
|
||
*/
|
||
data: Record;
|
||
|
||
/**
|
||
* @param data Record 记录详情
|
||
*/
|
||
constructor(data: Record,);
|
||
/**
|
||
* 从对象创建 GetRecordDetailResp
|
||
*
|
||
* @param o Object
|
||
* - data: Record, // 记录详情
|
||
*/
|
||
static fromObject(o: Object): GetRecordDetailResp;
|
||
}
|
||
|
||
/**
|
||
* 删除记录请求
|
||
*/
|
||
export declare class DeleteRecordReq {
|
||
[key: string]: any;
|
||
/**
|
||
* 记录ID
|
||
*/
|
||
id: string|number;
|
||
|
||
/**
|
||
* @param id string|number 记录ID
|
||
*/
|
||
constructor(id: string|number,);
|
||
/**
|
||
* 从对象创建 DeleteRecordReq
|
||
*
|
||
* @param o Object
|
||
* - id: string|number, // 记录ID
|
||
*/
|
||
static fromObject(o: Object): DeleteRecordReq;
|
||
}
|
||
|
||
/**
|
||
* 删除记录响应
|
||
*/
|
||
export declare class DeleteRecordResp {
|
||
[key: string]: any;
|
||
|
||
/**
|
||
*/
|
||
constructor();
|
||
/**
|
||
* 从对象创建 DeleteRecordResp
|
||
*
|
||
* @param o Object
|
||
*/
|
||
static fromObject(o: Object): DeleteRecordResp;
|
||
}
|
||
|
||
/**
|
||
* 获取日历打卡数据请求
|
||
*/
|
||
export declare class GetCalendarReq {
|
||
[key: string]: any;
|
||
/**
|
||
* 年份
|
||
*/
|
||
year: number;
|
||
/**
|
||
* 月份(1-12)
|
||
*/
|
||
month: number;
|
||
|
||
/**
|
||
* @param year number 年份
|
||
* @param month number 月份(1-12)
|
||
*/
|
||
constructor(year: number,month: number,);
|
||
/**
|
||
* 从对象创建 GetCalendarReq
|
||
*
|
||
* @param o Object
|
||
* - year: number, // 年份
|
||
* - month: number, // 月份(1-12)
|
||
*/
|
||
static fromObject(o: Object): GetCalendarReq;
|
||
}
|
||
|
||
/**
|
||
* 日历打卡数据
|
||
*/
|
||
export declare class CalendarData {
|
||
[key: string]: any;
|
||
/**
|
||
* 年份
|
||
*/
|
||
year: number;
|
||
/**
|
||
* 月份
|
||
*/
|
||
month: number;
|
||
/**
|
||
* 每天的打卡数据,null表示当天无记录
|
||
*/
|
||
days: Array<CalendarDayData>;
|
||
|
||
/**
|
||
* @param year number 年份
|
||
* @param month number 月份
|
||
* @param days Array<CalendarDayData> 每天的打卡数据,null表示当天无记录
|
||
*/
|
||
constructor(year: number,month: number,days: Array<CalendarDayData>,);
|
||
/**
|
||
* 从对象创建 CalendarData
|
||
*
|
||
* @param o Object
|
||
* - year: number, // 年份
|
||
* - month: number, // 月份
|
||
* - days: Array<CalendarDayData>, // 每天的打卡数据,null表示当天无记录
|
||
*/
|
||
static fromObject(o: Object): CalendarData;
|
||
}
|
||
|
||
/**
|
||
* 日历单日打卡数据
|
||
*/
|
||
export declare class CalendarDayData {
|
||
[key: string]: any;
|
||
/**
|
||
* 日期YYYY-MM-DD
|
||
*/
|
||
date: string;
|
||
/**
|
||
* 是否有记录
|
||
*/
|
||
hasRecord: boolean;
|
||
/**
|
||
* 打卡模式
|
||
*/
|
||
mode: Mode;
|
||
/**
|
||
* 标准杯总数
|
||
*/
|
||
standardCupsTotal: number;
|
||
/**
|
||
* 记录ID
|
||
*/
|
||
id: string|number;
|
||
/**
|
||
* 酒水列表
|
||
*/
|
||
drinks: Array<DrinkItem>;
|
||
/**
|
||
* 配餐信息
|
||
*/
|
||
food: FoodInfo;
|
||
/**
|
||
* 感受
|
||
*/
|
||
feeling: Feeling;
|
||
/**
|
||
* 照片URL数组
|
||
*/
|
||
photos: Array<string>;
|
||
/**
|
||
* 可见范围
|
||
*/
|
||
visibility: Visibility;
|
||
/**
|
||
* 酒言酒语
|
||
*/
|
||
quote: string;
|
||
/**
|
||
* 创建时间
|
||
*/
|
||
createdAt: string;
|
||
|
||
/**
|
||
* @param date string 日期YYYY-MM-DD
|
||
* @param hasRecord boolean 是否有记录
|
||
* @param mode Mode 打卡模式
|
||
* @param standardCupsTotal number 标准杯总数
|
||
* @param id string|number 记录ID
|
||
* @param drinks Array<DrinkItem> 酒水列表
|
||
* @param food FoodInfo 配餐信息
|
||
* @param feeling Feeling 感受
|
||
* @param photos Array<string> 照片URL数组
|
||
* @param visibility Visibility 可见范围
|
||
* @param quote string 酒言酒语
|
||
* @param createdAt string 创建时间
|
||
*/
|
||
constructor(date: string,hasRecord: boolean,mode: Mode,standardCupsTotal: number,id: string|number,drinks: Array<DrinkItem>,food: FoodInfo,feeling: Feeling,photos: Array<string>,visibility: Visibility,quote: string,createdAt: string,);
|
||
/**
|
||
* 从对象创建 CalendarDayData
|
||
*
|
||
* @param o Object
|
||
* - date: string, // 日期YYYY-MM-DD
|
||
* - hasRecord: boolean, // 是否有记录
|
||
* - mode: Mode, // 打卡模式
|
||
* - standardCupsTotal: number, // 标准杯总数
|
||
* - id: string|number, // 记录ID
|
||
* - drinks: Array<DrinkItem>, // 酒水列表
|
||
* - food: FoodInfo, // 配餐信息
|
||
* - feeling: Feeling, // 感受
|
||
* - photos: Array<string>, // 照片URL数组
|
||
* - visibility: Visibility, // 可见范围
|
||
* - quote: string, // 酒言酒语
|
||
* - createdAt: string, // 创建时间
|
||
*/
|
||
static fromObject(o: Object): CalendarDayData;
|
||
}
|
||
|
||
/**
|
||
* 获取日历打卡数据响应
|
||
*/
|
||
export declare class GetCalendarResp {
|
||
[key: string]: any;
|
||
/**
|
||
* 年份
|
||
*/
|
||
year: number;
|
||
/**
|
||
* 月份
|
||
*/
|
||
month: number;
|
||
/**
|
||
* 每天的打卡数据,null表示当天无记录
|
||
*/
|
||
days: Array<CalendarDayData>;
|
||
|
||
/**
|
||
* @param year number 年份
|
||
* @param month number 月份
|
||
* @param days Array<CalendarDayData> 每天的打卡数据,null表示当天无记录
|
||
*/
|
||
constructor(year: number,month: number,days: Array<CalendarDayData>,);
|
||
/**
|
||
* 从对象创建 GetCalendarResp
|
||
*
|
||
* @param o Object
|
||
* - year: number, // 年份
|
||
* - month: number, // 月份
|
||
* - days: Array<CalendarDayData>, // 每天的打卡数据,null表示当天无记录
|
||
*/
|
||
static fromObject(o: Object): GetCalendarResp;
|
||
}
|
||
|
||
/**
|
||
* 用户统计概览数据
|
||
*/
|
||
export declare class StatsOverview {
|
||
[key: string]: any;
|
||
/**
|
||
* 本周饮酒天数
|
||
*/
|
||
weekDrinkCount: number;
|
||
/**
|
||
* 本周标准杯总数
|
||
*/
|
||
weekCups: number;
|
||
/**
|
||
* 本月饮酒天数
|
||
*/
|
||
monthDrinkCount: number;
|
||
/**
|
||
* 本月标准杯总数
|
||
*/
|
||
monthCups: number;
|
||
/**
|
||
* 当前连续打卡天数
|
||
*/
|
||
streak: number;
|
||
/**
|
||
* 连续类型
|
||
*/
|
||
streakType: Mode;
|
||
/**
|
||
* 总饮酒天数(去重)
|
||
*/
|
||
totalDays: number;
|
||
/**
|
||
* 总记录数
|
||
*/
|
||
totalRecords: number;
|
||
/**
|
||
* 历史累计标准杯
|
||
*/
|
||
totalCups: number;
|
||
/**
|
||
* 最爱酒类ID
|
||
*/
|
||
favCategory: Category;
|
||
/**
|
||
* 尝试过的酒类品种数
|
||
*/
|
||
categoryVariety: number;
|
||
|
||
/**
|
||
* @param weekDrinkCount number 本周饮酒天数
|
||
* @param weekCups number 本周标准杯总数
|
||
* @param monthDrinkCount number 本月饮酒天数
|
||
* @param monthCups number 本月标准杯总数
|
||
* @param streak number 当前连续打卡天数
|
||
* @param streakType Mode 连续类型
|
||
* @param totalDays number 总饮酒天数(去重)
|
||
* @param totalRecords number 总记录数
|
||
* @param totalCups number 历史累计标准杯
|
||
* @param favCategory Category 最爱酒类ID
|
||
* @param categoryVariety number 尝试过的酒类品种数
|
||
*/
|
||
constructor(weekDrinkCount: number,weekCups: number,monthDrinkCount: number,monthCups: number,streak: number,streakType: Mode,totalDays: number,totalRecords: number,totalCups: number,favCategory: Category,categoryVariety: number,);
|
||
/**
|
||
* 从对象创建 StatsOverview
|
||
*
|
||
* @param o Object
|
||
* - weekDrinkCount: number, // 本周饮酒天数
|
||
* - weekCups: number, // 本周标准杯总数
|
||
* - monthDrinkCount: number, // 本月饮酒天数
|
||
* - monthCups: number, // 本月标准杯总数
|
||
* - streak: number, // 当前连续打卡天数
|
||
* - streakType: Mode, // 连续类型
|
||
* - totalDays: number, // 总饮酒天数(去重)
|
||
* - totalRecords: number, // 总记录数
|
||
* - totalCups: number, // 历史累计标准杯
|
||
* - favCategory: Category, // 最爱酒类ID
|
||
* - categoryVariety: number, // 尝试过的酒类品种数
|
||
*/
|
||
static fromObject(o: Object): StatsOverview;
|
||
}
|
||
|
||
/**
|
||
* 获取用户统计概览响应
|
||
*/
|
||
export declare class GetStatsOverviewResp {
|
||
[key: string]: any;
|
||
/**
|
||
* 统计概览数据
|
||
*/
|
||
data: StatsOverview;
|
||
|
||
/**
|
||
* @param data StatsOverview 统计概览数据
|
||
*/
|
||
constructor(data: StatsOverview,);
|
||
/**
|
||
* 从对象创建 GetStatsOverviewResp
|
||
*
|
||
* @param o Object
|
||
* - data: StatsOverview, // 统计概览数据
|
||
*/
|
||
static fromObject(o: Object): GetStatsOverviewResp;
|
||
}
|
||
|
||
/**
|
||
* 获取月度统计请求
|
||
*/
|
||
export declare class GetMonthlyStatsReq {
|
||
[key: string]: any;
|
||
/**
|
||
* 年份,默认当前年
|
||
*/
|
||
year: number;
|
||
/**
|
||
* 月份,默认当前月
|
||
*/
|
||
month: number;
|
||
|
||
/**
|
||
* @param year number 年份,默认当前年
|
||
* @param month number 月份,默认当前月
|
||
*/
|
||
constructor(year: number,month: number,);
|
||
/**
|
||
* 从对象创建 GetMonthlyStatsReq
|
||
*
|
||
* @param o Object
|
||
* - year: number, // 年份,默认当前年
|
||
* - month: number, // 月份,默认当前月
|
||
*/
|
||
static fromObject(o: Object): GetMonthlyStatsReq;
|
||
}
|
||
|
||
/**
|
||
* 月度统计数据
|
||
*/
|
||
export declare class MonthlyStats {
|
||
[key: string]: any;
|
||
/**
|
||
* 年份
|
||
*/
|
||
year: number;
|
||
/**
|
||
* 月份
|
||
*/
|
||
month: number;
|
||
/**
|
||
* 饮酒天数
|
||
*/
|
||
drinkDays: number;
|
||
/**
|
||
* 戒酒天数
|
||
*/
|
||
abstainDays: number;
|
||
/**
|
||
* 总标准杯数
|
||
*/
|
||
totalCups: number;
|
||
/**
|
||
* 日均标准杯数
|
||
*/
|
||
avgCupsPerDay: number;
|
||
/**
|
||
* 酒类分布
|
||
*/
|
||
categoryBreakdown: Array<CategoryBreakdown>;
|
||
/**
|
||
* 感受分布
|
||
*/
|
||
feelingBreakdown: Array<FeelingBreakdown>;
|
||
/**
|
||
* 配餐分布
|
||
*/
|
||
foodBreakdown: Array<FoodBreakdown>;
|
||
|
||
/**
|
||
* @param year number 年份
|
||
* @param month number 月份
|
||
* @param drinkDays number 饮酒天数
|
||
* @param abstainDays number 戒酒天数
|
||
* @param totalCups number 总标准杯数
|
||
* @param avgCupsPerDay number 日均标准杯数
|
||
* @param categoryBreakdown Array<CategoryBreakdown> 酒类分布
|
||
* @param feelingBreakdown Array<FeelingBreakdown> 感受分布
|
||
* @param foodBreakdown Array<FoodBreakdown> 配餐分布
|
||
*/
|
||
constructor(year: number,month: number,drinkDays: number,abstainDays: number,totalCups: number,avgCupsPerDay: number,categoryBreakdown: Array<CategoryBreakdown>,feelingBreakdown: Array<FeelingBreakdown>,foodBreakdown: Array<FoodBreakdown>,);
|
||
/**
|
||
* 从对象创建 MonthlyStats
|
||
*
|
||
* @param o Object
|
||
* - year: number, // 年份
|
||
* - month: number, // 月份
|
||
* - drinkDays: number, // 饮酒天数
|
||
* - abstainDays: number, // 戒酒天数
|
||
* - totalCups: number, // 总标准杯数
|
||
* - avgCupsPerDay: number, // 日均标准杯数
|
||
* - categoryBreakdown: Array<CategoryBreakdown>, // 酒类分布
|
||
* - feelingBreakdown: Array<FeelingBreakdown>, // 感受分布
|
||
* - foodBreakdown: Array<FoodBreakdown>, // 配餐分布
|
||
*/
|
||
static fromObject(o: Object): MonthlyStats;
|
||
}
|
||
|
||
/**
|
||
* 酒类分布统计项
|
||
*/
|
||
export declare class CategoryBreakdown {
|
||
[key: string]: any;
|
||
/**
|
||
* 酒类分类
|
||
*/
|
||
category: Category;
|
||
/**
|
||
* 次数
|
||
*/
|
||
count: number;
|
||
/**
|
||
* 标准杯数
|
||
*/
|
||
cups: number;
|
||
|
||
/**
|
||
* @param category Category 酒类分类
|
||
* @param count number 次数
|
||
* @param cups number 标准杯数
|
||
*/
|
||
constructor(category: Category,count: number,cups: number,);
|
||
/**
|
||
* 从对象创建 CategoryBreakdown
|
||
*
|
||
* @param o Object
|
||
* - category: Category, // 酒类分类
|
||
* - count: number, // 次数
|
||
* - cups: number, // 标准杯数
|
||
*/
|
||
static fromObject(o: Object): CategoryBreakdown;
|
||
}
|
||
|
||
/**
|
||
* 感受分布统计项
|
||
*/
|
||
export declare class FeelingBreakdown {
|
||
[key: string]: any;
|
||
/**
|
||
* 感受类型
|
||
*/
|
||
feeling: Feeling;
|
||
/**
|
||
* 次数
|
||
*/
|
||
count: number;
|
||
|
||
/**
|
||
* @param feeling Feeling 感受类型
|
||
* @param count number 次数
|
||
*/
|
||
constructor(feeling: Feeling,count: number,);
|
||
/**
|
||
* 从对象创建 FeelingBreakdown
|
||
*
|
||
* @param o Object
|
||
* - feeling: Feeling, // 感受类型
|
||
* - count: number, // 次数
|
||
*/
|
||
static fromObject(o: Object): FeelingBreakdown;
|
||
}
|
||
|
||
/**
|
||
* 配餐分布统计项
|
||
*/
|
||
export declare class FoodBreakdown {
|
||
[key: string]: any;
|
||
/**
|
||
* 配餐分类
|
||
*/
|
||
category: FoodCategory;
|
||
/**
|
||
* 次数
|
||
*/
|
||
count: number;
|
||
|
||
/**
|
||
* @param category FoodCategory 配餐分类
|
||
* @param count number 次数
|
||
*/
|
||
constructor(category: FoodCategory,count: number,);
|
||
/**
|
||
* 从对象创建 FoodBreakdown
|
||
*
|
||
* @param o Object
|
||
* - category: FoodCategory, // 配餐分类
|
||
* - count: number, // 次数
|
||
*/
|
||
static fromObject(o: Object): FoodBreakdown;
|
||
}
|
||
|
||
/**
|
||
* 获取月度统计响应
|
||
*/
|
||
export declare class GetMonthlyStatsResp {
|
||
[key: string]: any;
|
||
/**
|
||
* 月度统计数据
|
||
*/
|
||
data: MonthlyStats;
|
||
|
||
/**
|
||
* @param data MonthlyStats 月度统计数据
|
||
*/
|
||
constructor(data: MonthlyStats,);
|
||
/**
|
||
* 从对象创建 GetMonthlyStatsResp
|
||
*
|
||
* @param o Object
|
||
* - data: MonthlyStats, // 月度统计数据
|
||
*/
|
||
static fromObject(o: Object): GetMonthlyStatsResp;
|
||
}
|
||
|
||
/**
|
||
* 酒类分布统计项
|
||
*/
|
||
export declare class CategoryStats {
|
||
[key: string]: any;
|
||
/**
|
||
* 酒类分类ID
|
||
*/
|
||
id: Category;
|
||
/**
|
||
* 酒类名称
|
||
*/
|
||
name: string;
|
||
/**
|
||
* 记录次数
|
||
*/
|
||
recordCount: number;
|
||
/**
|
||
* 总标准杯数
|
||
*/
|
||
totalCups: number;
|
||
/**
|
||
* 占比(百分比)
|
||
*/
|
||
percentage: number;
|
||
|
||
/**
|
||
* @param id Category 酒类分类ID
|
||
* @param name string 酒类名称
|
||
* @param recordCount number 记录次数
|
||
* @param totalCups number 总标准杯数
|
||
* @param percentage number 占比(百分比)
|
||
*/
|
||
constructor(id: Category,name: string,recordCount: number,totalCups: number,percentage: number,);
|
||
/**
|
||
* 从对象创建 CategoryStats
|
||
*
|
||
* @param o Object
|
||
* - id: Category, // 酒类分类ID
|
||
* - name: string, // 酒类名称
|
||
* - recordCount: number, // 记录次数
|
||
* - totalCups: number, // 总标准杯数
|
||
* - percentage: number, // 占比(百分比)
|
||
*/
|
||
static fromObject(o: Object): CategoryStats;
|
||
}
|
||
|
||
/**
|
||
*
|
||
*/
|
||
export declare class GetStatsOverviewReq {
|
||
[key: string]: any;
|
||
|
||
/**
|
||
*/
|
||
constructor();
|
||
/**
|
||
* 从对象创建 GetStatsOverviewReq
|
||
*
|
||
* @param o Object
|
||
*/
|
||
static fromObject(o: Object): GetStatsOverviewReq;
|
||
}
|
||
|
||
/**
|
||
*
|
||
*/
|
||
export declare class GetCategoryStatsReq {
|
||
[key: string]: any;
|
||
|
||
/**
|
||
*/
|
||
constructor();
|
||
/**
|
||
* 从对象创建 GetCategoryStatsReq
|
||
*
|
||
* @param o Object
|
||
*/
|
||
static fromObject(o: Object): GetCategoryStatsReq;
|
||
}
|
||
|
||
/**
|
||
* 获取酒类分布统计响应
|
||
*/
|
||
export declare class GetCategoryStatsResp {
|
||
[key: string]: any;
|
||
/**
|
||
* 酒类分布统计数据
|
||
*/
|
||
data: CategoryStatsData;
|
||
|
||
/**
|
||
* @param data CategoryStatsData 酒类分布统计数据
|
||
*/
|
||
constructor(data: CategoryStatsData,);
|
||
/**
|
||
* 从对象创建 GetCategoryStatsResp
|
||
*
|
||
* @param o Object
|
||
* - data: CategoryStatsData, // 酒类分布统计数据
|
||
*/
|
||
static fromObject(o: Object): GetCategoryStatsResp;
|
||
}
|
||
|
||
/**
|
||
* 酒类分布统计数据
|
||
*/
|
||
export declare class CategoryStatsData {
|
||
[key: string]: any;
|
||
/**
|
||
* 酒类分布列表
|
||
*/
|
||
categories: Array<CategoryStats>;
|
||
|
||
/**
|
||
* @param categories Array<CategoryStats> 酒类分布列表
|
||
*/
|
||
constructor(categories: Array<CategoryStats>,);
|
||
/**
|
||
* 从对象创建 CategoryStatsData
|
||
*
|
||
* @param o Object
|
||
* - categories: Array<CategoryStats>, // 酒类分布列表
|
||
*/
|
||
static fromObject(o: Object): CategoryStatsData;
|
||
}
|
||
|
||
/**
|
||
* 用户信息
|
||
*/
|
||
export declare class User {
|
||
[key: string]: any;
|
||
/**
|
||
* 用户ID
|
||
*/
|
||
id: string|number;
|
||
/**
|
||
* 用户昵称
|
||
*/
|
||
nickname: string;
|
||
/**
|
||
* 头像URL
|
||
*/
|
||
avatar: string;
|
||
/**
|
||
* 加入时间
|
||
*/
|
||
joinedAt: string;
|
||
/**
|
||
* 用户偏好
|
||
*/
|
||
preferences: UserPreferences;
|
||
|
||
/**
|
||
* @param id string|number 用户ID
|
||
* @param nickname string 用户昵称
|
||
* @param avatar string 头像URL
|
||
* @param joinedAt string 加入时间
|
||
* @param preferences UserPreferences 用户偏好
|
||
*/
|
||
constructor(id: string|number,nickname: string,avatar: string,joinedAt: string,preferences: UserPreferences,);
|
||
/**
|
||
* 从对象创建 User
|
||
*
|
||
* @param o Object
|
||
* - id: string|number, // 用户ID
|
||
* - nickname: string, // 用户昵称
|
||
* - avatar: string, // 头像URL
|
||
* - joinedAt: string, // 加入时间
|
||
* - preferences: UserPreferences, // 用户偏好
|
||
*/
|
||
static fromObject(o: Object): User;
|
||
}
|
||
|
||
/**
|
||
* 用户偏好设置
|
||
*/
|
||
export declare class UserPreferences {
|
||
[key: string]: any;
|
||
/**
|
||
* 偏好酒类ID列表
|
||
*/
|
||
favoriteCategories: Array<Category>;
|
||
/**
|
||
* 饮酒频率
|
||
*/
|
||
frequency: Frequency;
|
||
|
||
/**
|
||
* @param favoriteCategories Array<Category> 偏好酒类ID列表
|
||
* @param frequency Frequency 饮酒频率
|
||
*/
|
||
constructor(favoriteCategories: Array<Category>,frequency: Frequency,);
|
||
/**
|
||
* 从对象创建 UserPreferences
|
||
*
|
||
* @param o Object
|
||
* - favoriteCategories: Array<Category>, // 偏好酒类ID列表
|
||
* - frequency: Frequency, // 饮酒频率
|
||
*/
|
||
static fromObject(o: Object): UserPreferences;
|
||
}
|
||
|
||
/**
|
||
* 获取用户信息请求
|
||
*/
|
||
export declare class GetUserProfileReq {
|
||
[key: string]: any;
|
||
|
||
/**
|
||
*/
|
||
constructor();
|
||
/**
|
||
* 从对象创建 GetUserProfileReq
|
||
*
|
||
* @param o Object
|
||
*/
|
||
static fromObject(o: Object): GetUserProfileReq;
|
||
}
|
||
|
||
/**
|
||
* 获取用户信息响应
|
||
*/
|
||
export declare class GetUserProfileResp {
|
||
[key: string]: any;
|
||
/**
|
||
* 用户ID
|
||
*/
|
||
id: string|number;
|
||
/**
|
||
* 用户昵称
|
||
*/
|
||
nickname: string;
|
||
/**
|
||
* 头像URL
|
||
*/
|
||
avatar: string;
|
||
/**
|
||
* 加入时间
|
||
*/
|
||
joinedAt: string;
|
||
/**
|
||
* 用户偏好
|
||
*/
|
||
preferences: UserPreferences;
|
||
|
||
/**
|
||
* @param id string|number 用户ID
|
||
* @param nickname string 用户昵称
|
||
* @param avatar string 头像URL
|
||
* @param joinedAt string 加入时间
|
||
* @param preferences UserPreferences 用户偏好
|
||
*/
|
||
constructor(id: string|number,nickname: string,avatar: string,joinedAt: string,preferences: UserPreferences,);
|
||
/**
|
||
* 从对象创建 GetUserProfileResp
|
||
*
|
||
* @param o Object
|
||
* - id: string|number, // 用户ID
|
||
* - nickname: string, // 用户昵称
|
||
* - avatar: string, // 头像URL
|
||
* - joinedAt: string, // 加入时间
|
||
* - preferences: UserPreferences, // 用户偏好
|
||
*/
|
||
static fromObject(o: Object): GetUserProfileResp;
|
||
}
|
||
|
||
/**
|
||
* 更新用户偏好请求
|
||
*/
|
||
export declare class UpdatePreferencesReq {
|
||
[key: string]: any;
|
||
/**
|
||
* 偏好酒类ID列表
|
||
*/
|
||
favoriteCategories: Array<Category>;
|
||
/**
|
||
* 饮酒频率
|
||
*/
|
||
frequency: Frequency;
|
||
|
||
/**
|
||
* @param favoriteCategories Array<Category> 偏好酒类ID列表
|
||
* @param frequency Frequency 饮酒频率
|
||
*/
|
||
constructor(favoriteCategories: Array<Category>,frequency: Frequency,);
|
||
/**
|
||
* 从对象创建 UpdatePreferencesReq
|
||
*
|
||
* @param o Object
|
||
* - favoriteCategories: Array<Category>, // 偏好酒类ID列表
|
||
* - frequency: Frequency, // 饮酒频率
|
||
*/
|
||
static fromObject(o: Object): UpdatePreferencesReq;
|
||
}
|
||
|
||
/**
|
||
* 更新用户偏好响应
|
||
*/
|
||
export declare class UpdatePreferencesResp {
|
||
[key: string]: any;
|
||
/**
|
||
* 偏好酒类ID列表
|
||
*/
|
||
favoriteCategories: Array<Category>;
|
||
/**
|
||
* 饮酒频率
|
||
*/
|
||
frequency: Frequency;
|
||
|
||
/**
|
||
* @param favoriteCategories Array<Category> 偏好酒类ID列表
|
||
* @param frequency Frequency 饮酒频率
|
||
*/
|
||
constructor(favoriteCategories: Array<Category>,frequency: Frequency,);
|
||
/**
|
||
* 从对象创建 UpdatePreferencesResp
|
||
*
|
||
* @param o Object
|
||
* - favoriteCategories: Array<Category>, // 偏好酒类ID列表
|
||
* - frequency: Frequency, // 饮酒频率
|
||
*/
|
||
static fromObject(o: Object): UpdatePreferencesResp;
|
||
}
|
||
|
||
/**
|
||
* 上传图片参数
|
||
*/
|
||
export declare class UploadImageReq {
|
||
[key: string]: any;
|
||
/**
|
||
* 图片
|
||
*/
|
||
image: any;
|
||
|
||
/**
|
||
* @param image any 图片
|
||
*/
|
||
constructor(image: any,);
|
||
/**
|
||
* 从对象创建 UploadImageReq
|
||
*
|
||
* @param o Object
|
||
* - image: any, // 图片
|
||
*/
|
||
static fromObject(o: Object): UploadImageReq;
|
||
}
|
||
|
||
/**
|
||
* 上传图片返回
|
||
*/
|
||
export declare class UploadImageResp {
|
||
[key: string]: any;
|
||
/**
|
||
* 图片 id
|
||
*/
|
||
id: string|number;
|
||
/**
|
||
* 图片 url
|
||
*/
|
||
url: string;
|
||
|
||
/**
|
||
* @param id string|number 图片 id
|
||
* @param url string 图片 url
|
||
*/
|
||
constructor(id: string|number,url: string,);
|
||
/**
|
||
* 从对象创建 UploadImageResp
|
||
*
|
||
* @param o Object
|
||
* - id: string|number, // 图片 id
|
||
* - url: string, // 图片 url
|
||
*/
|
||
static fromObject(o: Object): UploadImageResp;
|
||
}
|
||
|
||
/**
|
||
* 引用文件参数
|
||
*/
|
||
export declare class ReferenceFileReq {
|
||
[key: string]: any;
|
||
/**
|
||
* 项目名称
|
||
*/
|
||
project: string;
|
||
/**
|
||
* 模块名称
|
||
*/
|
||
module: string;
|
||
/**
|
||
* 数据 id
|
||
*/
|
||
data: number;
|
||
/**
|
||
* 文件 urls
|
||
*/
|
||
urls: Array<string>;
|
||
|
||
/**
|
||
* @param project string 项目名称
|
||
* @param module string 模块名称
|
||
* @param data number 数据 id
|
||
* @param urls Array<string> 文件 urls
|
||
*/
|
||
constructor(project: string,module: string,data: number,urls: Array<string>,);
|
||
/**
|
||
* 从对象创建 ReferenceFileReq
|
||
*
|
||
* @param o Object
|
||
* - project: string, // 项目名称
|
||
* - module: string, // 模块名称
|
||
* - data: number, // 数据 id
|
||
* - urls: Array<string>, // 文件 urls
|
||
*/
|
||
static fromObject(o: Object): ReferenceFileReq;
|
||
}
|
||
|
||
/**
|
||
* 引用文件返回
|
||
*/
|
||
export declare class ReferenceFileResp {
|
||
[key: string]: any;
|
||
/**
|
||
* 是否成功
|
||
*/
|
||
ok: boolean;
|
||
|
||
/**
|
||
* @param ok boolean 是否成功
|
||
*/
|
||
constructor(ok: boolean,);
|
||
/**
|
||
* 从对象创建 ReferenceFileResp
|
||
*
|
||
* @param o Object
|
||
* - ok: boolean, // 是否成功
|
||
*/
|
||
static fromObject(o: Object): ReferenceFileResp;
|
||
}
|
||
|
||
/**
|
||
* 取消引用文件参数
|
||
*/
|
||
export declare class DereferenceFileReq {
|
||
[key: string]: any;
|
||
/**
|
||
* 模块
|
||
*/
|
||
module: string;
|
||
/**
|
||
* 数据 id
|
||
*/
|
||
data: number;
|
||
/**
|
||
* 文件 urls
|
||
*/
|
||
urls: Array<string>;
|
||
|
||
/**
|
||
* @param module string 模块
|
||
* @param data number 数据 id
|
||
* @param urls Array<string> 文件 urls
|
||
*/
|
||
constructor(module: string,data: number,urls: Array<string>,);
|
||
/**
|
||
* 从对象创建 DereferenceFileReq
|
||
*
|
||
* @param o Object
|
||
* - module: string, // 模块
|
||
* - data: number, // 数据 id
|
||
* - urls: Array<string>, // 文件 urls
|
||
*/
|
||
static fromObject(o: Object): DereferenceFileReq;
|
||
}
|
||
|
||
/**
|
||
* 取消引用文件返回
|
||
*/
|
||
export declare class DereferenceFileResp {
|
||
[key: string]: any;
|
||
/**
|
||
* 是否成功
|
||
*/
|
||
ok: boolean;
|
||
|
||
/**
|
||
* @param ok boolean 是否成功
|
||
*/
|
||
constructor(ok: boolean,);
|
||
/**
|
||
* 从对象创建 DereferenceFileResp
|
||
*
|
||
* @param o Object
|
||
* - ok: boolean, // 是否成功
|
||
*/
|
||
static fromObject(o: Object): DereferenceFileResp;
|
||
}
|
||
|
||
/**
|
||
* 删除数据参数
|
||
*/
|
||
export declare class DeleteDataReq {
|
||
[key: string]: any;
|
||
/**
|
||
* 模块
|
||
*/
|
||
module: string;
|
||
/**
|
||
* 数据 id
|
||
*/
|
||
data: number;
|
||
|
||
/**
|
||
* @param module string 模块
|
||
* @param data number 数据 id
|
||
*/
|
||
constructor(module: string,data: number,);
|
||
/**
|
||
* 从对象创建 DeleteDataReq
|
||
*
|
||
* @param o Object
|
||
* - module: string, // 模块
|
||
* - data: number, // 数据 id
|
||
*/
|
||
static fromObject(o: Object): DeleteDataReq;
|
||
}
|
||
|
||
/**
|
||
* 删除数据返回
|
||
*/
|
||
export declare class DeleteDataResp {
|
||
[key: string]: any;
|
||
/**
|
||
* 是否成功
|
||
*/
|
||
ok: boolean;
|
||
|
||
/**
|
||
* @param ok boolean 是否成功
|
||
*/
|
||
constructor(ok: boolean,);
|
||
/**
|
||
* 从对象创建 DeleteDataResp
|
||
*
|
||
* @param o Object
|
||
* - ok: boolean, // 是否成功
|
||
*/
|
||
static fromObject(o: Object): DeleteDataResp;
|
||
}
|
||
|
||
|
||
|
||
/**
|
||
* * 喝酒了么 - 后端接口 API
|
||
* 小程序:喝酒了么(uni-app 微信小程序)
|
||
* 基础URL: /api/v1
|
||
*
|
||
* 主要功能模块:
|
||
* 1. 用户模块 - 微信登录、用户信息管理
|
||
* 2. 打卡记录模块 - 饮酒记录创建、查询、日历数据
|
||
* 3. 照片上传模块 - 单张/批量照片上传
|
||
* 4. 统计模块 - 用户统计、月度统计、酒类分布
|
||
* 5. 成就模块 - 成就列表和进度
|
||
* 6. 社交模块 - 朋友圈动态、点赞
|
||
*/
|
||
export default class HaveADrink {
|
||
host: string;
|
||
http_request: any;
|
||
upload: any;
|
||
constructor(conf: any);
|
||
|
||
/**
|
||
* 设置 token
|
||
*
|
||
* @param token 登录接口获取的 token
|
||
*/
|
||
public setToken(token: string): void;
|
||
|
||
/**
|
||
* 微信登录, 获取openid、unionid、token
|
||
*
|
||
* @param req WechatLoginReq 微信登录请求参数
|
||
* @return WechatLoginResp 微信登录返回值
|
||
*/
|
||
public WechatLogin(req: WechatLoginReq) : Promise<WechatLoginResp>;
|
||
|
||
/**
|
||
* 获取微信手机号
|
||
*
|
||
* @param req WechatGetPhoneNumberReq 获取微信手机号
|
||
* @return WechatGetPhoneNumberResp 获取微信手机号返回值
|
||
*/
|
||
public WechatGetPhoneNumber(req: WechatGetPhoneNumberReq) : Promise<WechatGetPhoneNumberResp>;
|
||
|
||
/**
|
||
* 刷新 token 接口
|
||
*
|
||
* @param req RefreshTokenReq 刷新token请求参数
|
||
* @return RefreshTokenResp 刷新 token 返回值
|
||
*/
|
||
public RefreshToken(req: RefreshTokenReq) : Promise<RefreshTokenResp>;
|
||
|
||
/**
|
||
* 获取成就列表
|
||
*
|
||
* @param req GetAchievementsReq
|
||
* @return GetAchievementsResp 获取成就列表响应
|
||
*/
|
||
public GetAchievements(req: GetAchievementsReq) : Promise<GetAchievementsResp>;
|
||
|
||
/**
|
||
* 获取朋友圈动态
|
||
*
|
||
* @param req GetFeedReq 获取朋友圈动态请求
|
||
* @return GetFeedResp 获取朋友圈动态响应
|
||
*/
|
||
public GetFeed(req: GetFeedReq) : Promise<GetFeedResp>;
|
||
|
||
/**
|
||
* 点赞
|
||
*
|
||
* @param req LikeRecordReq 点赞/取消点赞请求
|
||
* @return LikeRecordResp 点赞/取消点赞响应
|
||
*/
|
||
public LikeRecord(req: LikeRecordReq) : Promise<LikeRecordResp>;
|
||
|
||
/**
|
||
* 取消点赞
|
||
*
|
||
* @param req LikeRecordReq 点赞/取消点赞请求
|
||
* @return LikeRecordResp 点赞/取消点赞响应
|
||
*/
|
||
public UnlikeRecord(req: LikeRecordReq) : Promise<LikeRecordResp>;
|
||
|
||
/**
|
||
* 上传照片
|
||
*
|
||
* @param req UploadPhotoReq 上传照片请求
|
||
* @return UploadPhotoResp 上传照片响应
|
||
*/
|
||
public UploadPhoto(req: UploadPhotoReq) : Promise<UploadPhotoResp>;
|
||
|
||
/**
|
||
* 批量上传照片
|
||
*
|
||
* @param req UploadPhotosReq 批量上传照片请求
|
||
* @return UploadPhotosResp 批量上传照片响应
|
||
*/
|
||
public UploadPhotos(req: UploadPhotosReq) : Promise<UploadPhotosResp>;
|
||
|
||
/**
|
||
* 创建打卡记录
|
||
*
|
||
* @param req CreateRecordReq 创建打卡记录请求
|
||
* @return CreateRecordResp 创建打卡记录响应
|
||
*/
|
||
public CreateRecord(req: CreateRecordReq) : Promise<CreateRecordResp>;
|
||
|
||
/**
|
||
* 获取记录列表
|
||
*
|
||
* @param req GetRecordsReq 获取记录列表请求
|
||
* @return GetRecordsResp 获取记录列表响应
|
||
*/
|
||
public GetRecords(req: GetRecordsReq) : Promise<GetRecordsResp>;
|
||
|
||
/**
|
||
* 获取单条记录详情
|
||
*
|
||
* @param req GetRecordDetailReq 获取单条记录详情请求
|
||
* @return GetRecordDetailResp 获取单条记录详情响应
|
||
*/
|
||
public GetRecordDetail(req: GetRecordDetailReq) : Promise<GetRecordDetailResp>;
|
||
|
||
/**
|
||
* 删除记录
|
||
*
|
||
* @param req DeleteRecordReq 删除记录请求
|
||
* @return DeleteRecordResp 删除记录响应
|
||
*/
|
||
public DeleteRecord(req: DeleteRecordReq) : Promise<DeleteRecordResp>;
|
||
|
||
/**
|
||
* 获取日历打卡数据
|
||
*
|
||
* @param req GetCalendarReq 获取日历打卡数据请求
|
||
* @return GetCalendarResp 获取日历打卡数据响应
|
||
*/
|
||
public GetCalendar(req: GetCalendarReq) : Promise<GetCalendarResp>;
|
||
|
||
/**
|
||
* 获取用户统计概览
|
||
*
|
||
* @param req GetStatsOverviewReq
|
||
* @return GetStatsOverviewResp 获取用户统计概览响应
|
||
*/
|
||
public GetStatsOverview(req: GetStatsOverviewReq) : Promise<GetStatsOverviewResp>;
|
||
|
||
/**
|
||
* 获取月度统计
|
||
*
|
||
* @param req GetMonthlyStatsReq 获取月度统计请求
|
||
* @return GetMonthlyStatsResp 获取月度统计响应
|
||
*/
|
||
public GetMonthlyStats(req: GetMonthlyStatsReq) : Promise<GetMonthlyStatsResp>;
|
||
|
||
/**
|
||
* 获取酒类分布统计
|
||
*
|
||
* @param req GetCategoryStatsReq
|
||
* @return GetCategoryStatsResp 获取酒类分布统计响应
|
||
*/
|
||
public GetCategoryStats(req: GetCategoryStatsReq) : Promise<GetCategoryStatsResp>;
|
||
|
||
/**
|
||
* 获取用户信息
|
||
*
|
||
* @param req GetUserProfileReq 获取用户信息请求
|
||
* @return GetUserProfileResp 获取用户信息响应
|
||
*/
|
||
public GetUserProfile(req: GetUserProfileReq) : Promise<GetUserProfileResp>;
|
||
|
||
/**
|
||
* 更新用户偏好
|
||
*
|
||
* @param req UpdatePreferencesReq 更新用户偏好请求
|
||
* @return UpdatePreferencesResp 更新用户偏好响应
|
||
*/
|
||
public UpdatePreferences(req: UpdatePreferencesReq) : Promise<UpdatePreferencesResp>;
|
||
|
||
/**
|
||
* 上传文件
|
||
*
|
||
* @param req UploadImageReq 上传图片参数
|
||
* @return UploadImageResp 上传图片返回
|
||
*/
|
||
public UploadImage(req: UploadImageReq) : Promise<UploadImageResp>;
|
||
|
||
}
|