+ This field is required
+
+
@@ -143,8 +145,7 @@
//import { mapState } from "vuex";
import { createHelpers } from "vuex-map-fields";
import { fetchStates } from "@/services/util.service";
-import { VueTelInput } from "vue3-tel-input";
-
+
const { mapFields } = createHelpers({
getterType: "accountOne/getField",
mutationType: "accountOne/updateField",
@@ -180,8 +181,7 @@ export default {
(v && v.length >= 8) || "Phone Number must be at least 8 characters",
],
}),
- components: {
- VueTelInput,
+ components: {
},
computed: {
...mapFields([
@@ -230,6 +230,10 @@ export default {
},
},
methods: {
+ acceptNumber() {
+ let x = this.telephone.replace(/\D/g, '').match(/(\d{0,3})(\d{0,3})(\d{0,4})/);
+ this.telephone = !x[2] ? x[1] : '(' + x[1] + ') ' + x[2] + (x[3] ? '-' + x[3] : '');
+ },
verifyAddress() {
this.$emit("verifyAddress");
},
diff --git a/src/routes/retailer/checkout_page.vue b/src/routes/retailer/checkout_page.vue
index 7369647..d8e05ed 100644
--- a/src/routes/retailer/checkout_page.vue
+++ b/src/routes/retailer/checkout_page.vue
@@ -236,6 +236,7 @@
@click="
editLocalAddress(userLocalAddress, false)
"
+ color="primary"
>Edit
@@ -340,9 +341,12 @@
cols="12"
v-else-if="estimatedShippingMethods.length > 0"
>
+
@@ -495,6 +500,7 @@
@click="editBillBook()"
depressed
tile
+ color="primary"
>Edit
@@ -539,7 +545,7 @@
return-object
color="primary"
class="billing-address-select"
- @change="changeBillingAddress()"
+ @update:modelValue="changeBillingAddress()"
item-value="id"
>
@@ -621,7 +627,7 @@
@@ -675,11 +682,13 @@
Cancel
Update
@@ -1791,9 +1800,10 @@ export default {
);
}
},
- newBillingAddress() {
+ async newBillingAddress() {
this.previousAddress = this.address;
- if (this.$refs.billingForm.$refs.shippingAddressform.validate()) {
+ let validate = await this.$refs.billingForm.$refs.shippingAddressform.validate();
+ if (validate && validate.valid) {
if (this.saveInBillingAddressBook) {
this.$store.dispatch("accountOne/updateAddress");
localStorage.setItem(
@@ -1900,6 +1910,9 @@ export default {
}
},
next: function () {
+ if(this.estimatedShipping)
+ {
+
this.tabs = "reviewTab";
if (this.userAuth) {
if (this.addressesList.length == 0) {
@@ -2003,6 +2016,16 @@ export default {
window.scrollTo(0, 0);
}
}
+ }
+ else
+ {
+ this.snackbar = {
+ message: 'Please select shipping method.',
+ color: "error",
+ show: true,
+ timeout: 5000,
+ };
+ }
},
saveUserAddress() {
let phoneNumber = this.$refs.dialogShippingAddressForm.$refs.phoneNumber
@@ -2077,8 +2100,8 @@ export default {
},
async placeOrderFree(e) {
try {
- e.preventDefault();
- if (this.$refs.poNumberForm.validate()) {
+ let validate = await this.$refs.poNumberForm.validate()
+ if (validate && validate.valid ) {
this.isPageLoader = true;
if (this.userAuth) {
try {