Add models

This commit is contained in:
Michael RICOIS 2013-07-17 09:53:33 +00:00
parent 8e2a346a5e
commit c5d47727a5
3 changed files with 28 additions and 0 deletions

View File

@ -0,0 +1,6 @@
<?php
class Application_Model_JoLiens extends Zend_Db_Table_Abstract
{
protected $_name = 'liens2';
protected $_schema = 'jo';
}

View File

@ -0,0 +1,6 @@
<?php
class Application_Model_JoLiensDoc extends Zend_Db_Table_Abstract
{
protected $_name = 'liensDoc';
protected $_schema = 'jo';
}

View File

@ -0,0 +1,16 @@
<?php
class Application_Model_JoLiensRef extends Zend_Db_Table_Abstract
{
protected $_name = 'liensRef';
protected $_schema = 'jo';
public function insert(array $data)
{
// Ajout d'un timestamp
if (empty($data['dateInsert'])) {
$data['dateInsert'] = date('YmdHis');
}
return parent::insert($data);
}
}