init

init

그리드 기본 설정

Methods

(static) cancelSetting() → {undefined}

부가설정팝업을 취소하고 닫습니다
Example
grid.cancelSetting();
Returns:
Type
undefined

(static) getConfiguration() → {object}

그리드의 설정정보를 반환합니다
Example
grid.getConfiguration();
Returns:
- 사용자가 설정한 그리드의 속성 값
Type
object

(static) getPostData() → {json}

설정된 데이터소스의 파라메터를 가져옵니다
Example
grid.getPostData();
Returns:
Type
json

(static) getSelectedGrid() → {*|null}

선택된 그리드정보를 반환합니다
Example
grid.getSelectedGrid();
Returns:
- 선택된 그리드 정보
Type
* | null

(static) getSetting() → {Array}

부가설정정보를 반환합니다
Example
grid.getSetting();
Returns:
컬럼의 부가설정 정보 배열
Type
Array

(static) getVersion() → {object}

그리드 버전정보를 반환합니다
Example
grid.getVersion();
Returns:
- 그리드의 버전, 빌드날짜 및 시간을 반환
Type
object

(static) removeSelectedGrid() → {undefined}

선택된 그리드 선택해제
Example
grid.removeSelectedGrid();
Returns:
Type
undefined

(static) saveSetting() → {undefined}

부가설정팝업을 저장하고 닫습니다
Example
grid.saveSetting();
Returns:
Type
undefined

(static) setDatasource(urlopt, datatypeopt, methodopt, postDataopt) → {void}

그리드의 통신관련 설정을 합니다.
Example
grid.setDatasource("http://127.0.0.1/dataProvider","json","get",{param1:'1',param2:'2'});
Parameters:
Name Type Attributes Default Description
url string <optional>
데이터를 불러올 url주소
datatype stirng <optional>
json ["json"] 불러올 데이터의 타입. 현재는 json만 지원
method stirng <optional>
get ["get"|"post"] 데이터의 전송방식
postData json <optional>
[{param1:'1',param2:'2'}] 데이터를 불러올 url에 전달할 파라메터.
Returns:
Type
void

(static) setDataType(datatype) → {undefined}

데이터소스의 datatype을 설정합니다
Example
grid.setDataType("json");
Parameters:
Name Type Default Description
datatype string "json" 불러올 데이터의 타입. 현재는 json만 지원
Returns:
Type
undefined

(static) setHeight(height) → {undefined}

그리드의 높이를 변경합니다
Example
grid.setHeight(500);
Parameters:
Name Type Description
height number px단위의 그리드 높이
Returns:
Type
undefined

(static) setMethod(method) → {undefined}

데이터소스의 method를 설정합니다
Example
grid.setMethod("post");
Parameters:
Name Type Default Description
method string "get" 데이터의 전송방식
Returns:
Type
undefined

(static) setPanelText(str) → {undefined}

패널의 텍스트를 설정합니다
Example
grid.setPanelText("호펜 그리드 입니다");
Parameters:
Name Type Description
str string 패널에 표시될 텍스트
Returns:
Type
undefined

(static) setPostData(data) → {undefined}

데이터소스의 파라메터를 설정합니다
Example
grid.setPostData({param1:'1',param2:'2'}); //postdata값 전체를 새로운값으로 설정

//postdata의 page값 조작을 통한 페이지 변경
var changePage = grid.getPostData();
changePage.page=1; //2페이지로 변경
grid.setPostData(changePage);
grid.refresh();
Parameters:
Name Type Description
data json 데이터를 불러올 url에 전달할 파라메터.
Returns:
Type
undefined

(static) setSelectedGrid(gridID) → {*|null}

사용자가 원하는 그리드 선택
Example
grid.setSelectedGrid('gridID');
Parameters:
Name Type Description
gridID string 그리드선언시 사용한 ini.id의 속성값
Returns:
- 선택된 그리드 정보
Type
* | null

(static) setURL(url) → {undefined}

데이터소스의 url을 설정합니다
Example
grid.setURL("http://127.0.0.1:8080/jsondata");
Parameters:
Name Type Description
url string URL
Returns:
Type
undefined

(static) setWidth(width) → {undefined}

그리드의 넓이를 변경합니다
Example
grid.setWidth(500);
Parameters:
Name Type Description
width number px단위의 그리드 넓이
Returns:
Type
undefined