密码策略增删改分页 首页添加修改密码对话框 取消最近模块中dialog对话框中关闭对话框销毁对话框中元素的destroy-on-close属性(导致拖拽效果不实现)
已修改11个文件
230 ■■■■ 文件已修改
Source/plt-web/plt-web-ui/src/api/system/password/api.js 28 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Source/plt-web/plt-web-ui/src/components/PLT-basic-component/transfer.vue 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Source/plt-web/plt-web-ui/src/components/PLT-basic-component/upload-file.vue 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Source/plt-web/plt-web-ui/src/components/actions/base/startWorkFlow.vue 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Source/plt-web/plt-web-ui/src/components/actions/base/uploadFile.vue 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Source/plt-web/plt-web-ui/src/page/index/top/index.vue 111 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Source/plt-web/plt-web-ui/src/page/index/top/top-menu.vue 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Source/plt-web/plt-web-ui/src/views/system/department/index.vue 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Source/plt-web/plt-web-ui/src/views/system/password/index.vue 79 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Source/plt-web/plt-web-ui/src/views/system/role/index.vue 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Source/plt-web/plt-web-ui/src/views/system/user/index.vue 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Source/plt-web/plt-web-ui/src/api/system/password/api.js
@@ -11,3 +11,31 @@
    }
  });
}
// 删除
export function deleteDep(params) {
  return request({
    url: "/api/passwordStrategyQueryController/delPasswordStrateg",
    method: "delete",
    params
  });
}
// 添加
export function addDept(params) {
  return request({
    url: "/api/passwordStrategyQueryController/addPasswordStrateg",
    method: "post",
    data:params
  });
}
// 编辑
export function updatePasswordStrateg(params) {
  return request({
    url: "/api/passwordStrategyQueryController/updatePasswordStrateg",
    method: "put",
    data:params
  });
}
Source/plt-web/plt-web-ui/src/components/PLT-basic-component/transfer.vue
@@ -2,7 +2,6 @@
  <el-dialog
    v-dialogDrag
    :close-on-click-modal="false"
    :destroy-on-close="true"
    :title="title"
    :visible.sync="visible"
    append-to-body="true"
Source/plt-web/plt-web-ui/src/components/PLT-basic-component/upload-file.vue
@@ -2,7 +2,6 @@
  <el-dialog
    v-dialogDrag
    :close-on-click-modal="false"
    :destroy-on-close="true"
    :title="title"
    :visible.sync="visible"
    width="40%"
Source/plt-web/plt-web-ui/src/components/actions/base/startWorkFlow.vue
@@ -1,7 +1,6 @@
<template>
  <el-dialog v-dialogDrag
             :close-on-click-modal="false"
             :destroy-on-close="true"
             :visible.sync="visible"
             :width="width"
             append-to-body="true"
Source/plt-web/plt-web-ui/src/components/actions/base/uploadFile.vue
@@ -2,7 +2,6 @@
  <el-dialog
    v-dialogDrag
    :close-on-click-modal="false"
    :destroy-on-close="true"
    :visible.sync="visible"
    :width="width"
    append-to-body
