diff --git a/client/src/store/index.js b/client/src/store/index.js index 69a9202..9804620 100644 --- a/client/src/store/index.js +++ b/client/src/store/index.js @@ -71,6 +71,9 @@ const mutations = { }else{ state.arrayresultchaines.push({chaine: payload.chaine,name: payload.name,emission: payload.emission}); } + state.arrayresultchaines=state.arrayresultchaines.sort(function (a,b){ + return ((a.chaine < b.chaine) ? -1 : ((a.chaine > b.chaine) ? 1 : 0)); + }) }, setUserData (state, payload) { console.log('setUserData payload = ', payload)