/// <summary> /// AddNew : ตั้งค่าเอกสารแนบแก้ไขข้อมูลผู้สมัครสอบ /// </summary> /// <param name="sender"></param> /// <param name="e"></param> /// <EDITOR>Natta</EDITOR> /// <LASTUPDATE>09/08/2557</LASTUPDATE> protected void btnInsertApplicantDetail_Click(object sender, EventArgs e) { if (ddlApplicantDocumentType.SelectedIndex > 0 && ddlApplicantMemberType.SelectedIndex > 0) { BLL.DataCenterBiz biz = new BLL.DataCenterBiz(); DTO.ConfigDocument doc = new DTO.ConfigDocument(); //string funcID = DTO.DocFunction.APPLICANT_FUNCTION.GetEnumValue().ToString(); var detail = biz.GetConfigDocumentByDocumentCode(DTO.DocFunction.APPLICANT_FUNCTION.GetEnumValue().ToString(), ddlApplicantDocumentType.SelectedValue, ddlApplicantMemberType.SelectedValue); if (detail.DataResponse != null) { UCModalError.ShowMessageError = SysMessage.DupConfigSettingDocument; UCModalError.ShowModalError(); } else { doc.FUNCTION_ID = "64"; doc.MEMBER_CODE = ddlApplicantMemberType.SelectedValue; doc.DOCUMENT_CODE = ddlApplicantDocumentType.SelectedValue; doc.DOCUMENT_REQUIRE = "N"; doc.STATUS = "A"; var res = biz.InsertConfigDocument(doc, base.UserProfile); if (res.IsError) { UCModalError.ShowMessageError = res.ErrorMsg; UCModalError.ShowModalError(); } else { UCModalSuccess.ShowMessageSuccess = SysMessage.InsertSuccess; UCModalSuccess.ShowModalSuccess(); GetApplicantDetailtGrid(); //GetConfigDocumentGrid(); } } } else { UCModalError.ShowMessageError = SysMessage.PleaseInputFill; UCModalError.ShowModalError(); } }