public string MakeClient(string name, string VATNumber, string adres, CategorieType type)
        {
            Client client = new Client(name, VATNumber, adres, manager.GetCategory(type));

            SelectedClient = client;
            return(name);
        }
Esempio n. 2
0
 public void Set(CategorieType categorieType, ComponentType componentTypeMode, List <ComponentData> componentDatas, Action RefreshComponentCard, int maxComponentContent)
 {
     selectComponentButton.onClick.AddListener(() =>
     {
         PanelControl.instance.OpenComponentListPanel();
         ComponentListPanel.instance.Set(categorieType, componentTypeMode, componentDatas, RefreshComponentCard, maxComponentContent);
     });
 }
        public void TestRudyManagerGetCategory()
        {
            UnitOfWork             uow  = new UnitOfWork(new VIPServicesRudyTestContext(true));
            VIPServicesRudyManager m    = new VIPServicesRudyManager(uow);
            CategorieType          type = CategorieType.vip;
            Category vip = m.GetCategory(type);

            vip.Name.ShouldBe(CategorieType.vip);
            vip.StaffDiscount.Count.ShouldBe(3);
        }
Esempio n. 4
0
    public void ProductMode(CategorieType categorieType, ComponentType componentType, List <ComponentData> componentData)
    {
        this.categorieType          = categorieType;
        this.componentType          = componentType;
        this.componentData_list     = componentData;
        this.componentTypeText.text = componentType.ToString();

        RemoveAllSlotComponent();
        AddSlotComponent_ProductMode();
    }
    public void Set(CategorieType categorieTypeMode, ComponentType componentType, List <ComponentData> component_list, Action refreshConponentCard, int maxComponentContent)
    {
        this.categorieType        = categorieTypeMode;
        this.componentType        = componentType;
        this.component_list       = component_list;
        this.refreshConponentCard = refreshConponentCard;
        this.maxComponentContent  = maxComponentContent;
        header.text = componentType.ToString() + " List";

        RefreshSlotComponent();
    }
Esempio n. 6
0
    public void CreateMode(CategorieType categorieType, ComponentType componentType, List <ComponentData> componentData, int slotMax)
    {
        this.categorieType          = categorieType;
        this.componentType          = componentType;
        this.slotMax                = slotMax;
        this.componentData_list     = componentData;
        this.componentTypeText.text = componentType.ToString();

        RemoveAllSlotComponent();
        AddSlotComponent_CreateMode();
    }
Esempio n. 7
0
        private static List <Category> ReadCategories(List <string[]> file)
        {
            List <Category> categories = new List <Category>();

            foreach (string[] line in file.Skip(1))
            {
                CategorieType   type      = (CategorieType)Enum.Parse(typeof(CategorieType), line[0]);
                List <Discount> discounts = new List <Discount>();
                for (int i = 1; i < line.Length - 1; i += 2)
                {
                    discounts.Add(new Discount(int.Parse(line[i]), float.Parse(line[i + 1])));
                }
                Category cat = new Category(discounts, type);
                categories.Add(cat);
                Console.WriteLine($"added category: {cat.Name}");
            }
            return(categories);
        }
 public Category GetCategory(CategorieType name)
 {
     return(context.Categories
            .Include(c => c.StaffDiscount)
            .Single(c => c.Name == name));
 }
Esempio n. 9
0
 public void MakeClient(string name, string VATNumber, string adres, CategorieType categorie)
 {
     ClientShowBox.Text = vm.MakeClient(name, VATNumber, adres, categorie);
 }
Esempio n. 10
0
 public Category(List <Discount> staffDiscount, CategorieType name)
 {
     StaffDiscount = staffDiscount.OrderBy(x => x.Aantal).ToList();
     Name          = name;
 }
Esempio n. 11
0
 public void SetCategorie(CategorieType categorie)
 {
     this.categorie = categorie;
 }
 public Category GetCategory(CategorieType type)
 {
     return(uow.Categories.GetCategory(type));
 }