[CVW-000] Fix, 가격표현 방식 수정 #63
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
변경된 점
가격표현 방식 수정
기존의 표현의 경우 Fraction자리수의 최대 최소를 지정하고, 자리수 0부터 최대 자리수까지 순회하면서 가장 첫번째로 유효한 값이 등장하면 즉시 순회를 뭠추는 방법을 선택했습니다.
해당 방식의 경우 소수점에 0만 등장하는 경우 1.000000 과 같이 무의미한 표현을 증가시켰고, 1.20323과 같은 값을 1.2로 변경해버려 정보 훼손이 다소 심하게 발생했습니다.
따라서 문자열의 길이를 지정하고 그에 따라 동적으로 소수점 및 unit을 통한 표현 방식을 적용하도록 수정했습니다.
현재 희망하는 문자열 길이를 10으로 설정했습니다.