Exemple #1
0
 public FordExplorer()
 {
     Model  = "Ford Explorer";
     Engine = "4.0 L Cologne V6";
     Accessories.Add("Car Cover");
     Accessories.Add("Sun Shade");
 }
Exemple #2
0
        private void BtnAddFitting_Click(object sender, EventArgs e)
        {
            ViewForms.SelectItemWindow selectItem = new ViewForms.SelectItemWindow();
            selectItem.Owner = this;
            if (selectItem.ShowDialog() == DialogResult.OK)
            {
                int    id   = selectItem.SelectedFittingID;
                string name = selectItem.SelectedFittingName;

                Accessories.Add(new Model.FittingToBriefcaseModel()
                {
                    IdBriefcase  = IdBriefcase,
                    IdFitting    = id,
                    FittingName  = name,
                    FittingCount = 1,
                    IsAdded      = true
                });

                BindingSource bindingSource = new BindingSource();
                bindingSource.DataSource  = Accessories;
                gridBriefcases.DataSource = bindingSource;

                SetGridControlStyle();

                IsNotSaveChanges = true;
            }

            new UI.UserCulture().SetCultureOnForm();
        }
        public void AddTest()
        {
            VerifyDoesntExist();
            bool value = Accessories.Add(_databasePath, _gunId, _accessoriesManufacturer, _accessoriesName,
                                         _accessoriesSerialNumber, _accessoriesCondition, _accessoriesNotes, _accessoriesUse,
                                         _accessoriesPurValue, _accessoriesAppValue, _accessoriesCiv, _accessoriesIc, out _errOut);

            General.HasTrueValue(value, _errOut);
        }
Exemple #4
0
 public FordExplorer()
 {
     Model        = "Ford Explorer";
     Engine       = "4.0 L Cologne V6";
     Transmission = "5-speed M50D-R1 manual";
     Body         = "SUV";
     Doors        = 5;
     Accessories.Add("Car Cover");
     Accessories.Add("Sun Shade");
 }
Exemple #5
0
 public FordFocus()
 {
     Model        = "Ford Focus";
     Engine       = "1.0 L EcoBoost I3";
     Transmission = "6-speed PowerShift automatic";
     Body         = "5-door hatchback";
     Doors        = 5;
     Accessories.Add("Car Cover");
     Accessories.Add("Sun Shade");
 }
Exemple #6
0
 ///====================================================================================
 /// <summary>
 ///     Adds an accessory to the collection
 /// </summary>
 ///
 /// <param name="accessory">
 ///     The accessory to add
 /// </param>
 ///====================================================================================
 public void Add(Accessory accessory)
 {
     accessory.Accessories      = new ObservableCollection <string>(GetAccessories());
     accessory.ColorValues      = new ObservableCollection <string>(GetColorValues(accessory.Name));
     accessory.WidthValues      = new ObservableCollection <string>(GetWidthValues(accessory.Name, accessory.Color));
     accessory.HeightValues     = new ObservableCollection <string>(GetHeightValues(accessory.Name, accessory.Color));
     accessory.DepthValues      = new ObservableCollection <string>(GetDepthValues(accessory.Name, accessory.Color));
     accessory.PropertyChanged += Accessory_PropertyChanged;
     Accessories.Add(accessory);
 }
 /// <summary>
 /// Verifies the exists.
 /// </summary>
 private void VerifyExists()
 {
     if (!Accessories.Exists(_databasePath, _gunId, _accessoriesManufacturer, _accessoriesName,
                             _accessoriesSerialNumber, _accessoriesCondition, _accessoriesNotes, _accessoriesUse,
                             _accessoriesPurValue, _accessoriesAppValue, _accessoriesCiv, _accessoriesIc, out _errOut))
     {
         Accessories.Add(_databasePath, _gunId, _accessoriesManufacturer, _accessoriesName,
                         _accessoriesSerialNumber, _accessoriesCondition, _accessoriesNotes, _accessoriesUse,
                         _accessoriesPurValue, _accessoriesAppValue, _accessoriesCiv, _accessoriesIc, out _errOut);
     }
 }
Exemple #8
0
        ///====================================================================================
        /// <summary>
        ///     Adds an accessory to the collection
        /// </summary>
        ///
        /// <param name="roomNumber">
        ///     The room number to assign the accessory to
        /// </param>
        ///====================================================================================
        public void Add(int roomNumber)
        {
            Accessory accessory = new Accessory()
            {
                Accessories = new ObservableCollection <string>(GetAccessories()),
                RoomNumber  = roomNumber
            };

            accessory.PropertyChanged += Accessory_PropertyChanged;
            Accessories.Add(accessory);
        }
 public LincolnAviator(string model, string engine, string transmission, string body, int doors)
 {
     Model        = model;
     Engine       = engine;
     Transmission = transmission;
     Body         = body;
     Doors        = doors;
     Accessories.Add("Leather Look Seat Covers");
     Accessories.Add("Chequered Plate Racing Floor");
     Accessories.Add("4x 200 Watt Coaxial Speekers");
     Accessories.Add("500 Watt Bass Subwoofer");
 }
Exemple #10
0
        public void OnGet()
        {
            var chuildPhoneCategory = _categoryRepository.GetSome(x => x.IsDeleted == false && x.ParentId == 1);

            foreach (var item in chuildPhoneCategory)
            {
                var phone = _itemRepository.GetByCategory(item.Id);
                foreach (var _phone in phone)
                {
                    Phones.Add(_phone);
                }
            }
            var chuildLaptopCategory = _categoryRepository.GetSome(x => x.IsDeleted == false && x.ParentId == 2);

            foreach (var item in chuildLaptopCategory)
            {
                var laptop = _itemRepository.GetByCategory(item.Id);
                foreach (var _laptop in laptop)
                {
                    Laptops.Add(_laptop);
                }
            }
            var chuildTabletCategory = _categoryRepository.GetSome(x => x.IsDeleted == false && x.ParentId == 3);

            foreach (var item in chuildTabletCategory)
            {
                var tablet = _itemRepository.GetByCategory(item.Id);
                foreach (var _tablet in tablet)
                {
                    Tablets.Add(_tablet);
                }
            }
            var chuildAccessorieCategory = _categoryRepository.GetSome(x => x.IsDeleted == false && x.ParentId == 4);

            foreach (var item in chuildAccessorieCategory)
            {
                var accessorie = _itemRepository.GetByCategory(item.Id);
                foreach (var _accessorie in accessorie)
                {
                    Accessories.Add(_accessorie);
                }
            }
            var cus = _userManager.GetUserAsync(HttpContext.User).Result;
        }
 public NSIndexPath Add(HMAccessory accessory)
 {
     Accessories.Add(accessory);
     Accessories.SortByLocalizedName(a => a.Name);
     return(IndexPathOfObject(accessory));
 }
Exemple #12
0
 public void SetAccessory(string strAccessory)
 {
     Accessories.Add(strAccessory);
 }