|
@ -18,10 +18,10 @@ const actions = { |
|
|
* @param {*} commit |
|
|
* @param {*} commit |
|
|
* @param {object} param 请求参数 roleId, timeNode, timeUnit |
|
|
* @param {object} param 请求参数 roleId, timeNode, timeUnit |
|
|
*/ |
|
|
*/ |
|
|
async getGlobal(param) { |
|
|
async getGlobal({ commit }, param) { |
|
|
try { |
|
|
try { |
|
|
await uni.$u.api.getGlobal(param); |
|
|
const data = await uni.$u.api.getGlobal(param); |
|
|
// commit('setDailyTasks', data);
|
|
|
commit('setDailyTasks', data); |
|
|
} catch (error) { |
|
|
} catch (error) { |
|
|
console.log('task actions getGlobal error: ', error); |
|
|
console.log('task actions getGlobal error: ', error); |
|
|
} |
|
|
} |
|
@ -33,10 +33,9 @@ const actions = { |
|
|
* @param {number} param.queryType 必填 0 -> 向上 1 -> 向下 |
|
|
* @param {number} param.queryType 必填 0 -> 向上 1 -> 向下 |
|
|
*/ |
|
|
*/ |
|
|
// eslint-disable-next-line
|
|
|
// eslint-disable-next-line
|
|
|
async getRegulars(param) { |
|
|
async getRegulars({ commit }, param) { |
|
|
try { |
|
|
try { |
|
|
const data = await uni.$u.api.getRegularTask(param); |
|
|
return await uni.$u.api.getRegularTask(param); |
|
|
return data; |
|
|
|
|
|
} catch (error) { |
|
|
} catch (error) { |
|
|
throw error || '获取定期任务失败'; |
|
|
throw error || '获取定期任务失败'; |
|
|
} |
|
|
} |
|
|