Skip to content

Commit 63b1d68

Browse files
fix promotions behavior and texts
1 parent 3c2e790 commit 63b1d68

8 files changed

Lines changed: 32 additions & 11 deletions

File tree

CHANGELOG.md

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,17 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
77

88
## [Unreleased]
99

10+
### Fixed
11+
12+
- Promotional prices not being preserved when creating quotes
13+
- Items with promotional price of $0.00 not being included in quotes
14+
- Large currency values (>9,999.99) being truncated in Total and Quoted Price columns
15+
- Unit Multiplier column width adjusted to prevent text truncation
16+
17+
### Changed
18+
19+
- Updated "U. Mult." label to "Multiplicador de Unidade" (PT), "Unit Multiplier" (EN), and "Multiplicador de Unidad" (ES) for better readability
20+
1021
## [3.0.4] - 2026-01-06
1122

1223
### Added

messages/en.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@
7070
"store/b2b-quotes.quote-details.items.refId.title": "Ref. Code",
7171
"store/b2b-quotes.quote-details.items.name.title": "Name",
7272
"store/b2b-quotes.quote-details.items.quantity.title": "Quantity",
73-
"store/b2b-quotes.quote-details.items.unitMultiplier.title": "U. Mult.",
73+
"store/b2b-quotes.quote-details.items.unitMultiplier.title": "Unit Multiplier",
7474
"store/b2b-quotes.quote-details.items.price.title": "Price",
7575
"store/b2b-quotes.quote-details.items.total.title": "Total",
7676
"store/b2b-quotes.quote-details.apply-discount.title": "Apply Percentage Discount",

messages/es.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@
7070
"store/b2b-quotes.quote-details.items.refId.title": "Cód. de ref.",
7171
"store/b2b-quotes.quote-details.items.name.title": "Nombre",
7272
"store/b2b-quotes.quote-details.items.quantity.title": "Cantidad",
73-
"store/b2b-quotes.quote-details.items.unitMultiplier.title": "U. Mult.",
73+
"store/b2b-quotes.quote-details.items.unitMultiplier.title": "Multiplicador de Unidad",
7474
"store/b2b-quotes.quote-details.items.price.title": "Precio",
7575
"store/b2b-quotes.quote-details.items.total.title": "Total",
7676
"store/b2b-quotes.quote-details.apply-discount.title": "Aplicar descuento porcentual",

messages/pt.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@
7070
"store/b2b-quotes.quote-details.items.refId.title": "Código de ref.",
7171
"store/b2b-quotes.quote-details.items.name.title": "Nome",
7272
"store/b2b-quotes.quote-details.items.quantity.title": "Quantidade",
73-
"store/b2b-quotes.quote-details.items.unitMultiplier.title": "U. Mult.",
73+
"store/b2b-quotes.quote-details.items.unitMultiplier.title": "Multiplicador de Unidade",
7474
"store/b2b-quotes.quote-details.items.price.title": "Preço",
7575
"store/b2b-quotes.quote-details.items.total.title": "Total",
7676
"store/b2b-quotes.quote-details.apply-discount.title": "Aplicar desconto percentual",

react/components/OrganizationAndCostCenterFilter.tsx

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -228,7 +228,8 @@ const OrganizationAndCostCenterFilter = ({
228228
const onChangeOrganization = useCallback((value: string) => {
229229
setOrgState(value)
230230
setCostCenterState('')
231-
}, [])
231+
onChange({ organizationId: value, costCenterId: '' })
232+
}, [onChange])
232233

233234
const onChangeCostCenter = useCallback(
234235
(value: string) => {
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
/* Fix currency overflow for large values in total column */
2+
.quoteTable :global(.vtex-format-currency-2-x-currencyContainer),
3+
.quoteTable :global([class*='currencyContainer']) {
4+
white-space: nowrap;
5+
overflow: visible;
6+
}

react/components/QuoteDetails/QuoteTable.tsx

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,8 @@ import { itemDiscountEligible } from '../../utils/helpers'
1616
import { quoteMessages, statusMessages } from '../../utils/messages'
1717
import { LabelByStatusMap } from '../../utils/status'
1818

19+
import styles from './QuoteTable.css'
20+
1921
const QuoteTable = ({
2022
isNewQuote,
2123
quoteState,
@@ -55,6 +57,7 @@ const QuoteTable = ({
5557
<Table
5658
totalizers={totalizers}
5759
fullWidth
60+
className={styles.quoteTable}
5861
schema={{
5962
properties: {
6063
imageUrl: {
@@ -118,7 +121,7 @@ const QuoteTable = ({
118121
sellingPrice: {
119122
title: formatMessage(quoteMessages.quotePrice),
120123
headerRight: true,
121-
width: 120,
124+
width: 150,
122125
cellRenderer: ({
123126
cellData: sellingPrice,
124127
rowData: { id: itemId, listPrice, error },
@@ -177,7 +180,7 @@ const QuoteTable = ({
177180
unitMultiplier: {
178181
title: formatMessage(quoteMessages.unitMultiplier),
179182
headerRight: true,
180-
width: 80,
183+
width: 180,
181184
cellRenderer: ({ rowData: { id } }: any) => {
182185
const hasMultipliers =
183186
unitMultipliers && Object.keys(unitMultipliers).length > 0
@@ -203,7 +206,7 @@ const QuoteTable = ({
203206
: ''
204207

205208
return (
206-
<span className="tr w-100">
209+
<div className="tr w-100">
207210
<FormattedCurrency
208211
value={
209212
rowData.sellingPrice
@@ -212,10 +215,10 @@ const QuoteTable = ({
212215
: 0
213216
}
214217
/>
215-
</span>
218+
</div>
216219
)
217220
},
218-
width: 100,
221+
width: 150,
219222
},
220223
},
221224
}}

react/utils/helpers.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,12 +14,12 @@ export const initQuoteFromOrderForm = (orderForm: any) => {
1414

1515
if (existingItem) {
1616
existingItem.quantity += item.quantity
17-
} else if (item.sellingPrice !== 0) {
17+
} else {
1818
quoteItems.push({
1919
...item,
2020
listPrice: item.listPrice * 100,
2121
price: item.price * 100,
22-
sellingPrice: item.price * 100,
22+
sellingPrice: item.sellingPrice * 100,
2323
})
2424
}
2525
})

0 commit comments

Comments
 (0)