Merge branch 'master-dev' into feature-Beta-dev-renpy
This commit is contained in:
		
						commit
						afc0d317ca
					
				| 
						 | 
				
			
			@ -1,12 +1,12 @@
 | 
			
		|||
<template>
 | 
			
		||||
  <div class="user-wrapper" :class="theme">
 | 
			
		||||
    <header-notice class="action"/>
 | 
			
		||||
    <header-notice class="action" />
 | 
			
		||||
    <a-dropdown>
 | 
			
		||||
      <span class="action action-full ant-dropdown-link user-dropdown-menu">
 | 
			
		||||
        <img src="@/assets/images/header/avatar.png" alt="">
 | 
			
		||||
        <img src="@/assets/images/header/avatar.png" alt="" />
 | 
			
		||||
      </span>
 | 
			
		||||
      <a-menu slot="overlay" class="user-dropdown-menu-wrapper">
 | 
			
		||||
        <a-menu-item key="0">
 | 
			
		||||
        <!-- <a-menu-item key="0">
 | 
			
		||||
          <router-link :to="{ name: 'account-center' }">
 | 
			
		||||
            <a-icon type="user"/>
 | 
			
		||||
            <span>个人中心</span>
 | 
			
		||||
| 
						 | 
				
			
			@ -21,24 +21,24 @@
 | 
			
		|||
        <a-menu-item key="3"  @click="systemSetting">
 | 
			
		||||
           <a-icon type="tool"/>
 | 
			
		||||
           <span>系统设置</span>
 | 
			
		||||
        </a-menu-item>
 | 
			
		||||
        </a-menu-item> -->
 | 
			
		||||
        <a-menu-item key="4" @click="updatePassword">
 | 
			
		||||
          <a-icon type="setting"/>
 | 
			
		||||
          <span>密码修改</span>
 | 
			
		||||
          <a-icon type="setting" />
 | 
			
		||||
          <span>Change Password</span>
 | 
			
		||||
        </a-menu-item>
 | 
			
		||||
        <a-menu-item key="5" @click="updateCurrentDepart">
 | 
			
		||||
        <!-- <a-menu-item key="5" @click="updateCurrentDepart">
 | 
			
		||||
          <a-icon type="cluster"/>
 | 
			
		||||
          <span>切换部门</span>
 | 
			
		||||
        </a-menu-item>
 | 
			
		||||
        <a-menu-item key="6" @click="clearCache">
 | 
			
		||||
          <a-icon type="sync"/>
 | 
			
		||||
          <span>清理缓存</span>
 | 
			
		||||
        </a-menu-item>
 | 
			
		||||
        </a-menu-item> -->
 | 
			
		||||
      </a-menu>
 | 
			
		||||
    </a-dropdown>
 | 
			
		||||
    <span class="action">
 | 
			
		||||
      <a class="logout_title" href="javascript:;" @click="handleLogout">
 | 
			
		||||
        <img src="@/assets/images/header/close.png" alt="">
 | 
			
		||||
        <img src="@/assets/images/header/close.png" alt="" />
 | 
			
		||||
      </a>
 | 
			
		||||
    </span>
 | 
			
		||||
    <user-password ref="userPassword"></user-password>
 | 
			
		||||
| 
						 | 
				
			
			@ -48,201 +48,205 @@
 | 
			
		|||
</template>
 | 
			
		||||
 | 
			
		||||
<script>
 | 
			
		||||
  import HeaderNotice from './HeaderNotice'
 | 
			
		||||
  import UserPassword from './UserPassword'
 | 
			
		||||
  import SettingDrawer from "@/components/setting/SettingDrawer";
 | 
			
		||||
  import DepartSelect from './DepartSelect'
 | 
			
		||||
  import { mapActions, mapGetters,mapState } from 'vuex'
 | 
			
		||||
  import { mixinDevice } from '@/utils/mixin.js'
 | 
			
		||||
  import { getFileAccessHttpUrl,getAction } from "@/api/manage"
 | 
			
		||||
  import Vue from 'vue'
 | 
			
		||||
  import { UI_CACHE_DB_DICT_DATA } from "@/store/mutation-types"
 | 
			
		||||
import HeaderNotice from './HeaderNotice'
 | 
			
		||||
import UserPassword from './UserPassword'
 | 
			
		||||
import SettingDrawer from '@/components/setting/SettingDrawer'
 | 
			
		||||
import DepartSelect from './DepartSelect'
 | 
			
		||||
import { mapActions, mapGetters, mapState } from 'vuex'
 | 
			
		||||
import { mixinDevice } from '@/utils/mixin.js'
 | 
			
		||||
import { getFileAccessHttpUrl, getAction } from '@/api/manage'
 | 
			
		||||
import Vue from 'vue'
 | 
			
		||||
