public string getInterviewResultForCrew(string crewid) { BLL_Crew_CrewDetails objCrewBLL = new BLL_Crew_CrewDetails(); int CrewID = 0; if (crewid != "" && crewid != "undefined") { CrewID = int.Parse(crewid); } SqlDataReader dr = objCrewBLL.Get_InterviewResultsForCrew(CrewID); SqlDataReader dr2 = objCrewBLL.Get_InterviewResultsForCrew(CrewID); string ResultTable = GetJsArray(dr); while (dr2.Read()) { int InterviewID = int.Parse(dr2["ID"].ToString()); SqlDataReader drRes = objCrewBLL.Get_UserAnswers(CrewID, InterviewID); DataSet ds = objCrewBLL.Get_InterviewerRecomendations(CrewID, InterviewID); string AnswarTable = GetJsArray(drRes); string RecomendedVessels = GetJsArray(ds.Tables[0]); string RecomendedZones = GetJsArray(ds.Tables[1]); if (AnswarTable != "") { AnswarTable = "[" + AnswarTable + "]"; } else { AnswarTable = "''"; } if (RecomendedVessels != "") { RecomendedVessels = "[" + RecomendedVessels + "]"; } else { RecomendedVessels = "''"; } if (RecomendedZones != "") { RecomendedZones = "[" + RecomendedZones + "]"; } else { RecomendedZones = "''"; } ResultTable = ResultTable.Replace("'" + "UserAnswerTable" + InterviewID + "'", AnswarTable); ResultTable = ResultTable.Replace("'" + "RecomendedVessels" + InterviewID + "'", RecomendedVessels); ResultTable = ResultTable.Replace("'" + "RecomendedZones" + InterviewID + "'", RecomendedZones); } return(ResultTable); }
public string getPlannedInterviewForTheMonth(string userid, string crewid, string m, string y, string showcalforall) { BLL_Crew_CrewDetails objCrewBLL = new BLL_Crew_CrewDetails(); int Month = 1; int Year = 1900; int UserID = 0; int CrewID = 0; int ShowCalForAll = 0; if (m != "" && m != "undefined") { Month = int.Parse(m); } if (y != "" && y != "undefined") { Year = int.Parse(y); } if (userid != "" && userid != "undefined") { UserID = int.Parse(userid); } if (crewid != "" && crewid != "undefined") { CrewID = int.Parse(crewid); } if (showcalforall != "" && showcalforall != "undefined") { ShowCalForAll = int.Parse(showcalforall); } SqlDataReader dr = objCrewBLL.Get_PlannedInterviewesForTheMonth(UserID, CrewID, Month, Year, ShowCalForAll); return(GetJsArray(dr)); }
protected void Page_Load(object sender, EventArgs e) { if (!IsPostBack) { btnSendPO.Attributes.Add("onclick", "Async_Get_Reqsn_Validity('" + Request.QueryString["Requisitioncode"] + "');return Validation();"); //Session["VESSELCODE"] = Request.QueryString["Vessel_Code"].ToString(); //Session["DOCCODE"] = Request.QueryString["Document_Code"].ToString(); TypeOpen = Request.QueryString["Type"].ToString(); BindGrid(); BindRequisitionInfo(); divApprove.Visible = false; divpurcomment.Visible = false; BLL_PURC_Purchase objport = new BLL_PURC_Purchase(); DDLPort.DataSource = objport.getDeliveryPort(); DDLPort.DataBind(); DDLPort.Items.Insert(0, new ListItem("SELECT", "0")); BLL_Crew_CrewDetails objCrew = new BLL_Crew_CrewDetails(); gvPortCalls.DataSource = objCrew.Get_PortCall_List(Convert.ToInt32(Request.QueryString["Vessel_Code"].ToString())); gvPortCalls.DataBind(); DataTable dt = objport.SelectSupplier(); dt.DefaultView.RowFilter = "SUPPLIER_CATEGORY='A'"; ddlSentFrom.DataTextField = "SUPPLIER_NAME"; ddlSentFrom.DataValueField = "SUPPLIER"; ddlSentFrom.DataSource = dt.DefaultView.ToTable(); ddlSentFrom.DataBind(); ddlSentFrom.Items.Insert(0, new ListItem("SELECT", "0")); } //hlinkViewEval.NavigateUrl = "Quotation_Evaluation_Report.aspx?Requisitioncode=" + Request.QueryString["Requisitioncode"].ToString() + "&Document_Code=" + Request.QueryString["Document_Code"].ToString() + "&Vessel_Code=" + Request.QueryString["Vessel_Code"]; hlinkViewEval.NavigateUrl = "QuotationEvalRpt.aspx?Requisitioncode=" + Request.QueryString["Requisitioncode"].ToString() + "&Document_Code=" + Request.QueryString["Document_Code"].ToString() + "&Vessel_Code=" + Request.QueryString["Vessel_Code"]; }
protected void Load_Crew_Medical_History() { int FleetCode = 0; int Vessel_ID = 0; int CrewID = UDFLib.ConvertToInteger(Request.QueryString["CrewID"]); int Case_Type = 0; int Status = 1; int PAGE_SIZE = 1000; int PAGE_INDEX = 1; int SelectRecordCount = 0; string SortBy = (ViewState["SORTBY"] == null) ? null : (ViewState["SORTBY"].ToString()); int? SortDirection = null; if (ViewState["SORTDIRECTION"] != null) { SortDirection = Int32.Parse(ViewState["SORTDIRECTION"].ToString()); } DataTable dt = BLL_Crew_MedHistory.Get_Crew_MedHistory(FleetCode, Vessel_ID, CrewID, Case_Type, Status, null, GetSessionUserID(), PAGE_SIZE, PAGE_INDEX, ref SelectRecordCount, SortBy, SortDirection); GridView_MedicalHistory.DataSource = dt; GridView_MedicalHistory.DataBind(); BLL_Crew_CrewDetails objCrew = new BLL_Crew_CrewDetails(); DataTable dst = objCrew.Get_CrewPersonalDetailsByID(CrewID); if (dst.Rows[0]["Staff_Code"].ToString().Trim().Length == 0) { imgAdd_MedHistory.Visible = false; } }
protected void btnSave_Click(object sender, EventArgs e) { try { BLL_Crew_CrewDetails objCrewBLL = new BLL_Crew_CrewDetails(); objCrewBLL.UPDATE_CrewJoiningChecklist(int.Parse(getQueryString("CrewID")), 1, int.Parse(rdoQ1.SelectedValue), txtRemark1.Text, GetSessionUserID()); objCrewBLL.UPDATE_CrewJoiningChecklist(int.Parse(getQueryString("CrewID")), 2, int.Parse(rdoQ2.SelectedValue), txtRemark2.Text, GetSessionUserID()); objCrewBLL.UPDATE_CrewJoiningChecklist(int.Parse(getQueryString("CrewID")), 3, int.Parse(rdoQ3.SelectedValue), txtRemark3.Text, GetSessionUserID()); objCrewBLL.UPDATE_CrewJoiningChecklist(int.Parse(getQueryString("CrewID")), 4, int.Parse(rdoQ4.SelectedValue), txtRemark4.Text, GetSessionUserID()); objCrewBLL.UPDATE_CrewJoiningChecklist(int.Parse(getQueryString("CrewID")), 5, int.Parse(rdoQ5.SelectedValue), txtRemark5.Text, GetSessionUserID()); objCrewBLL.UPDATE_CrewJoiningChecklist(int.Parse(getQueryString("CrewID")), 6, int.Parse(rdoQ6.SelectedValue), txtRemark6.Text, GetSessionUserID()); objCrewBLL.UPDATE_CrewJoiningChecklist(int.Parse(getQueryString("CrewID")), 7, int.Parse(rdoQ7.SelectedValue), txtRemark7.Text, GetSessionUserID()); objCrewBLL.UPDATE_CrewJoiningChecklist(int.Parse(getQueryString("CrewID")), 8, int.Parse(rdoQ8.SelectedValue), txtRemark8.Text, GetSessionUserID()); objCrewBLL.UPDATE_CrewJoiningChecklist(int.Parse(getQueryString("CrewID")), 9, int.Parse(rdoQ9.SelectedValue), txtRemark9.Text, GetSessionUserID()); objCrewBLL.UPDATE_CrewJoiningChecklist(int.Parse(getQueryString("CrewID")), 10, int.Parse(rdoQ10.SelectedValue), txtRemark10.Text, GetSessionUserID()); objCrewBLL.UPDATE_CrewJoiningChecklist(int.Parse(getQueryString("CrewID")), 11, int.Parse(rdoQ11.SelectedValue), txtRemark11.Text, GetSessionUserID()); objCrewBLL.UPDATE_CrewJoiningChecklist(int.Parse(getQueryString("CrewID")), 12, int.Parse(rdoQ12.SelectedValue), txtRemark12.Text, GetSessionUserID()); objCrewBLL.UPDATE_CrewJoiningChecklist(int.Parse(getQueryString("CrewID")), 13, int.Parse(rdoQ13.SelectedValue), txtRemark13.Text, GetSessionUserID()); string js = "alert('Checklist saved successfully');"; ScriptManager.RegisterStartupScript(this, this.GetType(), "alertUser", js, true); } catch (Exception ex) { string js = "alert('Error in saving checklist. Error: " + ex.Message.Replace("'", "") + "');"; ScriptManager.RegisterStartupScript(this, this.GetType(), "alertUser", js, true); } }
public void BindPortCalls(int Vessel_ID) { BLL_Crew_CrewDetails objCrew = new BLL_Crew_CrewDetails(); gvPortCalls.DataSource = objCrew.Get_PortCall_List(Vessel_ID); gvPortCalls.DataBind(); }
protected void Page_Load(object sender, EventArgs e) { DataTable dtReports = BLL_OPS_VoyageReports.Get_Telegram_ToMail(); WebClient myClient = new WebClient(); BLL_Crew_CrewDetails objMail = new BLL_Crew_CrewDetails(); string MailHeader = ""; foreach (DataRow dr in dtReports.Rows) { string ReportPageHTML = null; byte[] requestHTML; string currentPageUrl = Request.Url.ToString(); UTF8Encoding utf8 = new UTF8Encoding(); MailHeader = dr["Vessel_Name"].ToString() + " / " + DateTime.Now.ToString("yy") + DateTime.Now.ToString("MM") + DateTime.Now.ToString("dd") + " / "; if (dr["Telegram_Type"].ToString().ToUpper() == "N") { currentPageUrl = "http://" + HttpContext.Current.Request.Url.Host + HttpContext.Current.Request.ApplicationPath + "/Operations/NoonReport.aspx?id=" + dr["PKID"].ToString(); MailHeader += "NOON"; } else if (dr["Telegram_Type"].ToString().ToUpper() == "D") { currentPageUrl = "http://" + HttpContext.Current.Request.Url.Host + HttpContext.Current.Request.ApplicationPath + "/Operations/DepartureReport.aspx?id=" + dr["PKID"].ToString(); MailHeader += "DEPARTURE"; } else if (dr["Telegram_Type"].ToString().ToUpper() == "A") { currentPageUrl = "http://" + HttpContext.Current.Request.Url.Host + HttpContext.Current.Request.ApplicationPath + "/Operations/ArrivalReport.aspx?id=" + dr["PKID"].ToString(); MailHeader += "ARRIVAL"; } requestHTML = myClient.DownloadData(currentPageUrl); ReportPageHTML = utf8.GetString(requestHTML); if (dr["Telegram_Type"].ToString().ToUpper() == "N") { #region Noon report ReportPageHTML = ReportPageHTML.Replace("class='leafTD-data-left'", "style='width: 140px; height: 20px; padding: 0px 0px 0px 2px; background-color: #cce499;text-align: center;'"); ReportPageHTML = ReportPageHTML.Replace("class='leafTD-data'", "style='width: 140px; height: 20px; padding: 0px 0px 0px 0px; background-color: #cce499;text-align: left;'"); ReportPageHTML = ReportPageHTML.Replace("class='leafTD-header-midsec'", "style=' width: 170px;height: 20px;padding: 0px 0px 0px 0px;text-align: left;'"); ReportPageHTML = ReportPageHTML.Replace("class='leafTD-header'", "style=' width: 120px; height: 20px; padding: 0px 0px 0px 0px;text-align: left;'"); ReportPageHTML = ReportPageHTML.Replace("class='leafTD-data-midsec'", "style='width: 115px; height: 20px; padding: 0px 0px 0px 0px; background-color: #cce499;text-align: right;'"); ReportPageHTML = ReportPageHTML.Replace("class='leafTD-data-consmp'", "style='width: 120px;height: 20px;padding: 0px 0px 0px 0px; background-color: #cce499;text-align: right;border-right: solid 1px white; white-space: normal; line-height: normal;letter-spacing: normal;'"); ReportPageHTML = ReportPageHTML.Replace("class='leafTR'", "style=' border-bottom-style: solid;border-bottom-color: White;border-bottom-width: 1px;'"); #endregion noon report } else { #region Departure Report ReportPageHTML = ReportPageHTML.Replace("class='leafTR'", "style='border-bottom-style: solid; border-bottom-color: White; border-bottom-width: 1px;'"); ReportPageHTML = ReportPageHTML.Replace("class='leafTD-header'", "style='width: 80px;height: 10px; padding: 0px 0px 0px 10px;text-align: left;'"); ReportPageHTML = ReportPageHTML.Replace("class='leafTD-data'", "style='width: 100px;height: 10px; padding: 0px 0px 0px 0px;background-color: #cce499;text-align: left;'"); #endregion } string[] strArray = ReportPageHTML.Split(new string[] { "<div" }, StringSplitOptions.None); ReportPageHTML = "<div " + strArray[8] + "<div> <div " + strArray[9]; } }
protected void Page_Load(object sender, EventArgs e) { BLL_Crew_CrewDetails objCrew = new BLL_Crew_CrewDetails(); DataTable dt = objCrew.Get_CrewCardIndex(0, 0, 0, 0, "", Convert.ToInt32(Session["userid"])); GridView1.DataSource = dt; GridView1.DataBind(); }
public void SaveCrewCard_Attachment(int CardID, int AttachmentType, string AttachmentName, string AttachmentPath, int Created_By) { try { BLL_Crew_CrewDetails objBLLCrew = new BLL_Crew_CrewDetails(); objBLLCrew.INS_CrewCard_Attachment(CardID, AttachmentType, AttachmentName, AttachmentPath, Created_By); } catch { } }
public void SaveCrewFeedback(int CrewID, string FeedBack, string AttachmentName, int CreatedBy) { try { BLL_Crew_CrewDetails objBLLCrew = new BLL_Crew_CrewDetails(); objBLLCrew.INS_CrewRemarks(CrewID, FeedBack, AttachmentName, CreatedBy); } catch { } }
public void Load_CountryList() { BLL_Crew_CrewDetails objCrew = new BLL_Crew_CrewDetails(); ddlCountry.DataSource = objCrew.Get_CrewNationality(GetSessionUserID()); ddlCountry.DataTextField = "COUNTRY"; ddlCountry.DataValueField = "ID"; ddlCountry.DataBind(); ddlCountry.Items.Insert(0, new ListItem("-SELECT ALL-", "0")); ddlCountry.SelectedIndex = 0; }
protected void Load_ManningAgent() { BLL_Crew_CrewDetails objBLLCrew = new BLL_Crew_CrewDetails(); int UserCompanyID = UDFLib.ConvertToInteger(Session["USERCOMPANYID"].ToString()); DataTable dt = objBLLCrew.Get_ManningAgentList(UserCompanyID); ddlManningAgent.DataSource = dt; ddlManningAgent.DataTextField = "COMPANY_NAME"; ddlManningAgent.DataValueField = "ID"; ddlManningAgent.DataBind(); ddlManningAgent.Items.Insert(0, new ListItem("-SELECT ALL-", "0")); }
protected void Page_Load(object sender, EventArgs e) { if (!IsPostBack) { lblheader.Text = "Raise PO for Logistic ID : " + Request.QueryString["LOG_ID"]; DataTable dtPoList = BLL_PURC_LOG.Get_Log_POList_Raise(Convert.ToInt32(Request.QueryString["LOG_ID"])); gvLPOList.DataSource = dtPoList; gvLPOList.DataBind(); btnSendOrder.Visible = true; dvRaiselPo.Visible = false; BLL_PURC_Purchase objport = new BLL_PURC_Purchase(); DDLPort.DataSource = objport.getDeliveryPort(); DDLPort.DataBind(); BLL_Crew_CrewDetails objCrew = new BLL_Crew_CrewDetails(); //DataSource = objCrew.Get_PortCall_List(Convert.ToInt32(Request.QueryString["Vessel_Code"].ToString())); //gvPortCalls.DataBind(); DataTable dt = objport.SelectSupplier(); dt.DefaultView.RowFilter = "SUPPLIER_CATEGORY='A'"; ddlSentFrom.DataTextField = "SUPPLIER_NAME"; ddlSentFrom.DataValueField = "SUPPLIER"; ddlSentFrom.DataSource = dt.DefaultView.ToTable(); ddlSentFrom.DataBind(); ddlSentFrom.Items.Insert(0, new ListItem("SELECT", "0")); ListItem liDDl = new ListItem(); liDDl = DDLPort.Items.FindByValue(dtPoList.Rows[0]["port"].ToString()); if (liDDl != null) { liDDl.Selected = true; } liDDl = ddlSentFrom.Items.FindByValue(dtPoList.Rows[0]["Agent"].ToString()); if (liDDl != null) { liDDl.Selected = true; if (Convert.ToString(dtPoList.Rows[0]["Agent"]) != "0") { DataTable dtAgentsDtls = BLL_PURC_Common.Get_SupplierDetails_ByCode(dtPoList.Rows[0]["Agent"].ToString()); if (dtAgentsDtls.Rows.Count > 0) { txtagent.Text = dtAgentsDtls.Rows[0]["fullname"].ToString(); txtagent.Text += "\r\n" + dtAgentsDtls.Rows[0]["address"].ToString(); txtagent.Text += "\r\n" + dtAgentsDtls.Rows[0]["phone"].ToString(); txtagent.Text += "\r\n" + dtAgentsDtls.Rows[0]["email"].ToString(); } } } } }
public DataTable Get_AirportList(string searchtext) { try { BLL_Crew_CrewDetails objCrew = new BLL_Crew_CrewDetails(); return(objCrew.Get_AirportList(searchtext)); } catch (Exception ex) { CustomSoapException(ex.GetType().Name, ex.Message); return(null); } }
public string GetVesselPortCall(int Vessel_ID) { BLL_Crew_CrewDetails objCrew = new BLL_Crew_CrewDetails(); DataTable dt; StringBuilder sTable = new StringBuilder(); try { dt = objCrew.Get_PortCall_List(Vessel_ID); return(UDFLib.CreateHtmlTableFromDataTable(dt, new string[] { "Port Name", "Arrival", "Departure", "Owners Agent", "Charterers Agent" }, new string[] { "Port_Name", "Arrival", "Departure", "Owners_Agent", "Charterers_Agent" }, "Vessel Port Call")); } catch { throw; } finally { dt = null; } }
public void Load_ReportData() { BLL_Crew_CrewDetails objCrew = new BLL_Crew_CrewDetails(); int vessel_manager = 1; int UserID = UDFLib.ConvertToInteger(Session["USERID"].ToString()); int MOID = Request.QueryString["MOID"] == null ? 0 : UDFLib.ConvertToInteger(Request.QueryString["MOID"].ToString()); string COL = Request.QueryString["C"] == null?"":Request.QueryString["C"].ToString(); DataSet ds = objCrew.Get_MissingDataDetails(vessel_manager, UserID, MOID, COL); GridView4.DataSource = ds.Tables[0]; GridView4.DataBind(); }
public string Get_Seniority_Log(int CrewID, int VoyageID, int UserID) { BLL_Crew_CrewDetails objCrewBLL = new BLL_Crew_CrewDetails(); DataTable dt = objCrewBLL.Get_Seniority_Log(CrewID, VoyageID, UserID); return(UDFLib.CreateHtmlTableFromDataTable(dt, new string[] { "Seniority Log" }, new string[] { "SeniorityLog" }, new string[] { }, "Seniority-Log-table", "Seniority-Log-DataHeder", "Seniority-Log-Data")); }
public string getPendingInterviewList_By_UserID(string userid) { BLL_Crew_CrewDetails objCrewBLL = new BLL_Crew_CrewDetails(); int UserID = 0; if (userid != "") { UserID = int.Parse(userid); } SqlDataReader dr = objCrewBLL.getPendingInterviewListt_By_UserID(UserID); return(GetJsArray(dr)); }
public string getInterviewsScheduledForToday(string userid) { BLL_Crew_CrewDetails objCrewBLL = new BLL_Crew_CrewDetails(); int UserID = 0; if (userid != "") { UserID = int.Parse(userid); } SqlDataReader dr = objCrewBLL.getInterviewsScheduledForToday(UserID); return(GetJsArray(dr)); }
protected void Get_CrewWorkflow(int CrewID) { try { DataSet ds = new BLL_Crew_CrewDetails().Get_CrewWorkflow(CrewID, GetSessionUserID()); ds.Relations.Add(new DataRelation("Parent", ds.Tables[0].Columns["ID"], ds.Tables[1].Columns["PID"])); ds.Tables[1].TableName = "Child"; rpt1.DataSource = ds; rpt1.DataBind(); } catch (Exception ex) { UDFLib.WriteExceptionLog(ex); } }
public void Load_ReportData() { BLL_Crew_CrewDetails objCrew = new BLL_Crew_CrewDetails(); int vessel_manager = 1; int UserID = UDFLib.ConvertToInteger(Session["USERID"].ToString()); DataSet ds = objCrew.Get_MissingDataReport(vessel_manager, UserID); GridView1.DataSource = ds.Tables[0]; GridView1.DataBind(); GridView2.DataSource = ds.Tables[1]; GridView2.DataBind(); GridView3.DataSource = ds.Tables[2]; GridView3.DataBind(); }
protected void Page_Load(object sender, EventArgs e) { UserAccessValidation(); if (Session["USERID"] == null) { Response.Redirect("~/account/login.aspx"); } if (!IsPostBack) { ViewState["PBMonth"] = "0"; ViewState["PBYear"] = "0"; ViewState["PBMonthPrev"] = "0"; ViewState["PBYearPrev"] = "0"; Load_FleetList(); Load_VesselList(); Load_Years(); Load_ManningAgent(); Load_BankNames(); BLL_Crew_CrewDetails objCrew = new BLL_Crew_CrewDetails(); ddlCountry.DataSource = objCrew.Get_CrewNationality(GetSessionUserID()); ddlCountry.DataTextField = "COUNTRY"; ddlCountry.DataValueField = "ID"; ddlCountry.DataBind(); ddlCountry.Items.Insert(0, new ListItem("-SELECT ALL-", "0")); ddlCountry.SelectedIndex = 0; string Month = DateTime.Today.Month.ToString(); string Year = DateTime.Today.Year.ToString(); try { ddlYear.Items.FindByValue(Year).Selected = true; ddlMonth.Items.FindByValue(Month).Selected = true; } catch { } Load_Allotments(); } //string msg1 = String.Format("$('.sailingInfo').SailingInfo();"); //ScriptManager.RegisterStartupScript(Page, Page.GetType(), "msgshowdetails", msg1, true); }
public string setCrewCard_AttachmentStatus(string cardid, string atttype, string status, string userid) { try { BLL_Crew_CrewDetails objCrewBLL = new BLL_Crew_CrewDetails(); int ret = objCrewBLL.UPDATE_CrewCard_AttachmentStatus(UDFLib.ConvertToInteger(cardid), atttype, UDFLib.ConvertToInteger(status), UDFLib.ConvertToInteger(userid)); return("1"); } catch { return("0"); } finally { } }
protected void Load_CrewPersonalDetails(int ID) { try { DataTable dt = new BLL_Crew_CrewDetails().Get_CrewPersonalDetailsByID(ID); if (dt.Rows.Count > 0) { lblStaffName.Text = dt.Rows[0]["STAFF_FULLNAME"].ToString(); lblStaffCode.Text = dt.Rows[0]["STAFF_CODE"].ToString(); lblRank.Text = dt.Rows[0]["RANK_NAME"].ToString(); hdnCrewrank.Value = dt.Rows[0]["CurrentRankID"].ToString(); } } catch (Exception ex) { UDFLib.WriteExceptionLog(ex); } }
public string getCrewTransferDetails(string crewid, string voyageid, string userid) { BLL_Crew_CrewDetails objCrewBLL = new BLL_Crew_CrewDetails(); DataTable dt = objCrewBLL.Get_Transfer_Promotions(UDFLib.ConvertToInteger(crewid), UDFLib.ConvertToInteger(voyageid), UDFLib.ConvertToInteger(userid)); UDFLib.ChangeColumnDataType(dt, "Effective_Date", typeof(string)); if (dt.Rows.Count > 0) { foreach (DataRow dr in dt.Rows) { if (!string.IsNullOrEmpty(dr["Effective_Date"].ToString())) { dr["Effective_Date"] = UDFLib.ConvertUserDateFormat(Convert.ToDateTime(dr["Effective_Date"].ToString()).ToString("dd/MM/yyyy"), UDFLib.GetDateFormat()); } } } return(UDFLib.CreateHtmlTableFromDataTable(dt, new string[] { "From Vessel", "Current Rank", "To Vessel", "Joining Rank", "Effective Date" }, new string[] { "FromVessel", "FromRank", "ToVessel", "ToRank", "Effective_Date" }, "Crew Transfer/Promotion Details")); }
protected void btnRqstUptResponse_Click(object sender, EventArgs e) { BLL_Crew_CrewDetails objBLLCrew = new BLL_Crew_CrewDetails(); BLL_Infra_UserCredentials ojbInfra = new BLL_Infra_UserCredentials(); string sToEmailAddress = "", strEmailAddCc = "", strFormatSubject = "Update response"; DataTable dtEmailAdd = BLL_SCM_Report.SCMReportGetEmailAddToSendMailForResponse(Convert.ToInt32(ddlYear.SelectedValue), Convert.ToInt32(ddlMonth.SelectedValue)); foreach (DataRow dr in dtEmailAdd.Rows) { sToEmailAddress += dr["EMAIL_ADD"].ToString() + ";"; } if (dtEmailAdd.Rows.Count > 0) { DataTable dtRequesterDetails = ojbInfra.Get_UserDetails(Convert.ToInt32(Session["userid"].ToString())); StringBuilder sbEmailbody = new StringBuilder(); string path = System.Configuration.ConfigurationManager.AppSettings["APP_URL"].ToString() + "/QMS/SCM/SCM_Response.aspx"; //string path = "http://seachange.dyndns.info/smslog/QMS/SCM/SCM_Response.aspx"; sbEmailbody.Append("Dear All,"); sbEmailbody.AppendLine("<br><br>"); sbEmailbody.AppendLine("Please click on below link to update the response."); sbEmailbody.Append("<a href=" + path + ">" + path + "</a>"); sbEmailbody.AppendLine("<br><br>"); sbEmailbody.AppendLine("<br>"); sbEmailbody.AppendLine("<br>"); sbEmailbody.AppendLine("Best Regards,"); sbEmailbody.AppendLine("<br>"); sbEmailbody.AppendLine(dtRequesterDetails.Rows[0]["User_name"].ToString().ToUpper() + " " + dtRequesterDetails.Rows[0]["Last_Name"].ToString().ToUpper()); sbEmailbody.AppendLine("<br>"); sbEmailbody.AppendLine(dtRequesterDetails.Rows[0]["Designation"].ToString()); sbEmailbody.AppendLine(Convert.ToString(Session["Company_Address_GL"])); sbEmailbody.AppendLine("<br>"); int MailID = objBLLCrew.Send_CrewNotification(0, 0, 0, 0, sToEmailAddress, strEmailAddCc, "", strFormatSubject, sbEmailbody.ToString(), "", "MAIL", "", UDFLib.ConvertToInteger(Session["USERID"].ToString()), "DRAFT"); string URL = String.Format("window.open('/" + System.Configuration.ConfigurationManager.AppSettings["APP_NAME"].ToString() + "/crew/EmailEditor.aspx?ID=+" + MailID.ToString() + "');"); ScriptManager.RegisterStartupScript(Page, Page.GetType(), "k" + MailID.ToString(), URL, true); } }
public string getContracts_ToVerify_Alerts(string userid, string DateFormat) { BLL_Crew_CrewDetails objCrewBLL = new BLL_Crew_CrewDetails(); int UserID = 0; if (userid != "") { UserID = int.Parse(userid); } DataTable dt = objCrewBLL.Get_Contracts_ToVerify_Alerts(UserID); foreach (DataRow row in dt.Rows) { row["CONTRACT_DATE"] = UDFLib.ConvertUserDateFormat(Convert.ToString(row["CONTRACT_DATE"]), DateFormat); } return(GetJsArray(dt)); }
public string getUSVisaAlerts(string userid, string DateFormat) { BLL_Crew_CrewDetails objCrewBLL = new BLL_Crew_CrewDetails(); int UserID = 0; if (userid != "") { UserID = int.Parse(userid); } DataTable dt = objCrewBLL.Get_USVisaAlerts(UserID); foreach (DataRow row in dt.Rows) { row["Us_Visa_Expiry"] = UDFLib.ConvertUserDateFormat(Convert.ToString(row["Us_Visa_Expiry"]), DateFormat); } return(GetJsArray(dt)); }
protected void Page_Load(object sender, EventArgs e) { BLL_Crew_CrewDetails objCrew = new BLL_Crew_CrewDetails(); int Vessel_ID = 1; if (Request.QueryString["vid"] != null) { Vessel_ID = UDFLib.ConvertToInteger(Request.QueryString["vid"].ToString()); } int SelectRecordCount = 1; DataTable dtFilters = new DataTable(); dtFilters.Columns.Add("VesselManager", typeof(int)); dtFilters.Columns.Add("Fleet", typeof(int)); dtFilters.Columns.Add("Vessel", typeof(int)); dtFilters.Columns.Add("RankID", typeof(int)); dtFilters.Columns.Add("Nationality", typeof(int)); dtFilters.Columns.Add("Status", typeof(String)); dtFilters.Columns.Add("ManningOfficeID", typeof(int)); dtFilters.Columns.Add("EOCDueIn", typeof(int)); dtFilters.Columns.Add("JoiningDateFrom", typeof(String)); dtFilters.Columns.Add("JoiningDateTo", typeof(String)); dtFilters.Columns.Add("SearchText", typeof(String)); DateTime dtFrom = DateTime.Parse("1900/01/01"); DateTime dtTo = DateTime.Parse("2900/01/01"); dtFilters.Rows.Add(1, 0, Vessel_ID, 0, 0, "CURRENT", 0, 0, dtFrom.ToString("yyyy/MM/dd"), dtTo.ToString("yyyy/MM/dd"), ""); DataTable dt = BLL_Crew_CrewList.Get_Crewlist_Index(dtFilters, GetSessionUserID(), 2000, 1, ref SelectRecordCount); //RepeaterRSS.DataSource = dt; //RepeaterRSS.DataBind(); GenerateRSS(dt); }
public string getCrewCardRemarks(string cardid, string userid) { BLL_Crew_CrewDetails objCrewBLL = new BLL_Crew_CrewDetails(); int UserID = 0; if (userid != "") { UserID = int.Parse(userid); } int CardID = 0; if (cardid != "") { CardID = int.Parse(cardid); } SqlDataReader dr = objCrewBLL.Get_CrewCard_Remarks(CardID, UserID); return(GetJsArray(dr)); }