---------------------------------------------------------------------------------------------------------------------------------------------------------------
1 . trustForm
화일 이름 : D:\Workspace\Project\ALP\ALP_GSW\WebSource\xfm\test\test.xfm
---------------------------------------------------------------------------------------------------------------------------------------------------------------
2. actionInfo
화일이름 : D:\Workspace\Project\ALP\ALP_GSW\Config\AS_VHRP_serviceinfo.xml
---------------------------------------------------------------------------------------------------------------------------------------------------------------
3. Facade
화일이름 : D:\Workspace\Project\ALP\ALP_GSW\JavaSource\alp\as\hkmc\vhrp\service\GrnRoWorkInpFacade.java
public RoListCdto[] selectRoList(String startDt, String endDt, AdminSessionInfo baseInfo) throws BizException {
LogonInfo logonInfo = LoginHelper.getLogonInfo(baseInfo);
return GrnRoWorkInp.getInstance().selectRoList(startDt, endDt, logonInfo);
}
---------------------------------------------------------------------------------------------------------------------------------------------------------------
4. biz
화일이름 : D:\Workspace\Project\ALP\ALP_GSW\JavaSource\alp\as\hkmc\vhrp\service\GrnRoWorkInp.java
public RoListCdto[] selectRoList(String startDt, String endDt, LogonInfo logonInfo) throws BizException {
return GrnRoMainDao.selectRoList(startDt, endDt, logonInfo);
}
---------------------------------------------------------------------------------------------------------------------------------------------------------------
5. dao( DAO )
화일이름 : D:\Workspace\Project\ALP\ALP_GSW\JavaSource\alp\as\hkmc\vhrp\dao\GrnRoMainDao.java
public static RoListCdto[] selectRoList(String startDt, String endDt, LogonInfo logonInfo) throws BizException {
RoListCdto[] resArrCdto = null;
PreparedStatementWrapper psw = null;
try {
StringBuffer sql = new StringBuffer();
sql.append("\n select ASN_CD ");
sql.append("\n ,RO_NO ");
sql.append("\n ,VIN ");
sql.append("\n ,CSMR_NM ");
sql.append("\n ,I_CDT ");
sql.append("\n from t_ro_info ");
sql.append("\n WHERE ASN_CD = ? ");
sql.append("\n AND i_cdt between ? and ? ");
psw = new PreparedStatementWrapper(logonInfo.getCoScnCd() + AsConstants.DATA_SOURCE_NAME, sql.toString());
int index = 1;
psw.setString(index++,"MA0D96");
psw.setString(index++,startDt);
psw.setString(index++, endDt);
DBManager db = new DBManager();
List dbData = db.selectList(psw, RoListCdto.class.getName());
if(dbData.size() > 0) {
resArrCdto = (RoListCdto[]) dbData.toArray(new RoListCdto[dbData.size()]);
}
} catch(SQLException se) {
logger.error(se.getMessage());
throw new BizException(AsConstants.SYSTEM_ID, "AS0001");
} finally {
if(psw != null)
psw.release();
}
return resArrCdto;
}
---------------------------------------------------------------------------------------------------------------------------------------------------------------
6. dto( VO )
화일이름 : D:\Workspace\Project\ALP\ALP_GSW\JavaSource\alp\as\hkmc\vhrp\dto\RoListCdto.java
---------------------------------------------------------------------------------------------------------------------------------------------------------------
7. jsp
화일이름 : D:\Workspace\Project\ALP\ALP_GSW\WebSource\jsp\test_selectRoList.jsp
<%--
***************************************************************************************************
* JSP 페이지 태그 선언
***************************************************************************************************
--%>
<%@page contentType="text/xml; charset=EUC-KR"%>
<%@page import="alp.as.hkmc.vhrp.dto.RoListCdto"%>
<%@page import="alp.as.hkmc.util.XmlGenHelper"%>
<%@page import="com.ebstorm.jframework.foundation.message.MsgParameter"%>
<%--
***************************************************************************************************
* 변수 선언 및 선행 로직
***************************************************************************************************
--%>
<%
XmlGenHelper xml = new XmlGenHelper(0);
try {
//메소드 이름을 작성합니다.
RoListCdto[] result = (RoListCdto[]) request.getAttribute("test_selectRoList");
// 컬럼 이름 작성(반환받는 곳의 이름)
String[] column = {
"asnCd"
,"roNo"
,"vin"
,"csmrNm"
,"iCdt"
};
// 노드 스트림의 위치를 작성합니다.
int pNode = xml.add (0, "res", "");
//소스가 있는 곳을 작성합니다.
xml.setSourceClassName("alp.as.hkmc.vhrp.dto.RoListCdto");
xml.genXml(pNode, "grid", column, result);
MsgParameter param = new MsgParameter();
param.add( result.length );
xml.setMessage("AS0002", param);
} catch (Exception e) {
e.printStackTrace();
} finally {
out.println(xml.getXmlString());
}
%>
'트러스트폼' 카테고리의 다른 글
티폼 기능 실사용 정리 (0) | 2012.09.27 |
---|---|
티폼 datagrid 의 일부 컬럼 값이 빈경우 삭제 하기 (0) | 2012.09.26 |
트러스트폼 이벤트 (0) | 2012.07.12 |
트러스트폼 버튼 엑션(늘리고 줄이고) (0) | 2012.07.12 |
트러스트폼 단축키 (0) | 2012.07.12 |