Our blazing fast Grid component built with pure JavaScript


Post by guillermoxintel »

Hello... as stated on the docs, (https://www.bryntum.com/docs/grid/api/Core/widget/Combo#event-beforeShow)
I should be able to run some preventable async action using the beforeShow event, but is not firing, I did report this before but nobody told me how to resolve this problem, if this is a bug was it resolved in a later version?

Thank you for any help you may bring... Here's my code:

        const phaseStartCombo = new bryntum.grid.Combo({
            displayField: 'textValue',
            valueField: 'id',
            store: phaseStoreModal,
            listeners: {               
beforeShow: (event) => { console.log("beforeShow executed!"); return true; }, action: (event) => { console.log("action executed!"); return true; }, }, });

Post by tasnim »

It actually fires before the combo shows. For the dropdown you can listen to beforeShow like this

new Combo({
	...
	picker : {
		listeners : {
			beforeShow() {
				// write your logic here
			}
		}
	}
});

Post by guillermoxintel »

Hi Tasnim! ok... but what's wrong with my code then? I know it should write in the console the message but it never happens... is there anything wrong with my code? should be

picker : { then listeners : {

?? or what's the reason it's not working? thanks for your help. In my sample, action is fully executed, but the other event is not...


Post by guillermoxintel »

Thank you Tasnim!... it works if I put this into the picker object... it would be a nice idea to explain this in the documentation, as this picker object is not clearly explained nor the events, thank you so much!


Post by marcio »

Thanks guillermoxintel, I created a ticket for improving the documentation https://github.com/bryntum/support/issues/5364

Best regards,
Márcio


Post Reply