function init_int_hotel() {
	
	// 初期化は1度のみ
//	if(typeof int_ticket == "object") return false;
	

	int_hotel = new formControll(document.intTkHtHt);

	int_hotel.init = function() {
		
		/***************************************************************************
		// 各プルダウンの読み込み @resouce from int_db.js
		***************************************************************************/		
		
		this.formView.createPulldown("depApo", intArrApo_list["JP"].slice(1));		// 出発空港
		this.formView.createPulldown("arrArea", intArrArea_list);					// 到着地域	
		this.formView.createPulldown("arrApo", allIntArrApo_list);					// 到着空港
				
		var tempList = day_list.slice(0, getDaylength());
		tempList.unshift({value:"", text:"---"});	
		
		this.formView.createPulldown("wayToMonth", month_list);						// 搭乗日時：往路：月
		this.formView.createPulldown("wayToDay", tempList);							//        ：日	
		
		this.formView.createPulldown("adultCount", persons_list.slice(1, 10));		// 人数：大人
		this.formView.createPulldown("childCount", persons_list.slice(0, 9));		//   ：子供
		this.formView.createPulldown("babyCount", persons_list.slice(0, 10));		//   ：幼児	
		
		this.formView.createPulldown("seatKind", intSeat_list);						// クラス				
		
			
		/***************************************************************************
		// 各エレメントの初期値のセット
		***************************************************************************/
	
		// いつもの情報設定
		var _depApo1 = (int_depApo1 == "") ? "TYO" : int_depApo1;
		this.formView.setPulldown("depApo", _depApo1);								// 出発空港
		
		this.formView.setPulldown("arrArea", "");									// 到着地域
		
		// いつもの情報設定
		var _arrApo1 = (int_arrApo1 == "") ? "" : int_arrApo1;
		this.formView.setPulldown("arrApo", _arrApo1);								// 到着空港


		// いつもの情報設定
	    var date  = new Date();
//		var _embMonth = (embMonth == "") ? date.getMonth()+1: embMonth;
		
//		this.formView.setPulldown("wayToMonth", _embMonth*1);						// 搭乗日時：往路：月
		this.formView.setPulldown("wayToMonth", date.getMonth()+1);					// 搭乗日時：往路：月
		this.formView.setPulldown("wayToDay", "");									//        ：日
		this.resetDay("wayToMonth", {value:"", text:"---"});
		//this.formView.addWeekPulldown("wayToDay");

		this.formView.setPulldown("adultCount", 1);									// 人数：大人
		this.formView.setPulldown("childCount", 0);									//   ：子供
		this.formView.setPulldown("babyCount", 0);									//   ：幼児	
		
		// いつもの情報設定
		var _int_seatKind = (int_seatKind == "") ? "Y" : int_seatKind;
		this.formView.setPulldown("seatKind", _int_seatKind); 						// クラス	
		
		/***************************************************************************
		// 各エレメントのイベントのセット
		***************************************************************************/
				
		
		// 空港プルダウン変更 => 空港コードを表示
		this.apoListener = function(eventObj) {
					
			var evt = this.getEventTarget(eventObj);
			if(!evt) evt = eventObj;
			var val = this.formView.getValue(evt);
			if(val == "NOP") val = "";
			
			this.formView.setCodeApo(this.formView.nextElement(evt), val);		
		};
		
		
		// 到着地域プルダウン変更 => 到着空港プルダウン生成 => 空港コードを表示
		this.arrArea = function(evt, val, targetElem) {
			
			if(val == "") {
				
				this.formView.createPulldown(targetElem, allIntArrApo_list);
				this.apoListener(targetElem);
				return false;
			}					
			
			var targetList = intArrApo_list[val].slice(1);
			this.formView.createPulldown(targetElem, targetList);
			//this.apoListener(targetElem);
		};		
		
		
		// 到着空港プルダウン変更 => valueが"IDX"の場合その次を表示
		this.arrApo = function(evt, val, targetElem) {
			
			if(val == "NOP") {
			
				this.formView.setSelectedIndex(evt, 0);
				val = this.formView.getValue(evt);
			}
			
			if(val == "IDX") {
				
				this.formView.setSelectedIndex(evt, this.formView.getSelectedIndex(evt)+1);
			}					
			//this.apoListener(evt);
		};		
		
		
		// 搭乗日時：往路：月プルダウン変更 => 往路：日を1日に設定 => 復路：月日を3日後に設定
		this.wayToMonth = function(evt, val, targetElem) {
					
			this.resetDay("wayToMonth", {value:"", text:"---"});
			this.formView.setPulldown(targetElem, 1);
			//this.relationListener(targetElem);// 往路：日プルダウンのイベント呼び出し
			
			//var toMonth = this.formView.Element(evt);			// 往路：月
			//var backMonth = targetElem;									// 復路：月
			//this.setMonthDay(evt, targetElem, "", "", {value:"", text:"---"});
		};

		// イベントの追加（一度追加したら追加しない）
		if(int_hotel_addEvent_flg == false){
			// 空港プルダウン変更 => 空港コードを表示
			//this.addEvent("depApo", "change", this.delegate(this, this.apoListener));
			//this.addEvent("arrApo", "change", this.delegate(this, this.apoListener));
			// 到着地域プルダウン変更 => 到着空港プルダウン生成 => 空港コードを表示
			this.addEvent("arrArea", "change", this.delegate(this, this.relationListener));
			// 到着空港プルダウン変更 => valueが"IDX"の場合その次を表示
			this.addEvent("arrApo", "change", this.delegate(this, this.relationListener));		
			// 搭乗日時：往路：月プルダウン変更 => 往路：日を1日に設定 => 復路：月日を3日後に設定
			this.addEvent("wayToMonth", "change", this.delegate(this, this.relationListener));
			// 搭乗日時：往路：日プルダウン変更 => 復路：月日を3日後に設定
			//this.addEvent("wayToDay", "change", this.delegate(this, this.relationListener));
			// 搭乗日時：復路：月プルダウン変更 => 復路：日を1日に設定
			//this.addEvent("wayBackMonth", "change", this.delegate(this, this.relationListener));		
			// フォーム送信イベント
			//this.addEvent(document.getElementById("BtnIntTkHtTk"), "click", this.delegate(this, this.submitForm));

			int_hotel_addEvent_flg = true;
		}
		
		
		// フォーム送信の前処理
		/*
		this.submitBefore = function() {
			
			with (this.form) {
				wayToMonth.options[wayToMonth.selectedIndex].value     = Number(wayToMonth.value);
				wayToDay.options[wayToDay.selectedIndex].value         = Number(wayToDay.value);
			}
			
		};
		*/
	}
	
	int_hotel.init();

	//履歴をセット
	int_onloadHistoryCookie();

}

// 二度フラグ
ticSubmited = false;


// フォーム送信
function HotOnSubmit() {
	
    with (document.intTkHtHt) {
        wayToMonth.options[wayToMonth.selectedIndex].value     = Number(wayToMonth.value);
        wayToDay.options[wayToDay.selectedIndex].value         = Number(wayToDay.value);
    }

    if (ticSubmited) return false;
    ticSubmited = true;
    return true;
}
