Exemplo n.º 1
0
        public ActionResult HeaderEvents()
        {
            EventsBLL oeventsBLL = new EventsBLL();
            var       details    = oeventsBLL.GetHeaderEvents(Convert.ToString(Session["UserId"]));

            return(PartialView("HeaderEvents", details));
        }
Exemplo n.º 2
0
        public ActionResult Wishlists(string Event_id)
        {
            EventsBLL oeventBLL = new EventsBLL();
            var       details   = oeventBLL.GetEventsWishlist(Event_id);

            return(PartialView("_wishlist", details));
        }
Exemplo n.º 3
0
        public ActionResult AddGroupContact(ContactsSummary obj)
        {
            ContactsBLL           ocntsBLL   = new ContactsBLL();
            EventsBLL             oeventsBLL = new EventsBLL();
            List <GoogleContacts> odetails   = new List <GoogleContacts>();

            foreach (var item in obj.UserContacts)
            {
                if (item.Selected == true)
                {
                    odetails.Add(new GoogleContacts(
                                     item.EmailID,
                                     item.UserId,
                                     item.Selected,
                                     item.GroupId
                                     ));
                }
            }
            obj.UserContacts = odetails.ToArray();
            obj.createrId    = Session["UserId"].ToString();
            var status = ocntsBLL.AddContactsToGroups(obj);

            if (status == "1")
            {
                return(Content("Contact Added Successfully", "text/html"));
            }
            else
            {
                return(Content("Contact Adding Failed", "text/html"));
            }
        }
Exemplo n.º 4
0
        public ActionResult Contributer_Wishlists(string Event_id)
        {
            EventsBLL oeventBLL = new EventsBLL();
            var       details   = oeventBLL.GetCNTWishlist(Event_id, Convert.ToString(Session["UserId"]));

            return(PartialView("_Cnt_WishlistDetails", details));
        }
Exemplo n.º 5
0
        public ActionResult SendInvites(InviteContacts obj)
        {
            EventsBLL            oeventsBLL = new EventsBLL();
            List <InviteMembers> odetails   = new List <InviteMembers>();
            Global ogl = new Global();

            foreach (var item in obj.InvitedMembers)
            {
                if (item.Selected == true)
                {
                    string rnd = Global.RandomString(6);
                    odetails.Add(new InviteMembers(
                                     item.EmailID,
                                     Convert.ToString(Session["UserId"]),
                                     item.ContactNo,
                                     rnd,
                                     false));
                    ogl.sendMail("", item.EmailID, "Invitation to an Event", "http://" + Global.MainLink + "/Account/Index?Code=" + rnd);
                }
            }
            obj.InvitedMembers = odetails.ToArray();
            var status = oeventsBLL.InviteMembers(obj);

            if (status == "1")
            {
                return(Content("Contact Invited Successfully", "text/html"));
            }
            else
            {
                return(Content("Failed to Invite Contacts", "text/html"));
            }
        }
Exemplo n.º 6
0
        public ActionResult Index()
        {
            EventsBLL obj = new EventsBLL();

            U_EVNT_MASTER[] Events = obj.GetAllEventsDetails();
            return(View(Events));
        }
Exemplo n.º 7
0
        public ActionResult Event_Images(string Id)
        {
            EventsBLL oeventsbll = new EventsBLL();

            //  var Event_type = oeventsbll.GetEventtypeImage(Id);
            return(Content("", "text/html"));
        }
