import { Data } from "../../Data";
import { IConsumerData } from "./IConsumerData";
import { IRankData } from "./IRankData";

/**
 *Created by cuiliqiang on 2018/3/1
 * 中奖数据
 */
export class WinRanksData extends Data {
    /**
     * 用户数据
     */
    public consumer: IConsumerData;

    /**
     * 排行列表
     */
    public rankList: IRankData[];

    public update(data: any): void {
        if (!data) {
            return;
        }
        super.update(data);
        this.consumer = data.consumer;
        this.rankList = data.ranks;
    }
}