考核管理删除考核人
This commit is contained in:
parent
f2ecd0690d
commit
5bafcfdf2e
@ -79,3 +79,12 @@ export function apiGet375 (query) {
|
||||
params: query
|
||||
})
|
||||
}
|
||||
|
||||
// 考核管理组管理变更
|
||||
export function apiAssessManagerChange (query) {
|
||||
return request({
|
||||
url: '/lz_management/performance/assess/manager/change',
|
||||
method: 'post',
|
||||
data: query
|
||||
})
|
||||
}
|
||||
|
||||
@ -85,17 +85,11 @@
|
||||
</div> -->
|
||||
</div>
|
||||
</popup-right>
|
||||
<popupRemovePerson
|
||||
:showPopup.sync='showPerson'
|
||||
:startId='startId'
|
||||
@cb="handlePopupRemoveList"
|
||||
/>
|
||||
</div>
|
||||
|
||||
</template>
|
||||
<script>
|
||||
import PopupRight from '@/components/PopupRight'
|
||||
import popupRemovePerson from '@/components/popupPerson'
|
||||
export default {
|
||||
props: {
|
||||
showPopup: {
|
||||
@ -114,14 +108,12 @@ export default {
|
||||
},
|
||||
data () {
|
||||
return {
|
||||
showPerson: false,
|
||||
permissionsRadio: '0', // 部门主管选项
|
||||
permissionsPrompt: '被考核人的目标完成确认后,管理员和部门主管都可以调整目标'
|
||||
}
|
||||
},
|
||||
components: {
|
||||
PopupRight,
|
||||
popupRemovePerson
|
||||
PopupRight
|
||||
},
|
||||
watch: {
|
||||
'showPopup': function (newVal) {
|
||||
@ -136,11 +128,7 @@ export default {
|
||||
},
|
||||
handleAdd () { },
|
||||
handleDelete () {
|
||||
this.showPerson = true
|
||||
},
|
||||
handlePopupRemoveList () {
|
||||
console.log('要删除的人员')
|
||||
this.$emit('update:showPopup', false)
|
||||
this.$emit('remove')
|
||||
}
|
||||
|
||||
// handlePermissionsRadio () {
|
||||
|
||||
@ -124,12 +124,15 @@
|
||||
@cb="handleDeptSubmit"
|
||||
/>
|
||||
<el-dialog title="删除确认" :visible.sync="visibleRemovePerson" width="440px">
|
||||
<div v-if="popupData.selectedList.length>1">
|
||||
<div class="commonFont line-space">确认将选中的{{popupData.selectedList.length}}人,从考核中删除,删除后,绩效考核数据将被清空,数据无法恢复,请确认是否删除</div>
|
||||
<div class="commonFont line-space">请在下方输入框中输入<span style="color: red;">“删除”</span>二字,确认您已知晓删除将导致数据无法恢复</div>
|
||||
<div><el-input v-model="removeConfirmInput" placeholder="请输入“删除二字”" size="small"></el-input></div>
|
||||
</div>
|
||||
<div v-else class="commonFont">被考核人删除后,本次考核相关数据数据将被清空,数据无法恢复,请确认是否删除</div>
|
||||
<div slot="footer">
|
||||
<el-button @click="visibleRemovePerson = false" size="small">取 消</el-button>
|
||||
<el-button @click="handleConfirmRemovePerson" type="primary" size="small" :disabled="removeConfirmInput!=='删除'">确 定</el-button>
|
||||
<el-button @click="handleConfirmRemovePerson" type="primary" size="small" :disabled="removeConfirmInput!=='删除'&&popupData.selectedList.length>1">确 定</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
</div>
|
||||
@ -140,8 +143,7 @@
|
||||
import PopupRight from '@/components/PopupRight'
|
||||
import EvaluationTeamFilter from '@/components/EvaluationTeamFilter'
|
||||
import dialogDepart from '@/components/getDepart'
|
||||
|
||||
import { apiManagerDetail } from '@/api/assessment'
|
||||
import { apiManagerDetail, apiAssessManagerChange } from '@/api/assessment'
|
||||
|
||||
export default {
|
||||
props: {
|
||||
@ -221,17 +223,34 @@ export default {
|
||||
this.popupData.selectedList = val
|
||||
},
|
||||
handleSubmitPopup () {
|
||||
// 确定选择
|
||||
// 确定选择 显示二次删除去人
|
||||
if (this.popupData.selectedList.length <= 0) {
|
||||
this.$message.error('请选择删除的人员')
|
||||
return
|
||||
}
|
||||
this.visibleRemovePerson = true
|
||||
// const list = this.popupData.selectedList
|
||||
// this.$emit('update:showPopup', false)
|
||||
},
|
||||
handleConfirmRemovePerson () {
|
||||
// 确认删除 选中用户 删除成功页面刷新
|
||||
console.log('删除')
|
||||
let removeStaffIds = []
|
||||
this.popupData.selectedList.forEach(item => {
|
||||
removeStaffIds.push(item.id)
|
||||
})
|
||||
let dicPara = {
|
||||
changeType: 1,
|
||||
confirm: 0,
|
||||
staffIds: removeStaffIds.join(),
|
||||
startId: this.startId
|
||||
}
|
||||
console.log('删除数据===', dicPara)
|
||||
apiAssessManagerChange(dicPara).then(res => {
|
||||
if (res.code !== 200) {
|
||||
return
|
||||
}
|
||||
// 删除成功
|
||||
this.visibleRemovePerson = false
|
||||
this.$emit('update:showPopup', false)
|
||||
this.$emit('cb')
|
||||
})
|
||||
},
|
||||
hundlePopupHide () {
|
||||
this.$emit('update:showPopup', false)
|
||||
@ -350,8 +369,8 @@ export default {
|
||||
'showPopup': function (newVal, oldVal) {
|
||||
if (newVal) {
|
||||
this.handleGainAssessmentGroupList()
|
||||
console.log('显示人员选择---------')
|
||||
} else {
|
||||
this.removeConfirmInput = ''
|
||||
this.rqAssessmentParameter.startId = null
|
||||
this.rqAssessmentParameter.staffIds = ''
|
||||
this.rqAssessmentParameter.evaluationIds = ''
|
||||
@ -362,6 +381,12 @@ export default {
|
||||
this.staffIds = ''
|
||||
this.popupData.tableList = []
|
||||
this.popupData.selectedList = []
|
||||
this.$nextTick(() => {
|
||||
if (this.$refs.popupMultipleTable) {
|
||||
console.log('lllllllllllllllllllllllllllllllll')
|
||||
this.$refs.popupMultipleTable.clearSelection()
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -178,11 +178,13 @@
|
||||
popupRightTitle="管理绩效考核"
|
||||
:startId='options.startId'
|
||||
@cb="handlePopupMangeSubmit"
|
||||
@remove="showPopupPerson=true"
|
||||
/>
|
||||
<popupRemovePerson
|
||||
:showPopup="showPopupPerson"
|
||||
title="删除被考核人员"
|
||||
></popupRemovePerson>
|
||||
:showPopup.sync='showPopupPerson'
|
||||
:startId='options.startId'
|
||||
@cb="handlePopupRemoveListSuccessful"
|
||||
/>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
@ -205,7 +207,7 @@ export default {
|
||||
startId: this.$route.query.id || ''
|
||||
},
|
||||
showPopupMange: false, // 显示管理
|
||||
showPopupPerson: false,
|
||||
showPopupPerson: false, // 删除人员
|
||||
showChooseList: false,
|
||||
dialogVisible: false,
|
||||
form: {
|
||||
@ -400,6 +402,12 @@ export default {
|
||||
},
|
||||
handlePopupMangeSubmit () {
|
||||
this.showPopupMange = false
|
||||
},
|
||||
handlePopupRemoveListSuccessful () {
|
||||
// 删除人员成功 页面刷新
|
||||
this.showPopupMange = false
|
||||
this.showPopupPerson = false
|
||||
this.handleGetListContent()
|
||||
}
|
||||
},
|
||||
watch: {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user