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

Update services.md #7999

Merged
merged 3 commits into from Sep 24, 2020
Merged

Update services.md #7999

merged 3 commits into from Sep 24, 2020

Conversation

derappelt
Copy link
Contributor

Added entityValidator to create and update service, so it act like the default service and doesn't throw a 500 Error on invalid data.

Added entityValidator to create and update service, so it act like the default service and doesn't throw a 500 Error on invalid data.
Copy link
Member

@alexandrebodin alexandrebodin left a comment

Choose a reason for hiding this comment

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

Thanks for this update. I actually think we should link to the reference implementation in the code directly @derrickmehaffy @lauriejim what do you think ?

@alexandrebodin alexandrebodin added this to the 3.2.0 milestone Sep 23, 2020
@alexandrebodin alexandrebodin added source: docs Documentation changes issue: enhancement Issue suggesting an enhancement to an existing feature labels Sep 23, 2020
@alexandrebodin alexandrebodin removed this from the 3.2.0 milestone Sep 23, 2020
@codecov
Copy link

codecov bot commented Sep 23, 2020

Codecov Report

Merging #7999 into documentation will increase coverage by 13.57%.
The diff coverage is n/a.

Impacted file tree graph

@@                Coverage Diff                 @@
##           documentation    #7999       +/-   ##
==================================================
+ Coverage          19.14%   32.71%   +13.57%     
==================================================
  Files                855     1194      +339     
  Lines              11933    12965     +1032     
  Branches            1898     1279      -619     
==================================================
+ Hits                2284     4241     +1957     
+ Misses              8100     7884      -216     
+ Partials            1549      840      -709     
Flag Coverage Δ
#front 24.81% <ø> (+10.32%) ⬆️
#unit 53.85% <ø> (+13.92%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
packages/strapi-plugin-email/admin/src/pluginId.js 0.00% <0.00%> (-100.00%) ⬇️
...api-plugin-users-permissions/admin/src/pluginId.js 0.00% <0.00%> (-100.00%) ⬇️
...n/src/containers/NotificationProvider/constants.js 0.00% <0.00%> (-100.00%) ⬇️
...n/admin/src/containers/LanguageProvider/reducer.js 0.00% <0.00%> (-61.54%) ⬇️
packages/strapi/lib/services/metrics/index.js 65.00% <0.00%> (-35.00%) ⬇️
...admin/admin/src/components/ContainerFluid/index.js 75.00% <0.00%> (-25.00%) ⬇️
...trapi-admin/admin/src/containers/LeftMenu/index.js 42.30% <0.00%> (-24.36%) ⬇️
...in/admin/src/containers/Webhooks/EditView/index.js 20.33% <0.00%> (-18.07%) ⬇️
...-admin/admin/src/containers/HomePage/components.js 40.00% <0.00%> (-17.15%) ⬇️
...in-upload/admin/src/containers/HomePage/reducer.js 69.56% <0.00%> (-14.81%) ⬇️
... and 1266 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 a070506...8254aca. Read the comment docs.

@derrickmehaffy
Copy link
Member

I agree @alexandrebodin (as I wasn't even aware that function existed :P I thought it was handled at the query level)

@derappelt
Copy link
Contributor Author

I've updated the code so it's more in line with the actual implementation
entity-service.js

@alexandrebodin alexandrebodin added this to the 3.2.0 milestone Sep 23, 2020
@derrickmehaffy
Copy link
Member

We should be sure to add this to the migration guide as well for 3.2.0 to make it easier to find and let people know to update their services.

@alexandrebodin
Copy link
Member

@derrickmehaffy this was introduced a while back so I don't think that should go in the next migration guide :)

@alexandrebodin alexandrebodin merged commit fb03331 into strapi:documentation Sep 24, 2020
@derrickmehaffy
Copy link
Member

Aye but no one was aware and we are changing the docs to add it in for overriding the core controllers > hence the migration guide.

I've helped a lot of people write their their own overrides and none are using that function ;p

@alexandrebodin
Copy link
Member

I think the only thing we should do is use a tool to embed the code directly from github or something. this would always be up to date this way

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
issue: enhancement Issue suggesting an enhancement to an existing feature source: docs Documentation changes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants