Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
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
10 changes: 8 additions & 2 deletions node/clients/mail.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,11 @@
import type { InstanceOptions, IOContext } from '@vtex/api'
import { JanusClient } from '@vtex/api'

import type { MailData, Template } from '../typings/mailClient'
import type {
StatusUpdateMailData,
ConfirmationMailData,
Template,
} from '../typings/mailClient'

const MAIL_SERVICE_PATH = '/api/mail-service/pvt/sendmail'
const TEMPLATE_RENDER_PATH = '/api/template-render/pvt/templates'
Expand All @@ -16,7 +20,9 @@ export class MailClient extends JanusClient {
})
}

public sendMail(mailData: MailData): Promise<string> {
public sendMail(
mailData: StatusUpdateMailData | ConfirmationMailData
): Promise<string> {
return this.http.post(MAIL_SERVICE_PATH, mailData, {
metric: 'mail-post-send',
})
Expand Down
3 changes: 2 additions & 1 deletion node/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,12 @@
"tslint": "^6.1.3",
"tslint-config-vtex": "^2.1.0",
"vtex.css-handles": "http://vtex.vtexassets.com/_v/public/typings/v1/vtex.css-handles@0.4.4/public/@types/vtex.css-handles",
"vtex.easypost": "http://vtex.vtexassets.com/_v/public/typings/v1/vtex.easypost@0.1.1/public/@types/vtex.easypost",
"vtex.format-currency": "http://vtex.vtexassets.com/_v/public/typings/v1/vtex.format-currency@0.4.1/public/@types/vtex.format-currency",
"vtex.my-account": "http://vtex.vtexassets.com/_v/public/typings/v1/vtex.my-account@1.25.0/public/@types/vtex.my-account",
"vtex.my-account-commons": "http://vtex.vtexassets.com/_v/public/typings/v1/vtex.my-account-commons@1.6.0/public/@types/vtex.my-account-commons",
"vtex.render-runtime": "http://vtex.vtexassets.com/_v/public/typings/v1/vtex.render-runtime@8.132.4/public/@types/vtex.render-runtime",
"vtex.return-app": "https://rmav3requestlistendpoint--powerplanet.myvtex.com/_v/private/typings/linked/v1/vtex.return-app@3.0.0-beta.9+build1657923944/public/@types/vtex.return-app",
"vtex.return-app": "https://performance--powerplanet.myvtex.com/_v/private/typings/linked/v1/vtex.return-app@3.0.0-beta.10+build1658662160/public/@types/vtex.return-app",
"vtex.store-graphql": "http://vtex.vtexassets.com/_v/public/typings/v1/vtex.store-graphql@2.152.2/public/@types/vtex.store-graphql",
"vtex.styleguide": "http://vtex.vtexassets.com/_v/public/typings/v1/vtex.styleguide@9.146.1/public/@types/vtex.styleguide",
"vtex.tenant-graphql": "http://vtex.vtexassets.com/_v/public/typings/v1/vtex.tenant-graphql@0.1.2/public/@types/vtex.tenant-graphql"
Expand Down
10 changes: 7 additions & 3 deletions node/yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -6147,6 +6147,10 @@ verror@1.10.0:
version "0.4.4"
resolved "http://vtex.vtexassets.com/_v/public/typings/v1/vtex.css-handles@0.4.4/public/@types/vtex.css-handles#8c45c6decf9acd2b944e07261686decff93d6422"

"vtex.easypost@http://vtex.vtexassets.com/_v/public/typings/v1/vtex.easypost@0.1.1/public/@types/vtex.easypost":
version "0.1.1"
resolved "http://vtex.vtexassets.com/_v/public/typings/v1/vtex.easypost@0.1.1/public/@types/vtex.easypost#078a135b63bb4fc5e39e6ad789d0caf9ea368f35"

"vtex.format-currency@http://vtex.vtexassets.com/_v/public/typings/v1/vtex.format-currency@0.4.1/public/@types/vtex.format-currency":
version "0.4.1"
resolved "http://vtex.vtexassets.com/_v/public/typings/v1/vtex.format-currency@0.4.1/public/@types/vtex.format-currency#aaed82b498270f0bb6f37e93eff7e7f401e4d283"
Expand All @@ -6163,9 +6167,9 @@ verror@1.10.0:
version "8.132.4"
resolved "http://vtex.vtexassets.com/_v/public/typings/v1/vtex.render-runtime@8.132.4/public/@types/vtex.render-runtime#66bb41bd4d342e37c9d85172aad5f7eefebfb6dc"

"vtex.return-app@https://rmav3requestlistendpoint--powerplanet.myvtex.com/_v/private/typings/linked/v1/vtex.return-app@3.0.0-beta.9+build1657923944/public/@types/vtex.return-app":
version "3.0.0-beta.9"
resolved "https://rmav3requestlistendpoint--powerplanet.myvtex.com/_v/private/typings/linked/v1/vtex.return-app@3.0.0-beta.9+build1657923944/public/@types/vtex.return-app#f2851456ef58a2e3165b2fe3ff9bdfc2a2816f99"
"vtex.return-app@https://performance--powerplanet.myvtex.com/_v/private/typings/linked/v1/vtex.return-app@3.0.0-beta.10+build1658662160/public/@types/vtex.return-app":
version "3.0.0-beta.10"
resolved "https://performance--powerplanet.myvtex.com/_v/private/typings/linked/v1/vtex.return-app@3.0.0-beta.10+build1658662160/public/@types/vtex.return-app#4c77d0131bd0d51852fbe32de1b1abde4f58ab5c"

"vtex.store-graphql@http://vtex.vtexassets.com/_v/public/typings/v1/vtex.store-graphql@2.152.2/public/@types/vtex.store-graphql":
version "2.152.2"
Expand Down
3 changes: 2 additions & 1 deletion react/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,12 @@
"@vtex/tsconfig": "^0.6.0",
"prop-types": "^15.7.2",
"vtex.css-handles": "http://vtex.vtexassets.com/_v/public/typings/v1/vtex.css-handles@0.4.4/public/@types/vtex.css-handles",
"vtex.easypost": "http://vtex.vtexassets.com/_v/public/typings/v1/vtex.easypost@0.1.1/public/@types/vtex.easypost",
"vtex.format-currency": "http://vtex.vtexassets.com/_v/public/typings/v1/vtex.format-currency@0.4.1/public/@types/vtex.format-currency",
"vtex.my-account": "http://vtex.vtexassets.com/_v/public/typings/v1/vtex.my-account@1.25.0/public/@types/vtex.my-account",
"vtex.my-account-commons": "http://vtex.vtexassets.com/_v/public/typings/v1/vtex.my-account-commons@1.6.0/public/@types/vtex.my-account-commons",
"vtex.render-runtime": "http://vtex.vtexassets.com/_v/public/typings/v1/vtex.render-runtime@8.132.4/public/@types/vtex.render-runtime",
"vtex.return-app": "https://rmav3requestlistendpoint--powerplanet.myvtex.com/_v/private/typings/linked/v1/vtex.return-app@3.0.0-beta.9+build1657923944/public/@types/vtex.return-app",
"vtex.return-app": "https://performance--powerplanet.myvtex.com/_v/private/typings/linked/v1/vtex.return-app@3.0.0-beta.10+build1658662160/public/@types/vtex.return-app",
"vtex.store-graphql": "http://vtex.vtexassets.com/_v/public/typings/v1/vtex.store-graphql@2.152.2/public/@types/vtex.store-graphql",
"vtex.styleguide": "http://vtex.vtexassets.com/_v/public/typings/v1/vtex.styleguide@9.146.1/public/@types/vtex.styleguide",
"vtex.tenant-graphql": "http://vtex.vtexassets.com/_v/public/typings/v1/vtex.tenant-graphql@0.1.2/public/@types/vtex.tenant-graphql"
Expand Down
11 changes: 7 additions & 4 deletions react/store/createReturnRequest/components/OrderList.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import React, { useState } from 'react'
import React, { useMemo, useState } from 'react'
import type { OrdersToReturnList, OrderToReturnSummary } from 'vtex.return-app'
import { FormattedMessage, FormattedDate } from 'react-intl'
import { useRuntime } from 'vtex.render-runtime/'
Expand Down Expand Up @@ -90,6 +90,11 @@ export const OrderList = ({ orders, handlePagination }: Props) => {
'IDLE'
)

const orderlListTableSchema = useMemo(
() => OrderlListTableSchema({ navigate }),
[navigate]
)

const { paging } = orders
const currentPage = paging?.currentPage ?? 1
const perPage = paging?.perPage ?? 0
Expand Down Expand Up @@ -118,9 +123,7 @@ export const OrderList = ({ orders, handlePagination }: Props) => {
emptyStateLabel={
<FormattedMessage id="store/return-app.return-order-list.table-empty-state-label.no-orders-available" />
}
schema={OrderlListTableSchema({
navigate,
})}
schema={orderlListTableSchema}
items={orders.list}
loading={fetchMoreState === 'LOADING'}
pagination={{
Expand Down
10 changes: 7 additions & 3 deletions react/yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -5182,6 +5182,10 @@ verror@1.10.0:
version "0.4.4"
resolved "http://vtex.vtexassets.com/_v/public/typings/v1/vtex.css-handles@0.4.4/public/@types/vtex.css-handles#8c45c6decf9acd2b944e07261686decff93d6422"

"vtex.easypost@http://vtex.vtexassets.com/_v/public/typings/v1/vtex.easypost@0.1.1/public/@types/vtex.easypost":
version "0.1.1"
resolved "http://vtex.vtexassets.com/_v/public/typings/v1/vtex.easypost@0.1.1/public/@types/vtex.easypost#078a135b63bb4fc5e39e6ad789d0caf9ea368f35"

"vtex.format-currency@http://vtex.vtexassets.com/_v/public/typings/v1/vtex.format-currency@0.4.1/public/@types/vtex.format-currency":
version "0.4.1"
resolved "http://vtex.vtexassets.com/_v/public/typings/v1/vtex.format-currency@0.4.1/public/@types/vtex.format-currency#aaed82b498270f0bb6f37e93eff7e7f401e4d283"
Expand All @@ -5198,9 +5202,9 @@ verror@1.10.0:
version "8.132.4"
resolved "http://vtex.vtexassets.com/_v/public/typings/v1/vtex.render-runtime@8.132.4/public/@types/vtex.render-runtime#66bb41bd4d342e37c9d85172aad5f7eefebfb6dc"

"vtex.return-app@https://rmav3requestlistendpoint--powerplanet.myvtex.com/_v/private/typings/linked/v1/vtex.return-app@3.0.0-beta.9+build1657923944/public/@types/vtex.return-app":
version "3.0.0-beta.9"
resolved "https://rmav3requestlistendpoint--powerplanet.myvtex.com/_v/private/typings/linked/v1/vtex.return-app@3.0.0-beta.9+build1657923944/public/@types/vtex.return-app#f2851456ef58a2e3165b2fe3ff9bdfc2a2816f99"
"vtex.return-app@https://performance--powerplanet.myvtex.com/_v/private/typings/linked/v1/vtex.return-app@3.0.0-beta.10+build1658662160/public/@types/vtex.return-app":
version "3.0.0-beta.10"
resolved "https://performance--powerplanet.myvtex.com/_v/private/typings/linked/v1/vtex.return-app@3.0.0-beta.10+build1658662160/public/@types/vtex.return-app#4c77d0131bd0d51852fbe32de1b1abde4f58ab5c"

"vtex.store-graphql@http://vtex.vtexassets.com/_v/public/typings/v1/vtex.store-graphql@2.152.2/public/@types/vtex.store-graphql":
version "2.152.2"
Expand Down