Hwt 2 년 전
부모
커밋
ba38227bca

+ 205 - 201
operationSupport/src/components/common/SelectTree.vue

@@ -1,224 +1,228 @@
 <!-- 树状选择器 -->
 <template>
-    <div>
-        <el-popover
-            v-if="!disabled"
-            class="selecttree-box"
-            ref="popover"
-            placement="bottom-start"
-            trigger="click"
-            @show="onShowPopover"
-            @hide="onHidePopover"
+  <div>
+    <el-popover
+      v-if="!disabled"
+      class="selecttree-box"
+      ref="popover"
+      placement="bottom-start"
+      trigger="click"
+      @show="onShowPopover"
+      @hide="onHidePopover"
+    >
+      <p class="select-tree-title">{{ selectTreeTitle }}</p>
+      <el-scrollbar>
+        <el-tree
+          ref="tree"
+          class="select-tree"
+          highlight-current
+          :style="`min-width: ${treeWidth}`"
+          :data="data"
+          :props="props"
+          :expand-on-click-node="false"
+          :filter-node-method="filterNode"
+          :default-expand-all="true"
+          @node-click="onClickNode"
         >
-            <p class="select-tree-title">{{ selectTreeTitle }}</p>
-            <el-scrollbar>
-                <el-tree
-                    ref="tree"
-                    class="select-tree"
-                    highlight-current
-                    :style="`min-width: ${treeWidth}`"
-                    :data="data"
-                    :props="props"
-                    :expand-on-click-node="false"
-                    :filter-node-method="filterNode"
-                    :default-expand-all="true"
-                    @node-click="onClickNode"
-                >
-                </el-tree>
-            </el-scrollbar>
-            <el-input
-                slot="reference"
-                ref="input"
-                v-model="labelModel"
-                clearable
-                :style="`width: ${width}px`"
-                :class="{ rotate: showStatus }"
-                suffix-icon="el-icon-arrow-down"
-                :placeholder="placeholder"
-            >
-            </el-input>
-        </el-popover>
-        <div v-else>
-            <el-input type="text" :disabled="disabled" :value="labelModel"></el-input>
-        </div>
+        </el-tree>
+      </el-scrollbar>
+      <el-input
+        slot="reference"
+        ref="input"
+        v-model="labelModel"
+        clearable
+        :style="`width: ${width}px`"
+        :class="{ rotate: showStatus }"
+        suffix-icon="el-icon-arrow-down"
+        :placeholder="placeholder"
+      >
+      </el-input>
+    </el-popover>
+    <div v-else>
+      <el-input
+        type="text"
+        :disabled="disabled"
+        :value="labelModel"
+      ></el-input>
     </div>
