summaryrefslogtreecommitdiff
path: root/protected/models/Verein.php
diff options
context:
space:
mode:
Diffstat (limited to 'protected/models/Verein.php')
-rw-r--r--protected/models/Verein.php8
1 files changed, 6 insertions, 2 deletions
diff --git a/protected/models/Verein.php b/protected/models/Verein.php
index 8556f48..9274111 100644
--- a/protected/models/Verein.php
+++ b/protected/models/Verein.php
@@ -14,10 +14,12 @@
* @property string $beschreibung
* @property integer $standort_id
* @property integer $published
+ * @property string $hintergrund
*/
class Verein extends CActiveRecord
{
public $uploadedImage;
+ public $uploadedHintergrund;
/**
* Returns the static model of the specified AR class.
* @param string $className active record class name.
@@ -47,14 +49,14 @@ class Verein extends CActiveRecord
array("email, name", "required"),
array('standort_id, published', 'numerical', 'integerOnly'=>true),
array('name, url', 'length', 'max'=>255),
- array('bild, email, slug', 'length', 'max'=>100),
+ array('bild, email, slug, hintergrund', 'length', 'max'=>100),
array("url", "url", "allowEmpty"=>true, "message"=>"Die eingebene URL ist ungültig."),
array("email", "email", "message"=>"Die eingebene eMail-Adresse ist ungültig."),
array("uploadedImage", "file", "types"=>"jpg, gif, png", "allowEmpty"=>true, "wrongType"=>'Die Datei "{file}" konnte nicht hochgeladen werden. Es sind nur Dateien mit den folgenden Endungen erlaubt: {extensions}.'),
array('kontaktdaten, beschreibung', 'safe'),
// The following rule is used by search().
// Please remove those attributes that should not be searched.
- array('id, name, url, bild, email, slug, kontaktdaten, beschreibung, standort_id, published', 'safe', 'on'=>'search'),
+ array('id, name, url, email, slug, kontaktdaten, beschreibung, standort_id, published', 'safe', 'on'=>'search'),
);
}
@@ -86,6 +88,7 @@ class Verein extends CActiveRecord
'beschreibung' => 'Beschreibung',
'standort_id' => 'Standort',
'standort' => 'Standort',
+ 'hintergrund' => 'Hintergrundbild',
'published' => 'Öffentlich',
);
}
@@ -105,6 +108,7 @@ class Verein extends CActiveRecord
$criteria->compare('name',$this->name,true);
$criteria->compare('url',$this->url,true);
$criteria->compare('bild',$this->bild,true);
+ $criteria->compare('hintergrund',$this->hintergrund,true);
$criteria->compare('email',$this->email,true);
$criteria->compare('slug',$this->slug);
$criteria->compare('kontaktdaten',$this->kontaktdaten,true);