public function MailchimpCampaign::label in Mailchimp 2.x
Same name and namespace in other branches
- 8 modules/mailchimp_campaign/src/Entity/MailchimpCampaign.php \Drupal\mailchimp_campaign\Entity\MailchimpCampaign::label()
Gets the label of the entity.
Return value
string|null The label of the entity, or NULL if there is no label defined.
Overrides ContentEntityBase::label
File
- modules/
mailchimp_campaign/ src/ Entity/ MailchimpCampaign.php, line 144
Class
- MailchimpCampaign
- Defines the MailchimpCampaign entity.
Namespace
Drupal\mailchimp_campaign\EntityCode
public function label() {
// Ensure the data still exists.
if (!isset($this->mc_data) || !$this->mc_data || !isset($this->mc_data->settings) || !$this->mc_data->settings) {
return "";
}
return $this->mc_data->settings->title;
}