평가로직 오류 수정
This commit is contained in:
@@ -45,15 +45,17 @@ export function hydrateStrategyDto(strategy: StrategyDto): StrategyDto {
|
||||
if (!layout) return next;
|
||||
|
||||
try {
|
||||
const buyState = decodeConditionForEditor(buy);
|
||||
const sellState = decodeConditionForEditor(sell);
|
||||
const normalizedBuy = asLogicNode(next.buyCondition);
|
||||
const normalizedSell = asLogicNode(next.sellCondition);
|
||||
const buyState = decodeConditionForEditor(normalizedBuy);
|
||||
const sellState = decodeConditionForEditor(normalizedSell);
|
||||
const encodedBuy = encodeConditionForSave(buyState);
|
||||
const encodedSell = encodeConditionForSave(sellState);
|
||||
if (encodedBuy || encodedSell) {
|
||||
next = {
|
||||
...next,
|
||||
buyCondition: encodedBuy ?? buy ?? undefined,
|
||||
sellCondition: encodedSell ?? sell ?? undefined,
|
||||
buyCondition: encodedBuy ?? normalizedBuy ?? undefined,
|
||||
sellCondition: encodedSell ?? normalizedSell ?? undefined,
|
||||
};
|
||||
}
|
||||
} catch {
|
||||
|
||||
Reference in New Issue
Block a user