mirror of
https://github.com/haiwen/seahub.git
synced 2025-09-24 04:48:03 +00:00
change online-read-write permission UI (#5560)
* change online-read-write permission UI * update * update
This commit is contained in:
@@ -621,7 +621,7 @@ class DirentListItem extends React.Component {
|
||||
{showShareBtn && (
|
||||
<a href="#" className="op-icon sf2-icon-share" title={gettext('Share')} role="button" aria-label={gettext('Share')} onClick={this.onItemShare}></a>
|
||||
)}
|
||||
{(dirent.permission === 'rw' || (isCustomPermission && canDelete)) && (
|
||||
{(dirent.permission === 'rw' || dirent.permission === 'cloud-edit' || (isCustomPermission && canDelete)) && (
|
||||
<a href="#" className="op-icon sf2-icon-delete" title={gettext('Delete')} role="button" aria-label={gettext('Delete')} onClick={this.onItemDelete}></a>
|
||||
)}
|
||||
<ItemDropdownMenu
|
||||
@@ -645,7 +645,7 @@ class DirentListItem extends React.Component {
|
||||
{showShareBtn && (
|
||||
<a href="#" className="op-icon sf2-icon-share" title={gettext('Share')} role="button" aria-label={gettext('Share')} onClick={this.onItemShare}></a>
|
||||
)}
|
||||
{(dirent.permission === 'rw' || (isCustomPermission && canDelete)) && (
|
||||
{(dirent.permission === 'rw' || dirent.permission === 'cloud-edit' || (isCustomPermission && canDelete)) && (
|
||||
<a href="#" className="op-icon sf2-icon-delete" title={gettext('Delete')} role="button" aria-label={gettext('Delete')} onClick={this.onItemDelete}></a>
|
||||
)}
|
||||
<ItemDropdownMenu
|
||||
|
@@ -239,7 +239,7 @@ class DirOperationToolbar extends React.Component {
|
||||
|
||||
return (
|
||||
<Fragment>
|
||||
{(userPerm === 'rw' || userPerm === 'admin' || isCustomPermission) && (
|
||||
{(userPerm === 'rw' || userPerm === 'admin' || userPerm === 'cloud-edit' || isCustomPermission) && (
|
||||
<div className="dir-operation">
|
||||
{content}
|
||||
</div>
|
||||
|
@@ -358,6 +358,13 @@ class MultipleDirOperationToolbar extends React.Component {
|
||||
{canDownload && <Button className="secondary group-op-item action-icon sf2-icon-download" title={gettext('Download')} aria-label={gettext('Download')} onClick={this.onItemsDownload}></Button>}
|
||||
</Fragment>
|
||||
)}
|
||||
{userPerm === 'cloud-edit' && (
|
||||
<Fragment>
|
||||
{canModify && <Button className="secondary group-op-item action-icon sf2-icon-move" title={gettext('Move')} aria-label={gettext('Move')} onClick={this.onMoveToggle}></Button>}
|
||||
{canCopy && <Button className="secondary group-op-item action-icon sf2-icon-copy" title={gettext('Copy')} aria-label={gettext('Copy')} onClick={this.onCopyToggle}></Button>}
|
||||
{canDelete && <Button className="secondary group-op-item action-icon sf2-icon-delete" title={gettext('Delete')} aria-label={gettext('Delete')} onClick={this.onItemsDelete}></Button>}
|
||||
</Fragment>
|
||||
)}
|
||||
{userPerm === 'r' && (
|
||||
<Fragment>
|
||||
<Button className="secondary group-op-item action-icon sf2-icon-copy" title={gettext('Copy')} aria-label={gettext('Copy')} onClick={this.onCopyToggle}></Button>
|
||||
|
Reference in New Issue
Block a user