<?php
class Table extends AppModel {
	var $name = 'Table';
	var $displayField = 'name';
	var $validate = array(
		'table_group_id' => array(
			'numeric' => array(
				'rule' => array('numeric'),
			),
		),
		'name' => array(
			'notempty' => array(
				'rule' => array('notempty'),
			),
			'unique' => array(
				'rule' => array('unique'),
			),
		),
	);

	var $belongsTo = array(
		'TableGroup' => array(
			'className' => 'TableGroup',
			'foreignKey' => 'table_group_id',
			'conditions' => '',
			'fields' => '',
			'order' => ''
		)
	);

	/*var $hasMany = array(
		'Sale' => array(
			'className' => 'Sale',
			'foreignKey' => 'table_id',
			'dependent' => false,
			'conditions' => '',
			'fields' => '',
			'order' => '',
			'limit' => '',
			'offset' => '',
			'exclusive' => '',
			'finderQuery' => '',
			'counterQuery' => ''
		)
	);*/

}
