if(pgm_info.s001_1.auth) {
    var v_1 = {key: "pgms001_dnd", title: langs.getText("common","dnd"), tr:[{order: 1}, {label: langs.getText("common","dnd")}, {name: "DND", value: "", select: [{value: "0", option: langs.getText("common","opt_off")}, {value: "1", option: langs.getText("common","opt_on")}], message: "", cont: 0}, {label: ""}]};
} else {
    var v_1 = {};
}

if(pgm_info.s001_2.auth) {
    var v_2 = {key: "pgms001_icmsignal", title: langs.getText("common","icmsignal"), tr:[{order: 1}, {label: langs.getText("common","icmsignal")}, {name: "ICMSIGNAL", value: "", select: [{value: "1", option: "H"}, {value: "2", option: "T"}, {value: "3", option: "P"}], message: "", cont: 0}, {label: ""}]};
} else {
    var v_2 = {};
}

if(pgm_info.s001_3.auth) {
    var v_3 = {key: "pgms001_ccmode", title: langs.getText("common","call_cover_mode"), tr:[{order: 1}, {label: langs.getText("common","call_cover_mode")}, {name: "CCMODE", value: "", select: [{value: "0", option: langs.getText("common","opt_off")}, {value: "1", option: langs.getText("common","opt_on")}], message: "", cont: 0}, {label: ""}]};
} else {
    var v_3 = {};
}

if(pgm_info.s001_4.auth) {
    var v_4 = {key: "pgms001_dlyring", title: langs.getText("ps001","dlyring"), tr:[{order: 1}, {label: langs.getText("ps001","dlyring")}, {name: "DLYRING", value: "", textfield: [{max: 2}], message: "", cont: 0}, {label: "0-15"}]};
} else {
    var v_4 = {};
}

if(pgm_info.s001_5.auth) {
    var v_5 = {key: "pgms001_earmic", title: langs.getText("ps001","earmic"), tr:[{order: 1}, {label: langs.getText("ps001","earmic")}, {name: "EARMIC", value: "", select: [{value: "0", option: langs.getText("common","opt_off")}, {value: "1", option: langs.getText("common","opt_on")}], message: "", cont: 0}, {label: ""}]};
} else {
    var v_5 = {};
}

if(pgm_info.s001_6.auth) {
    var v_6 = {key: "pgms001_authcode", title: langs.getText("common","authcode"), tr:[{order: 1}, {label: langs.getText("common","authcode")}, {name: "AUTHCODE", value: "", textfield: [{max: 12}], message: "", cont: 0}, {label: langs.getText("ps001","cmt_authcode")}]};
} else {
    var v_6 = {};
}

if(pgm_info.s001_7.auth) {
    var v_7 = {key: "pgms001_didwait", title: langs.getText("p113","didwait"), tr:[{order: 1}, {label: langs.getText("p113","didwait")}, {name: "DIDWAIT", value: "", select: [{value: "0", option: langs.getText("p113","opt_callwait_off")}, {value: "1", option: langs.getText("p113","opt_callwait_all")}, {value: "2", option: langs.getText("p113","opt_callwait_ext")}, {value: "3", option: langs.getText("p113","opt_callwait_int")}], message: "", cont: 0}, {label: ""}]};
} else {
    var v_7 = {};
}

if(pgm_info.s001_8.auth) {
    var v_8 = {key: "pgms001_execmsg", title: langs.getText("ps001","execmsg"), tr:[{order: 1}, {label: langs.getText("ps001","execmsg")}, {name: "EXECMSG", value: "", select: [{value: "0", option: langs.getText("common","opt_off")}, {value: "1", option: langs.getText("common","opt_on")}], message: "", cont: 0}, {label: ""}]};
} else {
    var v_8 = {};
}

if(pgm_info.s001_9.auth) {
    var v_9 = {key: "pgms001_wkuptime", title: langs.getText("ps001","wkuptime"), tr:[{order: 1}, {label: langs.getText("ps001","wkuptime")}, {name: "WKUPTIME", value: "", textfield: [{max: 4, size: 6}], message: "", cont: 0}, {label: langs.getText("common","repeat")+" ", cont: 1}, {name: "WKUPRPT", value: "", chk_type: "chk_selectall", chk: 1, cont: 1}, {label: langs.getText("common","cmt_simpletime")}, {br: 1, cont: 1}, {label: langs.getText("ps001","cmt_time2"), cont: 1}]};
} else {
    var v_9 = {};
}

