Base solution for your next web application

Activities of "bilalhaidar"

Thank you so much.

How to configure subdomains locally while development? Or I don't need to? I can specify Tenant or now, and on production I configure subdomains?

Thanks

Done

Question

Hi,

In the AccountController.cs code I noticed the following:

await _notificationSubscriptionManager.SubscribeToAllAvailableNotificationsAsync(user.ToUserIdentifier());

When defining Notifications, where do we specify notifications that is available for users? What is meant by the code above?

So far I noticed there are only 2 notifications defined. So how does Notification work in this case?

context.Manager.Add(
                new NotificationDefinition(
                    AppNotificationNames.NewUserRegistered,
                    displayName: L("NewUserRegisteredNotificationDefinition"),
                    permissionDependency: new SimplePermissionDependency(AppPermissions.Pages_Administration_Users)
                    )
                );

            context.Manager.Add(
                new NotificationDefinition(
                    AppNotificationNames.NewTenantRegistered,
                    displayName: L("NewTenantRegisteredNotificationDefinition"),
                    permissionDependency: new SimplePermissionDependency(AppPermissions.Pages_Tenants)
                    )
                );

Thanks

Hi, I read this in the documentation:

Note: In a multi-tenant application, two factor authentication is available to tenants only if it's enabled in the host settings. Also, email verification and SMS verification settings are only available in the host side. This is by design.

What do you mean by SMS and Email verification are only available in the host side. In other words, if admin of host enables SMS Verification, then all tenants would use SMS Verification without being able to disable or so?

Thanks

I am trying to configure my multi-tenant website as :

WebSiteRootAddress to be <a class="postlink" href="http://localhost:6240/">http://localhost:6240/</a>{TENANCY_NAME}

When I try to access website as:

<a class="postlink" href="http://localhost:6240/Default">http://localhost:6240/Default</a>

I get 404 Not Found

Any idea? Thanks

As far as I understood, the Framework would run the validation (data annotations) before calling my AppService method correct? Then, if that is true, how can I send back a message to client? Will the framework give me a way to know that the input didn't meet the validation rules?

Correct. Thanks a lot for the explanation.

Yes it works now. Thanks a lot.

Hello,

I noticed something which doesn't make sense in the AppSettingProvider when it comes to adding a new SettingDefinition for the AllowSelfRegistration.

The code uses

ConfigurationManager.AppSettings[AppSettings.TenantMangement.UseCaptchaOnRegistration]

Should it use something like this?

ConfigurationManager.AppSettings[AppSettings.TenantMangement.AllowSelfRegistration]

This is the code for the AppSettingsProvider I have:

public class AppSettingProvider : SettingProvider
    {
        public override IEnumerable<SettingDefinition> GetSettingDefinitions(SettingDefinitionProviderContext context)
        {
            context.Manager.GetSettingDefinition(AbpZeroSettingNames.UserManagement.TwoFactorLogin.IsEnabled).DefaultValue = false.ToString().ToLowerInvariant();

            var defaultPasswordComplexitySetting = new PasswordComplexitySetting
            {
                MinLength = 6,
                MaxLength = 15,
                UseNumbers = true,
                UseUpperCaseLetters = false,
                UseLowerCaseLetters = true,
                UsePunctuations = false,
            };

            return new[]
                   {
                       //Host settings
                        new SettingDefinition(AppSettings.TenantManagement.AllowSelfRegistration,ConfigurationManager.AppSettings[AppSettings.TenantManagement.UseCaptchaOnRegistration] ?? "true"),
                        new SettingDefinition(AppSettings.TenantManagement.IsNewRegisteredTenantActiveByDefault,ConfigurationManager.AppSettings[AppSettings.TenantManagement.IsNewRegisteredTenantActiveByDefault] ??"false"),
                        new SettingDefinition(AppSettings.TenantManagement.UseCaptchaOnRegistration,ConfigurationManager.AppSettings[AppSettings.TenantManagement.UseCaptchaOnRegistration] ?? "true"),
                        new SettingDefinition(AppSettings.TenantManagement.DefaultEdition,ConfigurationManager.AppSettings[AppSettings.TenantManagement.DefaultEdition] ?? ""),
                        new SettingDefinition(AppSettings.Security.PasswordComplexity, defaultPasswordComplexitySetting.ToJsonString(),scopes: SettingScopes.Application | SettingScopes.Tenant),

                        //Tenant settings
                        new SettingDefinition(AppSettings.UserManagement.AllowSelfRegistration, ConfigurationManager.AppSettings[AppSettings.UserManagement.UseCaptchaOnRegistration] ?? "true", scopes: SettingScopes.Tenant),
                        new SettingDefinition(AppSettings.UserManagement.IsNewRegisteredUserActiveByDefault, ConfigurationManager.AppSettings[AppSettings.UserManagement.IsNewRegisteredUserActiveByDefault] ?? "false", scopes: SettingScopes.Tenant),
                        new SettingDefinition(AppSettings.UserManagement.UseCaptchaOnRegistration, ConfigurationManager.AppSettings[AppSettings.UserManagement.UseCaptchaOnRegistration] ?? "true", scopes: SettingScopes.Tenant)
                   };
        }
    }

Thank you, Bilal

Showing 611 to 620 of 635 entries