Source/plt-web/plt-web-ui/src/page/index/top/index.vue
@@ -1,81 +1,81 @@
<template>
  <div class="avue-top">
    <div class="top-bar__left">
      <div class="avue-breadcrumb"
      <div v-if="showCollapse"
           :class="[{ 'avue-breadcrumb--active': isCollapse }]"
           v-if="showCollapse">
           class="avue-breadcrumb">
        <i class="icon-navicon"
           @click="setCollapse"></i>
      </div>
    </div>
    <div class="top-bar__title">
      <div class="top-bar__item top-bar__item--show"
           v-if="showMenu">
      <div v-if="showMenu"
           class="top-bar__item top-bar__item--show">
        <top-menu ref="topMenu"></top-menu>
      </div>
      <span class="top-bar__item"
            v-if="showSearch">
      <span v-if="showSearch"
            class="top-bar__item">
        <top-search></top-search>
      </span>
    </div>
    <div class="top-bar__right">
      <el-tooltip v-if="showColor"
                  effect="dark"
                  :content="$t('navbar.color')"
                  effect="dark"
                  placement="bottom">
        <div class="top-bar__item">
          <top-color></top-color>
        </div>
      </el-tooltip>
      <el-tooltip v-if="showDebug"
                  effect="dark"
                  :content="logsFlag?$t('navbar.bug'):logsLen+$t('navbar.bugs')"
                  effect="dark"
                  placement="bottom">
        <div class="top-bar__item">
          <top-logs></top-logs>
        </div>
      </el-tooltip>
      <el-tooltip v-if="showLock"
                  effect="dark"
                  :content="$t('navbar.lock')"
                  effect="dark"
                  placement="bottom">
        <div class="top-bar__item">
          <top-lock></top-lock>
        </div>
      </el-tooltip>
      <el-tooltip v-if="showTheme"
                  effect="dark"
                  :content="$t('navbar.theme')"
                  effect="dark"
                  placement="bottom">
        <div class="top-bar__item top-bar__item--show">
          <top-theme></top-theme>
        </div>
      </el-tooltip>
      <el-tooltip effect="dark"
                  :content="$t('navbar.notice')"
      <el-tooltip :content="$t('navbar.notice')"
                  effect="dark"
                  placement="bottom">
        <div class="top-bar__item top-bar__item--show">
          <top-notice></top-notice>
        </div>
      </el-tooltip>
      <el-tooltip effect="dark"
                  :content="$t('navbar.language')"
      <el-tooltip :content="$t('navbar.language')"
                  effect="dark"
                  placement="bottom">
        <div class="top-bar__item top-bar__item--show">
          <top-lang></top-lang>
        </div>
      </el-tooltip>
      <el-tooltip v-if="showFullScren"
                  effect="dark"
                  :content="isFullScren?$t('navbar.screenfullF'):$t('navbar.screenfull')"
                  effect="dark"
                  placement="bottom">
        <div class="top-bar__item">
          <i :class="isFullScren?'icon-tuichuquanping':'icon-quanping'"
             @click="handleScreen"></i>
        </div>
      </el-tooltip>
      <img class="top-bar__img"
           :src="userInfo.avatar">
      <img :src="userInfo.avatar"
           class="top-bar__img">
      <el-dropdown>
        <span class="el-dropdown-link">
          {{userInfo.userName}}
@@ -85,22 +85,34 @@
          <el-dropdown-item>
            <router-link to="/">{{$t('navbar.dashboard')}}</router-link>
          </el-dropdown-item>
          <el-dropdown-item>
            <router-link to="/info/index">{{$t('navbar.userinfo')}}</router-link>
          <el-dropdown-item @click.native="changePasswordHandler">
            <!--            <router-link to="/info/index">{{ $t('navbar.userinfo') }}</router-link>-->
            修改密码
          </el-dropdown-item>
          <el-dropdown-item v-if="this.website.switchMode" @click.native="switchDept"
                            >{{$t('navbar.switchDept')}}
          </el-dropdown-item>
          <el-dropdown-item @click.native="logout"
                            divided>{{$t('navbar.logOut')}}
          <el-dropdown-item divided
                            @click.native="logout">{{ $t('navbar.logOut') }}
          </el-dropdown-item>
        </el-dropdown-menu>
      </el-dropdown>
      <el-dialog title="用户信息选择"
      <el-dialog :visible.sync="userBox"
                 append-to-body
                 :visible.sync="userBox"
                 title="用户信息选择"
                 width="350px">
        <avue-form ref="form" :option="userOption" v-model="userForm" @submit="submitSwitch"/>
        <avue-form ref="form" v-model="userForm" :option="userOption" @submit="submitSwitch"/>
      </el-dialog>
      <!-- 修改密码对话框     -->
      <el-dialog
        v-dialogDrag
        :visible.sync="passwordVisible"
        append-to-body="true"
        class="avue-dialog"
        title="修改密码"
        width="50%">
        <avue-form ref="form" v-model="passwordForm" :option="passwordOption" @submit="submitSwitch"/>
      </el-dialog>
    </div>
  </div>