Exemplo n.º 8
0
        public ActionResult DashBoard()
        {
            DashboardGroup  details   = new DashboardGroup();
            DashboardTotals tempTotal = new DashboardTotals();
            MembersBLL      memBLL    = new MembersBLL();
            EventsBLL       eveBLL    = new EventsBLL();
            ItemsBLL        iteBLL    = new ItemsBLL();

            List <DashboardEvents>  eves  = new List <DashboardEvents>();
            List <DashboardVendors> vends = new List <DashboardVendors>();

            tempTotal.TotalMembers = memBLL.MembersCount();
            tempTotal.TotalEvents  = eveBLL.EventsCount();
            tempTotal.TotalItems   = iteBLL.ItemsCount();
            tempTotal.TotalVendors = "0000";

            vends.Add(new DashboardVendors("1", "Shop1", "Vendor1", DateTime.Now));
            vends.Add(new DashboardVendors("2", "Shop2", "Vendor2", DateTime.Now));
            vends.Add(new DashboardVendors("3", "Shop3", "Vendor3", DateTime.Now));
            vends.Add(new DashboardVendors("4", "Shop4", "Vendor4", DateTime.Now));
            vends.Add(new DashboardVendors("5", "Shop1", "Vendor5", DateTime.Now));

            details.Totals  = tempTotal;
            details.Members = memBLL.Recent5Members();
            details.Events  = eveBLL.Recent5Events();
            details.Items   = iteBLL.Recent5Items();
            details.Vendors = vends.ToArray();
            return(View(details));
        }
Exemplo n.º 9
0
        public ActionResult MyInvites()
        {
            EventsBLL oeventsBLL = new EventsBLL();
            var       details    = oeventsBLL.GetMyInvites(Convert.ToString(Session["UserId"]));

            return(View(details));
        }
Exemplo n.º 10
0
 public string UpdateEventInvites()
 {
     try
     {
         if (!string.IsNullOrEmpty(Convert.ToString(Session["Code"])) & !string.IsNullOrEmpty(Convert.ToString(Session["UserId"])))
         {
             EventsBLL obll = new EventsBLL();
             return(obll.UpdateEventInvites(Session["Code"].ToString(), Session["UserId"].ToString()));
         }
         else
         {
             return("");
         }
     }
     catch
     {
         return("");
     }
     finally
     {
         if (!string.IsNullOrEmpty(Convert.ToString(Session["Code"])) & !string.IsNullOrEmpty(Convert.ToString(Session["UserId"])))
         {
             Session["Code"] = null;
         }
     }
 }
Exemplo n.º 11
0
        public ActionResult Create()
        {
            EventsBLL    oeventsbll = new EventsBLL();
            var          Event_type = oeventsbll.GetEventtypes();
            Create_Event ogroup     = new Create_Event();

            ogroup.EventTypes = Event_type;
            return(View(ogroup));
        }
Exemplo n.º 12
0
        public ActionResult P_AddItems(string Id, string WList_Id)
        {
            EventsBLL oeventBLL = new EventsBLL();
            WishList  obj       = new WishList();

            obj.Id = WList_Id;
            var details = oeventBLL.GetEventDetails(Id, Convert.ToString(Session["UserId"]));

            details.CreateWishlist = obj;
            return(PartialView("_AddItems", details));
        }
Exemplo n.º 13
0
        private void gvEvents_RowHeaderMouseClick(object sender, DataGridViewCellMouseEventArgs e)
        {
            var          gridView = (DataGridView)sender;
            DialogResult result   = MessageBox.Show("Delete Event -- " + gridView.SelectedRows[0].Cells[2].Value, "Delete Event ", MessageBoxButtons.YesNo);

            if (result == DialogResult.Yes)
            {
                var eventId = (Guid)gridView.SelectedRows[0].Cells[0].Value;
                EventsBLL.DeleteEvent(eventId);
                Bind_gvEvents();
            }
        }
Exemplo n.º 14
0
        public ActionResult Eventsummary(string wishlist_id)
        {
            EventsBLL    oeventBLL = new EventsBLL();
            EventSummary osummary  = new EventSummary();

            osummary = oeventBLL.GetWishlistDetails(wishlist_id, Convert.ToString(Session["UserId"]));
            foreach (var items in osummary.ItemList)
            {
                osummary.total += Convert.ToInt32(items.Item_Tentative_Cost);
            }
            return(PartialView("_EventDetails", osummary));
        }
