liuyg
2021-07-27 3f1a0f246e1de207b6764f7003af4715103a7d93
表格样式  主题默认蓝色
27 files modified
1071 ■■■■■ changed files
src/store/modules/common.js 2 ●●● patch | view | raw | blame | history
src/styles/element-ui.scss 94 ●●●●● patch | view | raw | blame | history
src/views/authority/role.vue 2 ●●● patch | view | raw | blame | history
src/views/desk/notice.vue 2 ●●● patch | view | raw | blame | history
src/views/dispatch/dispatch.vue 1 ●●●● patch | view | raw | blame | history
src/views/dispatch/dispatchChildoperable.vue 7 ●●●● patch | view | raw | blame | history
src/views/recruitmentManagement/index.vue 2 ●●● patch | view | raw | blame | history
src/views/resource/attach.vue 2 ●●● patch | view | raw | blame | history
src/views/resource/oss.vue 190 ●●●●● patch | view | raw | blame | history
src/views/securityEquipment/car.vue 3 ●●●● patch | view | raw | blame | history
src/views/securityEquipment/equipments.vue 3 ●●●● patch | view | raw | blame | history
src/views/securityEquipment/gun.js 11 ●●●●● patch | view | raw | blame | history
src/views/securityEquipment/gun.vue 3 ●●●● patch | view | raw | blame | history
src/views/securityGuard/data.js 4 ●●●● patch | view | raw | blame | history
src/views/securityGuard/securityGuard.vue 3 ●●●● patch | view | raw | blame | history
src/views/securityUnit/data.js 21 ●●●●● patch | view | raw | blame | history
src/views/securityUnit/index.vue 5 ●●●●● patch | view | raw | blame | history
src/views/system/client.vue 170 ●●●●● patch | view | raw | blame | history
src/views/system/dept.vue 2 ●●● patch | view | raw | blame | history
src/views/system/dict.vue 104 ●●●●● patch | view | raw | blame | history
src/views/system/dictbiz.vue 104 ●●●●● patch | view | raw | blame | history
src/views/system/menu.vue 157 ●●●● patch | view | raw | blame | history
src/views/system/topmenu.vue 163 ●●●●● patch | view | raw | blame | history
src/views/trainingRegistration/index.vue 5 ●●●●● patch | view | raw | blame | history
src/views/workreport/data.js 4 ●●●● patch | view | raw | blame | history
src/views/workreport/workreport.vue 6 ●●●● patch | view | raw | blame | history
vue.config.js 1 ●●●● patch | view | raw | blame | history
src/store/modules/common.js
@@ -25,7 +25,7 @@
    showMenu: true,
    showColor: true,
    colorName: getStore({name: 'colorName'}) || '#409EFF',
    themeName: getStore({name: 'themeName'}) || 'theme-default',
    themeName: getStore({ name: 'themeName' }) || 'theme-bule',
    lockPasswd: getStore({name: 'lockPasswd'}) || '',
    website: website,
  },
