Opportunite

🔧 __construct

function __construct($id_obje = null) { try { if ($id_obje) { // Store the ID $this->id_obje = $id_obje; // Also store it in the entity attribute $this->Attributeidobje = $id_obje; $datas = parent::find($this->id_type, $id_obje, $this); $this->initializeProperties($datas); } } catch (Exception $e) { // Propagate the exception throw $e; // ... (truncated)

🔧 __construct

function __construct($id_obje = null) { try { if ($id_obje) { // Store the ID $this->id_obje = $id_obje; // Also store it in the entity attribute $this->Attributeidobje = $id_obje; $datas = parent::find($this->id_type, $id_obje, $this); $this->initializeProperties($datas); } } catch (Exception $e) { // Propagate the exception throw $e; // ... (truncated)

🔧 __construct

Class constructor initializes the object with type and ID
function __construct($id_obje = null) { try { if ($id_obje) { // Store the ID $this->id_obje = $id_obje; // Also store it in the entity attribute $this->Attributeidobje = $id_obje; $datas = parent::find($this->id_type, $id_obje, $this); $this->initializeProperties($datas); } } catch (Exception $e) { // Propagate the exception throw $e; // ... (truncated)

⚙️ Parameters

⚠️ Throws


🔧 getOrigineDuLead

function getOrigineDuLead() { return $this->OrigineDuLead; }

🔧 getOrigineDuLead

function getOrigineDuLead() { return $this->OrigineDuLead; }

🔧 getOrigineDuLead

function getOrigineDuLead() { return $this->OrigineDuLead; }

🔧 getOrigineDuLead

function getOrigineDuLead() { return $this->OrigineDuLead; }

🔧 getOrigineDuLead

function getOrigineDuLead() { return $this->OrigineDuLead; }

🔧 getOrigineDuLead

function getOrigineDuLead() { return $this->OrigineDuLead; }

🔧 getOrigineDuLead

function getOrigineDuLead() { return $this->OrigineDuLead; }

🔧 getOrigineDuLead

function getOrigineDuLead() { return $this->OrigineDuLead; }

🔧 getOrigineDuLead

function getOrigineDuLead() { return $this->OrigineDuLead; }

🔧 getOrigineDuLead

function getOrigineDuLead() { return $this->OrigineDuLead; }

🔧 getOrigineDuLead

function getOrigineDuLead() { return $this->OrigineDuLead; }

🔧 getOrigineDuLead

function getOrigineDuLead() { return $this->OrigineDuLead; }

🔧 getOrigineDuLead

function getOrigineDuLead() { return $this->OrigineDuLead; }

🔧 getOrigineDuLead

function getOrigineDuLead() { return $this->OrigineDuLead; }

🔧 getOrigineDuLead

function getOrigineDuLead() { return $this->OrigineDuLead; }

🔧 getOrigineDuLead

function getOrigineDuLead() { return $this->OrigineDuLead; }

🔧 getOrigineDuLead

function getOrigineDuLead() { return $this->OrigineDuLead; }

🔧 getOrigineDuLead

function getOrigineDuLead() { return $this->OrigineDuLead; }

🔧 getOrigineDuLead

function getOrigineDuLead() { return $this->OrigineDuLead; }

🔧 getOrigineDuLead

function getOrigineDuLead() { return $this->OrigineDuLead; }

🔧 getOrigineDuLead

function getOrigineDuLead() { return $this->OrigineDuLead; }

🔧 getOrigineDuLead

function getOrigineDuLead() { return $this->OrigineDuLead; }

🔧 getOrigineDuLead

function getOrigineDuLead() { return $this->OrigineDuLead; }

🔧 getOrigineDuLead

function getOrigineDuLead() { return $this->OrigineDuLead; }

🔧 getOrigineDuLead

function getOrigineDuLead() { return $this->OrigineDuLead; }

🔧 getOrigineDuLead

function getOrigineDuLead() { return $this->OrigineDuLead; }

🔧 getOrigineDuLead

function getOrigineDuLead() { return $this->OrigineDuLead; }

🔧 getOrigineDuLead

function getOrigineDuLead() { return $this->OrigineDuLead; }

🔧 getOrigineDuLead

function getOrigineDuLead() { return $this->OrigineDuLead; }

🔧 getOrigineDuLead

Gets the OrigineDuLead property value
function getOrigineDuLead() { return $this->OrigineDuLead; }

↩️ Returns

(mixed) The property value

🔧 setOrigineDuLead

Sets the OrigineDuLead property value
function setOrigineDuLead($value) { // Basic property assignment $this->OrigineDuLead = $value; // Store the value for saving later $this->datas["att7"] = $value; return $this; }

⚙️ Parameters

↩️ Returns

($this) for method chaining

🔧 getTitre

Gets the Titre property value
function getTitre() { return $this->Titre; }

↩️ Returns

(mixed) The property value

🔧 setTitre

Sets the Titre property value
function setTitre($value) { // Basic property assignment $this->Titre = $value; // Store the value for saving later $this->datas["att1"] = $value; return $this; }

⚙️ Parameters

↩️ Returns

($this) for method chaining

🔧 getNomduclient

Gets the Nomduclient property value
function getNomduclient() { return $this->Nomduclient; }

↩️ Returns

(mixed) The property value

🔧 setNomduclient

Sets the Nomduclient property value
function setNomduclient($value) { // Basic property assignment $this->Nomduclient = $value; // Store the value for saving later $this->datas["att2"] = $value; return $this; }

⚙️ Parameters

↩️ Returns

($this) for method chaining

🔧 getIsFranchiseur

Gets the IsFranchiseur property value
function getIsFranchiseur() { return $this->IsFranchiseur; }

↩️ Returns

(mixed) The property value

🔧 setIsFranchiseur

Sets the IsFranchiseur property value
function setIsFranchiseur($value) { // Basic property assignment $this->IsFranchiseur = $value; // Store the value for saving later $this->datas["attf103"] = $value; return $this; }

⚙️ Parameters

↩️ Returns

($this) for method chaining

🔧 getCommentaire

Gets the Commentaire property value
function getCommentaire() { return $this->Commentaire; }

↩️ Returns

(mixed) The property value

🔧 setCommentaire

Sets the Commentaire property value
function setCommentaire($value) { // Basic property assignment $this->Commentaire = $value; // Store the value for saving later $this->datas["att90"] = $value; return $this; }

⚙️ Parameters

↩️ Returns

($this) for method chaining

🔧 getDateDeCreation

Gets the DateDeCreation property value
function getDateDeCreation() { return $this->DateDeCreation; }

↩️ Returns

(mixed) The property value

🔧 setDateDeCreation

Sets the DateDeCreation property value
function setDateDeCreation($value) { // Basic property assignment $this->DateDeCreation = $value; // Store the value for saving later $this->datas["attf100"] = $value; return $this; }

⚙️ Parameters

↩️ Returns

($this) for method chaining

🔧 getDateDeProchainRappel

Gets the DateDeProchainRappel property value
function getDateDeProchainRappel() { return $this->DateDeProchainRappel; }

↩️ Returns

(mixed) The property value

🔧 setDateDeProchainRappel

Sets the DateDeProchainRappel property value
function setDateDeProchainRappel($value) { // Basic property assignment $this->DateDeProchainRappel = $value; // Store the value for saving later $this->datas["attf101"] = $value; return $this; }

⚙️ Parameters

↩️ Returns

($this) for method chaining

🔧 getAdresseintervention

Gets the Adresseintervention property value
function getAdresseintervention() { return $this->Adresseintervention; }

↩️ Returns

(mixed) The property value

🔧 setAdresseintervention

Sets the Adresseintervention property value
function setAdresseintervention($value) { // Basic property assignment $this->Adresseintervention = $value; // Store the value for saving later $this->datas["att8"] = $value; return $this; }

⚙️ Parameters

↩️ Returns

($this) for method chaining

🔧 getIduser

Gets the Iduser property value
function getIduser() { return $this->Iduser; }

↩️ Returns

(mixed) The property value

🔧 setIduser

Sets the Iduser property value
function setIduser($value) { // Basic property assignment $this->Iduser = $value; // Store the value for saving later $this->datas["att6"] = $value; return $this; }

⚙️ Parameters

↩️ Returns

($this) for method chaining

🔧 getContact

Gets the Contact property value
function getContact() { return $this->Contact; }

↩️ Returns

(mixed) The property value

🔧 setContact

Sets the Contact property value
function setContact($value) { // Basic property assignment $this->Contact = $value; // Store the value for saving later $this->datas["att9"] = $value; return $this; }

⚙️ Parameters

↩️ Returns

($this) for method chaining

🔧 getDaterdvtechnique

Gets the Daterdvtechnique property value
function getDaterdvtechnique() { return $this->Daterdvtechnique; }

↩️ Returns

(mixed) The property value

🔧 setDaterdvtechnique

Sets the Daterdvtechnique property value
function setDaterdvtechnique($value) { // Basic property assignment $this->Daterdvtechnique = $value; // Store the value for saving later $this->datas["attf102"] = $value; return $this; }

⚙️ Parameters

↩️ Returns

($this) for method chaining

🔧 getTypeintervention

Gets the Typeintervention property value
function getTypeintervention() { return $this->Typeintervention; }

↩️ Returns

(mixed) The property value

🔧 setTypeintervention

Sets the Typeintervention property value
function setTypeintervention($value) { // Basic property assignment $this->Typeintervention = $value; // Store the value for saving later $this->datas["att3"] = $value; return $this; }

⚙️ Parameters

↩️ Returns

($this) for method chaining

🔧 getDelaitransformationstatutgagne

Gets the Delaitransformationstatutgagne property value
function getDelaitransformationstatutgagne() { return $this->Delaitransformationstatutgagne; }

↩️ Returns

(mixed) The property value

🔧 setDelaitransformationstatutgagne

Sets the Delaitransformationstatutgagne property value
function setDelaitransformationstatutgagne($value) { // Basic property assignment $this->Delaitransformationstatutgagne = $value; // Store the value for saving later $this->datas["att4"] = $value; return $this; }

⚙️ Parameters

↩️ Returns

($this) for method chaining

🔧 getDatechangementstatut

Gets the Datechangementstatut property value
function getDatechangementstatut() { return $this->Datechangementstatut; }

↩️ Returns

(mixed) The property value

🔧 setDatechangementstatut

Sets the Datechangementstatut property value
function setDatechangementstatut($value) { // Basic property assignment $this->Datechangementstatut = $value; // Store the value for saving later $this->datas["attf104"] = $value; return $this; }

⚙️ Parameters

↩️ Returns

($this) for method chaining

🔧 getRaisonSociale

Gets the RaisonSociale property value
function getRaisonSociale() { return $this->RaisonSociale; }

↩️ Returns

(mixed) The property value

🔧 setRaisonSociale

Sets the RaisonSociale property value
function setRaisonSociale($value) { // Basic property assignment $this->RaisonSociale = $value; // Store the value for saving later $this->datas["att5"] = $value; return $this; }

⚙️ Parameters

↩️ Returns

($this) for method chaining

🔧 getTypeDeClient

Gets the TypeDeClient property value
function getTypeDeClient() { return $this->TypeDeClient; }

↩️ Returns

(mixed) The property value

🔧 setTypeDeClient

Sets the TypeDeClient property value
function setTypeDeClient($value) { // Basic property assignment $this->TypeDeClient = $value; // Store the value for saving later $this->datas["att10"] = $value; return $this; }

⚙️ Parameters

↩️ Returns

($this) for method chaining

🔧 getPrescripteur

Gets the Prescripteur property value
function getPrescripteur() { return $this->Prescripteur; }

↩️ Returns

(mixed) The property value

🔧 setPrescripteur

Sets the Prescripteur property value
function setPrescripteur($value) { // Basic property assignment $this->Prescripteur = $value; // Store the value for saving later $this->datas["att11"] = $value; return $this; }

⚙️ Parameters

↩️ Returns

($this) for method chaining

🔧 getPrescripteurLie

Gets the PrescripteurLie property value
function getPrescripteurLie() { return $this->PrescripteurLie; }

↩️ Returns

(mixed) The property value

🔧 setPrescripteurLie

Sets the PrescripteurLie property value
function setPrescripteurLie($value) { // Basic property assignment $this->PrescripteurLie = $value; // Store the value for saving later $this->datas["att12"] = $value; return $this; }

⚙️ Parameters

↩️ Returns

($this) for method chaining

🔧 getCalendarevent

Gets the Calendarevent property value
function getCalendarevent() { return $this->Calendarevent; }

↩️ Returns

(mixed) The property value

🔧 setCalendarevent

Sets the Calendarevent property value
function setCalendarevent($value) { // Basic property assignment $this->Calendarevent = $value; // Store the value for saving later $this->datas["att13"] = $value; return $this; }

⚙️ Parameters

↩️ Returns

($this) for method chaining

🔧 getAttributeactif

Gets the Attributeactif property value
function getAttributeactif() { return $this->Attributeactif; }

↩️ Returns

(mixed) The property value

🔧 setAttributeactif

Sets the Attributeactif property value
function setAttributeactif($value) { // Basic property assignment $this->Attributeactif = $value; // Store the value for saving later $this->datas["actif"] = $value; return $this; }

⚙️ Parameters

↩️ Returns

($this) for method chaining

🔧 getAttributeidtype

Gets the Attributeidtype property value
function getAttributeidtype() { return $this->Attributeidtype; }

↩️ Returns

(mixed) The property value

🔧 setAttributeidtype

Sets the Attributeidtype property value
function setAttributeidtype($value) { // Basic property assignment $this->Attributeidtype = $value; // Store the value for saving later $this->datas["id_type"] = $value; return $this; }

⚙️ Parameters

↩️ Returns

($this) for method chaining

🔧 getStatut

Gets the Statut property value
function getStatut() { return $this->Statut; }

↩️ Returns

(mixed) The property value

🔧 setStatut

Sets the Statut property value
function setStatut($value) { try { // For workflow fields, we store both the ID and the name $this->originalStatut = $value; if (!empty($value) && function_exists("fwc7_param_objet_workflow")) { $workflow_data = fwc7_param_objet_workflow("", $this->get_id_type(), $value); if (!empty($workflow_data) && isset($workflow_data["nom"])) { $this->Statut = $workflow_data["nom"]; } else { $this->Statut = $value; } // ... (truncated)

⚙️ Parameters

↩️ Returns

($this) for method chaining

🔧 getAttributeattdatcre

Gets the Attributeattdatcre property value
function getAttributeattdatcre() { return $this->Attributeattdatcre; }

↩️ Returns

(mixed) The property value

🔧 setAttributeattdatcre

Sets the Attributeattdatcre property value
function setAttributeattdatcre($value) { // Basic property assignment $this->Attributeattdatcre = $value; // Store the value for saving later $this->datas["attdatcre"] = $value; return $this; }

⚙️ Parameters

↩️ Returns

($this) for method chaining

🔧 getAttributeattdatmod

Gets the Attributeattdatmod property value
function getAttributeattdatmod() { return $this->Attributeattdatmod; }

↩️ Returns

(mixed) The property value

🔧 setAttributeattdatmod

Sets the Attributeattdatmod property value
function setAttributeattdatmod($value) { // Basic property assignment $this->Attributeattdatmod = $value; // Store the value for saving later $this->datas["attdatmod"] = $value; return $this; }

⚙️ Parameters

↩️ Returns

($this) for method chaining

🔧 getAttributeattusermod

Gets the Attributeattusermod property value
function getAttributeattusermod() { return $this->Attributeattusermod; }

↩️ Returns

(mixed) The property value

🔧 setAttributeattusermod

Sets the Attributeattusermod property value
function setAttributeattusermod($value) { // Basic property assignment $this->Attributeattusermod = $value; // Store the value for saving later $this->datas["attusermod"] = $value; return $this; }

⚙️ Parameters

↩️ Returns

($this) for method chaining

🔧 getAttributenewobj

Gets the Attributenewobj property value
function getAttributenewobj() { return $this->Attributenewobj; }

↩️ Returns

(mixed) The property value

🔧 setAttributenewobj

Sets the Attributenewobj property value
function setAttributenewobj($value) { // Basic property assignment $this->Attributenewobj = $value; // Store the value for saving later $this->datas["newobj"] = $value; return $this; }

⚙️ Parameters

↩️ Returns

($this) for method chaining

🔧 getAttributeidvent

Gets the Attributeidvent property value
function getAttributeidvent() { return $this->Attributeidvent; }

↩️ Returns

(mixed) The property value

🔧 setAttributeidvent

Sets the Attributeidvent property value
function setAttributeidvent($value) { // Basic property assignment $this->Attributeidvent = $value; // Store the value for saving later $this->datas["id_vent"] = $value; return $this; }

⚙️ Parameters

↩️ Returns

($this) for method chaining

🔧 getAttributeidobje

Gets the Attributeidobje property value
function getAttributeidobje() { return $this->Attributeidobje; }

↩️ Returns

(mixed) The property value

🔧 setAttributeidobje

Sets the Attributeidobje property value
function setAttributeidobje($value) { // Basic property assignment $this->Attributeidobje = $value; // Store the value for saving later $this->datas["id_obje"] = $value; return $this; }

⚙️ Parameters

↩️ Returns

($this) for method chaining

🔧 validate

Validates that all required properties have values
function validate() { $errors = []; // Validation logic can be added here // Example: check that required fields have values if (empty($errors)) { return true; } return $errors; }

↩️ Returns

(bool|array) True if valid, array of error messages if invalid

🔧 getClient

Gets the client associated with this opportunity
function getClient() { try { // Get client ID from opportunity $clientId = $this->getNomduclient(); if (empty($clientId)) { error_log("Missing client ID for opportunity"); return null; } // Load the client object directly using Client entity $client = new \CalDav\Entity\Client($clientId); return $client; } catch (Exception $e) { // ... (truncated)

↩️ Returns

(object|null) The client object or null if not found

🔧 getAddresseIntervention

Gets the formatted intervention address
function getAddresseIntervention() { try { // Define the client type ID and address template ID $type_id_client = (new \CalDav\Entity\Client())->get_id_type(); $id_tlig = fwp7_param_template_tlg_get_number("", $type_id_client, "adresse_intervention"); // Get client ID $clientId = $this->getNomduclient(); if (empty($clientId)) { return "Adresse non spécifiée"; } // Get intervention address lines $addresseInterventionLigs = reset(fwc7_data_objet_ligs("", $type_id_client, $clientId, $id_tlig, $this->getAdresseintervention(), "1", "", "", "", "", false, false, "")); // Validate and initialize address lines with fallback to empty string if (!is_array($addresseInterventionLigs)) { // ... (truncated)

↩️ Returns

(string) The formatted address

🔧 getEventDateTime

Gets the start and end date/time for the calendar event
function getEventDateTime() { try { // Parse and validate the technical appointment date $dateString = $this->getDaterdvtechnique(); if (empty($dateString) || strlen($dateString) < 12) { error_log("Missing or invalid date for opportunity"); return null; } // Extract date components $year = substr($dateString, 0, 4); $month = substr($dateString, 4, 2); $day = substr($dateString, 6, 2); // ... (truncated)

↩️ Returns

(array|null) Array with 'start' and 'end' DateTime objects or null if invalid

🔧 getCalendarEventData

Gets calendar event data formatted for CalDAV integration
function getCalendarEventData() { try { // Get client information $client = $this->getClient(); if (!$client) { throw new Exception("Client information not available"); } // Get address $adresse = $this->getAddresseIntervention(); if (empty($adresse)) { $adresse = "Adresse non spécifiée"; } // ... (truncated)

↩️ Returns

(array) The event data with title, description, times, location and additional properties