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

Add breadcrumb info to GraphQL categories topic #2767

Merged
merged 5 commits into from
Aug 20, 2018

Conversation

keharper
Copy link
Contributor

@keharper keharper commented Aug 17, 2018

This PR is a:

  • New topic
  • Content update
  • Content fix or rewrite
  • Bug fix or improvement

Summary

When this pull request is merged, it will document the breadcrumb support added in GraphQL PR-112

whatsnew
Added information about breadcrumbs in the GraphQL category topic.

@keharper keharper self-assigned this Aug 17, 2018
@keharper keharper added Major Update Significant original updates to existing content 2.3.x Magento 2.3 related changes labels Aug 17, 2018
@keharper keharper requested a review from meker12 August 17, 2018 20:59


{:.bs-callout .bs-callout-info}
You can access the GraphQL introspection feature only if your Magento instance is in developer mode. See [Set the Magento mode]({{ page.baseurl }}/config-guide/cli/config-cli-subcommands-mode.html) for more information about modes.
Copy link
Contributor

Choose a reason for hiding this comment

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

Consider leaving off "for more information about modes" -- just

"See [Set the Magento mode]."

Copy link
Contributor Author

Choose a reason for hiding this comment

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

That's too terse for me. Changed to

[Set the Magento mode] describes how to check and change the mode.

@@ -40,17 +40,19 @@ Attribute | Data type | Description
`product_count`| Int | The number of products in the category
`default_sort_by`| String | The attribute to use for sorting
`products(<attributes>)` | `CategoryProducts` | The list of products assigned to the category
`children` | `CategoryTree` |
`breadcrumbs` | `Breadcrumb` |
Copy link
Contributor

Choose a reason for hiding this comment

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

Breadcrumb description missing because it's obvious, right?

Further down page: Breadcrumb object --- Make Breadcrumb link to the Breadcrumb object

or in description: A Breadcrumb object that contains a set of links to show customers where they are in relation to other ....

`sort` | `ProductSortInput` Specifies which attribute to sort on, and whether to return the results in ascending or descending order. See [Searches and pagination in GraphQL]({{ page.baseurl }}/graphql/search-pagination.html) for more information.

#### CategoryProducts
`sort` | `ProductSortInput` | Specifies which attribute to sort on, and whether to return the results in ascending or descending order. See [Searches and pagination in GraphQL]({{ page.baseurl }}/graphql/search-pagination.html) for more information.
Copy link
Contributor

Choose a reason for hiding this comment

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

Consider dropping "for more information"

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Changed to [Searches and pagination in GraphQL] describes sort orders.

@@ -4,11 +4,11 @@ title: category endpoint
version: 2.3
---

The `category` endpoint allows you to search for a single category definition or the entire category tree.
The `category` endpoint allows you to search for a single category definition or the entire category tree. To return multiple category levels in a single call, define the response so that it contains up to ten nested `children` options. You cannot return the entire category tree if it contains more than 10 sublevels.

Copy link
Contributor

Choose a reason for hiding this comment

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

Not sure if it helps, but consider adding a "for example"

define a response so that it contains up to ten nested children options, for example the query can return a CategoryTree object with up to ten levels of categories, and each of those categories can contain up to ten CategoryTree objects with up to ten subcategories.

Also, in the Sample Queries section -- It might be good to show a real response for the CategoryTree query since it's kind of complicated.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I left the description as is, but added sample output.

Copy link
Contributor

@meker12 meker12 left a comment

Choose a reason for hiding this comment

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

Breadcrumb description lost it's tail ;-)

@@ -39,7 +39,7 @@ Attribute | Data type | Description
`product_count`| Int | The number of products in the category
`default_sort_by`| String | The attribute to use for sorting
`products(<attributes>)` | `CategoryProducts` | The list of products assigned to the category
`breadcrumbs` | `Breadcrumb` |
`breadcrumbs` | `Breadcrumb` | A `Breadcrumb` object contains information about each category that
Copy link
Contributor

Choose a reason for hiding this comment

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

Missing the end of the Breadcrumb description.....

@@ -51,7 +51,7 @@ Attribute | Data type | Description
--- | --- | ---
`pageSize` | Int | Specifies the maximum number of results to return at once. This attribute is optional. The default value is 20.
`currentPage` | Int | Specifies which page of results to return. The default value is 1.
`sort` | `ProductSortInput` | Specifies which attribute to sort on, and whether to return the results in ascending or descending order. See [Searches and pagination in GraphQL]({{ page.baseurl }}/graphql/search-pagination.html) for more information.
`sort` | `ProductSortInput` | Specifies which attribute to sort on, and whether to return the results in ascending or descending order. [Searches and pagination in GraphQL]({{ page.baseurl }}/graphql/search-pagination.html) describes sort orders.

Copy link
Contributor

Choose a reason for hiding this comment

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

I like the way you changed the "See" reference 🥇

@@ -3,11 +3,11 @@ group: graphql
title: category endpoint
---

The `category` endpoint allows you to search for a single category definition or the entire category tree.
The `category` endpoint allows you to search for a single category definition or the entire category tree. To return multiple category levels in a single call, define the response so that it contains up to ten nested `children` options. You cannot return the entire category tree if it contains more than 10 sublevels.
Copy link
Contributor

Choose a reason for hiding this comment

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

Just a note, nesting level limit can be re-configured via di.xml by the system integrator.

@keharper keharper merged commit 1fa90a3 into master Aug 20, 2018
@keharper keharper deleted the kh_graphql-112-breadcrumbs branch August 20, 2018 19:23
magento-devops-reposync-svc pushed a commit that referenced this pull request Feb 3, 2022
Add support for OpenSearch for on-premises installation
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
2.3.x Magento 2.3 related changes Major Update Significant original updates to existing content
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants