예제 #1
0
    public string Get_StaffInfo(int StaffCode, string DateFormat = "dd/MM/yyyy")
    {
        DAL_Crew_CrewDetails objCrew = new DAL_Crew_CrewDetails();
        DataTable            dt      = new DataTable();

        string[] str_etr = { };

        dt = objCrew.Get_StaffInfo_DL(StaffCode);
        foreach (DataRow dr in dt.Rows)
        {
            if (dr["Value"].ToString().Contains("On"))
            {
                dr["Value"] = dr["Value"].ToString().Replace("On", "|");
                str_etr     = Convert.ToString(dr["Value"]).Split('|');
                if (str_etr.Length > 0)
                {
                    dr["Value"] = str_etr[0] + "On " + UDFLib.ConvertUserDateFormat(Convert.ToString(str_etr[1]), DateFormat);
                }
            }
        }

        return(UDFLib.CreateHtmlTableFromDataTable(dt,
                                                   new string[] { "", "" },
                                                   new string[] { "Caption", "Value" }, ""));
    }
예제 #2
0
    public string Get_StaffSailingInfo(int CrewID, int RankID)
    {
        DAL_Crew_CrewDetails objCrew = new DAL_Crew_CrewDetails();

        return(UDFLib.CreateHtmlTableFromDataTable(objCrew.Get_StaffSailingInfo_DL(CrewID, RankID, 0),
                                                   new string[] { "", "" },
                                                   new string[] { "Caption", "Value" }, ""));
    }
예제 #3
0
    public string asyncGet_Record_Info(int CrewId, string DocType, string DateFormat)
    {
        System.Text.StringBuilder info    = new System.Text.StringBuilder();
        DAL_Crew_CrewDetails      objCrew = new DAL_Crew_CrewDetails();
        DataTable dtinfo = objCrew.Get_Record_Info(CrewId, DocType);

        if (dtinfo.Rows.Count > 0)
        {
            info.Append("<div style='margin:5px;border-radius:5px'>");
            info.Append("<table cellpadding='3px' >");

            info.Append("<tr>");
            info.Append("<td style='font-weight:bold;font-size:12px;color:#092B4C;text-align:left'>");
            info.Append("Updated: ");
            info.Append("</td>");
            info.Append("<td >" + dtinfo.Rows[0]["IsAutoUpdate"]);
            info.Append("</td>");
            info.Append("<td style='width:50px'>");
            info.Append("&nbsp;");
            info.Append("</td>");
            info.Append("</tr>");

            if (dtinfo.Rows[0]["Modified_By"].ToString().Equals(""))
            {
                info.Append("<tr>");
                info.Append("<td style='font-weight:bold;font-size:12px;color:#092B4C;text-align:left'>");
                info.Append("Current Value: ");
                info.Append("</td>");
                info.Append("<td >" + dtinfo.Rows[0]["CurrentValue"]);
                info.Append("</td>");
                info.Append("<td style='width:50px'>");
                info.Append("&nbsp;");
                info.Append("</td>");
                info.Append("</tr>");

                info.Append("<tr>");
                info.Append("<td style='font-weight:bold;font-size:12px;color:#092B4C;text-align:left'>");
                info.Append("Created By: ");
                info.Append("</td>");
                info.Append("<td >" + dtinfo.Rows[0]["Created_By"]);
                info.Append("</td>");
                info.Append("<td style='width:50px'>");
                info.Append("&nbsp;");
                info.Append("</td>");
                info.Append("</tr>");

                info.Append("<tr>");
                info.Append("<td style='font-weight:bold;font-size:12px;color:#092B4C;text-align:left'>");
                info.Append("Created On: ");
                info.Append("</td>");
                info.Append("<td >" + UDFLib.ConvertUserDateFormat(Convert.ToString(dtinfo.Rows[0]["Date_Of_Creatation"]), DateFormat));
                info.Append("</td>");
                info.Append("<td style='width:50px'>");
                info.Append("&nbsp;");
                info.Append("</td>");
                info.Append("</tr>");
            }
            else
            {
                info.Append("<tr>");
                info.Append("<td style='font-weight:bold;font-size:12px;color:#092B4C;text-align:left'>");
                info.Append("Previous Value: ");
                info.Append("</td>");
                info.Append("<td >" + dtinfo.Rows[0]["PreviousValue"]);
                info.Append("</td>");
                info.Append("<td style='width:50px'>");
                info.Append("&nbsp;");
                info.Append("</td>");
                info.Append("</tr>");

                info.Append("<tr>");
                info.Append("<td style='font-weight:bold;font-size:12px;color:#092B4C;text-align:left'>");
                info.Append("Current Value: ");
                info.Append("</td>");
                info.Append("<td >" + dtinfo.Rows[0]["CurrentValue"]);
                info.Append("</td>");
                info.Append("<td style='width:50px'>");
                info.Append("&nbsp;");
                info.Append("</td>");
                info.Append("</tr>");

                info.Append("<tr>");
                info.Append("<td style='font-weight:bold;font-size:12px;color:#092B4C;text-align:left'>");
                info.Append("Modified By: ");
                info.Append("</td>");
                info.Append("<td >" + dtinfo.Rows[0]["Modified_By"]);
                info.Append("</td>");
                info.Append("<td style='width:50px'>");
                info.Append("&nbsp;");
                info.Append("</td>");
                info.Append("</tr>");

                info.Append("<tr>");
                info.Append("<td style='font-weight:bold;font-size:12px;color:#092B4C;text-align:left'>");
                info.Append("Modified On: ");
                info.Append("</td>");
                info.Append("<td >" + UDFLib.ConvertUserDateFormat(Convert.ToString(dtinfo.Rows[0]["Date_Of_Modification"]), DateFormat));
                info.Append("</td>");
                info.Append("<td style='width:50px'>");
                info.Append("&nbsp;");
                info.Append("</td>");
                info.Append("</tr>");
            }


            info.Append("</table>");
            info.Append("</div>");
        }


        return(info.ToString());
    }
