mirror of https://github.com/MISP/MISP
Merge pull request #8258 from JakubOnderka/fix-unpublish-button
fix: [UI] Unpublish button titlepull/8271/head
commit
cb218004b0
|
@ -1,36 +1,37 @@
|
|||
<div class="confirmation">
|
||||
<?php
|
||||
echo $this->Form->create('Event', array('style' => 'margin:0px;', 'id' => 'PromptForm', 'url' => $baseurl . '/events/' . $type . '/' . $id));
|
||||
$extraTitle = "";
|
||||
if ($type == 'publish') $extraTitle = ' (no email)';
|
||||
$message = __('Publish Event%s', $extraTitle);
|
||||
echo $this->Form->create('Event', ['style' => 'margin:0px;', 'id' => 'PromptForm', 'url' => $baseurl . '/events/' . $type . '/' . $id]);
|
||||
if ($type === 'unpublish') {
|
||||
$message = __('Unpublish Event%s', $extraTitle);
|
||||
$message = __('Unpublish Event');
|
||||
$buttonTitle = __('Unpublish');
|
||||
} else {
|
||||
$extraTitle = $type === 'publish' ? ' (no email)' : '';
|
||||
$message = __('Publish Event%s', $extraTitle);
|
||||
$buttonTitle = __('Publish');
|
||||
}
|
||||
?>
|
||||
|
||||
<legend><?php echo $message;?></legend>
|
||||
<legend><?= $message ?></legend>
|
||||
<div style="padding-left:5px;padding-right:5px;padding-bottom:5px;">
|
||||
<?php
|
||||
if ($type == 'alert') {
|
||||
echo '<p>' . __('Are you sure this event is complete and everyone should be informed?') . '</p>';
|
||||
<p><?php
|
||||
if ($type === 'alert') {
|
||||
echo __('Are you sure this event is complete and everyone should be informed?');
|
||||
} else if ($type === 'unpublish') {
|
||||
echo '<p>' . __('Are you sure you wish to unpublish the event?') . '</p>';
|
||||
echo __('Are you sure you wish to unpublish the event?');
|
||||
} else if ($type === 'publishSightings') {
|
||||
echo '<p>' . __('Are you sure you wish publish and synchronise all sightings attached to this event?') . '</p>';
|
||||
echo __('Are you sure you wish publish and synchronise all sightings attached to this event?');
|
||||
} else {
|
||||
echo '<p>' . __('Publish but do NOT send alert email? Only for minor changes!') . '</p>';
|
||||
echo __('Publish but do NOT send alert email? Only for minor changes!');
|
||||
}
|
||||
?>
|
||||
?></p>
|
||||
<table>
|
||||
<tr>
|
||||
<td style="vertical-align:top">
|
||||
<button role="button" tabindex="0" aria-label="<?php echo __('Publish');?>" title="<?php echo __('Publish');?>" id="PromptYesButton" class="btn btn-primary"><?php echo __('Yes');?></button>
|
||||
<button role="button" tabindex="0" aria-label="<?= $buttonTitle ?>" title="<?= $buttonTitle ?>" id="PromptYesButton" class="btn btn-primary"><?= __('Yes') ?></button>
|
||||
</td>
|
||||
<td style="width:540px;">
|
||||
</td>
|
||||
<td style="vertical-align:top;">
|
||||
<span role="button" tabindex="0" aria-label="<?php echo __('Cancel');?>" title="<?php echo __('Cancel');?>" class="btn btn-inverse" id="PromptNoButton" onClick="cancelPrompt();"><?php echo __('No');?></span>
|
||||
<span role="button" tabindex="0" aria-label="<?= __('Cancel');?>" title="<?= __('Cancel');?>" class="btn btn-inverse" id="PromptNoButton" onclick="cancelPrompt()"><?= __('No');?></span>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
|
Loading…
Reference in New Issue