Exemplo n.º 15
0
        public ActionResult EventProfile(string id)
        {
            EventsBLL obj = new EventsBLL();
            Events    eve = obj.GetEventDetails(id);

            EventsWishList[] eveWlist = obj.GetEventWishListDetails(id);
            EventsGroup      data     = new EventsGroup();

            data.eventDetails  = eve;
            data.eventWishList = eveWlist;
            return(View(data));
        }
Exemplo n.º 16
0
 public ActionResult EventContributer(string id)
 {
     if (!string.IsNullOrEmpty(id))
     {
         EventsBLL oeventBLL = new EventsBLL();
         var       details   = oeventBLL.GetEventDetails(id, Convert.ToString(Session["UserId"]));
         return(View("EventContributer", details));
     }
     else
     {
         return(RedirectToAction("Index", "Home"));
     }
 }
Exemplo n.º 17
0
        public ActionResult DeleteWishlist(string Id)
        {
            EventsBLL oeventBLL = new EventsBLL();
            var       details   = oeventBLL.DeleteWishlist(Id);

            if (details == "1")
            {
                return(Content("Wishlist Deleted Sucessfully", "text/html"));
            }
            else
            {
                return(Content("Wishlist Deletion Falied", "text/html"));
            }
        }
Exemplo n.º 18
0
        public ActionResult CreateWishlist(WishList obj)
        {
            EventsBLL oeventBLL = new EventsBLL();
            var       details   = oeventBLL.CreateWishlist(obj);

            if (details == "1")
            {
                return(Content("Wishlist Created Sucessfully", "text/html"));
            }
            else
            {
                return(Content("Wishlist Creation Falied", "text/html"));
            }
        }
Exemplo n.º 19
0
        private void Bind_gvEvents()
        {
            if (lstProjects.SelectedValue != null)
            {
                gvEvents.DataSource = null;
                var selectedProject      = (Project)lstProjects.SelectedItems[0];
                List <EventEntry> events = EventsBLL.GetEvents(selectedProject.Id);
                gvEvents.DataSource = events;

                // Do not show Guid Id, or bool Finished
                gvEvents.Columns["Id"].Visible        = false;
                gvEvents.Columns["ProjectId"].Visible = false;
            }
        }
Exemplo n.º 20
0
 protected void Page_Load(object sender, EventArgs e)
 {
     if (!this.IsPostBack)
     {
         EventsBLL BLL = new EventsBLL();
         //Populating a DataTable from database.
         string       xmldt = client.GetData();
         StringReader xr    = new StringReader(xmldt);
         DataTable    dt    = new DataTable();
         dt.ReadXml(xr);
         //DataTable dt = BLL.GetData();
         EventRPT.DataSource = dt;
         EventRPT.DataBind();
     }
 }
Exemplo n.º 21
0
        private void PassToBLL(int EventID, string EventTitle, string FullName, string NRIC, string Email, int Handphone, string ReferralSource, string reason, DateTime DOB, string nationality, string HighestEducation, string CurrentEmployment, DateTime RegistrationDate, int TnC)
        {
            EventsBLL InsertIntoEvents = new EventsBLL();
            string    ex;
            int       result = client.InsertIntoEvents(EventID, EventTitle, FullName, NRIC, Email, Handphone, ReferralSource, reason, DOB, nationality, HighestEducation, CurrentEmployment, RegistrationDate, TnC, out ex);

            //int result = InsertIntoEvents.InsertEventForm(EventID, EventTitle, FullName, NRIC, Email, Handphone, ReferralSource, reason, DOB, nationality, HighestEducation, CurrentEmployment, RegistrationDate, TnC, out ex);

            if (result >= 1)
            {
                // Label1.Text = FullName + NRIC + Email + Handphone + ReferralSource + reason + DOB.ToString() + nationality + HighestEducation + CurrentEmployment;
                ClientScript.RegisterStartupScript(this.GetType(), "alert", "ShowPopup();", true);
                this.lblMessage.Text = "Your registration is done successfully! Our team will contact you shotly";
            }
            else
            {
                Label1.Text = ex.ToString();
            }
        }
