fix(tax): Initialize selectedTaxClass when opening Add Tax Rate dialog
Fixed blank screen when clicking "Add Tax Rate" button by initializing selectedTaxClass state to empty string before opening dialog.
This commit is contained in:
@@ -221,7 +221,10 @@ export default function TaxSettings() {
|
||||
action={
|
||||
<Button
|
||||
size="sm"
|
||||
onClick={() => setShowAddRate(true)}
|
||||
onClick={() => {
|
||||
setSelectedTaxClass('');
|
||||
setShowAddRate(true);
|
||||
}}
|
||||
>
|
||||
<Plus className="h-4 w-4 mr-2" />
|
||||
{__('Add Tax Rate')}
|
||||
|
||||
Reference in New Issue
Block a user