Beispiel #1
0
 public DataSet SelectPlay()
 {
     try
     {
         if (SecurityHeaderValidation.Validate(objSecurity))
         {
             DataSet ds = VistaDAL.SelectPlay();
             if (ds != null && ds.Tables[0].Rows.Count > 0)
             {
                 //foreach (DataRow dr in ds.Tables[0].Rows)
                 //{
                 //    if (!dr[0].ToString().Equals("ZANGOORA"))
                 //    {
                 //        dr.Delete();
                 //    }
                 //}
                 ds.AcceptChanges();
                 return(ds);
             }
         }
     }
     catch (Exception ex)
     {
         //Log Message
         Microsoft.Practices.EnterpriseLibrary.Logging.Logger.Write(ex.Message);
     }
     return(null);
 }
Beispiel #2
0
    //public DataTable FinalBooking()
    public DataSet funFinalBooking(String TransactionID, String Source, String DateOfBooking, String TimeOfBooking, String Location,
                                   String Play, String ShowTime, String ShowDate, String Category, String PaymentType, String AgentCode, String SeatInfo,
                                   String MobileNo, String EmailID, String CustomerName, int TotalSeats, decimal TotalAmount, String strPaymentReceiptNo)
    {
        try
        {
            if (SecurityHeaderValidation.Validate(objSecurity))
            {
                DataTable dt            = VistaDAL._Select_Time_Api(TransactionID);
                DateTime  startdatetime = Convert.ToDateTime(dt.Rows[0][0]);
                if (startdatetime.AddMinutes(25) >= DateTime.UtcNow)
                {
                    TransactionRecord _tr = new TransactionRecord();
                    _tr.BookingID     = long.Parse(TransactionID);
                    _tr.Location      = Location;
                    _tr.Play          = Play.ToUpper();
                    _tr.ShowTime      = ShowTime;
                    _tr.ShowDate      = ShowDate;
                    _tr.Category      = Category;
                    _tr.SeatInfo      = SeatInfo;
                    _tr.TotalSeats    = TotalSeats;
                    _tr.Name          = CustomerName;
                    _tr.MobileNo      = MobileNo;
                    _tr.EmailID       = EmailID;
                    _tr.AgentCode     = AgentCode;
                    _tr.ReceiptNo     = strPaymentReceiptNo;
                    _tr.DateOfBooking = DateOfBooking;
                    _tr.TimeOfBooking = TimeOfBooking;
                    _tr.Source        = Source;
                    _tr.TotalAmount   = TotalAmount;
                    _tr.TotalSeats    = TotalSeats;
                    _tr.BookingID     = long.Parse(TransactionID);

                    return(GTICKDAL.funFinalBooking(_tr));
                }
                else
                {
                    DataSet   dsexcep = new DataSet();
                    DataTable dtexcep = new DataTable();
                    dtexcep.Columns.Add("Column1", typeof(string));
                    dtexcep.Rows.Add("Session Time Out");
                    dsexcep.Tables.Add(dtexcep);
                    return(dsexcep);
                }
            }
        }
        catch (Exception ex)
        {
            Microsoft.Practices.EnterpriseLibrary.Logging.Logger.Write(ex.Message);
        }
        return(null);
    }
Beispiel #3
0
 public DataSet SelectPlayTime(String Location, String ShowCode, String ShowDate)
 {
     try
     {
         if (SecurityHeaderValidation.Validate(objSecurity))
         {
             return(VistaDAL.SelectPlayTime(Location, ShowCode, ShowDate));
         }
     }
     catch (Exception ex)
     {
         Microsoft.Practices.EnterpriseLibrary.Logging.Logger.Write(ex.Message);
     }
     return(null);
 }
Beispiel #4
0
 public int SelectAvailableSeats(String ShowAllocationID, String Location)
 {
     try
     {
         if (SecurityHeaderValidation.Validate(objSecurity))
         {
             return(VistaDAL.SelectAvailableSeats(ShowAllocationID, Location));
         }
     }
     catch (Exception ex)
     {
         Microsoft.Practices.EnterpriseLibrary.Logging.Logger.Write(ex.Message);
     }
     return(0);
 }
