Skip to content

Instantly share code, notes, and snippets.

View gist:549493
<?php
class BaseForm extends sfFormSymfony
{
static protected $user = null;
static public function getUser()
{
return self::$user;
}
View gist:549509
*/
class OrdinativiHealthStateForm extends BaseOrdinativiHealthStateForm
{
public function configure()
{
$this->useFields(array('name'));
$this->widgetSchema->setLabels(array(
'name' => 'Nome',
));
View gist:549522
<?php
class BaseForm extends sfFormSymfony
{
static protected $user = null;
static public function getUser()
{
return self::$user;
}
View gist:549524
<?php
class BaseForm extends sfFormSymfony
{
static protected $user = null;
static public function getUser()
{
return self::$user;
}
View gist:549638
<?php
/**
* healthstate actions.
*
* @package ordinativi
* @subpackage healthstate
* @author KEY5
* @version SVN: $Id: actions.class.php 23810 2009-11-12 11:07:44Z Kris.Wallsmith $
View OrdinativiMenuItemDayTable.class.php
<?php
class OrdinativiMenuItemDayTable extends Doctrine_Table
{
public static function getInstance()
{
return Doctrine_Core::getTable('OrdinativiMenuItemDay');
}
View BaseOrdinativiMenuItem.class.php
<?php
/**
* BaseOrdinativiMenuItem
*
* This class has been auto-generated by the Doctrine ORM Framework
*
* @property integer $menu_id
* @property string $name
* @property string $type
View gist:557848
OrdinativiMenuItem:
actAs: { Timestampable: ~ }
columns:
menu_id: { type: integer, notnull: true, default: 0 }
name: { type: string(255), notnull: true }
type: { type: string(3) }
state: { type: integer, notnull: true, default: 0 }
enabled: { type: boolean, notnull: true, default: 0 }
relations:
OrdinativiHealthState: { type: many, foreignType: one, class: OrdinativiHealthState, local: state, foreign: id, onDelete: CASCADE, foreignAlias: OrdinativiHealthStates }
View OrdinativiMenuItemDayTable.class.php
<?php
class OrdinativiMenuItemDayTable extends Doctrine_Table
{
public static function getInstance()
{
return Doctrine_Core::getTable('OrdinativiMenuItemDay');
}
View prova.php
<?php
$foods = Doctrine_Query::create()
->from('OrdinativiMenuItemDay a')
->leftJoin('a.MenuItemDays m')
->where('a.menu_id = ? ', $menu_id );
var_dump($foods->fetchArray());