ApplicationConfiguration

接口服务:/api/abp/application-configuration

export namespace ApplicationConfiguration {
  export interface Response {
    localization: Localization;
    auth: Auth;
    setting: Value;
    currentUser: CurrentUser;
    features: Value;
  }

  

 Volo.Abp.AspNetCore.Mvc

       public virtual async Task<ApplicationConfigurationDto> GetAsync()
        {
            //TODO: Optimize & cache..?

            return new ApplicationConfigurationDto
            {
                Auth = await GetAuthConfigAsync(),
                Features = await GetFeaturesConfigAsync(),
                Localization = await GetLocalizationConfigAsync(),
                CurrentUser = GetCurrentUser(),
                Setting = await GetSettingConfigAsync()
            };
        }

 

 

 

一、localization是国际化,对象{values,languages} ,其中values对象含有Default,AbpValidation,AbpIdentity,AbpPermissionManagement,AbpAccount

AbpUi,以及自己的库等一系列资源

languages是支持语言对象的数组

二、设置setting,Dictionary,keyvalue

三、当前用户currentUser

 

posted on 2019-10-25 15:48  dollymi  阅读(1271)  评论(0编辑  收藏  举报

导航