|
@@ -168,22 +168,13 @@ const actions = {
|
|
|
}
|
|
|
|
|
|
return axios.post(PROCESS_SALE_URL, data).then(response => {
|
|
|
- console.log(response)
|
|
|
-
|
|
|
- commit(SET_PROCESSING, false)
|
|
|
- dispatch(COMPLETE_SALE, true)
|
|
|
+ commit(SET_PROCESSING, !response.data.result)
|
|
|
+ dispatch(COMPLETE_SALE, response.data.result)
|
|
|
}).catch(error => {
|
|
|
console.log(error)
|
|
|
|
|
|
commit(SET_PROCESSING, false)
|
|
|
})
|
|
|
-
|
|
|
- // commit(SET_PROCESSING, true)
|
|
|
-
|
|
|
- // setTimeout(() => {
|
|
|
- // commit(SET_PROCESSING, false)
|
|
|
- // dispatch(COMPLETE_SALE, true)
|
|
|
- // }, 2000)
|
|
|
},
|
|
|
/**
|
|
|
*
|