Ticket good printing

This commit is contained in:
2024-06-25 17:58:18 -04:00
parent 52a02c7595
commit 4def44d82e
15 changed files with 963 additions and 429 deletions

View File

@@ -4,7 +4,7 @@
<div class="">
<SideBar />
</div>
<div class=" w-full px-10 ">
<div class=" w-full px-10 pb-10">
<div class="text-sm breadcrumbs">
<ul>
<li>
@@ -19,8 +19,9 @@
</li>
</ul>
</div>
<div class="flex justify-end">
<div class="flex justify-end mb-10">
Customers {{ customer_count }}
</div>
<div class="overflow-x-auto bg-neutral font-bold">
@@ -109,6 +110,7 @@ export default defineComponent({
token: null,
user: null,
customers: [],
customer_count: 0,
page: 1,
perPage: 50,
recordsLength: 0,
@@ -133,6 +135,7 @@ export default defineComponent({
// we simulate an api call that fetch the records from a backend
this.customers = [];
this.get_customers(page)
this.get_customer_count()
},
userStatus() {
let path = import.meta.env.VITE_BASE_URL + '/auth/whoami';
@@ -162,6 +165,16 @@ export default defineComponent({
this.customers = response.data
})
},
get_customer_count() {
let path = import.meta.env.VITE_BASE_URL + '/customer/count';
axios({
method: 'get',
url: path,
headers: authHeader(),
}).then((response: any) => {
this.customer_count = response.data.count
})
},
deleteCustomer(user_id: any) {
let path = import.meta.env.VITE_BASE_URL + '/customer/delete/' + user_id;
axios({