import { actionPromise } from ".";
import gql from "../api";

const actionGoodById = (_id) =>
   actionPromise('goodById', gql(`query goodById($goodId:String){
    GoodFindOne(query:$goodId){
        _id name description price images{
        _id text url
      }
    }
  }`, {"goodId": JSON.stringify([{_id}])}))

export default actionGoodById;