-
-
Notifications
You must be signed in to change notification settings - Fork 818
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Afform - Set data values in quick-add popup
Fixes https://lab.civicrm.org/dev/core/-/issues/5477 When using a quick-add form, this ensures the predetermined data values from the parent form's entity will be copied to the newly-created entity in the popup form.
- Loading branch information
Showing
11 changed files
with
172 additions
and
55 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -11,22 +11,21 @@ | |
* @group headless | ||
*/ | ||
class AfformEventUsageTest extends AfformUsageTestCase implements TransactionalInterface { | ||
use \Civi\Test\Api4TestTrait; | ||
|
||
/** | ||
* Tests prefilling an event from a template | ||
*/ | ||
public function testEventTemplatePrefill(): void { | ||
$locBlock1 = $this->createTestEntity('LocBlock', [ | ||
'email_id' => $this->createTestEntity('Email', ['email' => '[email protected]'])['id'], | ||
'phone_id' => $this->createTestEntity('Phone', ['phone' => '1234567'])['id'], | ||
$locBlock1 = $this->createTestRecord('LocBlock', [ | ||
'email_id' => $this->createTestRecord('Email', ['email' => '[email protected]'])['id'], | ||
'phone_id' => $this->createTestRecord('Phone', ['phone' => '1234567'])['id'], | ||
]); | ||
$locBlock2 = $this->createTestEntity('LocBlock', [ | ||
'email_id' => $this->createTestEntity('Email', ['email' => '[email protected]'])['id'], | ||
'phone_id' => $this->createTestEntity('Phone', ['phone' => '2234567'])['id'], | ||
$locBlock2 = $this->createTestRecord('LocBlock', [ | ||
'email_id' => $this->createTestRecord('Email', ['email' => '[email protected]'])['id'], | ||
'phone_id' => $this->createTestRecord('Phone', ['phone' => '2234567'])['id'], | ||
]); | ||
|
||
$eventTemplate = $this->createTestEntity('Event', [ | ||
$eventTemplate = $this->createTestRecord('Event', [ | ||
'template_title' => 'Test Template Title', | ||
'title' => 'Test Me', | ||
'event_type_id' => 1, | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters