import { PageQueryParam, PageResult } from "../base";

/**
 * 邀请记录请求参数
 */
export interface RecordQueryParam extends PageQueryParam {
    realName?: string;
    mobilePhone?: string;
    email?: string;
    property?: string | null;
    direction?: string | null;
    account?: string;
    id?: string;
    username?: string;
    startStatTime?: string;
    endStatTime?: string;
}

/**
 * 邀请记录列表分页列表项
 */
export interface RecordItem {
    id: number;
    username: string;
    promotionCode: string;
    firstLevel: number;
    secondLevel: number;
    thirdLevel: number;
    generalizeTotal: number;
}

/**
 * 邀请记录分页项类型
 */
export type RecordPageResult = PageResult<RecordItem[]>;

/**
 * 直邀列表请求参数
 */
export interface SecondRecordQueryParam {
    pageNumber: number | string;
    pageSize: number | string;
    id: number | string;
    property?: string;
    direction?: string;
}
/**
 * 直邀表分页列表项
 */
export interface SecondRecordItem {
    id: number;
    username: string;
    mobilePhone: string;
    email: string;
    registrationTime: string;
}

/**
 * 直邀分页项类型
 */
export type SecondRecordPageResult = PageResult<SecondRecordItem[]>;

/**
 * 邀请排名请求参数
 */
export interface RankQueryParam extends PageQueryParam {
    mobilePhone?: string;
    rankType?: string;
    property?: string;
    direction?: string;
}

/**
 * 邀请排名列表分页列表项
 */
export interface RankItem {
    id: number;
    memberId: number;
    userIdentify: string;
    levelOne: string;
    levelTwo: string;
    estimatedReward: number;
    extraReward: number;
    stasticDate: string;
}

/**
 * 邀请排名分页项类型
 */
export type RankPageResult = PageResult<RankItem[]>;

/**
 * 更新邀请排名请求参数
 */
export interface AlterRankParam {
    id?: string;
    estimatedReward?: string;
    extraReward?: string;
    levelOne?: string;
    levelTwo?: string;
}

/**
 * 代理商审核列表请求参数
 */
export interface AgentApplyQueryParam extends PageQueryParam {
    keyword?: string;
    auditStatus?: number | '';
}

/**
 * 代理商申请记录
 */
export interface AgentApplyItem {
    id: number;
    memberId: number;
    realName: string;
    phone: string;
    email: string;
    region: string;
    remark: string;
    auditStatus: number;
    rejectReason: string;
    createTime: string;
    updateTime: string;
}

/**
 * 代理商申请分页结果
 */
export type AgentApplyPageResult = PageResult<AgentApplyItem[]>;
