public function getHasManyReference($table, $targetTable = NULL) { switch ("{$table}:{$targetTable}") { case 'posts:props': return [$targetTable, 'post_id']; } parent::getHasManyReference($table, $targetTable); }
public function __construct($primary = 'id', $foreign = '%s_id', $table = '%s') { parent::__construct($primary, $foreign, $table); trigger_error(__CLASS__ . '() is deprecated; use Nette\\Database\\Conventions\\StaticConventions instead.', E_USER_DEPRECATED); }