Ends in:
7 DAYS
11 HRS
35 MIN
49 SEC
Ends in:
7 D
11 H
35 M
49 S
Open Closed

Custom-Settings #6874


User avatar
0
Vipinthachinari created

We need your support in creating a custom area for certain branch settings within Settings. Specifically, we need to add a custom tab labeled "Branch Settings" under the "Identity Management" tab as in the image attached, where we can add and store some values. Can you please assist us with this? It is very urgent.


7 Answer(s)
  • User Avatar
    0
    EngincanV created
    Support Team .NET Developer

    Hi, if you want to create a custom component and add it to the settings page, you can follow https://docs.abp.io/en/abp/latest/Modules/Setting-Management#create-a-setting-view-component this documentation.

    You need to define a view component and then, add it in your *SettingPageContributor class as described in the documentation.

  • User Avatar
    0
    Vipinthachinari created

    Hi, if you want to create a custom component and add it to the settings page, you can follow https://docs.abp.io/en/abp/latest/Modules/Setting-Management#create-a-setting-view-component this documentation.

    You need to define a view component and then, add it in your *SettingPageContributor class as described in the documentation.

    Hi, How can I save and get those values? using ISettingManager ?

  • User Avatar
    0
    EngincanV created
    Support Team .NET Developer

    Hi, if you want to create a custom component and add it to the settings page, you can follow https://docs.abp.io/en/abp/latest/Modules/Setting-Management#create-a-setting-view-component this documentation.

    You need to define a view component and then, add it in your *SettingPageContributor class as described in the documentation.

    Hi, How can I save and get those values? using ISettingManager ?

    You can use the ISettingProvider to get the value of a setting. It's recommended to use it to read the setting values because it implements caching.

    You can use the ISettingManager to set a setting.

  • User Avatar
    0
    Vipinthachinari created

    Hi, if you want to create a custom component and add it to the settings page, you can follow https://docs.abp.io/en/abp/latest/Modules/Setting-Management#create-a-setting-view-component this documentation.

    You need to define a view component and then, add it in your *SettingPageContributor class as described in the documentation.

    Hi, How can I save and get those values? using ISettingManager ?

    You can use the ISettingProvider to get the value of a setting. It's recommended to use it to read the setting values because it implements caching.

    You can use the ISettingManager to set a setting.

    Hi, From where I write this code , I mean save and get because I just created as you mentioned in the previous email and done some html components as in the attachment.Can you please describe me the steps involved? because we are using abp Single layer project.

  • User Avatar
    0
    EngincanV created
    Support Team .NET Developer

    Hi, if you want to create a custom component and add it to the settings page, you can follow https://docs.abp.io/en/abp/latest/Modules/Setting-Management#create-a-setting-view-component this documentation.

    You need to define a view component and then, add it in your *SettingPageContributor class as described in the documentation.

    Hi, How can I save and get those values? using ISettingManager ?

    You can use the ISettingProvider to get the value of a setting. It's recommended to use it to read the setting values because it implements caching.

    You can use the ISettingManager to set a setting.

    Hi, From where I write this code , I mean save and get because I just created as you mentioned in the previous email and done some html components as in the attachment.Can you please describe me the steps involved? because we are using abp Single layer project.

    You need to write your code in the related view component class. I had written an article to add a setting group, which you can found at https://community.abp.io/posts/how-to-hide-abp-related-endpoints-on-swagger-ui-mb2w01fe

    You can check it for all related steps. Regards.

  • User Avatar
    0
    Vipinthachinari created

    Hi, if you want to create a custom component and add it to the settings page, you can follow https://docs.abp.io/en/abp/latest/Modules/Setting-Management#create-a-setting-view-component this documentation.

    You need to define a view component and then, add it in your *SettingPageContributor class as described in the documentation.

    Hi, How can I save and get those values? using ISettingManager ?

    You can use the ISettingProvider to get the value of a setting. It's recommended to use it to read the setting values because it implements caching.

    You can use the ISettingManager to set a setting.

    Hi, From where I write this code , I mean save and get because I just created as you mentioned in the previous email and done some html components as in the attachment.Can you please describe me the steps involved? because we are using abp Single layer project.

    You need to write your code in the related view component class. I had written an article to add a setting group, which you can found at https://community.abp.io/posts/how-to-hide-abp-related-endpoints-on-swagger-ui-mb2w01fe

    You can check it for all related steps. Regards.

    Hi, Getting this error wile saving settings -"Volo.Abp.AbpException: Undefined setting: BranchSettings.IsServer"

  • User Avatar
    0
    EngincanV created
    Support Team .NET Developer

    It seems you did not define the settings before setting them. You should create a class derived from the SettingDefinitionProvider class in order to define its settings:

    public class MySettingProvider : SettingDefinitionProvider
    {
        public override void Define(ISettingDefinitionContext context)
        {
            context.Add(
                new SettingDefinition("BranchSettings.IsServer", "false"),
                new SettingDefinition("BranchSettings.ServerUrl"),
                new SettingDefinition("BranchSettings.BranchId")
            );
        }
    }
    
    

    Please follow the documentation for more info: https://docs.abp.io/en/abp/8.1/Settings#defining-settings

Made with ❤️ on ABP v9.1.0-preview. Updated on November 20, 2024, 13:06