- ABP Framework version: v5.0.1
- UI type: Angular
- DB provider: EF Core
- Tiered (MVC) or Identity Server Separated (Angular): yes
- Exception message and stack trace:
- Steps to reproduce the issue:"
Want: Add TenantType/UserType for tenant/abpuser table. And want to use the TenantType/UserType to filter the list of tenants/users management page.
Please check the image for the "want".
Try solutions, I cannot pass the "tenanttype/usertype" to "public override Task<PagedResultDto<SaasTenantDto>> GetListAsync(GetTenantsInput input)" The reason is "GetTenantsInput", which I cannot pass the value of "tenanttype/usertype" to GetListAsync().
And I try to below: use the class "GetTenantsInput" property "Filter" to pass the tenanttype/usertype value to GetListAsync(GetTenantsInput input).
Works. It could pass the value to backend. But the search text will be failed, was "undefined"
tenantComponent.filters.filter + "||tenanttype:1"; will be "undefined||tenanttype:1"
Could you give me any other hint for this requirements.
Thx
4 Answer(s)
-
0
for the backend you can check out this document https://docs.abp.io/en/abp/latest/Customizing-Application-Modules-Overriding-Services
-
0
If you could override the existing endpoint and add new a parameter, then you could do the following on the angular side:
... action: data => { const tenantComponent = data.getInjected(TenantsComponent); tenantComponent.filters['tenanttype'] = '1'; }
This way, it'll be independent of the search field.
-
0
Thanks you guys.
The class "GetTenantsInput" is not IHasExtraProperties. So without source code, I could not change any for this class "GetTenantsInput" and this method: public override Task<PagedResultDto> GetListAsync(GetTenantsInput input)
If GetTenantsInput is extensible, It would not be hard.
So that is why I use input.Filter the search text as for type property to filter the list.
-
0
hi, We will enhance this in next version.