liuyg
2021-12-07 f98f75348627fc5af2faa26ef56dcf0a8bfcb1b6
+加入驱动下载页面
4 files modified
3 files added
312 ■■■■■ changed files
public/pfd/build/generic/web/viewer.js 2 ●●● patch | view | raw | blame | history
src/api/drive/drive.js 13 ●●●●● patch | view | raw | blame | history
src/lang/zh.js 1 ●●●● patch | view | raw | blame | history
src/page/index/top/drive.vue 154 ●●●●● patch | view | raw | blame | history
src/page/index/top/index.vue 14 ●●●●● patch | view | raw | blame | history
src/page/index/top/top-drive.vue 114 ●●●●● patch | view | raw | blame | history
src/router/views/index.js 14 ●●●●● patch | view | raw | blame | history
public/pfd/build/generic/web/viewer.js
@@ -6999,7 +6999,7 @@
  document.getElementById('sidebarToggle').addEventListener('click',
    function () {
      console.log(12345)
      // console.log(12345)
      this.classList.toggle('toggled');
      outerContainer.classList.add('sidebarMoving');
src/api/drive/drive.js
New file
@@ -0,0 +1,13 @@
import request from '@/router/axios';
export const getList = (current, size, params) => {
    return request({
        url: '/api/blade-desk/notice/list',
        method: 'get',
        params: {
            ...params,
            current,
            size,
        }
    })
}
src/lang/zh.js
@@ -102,6 +102,7 @@
    notice: '消息通知',
    theme: '主题',
    userSManual: '用户手册',
    drive: '驱动',
    color: '换色'
  },
  tagsView: {
src/page/index/top/drive.vue
New file
@@ -0,0 +1,154 @@
<template>
  <div class="drive">
    <avue-crud
      :option="option1"
      :table-loading="loading"
      :data="data"
      :page.sync="page"
      v-model="form"
      ref="crud"
      @row-update="rowUpdate"
      @row-del="rowDel"
      @search-change="searchChange"
      @search-reset="searchReset"
      @selection-change="selectionChange"
      @current-change="currentChange"
      @size-change="sizeChange"
      @refresh-change="refreshChange"
      :row-style="rowStyle"
      @on-load="onLoad"
    >
      <template slot-scope="{ type, row }" slot="menu">
        <el-button
          :type="type"
          size="small"
          icon="el-icon-bottom"
          @click="handleCancel(row)"
          >下载
        </el-button>
      </template>
    </avue-crud>
  </div>
</template>
<script>
import { mapGetters } from "vuex";
import { getList } from "@/api/drive/drive";
export default {
  data() {
    return {
      ourdata: [
        // {
        //   calls: "身份证驱动(内含两个安装包)",
        //   links:
        //     "http://223.82.109.183:2081/zhba/upload/20211201/64d8b76f3aecae93e18d015bbca89aba.rar",
        // },
        {
          calls: "JLCertReaderV1.0.1.5.exe",
          zhcalls: "身份证设备识别驱动",
          links:
            "http://223.82.109.183:2081/minio/download/zhba/upload/20211207/JLCertReaderV1.0.1.5.exe?token=",
        },
        {
          calls: "USBDrv3.0-x64.msi",
          zhcalls: "身份证设备USB连接驱动",
          links:
            "http://223.82.109.183:2081/minio/download/zhba/upload/20211207/USBDrv3.0-x64.msi?token=",
        },
        {
          calls: "亚略特CID5000居民身份证指纹采集器安装程序.exe",
          zhcalls: "指纹采集器(安装)程序",
          links:
            "http://223.82.109.183:2081/minio/download/zhba/upload/20211207/%E4%BA%9A%E7%95%A5%E7%89%B9CID5000%E5%B1%85%E6%B0%91%E8%BA%AB%E4%BB%BD%E8%AF%81%E6%8C%87%E7%BA%B9%E9%87%87%E9%9B%86%E5%99%A8%E5%AE%89%E8%A3%85%E7%A8%8B%E5%BA%8F.exe?token=",
        },
        {
          calls: "AratekDMA_Installer_X86_V1.0.8.67(CID).exe",
          zhcalls: "指纹采集器(驱动)程序",
          links:
            "http://223.82.109.183:2081/minio/download/zhba/upload/20211207/AratekDMA_Installer_X86_V1.0.8.67(CID).exe?token=",
        },
      ],
      data: [],
      query: {},
      loading: false,
      page: {
        pageSize: 10,
        currentPage: 1,
        total: 0,
      },
      option1: {
        delBtn: false,
        editBtn: false,
        addBtn: false,
        calcHeight: 260,
        tip: false,
        height: "auto",
        searchShow: true,
        searchMenuSpan: 8,
        labelWidth: 130,
        headerAlign: "center",
        align: "center",
        border: true,
        index: true,
        viewBtn: false,
        selection: true,
        dialogClickModal: false,
        column: [
          {
            label: "驱动名称",
            prop: "zhcalls",
          },
          {
            label: "文件名称",
            prop: "calls",
          },
          {
            label: "驱动链接",
            prop: "links",
          },
        ],
      },
    };
  },
  methods: {
    handleCancel(row) {
      let url = row.links;
      window.open(url, "_self");
    },
    searchChange(params, done) {
      done();
    },
    searchReset() {
      this.query = {};
      this.onLoad(this.page);
    },
    rowDel(row) {},
    rowUpdate(row, index, done, loading) {
      done();
    },
    refreshChange() {
      this.onLoad(this.page, this.query);
    },
    currentChange(currentPage) {
      //分页页码
      this.page.currentPage = currentPage;
      this.refreshChange();
    },
    sizeChange(pageSize) {
      //分页尺寸
      this.page.pageSize = pageSize;
      this.refreshChange();
    },
    onLoad(page, params = {}) {
      this.loading = true;
      // console.log("获取数据");
      this.data = this.ourdata;
      this.loading = false;
    },
  },
};
</script>
<style lang="scss" scoped>
</style>
src/page/index/top/index.vue
@@ -59,6 +59,7 @@
          <top-theme></top-theme>
        </div>
      </el-tooltip> -->
      <!-- 手册 -->
      <el-tooltip
        v-if="showTheme"
        effect="dark"
@@ -67,6 +68,17 @@
      >
        <div class="top-bar__item top-bar__item--show">
          <top-userSManual></top-userSManual>
        </div>
      </el-tooltip>
      <!-- 驱动 -->
      <el-tooltip
        v-if="showTheme"
        effect="dark"
        :content="$t('navbar.drive')"
        placement="bottom"
      >
        <div class="top-bar__item top-bar__item--show">
          <top-drive></top-drive>
        </div>
      </el-tooltip>
      <el-tooltip
@@ -139,6 +151,7 @@
import topNotice from "./top-notice";
import topLang from "./top-lang";
import topUserSManual from "./top-userSManual";
import topDrive from "./top-drive";
export default {
  components: {
@@ -151,6 +164,7 @@
    topNotice,
    topLang,
    topUserSManual,
    topDrive,
  },
  name: "top",
  data() {
src/page/index/top/top-drive.vue
New file
@@ -0,0 +1,114 @@
<template>
  <div>
    <el-dialog title="选择" append-to-body :visible.sync="box" width="50%">
      <el-radio-group v-model="text" class="list">
        <el-row :span="24">
          <el-col
            v-for="(item, index) in list"
            :key="index"
            :md="4"
            :xs="12"
            :sm="4"
          >
            <el-radio :label="item.value">{{ item.name }}</el-radio>
          </el-col>
        </el-row>
      </el-radio-group>
    </el-dialog>
    <span>
      <i class="el-icon-receiving" @click="open" style="font-size: 20px"></i>
    </span>
  </div>
</template>
<script>
import { setTheme } from "@/util/util";
import { mapGetters } from "vuex";
export default {
  data() {
    return {
      box: false,
      text: "",
      list: [
        {
          name: "默认主题",
          value: "default",
        },
        {
          name: "白色主题",
          value: "theme-white",
        },
        {
          name: "黑色主题",
          value: "theme-dark",
        },
        {
          name: "炫彩主题",
          value: "theme-star",
        },
        {
          name: "智能主题",
          value: "theme-bule",
        },
        {
          name: "iview主题",
          value: "theme-iview",
        },
        {
          name: "vip主题",
          value: "theme-vip",
        },
        {
          name: "cool主题",
          value: "theme-cool",
        },
        {
          name: "d2主题",
          value: "theme-d2",
        },
        {
          name: "hey主题",
          value: "theme-hey",
        },
        {
          name: "lte主题",
          value: "theme-lte",
        },
      ],
    };
  },
  watch: {
    text: function (val) {
      this.$store.commit("SET_THEME_NAME", val);
      setTheme(val);
    },
  },
  computed: {
    ...mapGetters(["themeName"]),
  },
  mounted() {
    this.text = this.themeName;
    if (!this.text) {
      this.text = "";
    }
  },
  methods: {
    open() {
      // this.box = true;
      // console.log(123);
      this.$router.push({
        path: "/drive/index",
        // query: { departmentid: val.departmentid },
      });
    },
  },
};
</script>
<style lang="scss" scoped>
.list {
  width: 100%;
}
</style>
src/router/views/index.js
@@ -1020,4 +1020,18 @@
            import( /* webpackChunkName: "views" */ '@/page/index/top/userSManual')
    }]
},
{
    path: '/drive',
    component: Layout,
    redirect: '/drive/index',
    children: [{
        path: 'index',
        name: '驱动',
        meta: {
            i18n: 'index'
        },
        component: () =>
            import( /* webpackChunkName: "views" */ '@/page/index/top/drive')
    }]
},
]