Added description

This commit is contained in:
2024-09-18 12:48:28 -04:00
parent ec59223755
commit 94ce4af245
5 changed files with 141 additions and 10 deletions

View File

@@ -104,6 +104,25 @@
</div>
</div>
<div class="col-span-12 p-5">
<div class="grid grid-cols-12">
<div class="col-span-12 font-bold flex text-2xl">
Description
</div>
<div class="col-span-6">
<div class="col-span-12 py-2 font-bold">Home Description</div>
<div class="col-span-12 py-2">
{{ customer_description.description }}
</div>
<div class="col-span-12 py-2 font-bold">Fill Location</div>
<div class="col-span-12 py-2">
{{ customer_description.fill_location }}
</div>
</div>
</div>
</div>
<div class="col-span-12 p-5">
<div class="grid grid-cols-12">
<div class="col-span-12 font-bold flex text-2xl">
@@ -123,6 +142,9 @@
</div>
</div>
</div>
<div class="col-span-12 p-5">
<div class="grid grid-cols-12">
<div class="col-span-6 font-bold flex text-2xl">
@@ -154,7 +176,7 @@
{{ card.name_on_card }}
</div>
<div class="flex p-1 pl-4">
****-****-****-{{ card.last_four_digits }}
{{ card.card_number }}
</div>
<div class="flex p-1 pl-4">
{{ card.expiration_month }}/ {{ card.expiration_year }}
@@ -179,7 +201,7 @@
{{ card.name_on_card }}
</div>
<div class="flex p-1 pl-4">
****-****-****-{{ card.last_four_digits }}
{{ card.card_number }}
</div>
<div class="flex p-1 pl-4">
{{ card.expiration_month }}/ {{ card.expiration_year }}
@@ -264,13 +286,24 @@
<div v-if="oil['same_day'] == 0">No</div>
<div v-else>Yes</div>
</td>
<td class="flex gap-5">
<td class="lg:flex">
<div class="pb-2 pr-2">
<router-link :to="{ name: 'Ticket', params: { id: oil['id'] } }">
<button class="btn btn-accent btn-sm">
Print
</button>
</router-link>
</div>
<div class="pb-2 pr-2">
<router-link :to="{ name: 'deliveryEdit', params: { id: oil['id'] } }">
<button class="btn btn-sm btn-accent">Edit</button>
</router-link>
</div>
<div class="pb-2 pr-2">
<a @click.prevent="deleteCall(oil['id'])">
<button class="btn btn-sm btn-error">Delete</button>
</a>
</div>
</td>
</tr>
</tbody>
@@ -339,6 +372,14 @@ export default defineComponent({
customer_phone_number: '',
account_number: '',
},
customer_description: {
id: 0,
customer_id: 0,
account_number: '',
company_id: '',
fill_location: 0,
description: '',
},
deliveries: [],
delivery_page: 1,
delivery_perPage: 50,
@@ -455,9 +496,23 @@ export default defineComponent({
this.customer = response.data
this.userAutomaticStatus(this.customer.id);
this.getCustomerDescription(this.customer.id);
})
},
getCustomerDescription(userid: any) {
let path = import.meta.env.VITE_BASE_URL + '/customer/description/' + userid;
axios({
method: 'get',
url: path,
headers: authHeader(),
}).then((response: any) => {
this.customer_description = response.data
})
},
getCreditCards(user_id: any) {
let path = import.meta.env.VITE_BASE_URL + '/payment/cards/' + user_id;
axios({