[新增功能](hyx_2024-12-11_humanResource):

list.vue
 - 新增绑定人资系统人员功能
hyx_2024-12-11_humanResource
huangyuxuan 2024-12-11 18:04:43 +08:00
parent 7fac83da20
commit e31d16eb82
1 changed files with 100 additions and 1 deletions

View File

@ -70,6 +70,11 @@
</el-col>
</el-row>
</el-form>
<div class="app-statistical">
<span>
人资系统人员总数<i>{{ HR_USER_COUNT }}</i>
</span>
</div>
<el-table v-loading="listLoading" ref="multipleTable" :data="varList" :row-key="getRowKey" :header-cell-style="{'font-weight': 'bold','color': '#000'}" tooltip-effect="dark" border fit highlight-current-row>
<el-table-column :reserve-selection="true" type="selection" width="55" align="center" />
<el-table-column type="index" label="序号" width="50" align="center" />
@ -85,7 +90,14 @@
<span v-else></span>
</template>
</el-table-column>
<el-table-column prop="IN_HR_USER" label="是否对比成功" >
<template slot-scope="{row}">
<span v-if="row.IN_HR_USER =='0'"></span>
<span v-if="row.IN_HR_USER =='1'"></span>
<span v-if="row.IN_HR_USER =='2'"></span>
<span v-if="row.IN_HR_USER =='3'"></span>
</template>
</el-table-column>
<el-table-column label="操作" width="620px">
<template slot-scope="{row}">
<el-button v-show="edit" type="success" icon="el-icon-refresh" size="mini" @click="resetPwd(row.USER_ID)"></el-button>
@ -97,6 +109,7 @@
<el-button v-show="edit" type="primary" icon="el-icon-edit" size="mini" @click="handleEdit(row)"></el-button>
<el-button v-show="del && row.ISMAIN=='0'" type="danger" icon="el-icon-delete" size="mini" @click="handleDelete(row.USER_ID, row.NAME, row.ISPUSH)"></el-button>
<!-- <el-button v-if="row.ISPUSH == '0'" type="primary" icon="el-icon-position" size="mini" @click="goPush(row)"></el-button>-->
<el-button v-if="row.IN_HR_USER == '0' || row.IN_HR_USER == '1'" type="primary" icon="el-icon-position" size="mini" @click="bind()"></el-button>
</template>
</el-table-column>
</el-table>
@ -185,6 +198,46 @@
<el-button type="primary" @click="goScheduling(USER_ID)"> </el-button>
</div>
</el-dialog>
<el-dialog :visible.sync="humanResourceForm" :before-close="cancel" title="绑定人资系统人员" width="600px">
<template>
<div class="app-container">
<el-form ref="form" :model="formModel" label-width="110px" class="in-uploader">
<el-form-item label="人员信息">
<el-row :gutter="20">
<el-col :span="12"><div class="grid-content bg-purple"/>
<el-autocomplete
v-model="formModel.userName"
:fetch-suggestions="querySearch"
placeholder="请输入或选择用户名"
class="filter-item"
@select="handleSelect"
>
<template slot-scope="{ item }">
{{ item.NAME }}
</template>
</el-autocomplete>
</el-col>
<el-col :span="12"><div class="grid-content bg-purple"/>
<el-input
v-model="formModel.cardId"
placeholder="身份证号"
readonly
class="filter-item"
style="margin-left: 10px;"
/>
</el-col>
</el-row>
</el-form-item>
</el-form>
</div>
</template>
<div slot="footer" class="dialog-footer">
<el-button @click="cancel"> </el-button>
<el-button type="primary" @click="submitForm"> </el-button>
</div>
</el-dialog>
</div>
</template>
@ -239,11 +292,18 @@ export default {
}
}
return {
HR_USER_COUNT: 0,
dayTime: [],
dialogFormEditDate: false,
SchedulingFrom: false,
listLoading: true,
treeLoading: false,
humanResourceForm: false,
userInfoList: [],
formModel: {
userName: '',
cardId: ''
},
add: false,
del: false,
edit: false,
@ -441,9 +501,48 @@ export default {
this.getScheduleAll()
this.getDict()
this.getHrUserCount()
// this.getLearnerCategory() //
},
methods: {
cancel() {
this.humanResourceForm = false
this.formModel.cardId = ''
this.formModel.userName = ''
},
querySearch(queryString, cb) {
const results = queryString ? this.userInfoList.filter(item => item.NAME.toLowerCase().includes(queryString.toLowerCase())) : this.userInfoList
cb(results)
},
handleSelect(item) {
this.formModel.userName = item.NAME
this.formModel.cardId = item.CARD_ID //
},
bind() {
this.humanResourceForm = true
this.getHrUserInfo()
},
getHrUserInfo() {
requestFN(
'/api/humanResource/getUserInfoListByCorpName',
{
CORPINFO_ID: JSON.parse(sessionStorage.getItem('user')).CORPINFO_ID
}
).then((data) => {
this.userInfoList = data.varList
}).catch((e) => {
console.log(e)
})
},
getHrUserCount() {
requestFN(
'/api/humanResource/getHrUserCount'
).then((data) => {
this.HR_USER_COUNT = data.varList[0].HR_USER_COUNT
}).catch((e) => {
console.log(e)
})
},
goPush(row) {
requestFN(
'user/goPush',