From 7525419a78f51797ffb7fc2bba0bff0cfa2388c9 Mon Sep 17 00:00:00 2001 From: Bogdanova Olga Date: Wed, 10 Feb 2021 15:08:52 +0300 Subject: [PATCH] Issues-384: fixed Move Discussion popup --- .../moderation/confirmdiscussionmoves.php | 57 +++++++++++++++++++ 1 file changed, 57 insertions(+) create mode 100644 vanilla/applications/vanilla/views/moderation/confirmdiscussionmoves.php diff --git a/vanilla/applications/vanilla/views/moderation/confirmdiscussionmoves.php b/vanilla/applications/vanilla/views/moderation/confirmdiscussionmoves.php new file mode 100644 index 0000000..c03aa32 --- /dev/null +++ b/vanilla/applications/vanilla/views/moderation/confirmdiscussionmoves.php @@ -0,0 +1,57 @@ + +

data('Title'); ?>

+Form->open(); +echo $this->Form->errors(); +?> +
+Data, 0); +$CountNotAllowed = val('CountNotAllowed', $this->Data, 0); +$CountCheckedDiscussions = val('CountCheckedDiscussions', $this->Data, 0); + +if ($CountNotAllowed > 0) { + echo wrap(sprintf( + t('You do not have permission to move %1$s of the selected discussions.'), + $CountNotAllowed + ), 'p'); + + echo wrap(sprintf( + t('You are about to move %1$s of the %2$s of the selected discussions.'), + $CountAllowed, + $CountCheckedDiscussions + ), 'p'); +} else { + echo wrap(sprintf( + t('You are about to move %s.'), + plural($CountCheckedDiscussions, '%s discussion', '%s discussions') + ), 'p'); +} +?> + + '; + echo '
'; + echo $this->Form->label('Category', 'CategoryID'), ' '; + $options = [ + 'Value' => $this->Data('CategoryID'), + 'IncludeNull' => true, + 'DiscussionType' => $this->Data('DiscussionType'), + ]; + echo $this->Form->categoryDropDown('CategoryID', $options); + echo '
'; + echo '
'; + + echo '
'. + $this->Form->checkBox('RedirectLink', 'Leave a redirect link.', ['display' => 'before']). + '
'; + ?> + + +'; +echo $this->Form->button('Cancel', ['type' => 'button', 'class' => 'Button Close']); +echo $this->Form->button('Move', ['type' => 'submit', 'class' => 'Button Primary Move']); +echo ''; +echo ''; +