You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
17 lines
411 B
17 lines
411 B
import { get, post } from "./baseApi"; |
|
|
|
export function createCShifts(postBodies) { |
|
return Promise.all( |
|
postBodies.map(postBody => |
|
post("/cshift/", postBody).catch(err => { |
|
return { error: true, ...err }; |
|
}) |
|
) |
|
).then(resp => { |
|
return Promise.resolve(resp); |
|
}); |
|
} |
|
|
|
export function getCShifts(params) { |
|
return get("/cshift/", params).then(resp => Promise.resolve(resp)); |
|
}
|
|
|