import Header from '@/components/header/index.vue';
import Tabs from '@/components/tabs/index.vue';

import Left11 from './comps/left/top/1/index.vue';
import Left21 from './comps/left/middle/1/index.vue';
import Left31 from './comps/left/bottom/1/index.vue';
import Right11 from './comps/right/top/1/index.vue';
import Right21 from './comps/right/middle/1/index.vue';
import Right31 from './comps/right/bottom/1/index.vue';
import Bottom1 from './comps/buttom/1/index.vue';

import Left12 from './comps/left/top/2/index.vue';
import Left22 from './comps/left/middle/2/index.vue';
import Left32 from './comps/left/bottom/2/index.vue';
import Right12 from './comps/right/top/2/index.vue';
import Right22 from './comps/right/middle/2/index.vue';
import Right32 from './comps/right/bottom/2/index.vue';
import Bottom2 from './comps/buttom/2/index.vue';


import Left13 from './comps/left/top/3/index.vue';
import Left23 from './comps/left/middle/3/index.vue';
import Left33 from './comps/left/bottom/3/index.vue';
import Right13 from './comps/right/top/3/index.vue';
import Right23 from './comps/right/middle/3/index.vue';
import Right33 from './comps/right/bottom/3/index.vue';

import Left14 from './comps/left/top/4/index.vue';
import Left24 from './comps/left/middle/4/index.vue';
import Left34 from './comps/left/bottom/4/index.vue';
import Right14 from './comps/right/top/4/index.vue';
import Right24 from './comps/right/middle/4/index.vue';
import Right34 from './comps/right/bottom/4/index.vue'

import { comps } from './data.js'

import GisMap from '@/components/gis-map/index.vue';
import MainGis from './main-gis/index.vue';

import AssetDetails from './asset-details/index.vue';
export default {
  components: {
    Header,
    Tabs,
    Left11,
    Left21,
    Left31,
    Right11,
    Right21,
    Right31,
    Left12,
    Left22,
    Left32,
    Right12,
    Right22,
    Right32,
    Bottom1,
    Left13,
    Left23,
    Left33,
    Right13,
    Right23,
    Right33,
    Bottom2,
    Left14,
    Left24,
    Left34,
    Right14,
    Right24,
    Right34,
    MainGis,
    GisMap,
    AssetDetails
  },
  data () {
    return {
      tabData: [
        {
          id: '1',
          name: '资产分析'
        },
        {
          id: '2',
          name: '债务分析'
        },
        {
          id: '3',
          name: '资产预警'
        },
        {
          id: '4',
          name: '债务预警'
        }
      ],
      tab: '1',
      comps,
      dialogImageUrl: '',
      dialogVisible: false,
      showDetail: false,
      permanentDetail: {},
      permanentType: '1'
    };
  },
  computed: {
    currentComp: function () {
      return this.comps[this.tab]
    }
  },
  methods: {
    tabChange (info) {
      this.tab = info.id;
    },
    openImage (url) {
      console.log(url)
      this.dialogImageUrl = url;
      this.dialogVisible = true;
    },
    clickDetail (val, type) {
      console.log(val + 111111111)
      this.permanentDetail = val;
      this.permanentType = type;
      this.showDetail = true;
    }
  }
};
