This commit is contained in:
熊成强 2020-10-29 18:19:04 +08:00
commit 72b33afce9
6 changed files with 221 additions and 23 deletions

View File

@ -18,6 +18,16 @@
color: #b1b1b1;
}
.comonTitle {
font-size: 20px;
color: #52575b;
}
.comonPrompt {
font-size: 14px;
color: #9b9b9b;
}
.common-main {
background-color: white;
padding: 40px 20px;

View File

@ -32,7 +32,8 @@ import {
TabPane,
Menu,
MenuItem,
Loading
Loading,
Image
} from 'element-ui'
Vue.prototype.$loading = Loading
@ -71,3 +72,4 @@ Vue.use(DropdownItem)
Vue.use(Cascader)
Vue.use(Menu)
Vue.use(MenuItem)
Vue.use(Image)

View File

@ -7,7 +7,11 @@
<div>等级分布详情</div>
</div>
<div class="detail_content">
<el-cascader :options="depList" @change="handleChange" style="margin-bottom:20px" ></el-cascader>
<el-cascader
:options="depList"
@change="handleChange"
style="margin-bottom:20px"
v-model="defaultOpt"></el-cascader>
<el-table :data="tableData"
border
:header-cell-style="{ background:'#F5F7FA'}"
@ -30,7 +34,12 @@ export default {
//
tableData: [],
//
depList: []
depList: [{
value: '',
label: '全部'
}],
//
defaultOpt: ['']
}
},
computed: {},
@ -66,8 +75,8 @@ export default {
type: 0
}
let result = await getDepList(params)
console.log(result)
this.depList = this.handleDepResult(result.data)
this.depList = this.depList.concat(this.handleDepResult(result.data))
console.log(this.depList)
},
//
handleDepResult (list) {

View File

@ -1,7 +1,12 @@
<!-- -->
<template>
<div class="block">
<el-cascader :props="props" :options="timeOptions" @change="handleChange">
<div class="report_index">
<el-cascader
:props="props"
:options="timeOptions"
@change="handleChange"
v-model="defaultStartId"
style="width:250px">
</el-cascader>
<div class="report_content">
<div class="header">
@ -66,7 +71,7 @@
<el-table :data="tableData"
:header-cell-style="{ background:'#F5F7FA'}"
border
style="flex-grow:2;margin-top:20px">
style="flex-grow:2;margin-top:20px;height:100%">
<el-table-column prop="desc" label="绩效等级">
</el-table-column>
<el-table-column prop="num" label="实际分布">
@ -105,7 +110,9 @@ export default {
return {
//
pickerTime: '',
//
//
defaultStartId: [],
// id
startId: '',
//
statisticals: [
@ -135,16 +142,15 @@ export default {
props: {
lazy: true,
lazyLoad: (node, resolve) => {
console.log('aaaa')
//
let type = node.data.value
// 2
this.handleStartsReq(type, function (reslut) {
const childNode = Array.from(reslut.list).map(item => ({
value: item.startId,
label: item.time,
leaf: true
label: item.time
}))
// console.log(childNode)
resolve(childNode)
})
}
@ -232,7 +238,6 @@ export default {
beforeMount () { },
mounted () {
this.handleChartDataReq()
this.handleLevelChart()
},
methods: {
//
@ -267,7 +272,6 @@ export default {
path: ('report-detial'),
query: {startId: this.startId, flowProcess: rows.desc}
})
console.log(this.$router)
},
// Y34(0)
handleChartYMul (val) {
@ -287,6 +291,7 @@ export default {
},
//
handleChange (val) {
console.log(val)
this.startId = val[1]
this.handleChartDataReq(val[1])
},
@ -297,8 +302,16 @@ export default {
}
try {
const result = await getChartData(params)
// startIdstartId
if (typeof startId === 'undefined') {
this.defaultStartId[0] = result.data[0].type
this.defaultStartId[1] = result.data[0].defaultId
this.startId = result.data[0].defaultId
this.defaultStartName = result.data[0].defaultTime
//
this.handleStartsReq(result.data[0].type)
}
result.data.forEach((val, index) => {
console.log(val)
if (val.type === 0) {
//
this.statisticals = val.statisticals
@ -313,7 +326,6 @@ export default {
this.assessNum = val.statisticals
this.option.series[0].data = Array.from(this.assessNum).map(item => (item.num))
this.option.xAxis[0].data = Array.from(this.assessNum).map(item => (item.desc))
console.log(this.option.xAxis[0].data)
this.handleNumChart()
}
})
@ -330,7 +342,20 @@ export default {
}
try {
let res = await getStartsData(params)
handleNode(res.data)
if (typeof handleNode === 'undefined') {
let children = Array.from(res.data.list).map(item => ({
value: item.startId,
label: item.time,
leaf: true
}))
if (type === 0) {
this.timeOptions[0].children = children
} else {
this.timeOptions[1].children = children
}
} else {
handleNode(res.data)
}
} catch (error) {
console.log(error)
}
@ -341,6 +366,10 @@ export default {
</script>
<style lang='' scoped>
.report_index{
display: flex;
flex-direction: column;
}
.report_content {
background: white;
border: #fcfcfc solid 1px;
@ -385,8 +414,8 @@ export default {
.num_tips{
display: flex;
}
.num_chart {
flex-grow: 1;
.num_chart{
flex-grow: 1
}
.num_chart>:nth-child(1){
color: #3a3a3a;

View File

@ -0,0 +1,147 @@
<template>
<div class="authority commonFont">
<div>
<div class="authority-main line-space">
<div class="authority-main-header">
<div class="comonTitle">智能绩效主管理员</div>
<el-button
type="primary"
size="small"
@click="handleChangeDirector"
>更换智能绩效主管理员</el-button>
</div>
<div class="comonPrompt">绩效应用的主管理员可由钉钉主管理员设置绩效主管理员具有应用所有权限且可以设置智能绩效应用子管理员</div>
<div class="authority-main-info">
<el-image :src="url"></el-image>
<div class="authority-main-info-name">阿三来了</div>
</div>
</div>
<div class="authority-sub line-space">
<div class="authority-sub-header">
<div class="comonTitle">智能绩效子管理员</div>
<el-button
type="primary"
size="small"
@click="handleSubAdd"
icon="el-icon-plus"
plain
>添加</el-button>
</div>
<div class="comonPrompt line-space">可把绩效应用的日常管理工作交给绩效子管理员绩效子管理员可由绩效主管理员设置</div>
<el-table
:data="tableDataList"
:header-cell-style="handleSubGetTableStyle"
>
<el-table-column label="姓名"></el-table-column>
<el-table-column label="功能模块"></el-table-column>
<el-table-column label="管理范围"></el-table-column>
<el-table-column label="是否可见考核结果"></el-table-column>
<el-table-column label="菜单权限"></el-table-column>
<el-table-column label="管理考评组"></el-table-column>
<el-table-column label="操作"></el-table-column>
</el-table>
</div>
<div class="authority-ceo line-space">
<div class="comonTitle line-space">企业负责人</div>
<div class="comonPrompt">企业负责人可以看到全公司的绩效数据可由钉钉主管理员在通讯录设置</div>
</div>
<div class="authority-department line-space">
<div class="comonTitle line-space">部门主管</div>
<div class="comonPrompt">部门主管可看到管理部门的绩效数据可由钉钉管理员在钉钉通讯录设置</div>
</div>
<div class="authority-employee line-space">
<div class="comonTitle line-space">员工</div>
<div class="comonPrompt">员工仅可见自己的绩效数据</div>
</div>
</div>
<dialog-depart
v-if="showDialogDepart"
:value.sync='depIds'
:isShow.sync='showDialogDepart'
:showDataList.sync='showData'
/>
<popup-right
v-if="showPopupAddSub"
@cancel="hundlePopupAddSubHide"
@submit="handlePopupAddSubSubmit"
title="智能绩效子管理员设置"
class="popup"
></popup-right>
</div>
</template>
<script>
import dialogDepart from '@/components/getDepart'
import popupRight from '@/components/PopupRight'
export default {
components: {
dialogDepart,
popupRight
},
data () {
return {
url: '',
showDialogDepart: false,
tableDataList: [],
showData: {},
depIds: '22',
showPopupAddSub: false //
}
},
methods: {
handleSubGetTableStyle () {
return { 'background-color': '#f5f4f5', 'text-align': 'center' }
},
handleChangeDirector () {
//
this.showDialogDepart = true
},
handleSubAdd () {
}
}
}
</script>
<style lang="less" scoped>
.authority {
background-color: white;
padding-top: 40px;
.line-space {
margin-bottom: 18px;
}
.el-image {
width: 40px;
height: 40px;
border-radius: 20px;
overflow: hidden;
}
&-main {
&-header {
display: flex;
width: 100%;
justify-content: space-between;
}
&-info {
display: flex;
justify-content: flex-start;
align-items: center;
height: 72px;
width: 100%;
line-height: 72px;
&-name {
margin-left: 10px;
}
}
}
&-sub {
&-header {
display: flex;
width: 100%;
justify-content: space-between;
}
}
}
</style>

View File

@ -13,14 +13,14 @@
</el-menu>
<ground-table v-if="activeIndex==='0'"></ground-table>
<div v-else-if="activeIndex==='1'">
<span>默认值设置</span>
<try-authority></try-authority>
</div>
</div>
</template>
<script>
import groundTable from '../workbench/assessmentGroup/groundTable'
import tryAuthority from './authority'
export default {
data () {
return {
@ -28,7 +28,8 @@ export default {
}
},
components: {
groundTable
groundTable,
tryAuthority
},
beforeMount () { },
mounted () { },
@ -48,6 +49,6 @@ export default {
<style lang='less' scoped>
.set-mian {
padding-top: 0px;
min-height: 600px;
// min-height: 600px;
}
</style>