Example #1
0
        public static int VoyageLandingDateEntry(int vesselId, int voyageId, int Pod, DateTime?LandingDate, DateTime?OldLandingDate, int UserId)
        {
            string ProcName = "prcVoyageLandingDateEntry";

            DAL.DbManager.DbQuery dquery = new DAL.DbManager.DbQuery(ProcName);

            dquery.AddIntegerParam("@UserId", UserId);
            dquery.AddIntegerParam("@vesselId", vesselId);
            dquery.AddIntegerParam("@voyageId", voyageId);
            dquery.AddDateTimeParam("@LandingDate", LandingDate);
            dquery.AddDateTimeParam("@OldLandingDate", OldLandingDate);
            dquery.AddIntegerParam("@Pod", Pod);

            return(dquery.RunActionQuery());
        }
Example #2
0
        public static DateTime TranshipmentStatus(int ExpBLId, ref bool VoyageStatus, ref int CountID)
        {
            DateTime Result;
            string   TempString;
            bool     ClsVoyage = false;
            int      Count     = 0;
            string   ProcName  = "[exp].[prcTranshipmentStatus]";

            DAL.DbManager.DbQuery dquery = new DAL.DbManager.DbQuery(ProcName);

            dquery.AddIntegerParam("@ExpBLId", ExpBLId);
            dquery.AddDateTimeParam("@RESULT", null, QueryParameterDirection.Output);
            dquery.AddBooleanParam("@closeVoyage", ClsVoyage, QueryParameterDirection.Output);
            dquery.AddIntegerParam("@CountID", Count, QueryParameterDirection.Output);

            dquery.RunActionQuery();
            TempString = Convert.ToString(dquery.GetParaValue("@Result"));
            if (TempString == null || TempString == "")
            {
                Result = default(DateTime);
            }
            else
            {
                Result = Convert.ToDateTime(dquery.GetParaValue("@Result"));
            }
            //Result = Convert.ToDateTime(dquery.GetParaValue("@SailDate"));
            VoyageStatus = Convert.ToBoolean(dquery.GetParaValue("@CloseVoyage"));
            CountID      = Convert.ToInt32(dquery.GetParaValue("@CountID"));
            return(Result);
        }
Example #3
0
        public int AddEditVoyage(int userID, bool isEdit, EMS.Entity.VoyageEntity voyage)
        {
            string ProcName = "prcAddEditVoyage";

            DAL.DbManager.DbQuery dquery = new DAL.DbManager.DbQuery(ProcName);
            dquery.AddIntegerParam("@userID", userID);
            dquery.AddBooleanParam("@isEdit", isEdit);

            dquery.AddIntegerParam("@pk_VoyageID", voyage.pk_VoyageID);
            dquery.AddIntegerParam("@fk_VesselID", voyage.fk_VesselID);
            dquery.AddIntegerParam("@fl_TerminalID", voyage.fl_TerminalID);
            dquery.AddVarcharParam("@VoyageNo", 10, voyage.VoyageNo);
            dquery.AddDecimalParam("@ImpXChangeRate", 6, 2, voyage.ImpXChangeRate);
            dquery.AddVarcharParam("@IGMNo", 10, voyage.IGMNo);
            //dquery.AddVarcharParam("@CallSign", 14, voyage.CallSign);
            dquery.AddDateTimeParam("@IGMDate", voyage.IGMDate);
            dquery.AddDateTimeParam("@LandingDate", voyage.LandingDate);
            dquery.AddDateTimeParam("@ETADate", voyage.ETADate);
            dquery.AddDateTimeParam("@AddLandingDate", voyage.AddLandingDate);
            dquery.AddDateTimeParam("@PCCDate", voyage.PCCDate);
            dquery.AddVarcharParam("@PCCNo", 14, voyage.PCCNo);
            dquery.AddVarcharParam("@VoyageType", 1, "I");
            dquery.AddIntegerParam("@fk_LPortID", voyage.fk_LPortID);
            dquery.AddIntegerParam("@fk_LPortID1", voyage.fk_LPortID1);
            dquery.AddIntegerParam("@fk_LPortID2", voyage.fk_LPortID2);
            dquery.AddVarcharParam("@LGNo", 40, voyage.LGNo);
            dquery.AddVarcharParam("@AltLGNo", 40, voyage.AltLGNo);
            dquery.AddVarcharParam("@VesselType", 1, voyage.VesselType);
            dquery.AddVarcharParam("@MotherDaughterDtl", 500, voyage.MotherDaughterDtl);
            dquery.AddVarcharParam("@TotalLines", 5, voyage.TotalLines);
            dquery.AddVarcharParam("@CargoDesc", 50, voyage.CargoDesc);
            dquery.AddVarcharParam("@VIANo", 10, voyage.VIANo);
            dquery.AddVarcharParam("@VCN", 14, voyage.VCN);
            dquery.AddVarcharParam("@ETATime", 7, voyage.ETATime);
            dquery.AddIntegerParam("@LightHouseDue", voyage.LightHouseDue);
            dquery.AddBooleanParam("@SameButtonCargo", voyage.SameButtonCargo == "1" ? true : false);
            dquery.AddBooleanParam("@ShipStoreSubmitted", voyage.ShipStoreSubmitted == "1" ? true : false);
            dquery.AddBooleanParam("@CrewList", voyage.CrewList == "1" ? true : false);
            dquery.AddBooleanParam("@PassengerList", voyage.PassengerList == "1" ? true : false);
            dquery.AddBooleanParam("@CrewEffectList", voyage.CrewEffectList == "1" ? true : false);
            dquery.AddBooleanParam("@MaritimeList", voyage.MaritimeList == "1" ? true : false);
            dquery.AddIntegerParam("@LocId", voyage.locid);
            dquery.AddIntegerParam("@fk_pod", voyage.fk_Pod);
            return(dquery.RunActionQuery());
        }