if(pgm_info.s001_10.auth) {
	if(!offline_mode) {
		if(info.ATD_ENABLE == "1") {
			var v_10 = {key: "pgms001_atdwkup", title: langs.getText("ps001","atdwkup"), tr:[{order: 1}, {label: langs.getText("ps001","atdwkup")}, {name: "ATDWKUPSSTN", value: "", textfield: [{max: 8, size: 6}], message: ""}, {label: " - ", cont: 1}, {name: "ATDWKUPESTN", value: "", textfield: [{max: 8, size: 6}], message: "", cont: 1}, {br: 1, cont: 1},  {name: "ATDWKUPTIME", value: "", textfield: [{max: 4, size: 6}], message: "", cont: 1}, {label: " "+langs.getText("common","repeat")+" ", cont: 1}, {name: "ATDWKUPRPT", value: "", chk_type: "chk_selectall", chk: 1, cont: 1}, {label: langs.getText("common","cmt_simpletime")}, {br: 1, cont: 1}, {label: langs.getText("ps001","cmt_time2"), cont: 1}]};
		} else {
			var v_10 = {};
		}
	} else {
		var v_10 = {};
	}
} else {
    var v_10 = {};
}

if(pgm_info.s001_11.auth) {
    var v_11 = {key: "pgms001_hdsspk", title: langs.getText("ps001","hdsspk"), tr:[{order: 1}, {label: langs.getText("ps001","hdsspk")}, {name: "HDSSPK", value: "", select: [{value: "0", option: langs.getText("common","hdset")}, {value: "1", option: langs.getText("common","speaker")}], message: "", cont: 0}, {label: ""}]};
} else {
    var v_11 = {};
}

if(pgm_info.s001_12.auth) {
    var v_12 = {key: "pgms001_hdsring", title: langs.getText("ps001","hdsring"), tr:[{order: 1}, {label: langs.getText("ps001","hdsring")}, {name: "HDSRING", value: "", select: [{value: "0", option: langs.getText("common","hdset")}, {value: "1", option: langs.getText("common","speaker")}], message: "", cont: 0}, {label: ""}]};
} else {
    var v_12 = {};
}

if(pgm_info.s001_13.auth) {
    var v_13 = {key: "pgms001_username", title: langs.getText("ps001","username"), tr:[{order: 1}, {label: langs.getText("ps001","username")}, {name: "USERNAME", value: "", textfield: [{max: 20}], message: "", enable_mullang: 1}, {label: langs.getText("common","max")}, {name: "MAXUSERNAME", value: "", label: 1, cont: 1}, {label: langs.getText("common","cmt_byte"), cont: 1}]};
} else {
    var v_13 = {};
}

if(pgm_info.s001_14.auth) {
    var v_14 = {key: "pgms001_bgm", title: langs.getText("ps001","bgm"), tr:[{order: 1}, {label: langs.getText("ps001","bgm")}, {name: "BGM", value: "", select: [{value: "0", option: langs.getText("common","no_bgm")}, {value: "1", option: langs.getText("common","intext_music")+" 1"}, {value: "2", option: langs.getText("common","extmusic")+" 2"}, {value: "3", option: langs.getText("common","vsf_moh")}, {value: "4", option: langs.getText("common","slt_moh")+"1"}, {value: "5", option: langs.getText("common","slt_moh")+"2"}, {value: "6", option: langs.getText("common","slt_moh")+"3"}, {value: "7", option: langs.getText("common","slt_moh")+"4"}, {value: "8", option: langs.getText("common","slt_moh")+"5"}, {value: "9", option: langs.getText("common","vsf_moh")+"2"}, {value: "10", option: langs.getText("common","vsf_moh")+"3"}], message: "", cont: 0}, {label: ""}]};
} else {
    var v_14 = {};
}

if(pgm_info.s001_15.auth) {
    var v_15 = {key: "pgms001_staring", title: langs.getText("ps001","staring"), tr:[{order: 1}, {label: langs.getText("ps001","staring")}, {name: "STARING", value: "", textfield: [{max: 2, size: 2}], message: "", cont: 0}, {label: "1 - "}, {name: "TOTSTARING", value: "", label: 1, cont: 1}]};
} else {
    var v_15 = {};
}

