function searchFacilities ($id, $node_id, $class_id, $inner)
{
	this.node_id  = $node_id
	this.chara    = $id;
	this.class_id = $class_id;
	this.inner    = $inner;

	var $this = this;

	this.set = function()
	{
		$.each( $($this.chara).find('input'), function()
		{
			$(this).click( function()
			{
				$this.node_id = $(this).val();
				if( $this.node_id )
				{
					$action.searchFacilities.execute($this);
				}
			});
		});
	}

	this.getSearchFacilitiesObject = function()
	{
		return this;
	}
}

$action.searchFacilities = {
	execute : function($object)
	{
		this.object = $object;
		this.get();
	},
	getObject : function()
	{
		$this = this.object.getSearchFacilitiesObject();
		return $this;
	},
	get : function()
	{
		var $this = this.getObject();
		var $param      = {object_id:$this.node_id,class_id:$this.class_id,a:'search_facilities'};
		var $path       = '/ajax/get_category/';
		var $after      = '$action.searchFacilities.inner()';
		new get( $path, $param, $after );
	},
	inner : function()
	{
		var $response = new ajaxResponse();
		var $this     = this.getObject();
		$($this.inner).html($response.response);
	},
	set : function()
	{
		var $this    = this.getObject(); 
		var $_action = this;
	}
}

$(function(){
//	$('#search input[@type=radio]').attr('checked', '')
//	$('#search input[@type=checkbox]').attr('checked', '')
});