Example #4
0
        public DataSet GetSTax(int pk_StaxID, DateTime? StartDate)
        {
            string ProcName = "admin.prcGetSTax";
            DAL.DbManager.DbQuery dquery = new DAL.DbManager.DbQuery(ProcName);

            dquery.AddIntegerParam("@pk_StaxID", pk_StaxID);
            dquery.AddDateTimeParam("@StartDate", StartDate);

            return dquery.GetTables();
        }
Example #5
0
        public DataSet GetSTaxDate(DateTime? Startdt)
        {
            string ProcName = "admin.prcGetSTaxDate";
            DAL.DbManager.DbQuery dquery = new DAL.DbManager.DbQuery(ProcName);

            dquery.AddDateTimeParam("@StartDate", Startdt);


            return dquery.GetTables();
        }
Example #6
0
        public int AddEditSTax(int userID, int pk_StaxID, DateTime?StartDate, decimal TaxAddCess, decimal TaxCess, decimal TaxPer, bool TaxStatus, bool isEdit)
        {
            string ProcName = "admin.prcAddEditSTax";

            DAL.DbManager.DbQuery dquery = new DAL.DbManager.DbQuery(ProcName);
            dquery.AddIntegerParam("@userID", userID);
            dquery.AddIntegerParam("@pk_StaxID", pk_StaxID);
            dquery.AddDateTimeParam("@StartDate", StartDate);
            dquery.AddDecimalParam("@TaxAddCess", 6, 2, TaxAddCess);
            dquery.AddDecimalParam("@TaxCess", 6, 2, TaxCess);
            dquery.AddDecimalParam("@TaxPer", 6, 2, TaxPer);
            dquery.AddBooleanParam("@TaxStatus", TaxStatus);
            dquery.AddBooleanParam("@isEdit", isEdit);

            return(dquery.RunActionQuery());
        }
Example #7
0
 public int InvoiceDateCheck(DateTime dt)
 {
     DAL.DbManager.DbQuery dquery = new DAL.DbManager.DbQuery("prcInvoiceDateCheck");
     dquery.AddDateTimeParam("@StaxDate", dt);
     return(Convert.ToInt32(dquery.GetScalar()));
 }
Example #8
0
 public decimal GetExchnageRate(DateTime dt)
 {
     DAL.DbManager.DbQuery dquery = new DAL.DbManager.DbQuery("prcGetExchnageRate");
     dquery.AddDateTimeParam("@Exdate", dt);
     return(Convert.ToDecimal(dquery.GetScalar()));
 }