gijgo icon indicating copy to clipboard operation
gijgo copied to clipboard

rowdatachanged in detailedexpand?

Open raufozturk opened this issue 6 years ago • 4 comments

Hi,

i try to update the detailed inline table, but the grid.on is not called? Can you help?

$(document).ready(function () { grid = $('#grid').grid({ dataSource: { url: '/crm/?section=operasyon&act=get_takip' }, uiLibrary: 'bootstrap4', locale: 'tr-tr', autoLoad: true, primaryKey: 'id', //fixedHeader: true, height: 500, inlineEditing: { mode: 'command',managementColumn: false },

		columns: [ 
        { field: 'personel_id', title: 'Personel',width:180},
		{ width: 100, align: 'center', renderer: editManager }
		],
		detailTemplate: '<div><table/></div>',
        pager: { limit: 5 }
		});
		
		grid.on('detailExpand', function (e, $detailWrapper, id) {
			$detailWrapper.find('table').grid({
			params: { parent_id: id },
			dataSource: '/crm/?section=operasyon&act=get_durus2',
			primaryKey: 'id',
			inlineEditing: { mode: 'command',managementColumn: false },
			columns: [ 
			{ field: 'personel_id', title: 'Personel'},
			{ width: 100, align: 'center', renderer: editManager }
			], 
			pager: { limit: 5 }
			});
        });
		
		grid.on('rowDataChanged', function (e, $detailWrapper, id, record) {
		alert('update');
            var data = $.extend(true, {}, record);
            $.ajax({ url: '/crm/?section=operasyon&act=update_durus', data: { record: data }, method: 'POST' })
                .fail(function () {
                    alert('Güncelleme hatası, tekrar deneyin!');
                });
        });

raufozturk avatar Oct 30 '19 20:10 raufozturk

Merhba locale: 'tr-tr' sizde çalışıyor mu ? bende console da hata veriyor

sak1065 avatar May 01 '20 14:05 sak1065

Merhba locale: 'tr-tr' sizde çalışıyor mu ? bende console da hata veriyor

evet çalışıyor.

raufozturk avatar May 01 '20 14:05 raufozturk

bir js var ama nasıl uygulayacağım yardımcı olur musun

https://github.com/atatanasov/gijgo/pull/384/commits/322bd4e335fa04bce436489700da136f511a1ff2

sak1065 avatar May 01 '20 14:05 sak1065

bir js var ama nasıl uygulayacağım yardımcı olur musun

322bd4e

./js/gijgo.js ./js/messages/messages.tr-tr.js

bendeki yapı bu şekilde.

raufozturk avatar May 01 '20 15:05 raufozturk