Skip to content
Snippets Groups Projects

Resolve "Dashboard api calls"

Merged Carl Schönfelder requested to merge 110-dashboard-api-calls into dev
9 files
+ 66
16
Compare changes
  • Side-by-side
  • Inline
Files
9
+ 15
0
import axios from 'axios'
import { AppDispatch } from './../store'
import Types from './types'
export const getStatistics = () => async (dispatch: AppDispatch) => {
await axios
.get('/api/misc/statistics')
.then((res) => {
dispatch({
type: Types.SET_STATISTICS,
payload: res.data,
})
})
.catch((err) => console.log(err))
}
Loading