Files
FE_CPONE/test/vuex/one-queue-admin-fitri/api/px.js
2026-04-27 10:13:31 +07:00

74 lines
1.5 KiB
JavaScript

// API :
// search bank
// paramater : query , page , rowPerPage
const URL =
"/one-api/mockup/fo/registration/";
export async function search(mouCompanyID,search) {
try {
var resp = await axios.post(URL + 'px/search', {
search:search,
mouCompanyID:mouCompanyID
});
if (resp.status != 200) {
return {
status: "ERR",
message: resp.statusText
};
}
let data = resp.data;
return data;
} catch(e) {
return {
status: "ERR",
message: e.message
};
}
}
export async function panel(mouCompanyID,search) {
try {
var resp = await axios.post(URL + 'px/panel', {
search:search,
mouCompanyID:mouCompanyID
});
if (resp.status != 200) {
return {
status: "ERR",
message: resp.statusText
};
}
let data = resp.data;
return data;
} catch(e) {
return {
status: "ERR",
message: e.message
};
}
}
export async function get_price(test_id, mou_id, cito) {
try {
var resp = await axios.post(URL + 'px/get_price', {
test_id:test_id,
mou_id:mou_id,
cito:cito
});
if (resp.status != 200) {
return {
status: "ERR",
message: resp.statusText
};
}
let data = resp.data;
return data;
} catch(e) {
return {
status: "ERR",
message: e.message
};
}
}