Beispiel #5
0
 public DataSet SelectRowAudiWise(string audiNo)
 {
     try
     {
         if (SecurityHeaderValidation.Validate(objSecurity))
         {
             return(VistaDAL.SelectRowAudiWise(audiNo));
         }
     }
     catch (Exception ex)
     {
         Microsoft.Practices.EnterpriseLibrary.Logging.Logger.Write(ex.Message);
     }
     return(null);
 }
Beispiel #6
0
 public int MaxColumns(string audiNo)
 {
     try
     {
         if (SecurityHeaderValidation.Validate(objSecurity))
         {
             return(VistaDAL.MaxColumns(audiNo));
         }
     }
     catch (Exception ex)
     {
         Microsoft.Practices.EnterpriseLibrary.Logging.Logger.Write(ex.Message);
     }
     return(0);
 }
Beispiel #7
0
 public DataSet SelectAllSeats(string ShowAllocationID)
 {
     try
     {
         if (SecurityHeaderValidation.Validate(objSecurity))
         {
             return(VistaDAL.SelectAllSeats(ShowAllocationID));
         }
     }
     catch (Exception ex)
     {
         Microsoft.Practices.EnterpriseLibrary.Logging.Logger.Write(ex.Message);
     }
     return(null);
 }
Beispiel #8
0
 public DataSet MaxRowColumn(string audiNo)
 {
     try
     {
         if (SecurityHeaderValidation.Validate(objSecurity))
         {
             return(VistaDAL.MaxRowColumn(audiNo));
         }
     }
     catch (Exception ex)
     {
         //Log Message
         Microsoft.Practices.EnterpriseLibrary.Logging.Logger.Write(ex.Message);
     }
     return(null);
 }
Beispiel #9
0
 public DataSet SelectAudiByPlay(string ShowCode)
 {
     try
     {
         if (SecurityHeaderValidation.Validate(objSecurity))
         {
             return(VistaDAL.SelectAudiByPlay(ShowCode));
         }
     }
     catch (Exception ex)
     {
         //Log Message
         Microsoft.Practices.EnterpriseLibrary.Logging.Logger.Write(ex.Message);
     }
     return(null);
 }
Beispiel #10
0
    public DataSet CheckSeatsAndLock(string SeatNo, string showDate, string ShowTime, long TransactionID)
    {
        try
        {
            if (SecurityHeaderValidation.Validate(objSecurity))
            {
                DataTable classcode       = VistaDAL._Select_classcode(SeatNo, showDate, ShowTime);//this functon select all the categories of the seats, selected by the user.
                string    classcodestring = "";
                for (int i = 0; i < classcode.Rows.Count; i++)
                {
                    classcodestring = classcodestring + classcode.Rows[i]["class Code"].ToString() + ",";
                }
                classcodestring = classcodestring.Remove(classcodestring.Length - 1);
                string[] classcodearray    = classcodestring.Split(',');
                var      distinctclasscode = (from w in classcodearray //decide whether categories are same or not
                                              select w).Distinct().ToArray();

                string[] SeatKeyNo     = SeatNo.Split(',');
                var      distinctkeyno = (from w in SeatKeyNo           //decide whether key no are repitative or not
                                          select w).Distinct().ToArray();
                if (SeatKeyNo.Length == distinctkeyno.Length && distinctclasscode.Length == 1)
                {
                    return(GTICKDAL.CheckSeatsAndLock(TransactionID, SeatNo, showDate, ShowTime));
                }
                else
                {
                    DataSet   dsexcep = new DataSet();
                    DataTable dtexcep = new DataTable();
                    dtexcep.Columns.Add("Column1", typeof(int));
                    dtexcep.Rows.Add(0);
                    dsexcep.Tables.Add(dtexcep);
                    return(dsexcep);
                }
            }
        }
        catch (Exception ex)
        {
            Microsoft.Practices.EnterpriseLibrary.Logging.Logger.Write(ex.Message);
        }
        return(null);
    }
