34 lines
644 B
PHP
34 lines
644 B
PHP
<?php
|
|
|
|
/**
|
|
* Subclass for representing a row from the 'app_ads_tracker_campaign' table.
|
|
*
|
|
*
|
|
*
|
|
* @package plugins.appAdsTrackerPlugin.lib.model
|
|
*/
|
|
class AdsTrackerCampaign extends BaseAdsTrackerCampaign
|
|
{
|
|
public function __toString()
|
|
{
|
|
return $this->getAdsName();
|
|
}
|
|
|
|
public function save($con = null)
|
|
{
|
|
|
|
if ($this->isNew() && null === $this->getColor())
|
|
{
|
|
$this->setColor(appAdsTracker::random_color());
|
|
}
|
|
|
|
parent::save();
|
|
}
|
|
|
|
public function getAdminGeneratorTitle()
|
|
{
|
|
return $this->getAdsName();
|
|
}
|
|
|
|
}
|