<template>

    <van-loading size="16px" v-if="isLoading">加载中...</van-loading>
    <div class="main" v-if="!isLoading">
      <div class="banner">
        <h2>扎实提升“三力”</h2>
        <h2>深入推进“三化”</h2>
        <h2>坚持“三个思维”</h2>
      </div>
      <div class="info">
        <p>会议地点：{{ info.placeSelectName }}</p>
        <p>详细地址：{{ info.venueDetailed }}</p>
        <p>会议时间：{{ info.meetingTime }}</p>
        <p>会议场所：{{ info.siteName.name }}</p>
        <p>参会人员：{{ info.participants.name }}</p>
        <p>附&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;件：<span style="color: #6892ff">活动申请书</span></p>
        <p>会议议题：{{ info.meetingTopics }}</p>
      </div>
      <van-button v-if="canAudit" type="primary" class="btn-sub">审核</van-button>
    </div>
  </template>
    
    <script>
  import { ref } from "vue";
  import religiousConferenceService from "@/api/religiousConference/religiousConferenceService";
  import UserManage from "@/api/user/UserManage";
  import { useRoute } from "vue-router";
  export default {
    setup() {
      window.xm.setNavigationBarTitle({ title: '负责人会议详情'})
      let isLoading = ref(true);
      let canAudit = ref(false);
      // 活动信息
      const info = ref({        
      });
      let route = useRoute();
      new religiousConferenceService().queryById(route.query.id).then((data) => {
        info.value = data;
        if(data.assessment=="0"){
          canAudit.value = true;
        }else{
          canAudit.value = false;
        }      

        isLoading.value = false;
      });
      return {
        info,
        isLoading,
        canAudit,
      };
    },
  };
  </script>
    
  <style lang="less">
  .main {
    background: #fff;
    position: relative;
    top: 40px;
  }
  .banner {
    background-color: #36a7f3;
    padding: 20px 50px 40px 50px;
    color: #fff;
    h2 {
      &:nth-child(1) {
        margin-top: 0px;
        text-align: left;
      }
      &:nth-child(2) {
        text-align: center;
      }
      &:nth-child(3) {
        text-align: right;
      }
    }
  }
  .info {
    position: relative;
    width: 86vw;
    margin: 10px auto;
    padding: 10px;
    background: #fff;
    border-radius: 20px;
    top: -50px;
    font-size: 14px;
  }
  .btn-sub {
    width: 90%;
    border-radius: 20px;
    margin-left: 5%;
  }
  .van-loading {
    text-align: center;
    margin-top: 80px;
  }
  </style>