-
{{ delivery.expected_delivery_date }}
-
-
- AUTO
-
-
-
+
+
{{todays_price }}
-
-
-
-
@@ -140,18 +137,13 @@ export default defineComponent({
user: {
user_id: 0,
},
- past_deliveries1: [
+ past_deliveries: [
{
gallons_delivered: 0,
- when_delivered: '',
- }
- ],
- past_deliveries2: [
- {
- gallons_delivered: 0,
- when_delivered: '',
+ fill_date: '',
}
],
+
delivery: {
id: '',
customer_id: 0,
@@ -184,6 +176,13 @@ export default defineComponent({
driver_last_name: '',
promo_id: 0,
},
+ customer_tank: {
+ id: 0,
+ last_tank_inspection: null,
+ tank_status: false,
+ outside_or_inside: false,
+ tank_size: 0,
+ },
customer: {
id: 0,
user_id: 0,
@@ -239,7 +238,7 @@ export default defineComponent({
.then((response: any) => {
this.delivery = response.data;
this.getCustomer(this.delivery.customer_id)
-
+
})
.catch(() => {
@@ -250,6 +249,17 @@ export default defineComponent({
});
});
},
+ getCustomerTank(userid: any) {
+ let path = import.meta.env.VITE_BASE_URL + '/customer/tank/' + userid;
+ axios({
+ method: 'get',
+ url: path,
+ headers: authHeader(),
+ }).then((response: any) => {
+ this.customer_tank = response.data
+
+ })
+ },
getCustomerDescription(userid: any) {
let path = import.meta.env.VITE_BASE_URL + '/customer/description/' + userid;
axios({
@@ -293,33 +303,28 @@ export default defineComponent({
headers: authHeader(),
}).then((response: any) => {
this.customer = response.data
- this.getPastDeliveries1(this.customer.id)
- this.getPastDeliveries2(this.customer.id)
+ this.getPastDeliveriesAuto(this.customer.id)
this.getCustomerDescription(this.customer.id)
+
+
+
+ this.getCustomerDescription(this.customer.id)
+ this.getCustomerTank(this.customer.id)
})
},
- getPastDeliveries1(userid: any) {
- let path = import.meta.env.VITE_BASE_URL + '/delivery/past1/' + userid;
+ getPastDeliveriesAuto(userid: any) {
+ let path = import.meta.env.VITE_BASE_URL + '/delivery/auto/' + userid;
axios({
method: 'get',
url: path,
headers: authHeader(),
}).then((response: any) => {
- this.past_deliveries1 = response.data
- })
- },
- getPastDeliveries2(userid: any) {
- let path = import.meta.env.VITE_BASE_URL + '/delivery/past2/' + userid;
- axios({
- method: 'get',
- url: path,
- headers: authHeader(),
- }).then((response: any) => {
- this.past_deliveries2 = response.data
+ this.past_deliveries = response.data
})
},
+
},
})