changes
This commit is contained in:
@@ -7,7 +7,7 @@ const props = defineProps({
|
||||
viewMode: String,
|
||||
});
|
||||
|
||||
const { $getdata, $dayjs } = useNuxtApp();
|
||||
const { $findapi, $getapi, $dayjs } = useNuxtApp();
|
||||
const { invoices } = inject("orders");
|
||||
|
||||
const statuses = [
|
||||
@@ -33,28 +33,15 @@ const statuses = [
|
||||
},
|
||||
];
|
||||
|
||||
const paymentStatuses = [
|
||||
{
|
||||
id: 1,
|
||||
name: "Chưa thanh toán",
|
||||
color: "red",
|
||||
},
|
||||
{
|
||||
id: 2,
|
||||
name: "Một phần",
|
||||
color: "yellow",
|
||||
},
|
||||
{
|
||||
id: 3,
|
||||
name: "Đã thanh toán",
|
||||
color: "green",
|
||||
},
|
||||
];
|
||||
|
||||
const paymentStatuses = ref([]);
|
||||
const employees = ref([]);
|
||||
|
||||
onMounted(async () => {
|
||||
employees.value = await $getdata("Staff");
|
||||
const apis = $findapi(["Payment_Status", "Staff"]);
|
||||
const [paymentStatusRes, staffRes] = await $getapi(apis);
|
||||
|
||||
paymentStatuses.value = paymentStatusRes.data.rows || [];
|
||||
employees.value = staffRes.data.rows || [];
|
||||
});
|
||||
|
||||
const input = ref();
|
||||
|
||||
Reference in New Issue
Block a user