add modules folder based on s_menu
This commit is contained in:
80
test/vuex/acc-one-md-itemdivision/api/a_itemdiv.js
Normal file
80
test/vuex/acc-one-md-itemdivision/api/a_itemdiv.js
Normal file
@@ -0,0 +1,80 @@
|
||||
const URL = "/one-api/itemdivision/Itemdivision";
|
||||
|
||||
export async function getDropdownCategory(prm) {
|
||||
try {
|
||||
var resp = await axios.post(URL + '/dropdown_item_category', prm);
|
||||
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 searchItem(prm) {
|
||||
try {
|
||||
var resp = await axios.post(URL + "/search_item", prm);
|
||||
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 itemDivisionList(prm) {
|
||||
try {
|
||||
var resp = await axios.post(URL + "/item_division_list", prm);
|
||||
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 updateItemDivision(prm) {
|
||||
try {
|
||||
var resp = await axios.post(URL + "/update_item_division", prm);
|
||||
if (resp.status !== 200) {
|
||||
return {
|
||||
status: "ERR",
|
||||
message: resp.statusText,
|
||||
};
|
||||
}
|
||||
|
||||
let data = resp.data;
|
||||
return data;
|
||||
} catch (e) {
|
||||
return {
|
||||
status: "ERR",
|
||||
message: e.message,
|
||||
};
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user