<template>
  <div class="routerWapper">
    <!-- {{$cookie.get('token')}} -->
    <!-- {{systemList}} -->
    <a-card title="选择登录系统" style="margin: 20px; padding: 20px; height: 100%; border: 2px dashed lightgrey">
      <a-card-grid v-for="(item, index) in systemList" :key="index" style="width:25%;text-align:center; cursor: pointer" @click="loadPage(item)">
        <a-row type='flex' justify='center' align='middle'>
          <a-col :span='16'>
            {{item.name}}
          </a-col>

          <a-col :span='8'>
            <img :src="item.img" alt="" srcset="">
          </a-col>
        </a-row>
      </a-card-grid>
    </a-card>
  </div>
</template>

<script>
export default {
  data() {
    return {
      systemList: [
        {
          name: '业务联动平台',
          url: 'http://kw-linkage.omniview.pro',
          img: require('@/assets/icon/wd-applet-applicants.png'),
          token: ''
        },
        { 
          name: '数据可视化系统 V1.0',
          url: 'https://962121.fgj.sh.gov.cn/wyweb/mngplat/jsp/fxftDirectAccess.jsp?username=18679837182&password=111111a',
          img: require('@/assets/icon/wd-applet-big-data-analytics.png'),
          token: ''
        },
        { 
          name: '物联网传输协议智能转换及智能终端管理平台',
          url: 'https://kewei.omniview.pro/web/#/loginWithoutPwd',
          img: require('@/assets/icon/wd-applet-deployment.png'),
          token: ''
        },
        { 
          name: '知识图谱规则引擎软件 V1.0',
          url: 'http://kw-atlas.omniview.pro/demo?token='+this.$cookie.get('token'),
          img: require('@/assets/icon/wd-applet-rocket.png'),
          token: ''
        }
      ]
    }
  },
  methods: {
    loadPage(webInfo) {
      window.open(webInfo.url)
    }
  },
}
</script>