ZZJ
2021-10-09 2e56105da84145350e9b6fe2925cee63d55283f6
src/pages/settings/index/index.vue
@@ -8,7 +8,6 @@
        :key="i"
        @click="openMenu(i)"
      >
        <!-- <span class="icon iconfont">{{ item.icon }}</span> -->
        <img :src="item.blackIcon" class="b" alt="" />
        <img :src="item.whiteIcon" class="w" alt="" />
        <span class="card-text">{{ item.name }}</span>
@@ -40,7 +39,6 @@
          </div>
        </div>
        <div class="add-account" v-if="curUserRole != '普通用户'">
          <!-- <span class="icon iconfont" @click="openAdd">&#xe646;</span> -->
          <i
            class="el-icon-circle-plus"
            style="font-size: 40px"
@@ -74,15 +72,7 @@
                <span class="enable" v-if="!showJPGArr" @click="editHeadPic"
                  >编辑头像</span
                >
                <!-- <span
                  class="enable"
                  v-if="addForm.headpic"
                  @click="confirmChangePic"
                  >确认选择</span
                >
                <span class="enable" v-if="showJPGArr" @click="cacelChoosePic">
                  取消</span
                > -->
              </div>
            </div>
            <div class="user-desc">
@@ -366,12 +356,6 @@
          </div>
          <div class="adjust-zone">
            <!-- <el-radio-group v-model="ajustType"
            fill="#4E94FF"
            >
                  <el-radio-button label="手动校时"></el-radio-button>
                  <el-radio-button label=""></el-radio-button>
                </el-radio-group> -->
            <div class="two-radio">
              <div
                class="radio"
@@ -624,7 +608,6 @@
      :class="showRecomand ? 'border-change' : ''"
      @click.stop
    >
      <!-- @blur="showRecomand = false" -->
      <el-input
        class="search-input"
        placeholder="查找设置"
@@ -660,7 +643,6 @@
        :key="i"
      >
        <div class="child-info">
          <!-- <span class="icon iconfont welcome-icon">{{ item.icon }}</span> -->
          <img :src="item.imgUrl" alt="" />
          <span class="welcome-title">{{ item.name }}</span>
        </div>
@@ -752,7 +734,6 @@
      browserTimer: null,
      timezone: "",
      showRecomand: false,
      searchArr: [
        { name: "账户", addr: [0] },
        { name: "通用设置", addr: [5] },
@@ -786,7 +767,6 @@
      isSetPermission: false,
      timeInterval: 10,
      ntpServer: "",
      // syncType: "1",
      equipmentTime: "",
      equipmentDate: "",
      roleList: [],
@@ -847,7 +827,6 @@
      ],
      accountArr: [],
      jpgArr: [],
      isManual: true,
      isNtp: false,
      activeIndex: 0,
      clockTimer: null,
