예제 #1
0
        public virtual async Task <Guid> CreateAsync(CreateMapTenantDto input)
        {
            var mapTenant = new MapTenant(
                GuidGenerator.Create(),
                input.Code,
                input.TenantId,
                input.MapCode);

            await MapTenantManager.CreateAsync(mapTenant);

            return(mapTenant.Id);
        }
예제 #2
0
        public virtual async Task <Guid> CreateAsync(CreateMapTenantDto input)
        {
            await CheckMapTenantAsync(input.Code, null);

            var mapTenant = new MapTenant(
                GuidGenerator.Create(),
                input.Code,
                input.TenantId,
                input.MapCode);

            await MapTenantRepository.InsertAsync(mapTenant);

            return(mapTenant.Id);
        }
예제 #3
0
        public virtual async Task <Guid> CreateAsync(CreateMapTenantDto input)
        {
            //Validate tenant
            await MapTenantManager.ValidateTenantAsync(input.TenantId, null);

            //Validate code
            await MapTenantManager.ValidateCodeAsync(input.Code);

            var mapTenant = new MapTenant(
                GuidGenerator.Create(),
                input.Code,
                input.TenantId,
                input.MapCode);

            await MapTenantRepository.InsertAsync(mapTenant);

            return(mapTenant.Id);
        }
예제 #4
0
 public async Task <Guid> CreateAsync(CreateMapTenantDto input)
 {
     return(await _mapTenantAppService.CreateAsync(input));
 }