-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathtemp.js
More file actions
30 lines (24 loc) · 855 Bytes
/
temp.js
File metadata and controls
30 lines (24 loc) · 855 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
function getExpense_Category_payment_methods() {
let category = document.querySelector("#category");
ReqHandler.GET(ReqURI.Expense_category)
.then((res) => {
STATES.Expense_category = res;
res.data.forEach((e) => {
category.innerHTML += `<option value="${e.cat_name}">${e.cat_name}</option>`;
});
})
.catch((err) => {
console.log("Error(fn-getExpense_Category):", err);
});
ReqHandler.GET(ReqURI.Payment_methods)
.then((res) => {
STATES.Payment_methods = res;
})
.catch((err) => {
console.log("Error(fn-getExpense_Category):", err);
});
}
Payment_methods: location.origin + "/settings/get-payment-methods"
STATES.Payment_methods.data.forEach((e) => {
maindrop.querySelector('#mode').innerHTML+=`<option value="${e.pm_title}">${e.pm_title}</option>`
});