if(pgm_info.s001_16.auth) {
    var v_16 = {key: "pgms001_coring", title: langs.getText("ps001","coring"), tr:[{order: 1}, {label: langs.getText("ps001","coring")}, {name: "CORING", value: "", textfield: [{max: 2, size: 2}], message: "", cont: 0}, {label: "1 - "}, {name: "TOTCORING", value: "", label: 1, cont: 1}]};
} else {
    var v_16 = {};
}

if(pgm_info.s001_17.auth) {
    var v_17 = {key: "pgms001_umsmailsv", title: langs.getText("common","umsmailsv"), tr:[{order: 1}, {label: langs.getText("common","umsmailsv")}, {name: "UMSMAILSV", value: "", textfield: [{max: 64, size: 40}], message: "", cont: 0}, {label: langs.getText("common","max64ch")}]};
} else {
    var v_17 = {};
}

if(pgm_info.s001_18.auth) {
    if(info.PHASE >= 2.2) {
        var v_18 = {key: "pgms001_umsmailaddr", title: langs.getText("ps001","umsmailaddr"), tr:[{order: 1}, {label: langs.getText("ps001","umsmailaddr")}, {name: "UMSMAILADDR", value: "", textfield: [{max: 64, size: 40}], message: "", cont: 0}, {label: langs.getText("common","max64ch")}]};
    } else {
        var v_18 = {key: "pgms001_umsmailaddr", title: langs.getText("ps001","umsmailaddr"), tr:[{order: 1}, {label: langs.getText("ps001","umsmailaddr")}, {name: "UMSMAILADDR", value: "", textfield: [{max: 44}], message: "", cont: 0}, {label: ""}]};    
    }	
} else {
    var v_18 = {};
}

if(pgm_info.s001_19.auth) {
    var v_19 = {key: "pgms001_preftimer", title: langs.getText("common","preftimer"), tr:[{order: 1}, {label: langs.getText("common","preftimer")}, {name: "PREFTIMER", value: "", textfield: [{max: 3}], message: "", cont: 0}, {label: "000-600 ("+langs.getText("common","cmt_second")+")"}]};
} else {
    var v_19 = {};
}

if(pgm_info.s001_20.auth) {
    var v_20 = {key: "pgms001_isdnclir", title: langs.getText("common","isdnclir"), tr:[{order: 1}, {label: langs.getText("common","isdnclir")}, {name: "ISDNCLIR", value: "", select: [{value: "0", option: langs.getText("common","opt_off")}, {value: "1", option: langs.getText("common","opt_on")}], message: "", cont: 0}, {label: ""}]};
} else {
    var v_20 = {};
}

if(pgm_info.s001_21.auth) {
    var v_21 = {key: "pgms001_forcedfwd", title: langs.getText("ps001","forcedfwd"), tr:[{order: 1}, {label: langs.getText("ps001","forcedfwd")}, {name: "FORCEDFWDHUNT", value: "", textfield: [{max: 5, size: 5}], message: "", cont: 1}, {name: "FORCEDFWDACT", value: "", select: [{value: "0", option: langs.getText("common","no_action")}, {value: "1", option: langs.getText("ps001","opt_forcedfwd_fwd")}], message: "", cont: 0}, {name: "CMT_FORCEDFWDHUNT", value: "", label: 1}]};
} else {
    var v_21 = {};
}

if(pgm_info.s001_22.auth) {
    var v_22 = {key: "pgms001_acdduty", title: langs.getText("ps001","acdduty"), tr:[{order: 1}, {label: langs.getText("ps001","acdduty")}, {name: "ACDDUTYHUNT", value: "", textfield: [{max: 5, size: 5}], message: "", cont: 1}, {name: "ACDDUTYACT", value: "", select: [{value: "0", option: langs.getText("common","no_action")}, {value: "1", option: langs.getText("ps001","opt_acdduty_login")}, {value: "2", option: langs.getText("ps001","opt_acdduty_logout")}], message: "", cont: 0}, {br: 1, cont: 1}, {label: langs.getText("ps001","agent_off")+" ", cont: 1}, {name: "ACDDUTYREASON", value:"", textfield:[{max: 1, size: 1}], message: "", cont: 1}, {label: ""}]};
} else {
    var v_22 = {};
}

if(pgm_info.s001_23.auth) {
    var v_23 = {key: "pgms001_lcdlancode", title: langs.getText("ps001","lcdlancode"), tr:[{order: 1}, {label: langs.getText("ps001","lcdlancode")}, {name: "LCDLANCODE", value: "", select:g_lang_list, message: "", cont: 0}, {label: ""}]};
} else {
    var v_23 = {};
}

