123456789101112131415161718192021222324252627 |
- import {actionPromise} from "../reducers/PromiseReducer";
- import {gql} from "./PathDB";
- import {actionMyOrder} from "../reducers/MyOrdersReducer";
- const actionOrderFind = () => {
- return actionPromise('orderFind', gql(`query orderFind {
- OrderFind(query:"[{}]") {
- _id total createdAt orderGoods{
- _id count price good{
- _id name description images{
- _id url
- }
- }
- }
- }
- }`)
- )
- }
- export const actionFullOrderFind = () =>
- async dispatch => {
- let value = await dispatch(actionOrderFind())
- if (value){
- dispatch(actionMyOrder(value))
- }
- }
|