[st] chore: 검증 결과 상태 값 추가
This commit is contained in:
@@ -125,9 +125,22 @@ const RegionalGrid: React.FC<RegionalGridProps> = ({
|
||||
}
|
||||
}
|
||||
|
||||
const mapOtlrToLabel = (otlrYn: string) => {
|
||||
switch (otlrYn) {
|
||||
case "0":
|
||||
return "정상";
|
||||
case "1":
|
||||
return "이상치";
|
||||
case "2":
|
||||
return "제외";
|
||||
default:
|
||||
return "";
|
||||
}
|
||||
};
|
||||
|
||||
const mappedData = data.map((item) => ({
|
||||
...item,
|
||||
otlrYn: item.otlrYn === "0" ? "정상" : "이상치",
|
||||
otlrYn: mapOtlrToLabel(item.otlrYn),
|
||||
}));
|
||||
|
||||
setGridRowData(
|
||||
|
||||
Reference in New Issue
Block a user