src/styles/element-ui.scss
@@ -25,7 +25,6 @@
  display: none;
}
.el-message__icon,
.el-message__content {
  display: inline-block;
@@ -49,12 +48,19 @@
  padding: 0 !important;
}
.el-dropdown-menu__item--divided:before, .el-menu, .el-menu--horizontal > .el-menu-item:not(.is-disabled):focus, .el-menu--horizontal > .el-menu-item:not(.is-disabled):hover, .el-menu--horizontal > .el-submenu .el-submenu__title:hover {
.el-dropdown-menu__item--divided:before,
.el-menu,
.el-menu--horizontal > .el-menu-item:not(.is-disabled):focus,
.el-menu--horizontal > .el-menu-item:not(.is-disabled):hover,
.el-menu--horizontal > .el-submenu .el-submenu__title:hover {
  background-color: transparent;
}
.el-dropdown-menu__item--divided:before, .el-menu, .el-menu--horizontal > .el-menu-item:not(.is-disabled):focus, .el-menu--horizontal > .el-menu-item:not(.is-disabled):hover, .el-menu--horizontal > .el-submenu .el-submenu__title:hover {
.el-dropdown-menu__item--divided:before,
.el-menu,
.el-menu--horizontal > .el-menu-item:not(.is-disabled):focus,
.el-menu--horizontal > .el-menu-item:not(.is-disabled):hover,
.el-menu--horizontal > .el-submenu .el-submenu__title:hover {
  background-color: transparent !important;
}
@@ -69,3 +75,83 @@
.el-divider--horizontal {
  margin: 12px 0 !important;
}
//表格斑马纹
.el-table tr:nth-child(2n -1) {
  // background-color: rgba($color: #000000, $alpha: 0.1) !important;
}
//顶部搜索栏
.el-card.is-never-shadow.avue-crud__search {
  position: absolute !important;
  width: calc(100% - 220px) !important;
  z-index: 500 !important;
  border: none !important;
  box-shadow: none !important;
  height: 40px;
}
.desk .el-card.is-never-shadow.avue-crud__search {
  width: calc(100% - 360px) !important;
}
.securityGuard .el-card.is-never-shadow.avue-crud__search {
  width: calc(100% - 300px) !important;
  left: 120px;
}
.securityUnit .el-card.is-never-shadow.avue-crud__search {
  left: 200px;
  width: calc(100% - 380px) !important;
}
.equipments .el-card.is-never-shadow.avue-crud__search {
  width: calc(100% - 380px) !important;
  left: 200px;
}
.dispatch .el-card.is-never-shadow.avue-crud__search {
  width: calc(100% - 380px) !important;
  left: 200px;
}
.dispatchChildoperable .el-card.is-never-shadow.avue-crud__search {
  width: calc(100% - 280px) !important;
  left: 90px;
}
.workreply .el-card.is-never-shadow.avue-crud__search {
  width: calc(100% - 380px) !important;
  left: 200px !important;
}
.recruitmentManagement .el-card.is-never-shadow.avue-crud__search {
  width: calc(100% - 380px) !important;
  left: 200px !important;
}
.hasButOne .el-card.is-never-shadow.avue-crud__search {
  width: calc(100% - 300px) !important;
  left: 120px !important;
}
.hasButTwo .el-card.is-never-shadow.avue-crud__search {
  width: calc(100% - 380px) !important;
  left: 200px !important;
}
.topmenu .el-card.is-never-shadow.avue-crud__search {
  width: calc(100% - 390px) !important;
  left: 220px !important;
}
.hasButThree .el-card.is-never-shadow.avue-crud__search {
  width: calc(100% - 510px) !important;
  left: 310px !important;
}
.avue-form {
  position: relative;
  top: -10px;
}
//顶部按钮栏
.avue-crud__menu {
  height: 60px;
}
//顶部按钮
.avue-crud .avue-crud__left .el-button,
.avue-crud .avue-crud__right .el-button,
.avue-form .avue-crud__left .el-button,
.avue-form .avue-crud__right .el-button {
  position: relative;
  top: 5px;
}
src/views/authority/role.vue
@@ -1,5 +1,5 @@
<template>
  <basic-container>
  <basic-container class="hasButThree">
    <avue-crud
      :option="option"
      :table-loading="loading"
src/views/desk/notice.vue
@@ -1,5 +1,5 @@
<template>
  <basic-container>
  <basic-container class="desk">
    <avue-crud
      :option="option"
      :table-loading="loading"
src/views/dispatch/dispatch.vue
@@ -112,6 +112,7 @@
      option: {
        tip: false,
        // card: true,
        index: true,
        searchSize: "mini",
        searchMenuSpan: 6,
        height: 623,
src/views/dispatch/dispatchChildoperable.vue
@@ -158,7 +158,7 @@
        // addBtn: false,
        // menuWidth: 160,
        align: "center",
        // selection: true,
        selection: true,
        column: [
          // 派遣服务公司登记
          // {
@@ -231,6 +231,11 @@
            labelWidth: 120,
            searchLabelWidth: 120,
            // overHidden: true
            dicUrl: "/api/blade-user/page-security",
            props: {
              label: "name",
              value: "id",
            },
            rules: [
              {
                required: true,
src/views/recruitmentManagement/index.vue
@@ -56,7 +56,7 @@
        viewBtn: true,
        searchSize: "mini",
        searchMenuSpan: 6,
        height: 627,
        height: 693,
        menuWidth: 210,
        align: "center",
        selection: true,
src/views/resource/attach.vue
@@ -1,5 +1,5 @@
<template>
  <basic-container>
  <basic-container class="hasButTwo">
    <avue-crud
      :option="option"
      :table-loading="loading"
src/views/resource/oss.vue
@@ -1,6 +1,7 @@
<template>
  <basic-container>
    <avue-crud :option="option"
  <basic-container class="hasButOne">
    <avue-crud
      :option="option"
               :table-loading="loading"
               :data="data"
               :page.sync="page"
@@ -17,50 +18,69 @@
               @current-change="currentChange"
               @size-change="sizeChange"
               @refresh-change="refreshChange"
               @on-load="onLoad">
      @on-load="onLoad"
    >
      <template slot="menuLeft">
        <el-button type="danger"
        <el-button
          type="danger"
                   size="small"
                   icon="el-icon-delete"
                   plain
                   v-if="permission.oss_delete"
                   @click="handleDelete">删 除
          @click="handleDelete"
          >删 除
        </el-button>
      </template>
      <template slot-scope="scope" slot="menu">
        <el-button type="text"
        <el-button
          type="text"
                   icon="el-icon-video-play"
                   size="small"
                   v-if="userInfo.role_name.includes('admin')"
                   @click="handleDebug(scope.row)">调试
          @click="handleDebug(scope.row)"
          >调试
        </el-button>
        <el-button type="text"
        <el-button
          type="text"
                   icon="el-icon-circle-check"
                   size="small"
                   v-if="permission.oss_enable"
                   @click.stop="handleEnable(scope.row)">启用
          @click.stop="handleEnable(scope.row)"
          >启用
        </el-button>
      </template>
      <template slot-scope="{row}"
                slot="status">
      <template slot-scope="{ row }" slot="status">
        <el-tag>{{row.statusName}}</el-tag>
      </template>
      <template slot-scope="{row}"
                slot="category">
      <template slot-scope="{ row }" slot="category">
        <el-tag>{{row.categoryName}}</el-tag>
      </template>
    </avue-crud>
    <el-dialog title="对象存储上传调试"
    <el-dialog
      title="对象存储上传调试"
               append-to-body
               :visible.sync="box"
               width="550px">
      <avue-form ref="form" :option="debugOption" v-model="debugForm" @submit="handleSubmit"/>
      width="550px"
    >
      <avue-form
        ref="form"
        :option="debugOption"
        v-model="debugForm"
        @submit="handleSubmit"
      />
    </el-dialog>
  </basic-container>
</template>
<script>
  import {getList, getDetail, add, update, remove, enable} from "@/api/resource/oss";
import {
  getList,
  getDetail,
  add,
  update,
  remove,
  enable,
} from "@/api/resource/oss";
  import {mapGetters} from "vuex";
  import func from "@/util/func";
@@ -74,11 +94,11 @@
        page: {
          pageSize: 10,
          currentPage: 1,
          total: 0
        total: 0,
        },
        selectionList: [],
        option: {
          height: 'auto',
        height: "auto",
          calcHeight: 30,
          tip: false,
          searchShow: true,
@@ -103,17 +123,19 @@
              dicUrl: "/api/blade-system/dict/dictionary?code=oss",
              props: {
                label: "dictValue",
                value: "dictKey"
              value: "dictKey",
              },
              dataType: "number",
              slot: true,
              prop: "category",
              search: true,
              rules: [{
            rules: [
              {
                required: true,
                message: "请选择分类",
                trigger: "blur"
              }]
                trigger: "blur",
              },
            ],
            },
            {
              label: "资源编号",
@@ -121,32 +143,38 @@
              span: 24,
              width: 120,
              search: true,
              rules: [{
            rules: [
              {
                required: true,
                message: "请输入资源编号",
                trigger: "blur"
              }]
                trigger: "blur",
              },
            ],
            },
            {
              label: "资源地址",
              prop: "endpoint",
              span: 24,
              rules: [{
            rules: [
              {
                required: true,
                message: "请输入资源地址",
                trigger: "blur"
              }]
                trigger: "blur",
              },
            ],
            },
            {
              label: "空间名",
              prop: "bucketName",
              span: 24,
              width: 120,
              rules: [{
            rules: [
              {
                required: true,
                message: "请输入空间名",
                trigger: "blur"
              }]
                trigger: "blur",
              },
            ],
            },
            {
              label: "accessKey",
@@ -155,11 +183,13 @@
              search: true,
              width: 200,
              overHidden: true,
              rules: [{
            rules: [
              {
                required: true,
                message: "请输入accessKey",
                trigger: "blur"
              }]
                trigger: "blur",
              },
            ],
            },
            {
              label: "secretKey",
@@ -167,11 +197,13 @@
              span: 24,
              width: 200,
              overHidden: true,
              rules: [{
            rules: [
              {
                required: true,
                message: "请输入secretKey",
                trigger: "blur"
              }]
                trigger: "blur",
              },
            ],
            },
            {
              label: "appId",
@@ -204,11 +236,11 @@
              span: 24,
              hide: true,
            },
          ]
        ],
        },
        data: [],
        debugForm: {
          code: '',
        code: "",
        },
        debugOption: {
          submitText: "提交",
@@ -222,23 +254,23 @@
            {
              label: "上传背景",
              prop: "backgroundUrl",
              type: 'upload',
              listType: 'picture-img',
              action: '/api/blade-resource/oss/endpoint/put-file',
            type: "upload",
            listType: "picture-img",
            action: "/api/blade-resource/oss/endpoint/put-file",
              propsHttp: {
                res: 'data',
                url: 'link',
              res: "data",
              url: "link",
              },
              span: 24,
            },
          ]
        }
        ],
      },
      };
    },
    watch: {
      'form.category'() {
    "form.category"() {
        const category = func.toInt(this.form.category);
        this.$refs.crud.option.column.filter(item => {
      this.$refs.crud.option.column.filter((item) => {
          if (item.prop === "appId") {
            item.display = category === 4;
          }
@@ -247,10 +279,10 @@
          }
        });
      },
      'debugForm.code'() {
    "debugForm.code"() {
        const column = this.findObject(this.debugOption.column, "backgroundUrl");
        column.action = `/api/blade-resource/oss/endpoint/put-file?code=${this.debugForm.code}`;
      }
    },
    },
    computed: {
      ...mapGetters(["userInfo", "permission"]),
@@ -259,49 +291,55 @@
          addBtn: this.vaildData(this.permission.oss_add),
          viewBtn: this.vaildData(this.permission.oss_view),
          delBtn: this.vaildData(this.permission.oss_delete),
          editBtn: this.vaildData(this.permission.oss_edit)
        editBtn: this.vaildData(this.permission.oss_edit),
        };
      },
      ids() {
        let ids = [];
        this.selectionList.forEach(ele => {
      this.selectionList.forEach((ele) => {
          ids.push(ele.id);
        });
        return ids.join(",");
      }
    },
    },
    methods: {
      rowSave(row, done, loading) {
        add(row).then(() => {
      add(row).then(
        () => {
          this.onLoad(this.page);
          this.$message({
            type: "success",
            message: "操作成功!"
            message: "操作成功!",
          });
          done();
        }, error => {
        },
        (error) => {
          window.console.log(error);
          loading();
        });
        }
      );
      },
      rowUpdate(row, index, done, loading) {
        update(row).then(() => {
      update(row).then(
        () => {
          this.onLoad(this.page);
          this.$message({
            type: "success",
            message: "操作成功!"
            message: "操作成功!",
          });
          done();
        }, error => {
        },
        (error) => {
          window.console.log(error);
          loading();
        });
        }
      );
      },
      rowDel(row) {
        this.$confirm("确定将选择数据删除?", {
          confirmButtonText: "确定",
          cancelButtonText: "取消",
          type: "warning"
        type: "warning",
        })
          .then(() => {
            return remove(row.id);
@@ -310,7 +348,7 @@
            this.onLoad(this.page);
            this.$message({
              type: "success",
              message: "操作成功!"
            message: "操作成功!",
            });
          });
      },
@@ -335,7 +373,7 @@
        this.$confirm("是否确定启用这条配置?", {
          confirmButtonText: "确定",
          cancelButtonText: "取消",
          type: "warning"
        type: "warning",
        })
          .then(() => {
            return enable(row.id);
@@ -344,7 +382,7 @@
            this.onLoad(this.page);
            this.$message({
              type: "success",
              message: "操作成功!"
            message: "操作成功!",
            });
            this.$refs.crud.toggleSelection();
          });
@@ -352,12 +390,12 @@
      handleDebug(row) {
        this.box = true;
        this.debugForm.code = row.ossCode;
        this.debugForm.backgroundUrl = '';
      this.debugForm.backgroundUrl = "";
      },
      handleSubmit(form, done) {
        this.$message({
          type: "success",
          message: `获取到图片地址:[${form.backgroundUrl}]`
        message: `获取到图片地址:[${form.backgroundUrl}]`,
        });
        done();
      },
@@ -369,7 +407,7 @@
        this.$confirm("确定将选择数据删除?", {
          confirmButtonText: "确定",
          cancelButtonText: "取消",
          type: "warning"
        type: "warning",
        })
          .then(() => {
            return remove(this.ids);
@@ -378,14 +416,14 @@
            this.onLoad(this.page);
            this.$message({
              type: "success",
              message: "操作成功!"
            message: "操作成功!",
            });
            this.$refs.crud.toggleSelection();
          });
      },
      beforeOpen(done, type) {
        if (["edit", "view"].includes(type)) {
          getDetail(this.form.id).then(res => {
        getDetail(this.form.id).then((res) => {
            this.form = res.data.data;
          });
        }
@@ -402,14 +440,18 @@
      },
      onLoad(page, params = {}) {
        this.loading = true;
        getList(page.currentPage, page.pageSize, Object.assign(params, this.query)).then(res => {
      getList(
        page.currentPage,
        page.pageSize,
        Object.assign(params, this.query)
      ).then((res) => {
          const data = res.data.data;
          this.page.total = data.total;
          this.data = data.records;
          this.loading = false;
          this.selectionClear();
        });
      }
    }
    },
  },
  };
</script>
src/views/securityEquipment/car.vue
@@ -48,9 +48,10 @@
      option: {
        // card: true,
        tip: false,
        index: true,
        searchSize: "mini",
        searchMenuSpan: 6,
        height: 627,
        height: 693,
        menuWidth: 160,
        align: "center",
        selection: true,
src/views/securityEquipment/equipments.vue
@@ -50,7 +50,8 @@
        tip: false,
        searchSize: "mini",
        searchMenuSpan: 6,
        height: 627,
        height: 693,
        index: true,
        menuWidth: 160,
        align: "center",
        selection: true,
src/views/securityEquipment/gun.js
@@ -14,11 +14,13 @@
        prop: "id",
        hide: true,
        editDisplay: false,
        addDisplay: false
        addDisplay: false,
        labelWidth: 160,
    },
    {
        label: "公务用枪证编号",
        prop: "gunCardNumber",
        labelWidth: 160,
        searchLabelWidth: 130,
        search: true,
        rules: [{
@@ -30,6 +32,7 @@
    {
        label: "发证单位名称",
        searchLabelWidth: 110,
        labelWidth: 160,
        prop: "issueUnit",
        rules: [{
            required: true,
@@ -41,6 +44,7 @@
    {
        label: "公务用枪编号",
        prop: "cardNumber",
        labelWidth: 160,
        searchLabelWidth: 110,
        rules: [{
            required: true,
@@ -53,6 +57,7 @@
        label: "枪型",
        prop: "gunMode",
        width: 70,
        labelWidth: 160,
        rules: [{
            required: true,
            message: "请输入枪型",
@@ -63,6 +68,7 @@
    {
        label: "保安公司",
        prop: "tenantName",
        labelWidth: 160,
        rules: [{
            required: true,
            message: "请输入组织机构",
@@ -89,6 +95,7 @@
    {
        label: "责任人",
        prop: "personInCharge",
        labelWidth: 160,
        rules: [{
            required: true,
            message: "请输入责任人",
@@ -97,6 +104,7 @@
    },
    {
        label: "发证日期",
        labelWidth: 160,
        prop: "issueTime",
        // search: true,
        type: "date",
@@ -114,6 +122,7 @@
    {
        label: "有效日期",
        prop: "validTime",
        labelWidth: 160,
        // search: true,
        type: "date",
        format: "yyyy-MM-dd",
src/views/securityEquipment/gun.vue
@@ -50,7 +50,8 @@
        tip: false,
        searchSize: "mini",
        searchMenuSpan: 6,
        height: 627,
        height: 693,
        index: true,
        menuWidth: 160,
        align: "center",
        selection: true,
src/views/securityGuard/data.js
@@ -532,7 +532,7 @@
            value: "id",
        },
        slot: true,
        searchSpan: 5,
    searchSpan: 6,
        display: false,
        search: true,
        width: 260
@@ -584,7 +584,7 @@
        },
        dataType: "number",
        display: false,
        searchSpan: 3,
    searchSpan: 4,
        search: true,
        rules: [{
            required: true,
src/views/securityGuard/securityGuard.vue
@@ -1,5 +1,5 @@
<template>
  <el-row>
  <el-row class="securityGuard">
    <el-col :span="0" style="display: none">
      <div class="box">
        <el-scrollbar>
@@ -322,6 +322,7 @@
        searchMenuSpan: 6,
        border: false,
        stripe: true,
        align: "center",
        index: true,
        delBtnText: "注销",
        selection: true,
src/views/securityUnit/data.js
@@ -21,6 +21,8 @@
        prop: "creditcode",
        width: 140,
        hide: true,
        labelWidth: 160,
        // hide: true,
        // editDisplay: false,
        // addDisplay: false
@@ -55,12 +57,15 @@
        label: "企业名称",
        prop: "enterprisename",
        search: true,
        searchSpan: 6,
        labelWidth: 160,
        // width: 130,
    },
    {
        label: "企业类型",
        prop: "stats",
        type: "tree",
        labelWidth: 160,
        dicUrl: "/api/blade-system/dict-biz/dictionary?code=stats",
        props: {
            label: "dictValue",
@@ -77,10 +82,11 @@
    },
    {
        label: "法定代表人",
        labelWidth: 160,
        prop: "representative",
        width: 80,
        search: true,
        searchSpan: 5,
        searchSpan: 6,
        searchLabelWidth: 100
    },
    // {
@@ -106,6 +112,7 @@
    {
        label: "成立日期",
        prop: "establishtime",
        labelWidth: 160,
        width: 130,
        overHidden: true,
        type: "date",
@@ -131,6 +138,7 @@
    {
        label: "注册资本(万元人民币)",
        prop: "registeredcapital",
        labelWidth: 160,
        // search: true,
        width: 140,
        // overHidden: true
@@ -138,6 +146,7 @@
    {
        label: "实缴资本(万元人民币)",
        prop: "capital",
        labelWidth: 160,
        // width: 85,
        hide: true,
        // search: true,
@@ -146,6 +155,7 @@
    },
    {
        label: "组织机构代码",
        labelWidth: 160,
        prop: "organizationcode",
        // width: 110,
        // search: true,
@@ -154,6 +164,7 @@
    {
        label: "工商注册号",
        prop: "registrationnumber",
        labelWidth: 160,
        width: 120,
        // search: true,
        // searchSpan: 4,
@@ -161,6 +172,7 @@
    {
        label: "纳税人识别号",
        prop: "identificationnumber",
        labelWidth: 160,
        width: 140,
        // addDisplay: true,
        // editDisplay: true,
@@ -203,6 +215,7 @@
    {
        label: "注册地址",
        prop: "address",
        labelWidth: 160,
        // search: true,
        hide: true,
    },
@@ -210,6 +223,7 @@
        label: "经营范围",
        prop: "business",
        // search: true,
        labelWidth: 160,
        hide: true,
        // width: 110,
        overHidden: true
@@ -217,6 +231,7 @@
    {
        label: "所属地区",
        prop: "region",
        labelWidth: 160,
        // width: 110,
        // search: true,
        overHidden: true
@@ -225,6 +240,7 @@
        label: "登记机关",
        prop: "registration",
        // search: true,
        labelWidth: 160,
        // width: 88,
        overHidden: true,
        hide: true,
@@ -233,6 +249,7 @@
    {
        label: "所属行业",
        prop: "industry",
        labelWidth: 160,
        hide: true,
        // search: true,
        // width: 88,
@@ -280,7 +297,7 @@
    },
    {
        label: "辖区",
        prop: "departmentid",
        prop: "jurisdiction",
        // type: "tree",
        // disabled: true,
        type: "tree",
src/views/securityUnit/index.vue
@@ -212,12 +212,13 @@
      query: {},
      data: [],
      option: {
        index: true,
        addBtn: false,
        // card: true,
        tip: false,
        searchSize: "mini",
        searchMenuSpan: 6,
        height: 623,
        height: 693,
        menuWidth: 160,
        align: "center",
        selection: true,
@@ -421,7 +422,7 @@
          }
        }
      }
      // console.log(d);
      console.log(d);
      for (var k in d) {
        if (d[k] == "" || d[k] == undefined) {
          console.log(k);
src/views/system/client.vue
@@ -1,6 +1,7 @@
<template>
  <basic-container>
    <avue-crud :option="option"
  <basic-container class="hasButOne">
    <avue-crud
      :option="option"
               :table-loading="loading"
               :data="data"
               :page.sync="page"
@@ -17,14 +18,17 @@
               @current-change="currentChange"
               @size-change="sizeChange"
               @refresh-change="refreshChange"
               @on-load="onLoad">
      @on-load="onLoad"
    >
      <template slot="menuLeft">
        <el-button type="danger"
        <el-button
          type="danger"
                   size="small"
                   icon="el-icon-delete"
                   plain
                   v-if="permission.client_delete"
                   @click="handleDelete">删 除
          @click="handleDelete"
          >删 除
        </el-button>
      </template>
    </avue-crud>
@@ -44,11 +48,11 @@
        page: {
          pageSize: 10,
          currentPage: 1,
          total: 0
        total: 0,
        },
        selectionList: [],
        option: {
          height: 'auto',
        height: "auto",
          calcHeight: 30,
          tip: false,
          searchShow: true,
@@ -63,21 +67,25 @@
              label: "应用id",
              prop: "clientId",
              search: true,
              rules: [{
            rules: [
              {
                required: true,
                message: "请输入客户端id",
                trigger: "blur"
              }]
                trigger: "blur",
              },
            ],
            },
            {
              label: "应用密钥",
              prop: "clientSecret",
              search: true,
              rules: [{
            rules: [
              {
                required: true,
                message: "请输入客户端密钥",
                trigger: "blur"
              }]
                trigger: "blur",
              },
            ],
            },
            {
              label: "授权类型",
@@ -87,51 +95,57 @@
              dicData: [
                {
                  label: "refresh_token",
                  value: "refresh_token"
                value: "refresh_token",
                },
                {
                  label: "password",
                  value: "password"
                value: "password",
                },
                {
                  label: "authorization_code",
                  value: "authorization_code"
                value: "authorization_code",
                },
                {
                  label: "captcha",
                  value: "captcha"
                value: "captcha",
                },
                {
                  label: "social",
                  value: "social"
                }
                value: "social",
              },
              ],
              rules: [{
            rules: [
              {
                required: true,
                message: "请输入授权类型",
                trigger: "blur"
              }]
                trigger: "blur",
              },
            ],
            },
            {
              label: "授权范围",
              prop: "scope",
              value: "all",
              rules: [{
            rules: [
              {
                required: true,
                message: "请输入授权范围",
                trigger: "blur"
              }]
                trigger: "blur",
              },
            ],
            },
            {
              label: "令牌秒数",
              prop: "accessTokenValidity",
              type: "number",
              value: 3600,
              rules: [{
            rules: [
              {
                required: true,
                message: "请输入令牌过期秒数",
                trigger: "blur"
              }]
                trigger: "blur",
              },
            ],
            },
            {
              label: "刷新秒数",
@@ -139,62 +153,74 @@
              type: "number",
              value: 604800,
              hide: true,
              rules: [{
            rules: [
              {
                required: true,
                message: "请输入刷新令牌过期秒数",
                trigger: "blur"
              }]
                trigger: "blur",
              },
            ],
            },
            {
              label: "回调地址",
              prop: "webServerRedirectUri",
              hide: true,
              rules: [{
            rules: [
              {
                required: true,
                message: "请输入回调地址",
                trigger: "blur"
              }]
                trigger: "blur",
              },
            ],
            },
            {
              label: "资源集合",
              prop: "resourceIds",
              hide: true,
              rules: [{
            rules: [
              {
                message: "请输入资源集合",
                trigger: "blur"
              }]
                trigger: "blur",
              },
            ],
            },
            {
              label: "权限",
              prop: "authorities",
              hide: true,
              rules: [{
            rules: [
              {
                message: "请输入权限",
                trigger: "blur"
              }]
                trigger: "blur",
              },
            ],
            },
            {
              label: "自动授权",
              prop: "autoapprove",
              hide: true,
              rules: [{
            rules: [
              {
                message: "请输入自动授权",
                trigger: "blur"
              }]
                trigger: "blur",
              },
            ],
            },
            {
              label: "附加说明",
              hide: true,
              prop: "additionalInformation",
              span: 24,
              rules: [{
            rules: [
              {
                message: "请输入附加说明",
                trigger: "blur"
              }]
                trigger: "blur",
            },
          ]
            ],
        },
        data: []
        ],
      },
      data: [],
      };
    },
    computed: {
@@ -204,49 +230,55 @@
          addBtn: this.vaildData(this.permission.client_add),
          viewBtn: this.vaildData(this.permission.client_view),
          delBtn: this.vaildData(this.permission.client_delete),
          editBtn: this.vaildData(this.permission.client_edit)
        editBtn: this.vaildData(this.permission.client_edit),
        };
      },
      ids() {
        let ids = [];
        this.selectionList.forEach(ele => {
      this.selectionList.forEach((ele) => {
          ids.push(ele.id);
        });
        return ids.join(",");
      }
    },
    },
    methods: {
      rowSave(row, done, loading) {
        add(row).then(() => {
      add(row).then(
        () => {
          this.onLoad(this.page);
          this.$message({
            type: "success",
            message: "操作成功!"
            message: "操作成功!",
          });
          done();
        }, error => {
        },
        (error) => {
          window.console.log(error);
          loading();
        });
        }
      );
      },
      rowUpdate(row, index, done, loading) {
        update(row).then(() => {
      update(row).then(
        () => {
          this.onLoad(this.page);
          this.$message({
            type: "success",
            message: "操作成功!"
            message: "操作成功!",
          });
          done();
        }, error => {
        },
        (error) => {
          window.console.log(error);
          loading();
        });
        }
      );
      },
      rowDel(row) {
        this.$confirm("确定将选择数据删除?", {
          confirmButtonText: "确定",
          cancelButtonText: "取消",
          type: "warning"
        type: "warning",
        })
          .then(() => {
            return remove(row.id);
@@ -255,7 +287,7 @@
            this.onLoad(this.page);
            this.$message({
              type: "success",
              message: "操作成功!"
            message: "操作成功!",
            });
          });
      },
@@ -284,7 +316,7 @@
        this.$confirm("确定将选择数据删除?", {
          confirmButtonText: "确定",
          cancelButtonText: "取消",
          type: "warning"
        type: "warning",
        })
          .then(() => {
            return remove(this.ids);
@@ -293,14 +325,14 @@
            this.onLoad(this.page);
            this.$message({
              type: "success",
              message: "操作成功!"
            message: "操作成功!",
            });
            this.$refs.crud.toggleSelection();
          });
      },
      beforeOpen(done, type) {
        if (["edit", "view"].includes(type)) {
          getDetail(this.form.id).then(res => {
        getDetail(this.form.id).then((res) => {
            this.form = res.data.data;
          });
        }
@@ -317,15 +349,19 @@
      },
      onLoad(page, params = {}) {
        this.loading = true;
        getList(page.currentPage, page.pageSize, Object.assign(params, this.query)).then(res => {
      getList(
        page.currentPage,
        page.pageSize,
        Object.assign(params, this.query)
      ).then((res) => {
          const data = res.data.data;
          this.page.total = data.total;
          this.data = data.records;
          this.loading = false;
          this.selectionClear();
        });
      }
    }
    },
  },
  };
</script>
src/views/system/dept.vue
@@ -1,5 +1,5 @@
<template>
  <basic-container>
  <basic-container class="hasButTwo">
    <avue-crud
      :option="option"
      :table-loading="loading"
src/views/system/dict.vue
@@ -1,5 +1,5 @@
<template>
  <basic-container>
  <basic-container class="hasButTwo">
    <avue-crud
      :option="optionParent"
      :table-loading="loading"
@@ -43,16 +43,20 @@
        </el-button>
      </template>
      <template slot-scope="{row}" slot="code">
        <el-tag @click="handleRowClick(row)" style="cursor:pointer">{{ row.code }}</el-tag>
        <el-tag @click="handleRowClick(row)" style="cursor: pointer">{{
          row.code
        }}</el-tag>
      </template>
      <template slot-scope="{row}" slot="isSealed">
        <el-tag>{{ row.isSealed === 0 ? '否' : '是' }}</el-tag>
        <el-tag>{{ row.isSealed === 0 ? "否" : "是" }}</el-tag>
      </template>
    </avue-crud>
    <el-dialog :title="`[${dictValue}]字典配置`"
    <el-dialog
      :title="`[${dictValue}]字典配置`"
               append-to-body
               :visible.sync="box"
               width="1000px">
      width="1000px"
    >
      <avue-crud
        :option="optionChild"
        :table-loading="loadingChild"
@@ -95,7 +99,7 @@
          </el-button>
        </template>
        <template slot-scope="{row}" slot="isSealed">
          <el-tag>{{ row.isSealed === 0 ? '否' : '是' }}</el-tag>
          <el-tag>{{ row.isSealed === 0 ? "否" : "是" }}</el-tag>
        </template>
      </avue-crud>
    </el-dialog>
@@ -110,7 +114,7 @@
  update,
  add,
  getDict,
  getDictTree
  getDictTree,
} from "@/api/system/dict";
import {optionParent, optionChild} from "@/option/system/dict";
import {mapGetters} from "vuex";
@@ -118,7 +122,7 @@
export default {
  data() {
    return {
      dictValue: '暂无',
      dictValue: "暂无",
      parentId: -1,
      formParent: {},
      formChild: {},
@@ -131,13 +135,13 @@
        pageSize: 10,
        pageSizes: [10, 30, 50, 100, 200],
        currentPage: 1,
        total: 0
        total: 0,
      },
      pageChild: {
        pageSize: 10,
        pageSizes: [10, 30, 50, 100, 200],
        currentPage: 1,
        total: 0
        total: 0,
      },
      dataParent: [],
      dataChild: [],
@@ -157,18 +161,18 @@
    },
    ids() {
      let ids = [];
      this.selectionList.forEach(ele => {
      this.selectionList.forEach((ele) => {
        ids.push(ele.id);
      });
      return ids.join(",");
    }
    },
  },
  mounted() {
    this.initData();
  },
  methods: {
    initData() {
      getDictTree().then(res => {
      getDictTree().then((res) => {
        const column = this.findObject(this.optionChild.column, "parentId");
        column.dicData = res.data.data;
      });
@@ -187,37 +191,43 @@
        ...row,
        dictKey: -1,
      };
      add(form).then(() => {
      add(form).then(
        () => {
        this.onLoadParent(this.pageParent);
        this.$message({
          type: "success",
          message: "操作成功!"
            message: "操作成功!",
        });
        done();
      }, error => {
        },
        (error) => {
        window.console.log(error);
        loading();
      });
        }
      );
    },
    rowUpdate(row, index, done, loading) {
      update(row).then(() => {
      update(row).then(
        () => {
        this.onLoadParent(this.pageParent);
        this.$message({
          type: "success",
          message: "操作成功!"
            message: "操作成功!",
        });
        this.onLoadChild(this.pageChild);
        done();
      }, error => {
        },
        (error) => {
        window.console.log(error);
        loading();
      });
        }
      );
    },
    rowDel(row) {
      this.$confirm("确定将选择数据删除?", {
        confirmButtonText: "确定",
        cancelButtonText: "取消",
        type: "warning"
        type: "warning",
      })
        .then(() => {
          return remove(row.id);
@@ -226,7 +236,7 @@
          this.onLoadParent(this.pageParent);
          this.$message({
            type: "success",
            message: "操作成功!"
            message: "操作成功!",
          });
        });
    },
@@ -268,7 +278,7 @@
      this.$confirm("确定将选择数据删除?", {
        confirmButtonText: "确定",
        cancelButtonText: "取消",
        type: "warning"
        type: "warning",
      })
        .then(() => {
          return remove(this.ids);
@@ -277,14 +287,14 @@
          this.onLoadParent(this.pageParent);
          this.$message({
            type: "success",
            message: "操作成功!"
            message: "操作成功!",
          });
          this.$refs.crud.toggleSelection();
        });
    },
    beforeOpen(done, type) {
      if (["edit", "view"].includes(type)) {
        getDict(this.formParent.id).then(res => {
        getDict(this.formParent.id).then((res) => {
          this.formParent = res.data.data;
        });
      }
@@ -300,36 +310,42 @@
      this.onLoadParent(this.pageParent, this.query);
    },
    rowSaveChild(row, done, loading) {
      add(row).then(() => {
      add(row).then(
        () => {
        this.onLoadChild(this.pageChild);
        this.$message({
          type: "success",
          message: "操作成功!"
            message: "操作成功!",
        });
        done();
      }, error => {
        },
        (error) => {
        window.console.log(error);
        loading();
      });
        }
      );
    },
    rowUpdateChild(row, index, done, loading) {
      update(row).then(() => {
      update(row).then(
        () => {
        this.onLoadChild(this.pageChild);
        this.$message({
          type: "success",
          message: "操作成功!"
            message: "操作成功!",
        });
        done();
      }, error => {
        },
        (error) => {
        window.console.log(error);
        loading();
      });
        }
      );
    },
    rowDelChild(row) {
      this.$confirm("确定将选择数据删除?", {
        confirmButtonText: "确定",
        cancelButtonText: "取消",
        type: "warning"
        type: "warning",
      })
        .then(() => {
          return remove(row.id);
@@ -338,7 +354,7 @@
          this.onLoadChild(this.pageChild);
          this.$message({
            type: "success",
            message: "操作成功!"
            message: "操作成功!",
          });
        });
    },
@@ -367,7 +383,7 @@
      this.$confirm("确定将选择数据删除?", {
        confirmButtonText: "确定",
        cancelButtonText: "取消",
        type: "warning"
        type: "warning",
      })
        .then(() => {
          return remove(this.ids);
@@ -376,7 +392,7 @@
          this.onLoadChild(this.pageChild);
          this.$message({
            type: "success",
            message: "操作成功!"
            message: "操作成功!",
          });
          this.$refs.crudChild.toggleSelection();
        });
@@ -386,7 +402,7 @@
        this.initData();
      }
      if (["edit", "view"].includes(type)) {
        getDict(this.formChild.id).then(res => {
        getDict(this.formChild.id).then((res) => {
          this.formChild = res.data.data;
        });
      }
@@ -394,7 +410,7 @@
    },
    beforeCloseChild(done) {
      this.$refs.crudChild.value.parentId = this.parentId;
      this.$refs.crudChild.option.column.filter(item => {
      this.$refs.crudChild.option.column.filter((item) => {
        if (item.prop === "parentId") {
          item.value = this.parentId;
        }
@@ -416,7 +432,7 @@
        page.currentPage,
        page.pageSize,
        Object.assign(params, this.query)
      ).then(res => {
      ).then((res) => {
        const data = res.data.data;
        this.pageParent.total = data.total;
        this.dataParent = data.records;
@@ -431,13 +447,13 @@
        page.pageSize,
        this.parentId,
        Object.assign(params, this.query)
      ).then(res => {
      ).then((res) => {
        this.dataChild = res.data.data;
        this.loadingChild = false;
        this.selectionClear();
      });
    }
  }
    },
  },
};
</script>
src/views/system/dictbiz.vue
@@ -1,5 +1,5 @@
<template>
  <basic-container>
  <basic-container class="hasButTwo">
    <avue-crud
      :option="optionParent"
      :table-loading="loading"
@@ -43,16 +43,20 @@
        </el-button>
      </template>
      <template slot-scope="{row}" slot="code">
        <el-tag @click="handleRowClick(row)" style="cursor:pointer">{{ row.code }}</el-tag>
        <el-tag @click="handleRowClick(row)" style="cursor: pointer">{{
          row.code
        }}</el-tag>
      </template>
      <template slot-scope="{row}" slot="isSealed">
        <el-tag>{{ row.isSealed === 0 ? '否' : '是' }}</el-tag>
        <el-tag>{{ row.isSealed === 0 ? "否" : "是" }}</el-tag>
      </template>
    </avue-crud>
    <el-dialog :title="`[${dictValue}]字典配置`"
    <el-dialog
      :title="`[${dictValue}]字典配置`"
               append-to-body
               :visible.sync="box"
               width="1000px">
      width="1000px"
    >
      <avue-crud
        :option="optionChild"
        :table-loading="loadingChild"
@@ -95,7 +99,7 @@
          </el-button>
        </template>
        <template slot-scope="{row}" slot="isSealed">
          <el-tag>{{ row.isSealed === 0 ? '否' : '是' }}</el-tag>
          <el-tag>{{ row.isSealed === 0 ? "否" : "是" }}</el-tag>
        </template>
      </avue-crud>
    </el-dialog>
@@ -110,7 +114,7 @@
    update,
    add,
    getDict,
    getDictTree
  getDictTree,
  } from "@/api/system/dictbiz";
  import {optionParent, optionChild} from "@/option/system/dictbiz";
  import {mapGetters} from "vuex";
@@ -118,7 +122,7 @@
  export default {
    data() {
      return {
        dictValue: '暂无',
      dictValue: "暂无",
        parentId: -1,
        formParent: {},
        formChild: {},
@@ -131,13 +135,13 @@
          pageSize: 10,
          pageSizes: [10, 30, 50, 100, 200],
          currentPage: 1,
          total: 0
        total: 0,
        },
        pageChild: {
          pageSize: 10,
          pageSizes: [10, 30, 50, 100, 200],
          currentPage: 1,
          total: 0
        total: 0,
        },
        dataParent: [],
        dataChild: [],
@@ -157,18 +161,18 @@
      },
      ids() {
        let ids = [];
        this.selectionList.forEach(ele => {
      this.selectionList.forEach((ele) => {
          ids.push(ele.id);
        });
        return ids.join(",");
      }
    },
    },
    mounted() {
      this.initData();
    },
    methods: {
      initData() {
        getDictTree().then(res => {
      getDictTree().then((res) => {
          const column = this.findObject(this.optionChild.column, "parentId");
          column.dicData = res.data.data;
        });
@@ -187,37 +191,43 @@
          ...row,
          dictKey: -1,
        };
        add(form).then(() => {
      add(form).then(
        () => {
          this.onLoadParent(this.pageParent);
          this.$message({
            type: "success",
            message: "操作成功!"
            message: "操作成功!",
          });
          done();
        }, error => {
        },
        (error) => {
          window.console.log(error);
          loading();
        });
        }
      );
      },
      rowUpdate(row, index, done, loading) {
        update(row).then(() => {
      update(row).then(
        () => {
          this.onLoadParent(this.pageParent);
          this.$message({
            type: "success",
            message: "操作成功!"
            message: "操作成功!",
          });
          this.onLoadChild(this.pageChild);
          done();
        }, error => {
        },
        (error) => {
          window.console.log(error);
          loading();
        });
        }
      );
      },
      rowDel(row) {
        this.$confirm("确定将选择数据删除?", {
          confirmButtonText: "确定",
          cancelButtonText: "取消",
          type: "warning"
        type: "warning",
        })
          .then(() => {
            return remove(row.id);
@@ -226,7 +236,7 @@
            this.onLoadParent(this.pageParent);
            this.$message({
              type: "success",
              message: "操作成功!"
            message: "操作成功!",
            });
          });
      },
@@ -268,7 +278,7 @@
        this.$confirm("确定将选择数据删除?", {
          confirmButtonText: "确定",
          cancelButtonText: "取消",
          type: "warning"
        type: "warning",
        })
          .then(() => {
            return remove(this.ids);
@@ -277,14 +287,14 @@
            this.onLoadParent(this.pageParent);
            this.$message({
              type: "success",
              message: "操作成功!"
            message: "操作成功!",
            });
            this.$refs.crud.toggleSelection();
          });
      },
      beforeOpen(done, type) {
        if (["edit", "view"].includes(type)) {
          getDict(this.formParent.id).then(res => {
        getDict(this.formParent.id).then((res) => {
            this.formParent = res.data.data;
          });
        }
@@ -300,36 +310,42 @@
        this.onLoadParent(this.pageParent, this.query);
      },
      rowSaveChild(row, done, loading) {
        add(row).then(() => {
      add(row).then(
        () => {
          this.onLoadChild(this.pageChild);
          this.$message({
            type: "success",
            message: "操作成功!"
            message: "操作成功!",
          });
          done();
        }, error => {
        },
        (error) => {
          window.console.log(error);
          loading();
        });
        }
      );
      },
      rowUpdateChild(row, index, done, loading) {
        update(row).then(() => {
      update(row).then(
        () => {
          this.onLoadChild(this.pageChild);
          this.$message({
            type: "success",
            message: "操作成功!"
            message: "操作成功!",
          });
          done();
        }, error => {
        },
        (error) => {
          window.console.log(error);
          loading();
        });
        }
      );
      },
      rowDelChild(row) {
        this.$confirm("确定将选择数据删除?", {
          confirmButtonText: "确定",
          cancelButtonText: "取消",
          type: "warning"
        type: "warning",
        })
          .then(() => {
            return remove(row.id);
@@ -338,7 +354,7 @@
            this.onLoadChild(this.pageChild);
            this.$message({
              type: "success",
              message: "操作成功!"
            message: "操作成功!",
            });
          });
      },
@@ -367,7 +383,7 @@
        this.$confirm("确定将选择数据删除?", {
          confirmButtonText: "确定",
          cancelButtonText: "取消",
          type: "warning"
        type: "warning",
        })
          .then(() => {
            return remove(this.ids);
@@ -376,7 +392,7 @@
            this.onLoadChild(this.pageChild);
            this.$message({
              type: "success",
              message: "操作成功!"
            message: "操作成功!",
            });
            this.$refs.crudChild.toggleSelection();
          });
@@ -386,7 +402,7 @@
          this.initData();
        }
        if (["edit", "view"].includes(type)) {
          getDict(this.formChild.id).then(res => {
        getDict(this.formChild.id).then((res) => {
            this.formChild = res.data.data;
          });
        }
@@ -394,7 +410,7 @@
      },
      beforeCloseChild(done) {
        this.$refs.crudChild.value.parentId = this.parentId;
        this.$refs.crudChild.option.column.filter(item => {
      this.$refs.crudChild.option.column.filter((item) => {
          if (item.prop === "parentId") {
            item.value = this.parentId;
          }
@@ -416,7 +432,7 @@
          page.currentPage,
          page.pageSize,
          Object.assign(params, this.query)
        ).then(res => {
      ).then((res) => {
          const data = res.data.data;
          this.pageParent.total = data.total;
          this.dataParent = data.records;
@@ -431,12 +447,12 @@
          page.pageSize,
          this.parentId,
          Object.assign(params, this.query)
        ).then(res => {
      ).then((res) => {
          this.dataChild = res.data.data;
          this.loadingChild = false;
          this.selectionClear();
        });
      }
    }
    },
  },
  };
</script>
src/views/system/menu.vue
@@ -1,6 +1,7 @@
<template>
  <basic-container>
    <avue-crud :option="option"
  <basic-container class="hasButTwo">
    <avue-crud
      :option="option"
               :table-loading="loading"
               :data="data"
               ref="crud"
@@ -18,14 +19,17 @@
               @size-change="sizeChange"
               @refresh-change="refreshChange"
               @on-load="onLoad"
               @tree-load="treeLoad">
      @tree-load="treeLoad"
    >
      <template slot="menuLeft">
        <el-button type="danger"
        <el-button
          type="danger"
                   size="small"
                   icon="el-icon-delete"
                   v-if="permission.menu_delete"
                   plain
                   @click="handleDelete">删 除
          @click="handleDelete"
          >删 除
        </el-button>
      </template>
      <template slot-scope="scope" slot="menu">
@@ -34,12 +38,13 @@
          icon="el-icon-circle-plus-outline"
          size="small"
          @click.stop="handleAdd(scope.row,scope.index)"
          v-if="userInfo.role_name.includes('admin') && scope.row.category === 1"
          v-if="
            userInfo.role_name.includes('admin') && scope.row.category === 1
          "
        >新增子项
        </el-button>
      </template>
      <template slot-scope="{row}"
                slot="source">
      <template slot-scope="{ row }" slot="source">
        <div style="text-align:center">
          <i :class="row.source"/>
        </div>
@@ -91,9 +96,9 @@
                {
                  required: true,
                  message: "请输入菜单名称",
                  trigger: "blur"
                }
              ]
                trigger: "blur",
              },
            ],
            },
            {
              label: "路由地址",
@@ -102,9 +107,9 @@
                {
                  required: true,
                  message: "请输入路由地址",
                  trigger: "blur"
                }
              ]
                trigger: "blur",
              },
            ],
            },
            {
              label: "上级菜单",
@@ -114,15 +119,15 @@
              hide: true,
              addDisabled: false,
              props: {
                label: "title"
              label: "title",
              },
              rules: [
                {
                  required: false,
                  message: "请选择上级菜单",
                  trigger: "click"
                }
              ]
                trigger: "click",
              },
            ],
            },
            {
              label: "菜单图标",
@@ -134,9 +139,9 @@
                {
                  required: true,
                  message: "请输入菜单图标",
                  trigger: "click"
                }
              ]
                trigger: "click",
              },
            ],
            },
            {
              label: "菜单编号",
@@ -146,9 +151,9 @@
                {
                  required: true,
                  message: "请输入菜单编号",
                  trigger: "blur"
                }
              ]
                trigger: "blur",
              },
            ],
            },
            {
              label: "菜单类型",
@@ -157,21 +162,21 @@
              dicData: [
                {
                  label: "菜单",
                  value: 1
                value: 1,
                },
                {
                  label: "按钮",
                  value: 2
                }
                value: 2,
              },
              ],
              hide: true,
              rules: [
                {
                  required: true,
                  message: "请选择菜单类型",
                  trigger: "blur"
                }
              ]
                trigger: "blur",
              },
            ],
            },
            {
              label: "菜单别名",
@@ -181,9 +186,9 @@
                {
                  required: true,
                  message: "请输入菜单别名",
                  trigger: "blur"
                }
              ]
                trigger: "blur",
              },
            ],
            },
            {
              label: "新窗口",
@@ -193,21 +198,21 @@
              dicData: [
                {
                  label: "否",
                  value: 1
                value: 1,
                },
                {
                  label: "是",
                  value: 2
                }
                value: 2,
              },
              ],
              value: 1,
              rules: [
                {
                  required: true,
                  message: "请选择新窗口打开",
                  trigger: "blur"
                }
              ]
                trigger: "blur",
              },
            ],
            },
            {
              label: "菜单排序",
@@ -219,9 +224,9 @@
                {
                  required: true,
                  message: "请输入菜单排序",
                  trigger: "blur"
                }
              ]
                trigger: "blur",
              },
            ],
            },
            {
              label: "菜单备注",
@@ -229,21 +234,21 @@
              type: "textarea",
              span: 24,
              minRows: 2,
              hide: true
            }
          ]
            hide: true,
        },
        data: []
        ],
      },
      data: [],
      };
    },
    watch: {
      'form.category'() {
    "form.category"() {
        const category = func.toInt(this.form.category);
        this.$refs.crud.option.column.filter(item => {
      this.$refs.crud.option.column.filter((item) => {
          if (item.prop === "path") {
            item.rules[0].required = category === 1;
          }
          if (item.prop === 'isOpen') {
        if (item.prop === "isOpen") {
            item.disabled = category === 2;
          }
        });
@@ -256,20 +261,20 @@
          addBtn: this.vaildData(this.permission.menu_add, false),
          viewBtn: this.vaildData(this.permission.menu_view, false),
          delBtn: this.vaildData(this.permission.menu_delete, false),
          editBtn: this.vaildData(this.permission.menu_edit, false)
        editBtn: this.vaildData(this.permission.menu_edit, false),
        };
      },
      ids() {
        let ids = [];
        this.selectionList.forEach(ele => {
      this.selectionList.forEach((ele) => {
          ids.push(ele.id);
        });
        return ids.join(",");
      }
    },
    },
    methods: {
      initData() {
        getMenuTree().then(res => {
      getMenuTree().then((res) => {
          const column = this.findObject(this.option.column, "parentId");
          column.dicData = res.data.data;
        });
@@ -282,39 +287,45 @@
        this.$refs.crud.rowAdd();
      },
      rowSave(row, done, loading) {
        add(row).then((res) => {
      add(row).then(
        (res) => {
          // 获取新增数据的相关字段
          const data = res.data.data;
          row.id = data.id;
          this.$message({
            type: "success",
            message: "操作成功!"
            message: "操作成功!",
          });
          // 数据回调进行刷新
          done(row);
        }, error => {
        },
        (error) => {
          window.console.log(error);
          loading();
        });
        }
      );
      },
      rowUpdate(row, index, done, loading) {
        update(row).then(() => {
      update(row).then(
        () => {
          this.$message({
            type: "success",
            message: "操作成功!"
            message: "操作成功!",
          });
          // 数据回调进行刷新
          done(row);
        }, error => {
        },
        (error) => {
          window.console.log(error);
          loading();
        });
        }
      );
      },
      rowDel(row, index, done) {
        this.$confirm("确定将选择数据删除?", {
          confirmButtonText: "确定",
          cancelButtonText: "取消",
          type: "warning"
        type: "warning",
        })
          .then(() => {
            return remove(row.id);
@@ -322,7 +333,7 @@
          .then(() => {
            this.$message({
              type: "success",
              message: "操作成功!"
            message: "操作成功!",
            });
            // 数据回调进行刷新
            done(row);
@@ -336,7 +347,7 @@
        this.$confirm("确定将选择数据删除?", {
          confirmButtonText: "确定",
          cancelButtonText: "取消",
          type: "warning"
        type: "warning",
        })
          .then(() => {
            return remove(this.ids);
@@ -351,7 +362,7 @@
            this.onLoad(this.page);
            this.$message({
              type: "success",
              message: "操作成功!"
            message: "操作成功!",
            });
          });
      },
@@ -362,7 +373,7 @@
      },
      searchChange(params, done) {
        this.query = params;
        this.parentId = '';
      this.parentId = "";
        this.page.currentPage = 1;
        this.onLoad(this.page, params);
        done();
@@ -379,7 +390,7 @@
          this.initData();
        }
        if (["edit", "view"].includes(type)) {
          getMenu(this.form.id).then(res => {
        getMenu(this.form.id).then((res) => {
            this.form = res.data.data;
          });
        }
@@ -403,19 +414,21 @@
      },
      onLoad(page, params = {}) {
        this.loading = true;
        getLazyList(this.parentId, Object.assign(params, this.query)).then(res => {
      getLazyList(this.parentId, Object.assign(params, this.query)).then(
        (res) => {
          this.data = res.data.data;
          this.loading = false;
          this.selectionClear();
        });
        }
      );
      },
      treeLoad(tree, treeNode, resolve) {
        const parentId = tree.id;
        getLazyList(parentId).then(res => {
      getLazyList(parentId).then((res) => {
          resolve(res.data.data);
        });
      }
    }
    },
  },
  };
</script>
src/views/system/topmenu.vue
@@ -1,6 +1,7 @@
<template>
  <basic-container>
    <avue-crud :option="option"
  <basic-container class="topmenu">
    <avue-crud
      :option="option"
               :table-loading="loading"
               :data="data"
               :page.sync="page"
@@ -17,20 +18,25 @@
               @current-change="currentChange"
               @size-change="sizeChange"
               @refresh-change="refreshChange"
               @on-load="onLoad">
      @on-load="onLoad"
    >
      <template slot="menuLeft">
        <el-button type="danger"
        <el-button
          type="danger"
                   size="small"
                   icon="el-icon-delete"
                   plain
                   v-if="permission.topmenu_delete"
                   @click="handleDelete">删 除
          @click="handleDelete"
          >删 除
        </el-button>
        <el-button size="small"
        <el-button
          size="small"
                   icon="el-icon-delete"
                   @click="handleMenuSetting"
                   v-if="permission.topmenu_setting"
                   plain>菜单配置
          plain
          >菜单配置
        </el-button>
      </template>
      <template slot-scope="{row}" slot="source">
@@ -39,34 +45,49 @@
        </div>
      </template>
      <template slot="sort" slot-scope="{row}" >
        <el-input-number v-model="row.sort" @change="sortChange(row)" :min="1" :max="100"></el-input-number>
        <el-input-number
          v-model="row.sort"
          @change="sortChange(row)"
          :min="1"
          :max="100"
        ></el-input-number>
      </template>
    </avue-crud>
    <el-dialog title="下级菜单配置"
    <el-dialog
      title="下级菜单配置"
               append-to-body
               :visible.sync="box"
               width="345px">
      <el-tree :data="menuGrantList"
      width="345px"
    >
      <el-tree
        :data="menuGrantList"
               show-checkbox
               node-key="id"
               ref="treeMenu"
               :default-checked-keys="menuTreeObj"
               :props="props">
        :props="props"
      >
      </el-tree>
      <span slot="footer"
            class="dialog-footer">
      <span slot="footer" class="dialog-footer">
        <el-button @click="box = false">取 消</el-button>
        <el-button type="primary"
                   @click="submit">确 定</el-button>
        <el-button type="primary" @click="submit">确 定</el-button>
      </span>
    </el-dialog>
  </basic-container>
</template>
<script>
  import {getList, getDetail, add, update, remove, grant, grantTree, getTopTree} from "@/api/system/topmenu";
import {
  getList,
  getDetail,
  add,
  update,
  remove,
  grant,
  grantTree,
  getTopTree,
} from "@/api/system/topmenu";
  import {mapGetters} from "vuex";
  import iconList from "@/config/iconList";
@@ -79,18 +100,18 @@
        loading: true,
        props: {
          label: "title",
          value: "key"
        value: "key",
        },
        page: {
          pageSize: 10,
          currentPage: 1,
          total: 0
        total: 0,
        },
        selectionList: [],
        menuGrantList: [],
        menuTreeObj: [],
        option: {
          height: 'auto',
        height: "auto",
          calcHeight: 30,
          tip: false,
          searchShow: true,
@@ -106,11 +127,13 @@
              label: "菜单名",
              prop: "name",
              search: true,
              rules: [{
            rules: [
              {
                required: true,
                message: "请输入菜单名",
                trigger: "blur"
              }]
                trigger: "blur",
              },
            ],
            },
            {
              label: "菜单图标",
@@ -122,34 +145,38 @@
                {
                  required: true,
                  message: "请输入菜单图标",
                  trigger: "click"
                }
              ]
                trigger: "click",
              },
            ],
            },
            {
              label: "菜单编号",
              prop: "code",
              search: true,
              rules: [{
            rules: [
              {
                required: true,
                message: "请输入菜单编号",
                trigger: "blur"
              }]
                trigger: "blur",
              },
            ],
            },
            {
              label: "菜单排序",
              prop: "sort",
              type: "number",
              slot: true,
              rules: [{
            rules: [
              {
                required: true,
                message: "请输入菜单排序",
                trigger: "blur"
              }]
                trigger: "blur",
            },
          ]
            ],
        },
        data: []
        ],
      },
      data: [],
      };
    },
    computed: {
@@ -159,23 +186,23 @@
          addBtn: this.vaildData(this.permission.topmenu_add, false),
          viewBtn: this.vaildData(this.permission.topmenu_view, false),
          delBtn: this.vaildData(this.permission.topmenu_delete, false),
          editBtn: this.vaildData(this.permission.topmenu_edit, false)
        editBtn: this.vaildData(this.permission.topmenu_edit, false),
        };
      },
      ids() {
        let ids = [];
        this.selectionList.forEach(ele => {
      this.selectionList.forEach((ele) => {
          ids.push(ele.id);
        });
        return ids.join(",");
      },
      idsArray() {
        let ids = [];
        this.selectionList.forEach(ele => {
      this.selectionList.forEach((ele) => {
          ids.push(ele.id);
        });
        return ids;
      }
    },
    },
    methods: {
      submit() {
@@ -184,42 +211,48 @@
          this.box = false;
          this.$message({
            type: "success",
            message: "操作成功!"
          message: "操作成功!",
          });
          this.onLoad(this.page);
        });
      },
      rowSave(row, done, loading) {
        add(row).then(() => {
      add(row).then(
        () => {
          this.onLoad(this.page);
          this.$message({
            type: "success",
            message: "操作成功!"
            message: "操作成功!",
          });
          done();
        }, error => {
        },
        (error) => {
          window.console.log(error);
          loading();
        });
        }
      );
      },
      rowUpdate(row, index, done, loading) {
        update(row).then(() => {
      update(row).then(
        () => {
          this.onLoad(this.page);
          this.$message({
            type: "success",
            message: "操作成功!"
            message: "操作成功!",
          });
          done();
        }, error => {
        },
        (error) => {
          window.console.log(error);
          loading();
        });
        }
      );
      },
      rowDel(row) {
        this.$confirm("确定将选择数据删除?", {
          confirmButtonText: "确定",
          cancelButtonText: "取消",
          type: "warning"
        type: "warning",
        })
          .then(() => {
            return remove(row.id);
@@ -228,7 +261,7 @@
            this.onLoad(this.page);
            this.$message({
              type: "success",
              message: "操作成功!"
            message: "操作成功!",
            });
          });
      },
@@ -240,7 +273,7 @@
        this.$confirm("确定将选择数据删除?", {
          confirmButtonText: "确定",
          cancelButtonText: "取消",
          type: "warning"
        type: "warning",
        })
          .then(() => {
            return remove(this.ids);
@@ -249,7 +282,7 @@
            this.onLoad(this.page);
            this.$message({
              type: "success",
              message: "操作成功!"
            message: "操作成功!",
            });
            this.$refs.crud.toggleSelection();
          });
@@ -260,10 +293,9 @@
          return;
        }
        this.menuTreeObj = [];
        grantTree()
          .then(res => {
      grantTree().then((res) => {
            this.menuGrantList = res.data.data.menu;
            getTopTree(this.ids).then(res => {
        getTopTree(this.ids).then((res) => {
              this.menuTreeObj = res.data.data.menu;
              this.box = true;
            });
@@ -271,18 +303,21 @@
      },
      beforeOpen(done, type) {
        if (["edit", "view"].includes(type)) {
          getDetail(this.form.id).then(res => {
        getDetail(this.form.id).then((res) => {
            this.form = res.data.data;
          });
        }
        done();
      },
      sortChange(row) {
        update(row).then(() => {
      update(row).then(
        () => {
          this.onLoad(this.page);
        }, error => {
        },
        (error) => {
          window.console.log(error);
        });
        }
      );
      },
      searchReset() {
        this.query = {};
@@ -312,15 +347,19 @@
      },
      onLoad(page, params = {}) {
        this.loading = true;
        getList(page.currentPage, page.pageSize, Object.assign(params, this.query)).then(res => {
      getList(
        page.currentPage,
        page.pageSize,
        Object.assign(params, this.query)
      ).then((res) => {
          const data = res.data.data;
          this.page.total = data.total;
          this.data = data.records;
          this.loading = false;
          this.selectionClear();
        });
      }
    }
    },
  },
  };
</script>
src/views/trainingRegistration/index.vue
@@ -64,12 +64,13 @@
        tip: false,
        searchSize: "mini",
        searchMenuSpan: 6,
        height: 627,
        height: 693,
        index: true,
        menuWidth: 290,
        align: "center",
        selection: true,
        column: column,
        delBtn: false
        delBtn: false,
      },
    };
  },
src/views/workreport/data.js
@@ -27,7 +27,7 @@
            value: "dictKey"
        },
        dataType: "number",
        searchSpan: 4,
    searchSpan: 5,
        search: true,
        rules: [{
            required: true,
@@ -44,7 +44,7 @@
            value: "dictKey"
        },
        dataType: "number",
        searchSpan: 4,
    searchSpan: 5,
        search: true,
        rules: [{
            required: true,
src/views/workreport/workreport.vue
@@ -1,5 +1,5 @@
<template>
  <basic-container>
  <basic-container class="workreply">
    <avue-crud
      :option="option"
      :table-loading="loading"
@@ -271,4 +271,8 @@
</script>
<style>
.workreply .el-card.is-never-shadow.avue-crud__search {
  width: calc(100% - 380px) !important;
  left: 200px !important;
}
</style>
vue.config.js
@@ -29,6 +29,7 @@
        //本地服务接口地址
        // target: 'http://localhost',
        target: 'http://192.168.0.114:81',//钟W
        // target: 'http://192.168.0.109:81',//tangW
        // target: 'http://192.168.0.104:80',//唐N
        //远程演示服务地址,可用于直接启动项目
        // target: 'https://saber.bladex.vip/api',