Esempio n. 1
0
 public virtual async Task<TenantDto> UpdateAsync(Guid id, TenantUpdateDto input)
 {
     var tenant = await TenantRepository.GetAsync(id);
     await TenantManager.ChangeNameAsync(tenant, input.Name);
     input.MapExtraPropertiesTo(tenant);
     await TenantRepository.UpdateAsync(tenant);
     return ObjectMapper.Map<Tenant, TenantDto>(tenant);
 }
Esempio n. 2
0
        public async Task <TenantDto> UpdateAsync(Guid id, TenantUpdateDto input)
        {
            var tenant = await TenantRepository.GetAsync(id);

            await TenantManager.ChangeNameAsync(tenant, input.Name);

            await TenantRepository.UpdateAsync(tenant);

            return(ObjectMapper.Map <Tenant, TenantDto>(tenant));
        }
Esempio n. 3
0
        public virtual async Task <TenantDto> UpdateAsync(Guid id, TenantUpdateDto input)
        {
            var tenant = await TenantRepository.GetAsync(id);

            await TenantManager.ChangeNameAsync(tenant, input.Name);

            tenant.SetConcurrencyStampIfNotNull(input.ConcurrencyStamp);
            input.MapExtraPropertiesTo(tenant);

            await TenantRepository.UpdateAsync(tenant);

            return(ObjectMapper.Map <Tenant, TenantDto>(tenant));
        }
Esempio n. 4
0
 public virtual Task <TenantDto> UpdateAsync(Guid id, TenantUpdateDto input)
 {
     return(TenantAppService.UpdateAsync(id, input));
 }