sencha(166)
-
Sencha grid 사용자가 선택했을 때, 이벤트 발생하기
select 이벤트 사용Ext.create('Ext.form.ComboBox', { fieldLabel: 'Choose Item', store: ['Item 1', 'Item 2', 'Item 3'], queryMode: 'local', displayField: 'name', valueField: 'value', renderTo: Ext.getBody(), listeners: { select: function(combo, record, eOpts) { Ext.Msg.alert('Selection', `You selected: ${combo.getValue()}`); } }});값이 변경되었을 때, 이벤트가 발생하기 위..
2025.01.18 -
Sencha grid 내용 복사 가능하게 설정
viewConfig를 통해서 설정함trackOver: false, // Disable row hover effects enableTextSelection: true // Allow text selection in grid cellsExt.create('Ext.grid.Panel', { title: 'Example Grid', store: { fields: ['name', 'email', 'phone'], data: [ { name: 'Lisa', email: 'lisa@simpsons.com', phone: '555-111-1224' }, { name: 'Bart', email: 'bart@simpsons.com', phone: ..
2025.01.18 -
Sencha store의 value에 여러 건이 들어갈 경우 처리
if (value != null && value !== "") { const index = key.replace('search', ''); const keyword = app.getControl('keyword' + index).getValue(); const compare = app.getControl('compare' + index).getValue(); // Add temp to searchParams with key as `value` searchParams.set(value, { keyword: keyword, compare: compare });}
2025.01.15 -
Sencha grid csv 데이터 로딩
tbar: [ { text: 'Load CSV', handler: function() { // Trigger a file input dialog to select a CSV file const fileInput = document.createElement('input'); fileInput.type = 'file'; fileInput.accept = '.csv'; fileInput.onchange = function(event) { const file = event.target.files[0]; if (file) { ..
2025.01.15 -
Sencha grid의 내용 csv로 저장하기
tbar: [ { text: 'Export to CSV', handler: function() { const grid = this.up('grid'); // Get reference to the grid const store = grid.getStore(); // Get the grid's store // Filter columns to exclude those with dataIndex '_$_' const columns = grid.getColumns().filter(column => column.dataIndex !== '_$_'); // Extract column hea..
2025.01.15 -
Sencha grid header filter
const columns = grid.getColumns().filter(column => column.dataIndex !== '_$_');'_$_'는 row의 상태값 컬럼의 header
2025.01.15