1
0
mirror of https://github.com/haiwen/seahub.git synced 2025-09-13 05:39:59 +00:00

optimize code

This commit is contained in:
杨顺强
2023-11-29 16:14:38 +08:00
parent 185af18660
commit e226fcda0b
3 changed files with 11 additions and 5 deletions

View File

@@ -207,7 +207,7 @@ class DirentGridItem extends React.Component {
gridClass += this.state.isGridSelected ? ' grid-selected-active' : ' ';
gridClass += this.state.isGridDropTipShow ? ' grid-drop-show' : ' ';
let lockedInfo = gettext('locked by {name}');
let lockedInfo = dirent.is_freezed ? gettext('locked by {name}') : gettext('Freezed by {name}');
lockedInfo = lockedInfo.replace('{name}', dirent.lock_owner_name);
const lockedImageUrl = `${mediaUrl}img/file-${dirent.is_freezed ? 'freezed' : 'locked'}-32.png`;