Skip to content

Conversation

jase156
Copy link
Contributor

@jase156 jase156 commented May 26, 2021

I solved the task with:

  • Add function getAllFeatureToggle() : This method gets all the FeatureToggle of the Azure Endpoint. The Endpoint returns an object of type PagedAsyncIterableIterator, so we use for await to iterate.
  • Add function getAllFeatureToggleEnableForUser() : This method gets all the FeatureToggle from the provider to filter them and return only the Feature Toggle where the user is.
  • Add method getActivated(): This method returns all FeatureToggles enable for user. It use's getAllFeatureToggleEnableForUser() from FeatureManagerService.
  • Create FeatureToggleCookiesService: This services stores all of the user's toggle features in cookies
  • Modify all components that it use´s feature toggle: Now, when the component want to know if any feature toggle are enable for the user, it searchs on cookies.

@jase156 jase156 force-pushed the TT-19-Include-feature-role-as-part-of-JWT branch from 00664ed to 837a920 Compare May 26, 2021 22:27
@codecov
Copy link

codecov bot commented May 26, 2021

Codecov Report

Merging #689 (6f32023) into master (13de42e) will increase coverage by 0.96%.
The diff coverage is 93.77%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #689      +/-   ##
==========================================
+ Coverage   93.09%   94.06%   +0.96%     
==========================================
  Files          85      104      +19     
  Lines        1564     2071     +507     
  Branches      107      150      +43     
==========================================
+ Hits         1456     1948     +492     
- Misses         67       82      +15     
  Partials       41       41              
Impacted Files Coverage Δ
...nents/time-range-form/time-range-form.component.ts 100.00% <ø> (ø)
...er-management/store/customer-management.effects.ts 83.78% <14.28%> (-16.22%) ⬇️
...ared/components/input-date/input-date.component.ts 64.28% <50.00%> (-4.95%) ⬇️
.../components/project-list/project-list.component.ts 65.78% <52.17%> (-18.43%) ⬇️
...time-entries-table/time-entries-table.component.ts 61.90% <60.00%> (+6.34%) ⬆️
src/app/modules/user/store/user.reducer.ts 62.50% <62.50%> (ø)
src/app/modules/user/services/user-info.service.ts 66.66% <66.66%> (ø)
src/app/modules/user/services/user.service.ts 75.00% <75.00%> (ø)
...dules/time-entries/pages/time-entries.component.ts 85.33% <82.60%> (+2.52%) ⬆️
...es-management/store/activity-management.effects.ts 94.59% <83.33%> (-5.41%) ⬇️
... and 78 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 04f9c19...6f32023. Read the comment docs.

@jase156 jase156 force-pushed the TT-19-Include-feature-role-as-part-of-JWT branch from 837a920 to 6f32023 Compare May 31, 2021 18:13
@sonarqubecloud
Copy link

Kudos, SonarCloud Quality Gate passed!

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
0.0% 0.0% Duplication

@scastillo-jp scastillo-jp merged commit 4f14979 into master May 31, 2021
@scastillo-jp scastillo-jp deleted the TT-19-Include-feature-role-as-part-of-JWT branch May 31, 2021 19:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants