Exemplo n.º 1
0
        public async Task EditShopServiceAsync(ShopServicesParam param)
        {
            var entity = await shopServicesRepository.GetByIdAsync(param.Id);

            entity.ServicesName       = param.ServicesName;
            entity.PriceService       = param.PriceService;
            entity.DescriptionService = param.DescriptionService;

            await shopServicesRepository.SaveChangesAsync();
        }
Exemplo n.º 2
0
        public async Task AddNewShopServiceAsync(ShopServicesParam param)
        {
            var entity = new ShopServices()
            {
                ServicesName       = param.ServicesName,
                PriceService       = param.PriceService,
                DescriptionService = param.DescriptionService,
                ShopId             = 1
            };

            await shopServicesRepository.AddAsync(entity);
        }
Exemplo n.º 3
0
        public async Task <IActionResult> EditShopService(ShopServicesParam param)
        {
            await maintenancetService.EditShopServiceAsync(param);

            return(RedirectToAction("ShopService"));
        }