From cbc7d7f7494508fda69e88c76702a878bebca0e2 Mon Sep 17 00:00:00 2001 From: gabrhr <73925454+gabrhr@users.noreply.github.com> Date: Tue, 31 May 2022 03:58:23 -0500 Subject: Add Almacenes - todo de almacenes, redux, pagina - mejoro form de pedido (etiqueta estado, RUC) #TODO - Ver combobox con API --- front/odiparpack/app/actions/almacen.js | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 front/odiparpack/app/actions/almacen.js (limited to 'front/odiparpack/app/actions/almacen.js') diff --git a/front/odiparpack/app/actions/almacen.js b/front/odiparpack/app/actions/almacen.js new file mode 100644 index 0000000..b5694cd --- /dev/null +++ b/front/odiparpack/app/actions/almacen.js @@ -0,0 +1,19 @@ +import { + getAlmacenesAPI +} from 'ba-api/almacen'; +import * as types from './actionTypes' + +export const setAlmacenes = (payload) => ({ + type: types.LISTA_ALMACEN, + payload +}); + +export const getAlmacenes = () => async dispatch => { + try{ + const res = await getAlmacenesAPI(); + dispatch(setAlmacenes({res})) + return res; + }catch(e){ + console.log(e) + } +} \ No newline at end of file -- cgit v1.2.3