Fix queries
This commit is contained in:
parent
fea369be80
commit
0baa065896
4 changed files with 8 additions and 8 deletions
|
@ -99,6 +99,7 @@ export function queueInvoiceGenerate(
|
||||||
onCompleted: data =>
|
onCompleted: data =>
|
||||||
data.status === TaskStatus.SUCCESS
|
data.status === TaskStatus.SUCCESS
|
||||||
? notify({
|
? notify({
|
||||||
|
status: "success",
|
||||||
text: intl.formatMessage(messages.invoiceGenerateFinishedText),
|
text: intl.formatMessage(messages.invoiceGenerateFinishedText),
|
||||||
title: intl.formatMessage(messages.invoiceGenerateFinishedTitle)
|
title: intl.formatMessage(messages.invoiceGenerateFinishedTitle)
|
||||||
})
|
})
|
||||||
|
|
|
@ -5,7 +5,8 @@ import {
|
||||||
} from "@saleor/fragments/errors";
|
} from "@saleor/fragments/errors";
|
||||||
import {
|
import {
|
||||||
fragmentOrderDetails,
|
fragmentOrderDetails,
|
||||||
fragmentOrderEvent
|
fragmentOrderEvent,
|
||||||
|
invoiceFragment
|
||||||
} from "@saleor/fragments/orders";
|
} from "@saleor/fragments/orders";
|
||||||
import makeMutation from "@saleor/hooks/makeMutation";
|
import makeMutation from "@saleor/hooks/makeMutation";
|
||||||
import gql from "graphql-tag";
|
import gql from "graphql-tag";
|
||||||
|
@ -490,12 +491,6 @@ const invoiceEmailSendMutation = gql`
|
||||||
invoice {
|
invoice {
|
||||||
...InvoiceFragment
|
...InvoiceFragment
|
||||||
}
|
}
|
||||||
order {
|
|
||||||
id
|
|
||||||
invoices {
|
|
||||||
...InvoiceFragment
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
`;
|
`;
|
||||||
|
|
|
@ -1,5 +1,8 @@
|
||||||
import { fragmentAddress } from "@saleor/fragments/address";
|
import { fragmentAddress } from "@saleor/fragments/address";
|
||||||
import { fragmentOrderDetails } from "@saleor/fragments/orders";
|
import {
|
||||||
|
fragmentOrderDetails,
|
||||||
|
invoiceFragment
|
||||||
|
} from "@saleor/fragments/orders";
|
||||||
import makeQuery from "@saleor/hooks/makeQuery";
|
import makeQuery from "@saleor/hooks/makeQuery";
|
||||||
import makeTopLevelSearch from "@saleor/hooks/makeTopLevelSearch";
|
import makeTopLevelSearch from "@saleor/hooks/makeTopLevelSearch";
|
||||||
import gql from "graphql-tag";
|
import gql from "graphql-tag";
|
||||||
|
|
|
@ -276,6 +276,7 @@ export const OrderDetailsMessages: React.FC<OrderDetailsMessages> = ({
|
||||||
const errs = data.invoiceRequest?.errors;
|
const errs = data.invoiceRequest?.errors;
|
||||||
if (errs.length === 0) {
|
if (errs.length === 0) {
|
||||||
pushMessage({
|
pushMessage({
|
||||||
|
status: "success",
|
||||||
text: intl.formatMessage(messages.invoiceGenerateFinishedText),
|
text: intl.formatMessage(messages.invoiceGenerateFinishedText),
|
||||||
title: intl.formatMessage(messages.invoiceGenerateFinishedTitle)
|
title: intl.formatMessage(messages.invoiceGenerateFinishedTitle)
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in a new issue