<template>
  <div class="page">
    <div
      class="result"
      v-if="starInfo.code==3003&&starInfo.activity_result&&starInfo.activity_result.result==21">
      <div class="float">结果公示</div>
      <div>
        <h2>恭喜全勤活动审核通过</h2>
        <p>您将获得唱唱启蒙英语“全勤奖学金”</p>
        <!-- <div class="imgbox">
          <img :src="img_pass" alt />
        </div> -->
      </div>
    </div>
    <div
      v-if="starInfo.code==3003&&starInfo.activity_result&&starInfo.activity_result.result==22"
      class="result fal">
      <div class="float">结果公示</div>
      <div>
        <div class="fal_title">很抱歉全勤活动挑战失败</div>
        <div class="fal_tip">学习没有终点，任何时候都是一个起点</div>
      </div>
    </div>
  </div>
</template>

<script>
import rankBg from "../../assets/rankBg.png";
import star_inner from "../../assets/star_inner.png";
import { starPage } from "../../util/imgUrl";
import { getUserIntegralApi, getUserIntegralListApi } from "../../service/api";
import img_pass from "../../assets/star/img_pass@2x.png";
import { Toast } from "vant";
export default {
  name: "starResultV2",
  data() {
    return {
      img_pass:img_pass,
      pullup: true,
      rankBg: rankBg,
      starNum: "",
      userDetail: {},
      loading: true,
      finished: false,
      star_inner: star_inner,
      starList: [],
      page: 1,
      offset: 30,
      starPage: starPage,
      starInfo: {},
      addressObj: false
    };
  },
  components: {},
  methods: {
    initPage() {
      console.log(this.$route.query.starInfo)
      this.starInfo = JSON.parse(decodeURIComponent(this.$route.query.starInfo));
    }
  },
  mounted() {
    this.initPage();
  }
};
</script>

<style scoped lang="less">
@import "../../util/public";
.star-activity-page {
  border-top: 1px solid transparent;
}
.page {
  padding: 10 * @toVw;
  box-sizing: border-box;
}
.result {
  position: relative;
  text-align: center;
  background: url("https://cdn.singsingenglish.com/new-sing/957ce24c07da96d9fa1ef156e700109266494dd3.png");
  background-size: 100% 100%;
  padding: 50 * @toVw 13 * @toVw 150 * @toVw;
  box-shadow: 0px 1 * @toVw 8 * @toVw 0 * @toVw rgba(175, 175, 175, 0.53);
  border-radius: 8 * @toVw;
  margin-bottom: 10 * @toVw;
  background-color: #fff9f2;
  .float {
    width: 74 * @toVw;
    height: 27 * @toVw;
    background: linear-gradient(
      270deg,
      rgba(255, 227, 126, 1) 0%,
      rgba(255, 167, 114, 1) 100%
    );
    border-radius: 0 8 * @toVw 0 8 * @toVw;
    color: white;
    line-height: 27 * @toVw;
    position: absolute;
    top: 0;
    right: 0;
    font-size: 13 * @toVw;
  }
  .imgbox {
    margin-top: 8 * @toVw;
    img {
      width: 111 * @toVw;
      margin: 0 12 * @toVw;
    }
  }
  .addr {
    background: linear-gradient(
      270deg,
      rgba(252, 171, 69, 1) 0%,
      rgba(247, 115, 33, 1) 100%
    );
    border-radius: 12 * @toVw;
    height: 24 * @toVw;
    line-height: 24 * @toVw;
    text-indent: 10 * @toVw;
    color: white;
    font-size: 13 * @toVw;
    margin: 15 * @toVw 0;
    text-align: left;
    display: flex;
    span {
      max-width: 296 * @toVw;
      display: inline-block;
      overflow: hidden;
      text-overflow: ellipsis;
      white-space: nowrap;
    }
    i {
      margin-left: -6 * @toVw;
      width: 20 * @toVw;
      font-size: 12 * @toVw;
    }
  }
  .tip {
    color: #937148;
    font-size: 12 * @toVw;
    text-align: left;
  }
  h2 {
    color: #d33500;
    margin: 0 0 8 * @toVw;
  }
  p {
    color: #f65c28;
  }
}
.fal {
  padding: 39 * @toVw 0 12 * @toVw;
  height: 189 * @toVw;
  background: url("https://cdn.singsingenglish.com/new-sing/number_img_bg_lose@2x.png");
  background-size: 100% 100%;
  box-sizing: border-box;
  .fal_title {
    color: #2a455a;
    font-size: 24 * @toVw;
    font-weight: bold;
  }
  .fal_tip {
    color: #f65c28;
    font-size: 13 * @toVw;
    margin-top: 10 * @toVw;
  }
}
</style>
<style>
</style>
