管道基础大数据平台系统开发-【前端】-新系統界面
TreeWish
2023-03-03 b6c8e7c61f0270598ba7fdbc44f79512e010d0fe
src/views/userManage/roleManage.vue
@@ -17,22 +17,14 @@
        <div class="flex_box">
          <div style="margin-right: auto">
            <el-form-item
              :label="$t('userManage.RM.roleName')"
              prop="username"
            >
              <el-input
                v-model="roleForm.username"
                style="width: 200px"
              />
            </el-form-item>
            <el-form-item
              :label="$t('userManage.RM.ownedSystem')"
              prop="ownedSystem"
            >
              <el-select
                :popper-append-to-body="false"
                size="small"
                v-model="roleForm.depValue"
                placeholder="请选择"
                :placeholder="$t('userManage.RM.ownedSystemHolder')"
                style="width: 200px"
              >
                <el-option
@@ -55,24 +47,38 @@
            :placeholder="$t('common.pleaseInput')"
          /> -->
            </el-form-item>
            <el-form-item
                :label="$t('userManage.RM.roleName')"
                prop="username"
            >
              <el-input
                  v-model="roleForm.username"
                  :placeholder="$t('userManage.RM.roleNameHolder')"
                  size="small"
                  style="width: 200px"
              >
                <i slot="suffix" class="el-icon-search" @click="onSubmit"></i>
              </el-input>
            </el-form-item>
          </div>
          <div>
<!--            <el-form-item>-->
<!--              <el-button-->
<!--                size="small"-->
<!--                type="primary"-->
<!--                @click="onSubmit('ruleForm')"-->
<!--              ><i class="el-icon-search"></i> &nbsp;{{-->
<!--                  $t("userManage.RM.query")-->
<!--                }}</el-button>-->
<!--            </el-form-item>-->
            <el-form-item>
              <el-button
                type="info"
                size="small"
                @click="resetForm('ruleForm')"
              ><i class="el-icon-delete"></i>&nbsp;{{
                  $t("userManage.RM.reset")
                }}</el-button>
            </el-form-item>
            <el-form-item>
              <el-button
                size="small"
                type="primary"
                @click="onSubmit('ruleForm')"
              ><i class="el-icon-search"></i> &nbsp;{{
                  $t("userManage.RM.query")
                  type="success"
                  size="small"
                  @click="setInsertFormdialog"
                  v-if="menuStatus.insert"
              ><i class="el-icon-circle-plus-outline"></i> &nbsp;{{
                  $t("userManage.RM.add")
                }}</el-button>
            </el-form-item>
            <el-form-item>
@@ -87,12 +93,11 @@
            </el-form-item>
            <el-form-item>
              <el-button
                type="success"
                size="small"
                @click="setInsertFormdialog"
                v-if="menuStatus.insert"
              ><i class="el-icon-circle-plus-outline"></i> &nbsp;{{
                  $t("userManage.RM.add")
                  type="info"
                  size="small"
                  @click="resetForm('ruleForm')"
              ><i class="el-icon-delete"></i>&nbsp;{{
                  $t("userManage.RM.reset")
                }}</el-button>
            </el-form-item>
          </div>
@@ -145,6 +150,7 @@
        </el-form-item> -->
      </el-form>
    </div>
    <div class="dividing-line"></div>
    <div
      class="table_box subpage_Div"
      :style="styleVar"
@@ -152,7 +158,8 @@
      <el-table
        :data="tableData"
        style="width: 100%"
        height="calc(100% - 57px)"
        border
        height="calc(100% - 45px)"
        @selection-change="handleSelectionChange"
      >
        <el-table-column
@@ -244,12 +251,12 @@
              size="small"
              plain
            >{{ $t("common.update") }}</el-button>
          </template>
        </el-table-column>
      </el-table>
      <div
        style="margin-top: 25px"
        style="margin-top: 10px"
        class="pagination_box"
      >
        <el-pagination
@@ -267,8 +274,7 @@
    <el-dialog
      :title="$t('userManage.RM.insertRole')"
      top="2vh"
      :before-close="handleClose"
      style="overflow: hidden"
      :visible.sync="InsertFormdialog"
    >
@@ -378,8 +384,8 @@
    </el-dialog>
    <el-dialog
      :title="$t('userManage.RM.updateRole')"
      top="2vh"
      :visible.sync="UpdateFormdialog"
      :before-close="handleCloseEdit"
    >
        <div style="height: 500px; overflow: auto">
      <el-form :model="updateform" label-position="top">
@@ -509,7 +515,7 @@
<div class="infoBox_box" v-show="showinfoBox">
    <div
      class="infoBox box_div subpage_Div"
    >
      <div
        slot="header"
@@ -660,7 +666,8 @@
      this.$nextTick(() => {
        const rect = this.$refs.container.getBoundingClientRect();
        this.tableHeight = `${rect.height + 97}px`;
        this.styleVar["height"] = `calc(100% - ${rect.height + 97}px)`;
        // this.styleVar["height"] = `calc(100% - ${rect.height + 97}px)`;
        this.styleVar["height"] = `calc(100% - ${rect.height + 30}px)`;
      });
    },
    handleRouleDepList(data, node, nodeData) {
@@ -787,8 +794,12 @@
      });
    },
    insertFromClose() {
      this.InsertFormdialog = false;
      this.insertform = {};
      this.$confirm("关闭后无法保存,是否关闭?")
        .then((_) => {
          this.InsertFormdialog = false;
          this.insertform = {};
        })
        .catch((_) => { });
    },
    async insertFromData() {
      if (this.insertform.depValue == null) {
@@ -815,8 +826,13 @@
      }
    },
    updateFromClose() {
      this.UpdateFormdialog = false;
      this.updateform = {};
      this.$confirm("关闭后无法保存,是否关闭?")
        .then((_) => {
          this.UpdateFormdialog = false;
          this.updateform = {};
          this.getRoleTabelData();
        })
        .catch((_) => { });
    },
    async updateFromData() {
      if (this.updateform.depValue == null) {
@@ -918,6 +934,21 @@
          break;
      }
    },
    handleClose() {
      this.$confirm("关闭后无法保存,是否关闭?")
        .then((_) => {
          this.InsertFormdialog = false
        })
        .catch((_) => { });
    },
    handleCloseEdit() {
      this.$confirm("关闭后无法保存,是否关闭?")
        .then((_) => {
          this.UpdateFormdialog = false
          this.getRoleTabelData();
        })
        .catch((_) => { });
    },
  },
  beforeDestroy() {
    this.timer && clearTimeout(this.timer);
@@ -945,7 +976,7 @@
.logLog_box {
  height: 98%;
  width: 98%;
  padding: 1%;
  padding: 0.5%;
  .el-input {
    width: 300px;
@@ -971,12 +1002,12 @@
  .inquire {
    height: auto;
    padding: 8px;
    margin-top: 20px;
    //padding: 8px;
    //margin-top: 20px;
    border-radius: 5px;
    margin-bottom: 20px;
    //margin-bottom: 20px;
    // width: calc(100% - 22px);
    .el-form-item {