Hi
I need to set, dipending on my profile, where is the default route in angular.
in app.js how can I do that? suppose in core/application I have already store or set this parameter.
I think is a global user settings. Is it correct?
3 Answer(s)
-
0
Hi,
It's defined in app.js.
Default: <a class="postlink" href="https://github.com/aspnetzero/aspnet-zero/blob/master/src/MyCompanyName.AbpZeroTemplate.Web/App/app.js#L61">https://github.com/aspnetzero/aspnet-ze ... app.js#L61</a>
overrided for host: <a class="postlink" href="https://github.com/aspnetzero/aspnet-zero/blob/master/src/MyCompanyName.AbpZeroTemplate.Web/App/app.js#L133">https://github.com/aspnetzero/aspnet-ze ... pp.js#L133</a>
overrided for tenant: <a class="postlink" href="https://github.com/aspnetzero/aspnet-zero/blob/master/src/MyCompanyName.AbpZeroTemplate.Web/App/app.js#L166">https://github.com/aspnetzero/aspnet-ze ... pp.js#L166</a>
Likewise you can override it conditionally.
-
0
ok it's clear, but if I want that a user can define a page that want to see on start up where can I store this information? abpsession?
if (abp.auth.hasPermission('Pages.Tenant.Dashboard')) { if (abp.auth.hasCustomRoute()) { $urlRouterProvider.otherwise(abp.auth.customRoute); }else{ $urlRouterProvider.otherwise("/tenant/dashboard"); }
-
0
Setting system is ideal for that. See documents: <a class="postlink" href="http://www.aspnetboilerplate.com/Pages/Documents/Setting-Management">http://www.aspnetboilerplate.com/Pages/ ... Management</a> You can define a setting, set a default value and allow users to override it. Then you can get the setting value in the client.