Merge branch 'dev-anang' of https://gitlab.com/hanifsalafi/mediahub_redesign
This commit is contained in:
commit
03e0f74cee
|
|
@ -20,9 +20,13 @@ export async function listTask(
|
||||||
taskType: string,
|
taskType: string,
|
||||||
status: number[]
|
status: number[]
|
||||||
) {
|
) {
|
||||||
const statusQuery = status.length
|
let statusQuery = "";
|
||||||
? `&isDone=${status.includes(1)}&isActive=${status.includes(2)}`
|
|
||||||
: "";
|
if (status.includes(1)) {
|
||||||
|
statusQuery = "&isDone=true";
|
||||||
|
} else if (status.includes(2)) {
|
||||||
|
statusQuery = "&isDone=false";
|
||||||
|
}
|
||||||
|
|
||||||
return httpGetInterceptor(
|
return httpGetInterceptor(
|
||||||
`assignment/list?enablePage=1&size=${size}&page=${page}&title=${title}&taskType=${taskType}&uniqueCode=${code}&createdAt=${createdAt}${statusQuery}`
|
`assignment/list?enablePage=1&size=${size}&page=${page}&title=${title}&taskType=${taskType}&uniqueCode=${code}&createdAt=${createdAt}${statusQuery}`
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue