Skip to content
This repository was archived by the owner on Nov 19, 2024. It is now read-only.

issue-8376-made the requested changes #8381

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions src/_data/toc/graphql.yml
Original file line number Diff line number Diff line change
Expand Up @@ -382,11 +382,6 @@ pages:
url: /graphql/mutations/remove-store-credit.html
edition: ee-only

- label: renameRequisitionList mutation
url: /graphql/mutations/rename-requisition-list.html
edition: b2b-only
exclude_versions: [ "2.3" ]

- label: reorderItems mutation
url: /graphql/mutations/reorder-items.html
exclude_versions: ["2.3"]
Expand Down Expand Up @@ -477,6 +472,11 @@ pages:
url: /graphql/mutations/update-products-in-wishlist.html
exclude_versions: ["2.3"]

- label: updateRequisitionList mutation
url: /graphql/mutations/update-requisition-list.html
edition: b2b-only
exclude_versions: [ "2.3" ]

- label: updateRequisitionListItems mutation
url: /graphql/mutations/update-requisition-list-items.html
exclude_versions: [ "2.3" ]
Expand Down
25 changes: 14 additions & 11 deletions src/guides/v2.4/graphql/mutations/create-requisition-list.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,11 +33,12 @@ The following example creates the `Frequently Ordered Products` requisition list

