Skip to content

Commit

Permalink
Fix unavailable sendout actions
Browse files Browse the repository at this point in the history
  • Loading branch information
bencroker committed Mar 10, 2024
1 parent f011c62 commit 6db2acf
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 20 deletions.
3 changes: 2 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,8 @@

### Fixed

- Fixed a bug in which the expected recipients count could fail in sendouts with very large numbers of contacts.
- Fixed a bug in which the expected recipients count could fail in sendouts with very large numbers of contacts.
- Fixed a bug in which sendout actions were unavailable on the sendout index page.

### Deprecated

Expand Down
27 changes: 8 additions & 19 deletions src/elements/SendoutElement.php
Original file line number Diff line number Diff line change
Expand Up @@ -1188,25 +1188,14 @@ public function setSchedule(ScheduleModel|array|string|null $schedule): void
*/
protected function htmlAttributes(string $context): array
{
$htmlAttributes = [];

if ($this->getIsModifiable()) {
$htmlAttributes['data-modifiable'] = true;
}

if ($this->getIsPausable()) {
$htmlAttributes['data-pausable'] = true;
}

if ($this->getIsResumable()) {
$htmlAttributes['data-resumable'] = true;
}

if ($this->getIsCancellable()) {
$htmlAttributes['data-cancellable'] = true;
}

return $htmlAttributes;
return [
'data' => [
'modifiable' => $this->getIsModifiable(),
'pausable' => $this->getIsPausable(),
'resumable' => $this->getIsResumable(),
'cancellable' => $this->getIsCancellable(),
],
];
}

/**
Expand Down

0 comments on commit 6db2acf

Please sign in to comment.