MP_Addon_Netsuite_REST::netsuite_send_from_lead_page()
Callback function to send lead data from the lead page.
Source Source
File: calculator-netsuite-add-on/inc/MP_Addon_Netsuite_REST.php
public function netsuite_send_from_lead_page() {
MP_Callback::check_nonce($_REQUEST['nonce'], MortgagePlatform::$prefix . 'netsuite');
$post_ID = sanitize_text_field($_POST['id']);
$lead = array(
'lead' => $post_ID,
'firstname' => get_post_meta($post_ID, MortgagePlatform::$prefix . 'lead_firstname', true),
'secondname' => get_post_meta($post_ID,MortgagePlatform::$prefix . 'lead_secondname', true),
'phone' => get_post_meta($post_ID,MortgagePlatform::$prefix . 'lead_phone', true),
'email' => get_post_meta($post_ID,MortgagePlatform::$prefix . 'lead_email', true),
);
$this->set_lead_data_to_netsuite($lead);
wp_die();
}
Changelog Changelog
| Version | Description |
|---|---|
| 1.0.0 | Introduced. |