Пример #1
0
        public void Load(Customer C, VenObj V, Show S)
        {
            A = V;
            B = S;
            D = C;

            int op = 0;
            venseatLabel.Text = "";
            foreach (instaSeat i in S.Seats)
            {
                if (i.C == Color.Blue)
                {
                    op++;
                    venseatLabel.Text += i.DSP + "\n";
                }
            }

            totalpriceLabel.Text = (S.TikPrice * op).ToString();
            tikpriceLabel.Text = S.TikPrice.ToString();
            vennameLabel.Text = V.VenueName;

            custLabel.Text = C.CombName + " " + C.Phone;
            caddLabel.Text = C.Street + "\n" + C.City + " " + C.State + " " + C.Zip;

            showLabel.Text = S.name;
            dateLabel.Text = S.ShowDate;

            billingLabel.Text = C.CardNum + " " + C.CardType + " " + C.ExpMon + " " + C.ExpYear + " " + C.CVV;
        }
Пример #2
0
        private void saveButton_Click(object sender, EventArgs e)
        {
            Customer C = new Customer(fnameBox.Text, lnameBox.Text, saddressBox.Text, caddressBox.Text,
                                        staddressBox.Text, zaddressBox.Text, textBox2.Text);
            CustDBase.Instance.Add(C);

            this.Close();
        }
Пример #3
0
 public instaSeat(instaSeat I)
 {
     this.Reserve = I.Reserve;
     this.C = I.C;
     this.S = I.S;
     this.P = I.P;
     this.DSP = I.DSP;
     this.rCust = I.rCust;
 }
Пример #4
0
 public void loadC(Customer C)
 {
     fnameBox.Text = C.FName;
     lnameBox.Text = C.LName;
     saddressBox.Text = C.Street;
     caddressBox.Text = C.City;
     staddressBox.Text = C.State;
     zaddressBox.Text = C.Zip;
     textBox2.Text = C.Phone;
 }
Пример #5
0
 public Customer(Customer C)
 {
     this.Id = C.Id;
     this.FName = C.FName;
     this.LName = C.LName;
     this.Street = C.Street;
     this.City = C.City;
     this.State = C.State;
     this.Zip = C.Zip;
     this.Phone = C.Phone;
     this.CardNum = C.CardNum;
     this.CVV = C.CVV;
     this.ExpMon = C.ExpMon;
     this.ExpYear = C.ExpYear;
     this.CardType = C.CardType;
 }
Пример #6
0
        public void Add(Customer C)
        {
            //Check for existing Customer as in record edit or update
            if (this.KnownCust.Exists(item => (item.FName == C.FName && item.LName == C.LName)))
            {
                int loc = this.KnownCust.FindIndex(item => (item.FName == C.FName && item.LName == C.LName));

                this.KnownCust.RemoveAt(loc);
                this.KnownCust.Insert(loc, C);
            }
            else
            {
                C.Id = this.KnownCust.Count;
                this.KnownCust.Add(C);
            }

            this.Save();
        }
Пример #7
0
        public void LoadC(Customer C)
        {
            this.fnameLabel.Text = C.FName;
            this.lnameLabel.Text = C.LName;
            this.saddressLabel.Text = C.Street;
            this.caddressLabel.Text = C.City;
            this.stateaddressLabel.Text = C.State;
            this.zaddressLabel.Text = C.Zip;
            this.cphone.Text = C.Phone;

            this.ccBox1.Text = C.CardNum;
            this.ccExpMonBox.Text = C.ExpMon;
            this.CCexpYearBox.Text = C.ExpYear;
            this.textBox1.Text = C.CVV;

            if (C.CardType == "MasterCard")
                ctButton.Checked = true;
            else if (C.CardType == "Visa")
                ctButton2.Checked = true;
            else if (C.CardType == "Discover")
                ctButton3.Checked = true;
            else if (C.CardType == "AMEX")
                ctButton4.Checked = true;
        }
Пример #8
0
 //Select Customer
 private void button2_Click(object sender, EventArgs e)
 {
     reval = (Customer)custlistBox.SelectedItem;
     this.Close();
 }
Пример #9
0
        private void saveButton_Click(object sender, EventArgs e)
        {
            Customer C = new Customer(fnameLabel.Text, lnameLabel.Text, saddressLabel.Text, caddressLabel.Text,
                            stateaddressLabel.Text, zaddressLabel.Text, cphone.Text, ccBox1.Text, textBox1.Text,
                            ccExpMonBox.Text, CCexpYearBox.Text, cardIssuer);

            CustDBase.Instance.Add(C);
            this.Close();
        }