예제 #4
0
    public string Get_RJBFormula(string Description)
    {
        DAL_Crew_CrewDetails objCrew = new DAL_Crew_CrewDetails();

        return(objCrew.Get_RJBFormula(Description));
    }
예제 #5
0
    public int CheckCrewSeniority(int CrewId)
    {
        DAL_Crew_CrewDetails objCrew = new DAL_Crew_CrewDetails();

        return(objCrew.CheckCrewSeniority(CrewId));
    }
예제 #6
0
    public int Del_CrewOtherServices(int CrewID, int ID, int Deleted_By)
    {
        DAL_Crew_CrewDetails objCrew = new DAL_Crew_CrewDetails();

        return(objCrew.Delete_CrewOtherServices_DL(ID, CrewID, Deleted_By));
    }
예제 #7
0
    public int Del_CrewEvaluation(int ID, int CrewId, int VoyageId, int Deleted_By)
    {
        DAL_Crew_CrewDetails objCrew = new DAL_Crew_CrewDetails();

        return(objCrew.DEL_CrewEvalaution_DL(ID, CrewId, VoyageId, Deleted_By));
    }
예제 #8
0
    public int Del_CrewVoyage(int VoyID, int Deleted_By)
    {
        DAL_Crew_CrewDetails objCrew = new DAL_Crew_CrewDetails();

        return(objCrew.DEL_CrewVoyages_DL(VoyID, Deleted_By));
    }
예제 #9
0
    public int Del_CrewDependent(int ID, int Deleted_By)
    {
        DAL_Crew_CrewDetails objCrew = new DAL_Crew_CrewDetails();

        return(objCrew.DEL_Crew_DependentDetails_DL(ID, Deleted_By));
    }