if(pgm_info.s001_24.auth) {
    var v_24 = {key: "pgms001_backlight", title: langs.getText("ps001","backlight"), tr:[{order: 1}, {label: langs.getText("ps001","backlight")}, {name: "BACKLIGHT", value: "", select: [{value: "0", option: langs.getText("ps001","opt_backlight_off")}, {value: "1", option: langs.getText("common","opt_busyonly")}, {value: "2", option: langs.getText("common","opt_backlight_alwayson")}], message: "", cont: 0}, {label: ""}]};
} else {
    var v_24 = {};
}

if(pgm_info.s001_25.auth) {
    var v_25 = {key: "pgms001_vmmsgno", title: langs.getText("common","vm_msg_num"), tr:[{order: 1}, {label: langs.getText("common","vm_msg_num")}, {name: "MSGTOT", value: "", label: 1}, {label: " (", cont: 1}, {label: langs.getText("common","simple_newmsg")+": ", cont: 1}, {name: "MSGNEW", value: "", label: 1, cont: 1}, {label: ", "+langs.getText("common","savedmsg")+": ", cont: 1}, {name: "MSGSAVED", value: "", label: 1, cont: 1}, {label: ", "+langs.getText("common","urgentmsg")+": ", cont: 1}, {name: "MSGURGENT", value: "", label: 1, cont: 1}, {label: ")", cont: 1}, {label: ""}]};
} else {
    var v_25 = {};
}

if(pgm_info.s001_26.auth) {
    var v_26 = {key: "pgms001_anncmailbox", title: langs.getText("common","anncmailbox"), tr:[{order: 1}, {label: langs.getText("common","anncmailbox")}, {name: "ANNCMAILBOX", value: "", select: [{value: "0", option: langs.getText("common","opt_disable")}, {value: "1", option: langs.getText("common","opt_enable")}], message: "", cont: 0}, {label: ""}]};
} else {
    var v_26 = {};
}

if(pgm_info.s001_27.auth) {
    var v_27 = {key: "pgms001_anncoption", title: langs.getText("common","anncoption"), tr:[{order: 1}, {label: langs.getText("common","anncoption")}, {name: "ANNCOPTION", value: "", select: [{value: "0", option: langs.getText("common","prev_menu")}, {value: "1", option: langs.getText("common","hang_up")}], message: "", cont: 0}, {label: ""}]};
} else {
    var v_27 = {};
}

if(pgm_info.s001_28.auth) {
    var v_28 = {key: "pgms001_comfirstname", title: langs.getText("common","comfirstname"), tr:[{order: 1}, {label: langs.getText("common","comfirstname")}, {name: "COMFIRSTNAME", value: "", textfield: [{max: 12, size: 30}], message: "", cont: 0}, {label: ""}]};
} else {
    var v_28 = {};
}

if(pgm_info.s001_29.auth) {
    var v_29 = {key: "pgms001_comlastname", title: langs.getText("common","comlastname"), tr:[{order: 1}, {label: langs.getText("common","comlastname")}, {name: "COMLASTNAME", value: "", textfield: [{max: 12, size: 30}], message: "", cont: 0}, {label: ""}]};
} else {
    var v_29 = {};
}

if(pgm_info.s001_30.auth) {
    var v_30 = {key: "pgms001_casmailbox",  title: langs.getText("common","casmailbox")+" 1", tr:[{order: 1}, {label: langs.getText("common","casmailbox")+" 1"}, {name: "CASMAILBOX", value: "", textfield: [{max: 8, size: 30}], message: "", cont: 0}, {label: ""}]};
    var v_33 = {key: "pgms001_casmailbox2", title: langs.getText("common","casmailbox")+" 2", tr:[{order: 1}, {label: langs.getText("common","casmailbox")+" 2"}, {name: "CASMAILBOX2", value: "", textfield: [{max: 8, size: 30}], message: "", cont: 0}, {label: ""}]};
    var v_34 = {key: "pgms001_casmailbox3", title: langs.getText("common","casmailbox")+" 3", tr:[{order: 1}, {label: langs.getText("common","casmailbox")+" 3"}, {name: "CASMAILBOX3", value: "", textfield: [{max: 8, size: 30}], message: "", cont: 0}, {label: ""}]};
    var v_35 = {key: "pgms001_casmailbox4", title: langs.getText("common","casmailbox")+" 4", tr:[{order: 1}, {label: langs.getText("common","casmailbox")+" 4"}, {name: "CASMAILBOX4", value: "", textfield: [{max: 8, size: 30}], message: "", cont: 0}, {label: ""}]};
    var v_36 = {key: "pgms001_casmailbox5", title: langs.getText("common","casmailbox")+" 5", tr:[{order: 1}, {label: langs.getText("common","casmailbox")+" 5"}, {name: "CASMAILBOX5", value: "", textfield: [{max: 8, size: 30}], message: "", cont: 0}, {label: ""}]};
} else {
    var v_30 = {};
	var v_33 = {};
	var v_34 = {};
	var v_35 = {};
	var v_36 = {};
}

