Skip to content

Regarding user order creation date. #209

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

Closed
SundramSinghDev opened this issue May 16, 2025 · 3 comments
Closed

Regarding user order creation date. #209

SundramSinghDev opened this issue May 16, 2025 · 3 comments
Labels
Bug Something isn't working untriaged The issue has not yet been checked by the team

Comments

@SundramSinghDev
Copy link

What area is the issue related to?

Storefront API

What version of the package are you using?

com.shopify.mobilebuysdk:buy3:2025.1.0

Reproducible sample code

I am using customer.orders query and in the order I am accessing processedAt() to represent the order processed date but why I am getting latest order date on the all of the order.

fun getOrderList(
    accesstoken: String?, cursor: String, directive: List<InContextDirective>? = null,first:Int=10
): QueryRootQuery {

    return query(directive) { root ->
        root.customer(
            accesstoken
        ) { customer ->
            customer.orders({ args -> order_list(args, cursor,first) }, { order ->
                order.nodes({ n -> n.processedAt() }).edges({ edge ->
                    edge.cursor().node({ ordernode ->
                        ordernode.customerUrl().statusUrl().name().processedAt()
                            .orderNumber().fulfillmentStatus().canceledAt()
                            .cancelReason().financialStatus()
                            .discountApplications({ discountApplicationConnection ->
                                discountApplicationConnection.first(10)
                            }, { discountApplicationEdge ->
                                discountApplicationEdge.nodes { discountApplication ->
                                    discountApplication
                                        .onAutomaticDiscountApplication { automaticDiscountApplication ->
                                            automaticDiscountApplication.title()
                                                .value { value ->
                                                    value.onMoneyV2 { moneyV2 ->
                                                        moneyV2.amount().currencyCode()
                                                    }
                                                }
                                        }
                                        .onManualDiscountApplication { manualDiscountApplication ->
                                            manualDiscountApplication.title().value { value ->
                                                value.onMoneyV2 { moneyV2 ->
                                                    moneyV2.amount().currencyCode()
                                                }
                                                    .onPricingPercentageValue { pricingPercentageValue ->
                                                        pricingPercentageValue.percentage()
                                                    }
                                            }
                                        }
                                        .onScriptDiscountApplication { scriptDiscountApplication ->
                                            scriptDiscountApplication.title().value { value ->
                                                value.onMoneyV2 { moneyV2 ->
                                                    moneyV2.amount().currencyCode()
                                                }
                                                    .onPricingPercentageValue { pricingPercentageValue ->
                                                        pricingPercentageValue.percentage()
                                                    }
                                            }
                                        }
                                        .onDiscountCodeApplication { discountCodeApplication ->
                                            discountCodeApplication.code().value { value ->
                                                value.onMoneyV2 { moneyV2 ->
                                                    moneyV2.amount().currencyCode()
                                                }
                                                    .onPricingPercentageValue { pricingPercentageValue ->
                                                        pricingPercentageValue.percentage()
                                                    }
                                            }
                                        }
                                        .value { discountValue ->
                                            discountValue.onMoneyV2 { moneyV2 ->
                                                moneyV2.amount()
                                                moneyV2.currencyCode()
                                            }
                                            discountValue.onPricingPercentageValue { pricingPercentageValue ->
                                                pricingPercentageValue.percentage()
                                            }
                                        }
                                }
                            })
                            .shippingDiscountAllocations() { disocunt ->
                                disocunt.allocatedAmount { it ->
                                    it.amount().currencyCode()
                                }
                            }
                            .totalRefunded() { _queryBuilder ->
                                _queryBuilder.amount().currencyCode()
                            }.email().phone().totalPrice { _queryBuilder ->
                                _queryBuilder.amount().currencyCode()
                            }
                                .shippingAddress { _queryBuilder ->
                                _queryBuilder.address1().address2().city()
                                    .company().country().firstName().lastName()
                                    .phone().zip().latitude().longitude()
                            }.totalShippingPrice { _queryBuilder ->
                                _queryBuilder.currencyCode().amount()
                            }.totalTax { _queryBuilder ->
                                _queryBuilder.amount().currencyCode()
                            }.subtotalPrice { _queryBuilder ->
                                _queryBuilder.amount().currencyCode()
                            }.lineItems({ arg -> arg.first(150) }, { item ->
                                item.edges({ itemedge ->
                                    itemedge.node({ n ->
                                        n.customAttributes { customAttributes ->
                                            customAttributes.key().value()
                                        }.title().quantity()
                                            .originalTotalPrice { originalPrice ->
                                                originalPrice.amount().currencyCode()
                                            }
                                            .variant({ v ->
                                                v.product {}
                                                v.price({ p ->
                                                    p.amount()
                                                        .currencyCode()
                                                })
                                                    .selectedOptions({ select ->
                                                        select.name()
                                                            .value()
                                                    })
                                                    .compareAtPrice({ c ->
                                                        c.amount()
                                                            .currencyCode()
                                                    }).image({ image ->
                                                        image.url({ t ->
                                                            t.transform(
                                                                Constant.imageConfiguration("order_list")
                                                            )
                                                        }).width().height()
                                                    })

// .image(Storefront.ImageQueryDefinition { it.url() })
})
})
})
}).shippingAddress({ ship ->
ship.address1().address2().firstName()
.lastName().country().city().phone()
.province().zip()
})

                    })
                }).pageInfo(Storefront.PageInfoQueryDefinition {
                    it.hasNextPage().startCursor().endCursor()
                })
            })
        }
    }
}

Steps to Reproduce

place multiple orders and check the date of the order

Expected Behavior

It should give every processed order date(when order is placed or created).

Actual Behavior

Right now it is giving me same order process date on each order.

Screenshots/Videos/Log output

No response

Storefront domain

https://home-run.co/

@SundramSinghDev SundramSinghDev added Bug Something isn't working untriaged The issue has not yet been checked by the team labels May 16, 2025
@SundramSinghDev
Copy link
Author

Hey

@kieran-osgood-shopify
Copy link

@SundramSinghDev - This issue seems related to the mobile-buy-sdk-android repository more so than checkout-sheet-kit-android - I took a look and there appears to be an issue similar to yours: Shopify/mobile-buy-sdk-android#773 - for the moment downgrading to 18.1.0 may be a possible fix

Thanks for raising - will get this looked into over there, but for now I'll close this issue in this repo

@SundramSinghDev
Copy link
Author

SundramSinghDev commented Jun 6, 2025

Do we have another solution rather than downgrading the version @kieran-osgood-shopify

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Something isn't working untriaged The issue has not yet been checked by the team
Projects
None yet
Development

No branches or pull requests

2 participants