<template> <el-card style="margin-bottom:20px;"> <div class="user-profile"> <div class="account-center-avatarHolder"> <div class="avatar"> <img :src="avatar || userPic"/> </div> <div class="username">{{ user.fusername }}</div> <div class="bio">{{ user.fuserid }}</div> </div> <div class="account-center-detail"> <p> <i class="el-icon-s-custom"></i>{{ user.fbzname }} </p> <p> <i class="iconfont icon-tree"></i>{{ `${user.forgname} - ${user.fdeptname} - ${user.frolename}` }} </p> <p> <i class="el-icon-phone-outline"></i><span>{{ user.FMBPHONE || user.fmbphone}}</span><span></span> </p> </div> <el-divider /> </div> <div class="user-bio"> <div class="user-bio-section-header"><svg-icon icon-class="education" /><span>{{ $t("hivuiMain_app_orgbz")}}</span></div> <div class="user-education user-bio-section"> <div class="user-bio-section-body" v-for="item in bzList"> <p style="display: inline-flex;"> <i class="el-icon-s-custom"></i><span>{{ item.forgnamepath || item.fbzname }}</span><i class="el-icon-star-on" title="主岗" v-if="item.fdefaultbz"></i><span class="bzid">{{ item.fbzid}}</span><span></span> </p> </div> </div> </div> </el-card> </template> <script> import userPic from "@main/assets/user.png" export default { props: { user: { type: Object, default: () => { return { name: '', email: '', avatar: '', role: '' } } }, avatar:{ type: String, default: "" } }, data(){ return{ userPic: userPic, bzList:[] } }, mounted(){ }, methods:{ } } </script> <style lang="scss" scoped> .box-center { margin: 0 auto; display: table; } .text-muted { color: #777; } .user-profile { .user-name { font-weight: bold; } .box-center { padding-top: 10px; } .user-role { padding-top: 10px; font-weight: 400; font-size: 14px; } .box-social { padding-top: 30px; .el-table { border-top: 1px solid #dfe6ec; } } .user-follow { padding-top: 20px; } } .account-center-avatarHolder { text-align: center; margin-bottom: 24px; & > .avatar { margin: 0 auto; width: 104px; height: 104px; margin-bottom: 20px; border-radius: 50%; overflow: hidden; img { height: 100%; width: 100%; } } .username { color: rgba(0, 0, 0, 0.85); font-size: 20px; line-height: 28px; font-weight: 500; margin-bottom: 4px; } } .account-center-detail { p { margin-bottom: 8px; padding-left: 26px; position: relative; } i { position: absolute; height: 14px; width: 14px; left: 0; top: 4px; // background: url(https://gw.alipayobjects.com/zos/rmsportal/pBjWzVAHnOOtAUvZmZfy.svg) } .title { background-position: 0 0; } .group { background-position: 0 -22px; } .address { background-position: 0 -44px; } } .user-bio { margin-top: 20px; color: #606266; span { padding-left: 4px; } .user-bio-section-body{ .bzid{ float: right; color: #000; } .el-icon-star-on{ color: #06c; } } .user-bio-section-header { border-bottom: 1px solid #dfe6ec; padding-bottom: 10px; margin-bottom: 10px; font-weight: bold; } .user-bio-section { height: calc(100vh - 427px); min-height: 336px; overflow: auto; font-size: 14px; line-height: 14px; // padding: 15px 0; } } </style>