Exemple #1
0
 public Table(Area area, string tableNumber)
 {
     this.Area = area;
     this.TableNumber = tableNumber;
     this.StateId = 1;
     this.TableSales = new HashSet<TableSale>();
 }
Exemple #2
0
 public void addTableToArea()
 {
     string expectedTableNumber = "02";
     Area a = new Area { Description = "MainFloor" };
     Table t = a.AddTable("02");
     Assert.AreEqual(expectedTableNumber, t.TableNumber);
 }
Exemple #3
0
        public Area AddArea(string description)
        {
            foreach (var a in Areas)
            {
                if (a.Description.Equals(description))
                {
                    throw new BusinessRuleException(uniqueAreaName);
                }
            }

            var area = new Area(this, description);
            this.Areas.Add(area);
            return area;
        }
Exemple #4
0
 public Register(Area area, string name)
 {
     this.Area = area;
     this.Name = name;
 }