PluginProbe
The Innovative Form Builder – IvyForms / 1.5
The Innovative Form Builder – IvyForms v1.5
1.5.1 1.5 1.4.1 1.4 trunk 0.1.2 0.2 0.2.1 0.3 0.3.1 0.4 0.5 0.6 0.6.1 0.6.1-backup 0.6.1.1 0.7 0.8 0.8.1 0.8.2 0.9 0.9.1 1.0 1.1 1.1.1 All 27 releases
← All changes | backend/src/Entity/Notification/Notification.php +25 -2 1.1.1 → 1.5 View file →
@@ -7,9 +7,8 @@
7 7
8 8 namespace IvyForms\Entity\Notification;
9 9
10 10 use IvyForms\ValueObjects\Notification\Notification as NotificationValueObject;
11 -use IvyForms\Entity\Notification\NotificationContact;
12 11
13 12 /**
14 13 * Class Notification
15 14 *
@@ -27,8 +26,15 @@
27 26 */
28 27 private NotificationContact $contact;
29 28
30 29 /**
30 + * Opaque extension payload (Pro / add-ons). Not owned by Lite domain fields.
31 + *
32 + * @var array<string, mixed>
33 + */
34 + private array $extensionData = [];
35 +
36 + /**
31 37 * Notification constructor.
32 38 *
33 39 * @param NotificationValueObject $notification The notification object.
34 40 */
@@ -38,8 +44,24 @@
38 44 $this->contact = new NotificationContact($notification->contact);
39 45 }
40 46
41 47 /**
48 + * @param array<string, mixed> $data
49 + */
50 + public function setExtensionData(array $data): void
51 + {
52 + $this->extensionData = $data;
53 + }
54 +
55 + /**
56 + * @return array<string, mixed>
57 + */
58 + public function getExtensionData(): array
59 + {
60 + return $this->extensionData;
61 + }
62 +
63 + /**
42 64 * Get the notification ID.
43 65 *
44 66 * @return int
45 67 */
@@ -225,8 +247,9 @@
225 247 'showEmptyFields' => $this->isShowEmptyFields(),
226 248 'smartLogic' => $this->getSmartLogic(),
227 249 'formId' => $this->getFormId(),
228 250 ],
229 - $this->getNotificationContact()->toArray()
251 + $this->getNotificationContact()->toArray(),
252 + $this->extensionData
230 253 );
231 254 }
232 255 }