<template>
    <div>
        <el-container>
        <el-aside width="210px" style="overflow:hidden" class="patent-articles-menu">
          <el-menu class="theme-dark" :default-active="activeMenu" @select="handleSelect">
            <el-menu-item v-for="item in reportType==3?menuList:menuList1" :index="item.path" v-if="item.show">
              <i class="el-icon-film"></i>
              <span slot="title">{{item.title}}</span>
            </el-menu-item>
          </el-menu>
        </el-aside>
        <el-container>
          <!-- <el-header></el-header> -->
          <el-main class="admin-main-box">
            <component :is="activeMenu" :row="row" :reportId="reportId" :patentNo="signPatentNo" :signPatentNo="signPatentNo" :reportId2="reportId" :taskId="taskId"></component>
          </el-main>
        </el-container>
      </el-container>
    </div>
</template>

<script>
import BasicInformation from '@/views/report/reportDetails/components/basicMessage.vue';
import ProductMessage from '@/views/report/FTO/FTOPage/components/ProductMessage.vue';
import SignPatent from '@/views/components/articles/components/features.vue';
import ContrastResult from '@/views/report/Invalid/InvalidPage/Result.vue';
import ProductContrastResult from '@/views/report/FTO/FTOPage/components/ProductResult.vue';
export default {
    components:{
        BasicInformation,
        ProductMessage,
        SignPatent,
        ContrastResult,
        ProductContrastResult
    },
    data() {
        return {
            activeMenu: "BasicInformation",
            menuList: [
              { title: '基本信息', path:"BasicInformation",show:true}, 
                { title: '标的产品信息', path:"ProductMessage",show:true}, 
                { title: '对比结果', path:"ProductContrastResult",show:true}, 
            ],
            menuList1: [
              { title: '基本信息', path:"BasicInformation",show:true}, 
                { title: '标的专利特征拆分详情', path:"SignPatent",show:true}, 
                { title: '对比结果', path:"ContrastResult",show:true }
            ],
        }
    },
    computed:{
        dictMessage() {
            return this.$s.getSession('row').dictMessage.REPORT_TYPE
        },
        row(){
            return this.$s.getSession('row')
        },
        reportId(){
            return this.$s.getSession('row').reportId
        },
        taskId(){
            return this.$s.getSession('row').id
        },
        reportType(){
            return this.$s.getSession('row').reportType
        },
        signPatentNo(){
            return this.$s.getSession('row').signPatentNo
        }
    },
    mounted() {
        this.changePageTitle()
    },
    methods: {
        changePageTitle() {
            document.title = `${this.row.reportName} ${'报告详情'}`
        },
        handleSelect(index, path) {
            this.activeMenu = index
        },
    },
}
</script>