@@ -132,6 +144,52 @@
    name: "top",
    data() {
      return {
      passwordVisible: false,
      passwordForm: {},
      passwordOption: {
        submitText:'保存',
        column: [
          {
            label: '登陆密码',
            prop: 'input',
            span: 24,
            labelWidth:"15%",
            rules: [
              {
                required: true,
                message: '请输入登陆密码',
                trigger: 'blur'
              }
            ]
          },
          {
            label: '新登陆密码',
            prop: 'input1',
            span: 24,
            labelWidth:"15%",
            rules: [
              {
                required: true,
                message: '请输入新登陆密码',
                trigger: 'blur'
              }
            ]
          },
          {
            label: '新密码登陆确认',
            prop: 'input2',
            span: 24,
            labelWidth:"15%",
            rules: [
              {
                required: true,
                message: '请确认登陆密码',
                trigger: 'blur'
              }
            ]
          }
        ]
      },
        userBox: false,
        userForm: {
          deptId: '',
@@ -210,6 +268,11 @@
      ])
    },
    methods: {
    // 修改密码
    changePasswordHandler() {
      console.log('123');
      this.passwordVisible = true;
    },
      handleScreen() {
        fullscreenToggel();
      },
Source/plt-web/plt-web-ui/src/page/index/top/top-menu.vue
@@ -3,14 +3,14 @@
    <el-menu :default-active="activeIndex"
             mode="horizontal"
             text-color="#333">
      <el-menu-item index="0" @click.native="openHome(itemHome)" key="0">
      <el-menu-item key="0" index="0" @click.native="openHome(itemHome)">
        <template slot="title">
          <i :class="itemHome.source"></i>
          <span>{{generateTitle(itemHome)}}</span>
        </template>
      </el-menu-item>
      <template v-for="(item,index) in items">
        <el-menu-item :index="item.id+''" @click.native="openMenu(item)" :key="index">
        <el-menu-item :key="index" :index="item.id+''" @click.native="openMenu(item)">
          <template slot="title">
            <i :class="item.source" style="padding-right: 5px;"></i>
            <span>{{generateTitle(item)}}</span>
Source/plt-web/plt-web-ui/src/views/system/department/index.vue
@@ -37,7 +37,6 @@
    <el-dialog
      v-dialogDrag
      v-loading="statisticsLoading"
      :destroy-on-close="true"
      :visible.sync="statisticsVisible"
      append-to-body="true"
      class="avue-dialog"
Source/plt-web/plt-web-ui/src/views/system/password/index.vue
@@ -2,18 +2,17 @@
  <basic-container>
    <avue-crud
      ref="passWordCrud"
      v-model="form"
      :data="tableData"
      :option="option"
      :page.sync="page"
      :table-loading="tableLoading"
      v-model="form"
      @on-load="getTableList"
      @refresh-change="handleRefresh"
      @size-change="sizeChange"
      @current-change="currentChange"
      @row-save="rowSaveHandler"
      @row-update="rowUpdateHandler"
      @row-del="rowDeleteHandler"
    >
      <template slot="menu" slot-scope="{ row, index }">
        <el-button
@@ -48,10 +47,9 @@
</template>
<script>
import {refDataGrid} from "@/api/system/password/api"
import {refDataGrid, deleteDep, addDept, updatePasswordStrateg} from "@/api/system/password/api"
import basicOption from "@/util/basic-option";
import {column} from "@/views/system/password/option";
import Vue from "vue";
export default {
  name: "index",
  data(){
@@ -63,6 +61,8 @@
        selection:false,
        calcHeight:-60,
        menuWidth:150,
        editBtn: false,
        delBtn: false,
        column:[
          {
            label: '策略名称',
@@ -288,6 +288,7 @@
            prop: 'defaultFlag',
            type: 'switch',
            labelWidth: "30%",
            value: 0,
            dicData: [{
              label: '否',
              value: 0
@@ -306,10 +307,10 @@
      },
      tableLoading:false,
      checkboxlength: "", //添加存放多选的变量,用于下拉菜单的禁用效果和必填种类是否大于组合方式然后提示用户重新选择
      selectlength: 0,    //这个是下拉菜单的数据变量
      checkboxlist: "" ,  //这个是用于防止change时间冒泡,出现两次弹窗定义的变量
      selectlength: 0,    // 下拉菜单的数据变量
      checkboxlist: "",  // 用于防止change时间冒泡,出现两次弹窗定义的变量
      checkboxNumber: "", //用于首次点击编辑,判断组合方式是否小于必填种类的变量
      selectNumber: "",   //这个也是存放多选的变量,效果一样,只是用作在编辑模块
      selectNumber: "",   // 存放多选的变量,效果一样,只是用作在编辑模块
      checkboxedit: "",   // 用于判断是否是编辑
      editFlag: false,
      minValue:"", // 最小长度value
@@ -321,7 +322,6 @@
    getTableList() {
      this.tableLoading = true;
      refDataGrid(this.page.currentPage, this.page.pageSize).then(res =>{
        console.log(res);
        this.tableData = res.data.data;
        this.page.total = res.data.total;
        this.tableLoading = false;
@@ -344,8 +344,19 @@
    },
    // 添加
    rowSaveHandler(){
      console.log(this.form.requireCharCount);
    rowSaveHandler(row, done, loading) {
      row.combinations = row.requireCharType.join(',');
      delete row.requireCharType;
      addDept(row).then(res => {
        if (res.data.code === 200) {
          this.$message.success(res.data.obj);
          this.getTableList();
          done()
        }
      }).catch(err => {
        loading()
        console.log(err);
      })
    },
    // 编辑按钮
@@ -357,18 +368,44 @@
    },
    // 修改
    rowUpdateHandler(){
    },
    // 删除按钮
    handleDel(){
    rowUpdateHandler(row, index, done,loading) {
      row.combinations = row.requireCharType;
      delete row.requireCharType;
      updatePasswordStrateg(row).then(res => {
        if (res.data.code === 200) {
          this.$message.success(res.data.obj);
          this.getTableList();
          done()
        }
      }).catch(err => {
        loading()
        console.log(err);
      })
    },
    // 删除
    rowDeleteHandler(){
    handleDel(row, index) {
      let params = {
        pwdIds: row.oid
      }
      this.$confirm('您确定要删除当前的密码策略吗?', '提示', {
        confirmButtonText: '确定',
        cancelButtonText: '取消',
        type: 'warning'
      }).then(() => {
        deleteDep(params).then(res => {
          if (res.data.code === 200) {
            this.$message.success(res.data.obj);
            this.getTableList();
          }
        });
      }).catch(() => {
        this.$message({
          type: 'info',
          message: '已取消删除'
        });
      });
    },
    // 必填种类changge事件
@@ -430,7 +467,7 @@
      }
    },
    // 循环找到对应必填种类禁用选项
    // 过滤找到对应必填种类禁用选项
    setDisabled(arr, indices) {
      arr.dicData.forEach((item, index) => {
        item.disabled = !indices.includes(index);
@@ -441,7 +478,7 @@
}
</script>
<style scoped lang="scss">
<style lang="scss" scoped>
.avue-form__group--flex{
  padding-bottom: 25px !important;
}
Source/plt-web/plt-web-ui/src/views/system/role/index.vue
@@ -40,7 +40,6 @@
    <el-dialog
      v-dialogDrag
      v-loading="statisticsLoading"
      :destroy-on-close="true"
      :visible.sync="statisticsVisible"
      append-to-body="true"
      class="avue-dialog"
Source/plt-web/plt-web-ui/src/views/system/user/index.vue
@@ -77,7 +77,6 @@
    <el-dialog
      v-dialogDrag
      v-loading="pwdLoading"
      :destroy-on-close="true"
      :visible.sync="pwdVisible"
      append-to-body="true"
      class="avue-dialog"
@@ -106,7 +105,6 @@
    <el-dialog
      v-dialogDrag
      v-loading="departLoading"
      :destroy-on-close="true"
      :visible.sync="departVisible"
      append-to-body="true"
      class="avue-dialog"