if(pgm_info.s001_31.auth) {
    var v_31 = {key: "pgms001_casmethod", title: langs.getText("p127","casmethod"), tr:[{order: 1}, {label: langs.getText("p127","casmethod")}, {name:"CASMETHOD", value:"", select:[{value: "0", option: langs.getText("p127","opt_casmethod_disable")}, {value: "1", option: langs.getText("p127","opt_casmethod_copy")}, {value: "2", option: langs.getText("p127","opt_casmethod_move")}], message: "", cont: 0}, {label: ""}]};
    var v_37 = {key: "pgms001_casmsgtype", title: langs.getText("p127","casmsgtype"), tr:[{order: 1}, {label: langs.getText("p127","casmsgtype")}, {name:"CASMSGTYPE", value:"", select:[{value: "0", option: langs.getText("p127","opt_casmsgtype_normal")}, {value: "1", option: langs.getText("p127","opt_casmsgtype_urgent")}, {value: "2", option: langs.getText("p127","opt_casmsgtype_all")}], message: "", cont: 0}, {label: ""}]};
    var v_39 = {key: "pgms001_casapplytimer", title: langs.getText("p127","casapplytimer"), tr:[{order: 1}, {label: langs.getText("p127","casapplytimer")}, {name:"CASAPPLYTIMER", value:"", textfield: [{max: 3, size: 10}], message: "", cont: 0}, {label: "0-250 ("+langs.getText("common","cmt_minute")+")"}]};

    if(info.PHASE >= 3.1) {
		var v_40 = {key: "pgms001_casreadmsg", title: langs.getText("p127","casreadmsg"), tr:[{order: 1}, {label: langs.getText("p127","casreadmsg")}, {name: "CASREADMSG", value: "", select: [{value: "0", option: langs.getText("common","opt_disable")}, {value: "1", option: langs.getText("common","opt_enable")}], message: "", cont: 0}, {label: ""}]};
    } else {
		var v_40 = {};
	}
} else {
    var v_31 = {};
	var v_37 = {};
	var v_39 = {};
	var v_40 = {};
}

if(pgm_info.s001_32.auth) {
    var v_32 = {key: "pgms001_rwfftime", title: langs.getText("common","rwfftime"), tr:[{order: 1}, {label: langs.getText("common","rwfftime")}, {name: "RWFFTIME", value: "", textfield: [{max: 2, size: 10}], message: "", cont: 0}, {label: "(3-99 "+langs.getText("common","cmt_second")+")"}]};
} else {
    var v_32 = {};
}

define(
    {elements:[
        {name:"tab1", tab: [
            {key: "pgms001_button", button: [{btn: langs.getText("common","btn_save"), btn_type: "btn_save auth_write"}]},
            {key: "pgms001_mktbl", title: langs.getText("common","mktbl"), table: [{label: langs.getText("common","order"), sort: "num"}, {label: langs.getText("common","attr"), sort: "str"}, {label: langs.getText("common","val")}, {label: langs.getText("common","range")}]},
			v_1,
			v_2,
			v_3,
            v_4,
		    v_5,
            v_6,
		    v_7,
			v_8,
            v_9,
            v_10,
		    v_11,
		    v_12,
            v_13,
			v_14,
            v_15,
            v_16,
            v_17,
            v_18,
            v_19,
			v_20,
            v_21,
            v_22,
            v_23,
			v_24,
		    v_25,
            v_26,
			v_27,
			v_28,
            v_29,
            v_30,
            v_33,
            v_34,
            v_35,
            v_36,
            v_31,
            v_37,
            v_39,
			v_40,
			v_32
		]}
	]}
);