import { UI_CACHE_DB_DICT_DATA } from '@/store/mutation-types'
 | 
			
		||||
 | 
			
		||||
  export default {
 | 
			
		||||
    name: "UserMenu",
 | 
			
		||||
    mixins: [mixinDevice],
 | 
			
		||||
    data(){
 | 
			
		||||
      return{
 | 
			
		||||
        // update-begin author:sunjianlei date:20200219 for: 头部菜单搜索规范命名 --------------
 | 
			
		||||
        searchMenuOptions:[],
 | 
			
		||||
        searchMenuComp: 'span',
 | 
			
		||||
        searchMenuVisible: false,
 | 
			
		||||
        // update-begin author:sunjianlei date:20200219 for: 头部菜单搜索规范命名 --------------
 | 
			
		||||
      }
 | 
			
		||||
    },
 | 
			
		||||
    components: {
 | 
			
		||||
      HeaderNotice,
 | 
			
		||||
      UserPassword,
 | 
			
		||||
      DepartSelect,
 | 
			
		||||
      SettingDrawer
 | 
			
		||||
    },
 | 
			
		||||
    props: {
 | 
			
		||||
      theme: {
 | 
			
		||||
        type: String,
 | 
			
		||||
        required: false,
 | 
			
		||||
        default: 'dark'
 | 
			
		||||
export default {
 | 
			
		||||
  name: 'UserMenu',
 | 
			
		||||
  mixins: [mixinDevice],
 | 
			
		||||
  data() {
 | 
			
		||||
    return {
 | 
			
		||||
      // update-begin author:sunjianlei date:20200219 for: 头部菜单搜索规范命名 --------------
 | 
			
		||||
      searchMenuOptions: [],
 | 
			
		||||
      searchMenuComp: 'span',
 | 
			
		||||
      searchMenuVisible: false,
 | 
			
		||||
      // update-begin author:sunjianlei date:20200219 for: 头部菜单搜索规范命名 --------------
 | 
			
		||||
    }
 | 
			
		||||
  },
 | 
			
		||||
  components: {
 | 
			
		||||
    HeaderNotice,
 | 
			
		||||
    UserPassword,
 | 
			
		||||
    DepartSelect,
 | 
			
		||||
    SettingDrawer,
 | 
			
		||||
  },
 | 
			
		||||
  props: {
 | 
			
		||||
    theme: {
 | 
			
		||||
      type: String,
 | 
			
		||||
      required: false,
 | 
			
		||||
      default: 'dark',
 | 
			
		||||
    },
 | 
			
		||||
  },
 | 
			
		||||
  /* update_begin author:zhaoxin date:20191129 for: 做头部菜单栏导航*/
 | 
			
		||||
  created() {
 | 
			
		||||
    let lists = []
 | 
			
		||||
    this.searchMenus(lists, this.permissionMenuList)
 | 
			
		||||
    this.searchMenuOptions = [...lists]
 | 
			
		||||
  },
 | 
			
		||||
  mounted() {
 | 
			
		||||
    //如果是单点登录模式
 | 
			
		||||
    if (process.env.VUE_APP_SSO == 'true') {
 | 
			
		||||
      let depart = this.userInfo().orgCode
 | 
			
		||||
      if (!depart) {
 | 
			
		||||
        this.updateCurrentDepart()
 | 
			
		||||
      }
 | 
			
		||||
    }
 | 
			
		||||
  },
 | 
			
		||||
  computed: {
 | 
			
		||||
    ...mapState({
 | 
			
		||||
      // 后台菜单
 | 
			
		||||
      permissionMenuList: (state) => state.user.permissionList,
 | 
			
		||||
    }),
 | 
			
		||||
  },
 | 
			
		||||
  /* update_end author:zhaoxin date:20191129 for: 做头部菜单栏导航*/
 | 
			
		||||
  watch: {
 | 
			
		||||
    // update-begin author:sunjianlei date:20200219 for: 菜单搜索改为动态组件,在手机端呈现出弹出框
 | 
			
		||||
    device: {
 | 
			
		||||
      immediate: true,
 | 
			
		||||
      handler() {
 | 
			
		||||
        this.searchMenuVisible = false
 | 
			
		||||
        this.searchMenuComp = this.isMobile() ? 'a-modal' : 'span'
 | 
			
		||||
      },
 | 
			
		||||
    },
 | 
			
		||||
    // update-end author:sunjianlei date:20200219 for: 菜单搜索改为动态组件,在手机端呈现出弹出框
 | 
			
		||||
  },
 | 
			
		||||
  methods: {
 | 
			
		||||
    /* update_begin author:zhaoxin date:20191129 for: 做头部菜单栏导航*/
 | 
			
		||||
    created() {
 | 
			
		||||
      let lists = []
 | 
			
		||||
      this.searchMenus(lists,this.permissionMenuList)
 | 
			
		||||
      this.searchMenuOptions=[...lists]
 | 
			
		||||
    showClick() {
 | 
			
		||||
      this.searchMenuVisible = true
 | 
			
		||||
    },
 | 
			
		||||
    mounted() {
 | 
			
		||||
      //如果是单点登录模式
 | 
			
		||||
      if (process.env.VUE_APP_SSO == 'true') {
 | 
			
		||||
        let depart = this.userInfo().orgCode
 | 
			
		||||
        if (!depart) {
 | 
			
		||||
          this.updateCurrentDepart()
 | 
			
		||||
        }
 | 
			
		||||
      }
 | 
			
		||||
    },
 | 
			
		||||
    computed: {
 | 
			
		||||
      ...mapState({
 | 
			
		||||
        // 后台菜单
 | 
			
		||||
        permissionMenuList: state => state.user.permissionList
 | 
			
		||||
 | 
			
		||||
      })
 | 
			
		||||
    hiddenClick() {
 | 
			
		||||
      this.shows = false
 | 
			
		||||
    },
 | 
			
		||||
    /* update_end author:zhaoxin date:20191129 for: 做头部菜单栏导航*/
 | 
			
		||||
    watch: {
 | 
			
		||||
      // update-begin author:sunjianlei date:20200219 for: 菜单搜索改为动态组件,在手机端呈现出弹出框
 | 
			
		||||
      device: {
 | 
			
		||||
        immediate: true,
 | 
			
		||||
        handler() {
 | 
			
		||||
          this.searchMenuVisible = false
 | 
			
		||||
          this.searchMenuComp = this.isMobile() ? 'a-modal' : 'span'
 | 
			
		||||
        },
 | 
			
		||||
      },
 | 
			
		||||
      // update-end author:sunjianlei date:20200219 for: 菜单搜索改为动态组件,在手机端呈现出弹出框
 | 
			
		||||
    ...mapActions(['Logout']),
 | 
			
		||||
    ...mapGetters(['nickname', 'avatar', 'userInfo']),
 | 
			
		||||
    getAvatar() {
 | 
			
		||||
      return getFileAccessHttpUrl(this.avatar())
 | 
			
		||||
    },
 | 
			
		||||
    methods: {
 | 
			
		||||
      /* update_begin author:zhaoxin date:20191129 for: 做头部菜单栏导航*/
 | 
			
		||||
      showClick() {
 | 
			
		||||
        this.searchMenuVisible = true
 | 
			
		||||
      },
 | 
			
		||||
      hiddenClick(){
 | 
			
		||||
        this.shows = false
 | 
			
		||||
      },
 | 
			
		||||
      /* update_end author:zhaoxin date:20191129 for: 做头部菜单栏导航*/
 | 
			
		||||
      ...mapActions(["Logout"]),
 | 
			
		||||
      ...mapGetters(["nickname", "avatar","userInfo"]),
 | 
			
		||||
      getAvatar(){
 | 
			
		||||
        return getFileAccessHttpUrl(this.avatar())
 | 
			
		||||
      },
 | 
			
		||||
      handleLogout() {
 | 
			
		||||
        const that = this
 | 
			
		||||
    handleLogout() {
 | 
			
		||||
      const that = this
 | 
			
		||||
 | 
			
		||||
        this.$confirm({
 | 
			
		||||
          title: 'Prompt',
 | 
			
		||||
          content: 'Ensure Log Out?',
 | 
			
		||||
          cancelButtonProps: {
 | 
			
		||||
            props: {
 | 
			
		||||
              type: 'warn'
 | 
			
		||||
            }
 | 
			
		||||
      this.$confirm({
 | 
			
		||||
        title: 'Prompt',
 | 
			
		||||
        content: 'Ensure Log Out?',
 | 
			
		||||
        cancelButtonProps: {
 | 
			
		||||
          props: {
 | 
			
		||||
            type: 'warn',
 | 
			
		||||
          },
 | 
			
		||||
          onOk() {
 | 
			
		||||
            return that.Logout({}).then(() => {
 | 
			
		||||
        },
 | 
			
		||||
        onOk() {
 | 
			
		||||
          return that
 | 
			
		||||
            .Logout({})
 | 
			
		||||
            .then(() => {
 | 
			
		||||
              // update-begin author:scott date:20211223 for:【JTC-198】退出登录体验不好
 | 
			
		||||
              //that.$router.push({ path: '/user/login' });
 | 
			
		||||
              window.location.reload()
 | 
			
		||||
              // update-end author:scott date:20211223 for:【JTC-198】退出登录体验不好
 | 
			
		||||
            }).catch(err => {
 | 
			
		||||
            })
 | 
			
		||||
            .catch((err) => {
 | 
			
		||||
              that.$message.error({
 | 
			
		||||
                title: 'Error',
 | 
			
		||||
                description: err.message
 | 
			
		||||
                description: err.message,
 | 
			
		||||
              })
 | 
			
		||||
            })
 | 
			
		||||
          },
 | 
			
		||||
          onCancel() {
 | 
			
		||||
          },
 | 
			
		||||
        });
 | 
			
		||||
      },
 | 
			
		||||
      updatePassword(){
 | 
			
		||||
        let username = this.userInfo().username
 | 
			
		||||
        this.$refs.userPassword.show(username)
 | 
			
		||||
      },
 | 
			
		||||
      updateCurrentDepart(){
 | 
			
		||||
        this.$refs.departSelect.show()
 | 
			
		||||
      },
 | 
			
		||||
      systemSetting(){
 | 
			
		||||
        this.$refs.settingDrawer.showDrawer()
 | 
			
		||||
      },
 | 
			
		||||
      /* update_begin author:zhaoxin date:20191129 for: 做头部菜单栏导航*/
 | 
			
		||||
      searchMenus(arr,menus){
 | 
			
		||||
        for(let i of menus){
 | 
			
		||||
          if(!i.hidden && "layouts/RouteView"!==i.component){
 | 
			
		||||
           arr.push(i)
 | 
			
		||||
          }
 | 
			
		||||
          if(i.children&& i.children.length>0){
 | 
			
		||||
            this.searchMenus(arr,i.children)
 | 
			
		||||
          }
 | 
			
		||||
        },
 | 
			
		||||
        onCancel() {},
 | 
			
		||||
      })
 | 
			
		||||
    },
 | 
			
		||||
    updatePassword() {
 | 
			
		||||
      let username = this.userInfo().username
 | 
			
		||||
      this.$refs.userPassword.show(username)
 | 
			
		||||
    },
 | 
			
		||||
    updateCurrentDepart() {
 | 
			
		||||
      this.$refs.departSelect.show()
 | 
			
		||||
    },
 | 
			
		||||
    systemSetting() {
 | 
			
		||||
      this.$refs.settingDrawer.showDrawer()
 | 
			
		||||
    },
 | 
			
		||||
    /* update_begin author:zhaoxin date:20191129 for: 做头部菜单栏导航*/
 | 
			
		||||
    searchMenus(arr, menus) {
 | 
			
		||||
      for (let i of menus) {
 | 
			
		||||
        if (!i.hidden && 'layouts/RouteView' !== i.component) {
 | 
			
		||||
          arr.push(i)
 | 
			
		||||
        }
 | 
			
		||||
      },
 | 
			
		||||
      filterOption(input, option) {
 | 
			
		||||
        return option.componentOptions.children[0].text.toLowerCase().indexOf(input.toLowerCase()) >= 0
 | 
			
		||||
      },
 | 
			
		||||
      // update_begin author:sunjianlei date:20191230 for: 解决外部链接打开失败的问题
 | 
			
		||||
      searchMethods(value) {
 | 
			
		||||
        let route = this.searchMenuOptions.filter(item => item.id === value)[0]
 | 
			
		||||
        //update-begin-author:sunjianlei date:20220111 for: 【JTC-702】【菜单搜索】菜单搜索里点击跳转的菜单,无法将Token信息传递过去
 | 
			
		||||
        if(route.component.includes('layouts/IframePageView')){
 | 
			
		||||
          this.$router.push(route)
 | 
			
		||||
        }else{
 | 
			
		||||
          this.$router.push({ path: route.path })
 | 
			
		||||
        if (i.children && i.children.length > 0) {
 | 
			
		||||
          this.searchMenus(arr, i.children)
 | 
			
		||||
        }
 | 
			
		||||
        //update-end-author:sunjianlei date:20220111 for: 【JTC-702】【菜单搜索】菜单搜索里点击跳转的菜单,无法将Token信息传递过去
 | 
			
		||||
        this.searchMenuVisible = false
 | 
			
		||||
      },
 | 
			
		||||
      // update_end author:sunjianlei date:20191230 for: 解决外部链接打开失败的问题
 | 
			
		||||
      /*update_end author:zhaoxin date:20191129 for: 做头部菜单栏导航*/
 | 
			
		||||
      /*update_begin author:liushaoqian date:20200507 for: 刷新缓存*/
 | 
			
		||||
      clearCache(){
 | 
			
		||||
        getAction("sys/dict/refleshCache").then((res) => {
 | 
			
		||||
      }
 | 
			
		||||
    },
 | 
			
		||||
    filterOption(input, option) {
 | 
			
		||||
      return option.componentOptions.children[0].text.toLowerCase().indexOf(input.toLowerCase()) >= 0
 | 
			
		||||
    },
 | 
			
		||||
    // update_begin author:sunjianlei date:20191230 for: 解决外部链接打开失败的问题
 | 
			
		||||
    searchMethods(value) {
 | 
			
		||||
      let route = this.searchMenuOptions.filter((item) => item.id === value)[0]
 | 
			
		||||
      //update-begin-author:sunjianlei date:20220111 for: 【JTC-702】【菜单搜索】菜单搜索里点击跳转的菜单,无法将Token信息传递过去
 | 
			
		||||
      if (route.component.includes('layouts/IframePageView')) {
 | 
			
		||||
        this.$router.push(route)
 | 
			
		||||
      } else {
 | 
			
		||||
        this.$router.push({ path: route.path })
 | 
			
		||||
      }
 | 
			
		||||
      //update-end-author:sunjianlei date:20220111 for: 【JTC-702】【菜单搜索】菜单搜索里点击跳转的菜单,无法将Token信息传递过去
 | 
			
		||||
      this.searchMenuVisible = false
 | 
			
		||||
    },
 | 
			
		||||
    // update_end author:sunjianlei date:20191230 for: 解决外部链接打开失败的问题
 | 
			
		||||
    /*update_end author:zhaoxin date:20191129 for: 做头部菜单栏导航*/
 | 
			
		||||
    /*update_begin author:liushaoqian date:20200507 for: 刷新缓存*/
 | 
			
		||||
    clearCache() {
 | 
			
		||||
      getAction('sys/dict/refleshCache')
 | 
			
		||||
        .then((res) => {
 | 
			
		||||
          if (res.success) {
 | 
			
		||||
            //重新加载缓存
 | 
			
		||||
            getAction("sys/dict/queryAllDictItems").then((res) => {
 | 
			
		||||
            getAction('sys/dict/queryAllDictItems').then((res) => {
 | 
			
		||||
              if (res.success) {
 | 
			
		||||
                Vue.ls.remove(UI_CACHE_DB_DICT_DATA)
 | 
			
		||||
                Vue.ls.set(UI_CACHE_DB_DICT_DATA, res.result, 7 * 24 * 60 * 60 * 1000)
 | 
			
		||||
              }
 | 
			
		||||
            })
 | 
			
		||||
            this.$message.success("刷新缓存完成!");
 | 
			
		||||
            this.$message.success('刷新缓存完成!')
 | 
			
		||||
          }
 | 
			
		||||
        }).catch(e=>{
 | 
			
		||||
          this.$message.warn("刷新缓存失败!");
 | 
			
		||||
          console.log("刷新失败",e)
 | 
			
		||||
        })
 | 
			
		||||
      }
 | 
			
		||||
      /*update_end author:liushaoqian date:20200507 for: 刷新缓存*/
 | 
			
		||||
    }
 | 
			
		||||
  }
 | 
			
		||||
        .catch((e) => {
 | 
			
		||||
          this.$message.warn('刷新缓存失败!')
 | 
			
		||||
          console.log('刷新失败', e)
 | 
			
		||||
        })
 | 
			
		||||
    },
 | 
			
		||||
    /*update_end author:liushaoqian date:20200507 for: 刷新缓存*/
 | 
			
		||||
  },
 | 
			
		||||
}
 | 
			
		||||
</script>
 | 
			
		||||
 | 
			
		||||
<style lang="less" scoped>
 | 
			
		||||
  /* update_begin author:zhaoxin date:20191129 for: 让搜索框颜色能随主题颜色变换*/
 | 
			
		||||
  /* update-begin author:sunjianlei date:20191220 for: 解决全局样式冲突问题 */
 | 
			
		||||
  .user-wrapper .search-input {
 | 
			
		||||
    width: 180px;
 | 
			
		||||
    color: inherit;
 | 
			
		||||
/* update_begin author:zhaoxin date:20191129 for: 让搜索框颜色能随主题颜色变换*/
 | 
			
		||||
/* update-begin author:sunjianlei date:20191220 for: 解决全局样式冲突问题 */
 | 
			
		||||
.user-wrapper .search-input {
 | 
			
		||||
  width: 180px;
 | 
			
		||||
  color: inherit;
 | 
			
		||||
 | 
			
		||||
    /deep/ .ant-select-selection {
 | 
			
		||||
      background-color: inherit;
 | 
			
		||||
      border: 0;
 | 
			
		||||
      border-bottom: 1px solid white;
 | 
			
		||||
      &__placeholder, &__field__placeholder {
 | 
			
		||||
        color: inherit;
 | 
			
		||||
      }
 | 
			
		||||
  /deep/ .ant-select-selection {
 | 
			
		||||
    background-color: inherit;
 | 
			
		||||
    border: 0;
 | 
			
		||||
    border-bottom: 1px solid white;
 | 
			
		||||
    &__placeholder,
 | 
			
		||||
    &__field__placeholder {
 | 
			
		||||
      color: inherit;
 | 
			
		||||
    }
 | 
			
		||||
  }
 | 
			
		||||
  /* update-end author:sunjianlei date:20191220 for: 解决全局样式冲突问题 */
 | 
			
		||||
  /* update_end author:zhaoxin date:20191129 for: 让搜索框颜色能随主题颜色变换*/
 | 
			
		||||
}
 | 
			
		||||
/* update-end author:sunjianlei date:20191220 for: 解决全局样式冲突问题 */
 | 
			
		||||
/* update_end author:zhaoxin date:20191129 for: 让搜索框颜色能随主题颜色变换*/
 | 
			
		||||
</style>
 | 
			
		||||
 | 
			
		||||
<style scoped>
 | 
			
		||||
  .logout_title {
 | 
			
		||||
    color: inherit;
 | 
			
		||||
    text-decoration: none;
 | 
			
		||||
  }
 | 
			
		||||
.logout_title {
 | 
			
		||||
  color: inherit;
 | 
			
		||||
  text-decoration: none;
 | 
			
		||||
}
 | 
			
		||||
</style>
 | 
			
		||||
| 
						 | 
				
			
			@ -11,8 +11,9 @@
 | 
			
		|||
    :customRow="customRow"
 | 
			
		||||
    :rowClassName="() => (canSelect ? 'custom-table-row' : '')"
 | 
			
		||||
    @change="handleTableChange"
 | 
			
		||||
    :scroll="{ y: 186 }"
 | 
			
		||||
    :scroll="scroll"
 | 
			
		||||
  >
 | 
			
		||||
    <!-- :scroll="{ y: 186 }" -->
 | 
			
		||||
    <!-- 处理 scopedSlots -->
 | 
			
		||||
    <template v-for="slotName of scopedSlotsKeys" :slot="slotName" slot-scope="text, record, index">
 | 
			
		||||
      <slot :name="slotName" :text="text" :record="record" :index="index"></slot>
 | 
			
		||||
| 
						 | 
				
			
			@ -58,6 +59,7 @@ export default {
 | 
			
		|||
      type: Boolean,
 | 
			
		||||
      default: false,
 | 
			
		||||
    },
 | 
			
		||||
    scroll: { type: Object },
 | 
			
		||||
  },
 | 
			
		||||
  data() {
 | 
			
		||||
    return {
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -49,8 +49,7 @@
 | 
			
		|||
 | 
			
		||||
<script>
 | 
			
		||||
import moment from 'moment'
 | 
			
		||||
import dateFormat from '@/components/jeecg/JEasyCron/format-date'
 | 
			
		||||
import { getAction, postAction, httpAction, deleteAction } from '@/api/manage'
 | 
			
		||||
import { getAction } from '@/api/manage'
 | 
			
		||||
export default {
 | 
			
		||||
  props: {
 | 
			
		||||
    value: {
 | 
			
		||||
| 
						 | 
				
			
			@ -76,6 +75,17 @@ export default {
 | 
			
		|||
  mounted() {
 | 
			
		||||
    this.getDbList()
 | 
			
		||||
  },
 | 
			
		||||
  watch: {
 | 
			
		||||
    $route: {
 | 
			
		||||
      handler: function (val, oldVal) {
 | 
			
		||||
        if (val.query && val.query.id) {
 | 
			
		||||
          this.getDbList()
 | 
			
		||||
        }
 | 
			
		||||
      },
 | 
			
		||||
      deep: true,
 | 
			
		||||
      immediate: true,
 | 
			
		||||
    },
 | 
			
		||||
  },
 | 
			
		||||
  methods: {
 | 
			
		||||
    getBeforeHours(num) {
 | 
			
		||||
      let currentTime = moment()
 | 
			
		||||
| 
						 | 
				
			
			@ -94,8 +104,10 @@ export default {
 | 
			
		|||
          // 如果url中有sourceId
 | 
			
		||||
          if (sourceId) {
 | 
			
		||||
            const find = res.result.find((item) => item.sourceId == sourceId)
 | 
			
		||||
            if (find) {
 | 
			
		||||
            if (find && find.hostId) {
 | 
			
		||||
              this.value.hostId = find.hostId
 | 
			
		||||
            } else {
 | 
			
		||||
              this.value.hostId = `my${find.sourceId}`
 | 
			
		||||
            }
 | 
			
		||||
          }
 | 
			
		||||
          if (!this.value.hostId) {
 | 
			
		||||
| 
						 | 
				
			
			@ -103,7 +115,7 @@ export default {
 | 
			
		|||
          }
 | 
			
		||||
 | 
			
		||||
          this.DbOptions = res.result.map((item, index) => {
 | 
			
		||||
            let str = `my${index}`
 | 
			
		||||
            let str = `my${item.sourceId}`
 | 
			
		||||
            return {
 | 
			
		||||
              label: item.sourceName,
 | 
			
		||||
              value: item.hostId || str,
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -98,7 +98,7 @@
 | 
			
		|||
            <div class="email-top-content-li-right">
 | 
			
		||||
              <div class="email-top-content-li-right-title">Used Capacity</div>
 | 
			
		||||
              <div class="email-top-content-li-right-val" style="color: #ade6ee; font-size: 26px; margin-top: 36px">
 | 
			
		||||
                {{ emailTotal.usage || 0 }}/<span style="font-size: 40px; vertical-align: middle">∞</span>
 | 
			
		||||
                {{ emailSpace.usage || 0 }}/<span style="font-size: 40px; vertical-align: middle">∞</span>
 | 
			
		||||
              </div>
 | 
			
		||||
            </div>
 | 
			
		||||
            <div class="email-top-content-li-rect" style="background: #8351d4"></div>
 | 
			
		||||
| 
						 | 
				
			
			@ -239,7 +239,19 @@ export default {
 | 
			
		|||
  mounted() {
 | 
			
		||||
    this.getEmailList()
 | 
			
		||||
  },
 | 
			
		||||
  // activated() {
 | 
			
		||||
  //   this.getEmailList()
 | 
			
		||||
  // },
 | 
			
		||||
  watch: {
 | 
			
		||||
    $route: {
 | 
			
		||||
      handler: function (val, oldVal) {
 | 
			
		||||
        if (val.query && val.query.emailId) {
 | 
			
		||||
          this.getEmailList()
 | 
			
		||||
        }
 | 
			
		||||
      },
 | 
			
		||||
      deep: true,
 | 
			
		||||
      immediate: true,
 | 
			
		||||
    },
 | 
			
		||||
    emailId(newValue, oldValue) {
 | 
			
		||||
      this.currId = newValue
 | 
			
		||||
      this.getEmailStatus()
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -237,6 +237,17 @@ export default {
 | 
			
		|||
  mounted() {
 | 
			
		||||
    this.getServerList()
 | 
			
		||||
  },
 | 
			
		||||
  watch: {
 | 
			
		||||
    $route: {
 | 
			
		||||
      handler: function (val, oldVal) {
 | 
			
		||||
        if (val.query && val.query.serverId) {
 | 
			
		||||
          this.getServerList()
 | 
			
		||||
        }
 | 
			
		||||
      },
 | 
			
		||||
      deep: true,
 | 
			
		||||
      immediate: true,
 | 
			
		||||
    },
 | 
			
		||||
  },
 | 
			
		||||
  methods: {
 | 
			
		||||
    handleRefresh() {
 | 
			
		||||
      if (!this.userDefined) {
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -280,6 +280,7 @@
 | 
			
		|||
          <BoxTitle title="Alarm information"></BoxTitle>
 | 
			
		||||
          <div
 | 
			
		||||
            class="alarm-info-list"
 | 
			
		||||
            style="margin-bottom: 15px"
 | 
			
		||||
            v-infinite-scroll="handleInfiniteAlarmInfo"
 | 
			
		||||
            :infinite-scroll-disabled="busy_alarm_info"
 | 
			
		||||
            :infinite-scroll-distance="10"
 | 
			
		||||
| 
						 | 
				
			
			@ -451,48 +452,58 @@ export default {
 | 
			
		|||
      },
 | 
			
		||||
    }
 | 
			
		||||
  },
 | 
			
		||||
  mounted() {
 | 
			
		||||
    this.getSysServer((res) => {
 | 
			
		||||
      this.loading = false
 | 
			
		||||
      if (res.success) {
 | 
			
		||||
        this.ipagination.total = res.result.total
 | 
			
		||||
        this.dataSource = res.result.records
 | 
			
		||||
        if (this.$route.query.serverId) {
 | 
			
		||||
          this.serverId = this.$route.query.serverId
 | 
			
		||||
          this.currIndex = this.dataSource.findIndex((item) => item.sourceId === this.serverId)
 | 
			
		||||
          this.currHostId = this.dataSource.find((item) => item.sourceId === this.serverId).hostId
 | 
			
		||||
          this.currSourceId = this.dataSource.find((item) => item.sourceId === this.serverId).sourceId
 | 
			
		||||
          this.currItemId = this.dataSource.find((item) => item.sourceId === this.serverId).cpuUsedItemId
 | 
			
		||||
        } else {
 | 
			
		||||
          this.currHostId = this.dataSource[0].hostId
 | 
			
		||||
          this.currSourceId = this.dataSource[0].sourceId
 | 
			
		||||
          this.currItemId = this.dataSource[0].cpuUsedItemId
 | 
			
		||||
          this.currIndex = 0
 | 
			
		||||
  watch: {
 | 
			
		||||
    $route: {
 | 
			
		||||
      handler: function (val, oldVal) {
 | 
			
		||||
        if (val.query && val.query.serverId) {
 | 
			
		||||
          this.getData()
 | 
			
		||||
        }
 | 
			
		||||
        this.getBasiclnfo(this.currHostId)
 | 
			
		||||
        this.getCpuUtilizationData()
 | 
			
		||||
        this.getTimeLineData()
 | 
			
		||||
        // this.EchartsTimeline()
 | 
			
		||||
        this.getDetailsAlarmInfo((res) => {
 | 
			
		||||
          this.loading_alarm_info = false
 | 
			
		||||
          if (res.success) {
 | 
			
		||||
            this.ipagination_alarm_info.total = res.result.total
 | 
			
		||||
            this.dataSource_alarm_info = res.result.records
 | 
			
		||||
          } else {
 | 
			
		||||
            this.$message.warning('This operation fails. Contact your system administrator')
 | 
			
		||||
          }
 | 
			
		||||
        })
 | 
			
		||||
      } else {
 | 
			
		||||
        this.$message.warning('This operation fails. Contact your system administrator')
 | 
			
		||||
      }
 | 
			
		||||
    })
 | 
			
		||||
    // this.$nextTick(() => {
 | 
			
		||||
    //   setTimeout(() => {
 | 
			
		||||
    //     this.drawGuageLoads()
 | 
			
		||||
    //   }, 0)
 | 
			
		||||
    // })
 | 
			
		||||
      },
 | 
			
		||||
      deep: true,
 | 
			
		||||
      immediate: true,
 | 
			
		||||
    },
 | 
			
		||||
  },
 | 
			
		||||
  mounted() {
 | 
			
		||||
    this.getData()
 | 
			
		||||
  },
 | 
			
		||||
  // activated() {},
 | 
			
		||||
  methods: {
 | 
			
		||||
    getData() {
 | 
			
		||||
      this.getSysServer((res) => {
 | 
			
		||||
        this.loading = false
 | 
			
		||||
        if (res.success) {
 | 
			
		||||
          this.ipagination.total = res.result.total
 | 
			
		||||
          this.dataSource = res.result.records
 | 
			
		||||
          if (this.$route.query.serverId) {
 | 
			
		||||
            this.serverId = this.$route.query.serverId
 | 
			
		||||
            this.currIndex = this.dataSource.findIndex((item) => item.sourceId === this.serverId)
 | 
			
		||||
            this.currHostId = this.dataSource.find((item) => item.sourceId === this.serverId).hostId
 | 
			
		||||
            this.currSourceId = this.dataSource.find((item) => item.sourceId === this.serverId).sourceId
 | 
			
		||||
            this.currItemId = this.dataSource.find((item) => item.sourceId === this.serverId).cpuUsedItemId
 | 
			
		||||
          } else {
 | 
			
		||||
            this.currHostId = this.dataSource[0].hostId
 | 
			
		||||
            this.currSourceId = this.dataSource[0].sourceId
 | 
			
		||||
            this.currItemId = this.dataSource[0].cpuUsedItemId
 | 
			
		||||
            this.currIndex = 0
 | 
			
		||||
          }
 | 
			
		||||
          this.getBasiclnfo(this.currHostId)
 | 
			
		||||
          this.getCpuUtilizationData()
 | 
			
		||||
          this.getTimeLineData()
 | 
			
		||||
          // this.EchartsTimeline()
 | 
			
		||||
          this.getDetailsAlarmInfo((res) => {
 | 
			
		||||
            this.loading_alarm_info = false
 | 
			
		||||
            if (res.success) {
 | 
			
		||||
              this.ipagination_alarm_info.total = res.result.total
 | 
			
		||||
              this.dataSource_alarm_info = res.result.records
 | 
			
		||||
            } else {
 | 
			
		||||
              this.$message.warning('This operation fails. Contact your system administrator')
 | 
			
		||||
            }
 | 
			
		||||
          })
 | 
			
		||||
        } else {
 | 
			
		||||
          this.$message.warning('This operation fails. Contact your system administrator')
 | 
			
		||||
        }
 | 
			
		||||
      })
 | 
			
		||||
    },
 | 
			
		||||
    moment,
 | 
			
		||||
    // Basic lnformation
 | 
			
		||||
    getBasiclnfo(sourceId) {
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -166,6 +166,17 @@ export default {
 | 
			
		|||
  mounted() {
 | 
			
		||||
    this.getServerList()
 | 
			
		||||
  },
 | 
			
		||||
  watch: {
 | 
			
		||||
    $route: {
 | 
			
		||||
      handler: function (val, oldVal) {
 | 
			
		||||
        if (val.query && val.query.serverId) {
 | 
			
		||||
          this.getServerList()
 | 
			
		||||
        }
 | 
			
		||||
      },
 | 
			
		||||
      deep: true,
 | 
			
		||||
      immediate: true,
 | 
			
		||||
    },
 | 
			
		||||
  },
 | 
			
		||||
  methods: {
 | 
			
		||||
    handleRefresh() {
 | 
			
		||||
      if (!this.userDefined) {
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -74,35 +74,17 @@
 | 
			
		|||
        <div class="service-content-center">
 | 
			
		||||
          <a-row :gutter="20">
 | 
			
		||||
            <a-col :span="12">
 | 
			
		||||
              <BoxTitle title="Process CPU usage(%)">
 | 
			
		||||
                <!-- <template slot="right">
 | 
			
		||||
                <ul class="legend-list">
 | 
			
		||||
                  <li v-for="(item, index) in processCpu.legend" :key="index">
 | 
			
		||||
                    <div :style="`background:${processCpu.color[index]}`" class="li-icon"></div>
 | 
			
		||||
                    {{ item }}
 | 
			
		||||
                  </li>
 | 
			
		||||
                </ul>
 | 
			
		||||
              </template> -->
 | 
			
		||||
              </BoxTitle>
 | 
			
		||||
              <BoxTitle title="Process CPU usage(%)" />
 | 
			
		||||
              <div class="service-content-center-item" id="processCpu"></div>
 | 
			
		||||
            </a-col>
 | 
			
		||||
            <a-col :span="12">
 | 
			
		||||
              <BoxTitle title="Process memory usage(%)">
 | 
			
		||||
                <!-- <template slot="right">
 | 
			
		||||
                <ul class="legend-list">
 | 
			
		||||
                  <li v-for="(item, index) in processMenbry.legend" :key="index">
 | 
			
		||||
                    <div :style="`background:${processMenbry.color[index]}`" class="li-icon"></div>
 | 
			
		||||
                    {{ item }}
 | 
			
		||||
                  </li>
 | 
			
		||||
                </ul>
 | 
			
		||||
              </template> -->
 | 
			
		||||
              </BoxTitle>
 | 
			
		||||
              <BoxTitle title="Process memory usage(%)" />
 | 
			
		||||
              <div class="service-content-center-item" id="menbry"></div>
 | 
			
		||||
            </a-col>
 | 
			
		||||
          </a-row>
 | 
			
		||||
        </div>
 | 
			
		||||
        <div class="service-content-table">
 | 
			
		||||
          <BoxTitle title="Service"></BoxTitle>
 | 
			
		||||
          <BoxTitle title="Service" />
 | 
			
		||||
          <div style="padding-top: 10px">
 | 
			
		||||
            <TableList
 | 
			
		||||
              size="middle"
 | 
			
		||||
| 
						 | 
				
			
			@ -112,6 +94,7 @@
 | 
			
		|||
              :loading="loading"
 | 
			
		||||
              :pagination="false"
 | 
			
		||||
              :canSelect="false"
 | 
			
		||||
              :scroll="{ y: 186 }"
 | 
			
		||||
            >
 | 
			
		||||
            </TableList>
 | 
			
		||||
            <!-- <a-pagination
 | 
			
		||||
| 
						 | 
				
			
			@ -303,6 +286,17 @@ export default {
 | 
			
		|||
      setTimeout(() => {}, 0)
 | 
			
		||||
    })
 | 
			
		||||
  },
 | 
			
		||||
  watch: {
 | 
			
		||||
    $route: {
 | 
			
		||||
      handler: function (val, oldVal) {
 | 
			
		||||
        if (val.query && val.query.serverId) {
 | 
			
		||||
          this.getServerList()
 | 
			
		||||
        }
 | 
			
		||||
      },
 | 
			
		||||
      deep: true,
 | 
			
		||||
      immediate: true,
 | 
			
		||||
    },
 | 
			
		||||
  },
 | 
			
		||||
  methods: {
 | 
			
		||||
    handleRefresh() {
 | 
			
		||||
      if (!this.userDefined) {
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -17,7 +17,7 @@
 | 
			
		|||
      </template>
 | 
			
		||||
      <!-- 标题结束 -->
 | 
			
		||||
      <!-- 内容 -->
 | 
			
		||||
      <a-spin :spinning="isGettingTreeData" style="margin-top: 80px; width: 100%; text-align: center;"> </a-spin>
 | 
			
		||||
      <a-spin :spinning="isGettingTreeData" style="margin-top: 80px; width: 100%; text-align: center"> </a-spin>
 | 
			
		||||
      <tree-with-line
 | 
			
		||||
        v-if="treeData.length"
 | 
			
		||||
        :treeData="treeData"
 | 
			
		||||
| 
						 | 
				
			
			@ -57,7 +57,7 @@
 | 
			
		|||
    <!-- 日志列表结束 -->
 | 
			
		||||
    <custom-modal title="Log" :width="950" v-model="visible" :footer="null">
 | 
			
		||||
      <a-spin class="log-detail" :spinning="isGettingDetail">
 | 
			
		||||
        <div v-for="(logItem, index) in logInfo" :key="index">
 | 
			
		||||
        <div style="font-family: 宋体" v-for="(logItem, index) in logInfo" :key="index">
 | 
			
		||||
          {{ logItem }}
 | 
			
		||||
        </div>
 | 
			
		||||
      </a-spin>
 | 
			
		||||
| 
						 | 
				
			
			@ -74,42 +74,42 @@ const columns = [
 | 
			
		|||
    title: 'NAME',
 | 
			
		||||
    align: 'center',
 | 
			
		||||
    width: 320,
 | 
			
		||||
    dataIndex: 'fileName'
 | 
			
		||||
    dataIndex: 'fileName',
 | 
			
		||||
  },
 | 
			
		||||
  {
 | 
			
		||||
    title: 'DATE',
 | 
			
		||||
    align: 'center',
 | 
			
		||||
    width: 200,
 | 
			
		||||
    dataIndex: 'fileDate'
 | 
			
		||||
    dataIndex: 'fileDate',
 | 
			
		||||
  },
 | 
			
		||||
  {
 | 
			
		||||
    title: 'SIZE',
 | 
			
		||||
    align: 'center',
 | 
			
		||||
    width: 220,
 | 
			
		||||
    dataIndex: 'fileSize'
 | 
			
		||||
    dataIndex: 'fileSize',
 | 
			
		||||
  },
 | 
			
		||||
  {
 | 
			
		||||
    title: 'OPERATE',
 | 
			
		||||
    align: 'center',
 | 
			
		||||
    width: 200,
 | 
			
		||||
    scopedSlots: {
 | 
			
		||||
      customRender: 'operate'
 | 
			
		||||
    }
 | 
			
		||||
  }
 | 
			
		||||
      customRender: 'operate',
 | 
			
		||||
    },
 | 
			
		||||
  },
 | 
			
		||||
]
 | 
			
		||||
 | 
			
		||||
export default {
 | 
			
		||||
  name: 'LogManage',
 | 
			
		||||
  mixins: [JeecgListMixin],
 | 
			
		||||
  components: {
 | 
			
		||||
    TreeWithLine
 | 
			
		||||
    TreeWithLine,
 | 
			
		||||
  },
 | 
			
		||||
  data() {
 | 
			
		||||
    this.columns = columns
 | 
			
		||||
    return {
 | 
			
		||||
      disableMixinCreated: true,
 | 
			
		||||
      url: {
 | 
			
		||||
        list: '/logManage/findFiles'
 | 
			
		||||
        list: '/logManage/findFiles',
 | 
			
		||||
      },
 | 
			
		||||
      isGettingTreeData: false, // 正在获取左侧树信息
 | 
			
		||||
      treeData: [],
 | 
			
		||||
| 
						 | 
				
			
			@ -119,7 +119,7 @@ export default {
 | 
			
		|||
 | 
			
		||||
      visible: false,
 | 
			
		||||
      isGettingDetail: false,
 | 
			
		||||
      logInfo: []
 | 
			
		||||
      logInfo: [],
 | 
			
		||||
    }
 | 
			
		||||
  },
 | 
			
		||||
  created() {
 | 
			
		||||
| 
						 | 
				
			
			@ -148,11 +148,11 @@ export default {
 | 
			
		|||
     */
 | 
			
		||||
    buildTreeData(treeJson) {
 | 
			
		||||
      const tree = []
 | 
			
		||||
      treeJson.forEach(item => {
 | 
			
		||||
      treeJson.forEach((item) => {
 | 
			
		||||
        const treeNode = {
 | 
			
		||||
          title: item.name,
 | 
			
		||||
          key: item.path,
 | 
			
		||||
          children: []
 | 
			
		||||
          children: [],
 | 
			
		||||
        }
 | 
			
		||||
        if (item.children && item.children.length) {
 | 
			
		||||
          treeNode.children.push(...this.buildTreeData(item.children))
 | 
			
		||||
| 
						 | 
				
			
			@ -180,7 +180,7 @@ export default {
 | 
			
		|||
      var params = this.getQueryParams() //查询条件
 | 
			
		||||
      this.loading = true
 | 
			
		||||
      getAction(this.url.list, params)
 | 
			
		||||
        .then(res => {
 | 
			
		||||
        .then((res) => {
 | 
			
		||||
          this.dataSource = res
 | 
			
		||||
        })
 | 
			
		||||
        .finally(() => {
 | 
			
		||||
| 
						 | 
				
			
			@ -216,8 +216,8 @@ export default {
 | 
			
		|||
      formData.append('fileName', fileName)
 | 
			
		||||
      formData.append('localPath', filePath)
 | 
			
		||||
      downloadFile('/logManage/downloadFile', fileName, formData, 'post')
 | 
			
		||||
    }
 | 
			
		||||
  }
 | 
			
		||||
    },
 | 
			
		||||
  },
 | 
			
		||||
}
 | 
			
		||||
</script>
 | 
			
		||||
<style lang="less" scoped>
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -28,6 +28,10 @@
 | 
			
		|||
        {{ index + 1 }}
 | 
			
		||||
      </template>
 | 
			
		||||
    </custom-table>
 | 
			
		||||
    <!-- 日志列表结束 -->
 | 
			
		||||
    <custom-modal title="List Of File Deletion Failures" :width="950" v-model="visibleInfo" :footer="null">
 | 
			
		||||
      <a-table :columns="columnsModal" :data-source="dataInfo" :pagination="false"> </a-table>
 | 
			
		||||
    </custom-modal>
 | 
			
		||||
  </div>
 | 
			
		||||
</template>
 | 
			
		||||
 | 
			
		||||
| 
						 | 
				
			
			@ -163,11 +167,24 @@ const columns = [
 | 
			
		|||
    dataIndex: 'status',
 | 
			
		||||
  },
 | 
			
		||||
]
 | 
			
		||||
const columnsModal = [
 | 
			
		||||
  {
 | 
			
		||||
    title: 'Index',
 | 
			
		||||
    dataIndex: 'rowCount',
 | 
			
		||||
    align: 'center',
 | 
			
		||||
  },
 | 
			
		||||
  {
 | 
			
		||||
    title: 'Information',
 | 
			
		||||
    dataIndex: 'info',
 | 
			
		||||
    align: 'left',
 | 
			
		||||
  },
 | 
			
		||||
]
 | 
			
		||||
 | 
			
		||||
export default {
 | 
			
		||||
  mixins: [JeecgListMixin],
 | 
			
		||||
  data() {
 | 
			
		||||
    this.columns = columns
 | 
			
		||||
    this.columnsModal = columnsModal
 | 
			
		||||
    return {
 | 
			
		||||
      queryParam: {
 | 
			
		||||
        collectStart: this.getBeforeDate(6),
 | 
			
		||||
| 
						 | 
				
			
			@ -183,6 +200,8 @@ export default {
 | 
			
		|||
      },
 | 
			
		||||
      stationList: [],
 | 
			
		||||
      detectorList: [],
 | 
			
		||||
      visibleInfo: false,
 | 
			
		||||
      dataInfo: [],
 | 
			
		||||
    }
 | 
			
		||||
  },
 | 
			
		||||
  created() {
 | 
			
		||||
| 
						 | 
				
			
			@ -264,7 +283,7 @@ export default {
 | 
			
		|||
          cancelText: 'Cancel',
 | 
			
		||||
          onOk: async () => {
 | 
			
		||||
            try {
 | 
			
		||||
              const { success, message } = await deleteAction('/gardsSampleData/deleteById', {
 | 
			
		||||
              const { success, message, result } = await deleteAction('/gardsSampleData/deleteById', {
 | 
			
		||||
                sampleId: this.selectedRowKeys[0],
 | 
			
		||||
                ...this.delParams,
 | 
			
		||||
              })
 | 
			
		||||
| 
						 | 
				
			
			@ -273,6 +292,13 @@ export default {
 | 
			
		|||
                that.loadData()
 | 
			
		||||
              } else {
 | 
			
		||||
                this.$message.error(message)
 | 
			
		||||
                this.visibleInfo = true
 | 
			
		||||
                this.dataInfo = result.map((item, index) => {
 | 
			
		||||
                  return {
 | 
			
		||||
                    rowCount: `${index + 1}`,
 | 
			
		||||
                    info: item,
 | 
			
		||||
                  }
 | 
			
		||||
                })
 | 
			
		||||
              }
 | 
			
		||||
            } catch (error) {
 | 
			
		||||
              console.error(error)
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
		Reference in New Issue
	
	Block a user