Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[ADF-5158] ECM Version Directive #5779

Merged
merged 12 commits into from Jun 23, 2020
Merged

[ADF-5158] ECM Version Directive #5779

merged 12 commits into from Jun 23, 2020

Conversation

davidcanonieto
Copy link
Contributor

@davidcanonieto davidcanonieto commented Jun 16, 2020

Please check if the PR fulfills these requirements

  • The commit message follows our guidelines
  • Tests for the changes have been added (for bug fixes / features)
  • Docs have been added / updated (for bug fixes / features)

What kind of change does this PR introduce? (check one with "x")

  • Bugfix
  • Feature
  • Code style update (formatting, local variables)
  • Refactoring (no functional changes, no api changes)
  • Build related changes
  • Documentation
  • Other... Please describe:

What is the current behaviour? (You can also link to an open issue here)
https://issues.alfresco.com/jira/browse/ADF-5158

What is the new behaviour?
This new directive allows component to hide when the app is not running the ACS version required for them to work properly.

<button *adf-ecm-version="'6.0.0'">
    My Action
</button>

This means this button will be present in the DOM tree from 6.0.0 onwards. Otherwise it will be removed to avoid the component breaking the app.

Does this PR introduce a breaking change? (check one with "x")

  • Yes
  • No

If this PR contains a breaking change, please describe the impact and migration path for existing applications: ...

Other information:

}

private initCompatibilityVersion() {
this.discoveryApiService.getEcmProductInfo().toPromise().then(
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

don't use .toPromise because it is deprecated and will be soon removed

@DenysVuika
Copy link
Contributor

I don't think "ECM" (enterprise content management) is the right term here, maybe "ACS" is better?

@codecov-commenter
Copy link

codecov-commenter commented Jun 16, 2020

Codecov Report

Merging #5779 into develop will increase coverage by 0.04%.
The diff coverage is 91.22%.

Impacted file tree graph

@@             Coverage Diff             @@
##           develop    #5779      +/-   ##
===========================================
+ Coverage    83.88%   83.93%   +0.04%     
===========================================
  Files          960      963       +3     
  Lines        27164    27231      +67     
  Branches      3788     3798      +10     
===========================================
+ Hits         22787    22855      +68     
+ Misses        3247     3240       -7     
- Partials      1130     1136       +6     
Impacted Files Coverage Δ
...core/directives/version-compatibility.directive.ts 83.33% <83.33%> (ø)
lib/core/core.module.ts 97.91% <100.00%> (+0.09%) ⬆️
lib/core/directives/directive.module.ts 100.00% <100.00%> (ø)
lib/core/directives/public-api.ts 100.00% <100.00%> (ø)
lib/core/services/public-api.ts 100.00% <100.00%> (ø)
lib/core/services/version-compatibility-factory.ts 100.00% <100.00%> (ø)
lib/core/services/version-compatibility.service.ts 100.00% <100.00%> (ø)
lib/core/testing/core.testing.module.ts 100.00% <100.00%> (ø)
lib/core/services/translate-loader.service.ts 72.15% <0.00%> (-8.87%) ⬇️
...ib/document-list/services/document-list.service.ts 79.36% <0.00%> (-1.59%) ⬇️
... and 11 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 29d953e...43e06ce. Read the comment docs.

@eromano eromano self-requested a review June 16, 2020 14:32
Copy link
Contributor

@eromano eromano left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the documentation seems to be not update

@eromano
Copy link
Contributor

eromano commented Jun 20, 2020

/rebase

@eromano
Copy link
Contributor

eromano commented Jun 20, 2020

I don't think you need to change the e2e they are working on develop

@eromano eromano merged commit 46e4dae into develop Jun 23, 2020
@eromano eromano deleted the dev-dcano-ADF-5158 branch June 23, 2020 07:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants