public Result <T> Update(T item)
        {
            //var i = new T();
            Result <T> r = new Result <T>();

            try
            {
                using (CarCosmeticSalonEntities2 db = new CarCosmeticSalonEntities2())
                {
                    db.Configuration.LazyLoadingEnabled = false;
                    db.Entry(item).State = System.Data.Entity.EntityState.Modified;
                    db.SaveChanges();
                }

                r.value  = item;
                r.info   = "poprawnie dodane";
                r.status = true;
                return(r);
            }
            catch (Exception e)
            {
                r.value  = null;
                r.info   = "Error:" + e.Message;
                r.status = false;
                return(r);
            }
        }
        public Result <T> Add(T item) //    item.AccoutCreateDate = DateTime.Now; dla usera
        {
            var r = new Result <T>();

            try
            {
                using (CarCosmeticSalonEntities2 db = new CarCosmeticSalonEntities2())
                {
                    db.Configuration.LazyLoadingEnabled = false;

                    r.info               = "Poprawnie dodane";
                    r.status             = true;
                    r.value              = item;
                    db.Entry(item).State = System.Data.Entity.EntityState.Added;
                    db.SaveChanges();
                    return(r);
                }
            }catch (Exception e)
            {
                r.status = false;
                r.value  = null;
                r.info   = "Nie udało się dodać, error:" + e.ToString();
                return(r);
            }
        }