diff --git a/app/View/Elements/galaxyQuickView.ctp b/app/View/Elements/galaxyQuickView.ctp index ca26afec8..9d86f2a02 100644 --- a/app/View/Elements/galaxyQuickView.ctp +++ b/app/View/Elements/galaxyQuickView.ctp @@ -20,11 +20,9 @@ Form->postLink('', - $baseurl . '/galaxy_clusters/detach/' . ucfirst(h($target_id)) . '/' . h($target_type) . '/' . $cluster['tag_id'], - array('class' => 'icon-trash', 'title' => __('Delete'), 'div' => false), - __('Are you sure you want to detach %s from this event?', h($cluster['value'])) - ); + echo $this->Form->create(false, array('url' => $baseurl . '/galaxy_clusters/detach/' . ucfirst(h($target_id)) . '/' . h($target_type) . '/' . $cluster['tag_id'], 'style' => 'display: inline-block; margin: 0px;')); + echo ''; + echo $this->Form->end(); } ?> diff --git a/app/webroot/js/misp.js b/app/webroot/js/misp.js index 1c56d9e67..6616053cd 100644 --- a/app/webroot/js/misp.js +++ b/app/webroot/js/misp.js @@ -1397,7 +1397,7 @@ function openPopup(id) { function openPopover(clicked, data) { // popup handling // var loadingHtml = '
Loading
'; - var closeButtonHtml = ''; + var closeButtonHtml = ''; $clicked = $(clicked); var title = $clicked.attr('title'); var origTitle = $clicked.attr('data-original-title'); @@ -1497,6 +1497,22 @@ function popoverPopup(clicked, id, context, target, admin) { }); } +// create a confirm popover on the clicked html node. +function popoverConfirm(clicked) { + var $clicked = $(clicked); + var popoverContent = '
'; + popoverContent += 'Yes'; + popoverContent += 'Cancel'; + popoverContent += '
'; + openPopover($clicked, popoverContent); +} + +function submitClosestForm(clicked) { + $clicked = $(clicked); + $form = $clicked.closest('form'); + $form.submit(); +} + function simplePopup(url) { $("#gray_out").fadeIn(); $.ajax({