@@ -904,9 +883,9 @@
  beforeDestroy() {
    clearTimeout(this.clockTimer);
    clearInterval(this.browserTimer);
    if (this.$refs.curPage) {
      this.$refs.curPage.removeEventListener("click");
    }
    // if (this.$refs.curPage) {
    //   this.$refs.curPage.removeEventListener("click");
    // }
  },
  mounted() {
    const menu = getUrlKey("menu");
@@ -1017,7 +996,6 @@
        case "hrs":
          num = +this.syncHour - 1;
          if (num == -1) {
            有线网络有线网络;
            num = 23;
          }
          this.syncHour = pad0(+num);
@@ -1175,18 +1153,18 @@
        }
      );
    },
    flatCheckedArr(arr, res) {
      for (const item of arr) {
        if (item.selected) res.push(item.id);
        if (item.children) this.flatCheckedArr(item.children, res);
      }
    },
    // flatCheckedArr(arr, res) {
    //   for (const item of arr) {
    //     if (item.selected) res.push(item.id);
    //     if (item.children) this.flatCheckedArr(item.children, res);
    //   }
    // },
    saveAuth() {
      let arr = [];
      this.flatCheckedArr(this.sysMenus, arr);
      // let arr = [];
      // this.flatCheckedArr(this.sysMenus, arr);
      updataUser({
        id: this.activeAccountItem.id,
        menuIds: arr,
        menuIds: this.$refs.treeMenus.getCheckedKeys(),
      }).then((res) => {
        if (res.success) {
          this.$message.success(res.msg);
@@ -1218,9 +1196,7 @@
        if (rsp && rsp.success) {
          this.timezone = rsp.data.time_zone;
          if (!ntpTest) {
            // this.syncType = rsp.data.ntp ? "1" : "2";
            this.isNtp = rsp.data.ntp;
            this.isManual = !rsp.data.ntp;
          }
          if (rsp.data.ntp) {
            this.ntpServer = rsp.data.ntp_server;
@@ -1232,7 +1208,7 @@
            "日一二三四五六".charAt(new Date(+this.timestamp * 1000).getDay());
          if (this.clockTimer === null) {
            this.runClock();
            if (this.isManual) this.parseTime();
            if (!this.isNtp) this.parseTime();
          }
        }
      });
@@ -1313,9 +1289,6 @@
        this.openWelcome(addr[0]);
        this.$nextTick(() => {
          if (addr[0] == 1) {
            // addr[1] == 0
            //   ? this.changeSwitch("isNtp")
            //   : this.changeSwitch("isManual");
            return;
          }
          this.$refs[`view_${addr[0]}`].openRight(addr[1]);
@@ -1570,7 +1543,6 @@
  .search-box {
    width: 332px;
    z-index: 999;
    // margin: 55px auto;
    position: fixed;
    left: calc(50% - 166px);
    top: 50px;
@@ -1653,9 +1625,6 @@
        font-weight: bold;
        color: #4e94ff;
      }
      // .res-bar:last-child {
      //   border-radius: 0 0 20px 20px;
      // }
    }
  }
  .nav-items {
@@ -1674,11 +1643,9 @@
      align-items: center;
      cursor: pointer;
      // box-shadow: 2px 2px 4px rgb(226, 226, 226);
      .child-info {
        display: flex;
        flex-direction: column;
        // justify-content: space-around;
        height: 100%;
        .welcome-icon {
          font-size: 72px;
@@ -1697,11 +1664,7 @@
        }
      }
    }
    .nav-child:hover {
      // box-shadow: 4px 4px 12px rgb(218, 218, 218);
      // transform: translate3d(0, -1px, 0);
      // transition: all 0.3s;
    }
  }
}
.container {
@@ -1713,7 +1676,6 @@
  box-sizing: border-box;
  background-color: #fff;
  border-top: 1px solid #e1e0e6;
  .container-left {
    height: 100%;
    width: 244px;
@@ -1721,7 +1683,6 @@
    box-sizing: border-box;
    flex-shrink: 0;
    padding: 10px;
    // border-right: 5px solid rgba(248, 248, 248, 1);
    box-sizing: border-box;
    .left-card {
      height: 56px;
@@ -1731,11 +1692,7 @@
      display: flex;
      align-items: center;
      padding: 0 20px;
      // .iconfont {
      //   margin-left: 25px;
      //   margin-right: 10px;
      //   font-size: 24px;
      // }
      .card-text {
        margin-left: 20px;
        color: #333333;
@@ -1825,7 +1782,6 @@
          color: #333333;
          transform: scale(0.833333);
          line-height: 22.21px;
          // border: 1px solid var(--colorCard) ;
          span {
            font-size: 13px;
          }
@@ -1859,7 +1815,6 @@
          margin: 0 auto;
          display: flex;
          flex-direction: column;
          // margin-bottom: 80px;
          align-items: center;
          .touxiang-big {
            width: 100px;
@@ -2009,22 +1964,23 @@
      .change-pw {
        padding: 40px 10px;
    max-width: 600px;
    margin: 0 auto;
        max-width: 600px;
        margin: 0 auto;
        .title {
          font-weight: bold;
          font-size: 16px;
          line-height: 22px;
          color: #333333;    margin-bottom: 40px;
              height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
          .icon{
    font-size: 28px;
    font-weight: normal;margin-right: 10px;
          color: #333333;
          margin-bottom: 40px;
          height: 28px;
          display: flex;
          align-items: center;
          justify-content: center;
          .icon {
            font-size: 28px;
            font-weight: normal;
            margin-right: 10px;
          }
        }
        .el-form-item__content {
          line-height: 48px;
@@ -2059,12 +2015,16 @@
        .el-form-item {
          .el-input__inner {
            background-color: #ffffff;
            border: none;
            border: 2px solid transparent;
            border-radius: 20px;
            height: 32px;
          line-height: 32px;
            padding: 0 15px;
            font-size: 14px;
            font-weight: bold;
          }
          .el-input__inner:focus{
            border: 2px solid #4e94ff;
          }
          .el-input__inner::placeholder {
            color: #c0c4cc;
@@ -2081,11 +2041,11 @@
          }
        }
        .p-title {
           height: 48px;
            text-align: left;
            line-height: 48px;
            width: 90px;
            font-weight: 600;
          height: 48px;
          text-align: left;
          line-height: 48px;
          width: 90px;
          font-weight: 600;
        }
      }
      .el-form-item {
@@ -2132,8 +2092,8 @@
            color: #333;
            height: 100%;
            overflow: auto;
                max-width: 600px;
    margin: 0 auto;
            max-width: 600px;
            margin: 0 auto;
            .el-tree-node {
              background: initial;
              .el-tree-node__content {
@@ -2271,14 +2231,18 @@
          }
          .el-form-item {
            .el-input__inner {
              background-color: #ffffff;
              border: none;
              border-radius: 20px;
              height: 32px;
              padding: 0 15px;
              font-size: 14px;
              font-weight: bold;
            }
            background-color: #ffffff;
            border: 2px solid transparent;
            border-radius: 20px;
            height: 32px;
          line-height: 32px;
            padding: 0 15px;
            font-size: 14px;
            font-weight: bold;
          }
          .el-input__inner:focus{
            border: 2px solid #4e94ff;
          }
            .el-input__inner::placeholder {
              color: #c0c4cc;
              font-size: 12px;
@@ -2534,7 +2498,8 @@
                border-radius: 20px;
                width: 68px;
                color: #333;
                font-weight: bold;padding: 6px 20px;
                font-weight: bold;
                padding: 6px 20px;
              }
            }
          }
@@ -2573,7 +2538,6 @@
      }
      .ip-input-container {
        max-width: none !important;
        display: inline-block;
        width: 336px;
        height: 34px;
        line-height: normal;
@@ -2585,7 +2549,9 @@
        border: 2px solid transparent;
      }
    }
    .btns {
  }
      .btns {
      margin: 0 auto;
      margin-top: 40px;
      width: fit-content;
@@ -2613,7 +2579,6 @@
        font-size: 16px;
      }
    }
  }
  .container-right-for-account {
    background: #fbfaff;
    padding: 0;