Enh #4061: Improved post context menu order

This commit is contained in:
buddh4 2020-05-14 17:31:58 +02:00
parent e8eaba6f64
commit 5487880f33
2 changed files with 6 additions and 4 deletions

View File

@ -18,6 +18,7 @@ HumHub Change Log
- Fix #4096: Missing CreatePost permission check in post model canMove
- Fix #4098: Space setting edit fails due to unique name validation
- Fix #4100: Empty message validation errors on post and comment edit broken
- Enh #4061: Improved post context menu order
1.5.1 (April 19, 2020)

View File

@ -187,13 +187,14 @@ class WallEntry extends Widget
{
$result = [];
$this->addControl($result, [DeleteLink::class, ['content' => $this->contentObject], ['sortOrder' => 100]]);
if (!empty($this->getEditUrl())) {
$this->addControl($result, [EditLink::class, ['model' => $this->contentObject, 'mode' => $this->editMode, 'url' => $this->getEditUrl()], ['sortOrder' => 200]]);
$this->addControl($result, [EditLink::class, ['model' => $this->contentObject, 'mode' => $this->editMode, 'url' => $this->getEditUrl()], ['sortOrder' => 100]]);
}
$this->addControl($result, [PermaLink::class, ['content' => $this->contentObject], ['sortOrder' => 300]]);
$this->addControl($result, [PermaLink::class, ['content' => $this->contentObject], ['sortOrder' => 200]]);
$this->addControl($result, [DeleteLink::class, ['content' => $this->contentObject], ['sortOrder' => 300]]);
$this->addControl($result, new DropdownDivider(['sortOrder' => 350]));
$this->addControl($result, [VisibilityLink::class, ['contentRecord' => $this->contentObject], ['sortOrder' => 400]]);
$this->addControl($result, [NotificationSwitchLink::class, ['content' => $this->contentObject], ['sortOrder' => 500]]);