/*
------------Left Button---------------
*/
/*EIP 模組按鈕*/
function main_EipModule_click(that)
{
	var LeftDivId="#Main_Left-List";
	var Class = new ListCommon();
	Class.ChangeDivCss(that, LeftDivId);
	Class = new Path();
	Class.LoadPathHtml($(that).text(), 1, "main_PathEipModule_click(this)");
	Class = new LoadHtml();
	var Html = Class.GetVariableTranslationHtml(Global_EipModuleCssHtml);
	Html = Html + Class.GetVariableTranslationHtml(Global_EipModuleFirstPageHtml);
	Html = Html + Class.GetVariableTranslationHtml(Global_EipModuleSecondPageHtml);
	$("#Main_Center-Content").empty();
	$("#Main_Center-Content").append(Html);
	Class = new EipModuleFirstPage();
	Class.Initialization();
	Class = null;
}
/*路徑*/
function main_PathEipModule_click(that)
{
	var Class = new Path();
	Class.ClearTheDivOfTheTail(that, "#Main_Top-Path");
	$("#Main_Left-List").css("display", "block");
	Class = new EipModuleSecondPage();
	Class.NoConfirmButton();
	Class = null;
}

//----------------第一頁-------------------
/*EIP 全選打勾Checkbox*/
function main_EipModuleChangeAllCheckbox_click(that)
{
	var DataModelId = $(that).closest(".Table").attr("id");
	var Bool = $(that).closest(".Row").find(":checkbox").prop("checked");
	$("#"+DataModelId).find(".DynamicRow").find(":checkbox").prop("checked",Bool);
}
/*[+]*/
function main_EipModuleAddNewRow_click(that)
{
	var Class = new EipModuleFirstPage();
	Class.ModuleAddNewRow(that);
	Class = null;
}
/*移除全部*/
function main_EipModuleClearDialogEnabled_click(Event)
{

	var Class = new EipModuleFirstPage();
	Class.ClearDialogEnabled(Event);
	Class = null;
}
/*全補移除 [是]*/
function main_EipModuleClearAllModule_click(that)
{
	var Class = new EipModuleFirstPage();
	Class.ClearAllModule(that);
	Class = null;
}
/*全部移除 [否]*/
function main_EipModuleClearDialogDisabled_click()
{
	var Class = new EipModuleFirstPage();
	Class.ClearDialogDisabled();
	Class = null;
}
/*複製模組*/
function main_EipModuleCopyDialogEnabled_click(that, Event)
{
	var Class = new EipModuleFirstPage();
	if(Class.IsTickedModule() == false)
	{
		$(that).closest(".Column").find(".Message").eq(0).show();
		return 0;
	}
	$(that).closest(".Column").find(".Message").eq(0).hide();
	Class.CopyDialogEnabled(Event);
	Class = null;
}
/*複製模組 [是]*/
function main_EipModuleCopyModule_click()
{
	$(".Dialog").find(".Message").show();
	var Class = new EipModuleFirstPage();
	Class.CopyModule();
	Class = null;
}
/*複製模組 [否]*/
function main_EipModuleCopyDialogDisabled_click()
{
	var Class = new EipModuleFirstPage();
	Class.CopyDialogDisabled();
	Class = null;
}
/*移除模組*/
function main_EipModuleDeleteModule_click(that)
{
	var Class = new EipModuleFirstPage();
	if(Class.IsTickedModule() == false)
	{
		$(that).closest(".Column").find(".Message").eq(0).show();
		return 0;
	}
	$(that).closest(".Column").find(".Message").eq(0).hide();
	Class.DeleteModule();
	Class = null;
}
/*頁數 [上一頁]*/
function main_EipModuleShowPreviousPage_click()
{
	var Class = new EipModuleFirstPage();
	Class.ShowPreviousPage();
	Class = null;
}
/*頁數 [下一頁]*/
function main_EipModuleShowNextPage_click()
{
	var Class = new EipModuleFirstPage();
	Class.ShowNextPage();
	Class = null;
}
/*編輯*/
function main_EipModuleSettingButton_click(that)
{
	var Class = new EipModuleFirstPage();
	Class.EditButton(that);
	Class = null;
}
/*儲存按鈕*/
function main_EipModuleSaveButton_click(that)
{
	var Class = new EipModuleFirstPage();
	Class.SaveButton(that);
	Class = null;
}
/*
----------------第二頁-------------------
*/
/*確認*/
function main_EipModuleConfirmButton_click(that)
{
	var Class = new EipModuleSecondPage();
	Class.ConfirmButton(that);
	Class = null;
}
/*取消*/
function main_EipModuleNoConfirmButton_click()
{
	var Class = new EipModuleSecondPage();
	Class.NoConfirmButton();
	Class = null;
}