Exemplo n.º 22
0
        public ActionResult AddItemsToWishlist(EventDetails obj)
        {
            EventsBLL        oeventsBLL = new EventsBLL();
            List <ItemsList> odetails   = new List <ItemsList>();

            foreach (var item in obj.ItemList)
            {
                if (item.Selected == true)
                {
                    odetails.Add(new ItemsList(
                                     item.Item_Id,
                                     item.Item_Tentative_Cost,
                                     item.Selected,
                                     obj.EventMaster.Event_Id,
                                     obj.CreateWishlist.Id
                                     ));
                }
            }
            oeventsBLL.AddItemsToWishlist(odetails.ToArray());
            return(Content("Items Added Successfully", "text/html"));
        }
Exemplo n.º 23
0
        public ActionResult UpdateEvent(EventsGroup eveg, HttpPostedFileBase newImg)
        {
            EventsBLL eveBLL = new EventsBLL();
            Events    eve    = new Events();

            eve.Event_id        = eveg.eventDetails.Event_id;
            eve.Event_Name      = eveg.eventDetails.Event_Name;
            eve.Event_Location  = eveg.eventDetails.Event_Location;
            eve.Event_Status    = eveg.eventDetails.Event_Status;
            eve.Event_StartDate = eveg.eventDetails.Event_StartDate;
            eve.Event_EndDate   = eveg.eventDetails.Event_EndDate;
            eve.Event_Desc      = eveg.eventDetails.Event_Desc;

            string Images = "";

            if (!string.IsNullOrEmpty(Convert.ToString(newImg)))
            {
                if (Request.Files.Count > 0)
                {
                    int i = 0;
                    HttpPostedFileBase files = Request.Files[i];
                    if (files.ContentLength > 0)
                    {
                        string filestoragename = Guid.NewGuid().ToString() + ".jpeg";
                        string directory       = Server.MapPath("~/images/");
                        string path            = Path.Combine(directory, filestoragename);
                        files.SaveAs(path);
                        Images = filestoragename;
                    }
                }
                eve.Event_PicUrl = string.IsNullOrEmpty(Images) ? "/img/default_event.png" : "/images/" + Images;
            }
            eve.Event_Update_by = Convert.ToString(Session["AdminId"]);

            int status = eveBLL.UpdateEventDetails(eve);

            return(RedirectToAction("Index", "Events"));
        }
Exemplo n.º 24
0
        private void btnStartEnd_Click(object sender, EventArgs e)
        {
            // Use the same button for Start and End

            var btn = (Button)sender;

            if (btn.Text == "Start")
            {
                PnlAddEventVisible(true);
            }
            else
            {
                btn.Text                      = "Start";
                btn.BackColor                 = System.Drawing.Color.PaleGreen;
                lblTime.Text                  = "00:00:00";
                lblEventName.Text             = "";
                timer1.Enabled                = false;
                currentEventEntry.EndTime     = DateTime.Now;
                currentEventEntry.ElapsedTime = (currentEventEntry.EndTime - currentEventEntry.StartTime).ToString().Substring(0, 8);
                EventsBLL.AddEvent(currentEventEntry);
                Bind_gvEvents();
            }
        }
Exemplo n.º 25
0
 public ActionResult CreateEvent(Create_Event obj)
 {
     try
     {
         EventsBLL oeventbll = new EventsBLL();
         string    message   = "";
         obj.CreateEvent.User_Id = Convert.ToString(Session["UserId"]);
         var status = oeventbll.CreateEvent(obj.CreateEvent);
         if (status == "1")
         {
             ModelState.Clear();
             message = "Event Created Successfully";
         }
         else
         {
             message = "Event Creation Failed,Please try again.";
         }
         return(Content(message, "text/html"));
     }
     catch
     {
         return(Content("Event Creation Failed, Please try again.", "text/html"));
     }
 }