|
@@ -33,6 +33,7 @@
|
|
|
<script>
|
|
|
import { getPowerRoleList } from '@/api/powerRole-md.js'
|
|
|
import {saveEmployee,setManager} from '@/api/employee'
|
|
|
+ import { getCurrUserInfo } from '@/api/data.js';
|
|
|
export default{
|
|
|
data(){
|
|
|
return{
|
|
@@ -56,11 +57,7 @@
|
|
|
},
|
|
|
onLoad(opts) {
|
|
|
this.userInfo = this.$store.state.vuex_nowStaffData
|
|
|
- this.formData = Object.assign({},this.formData,this.userInfo)
|
|
|
- },
|
|
|
- onShow() {
|
|
|
- this.pageNo = 1
|
|
|
- this.getRoleList()
|
|
|
+ this.getCurrUserInfo()
|
|
|
},
|
|
|
// 下一页
|
|
|
onReachBottom() {
|
|
@@ -101,6 +98,15 @@
|
|
|
_this.status = "loadmore"
|
|
|
})
|
|
|
},
|
|
|
+ getCurrUserInfo(){
|
|
|
+ getCurrUserInfo().then(res => {
|
|
|
+ if(res.data){
|
|
|
+ this.formData = Object.assign({},this.formData,res.data)
|
|
|
+ this.pageNo = 1
|
|
|
+ this.getRoleList()
|
|
|
+ }
|
|
|
+ })
|
|
|
+ },
|
|
|
// 保存
|
|
|
save(name){
|
|
|
if(!this.formData.roleIds){
|