tui-grid-color 자바 상수 생성해서 사용

dev
박성영 2 months ago
parent 478584a4eb
commit cebbcb5f6c

@ -0,0 +1,27 @@
package egovframework.constant;
/**
* packageName : egovframework.constant
* fileName : TuiGridColorConstants
* author :
* date : 2025-10-21
* description : TUI Grid / CSS
* : TUI Grid _attributes.className.row CSS
* .
* ===========================================================
* DATE AUTHOR NOTE
* -----------------------------------------------------------
* 2025-10-21 (tui-grid-custom-color* )
*/
public class TuiGridColorConstants {
// 공통: 그리드 행 배경색 지정용 CSS 클래스명 (xit-tui-grid.css 참고)
public static final String ROW_COLOR_RED = "tui-grid-custom-color-red";
public static final String ROW_COLOR_BLUE = "tui-grid-custom-color-blue";
public static final String ROW_COLOR_GRAY = "tui-grid-custom-color-gray";
public static final String ROW_COLOR_WHITE = "tui-grid-custom-color-white";
private TuiGridColorConstants() {
// 유틸 상수 클래스 - 인스턴스화 방지
}
}

@ -1,6 +1,7 @@
package go.kr.project.crdn.crndRegistAndView.main.service.impl;
import egovframework.constant.ImpltTaskSeConstants;
import egovframework.constant.TuiGridColorConstants;
import egovframework.exception.MessageException;
import egovframework.util.SessionUtil;
import egovframework.util.StringUtil;
@ -292,9 +293,9 @@ public class CrdnImpltTaskServiceImpl extends EgovAbstractServiceImpl implements
List<String> rowClass = new ArrayList<>();
if (actNo % 2 == 0) {
rowClass.add("tui-grid-custom-color-red");
rowClass.add(TuiGridColorConstants.ROW_COLOR_RED);
} else {
rowClass.add("tui-grid-custom-color-blue");
rowClass.add(TuiGridColorConstants.ROW_COLOR_BLUE);
}
className.put("row", rowClass);
attributes.put("className", className);

@ -1,5 +1,6 @@
package go.kr.project.levy.levyRelevy.service.impl;
import egovframework.constant.TuiGridColorConstants;
import egovframework.exception.MessageException;
import go.kr.project.crdn.crndRegistAndView.main.model.CrdnRelevyVO;
import go.kr.project.crdn.crndRegistAndView.main.service.CrdnRelevyService;
@ -64,7 +65,7 @@ public class LevyRelevyServiceImpl extends EgovAbstractServiceImpl implements Le
Map<String, Object> className = new HashMap<>();
List<String> rowClass = new ArrayList<>();
rowClass.add("tui-grid-custom-color-red");
rowClass.add(TuiGridColorConstants.ROW_COLOR_RED);
className.put("row", rowClass);
attributes.put("className", className);
item.set_attributes(attributes);

@ -1,5 +1,6 @@
package go.kr.project.noti.service.impl;
import egovframework.constant.TuiGridColorConstants;
import go.kr.project.noti.mapper.NotiMapper;
import go.kr.project.noti.model.NotiImpltInfoVO;
import go.kr.project.noti.model.NotiImpltTrprInfoVO;
@ -84,9 +85,9 @@ public class NotiServiceImpl extends EgovAbstractServiceImpl implements NotiServ
// 그룹 인덱스의 홀/짝에 따라 색상 클래스 적용
if (currentGroupIndex % 2 == 0) {
rowClass.add("tui-grid-custom-color-blue");
rowClass.add(TuiGridColorConstants.ROW_COLOR_BLUE);
} else {
rowClass.add("tui-grid-custom-color-red");
rowClass.add(TuiGridColorConstants.ROW_COLOR_RED);
}
className.put("row", rowClass);

Loading…
Cancel
Save