Commit 78aa2af8 by 梁建民

js

parent 931fc388
......@@ -72,48 +72,48 @@ const mutations = {
const actions = {
ziYingIndex({commit}, payload) {
state.loading = true;
state.finished = false;
/* let param = {
'sample_status/eq': 1
};*/
Toast.loading({
message: '加载中...',
forbidClick: true,
loadingType: 'spinner'
});
/* let obj = Object.assign({}, param, payload.params);*/
let obj = {
...payload.params,
'offset':200,
'offset': 200,
'sample_status/eq': 1,
}
};
let params = Util.getParams(obj);
Services.ZiYingIndex(params).then((res) => {
state.loading = false;
let data = res.data;
if (data.error_code == 0) {
commit({
type: 'ziYingIndex',
data: data.data
});
state.finished = true;
} else if (data.error_code == 3) {
window.location.reload();
} else {
state.loading = false;
state.finished = true;
Toast({
message: data.error_msg,
duration: 3000
});
Toast.clear();
}
}).catch(function (err) {
state.loading = false;
state.finished = true;
Toast.clear();
});
},
aggs({commit}, payload) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment