示例#1
0
        public bool Update()
        {
            BrandDTO brandDTO = new BrandDTO
            {
                Id     = this.Id,
                Name   = this.Name,
                Origin = this.Origin
            };

            return(brandDAL.Update(brandDTO));
        }
示例#2
0
        public async Task <IResult> AddOrEditAsync(Brand brand)
        {
            if (brand.Id != 0)
            {
                _brandDAL.Update(brand);
            }
            else
            {
                _brandDAL.Add(brand);
            }

            int result = await _uow.Complete();

            if (result == 0)
            {
                return(new ErrorResult(CRUDMessages.CreateMessage));
            }

            return(new SuccessResult());
        }
示例#3
0
 public IResult UpdateBrand(NBrand brand)
 {
     _iBrandDal.Update(brand);
     return(new SuccessResult(Messages.BrandUpdated));
 }
示例#4
0
 public IResult Update(Brand brand)
 {
     _brandDAL.Update(brand);
     return(new Result(true, Messages.BrandUpdated));
 }
示例#5
0
 public bool Update(Brand entity)
 {
     return(_brandDAL.Update(entity) > 0);
 }
示例#6
0
 public IResult Update(Brand brand)
 {
     _brandDAL.Update(brand);
     return(new SuccessResult(Messages.BrandUpdated));
 }
示例#7
0
 public void Update(Brand entity)
 {
     _brand.Update(entity);
 }
示例#8
0
 public IResult Update(Brand brand)
 {
     _brandDAL.Update(brand);
     return(new SuccessResult());
 }
示例#9
0
 public void Update(Brand entity)
 {
     _dal.Update(entity);
 }