You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
15 lines
529 B
15 lines
529 B
import { createAsyncThunk } from '@reduxjs/toolkit';
|
|
import axios from 'axios';
|
|
import { PizzaToCard, GetPizzaParams } from './types';
|
|
import pickBy from 'lodash/pickBy';
|
|
import identity from 'lodash/identity';
|
|
|
|
export const fetchPizzaToCard = createAsyncThunk<PizzaToCard[], GetPizzaParams>(
|
|
'pizza/fetchPizzaStatus',
|
|
async (params) => {
|
|
const { id } = params;
|
|
const { data } = await axios.get<PizzaToCard[]>(`/api/loadingPizzaInformation/`+id)
|
|
console.log(data);
|
|
return data;
|
|
},
|
|
); |