diff options
| author | 2012-10-25 19:06:32 +0200 | |
|---|---|---|
| committer | 2012-10-25 19:06:32 +0200 | |
| commit | 3ff51a59ba97f3ef1df3c26df16d9a3ab5789843 (patch) | |
| tree | 89de7b553f5b8240ad0d9f766800973f9845a121 /app/models/RSSConfiguration.php | |
| parent | 48a1aa7d52e712d5f64a33a003b31f23a00b99f5 (diff) | |
Ajout fonctionnalité connexion avec Persona (à améliorer sans doute)
Diffstat (limited to 'app/models/RSSConfiguration.php')
| -rwxr-xr-x | app/models/RSSConfiguration.php | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/app/models/RSSConfiguration.php b/app/models/RSSConfiguration.php index f3e7f9d4a..2ca60379a 100755 --- a/app/models/RSSConfiguration.php +++ b/app/models/RSSConfiguration.php @@ -7,6 +7,7 @@ class RSSConfiguration extends Model { private $sort_order; private $old_entries; private $shortcuts = array (); + private $mail_login = ''; public function __construct () { $confDAO = new RSSConfigurationDAO (); @@ -16,6 +17,7 @@ class RSSConfiguration extends Model { $this->_sortOrder ($confDAO->sort_order); $this->_oldEntries ($confDAO->old_entries); $this->_shortcuts ($confDAO->shortcuts); + $this->_mailLogin ($confDAO->mail_login); } public function postsPerPage () { @@ -36,6 +38,9 @@ class RSSConfiguration extends Model { public function shortcuts () { return $this->shortcuts; } + public function mailLogin () { + return $this->mail_login; + } public function _postsPerPage ($value) { if (is_int ($value)) { @@ -77,6 +82,13 @@ class RSSConfiguration extends Model { $this->shortcuts[$key] = $value; } } + public function _mailLogin ($value) { + if (filter_var ($value, FILTER_VALIDATE_EMAIL)) { + $this->mail_login = $value; + } elseif ($value == false) { + $this->mail_login = false; + } + } } class RSSConfigurationDAO extends Model_array { @@ -94,6 +106,7 @@ class RSSConfigurationDAO extends Model_array { 'next_page' => 'right', 'prev_page' => 'left', ); + public $mail_login = ''; public function __construct () { parent::__construct (PUBLIC_PATH . '/data/db/Configuration.array.php'); @@ -116,6 +129,9 @@ class RSSConfigurationDAO extends Model_array { if (isset ($this->array['shortcuts'])) { $this->shortcuts = $this->array['shortcuts']; } + if (isset ($this->array['mail_login'])) { + $this->mail_login = $this->array['mail_login']; + } } public function update ($values) { |
