small fixes
This commit is contained in:
@@ -7,9 +7,9 @@
|
||||
<div class="col-span-2 pt-2 pl-4">#2 </div>
|
||||
<div class="col-span-2 pt-2"></div>
|
||||
<div class="col-span-2 pt-2"></div>
|
||||
<div class="col-span-2 pt-2 "></div>
|
||||
<div class="col-span-1 pt-2 "></div>
|
||||
<div class="col-span-3 text-xs pt-2 ">{{ customer.customer_phone_number }}</div>
|
||||
<div class="col-span-2 pt-2 ">{{ customer_tank.tank_size }}</div>
|
||||
<div class="col-span-1 pt-2 ">{{ customer_description.fill_location }}</div>
|
||||
<div class="col-span-3 text-xs pt-3 ">{{ customer.customer_phone_number }}</div>
|
||||
</div>
|
||||
|
||||
<div class="grid grid-cols-12 pt-2 pb-2">
|
||||
@@ -80,7 +80,7 @@
|
||||
<div class="col-span-6 ">
|
||||
<div v-if="past_deliveries1.length > 1">
|
||||
<div class="col-span-6" v-for="past_delivery in past_deliveries1">
|
||||
<div class="">
|
||||
<div class="" v-if="past_delivery.gallons_delivered != 0.00">
|
||||
{{ past_delivery.when_delivered }} - {{ past_delivery.gallons_delivered }}
|
||||
</div>
|
||||
</div>
|
||||
@@ -110,8 +110,7 @@
|
||||
|
||||
<div class="col-span-12 h-7 pl-4 pt-2" v-if="promo_active">
|
||||
<div class="flex gap-2">
|
||||
<div class="line-through"> {{ delivery.customer_price }}</div> ({{
|
||||
delivery.customer_price - promo.money_off_delivery }})
|
||||
<div class="line-through"> {{ delivery.customer_price }}</div> ({{ promoprice}})
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-span-12 h-7 pl-4 pt-2" v-else>{{ delivery.customer_price }}</div>
|
||||
@@ -220,6 +219,13 @@ export default defineComponent({
|
||||
customer_phone_number: '',
|
||||
account_number: '',
|
||||
},
|
||||
customer_tank: {
|
||||
id: 0,
|
||||
last_tank_inspection: null,
|
||||
tank_status: false,
|
||||
outside_or_inside: false,
|
||||
tank_size: 0,
|
||||
},
|
||||
customer_description: {
|
||||
id: 0,
|
||||
customer_id: 0,
|
||||
@@ -228,6 +234,7 @@ export default defineComponent({
|
||||
fill_location: 0,
|
||||
description: '',
|
||||
},
|
||||
promoprice: 0,
|
||||
promo_active: false,
|
||||
promo: {
|
||||
id: 0,
|
||||
@@ -275,6 +282,7 @@ export default defineComponent({
|
||||
if (this.delivery.promo_id != null) {
|
||||
this.getPromo(this.delivery.promo_id);
|
||||
this.promo_active = true;
|
||||
this.getPrice(delivery_id)
|
||||
}
|
||||
|
||||
})
|
||||
@@ -335,6 +343,18 @@ export default defineComponent({
|
||||
this.getPastDeliveries1(this.customer.id)
|
||||
this.getPastDeliveries2(this.customer.id)
|
||||
this.getCustomerDescription(this.customer.id)
|
||||
this.getCustomerTank(this.customer.id)
|
||||
})
|
||||
},
|
||||
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
|
||||
|
||||
})
|
||||
},
|
||||
|
||||
@@ -358,6 +378,21 @@ export default defineComponent({
|
||||
this.past_deliveries2 = response.data
|
||||
})
|
||||
},
|
||||
|
||||
getPrice(delivery_id: any) {
|
||||
let path = import.meta.env.VITE_BASE_URL + "/promo/promoprice/" + delivery_id;
|
||||
axios({
|
||||
method: "get",
|
||||
url: path,
|
||||
withCredentials: true,
|
||||
headers: authHeader(),
|
||||
})
|
||||
.then((response: any) => {
|
||||
if (response.data) {
|
||||
this.promoprice = response.data.price
|
||||
}
|
||||
})
|
||||
},
|
||||
getPromo(promo_id: any) {
|
||||
let path = import.meta.env.VITE_BASE_URL + "/promo/" + promo_id;
|
||||
axios({
|
||||
|
||||
Reference in New Issue
Block a user