From 4f23fc964c031bed0363388202f71105d4a29c24 Mon Sep 17 00:00:00 2001 From: vchikalkin Date: Wed, 11 Jan 2023 16:17:26 +0300 Subject: [PATCH] =?UTF-8?q?=D0=BF=D0=BE=D0=BF=D1=80=D0=B0=D0=B2=D0=B8?= =?UTF-8?q?=D0=BB=D0=B8=20=D1=81=D0=B1=D1=80=D0=BE=D1=81=20=D1=81=D0=BF?= =?UTF-8?q?=D0=B8=D1=81=D0=BA=D0=B0=20rewardCondition=20=D0=BF=D1=80=D0=B8?= =?UTF-8?q?=20=D0=B7=D0=B0=D0=B3=D1=80=D1=83=D0=B7=D0=BA=D0=B5=20=D1=81?= =?UTF-8?q?=D0=BF=D0=B8=D1=81=D0=BA=D0=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- apps/web/process/supplier-agent/lib/create-reactions.ts | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/apps/web/process/supplier-agent/lib/create-reactions.ts b/apps/web/process/supplier-agent/lib/create-reactions.ts index 281676b..a41bd85 100644 --- a/apps/web/process/supplier-agent/lib/create-reactions.ts +++ b/apps/web/process/supplier-agent/lib/create-reactions.ts @@ -65,6 +65,8 @@ export function fillAgentRewardReaction( $calculation .element(rewardConditionField) .setOptions(normalizeOptions(evo_reward_conditions)); + } else { + $calculation.element(rewardConditionField).reset(); } } ); @@ -125,10 +127,10 @@ export function fillAgentRewardSummReaction( reaction( () => $calculation.element(rewardConditionField).getValue(), (rewardConditionId) => { - if (!rewardConditionId) { - $calculation.element(rewardSummField).block(); - } else { + if (rewardConditionId) { $calculation.element(rewardSummField).unblock(); + } else { + $calculation.element(rewardSummField).block(); } } );