<template>
  <el-row class="map-warpper" :gutter="16">
    <el-col class="map-left" :span="8">
      <div class="footer-item card-item">
        <TargetBar />
      </div>
    </el-col>
    <el-col :span="16">
      <el-row class="map-right card-item">
        <el-col :span="12">
          <IncomExtendLine
            echartsId="incomExtend"
            echartsTitle="规模以上企业参与军民融合产业活动情况"
            echartsDesText="主营业务收入趋势"
            :cardItems="extendCardItems"
          />
        </el-col>
        <el-col :span="10" :offset="1">
          <IncomDistribution />
        </el-col>
      </el-row>
    </el-col>
  </el-row>

  <!-- foot -->
  <el-row class="footer-warpper" :gutter="16">
    <el-col class="map-right" :span="16">
      <div class="footer-item card-item">
        <BusinessIncome />
      </div>
    </el-col>

    <el-col class="map-left" :span="8">
      <div class="business-extend footer-item card-item">
        <Industrial
          echartsId="industryDistribute"
          echartsTitle="国防科技工业产值规模分布"
          echartsDesText="各市国防科技工业产值规模及增长率"
          :cardItems="industryCardItems"
        />
      </div>
    </el-col>
  </el-row>
</template>
<script lang="ts">
import { defineComponent } from "vue";
import TargetBar from "./model/TargetBar/index.vue";
import IncomExtendLine from "./model/IncomExtendLine/index.vue";
import IncomDistribution from "./model/IncomDistribution/index.vue";
import BusinessIncome from "./model/BusinessIncome/index.vue";
import Industrial from "./model/Industrial/index.vue";

import Mock from "./mock";
import { mapState } from "vuex";

export default defineComponent({
  components: {
    TargetBar,
    IncomExtendLine,
    IncomDistribution,
    BusinessIncome,
    Industrial,
  },
  setup() {},
   computed: {
    ...mapState({
      curDataType: (state) => state.curDataType,
    }),
    industryCardItems() {
      return Mock[this.curDataType].industryCardItems;
    },
    extendCardItems() {
      return Mock[this.curDataType].extendCardItems;
    },
   },
  data() {
    return {
     
    };
  },
});
</script>
<style lang="scss" scoped>
.card-item {
      background-color: rgba(25, 125, 237, 15%);
  border-radius: 5px;
  padding: 16px;
  overflow: hidden;
  cursor: pointer;
  transition: all 0.2s;
  // box-shadow: 2px 2px 10px #eee;
      border: 1px solid #10529a;
  flex: 1;
  height: 100%;
  box-sizing: border-box;
}

.map-warpper {
  box-sizing: border-box;
  .map-right {
    padding-bottom: 0;
  }
}
.footer-warpper {
  margin-top: 20px;
  .business-extend {
    min-height: 430px;
    height: 100%;
  }
}
</style>