+  </div>
 </template>
 
 <script>
 export default {
-    name: 'SelectTree',
+  name: 'SelectTree',
+  props: {
+    // 接收绑定参数
+    value: String,
+    // 输入框宽度
+    width: String,
+    // selectTreeTitle
+    selectTreeTitle: String,
+    // 选项数据
+    options: {
+      type: Array,
+      required: true
+    },
+    // 输入框占位符
+    placeholder: {
+      type: String,
+      required: false,
+      default: '请选择'
+    },
+    // 树节点配置选项
     props: {
-        // 接收绑定参数
-        value: String,
-        // 输入框宽度
-        width: String,
-        // selectTreeTitle
-        selectTreeTitle: String,
-        // 选项数据
-        options: {
-            type: Array,
-            required: true
-        },
-        // 输入框占位符
-        placeholder: {
-            type: String,
-            required: false,
-            default: '请选择'
-        },
-        // 树节点配置选项
-        props: {
-            type: Object,
-            required: false,
-            default: () => ({
-                parent: 'parentId',
-                value: 'id',
-                label: 'label',
-                children: 'children'
-            })
-        },
-        disabled: {
-            type: Boolean,
-            required: false,
-            default: () => {
-                return false;
-            }
-        }
+      type: Object,
+      required: false,
+      default: () => ({
+        parent: 'parentId',
+        value: 'id',
+        label: 'label',
+        children: 'children'
+      })
     },
-    // 设置绑定参数
-    model: {
-        prop: 'value',
-        event: 'selected'
+    disabled: {
+      type: Boolean,
+      required: false,
+      default: () => {
+        return false;
+      }
+    }
+  },
+  // 设置绑定参数
+  model: {
+    prop: 'value',
+    event: 'selected'
+  },
+  computed: {
+    // 是否为树状结构数据
+    dataType () {
+      const jsonStr = JSON.stringify(this.options);
+      return jsonStr.indexOf(this.props.children) !== -1;
     },
-    computed: {
-        // 是否为树状结构数据
-        dataType() {
-            const jsonStr = JSON.stringify(this.options);
-            return jsonStr.indexOf(this.props.children) !== -1;
-        },
-        // 若非树状结构,则转化为树状结构数据
-        data() {
-            return this.dataType ? this.options : this.switchTree();
+    // 若非树状结构,则转化为树状结构数据
+    data () {
+      return this.dataType ? this.options : this.switchTree();
+    }
+  },
+  watch: {
+    labelModel (val) {
+      if (this.disabled) {
+        return;
+      } else {
+        if (!val) {
+          this.valueModel = '';
         }
+        this.$refs.tree.filter(val);
+      }
     },
-    watch: {
-        labelModel(val) {
-            if (this.disabled) {
-                return;
-            } else {
-                if (!val) {
-                    this.valueModel = '';
-                }
-                this.$refs.tree.filter(val);
-            }
-        },
-        value(val) {
-            this.labelModel = this.queryTree(this.data, val);
-        }
+    value (val) {
+      this.labelModel = this.queryTree(this.data, val);
+    }
+  },
+  data () {
+    return {
+      // 树状菜单显示状态
+      showStatus: false,
+      // 菜单宽度
+      treeWidth: 'auto',
+      // 输入框显示值
+      labelModel: '',
+      // 实际请求传值
+      valueModel: ''
+    };
+  },
+  created () {
+    // 检测输入框原有值并显示对应 label
+    if (this.value) {
+      this.labelModel = this.queryTree(this.data, this.value);
+    }
+    if (this.disabled) {
+      return;
+    } else {
+      // 获取输入框宽度同步至树状菜单宽度
+      this.$nextTick(() => {
+        this.treeWidth = `${(this.width || this.$refs.input.$refs.input.clientWidth) - 24}px`;
+      });
+    }
+  },
+  methods: {
+    // 单击节点
+    onClickNode (node) {
+      this.labelModel = node[this.props.label];
+      this.valueModel = node[this.props.value];
+      this.onCloseTree();
+    },
+    // 偏平数组转化为树状层级结构
+    switchTree () {
+      return this.cleanChildren(this.buildTree(this.options, '0'));
+    },
+    // 隐藏树状菜单
+    onCloseTree () {
+      this.$refs.popover.showPopper = false;
     },
-    data() {
-        return {
-            // 树状菜单显示状态
-            showStatus: false,
-            // 菜单宽度
-            treeWidth: 'auto',
-            // 输入框显示值
-            labelModel: '',
-            // 实际请求传值
-            valueModel: ''
-        };
+    // 显示时触发
+    onShowPopover () {
+      // if(this.disabled)
+      this.showStatus = true;
+      this.$refs.tree.filter(false);
     },
-    created() {
-        // 检测输入框原有值并显示对应 label
-        if (this.value) {
-            this.labelModel = this.queryTree(this.data, this.value);
+    // 隐藏时触发
+    onHidePopover () {
+      this.showStatus = false;
+      this.$emit('selected', this.valueModel);
+      this.$emit('selectedLable', this.labelModel);
+    },
+    // 树节点过滤方法
+    filterNode (query, data) {
+      if (!query) return true;
+      return data[this.props.label].indexOf(query) !== -1;
+    },
+    // 搜索树状数据中的 ID
+    queryTree (tree, id) {
+      let stark = [];
+      stark = stark.concat(tree);
+      while (stark.length) {
+        const temp = stark.shift();
+        if (temp[this.props.children]) {
+          stark = stark.concat(temp[this.props.children]);
         }
-        if (this.disabled) {
-            return;
-        } else {
-            // 获取输入框宽度同步至树状菜单宽度
-            this.$nextTick(() => {
-                this.treeWidth = `${(this.width || this.$refs.input.$refs.input.clientWidth) - 24}px`;
-            });
+        if (temp[this.props.value] === id) {
+          return temp[this.props.label];
         }
+      }
+      return '';
     },
-    methods: {
-        // 单击节点
-        onClickNode(node) {
-            this.labelModel = node[this.props.label];
-            this.valueModel = node[this.props.value];
-            this.onCloseTree();
-        },
-        // 偏平数组转化为树状层级结构
-        switchTree() {
-            return this.cleanChildren(this.buildTree(this.options, '0'));
-        },
-        // 隐藏树状菜单
-        onCloseTree() {
-            this.$refs.popover.showPopper = false;
-        },
-        // 显示时触发
-        onShowPopover() {
-            // if(this.disabled)
-            this.showStatus = true;
-            this.$refs.tree.filter(false);
-        },
-        // 隐藏时触发
-        onHidePopover() {
-            this.showStatus = false;
-            this.$emit('selected', this.valueModel);
-            this.$emit('selectedLable', this.labelModel);
-        },
-        // 树节点过滤方法
-        filterNode(query, data) {
-            if (!query) return true;
-            return data[this.props.label].indexOf(query) !== -1;
-        },
-        // 搜索树状数据中的 ID
-        queryTree(tree, id) {
-            let stark = [];
-            stark = stark.concat(tree);
-            while (stark.length) {
-                const temp = stark.shift();
-                if (temp[this.props.children]) {
-                    stark = stark.concat(temp[this.props.children]);
-                }
-                if (temp[this.props.value] === id) {
-                    return temp[this.props.label];
-                }
-            }
-            return '';
-        },
-        // 将一维的扁平数组转换为多层级对象
-        buildTree(data, id = '0') {
-            const fa = (parentId) => {
-                const temp = [];
-                for (let i = 0; i < data.length; i++) {
-                    const n = data[i];
-                    if (n[this.props.parent] === parentId) {
-                        n.children = fa(n.rowGuid);
-                        temp.push(n);
-                    }
-                }
-                return temp;
-            };
-            return fa(id);
-        },
-        // 清除空 children项
-        cleanChildren(data) {
-            const fa = (list) => {
-                list.map((e) => {
-                    if (e.children.length) {
-                        fa(e.children);
-                    } else {
-                        delete e.children;
-                    }
-                    return e;
-                });
-                return list;
-            };
-            return fa(data);
+    // 将一维的扁平数组转换为多层级对象
+    buildTree (data, id = '0') {
+      const fa = (parentId) => {
+        const temp = [];
+        for (let i = 0; i < data.length; i++) {
+          const n = data[i];
+          if (n[this.props.parent] === parentId) {
+            n.children = fa(n.rowGuid);
+            temp.push(n);
+          }
         }
+        return temp;
+      };
+      return fa(id);
+    },
+    // 清除空 children项
+    cleanChildren (data) {
+      const fa = (list) => {
+        list.map((e) => {
+          if (e.children.length) {
+            fa(e.children);
+          } else {
+            delete e.children;
+          }
+          return e;
+        });
+        return list;
+      };
+      return fa(data);
     }
+  }
 };
 </script>
 

+ 5 - 6
operationSupport/src/utils/http.js

@@ -69,8 +69,7 @@ http.interceptors.response.use(
                             window.relogin = false;
                             localStorage.removeItem('SC_token');
                         })
-                        .catch(() => { });
-
+                        .catch(() => {});
                 } else if (data == 1) {
                     ELEMENT.MessageBox('该账号已在其他地址登录,如需访问请重新登录', '提示', 'warning', {
                         confirmButtonText: '确定',
@@ -80,10 +79,10 @@ http.interceptors.response.use(
                             window.open(config.loginUrl, '_self');
                             window.relogin = false;
                             localStorage.removeItem('SC_token');
-                            sessionStorage.removeItem("tabs");
+                            sessionStorage.removeItem('tabs');
                             localStorage.removeItem('menupath');
                         })
-                        .catch(() => { });
+                        .catch(() => {});
                 } else {
                     Vue.prototype
                         .$msgBox('你的账号已被停用,如有问题请联系管理员', '', 'warning', {
@@ -97,12 +96,12 @@ http.interceptors.response.use(
                             window.relogin = false;
                             localStorage.removeItem('SC_token');
                         })
-                        .catch(() => { });
+                        .catch(() => {});
                 }
             });
             return;
         }
-        if (axios.isCancel(err)) return new Promise(() => { }); // 取消请求的情况下,终端Promise调用链
+        if (axios.isCancel(err)) return new Promise(() => {}); // 取消请求的情况下,终端Promise调用链
         return Promise.reject(err);
     }
 );

+ 320 - 272
operationSupport/src/views/performanceManagement/performanceEvaluation/index.vue

@@ -1,302 +1,350 @@
 <!--
  * @Description: 
  * @Date: 2021-05-08 08:41:26
- * @LastEditTime: 2021-05-20 08:26:36
+ * @LastEditTime: 2022-09-26 17:30:31
  * @FilePath: \WEB\maintenanceManagement\src\views\performanceManage\performanceEvaluation\performanceEvaluation.vue
 -->
 <template>
-    <div style="padding-right: 20px">
-        <div class="handle-box">
-            <el-input class="servertype-serch" v-model.trim="mixins_query.userName" placeholder="请输入用户名"></el-input>
-            <select-tree
-                class="new-select-tree"
-                selectTreeTitle="所属公司"
-                placeholder="请选择所属公司"
-                :options="organListCompany"
-                :props="defaultProps"
-                @selected="selectedcompanyOrgId"
-                v-model="mixins_query.companyOrgId"
-            >
-            </select-tree>
-            <select-tree
-                class="new-select-tree"
-                selectTreeTitle="所属部门"
-                placeholder="请选择所属部门"
-                :options="organListdepartment"
-                :props="defaultProps"
-                v-model="mixins_query.deptOrgId"
-            >
-            </select-tree>
-            <el-select clearable class="servertype-serch" v-model="mixins_query.state" placeholder="请选择考评状态">
-                <el-option v-for="(item, index) in allServiceStatu" :key="index" :label="item.label" :value="item.id">{{
+  <div style="padding-right: 20px">
+    <div class="handle-box">
+      <el-input
+        class="servertype-serch"
+        v-model.trim="mixins_query.userName"
+        placeholder="请输入用户名"
+      ></el-input>
+      <select-tree
+        class="new-select-tree"
+        selectTreeTitle="所属公司"
+        placeholder="请选择所属公司"
+        :options="organListCompany"
+        :props="defaultProps"
+        v-model="mixins_query.companyOrgId"
+      >
+        <!--  @selected="selectedcompanyOrgId" -->
+      </select-tree>
+      <select-tree
+        class="new-select-tree"
+        selectTreeTitle="所属部门"
+        placeholder="请选择所属部门"
+        :options="organListdepartment"
+        :props="defaultProps"
+        v-model="mixins_query.deptOrgId"
+      >
+      </select-tree>
+      <el-select
+        clearable
+        class="servertype-serch"
+        v-model="mixins_query.state"
+        placeholder="请选择考评状态"
+      >
+        <el-option
+          v-for="(item, index) in allServiceStatu"
+          :key="index"
+          :label="item.label"
+          :value="item.id"
+        >{{
                     item.label
                 }}</el-option>
-            </el-select>
-            <el-date-picker
-                v-show="mixins_query.cycle == 0"
-                :clearable="false"
-                class="servertype-serch"
-                v-model="days"
-                type="month"
-                placeholder="请选择月"
-                format="yyyy年MM月"
-            ></el-date-picker>
-            <datepicker-quarter
-                v-show="mixins_query.cycle == 1"
-                :clearable="false"
-                class="servertype-serch"
-                type="quarter"
-                placeholder="请选择季"
-                value-format="yyyy年MM季度"
-                @change-quarter="changeQuarter"
-            ></datepicker-quarter>
-            <el-date-picker
-                v-show="mixins_query.cycle == 2"
-                :clearable="false"
-                class="servertype-serch"
-                v-model="days"
-                type="year"
-                placeholder="请选择年"
-                format="yyyy年"
-            ></el-date-picker>
+      </el-select>
+      <el-date-picker
+        v-show="mixins_query.cycle == 0"
+        :clearable="false"
+        class="servertype-serch"
+        v-model="days"
+        type="month"
+        placeholder="请选择月"
+        format="yyyy年MM月"
+      ></el-date-picker>
+      <datepicker-quarter
+        v-show="mixins_query.cycle == 1"
+        :clearable="false"
+        class="servertype-serch"
+        type="quarter"
+        placeholder="请选择季"
+        value-format="yyyy年MM季度"
+        @change-quarter="changeQuarter"
+      ></datepicker-quarter>
+      <el-date-picker
+        v-show="mixins_query.cycle == 2"
+        :clearable="false"
+        class="servertype-serch"
+        v-model="days"
+        type="year"
+        placeholder="请选择年"
+        format="yyyy年"
+      ></el-date-picker>
 
-            <el-radio-group v-model="mixins_query.cycle" class="mr20 self-el-radio-group-box">
-                <el-radio :label="0">月度</el-radio>
-                <el-radio :label="1">季度</el-radio>
-                <el-radio :label="2">年度</el-radio>
-            </el-radio-group>
+      <el-radio-group
+        v-model="mixins_query.cycle"
+        class="mr20 self-el-radio-group-box"
+      >
+        <el-radio :label="0">月度</el-radio>
+        <el-radio :label="1">季度</el-radio>
+        <el-radio :label="2">年度</el-radio>
+      </el-radio-group>
 
-            <el-button type="primary" class="search-btn" @click="getlistpage" icon="el-icon-search">查询 </el-button>
-            <!-- <i class="fr fr-fs-fc fr-add iconfont" @click="openEvaluationHandle" v-left-txt-tip data-txt="新增">&#xe641;</i>
+      <el-button
+        type="primary"
+        class="search-btn"
+        @click="getlistpage"
+        icon="el-icon-search"
+      >查询 </el-button>
+      <!-- <i class="fr fr-fs-fc fr-add iconfont" @click="openEvaluationHandle" v-left-txt-tip data-txt="新增">&#xe641;</i>
             <i class="fr fr-fs-fc fr-del iconfont" @click="delusergroup" v-txt-tip data-txt="删除">&#xe63b;</i> -->
-        </div>
+    </div>
 
-        <!-- 表格 -->
-        <div class="device-manage-table">
-            <zz-table
-                :cols="cols"
-                :settings="{ showCheckbox: false, showIndex: true, stripe: true }"
-                :loading="mixins_onQuery"
-                :data="mixins_list"
-                :pageset="mixins_pageset"
-                @page-change="pageChange"
-                @selection-change="selectionChange"
+    <!-- 表格 -->
+    <div class="device-manage-table">
+      <zz-table
+        :cols="cols"
+        :settings="{ showCheckbox: false, showIndex: true, stripe: true }"
+        :loading="mixins_onQuery"
+        :data="mixins_list"
+        :pageset="mixins_pageset"
+        @page-change="pageChange"
+        @selection-change="selectionChange"
+      >
+        <template
+          slot-scope="scope"
+          slot="statecolor"
+        >
+          <span
+            v-if="scope.row.state === '未考评'"
+            style="color: #fd3a68"
+          >{{ scope.row.state }}</span>
+          <span
+            v-else
+            style="color: #21d4dc"
+          >{{ scope.row.state }}</span>
+        </template>
+        <template
+          slot-scope="scope"
+          slot="opt"
+        >
+          <div class="opt">
+            <el-tooltip
+              effect="light"
+              placement="bottom"
+              content="考评"
             >
-                <template slot-scope="scope" slot="statecolor">
-                    <span v-if="scope.row.state === '未考评'" style="color: #fd3a68">{{ scope.row.state }}</span>
-                    <span v-else style="color: #21d4dc">{{ scope.row.state }}</span>
-                </template>
-                <template slot-scope="scope" slot="opt">
-                    <div class="opt">
-                        <el-tooltip effect="light" placement="bottom" content="考评">
-                            <i class="iconfont" @click="openEvaluationHandle(scope.row)">&#xe645;</i>
-                        </el-tooltip>
-                        <el-tooltip effect="light" placement="bottom" content="详情">
-                            <i class="zoniot_font zoniot-icon-xiangqing" @click="openEvaluationDetile(scope.row)"></i>
-                        </el-tooltip>
-                    </div>
-                </template>
-            </zz-table>
-        </div>
+              <i
+                class="iconfont"
+                @click="openEvaluationHandle(scope.row)"
+              >&#xe645;</i>
+            </el-tooltip>
+            <el-tooltip
+              effect="light"
+              placement="bottom"
+              content="详情"
+            >
+              <i
+                class="zoniot_font zoniot-icon-xiangqing"
+                @click="openEvaluationDetile(scope.row)"
+              ></i>
+            </el-tooltip>
+          </div>
+        </template>
+      </zz-table>
     </div>
+  </div>
 </template>
 
 <script>
 import list from '@utils/list.js';
 export default {
-    mixins: [list],
-    data() {
-        return {
-            mixins_query: {
-                userName: '',
-                companyOrgId: '',
-                deptOrgId: '',
-                state: '',
-                cycle: 0,
-                year: '',
-                month: '',
-                sort: 1
-            },
-            days: new Date(),
-            lastQuarter: '',
-            scenetypeList: [],
-            organListCompany: '',
-            organListdepartment: '',
-            allServiceStatu: [
-                {
-                    id: 1,
-                    label: '已考评'
-                },
-                {
-                    id: 0,
-                    label: '未考评'
-                }
-            ],
-            defaultProps: {
-                value: 'id', // 唯一标识
-                label: 'orgName', // 标签显示
-                children: 'orgs' // 子级
-            },
-            selectRow: '',
-            allSelectRow: [],
-            cols: [
-                {
-                    label: '用户名',
-                    prop: 'evaluationBe'
-                },
-                {
-                    label: '所属公司',
-                    prop: 'companyOrgName'
-                },
-                {
-                    label: '所属部门',
-                    prop: 'deptOrgName'
-                },
-                {
-                    label: '考评状态',
-                    prop: 'state',
-                    slot: 'statecolor'
-                },
-                {
-                    label: '考评周期',
-                    prop: 'cycle'
-                },
-                {
-                    label: '操作',
-                    prop: 'opt',
-                    slot: 'opt'
-                }
-            ]
-        };
-    },
-    created() {
-        this.getorgTree();
-        this.getlistpage();
-    },
-    methods: {
-        getlistpage() {
-            switch (this.mixins_query.cycle) {
-                case 0:
-                    this.mixins_query.month = this.days.getMonth() + 1;
-                    this.mixins_query.year = this.days.getFullYear();
-                    break;
-                case 1:
-                    this.mixins_query.month = this.lastQuarter.season;
-                    this.mixins_query.year = this.lastQuarter.year;
-                    break;
-                case 2:
-                    this.mixins_query.month = '';
-                    this.mixins_query.year = this.days.getFullYear();
-                    break;
-                default:
-                    break;
-            }
-            this.mixins_dataUrl = '/sc-community/evaluation/result/find/page';
-            this.mixins_pageset = {
-                pageNum: this.mixins_pageset.pageNum,
-                pageSize: this.mixins_pageset.pageSize
-            };
-            this.mixins_post = 'post';
-            this.mixins_search();
+  mixins: [list],
+  data () {
+    return {
+      mixins_query: {
+        userName: '',
+        companyOrgId: '',
+        deptOrgId: '',
+        state: '',
+        cycle: 0,
+        year: '',
+        month: '',
+        sort: 1
+      },
+      days: new Date(),
+      lastQuarter: '',
+      scenetypeList: [],
+      organListCompany: '',
+      organListdepartment: '',
+      allServiceStatu: [
+        {
+          id: 1,
+          label: '已考评'
         },
-        changeQuarter(val) {
-            this.lastQuarter = val;
+        {
+          id: 0,
+          label: '未考评'
+        }
+      ],
+      defaultProps: {
+        value: 'id', // 唯一标识
+        label: 'orgName', // 标签显示
+        children: 'orgs' // 子级
+      },
+      selectRow: '',
+      allSelectRow: [],
+      cols: [
+        {
+          label: '用户名',
+          prop: 'evaluationBe'
         },
-        openEvaluationHandle(item) {
-            let row = {};
-            new Promise((resolve) => {
-                this.$http.postForm('/sc-community/evaluation/task/find', { evaluationResultId: item.id }).then(({ status, data, msg }) => {
-                    if (status === 0) {
-                        row = data;
-                        resolve();
-                    } else {
-                        this.$message.error(msg);
-                    }
-                });
-            }).then(() => {
-                new Promise((resolve) => {
-                    this.$store.dispatch('openModal', {
-                        url: '/performanceManagement/performanceEvaluation/popups/evaluationEdit.vue',
-                        width: '1200px',
-                        height: '510px',
-                        props: {
-                            rowInfo: item,
-                            data: row,
-                            year: this.mixins_query.year,
-                            month: this.mixins_query.month,
-                            callback: resolve
-                        },
-                        title: '考评',
-                        notip: true,
-                        confirmButtonText: '确定',
-                        showCancelButton: item.state === '未考评' ? false : true,
-                        showConfirmButton: item.state === '未考评' ? false : true
-                    });
-                }).then(() => {
-                    this.mixins_search();
-                });
-            });
+        {
+          label: '所属公司',
+          prop: 'companyOrgName'
         },
-        openEvaluationDetile(item) {
-            let row = {};
-            new Promise((resolve) => {
-                this.$http.postForm('/sc-community/evaluation/task/find', { evaluationResultId: item.id }).then(({ status, data, msg }) => {
-                    if (status === 0) {
-                        row = data;
-                        resolve();
-                    } else {
-                        this.$message.error(msg);
-                    }
-                });
-            }).then(() => {
-                new Promise((resolve) => {
-                    this.$store.dispatch('openModal', {
-                        url: '/performanceManagement/performanceEvaluation/popups/evaluationDetail.vue',
-                        width: '1200px',
-                        height: '510px',
-                        props: {
-                            rowInfo: item,
-                            data: row,
-                            cycle: this.mixins_query.cycle,
-                            year: this.mixins_query.year,
-                            month: this.mixins_query.month,
-                            callback: resolve
-                        },
-                        title: '考评详情',
-                        notip: true,
-                        showCancelButton: true,
-                        showConfirmButton: true
-                    });
-                }).then(() => {
-                    // this.mixins_search();
-                });
-            });
+        {
+          label: '所属部门',
+          prop: 'deptOrgName'
         },
-        selectionChange(val) {
-            this.selectRow = val;
+        {
+          label: '考评状态',
+          prop: 'state',
+          slot: 'statecolor'
         },
-        getorgTree() {
-            // 获取公司树
-            this.$http.postForm('/sc-user-center/org/getOrgUserTree', { orgType: 'company', id: '000' }).then(({ status, data, msg }) => {
-                if (status === 0 && data) {
-                    this.organListCompany = data;
-                } else {
-                    this.$message.error(msg);
-                }
-            });
+        {
+          label: '考评周期',
+          prop: 'cycle'
         },
-        selectedcompanyOrgId(e) {
-            if (!e) return;
-            // 获取 部门树e
-            this.$http.postForm('/user-center/org/getOrgUserTree', { orgType: 'department', id: e }).then(({ status, data, msg }) => {
-                if (status === 0) {
-                    this.organListdepartment = data ? data : [];
-                } else {
-                    this.$message.error(msg);
-                }
-            });
+        {
+          label: '操作',
+          prop: 'opt',
+          slot: 'opt'
+        }
+      ]
+    };
+  },
+  created () {
+    this.getorgTree();
+    this.getlistpage();
+  },
+  methods: {
+    getlistpage () {
+      switch (this.mixins_query.cycle) {
+        case 0:
+          this.mixins_query.month = this.days.getMonth() + 1;
+          this.mixins_query.year = this.days.getFullYear();
+          break;
+        case 1:
+          this.mixins_query.month = this.lastQuarter.season;
+          this.mixins_query.year = this.lastQuarter.year;
+          break;
+        case 2:
+          this.mixins_query.month = '';
+          this.mixins_query.year = this.days.getFullYear();
+          break;
+        default:
+          break;
+      }
+      this.mixins_dataUrl = '/sc-community/evaluation/result/find/page';
+      this.mixins_pageset = {
+        pageNum: this.mixins_pageset.pageNum,
+        pageSize: this.mixins_pageset.pageSize
+      };
+      this.mixins_post = 'post';
+      this.mixins_search();
+    },
+    changeQuarter (val) {
+      this.lastQuarter = val;
+    },
+    openEvaluationHandle (item) {
+      let row = {};
+      new Promise((resolve) => {
+        this.$http.postForm('/sc-community/evaluation/task/find', { evaluationResultId: item.id }).then(({ status, data, msg }) => {
+          if (status === 0) {
+            row = data;
+            resolve();
+          } else {
+            this.$message.error(msg);
+          }
+        });
+      }).then(() => {
+        new Promise((resolve) => {
+          this.$store.dispatch('openModal', {
+            url: '/performanceManagement/performanceEvaluation/popups/evaluationEdit.vue',
+            width: '1200px',
+            height: '510px',
+            props: {
+              rowInfo: item,
+              data: row,
+              year: this.mixins_query.year,
+              month: this.mixins_query.month,
+              callback: resolve
+            },
+            title: '考评',
+            notip: true,
+            confirmButtonText: '确定',
+            showCancelButton: item.state === '未考评' ? false : true,
+            showConfirmButton: item.state === '未考评' ? false : true
+          });
+        }).then(() => {
+          this.mixins_search();
+        });
+      });
+    },
+    openEvaluationDetile (item) {
+      let row = {};
+      new Promise((resolve) => {
+        this.$http.postForm('/sc-community/evaluation/task/find', { evaluationResultId: item.id }).then(({ status, data, msg }) => {
+          if (status === 0) {
+            row = data;
+            resolve();
+          } else {
+            this.$message.error(msg);
+          }
+        });
+      }).then(() => {
+        new Promise((resolve) => {
+          this.$store.dispatch('openModal', {
+            url: '/performanceManagement/performanceEvaluation/popups/evaluationDetail.vue',
+            width: '1200px',
+            height: '510px',
+            props: {
+              rowInfo: item,
+              data: row,
+              cycle: this.mixins_query.cycle,
+              year: this.mixins_query.year,
+              month: this.mixins_query.month,
+              callback: resolve
+            },
+            title: '考评详情',
+            notip: true,
+            showCancelButton: true,
+            showConfirmButton: true
+          });
+        }).then(() => {
+          // this.mixins_search();
+        });
+      });
+    },
+    selectionChange (val) {
+      this.selectRow = val;
+    },
+    getorgTree () {
+      // 获取公司树
+      this.$http.postForm('/sc-user-center/org/getOrgUserTree', { orgType: 'company', id: '000' }).then(({ status, data, msg }) => {
+        if (status === 0 && data) {
+          this.organListCompany = data;
+        } else {
+          this.$message.error(msg);
+        }
+      });
+    },
+    selectedcompanyOrgId (e) {
+      if (!e) return;
+      // 获取 部门树e
+      this.$http.postForm('/user-center/org/getOrgUserTree', { orgType: 'department', id: e }).then(({ status, data, msg }) => {
+        if (status === 0) {
+          this.organListdepartment = data ? data : [];
+        } else {
+          this.$message.error(msg);
         }
+      });
     }
+  }
 };
 </script>