Skip to content

Commit

Permalink
Implemented: function to prepare the order timeline and fixed issue i…
Browse files Browse the repository at this point in the history
…n updating button status once the order is cancelled or rejected(#472)
  • Loading branch information
ymaheshwari1 committed Jan 9, 2025
1 parent b0f4944 commit 920a3f1
Show file tree
Hide file tree
Showing 3 changed files with 221 additions and 59 deletions.
6 changes: 3 additions & 3 deletions src/components/ConfirmCancelModal.vue
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ export default defineComponent({
IonThumbnail,
IonToolbar
},
props: ["order", "isCancelationSyncJobEnabled", "isProcessRefundEnabled", "cancelJobNextRunTime"],
props: ["order", "isCancelationSyncJobEnabled", "isProcessRefundEnabled", "cancelJobNextRunTime", "orderType"],
data() {
return {
cancelledItems: [] as Array<any>,
Expand Down Expand Up @@ -173,11 +173,11 @@ export default defineComponent({
// This is done because when cancelling some of the order items the shipment is marked as approved, resulting in removing the order from packed tab
// but we need the order to be displayed in packed tab as it still has some items as reserved status
if(isCancelled) {
await this.store.dispatch("packDeliveryItems", this.currentOrder.shipmentId)
await this.store.dispatch("order/packDeliveryItems", this.currentOrder.shipmentId)
}
}
this.store.dispatch("order/updateCurrent", { order: this.currentOrder });
await this.store.dispatch("order/updateCurrent", { order: this.currentOrder });
this.closeModal();
}
},
Expand Down
2 changes: 1 addition & 1 deletion src/services/OrderService.ts
Original file line number Diff line number Diff line change
Expand Up @@ -349,7 +349,7 @@ const packOrder = async (payload: any): Promise<any> => {

const performFind = async (payload: any): Promise<any> => {
return api({
url: "/performFind",
url: "performFind",
method: "post",
data: payload
});
Expand Down
Loading

0 comments on commit 920a3f1

Please sign in to comment.