diff --git a/src/components/article/boxes/ArticleViewPrice.jsx b/src/components/article/boxes/ArticleViewPrice.jsx
index 0da2659..3a31fff 100644
--- a/src/components/article/boxes/ArticleViewPrice.jsx
+++ b/src/components/article/boxes/ArticleViewPrice.jsx
@@ -201,11 +201,10 @@ class PriceAmountField extends Component {
class PriceDisplay extends Component {
render() {
- const { saved, taxRates, unitOptions, displaySymbol } = this.props;
+ const { saved, unitOptions, displaySymbol } = this.props;
return (
-
onChange({ ...draft, gross })}
error={draft.gross !== '' && draftGross == null}
/>
- onChange({ ...draft, taxRate })}
- onOpenTiers={onOpenTiers}
- />
onChange({ ...draft, unitamount })}
onChangeSi={(unitSi) => onChange({ ...draft, unitSi })}
amountError={
- draft.hasUnit &&
- draft.unitamount !== '' &&
+ draft.hasUnit && draft.unitamount !== '' &&
(draftAmount == null || draftAmount <= 0)
}
/>
onChange({ ...draft, tiers })}
+ open={tiersDialogOpen} tiers={draft.tiers ?? []}
+ onClose={onCloseTiers} onApply={(tiers) => onChange({ ...draft, tiers })}
/>
);
@@ -557,7 +535,32 @@ export default class ArticleViewPrice extends PureComponent {
wide={1}
minHeight={SECOND_ROW_MIN_HEIGHT}
color={BLUE_PANEL}
- title={'€'}
+ titleContent={({ editing, draft, onChange }) => (
+
+
+ €
+
+ onChange({ ...draft, taxRate })
+ : undefined
+ }
+ readOnly={!editing}
+ onOpenTiers={this.openTiersDialog}
+ />
+
+ )}
contentAlignItems="flex-start"
value={priceValue}
onSave={this.handleSave}
@@ -577,7 +580,6 @@ export default class ArticleViewPrice extends PureComponent {
display={
@@ -587,12 +589,10 @@ export default class ArticleViewPrice extends PureComponent {
draft={draft}
onChange={onChange}
inputRef={inputRef}
- taxRates={taxRates}
unitOptions={unitOptions}
displaySymbol={displaySymbol}
tiersDialogOpen={tiersDialogOpen}
unitEditorOpen={unitEditorOpen}
- onOpenTiers={this.openTiersDialog}
onCloseTiers={this.closeTiersDialog}
onCloseUnitEditor={this.closeUnitEditor}
onUnitUpserted={this.refreshUnits}