diff --git a/resources/js/store/modules/admin/index.ts b/resources/js/store/modules/admin/index.ts index 12b5de6..4dee72d 100644 --- a/resources/js/store/modules/admin/index.ts +++ b/resources/js/store/modules/admin/index.ts @@ -66,7 +66,10 @@ const actions = { commit('toggleCaracteristica', { caracteristica_id: caracteristica_id }) }, async abrirFaltantesYSobrantes({ commit, dispatch }) { + const { data } = await axios.get(`/admin/${state.grupo_de_compra_id}/faltantes-y-sobrantes`) + const pedido = { pedido_id: data.id }; dispatch("productos/init", null, { root: true }); + dispatch("pedido/elegirPedido", pedido, { root: true }); dispatch("ui/toggleFaltantesYSobrantes", null, { root: true }); } };