```graphql
mutation {
createRequisitionList(
name: "Frequently Ordered Products",
createRequisitionList(input:{
name: "Frequently Ordered Products"
description: "Frequently ordered products list"
}
) {
list {
requisition_list {
uid
name
description
Expand All @@ -52,9 +53,9 @@ mutation {
{
"data": {
"createRequisitionList": {
"list": {
"uid": "4",
"name": "Frequently Ordered Products",
"requisition_list": {
"uid": "Mw=="
"name": "Frequently Ordered Products"
"description": "Frequently ordered products list"
}
}
Expand All @@ -73,15 +74,17 @@ Attribute | Data Type | Description

## Output attributes

The `createRequisitionListOutput` object returns the `uid` of the new requisition list as well as the input attributes.
The `createRequisitionList` mutation returns the new requisition list.

Attribute | Data Type | Description
--- | --- | ---
`description` | String | The requisition list description
`name` | String! | The requisition list name
`uid` | ID! | The ID of the new requisition list
`requisition_list` | [[RequisitionList](#RequisitionList)] | The created requisition list

### RequisitionList attributes {#RequisitionList}

{% include graphql/requisition-list.md %}

## Related topics

* [renameRequisitionList mutation]({{page.baseurl}}/graphql/mutations/rename-requisition-list.html)
* [updateRequisitionList mutation]({{page.baseurl}}/graphql/mutations/update-requisition-list.html)
* [deleteRequisitionList mutation]({{page.baseurl}}/graphql/mutations/delete-requisition-list.html)
Original file line number Diff line number Diff line change
Expand Up @@ -77,5 +77,5 @@ Attribute | Data Type | Description

## Related topics

* [renameRequisitionList mutation]({{page.baseurl}}/graphql/mutations/rename-requisition-list.html)
* [updateRequisitionList mutation]({{page.baseurl}}/graphql/mutations/update-requisition-list.html)
* [deleteRequisitionList mutation]({{page.baseurl}}/graphql/mutations/delete-requisition-list.html)
34 changes: 25 additions & 9 deletions src/guides/v2.4/graphql/mutations/delete-requisition-list.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ b2b_only: true
contributor_name: Zilker Technology
contributor_link: https://www.ztech.io/
---

The `deleteRequisitionList` mutation deletes a requisition list of the logged in customer.

This mutation requires a valid [customer authentication token]({{page.baseurl}}/graphql/mutations/generate-customer-token.html).
Expand All @@ -14,7 +15,7 @@ This mutation requires a valid [customer authentication token]({{page.baseurl}}/
```graphql
mutation {
deleteRequisitionList(
uid: ID!
requisitionListUid: ID!
) {
deleteRequisitionListOutput
}
Expand All @@ -23,16 +24,21 @@ mutation {

## Example usage

The following example deletes the requisition list with `uid` 4.
The following example deletes a requisition list.

**Request:**

```graphql
mutation {
deleteRequisitionList(
uid: "4"
requisitionListUid: "Mw=="
) {
result
status
requisition_list {
uid
name
description
}
}
}
```
Expand All @@ -43,7 +49,12 @@ mutation {
{
"data": {
"deleteRequisitionList": {
"result": true
"status": true,
"requisition_list": {
"uid": "Mw=="
"name": "Frequently Ordered Products"
"description": "Frequently ordered products list"
}
}
}
}
Expand All @@ -55,17 +66,22 @@ The `deleteRequisitionList` mutation requires the following input.

Attribute | Data Type | Description
--- | --- | ---
`uid` | ID! | The ID of the requisition list to delete
`requisitionListUid` | ID! | The ID of the requisition list to delete

## Output attributes

The `deleteRequisitionListOutput` object returns the `uid` of the new requisition list as well as the input attributes.
The `deleteRequisitionList` mutation returns the status of the operation, and the requisition list, if it was successfully deleted.

Attribute | Data Type | Description
--- | --- | ---
`result` | Boolean | Indicates whether the requisition list was deleted
`requisition_list` | [[RequisitionList](#RequisitionList)] | Details about the deleted requisition list
`status` | Boolean | Indicates whether the request to delete the requisition list was successful

### RequisitionList attributes {#RequisitionList}

{% include graphql/requisition-list.md %}

## Related topics

* [createRequisitionList mutation]({{page.baseurl}}/graphql/mutations/create-requisition-list.html)
* [renameRequisitionList mutation]({{page.baseurl}}/graphql/mutations/rename-requisition-list.html)
* [updateRequisitionList mutation]({{page.baseurl}}/graphql/mutations/update-requisition-list.html)
Original file line number Diff line number Diff line change
@@ -1,24 +1,24 @@
---
group: graphql
title: renameRequisitionList mutation
title: updateRequisitionList mutation
b2b_only: true
contributor_name: Zilker Technology
contributor_link: https://www.ztech.io/
---
The `renameRequisitionList` mutation updates the name and, optionally, the description of a requisition list.
The `updateRequisitionList` mutation updates the name and, optionally, the description of a requisition list.

This mutation requires a valid [customer authentication token]({{page.baseurl}}/graphql/mutations/generate-customer-token.html).

## Syntax

```graphql
mutation {
renameRequisitionList(
uid: ID!
updateRequisitionList(
requisitionListUid: ID!
name: String!
description: String
) {
renameRequisitionListOutput
updateRequisitionListOutput
}
}
```
Expand All @@ -31,12 +31,13 @@ The following example renames the `Frequently Ordered Products` requisition list

```graphql
mutation {
renameRequisitionList(
uid: "4"
name: "Frequently Ordered Essential Products",
updateRequisitionList(input:{
name: "Frequently Ordered Essential Products"
description: "Frequently ordered essential products list"
}
requisitionListUid: "Mw=="
) {
list {
requisition_list {
uid
name
description
Expand All @@ -50,10 +51,10 @@ mutation {
```json
{
"data": {
"renameRequisitionList": {
"list": {
"uid": "4",
"name": "Frequently Ordered Essential Products",
"updateRequisitionList": {
"requisition_list": {
"uid": "Mw=="
"name": "Frequently Ordered Essential Products"
"description": "Frequently ordered essential products list"
}
}
Expand All @@ -63,23 +64,25 @@ mutation {

## Input attributes

The `renameRequisitionList` mutation requires the following input.
The `updateRequisitionList` mutation requires the following input.

Attribute | Data Type | Description
--- | --- | ---
`description`| String | Description of the customer's requisition list
`name` | String! | The name of the customer's requisition list
`uid` | ID! | The ID of the new requisition list
`requisitionListUid` | ID! | The ID of the new requisition list

## Output attributes

The `renameRequisitionListOutput` object returns the `uid` of the new requisition list as well as the input attributes.
The `updateRequisitionList` mutation returns the new requisition list after updating a list.

Attribute | Data Type | Description
--- | --- | ---
`description` | String | The requisition list description
`name` | String! | The requisition list name
`uid` | ID! | The ID of the new requisition list
`requisition_list` | [[RequisitionList](#RequisitionList)] | The updated requisition list

### RequisitionList attributes {#RequisitionList}

{% include graphql/requisition-list.md %}

## Related topics

Expand Down