diff --git a/src/views/Completed.vue b/src/views/Completed.vue
index 03edb2d1..ff4634a4 100644
--- a/src/views/Completed.vue
+++ b/src/views/Completed.vue
@@ -388,12 +388,12 @@ export default defineComponent({
showBackdrop: false,
});
- popover.onDidDismiss().then((result) => {
+ popover.onDidDismiss().then(async(result) => {
const selectedMethod = result.data.selectedMethod
// Calls method which is clicked on the popover, functions name returns when popover dismiss.
if(typeof(this[selectedMethod]) === 'function') {
- (this as any)[selectedMethod](order);
+ await (this as any)[selectedMethod](order);
}
})
diff --git a/src/views/ShippingPopover.vue b/src/views/ShippingPopover.vue
index 63d0a5ad..56d9f28f 100644
--- a/src/views/ShippingPopover.vue
+++ b/src/views/ShippingPopover.vue
@@ -10,7 +10,7 @@
{{ $t("Unpack") }}
-
+
{{ $t("Shipping label error") }}
@@ -36,9 +36,9 @@ export default defineComponent({
},
props: ['hasPackedShipments', 'order'],
methods: {
- closeModal(eventName: string) {
+ closeModal(selectedMethod: string) {
// Sending function name to be called after popover dismiss.
- popoverController.dismiss({selectedMethod: eventName})
+ popoverController.dismiss({selectedMethod: selectedMethod})
}
},
setup() {