'use strict';

import React, { Component } from 'react';
import resList from '../../resconfig/resList';

import './comawardp.less';

class Comawardp extends Component {
  constructor(props) {
    super(props);
    this.state = this.state || { resList: resList };
  }
  render() {
    const { onClose, rankPrizeInfo } = this.props;
    console.log('rankPrizeInfo=', rankPrizeInfo);
    /*
    prizeName: "中的奖品"
    prizePic: "http://yun.duiba.com.cn/spark/assets/273d0395e7c858d2fdae770fd3716401e431146d.png"
    prizeUrl: "www.baidu.com"
    rank: 25
    show: true
    */
    return (
      <div className="awardp">
        <img className="rankPrizeBg" />
        <img className="awardbg" src={this.state.resList['ded7851e-6b2e-4fa9-8790-238a0779979e'].url} />
        <label className="prizena">{rankPrizeInfo.prizeName}</label>
        <label className="lastmon">上月排名第{rankPrizeInfo.rank}名</label>
        {/* <img className="awardim" src={this.state.resList['32106cbd-7920-4c6a-8669-83acbedbbed8'].url} /> */}
        <img className="awardim" src={rankPrizeInfo.prizePic} />
        <img className="awardcl" onClick={onClose} src={this.state.resList['c9098829-9dc3-4561-887d-e2a9b3a60e43'].url} />
        <img className="receive"  src={this.state.resList['f67866ee-5b8b-4cbd-bab5-7847e8cfff27'].url} />
      </div>
    );
  }
}
export default Comawardp;
