이 문서는 읽기 전용입니다. 원본을 볼 수는 있지만 바꿀 수는 없습니다. 문제가 있다고 생각하면 관리자에게 문의하세요. ====== 필드 버튼 가이드 ====== 필드성 컴포넌트 버튼 관련 예시화면이다. 필드성 컴포넌트 버튼 관련 기능은 버튼을 눌러서 필드에 값을 설정하기 위한 기능(예: 팝업 표시) 수행하기 위한 용도로 사용된다. 필드성 컴포넌트 button_hidden, button_size, button_image, button_image_disable 속성에 의해서 설정된다. 버튼 클릭시 on_click 이벤트의 buttonclick 파라미터가 true로 전달된다. 필드성 컴포넌트 버튼은 필드의 input_type 및 enable 속성을 기준으로 활성화 상태가 적용된다. 관련 API로 getbuttonhidden, setbuttonhidden가 있다. ===== 예시 ===== 템플릿 위치: /HTML5/COMPONENT/FIELD/field_button 템플릿 파일 * [[xf5projecthome>template/screen/HTML5/COMPONENT/FIELD/field_button.xml|field_button.xml]] * [[xf5projecthome>template/screen/HTML5/COMPONENT/FIELD/field_button.js|field_button.js]] * [[xf5projecthome>template/template.html?xframe_screen_url=/HTML5/COMPONENT/FIELD/field_button|새창으로 실행]] <php> echo '<html>'; echo '<iframe src="'; echo $conf['plugin']['xf5']['xf5projecthome'], 'template/template.html?'; echo 'xframe_screen_url=/HTML5/COMPONENT/FIELD/field_button"'; echo ' class="_xf5_iframe"'; echo ' style="'; echo $conf['plugin']['xf5']['xf5iframestyle']; echo '">'; echo '</iframe>'; echo '</html>'; </php> ==== 화면 스크립트 ==== <sxh javascript> // 필드 클릭 이벤트 function fld_button_event_on_click(objInst, buttonclick) { var mouse_event_pos_info; factory.consoleprint("on_click> Start"); factory.consoleprint("on_click> buttonclick = " + buttonclick); // mouse_event_pos_info 정보에 대한 자세한 내용은 getmouseeventpos API 도움말 참조 mouse_event_pos_info = factory.getmouseeventpos(); } // button_hidden 속성값을 토글로 지정한다. function btn_buttonhidden_on_click(objInst) { var button_hidden; button_hidden = this.fld_buttonhidden_api.getbuttonhidden(); factory.consoleprint("클리어 버튼 보이기/숨김 = " + button_hidden); this.fld_buttonhidden_api.setbuttonhidden(!this.fld_buttonhidden_api.getbuttonhidden()); } </sxh> guide/component/field/field_button.txt 마지막으로 수정됨: 2023/10/25 16:57저자 127.0.0.1