Skip to content

Commit 0b7c70d

Browse files
committed
Remove functionality to delete subscriptions
1 parent 2a38857 commit 0b7c70d

File tree

6 files changed

+2
-177
lines changed

6 files changed

+2
-177
lines changed

Block/Form/AsyncEvent/Delete.php

Lines changed: 0 additions & 38 deletions
This file was deleted.

Command/AsyncEvent/DeleteByIdCommand.php

Lines changed: 0 additions & 68 deletions
This file was deleted.

Controller/Adminhtml/Events/Delete.php

Lines changed: 0 additions & 61 deletions
This file was deleted.

README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,12 +25,13 @@ bin/magento setup:upgrade
2525
In the Async Events grid (Stores -> Asynchronous Events -> Subscribers) you now have the options to:
2626
* Create new subscriptions
2727
* Edit existing subscriptions
28-
* Delete existing subscriptions
2928

3029
![grid.png](doc%2Fimages%2Fgrid.png)
3130

3231
The form for editing or creating subscriptions looks like this:
3332

3433
![form.png](doc/images/form.png)
3534

35+
Deleting subscriptions via Admin Interface is not possible due to [security reasons](https://github.com/mage-os/mageos-async-events-admin-ui/pull/1#issuecomment-1718979600).
36+
3637
Please note that this module only supports HTTP subscriptions at the moment.

Ui/Component/Listing/Column/AsyncEventBlockActions.php

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,6 @@ class AsyncEventBlockActions extends Column
2222
* Url paths.
2323
*/
2424
private const EDIT_URL_PATH = 'async_events/events/edit';
25-
private const DELETE_URL_PATH = 'async_events/events/delete';
2625

2726
private UrlInterface $urlBuilder;
2827

@@ -51,16 +50,9 @@ public function prepareDataSource(array $dataSource): array
5150
$urlData = ['subscription_id' => $item['subscription_id']];
5251

5352
$editUrl = $this->urlBuilder->getUrl(static::EDIT_URL_PATH, $urlData);
54-
$deleteUrl = $this->urlBuilder->getUrl(static::DELETE_URL_PATH, $urlData);
5553

5654
$item[$this->getData('name')] = [
5755
'edit' => $this->getActionData($editUrl, (string)__('Edit')),
58-
'delete' => $this->getActionData(
59-
$deleteUrl,
60-
(string)__('Delete'),
61-
(string)__('Delete %1', $entityName),
62-
(string)__('Are you sure you want to delete a %1 record?', $entityName)
63-
)
6456
];
6557
}
6658
}

view/adminhtml/ui_component/async_events_events_form.xml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@
1717
<buttons>
1818
<button name="save" class="MageOS\AsyncEventsAdminUi\Block\Form\AsyncEvent\Save"/>
1919
<button name="back" class="MageOS\AsyncEventsAdminUi\Block\Form\AsyncEvent\Back"/>
20-
<button name="delete" class="MageOS\AsyncEventsAdminUi\Block\Form\AsyncEvent\Delete"/>
2120
</buttons>
2221
</settings>
2322
<dataSource name="async_events_events_form_data_source" component="Magento_Ui/js/form/provider">

0 commit comments

Comments
 (0)