<?php
class ProductItem extends AppModel {
	var $name = 'ProductItem';
	var $validate = array(
//		'product_id' => array(
//			'numeric' => array(
//				'rule' => array('numeric'),
//			),
//		),
		'article_id' => array(
			'numeric' => array(
				'rule' => array('numeric'),
			),
		),
		'amount' => array(
			'numeric' => array(
				'rule' => array('numeric'),
			),
		),
	);

	var $belongsTo = array(
		'Product' => array(
			'className' => 'Product',
			'foreignKey' => 'product_id',
			'conditions' => '',
			'fields' => '',
			'order' => ''
		),
		'Article' => array(
			'className' => 'Article',
			'foreignKey' => 'article_id',
			'conditions' => '',
			'fields' => '',
			'order' => ''
		)
	);
}