Beispiel #11
0
 public static int Select_Available_Seats(String Category, String PlayTime)
 {
     return(int.Parse(VistaDAL._Select_Available_Seats(Category, PlayTime).Rows[0][0].ToString()));
 }
Beispiel #12
0
 //end
 public static DataTable Select_Audi(String Location)
 {
     return(VistaDAL._Select_Audi(Location));
 }
Beispiel #13
0
 public static DataTable Select_Category_Price(string filmcode, string category)
 {
     return(VistaDAL._Select_Category_Price(filmcode, category));
 }
Beispiel #14
0
 public static DataTable Select_AuditPlay()
 {
     return(VistaDAL._Select_AuditPlay());
 }
Beispiel #15
0
 public static DataTable Select_Newyear_RoyalInfo(String info)
 {
     return(VistaDAL._Select_Newyear_RoyalInfo(info));
 }
Beispiel #16
0
 public static DataTable Select_AuditPlayDate(String Location, String filmCode)
 {
     return(VistaDAL._Select_AuditPlayDate(Location, filmCode));
 }
Beispiel #17
0
 public static DataTable Select_PlayTime_AuditReport(String Location, String filmCode, String PlayDate)
 {
     return(VistaDAL._Select_PlayTime_AuditReport(Location, filmCode, PlayDate));
 }
Beispiel #18
0
 public static DataTable Select_Category(String filmCode)
 {
     return(VistaDAL._Select_Category(filmCode));
 }
Beispiel #19
0
 public static DataTable Select_Play(string Location, string filmCode, string PlayDate)
 {
     return(VistaDAL._Select_Play(Location, filmCode, PlayDate));
 }
Beispiel #20
0
 public static DataSet Select_Category_DS(String filmCode)
 {
     return(VistaDAL._Select_Category_DS(filmCode));
 }
Beispiel #21
0
        public static List <Promotion> GetPromostionCode()
        {
            DataTable        dt        = VistaDAL.GetPromostionCode();
            List <Promotion> listPromo = new List <Promotion>();
            Promotion        objPromotion;

            if (dt != null)
            {
                foreach (DataRow row in dt.Rows)
                {
                    if (!String.IsNullOrEmpty(row["Regex"].ToString()))
                    {
                        objPromotion = new Promotion();
                        if (!row.IsNull("Promotion Code"))
                        {
                            objPromotion.PromotionCode = row["Promotion Code"].ToString();
                        }
                        if (!row.IsNull("Start Date"))
                        {
                            objPromotion.StartDate = Convert.ToDateTime(row["Start Date"]);
                        }
                        if (!row.IsNull("End date"))
                        {
                            objPromotion.EndDate = Convert.ToDateTime(row["End date"]);
                        }
                        if (!row.IsNull("Discount %"))
                        {
                            objPromotion.DiscountPercentage = Convert.ToDecimal(row["Discount %"]);
                        }
                        if (!row.IsNull("RegEx"))
                        {
                            objPromotion.RegexValidator = Convert.ToString(row["RegEx"]);
                        }
                        if (!row.IsNull("CO"))
                        {
                            objPromotion.CO = Convert.ToInt16(row["CO"]);
                        }
                        if (!row.IsNull("BZ"))
                        {
                            objPromotion.BZ = Convert.ToInt16(row["BZ"]);
                        }
                        if (!row.IsNull("DM"))
                        {
                            objPromotion.DM = Convert.ToInt16(row["DM"]);
                        }
                        if (!row.IsNull("GL"))
                        {
                            objPromotion.GL = Convert.ToInt16(row["GL"]);
                        }
                        if (!row.IsNull("SL"))
                        {
                            objPromotion.SL = Convert.ToInt16(row["SL"]);
                        }
                        if (!row.IsNull("PL"))
                        {
                            objPromotion.PL = Convert.ToInt16(row["PL"]);
                        }

                        listPromo.Add(objPromotion);
                    }
                }
            }
            return(listPromo);
        }
Beispiel #22
0
 //Event Event_Mailer_Tracker
 public static DataTable Event_Mailer_Tracker(string _ip, string _date, string _event)
 {
     return(VistaDAL._Write_Event(_ip, _date, _event));
 }