Added IMS token changes.
This commit is contained in:
@@ -9,22 +9,23 @@ export function* onSetJobMedia() {
|
||||
}
|
||||
export function* getJobMedia({ payload: jobid }) {
|
||||
try {
|
||||
const localmediaserverhttp = (yield select(
|
||||
(state) => state.user.bodyshop.localmediaserverhttp
|
||||
)).trim();
|
||||
const bodyshop = yield select((state) => state.user.bodyshop);
|
||||
const localmediaserverhttp = bodyshop.localmediaserverhttp.trim();
|
||||
|
||||
if (localmediaserverhttp && localmediaserverhttp !== "") {
|
||||
const imagesFetch = yield cleanAxios.post(
|
||||
`${localmediaserverhttp}/jobs/list`,
|
||||
{
|
||||
jobid,
|
||||
}
|
||||
},
|
||||
{ headers: { ims_token: bodyshop.localmediatoken } }
|
||||
);
|
||||
const documentsFetch = yield cleanAxios.post(
|
||||
`${localmediaserverhttp}/bills/list`,
|
||||
{
|
||||
jobid,
|
||||
}
|
||||
},
|
||||
{ headers: { ims_token: bodyshop.localmediatoken } }
|
||||
);
|
||||
|
||||
yield put(
|
||||
@@ -66,9 +67,8 @@ export function* onSetBillMedia() {
|
||||
}
|
||||
export function* getBillMedia({ payload: { jobid, invoice_number } }) {
|
||||
try {
|
||||
const localmediaserverhttp = (yield select(
|
||||
(state) => state.user.bodyshop.localmediaserverhttp
|
||||
)).trim();
|
||||
const bodyshop = yield select((state) => state.user.bodyshop);
|
||||
const localmediaserverhttp = bodyshop.localmediaserverhttp.trim();
|
||||
|
||||
if (localmediaserverhttp && localmediaserverhttp !== "") {
|
||||
const documentsFetch = yield cleanAxios.post(
|
||||
@@ -76,7 +76,8 @@ export function* getBillMedia({ payload: { jobid, invoice_number } }) {
|
||||
{
|
||||
jobid,
|
||||
invoice_number,
|
||||
}
|
||||
},
|
||||
{ headers: { ims_token: bodyshop.localmediatoken } }
|
||||
);
|
||||
|
||||
yield put(
|
||||
|
||||
Reference in New Issue
Block a user