/** * functions and constants which helps to build * nextjs or react router dom navigation operations * for an entity. */ export const PaymentRequestNavigationTools = { edit(uniqueId: string, locale?: string) { return `${locale ? "/" + locale : ""}/payment-request/edit/${uniqueId}`; }, create(locale?: string) { return `${locale ? "/" + locale : ""}/payment-request/new`; }, single(uniqueId: string, locale?: string) { return `${locale ? "/" + locale : ""}/payment-request/${uniqueId}`; }, query(params: any = {}, locale?: string) { return `${locale ? "/" + locale : ""}/payment-requests`; }, /** * Use R series while building router in CRA or nextjs, or react navigation for react Native * Might be useful in Angular as well. **/ Redit: "payment-request/edit/:uniqueId", Rcreate: "payment-request/new", Rsingle: "payment-request/:uniqueId", Rquery: "payment-requests", };