Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implemented: new Re-route fulfillment app v2 (#92) #100

Merged
merged 16 commits into from
Dec 3, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
16 commits
Select commit Hold shift + click to select a range
2c4651c
Implemented: new UI of the Reroute fulfillment app (#92)
amansinghbais Sep 17, 2024
b4b7a14
Implemented: Logic for the reroute fulfillment v2 (#92)
amansinghbais Sep 19, 2024
a5afa74
Reverted: unwanted code from the order page (#92)
amansinghbais Sep 19, 2024
22fec9d
Implemented: logic for reroute fulfillment app v2 (#92)
amansinghbais Sep 26, 2024
4bda099
Improved: reverted unused code, check in case order split not allowed…
amansinghbais Sep 27, 2024
27e592a
Improved: api endpoint for fetching order rejection facility history …
amansinghbais Oct 3, 2024
19c5a36
Improved: optimized code and fixed empty state (#92)
amansinghbais Nov 4, 2024
1023f9f
Improved: sending reason for item cancellation as payload and reverte…
amansinghbais Nov 28, 2024
6a7fcfe
Improved: migrated from moment to luxon for timezones (#92)
amansinghbais Nov 28, 2024
1a6d36c
Improved: icon for selecting store for item, added state variable for…
amansinghbais Nov 28, 2024
7c9bfd3
Improved: added service and handling for the request cancellation bas…
amansinghbais Nov 29, 2024
e32f0a6
Improved: refetching order detail on cancel whole shipGroup and added…
amansinghbais Dec 2, 2024
0a84415
Improved: reverted logic to split toName to firstName and lastName, a…
amansinghbais Dec 2, 2024
6049fd2
Improved: variable name for the seleted facility id value (#92)
amansinghbais Dec 2, 2024
3155ace
Improved: fetching recent facility from where order is rejected and g…
amansinghbais Dec 2, 2024
b4c3da4
Improved: payload for updating the shipping method so as to use exist…
amansinghbais Dec 3, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions src/services/OrderService.ts
Original file line number Diff line number Diff line change
Expand Up @@ -40,9 +40,9 @@ const getProductStoreSetting = async (payload: any): Promise<any> => {
});
}

const getRerouteOrderBrokeringHistory = async (payload: any): Promise<any> => {
const getRerouteOrderFacilityChangeHistory = async (payload: any): Promise<any> => {
return api({
url: "getRerouteOrderBrokeringHistory",
url: "getRerouteOrderFacilityChangeHistory",
method: "post",
data: payload
});
Expand All @@ -58,7 +58,7 @@ const releaseRerouteOrderItem = async (payload: any): Promise<any> => {

export const OrderService = {
getOrder,
getRerouteOrderBrokeringHistory,
getRerouteOrderFacilityChangeHistory,
updateShippingAddress,
updatePickupFacility,
cancelOrderItem,
Expand Down
10 changes: 4 additions & 6 deletions src/views/Order.vue
Original file line number Diff line number Diff line change
Expand Up @@ -346,16 +346,14 @@ export default defineComponent({
let originFacilityName = "", resp;

try {
resp = await OrderService.getRerouteOrderBrokeringHistory({ "token": this.token })
resp = await OrderService.getRerouteOrderFacilityChangeHistory({ "token": this.token, facilityId: "PICKUP_REJECTED" })

if(!hasError(resp) && resp.data?.brokeringHistory.length) {
const oldestBrokeringHistory = resp.data.brokeringHistory.reduce((oldest: any, current: any) => {
return current.changeDatetime < oldest.changeDatetime ? current : oldest;
ymaheshwari1 marked this conversation as resolved.
Show resolved Hide resolved
});
if(!hasError(resp) && resp.data?.facilityChangeHistory?.length) {
const fromFacilityId = resp.data.facilityChangeHistory[0]?.fromFacilityId

resp = await FacilityService.getStores({
"viewSize": process.env.VUE_APP_VIEW_SIZE,
"filters": [`storeCode: ${oldestBrokeringHistory.facilityId}`]
"filters": [`storeCode: ${fromFacilityId}`]
})

if(!hasError(resp) && resp.data.response.numFound) {
Expand Down
Loading