Reseteando ui
This commit is contained in:
parent
ca42526a62
commit
258bccf59b
2 changed files with 8 additions and 0 deletions
1
resources/js/store/modules/pedido.js
vendored
1
resources/js/store/modules/pedido.js
vendored
|
@ -96,6 +96,7 @@ const actions = {
|
|||
async resetear({ commit, dispatch }) {
|
||||
await axios.delete("/pedido/sesion");
|
||||
dispatch("productos/getProductos", null, { root: true });
|
||||
dispatch("ui/resetear", null, { root: true });
|
||||
commit('reset');
|
||||
},
|
||||
};
|
||||
|
|
7
resources/js/store/modules/ui.js
vendored
7
resources/js/store/modules/ui.js
vendored
|
@ -17,6 +17,10 @@ const mutations = {
|
|||
popUltimaBusqueda(state) {
|
||||
if (!state.migas.at(-1).action)
|
||||
state.migas.pop();
|
||||
},
|
||||
reset(state) {
|
||||
state.show_chismosa = false;
|
||||
state.show_devoluciones = false;
|
||||
}
|
||||
};
|
||||
|
||||
|
@ -47,6 +51,9 @@ const actions = {
|
|||
: error.message;
|
||||
dispatch("toast", { mensaje: errorMsg });
|
||||
},
|
||||
resetear({ commit }) {
|
||||
commit("reset");
|
||||
},
|
||||
};
|
||||
|
||||
export default {
|
||||
|
|
Loading…
Add table
Reference in a new issue