Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Published by Scroll Versions from this space and version 2021.3

...

Each of the different types of Custom Logic: Custom Events, Custom API, and Custom Validation share these common syntaxes and available functions.

...

Code Block
languagephp
$contact_request = [
    "customer_number" => "ABC123",
    "last_name" => "Help",
    "first_name" => "PCR",
    "email" => "help@pcr.com",
    "email_directory" => 1,
    "phone_number" => "616-555-1212",
    "phone_primary" => 1,
    "phone_type" => 1234, // RECID from Lists
    "phone_directory" => 1,
    "status" => 1,
    "contact_directory" => 1,
    "contact_types" => "CUSTOMER",
];
$result_contact = $this->call("saveContact", $contact_request);
if($result_contact["status"] == "success") {
    $response["contact"] = $result_contact["data"];
}

...

debug

The debug command outputs to a cache which is then displayed in the Debug tab/grid for the Custom Logic you are debugging.

Example

In this example, the debug function is being invoked.

Code Block
languagephp
titleExample debug use
$this->debug();

Child pages (Children Display)
styleh6
sorttitle