zhouwx
2024-07-31 57ffebab5fded6f5236bd1b40c4b4e7a6d4ae07f
驱动下载
已修改2个文件
76 ■■■■ 文件已修改
src/router/index.js 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/Admin/downLoadKey.vue 74 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/router/index.js
@@ -8,7 +8,7 @@
  {
    path: '/',
    name: 'login',
    component: () => import('@/views/Login1'),
    component: () => import('@/views/Login'),
    meta: { title: '登录' },
  },
    {
src/views/Admin/downLoadKey.vue
@@ -10,7 +10,7 @@
      </div>
    </div>
    <div class="box-center">
      <div style="width: 1200px;margin: 30px auto 0;padding: 0 20px 0;" v-for="(item,index) in state.keyTypes" :key="index">
      <div style="width: 1200px;margin: 30px auto 0;padding: 0 20px 0;" v-for="(item,index) in keyTypes" :key="index">
        <div class="title">{{item.name}}</div>
        <a-card style="width: 250px;margin:20px 80px;" hoverable title="">
          <template #extra>
@@ -20,7 +20,7 @@
            <img
                style="width: 120px;height: 120px;margin: 1px auto"
                alt="example"
                :src= keyPic
                src= '@/assets/img/key.png'
            />
          </template>
          <template #actions>
@@ -32,42 +32,42 @@
    </div>
  </div>
</template>
<script setup>
import {reactive} from "vue";
<script>
import { message } from 'ant-design-vue';
import keyPic from '@/assets/img/key.png'
const state = reactive({
  keyTypes: [
    {
      name: 'Windows 版',
      url: 'http://oss.bestong8.com/xinjiang/SetUp.exe'
    },
    {
      name: 'Linux 版',
      url: 'http://oss.bestong8.com/xinjiang/linux.zip'
    },
    {
      name: 'Mac 版',
      url: ''
    },
  ]
})
const downLoad = (item) => {
  if(item.url === ''){
    message.warning( "暂未开放苹果系统应用该加密工具。");
  }else{
    const link = document.createElement('a')
    link.href =item.url
    link.target = '_blank'
    link.download = item.name + '.exe'
    link.click()
  }
}
export default {
  name: "login",
  data() {
    return {
      keyTypes: [
        {
          name: 'Windows 版',
          url: 'http://oss.bestong8.com/xinjiang/SetUp.exe'
        },
        {
          name: 'Linux 版',
          url: 'http://oss.bestong8.com/xinjiang/linux.zip'
        },
        {
          name: 'Mac 版',
          url: ''
        },
      ]
    };
  },
  methods: {
    downLoad (item){
      if(item.url === ''){
        message.warning( "暂未开放苹果系统应用该加密工具。");
      }else{
        const link = document.createElement('a')
        link.href =item.url
        link.target = '_blank'
        link.download = item.name + '.exe'
        link.click()
      }
    }
  },
};
</script>