if(info.LCR_MAX_LDT_TBL) {
   var range_guide = " (1 - "+info.LCR_MAX_LDT_TBL+")";
} else {
   var range_guide = "";
}

var LCR_MAX_LDT_TBL_RANGE = "249";

if(LCR_MAX_LDT_TBL_RANGE) {
	var range_guide2 = " (0 - "+LCR_MAX_LDT_TBL_RANGE+")";
	if(LCR_MAX_LDT_TBL_RANGE < 99) {
		var maxInputRange = LCR_MAX_LDT_TBL_RANGE;
	} else {
		var maxInputRange = "100";
	}
}

define(
    {elements:[
        {name:"tab1", tab: [
            {key: "pgm221_button", button: [{btn: langs.getText("common","btn_save"), btn_type: "btn_save auth_write"}]},
            {key: "pgm221_preload", preload: [{name: "RANGE_TYPE_1", range_type: 2}, {text: langs.getText("p221","enter_tblindex")+range_guide+" : "}, {name: "RANGE_1_0", value: "", textfield: [{max: 8, size: 10}], message: ""}, {br: 1}, {name: "RANGE_TYPE_2", range_type: 2}, {text: langs.getText("common","enter_indexrange")+range_guide2+" : "}, {name: "RANGE_2_1", value: "", textfield: [{max: 40, size: 50}], message: "", help: langs.re_toolTip()+"<br><br>"+langs.getText("toolTip","maxinputrange")+" - "+maxInputRange}, {btn: langs.getText("common","load"), btn_type: "btn_load"},
				langs.Range_Error_Table(),
				{endload: 1}, {br: 2}, {text: langs.getText("common","ldt_tbl_index")+" "}, {name: "RANGE_VIEW_1", value: "", text: 1}, {br: 1}, {text: langs.getText("common","index_range")+" "}, {name: "RANGE_VIEW_2", value: "", text: 1}]},
            {key: "pgm221_mktbl", table: [{label: langs.getText("common","index")}, {label: langs.getText("common","val"), colspan: 2}, {label: langs.getText("common","range")}],
                              data_form: [{key: "", struct: [{tr: [ {name: "DEV_INDEX", value: "", rowspan: 7, label: 1}, {label: langs.getText("p221","ldt_type")}, {name:"LDT_TYPE", value: "", select: [{value: "1", option: langs.getText("p221","opt_ldt_type_int")}, {value: "2", option: langs.getText("p221","opt_ldt_type_col")}, {value: "3", option: langs.getText("common","opt_both")}], message: "", cont: 0}, {label: ""}]},
                                                             {tr: [{label: langs.getText("p221","ldt_cd")}, {name:"LDT_CD", value: "", textfield: [{max: 12, size: 15}], message: "", cont: 0}, {label: langs.getText("p221","cmt_max12digit")}]},
                                                             {tr: [{label: langs.getText("p221","ldt_password")}, {name:"LDT_PASSWARD", value: "", select: [{value: "0", option: langs.getText("common","opt_off")}, {value: "1", option: langs.getText("common","opt_on")}], message: "", cont: 0}, {label: ""}]},
                                                             {tr: [{label: langs.getText("common","ldt_zone_no")}, {name:"LDT_SUBZONE", value: "", textfield: [{max: 3, size: 10}], message: "", cont: 0}, {label: "1-100"}]},
															 {tr: [{label: langs.getText("common","dmt")+" 1"}, {name:"LDT_DMT_0", value: "", textfield: [{max: 6, size: 10}], message: "", cont: 0}, {label: langs.getText("common","must6digit")}]},
                                                             {tr: [{label: langs.getText("common","dmt")+" 2"}, {name:"LDT_DMT_1", value: "", textfield: [{max: 6, size: 10}], message: "", cont: 0}, {label: langs.getText("common","must6digit")}]},
                                                             {tr: [{label: langs.getText("common","dmt")+" 3"}, {name:"LDT_DMT_2", value: "", textfield: [{max: 6, size: 10}], message: "", cont: 0}, {label: langs.getText("common","must6digit")}]}]}],                                                           
                          variable_data: []}
		]}
	]}
);
