Files
FE_CPONE/test/vuex/cpone-card-reader/api/photo.js
2026-04-27 10:13:31 +07:00

30 lines
622 B
JavaScript

// API :
// search bank
// paramater : query , page , rowPerPage
const URL =
"/one-api/mockup/fo/cpone_card_reader/";
export async function upload(token, id, datas) {
try {
var resp = await axios.post(URL + 'photo/upload', {
token: token,
id: id,
data: datas
});
if (resp.status != 200) {
return {
status: "ERR",
message: resp.statusText
};
}
let data = resp.data;
return data;
} catch(e) {
return {
status: "ERR",
message: e.message
};
}
}