Add: Entra Cronjob, Cronjob-Verwaltung, Profilfotos, PDF-Auth-Fix, Tickets-Demo
This commit is contained in:
@@ -105,6 +105,16 @@ const BarIcon = () => <Ico d="M22 12h-4l-3 9L9 3l-3 9H2"/>;
|
||||
const Avatar = ({ user, size = 36, radius = 10, fontSize = 13 }) => {
|
||||
const initials = ((user.first_name?.[0] || '') + (user.last_name?.[0] || '')).toUpperCase() || (user.username?.[0] || '?').toUpperCase();
|
||||
const bg = ROLE_AV_COLORS[user.role_name] || '#475569';
|
||||
if (user.avatar_url) {
|
||||
return (
|
||||
<img
|
||||
src={user.avatar_url}
|
||||
alt={initials}
|
||||
style={{ width: size, height: size, borderRadius: radius, objectFit: 'cover', flexShrink: 0 }}
|
||||
onError={e => { e.target.style.display = 'none'; e.target.nextSibling && (e.target.nextSibling.style.display = 'flex'); }}
|
||||
/>
|
||||
);
|
||||
}
|
||||
return (
|
||||
<div style={{ width: size, height: size, borderRadius: radius, background: bg, display: 'flex', alignItems: 'center', justifyContent: 'center', fontSize, fontWeight: 700, color: '#fff', flexShrink: 0 }}>
|
||||
{initials}
|
||||
@@ -1152,9 +1162,13 @@ const UserManagementPage = () => {
|
||||
const init = ((u.first_name?.[0] || '') + (u.last_name?.[0] || '')).toUpperCase() || u.username?.[0]?.toUpperCase() || '?';
|
||||
return (
|
||||
<div className={`bv-user-row ${u.id === selectedId ? 'active' : ''}`} onClick={() => handleSelect(u.id)}>
|
||||
<div className="bv-ur-av" style={{background: avatarBg, width:36, height:36, borderRadius:10, display:'flex', alignItems:'center', justifyContent:'center', fontSize:13, fontWeight:700, color:'#fff', flexShrink:0}}>
|
||||
{init}
|
||||
</div>
|
||||
{u.avatar_url ? (
|
||||
<img src={u.avatar_url} alt={init} style={{width:36, height:36, borderRadius:10, objectFit:'cover', flexShrink:0}} onError={e => { e.target.style.display='none'; }} />
|
||||
) : (
|
||||
<div className="bv-ur-av" style={{background: avatarBg, width:36, height:36, borderRadius:10, display:'flex', alignItems:'center', justifyContent:'center', fontSize:13, fontWeight:700, color:'#fff', flexShrink:0}}>
|
||||
{init}
|
||||
</div>
|
||||
)}
|
||||
<div className={`bv-presence ${p}`} />
|
||||
<div className="bv-ur-body">
|
||||
<div className="bv-ur-name">{u.first_name} {u.last_name}</div>
|
||||
@@ -1222,8 +1236,12 @@ const UserManagementPage = () => {
|
||||
<div className="bv-detail-inner">
|
||||
{/* Header */}
|
||||
<div className="bv-detail-head">
|
||||
<div className="bv-dh-avatar" style={{background: ROLE_AV_COLORS[selectedUser.role_name] || '#475569'}}>
|
||||
{initials}
|
||||
<div className="bv-dh-avatar" style={{background: selectedUser.avatar_url ? 'transparent' : (ROLE_AV_COLORS[selectedUser.role_name] || '#475569'), padding: 0, overflow: 'hidden'}}>
|
||||
{selectedUser.avatar_url ? (
|
||||
<img src={selectedUser.avatar_url} alt={initials} style={{width:'100%',height:'100%',objectFit:'cover',display:'block'}} onError={e => { e.target.style.display='none'; e.target.closest('.bv-dh-avatar').style.background = ROLE_AV_COLORS[selectedUser.role_name] || '#475569'; }} />
|
||||
) : (
|
||||
initials
|
||||
)}
|
||||
<div className={`bv-dh-presence ${presence}`} />
|
||||
</div>
|
||||
<div className="bv-dh-body">
|
||||
|
||||
Reference in New Issue
Block a user