Get Value of Selected rowwidget on ExtJS - extjs

How do I get the value of the selected row in rowwidget after the toggle. Please assist, I have tried the the bind functionality but it does not work or necessary for my problem.

if as you said row is selected then this must work: yourGrid.getSelection()[0]

Related

smart-table row selection enable disable using script

I am working on on page where I need to show row selected and I need to populate that selected row in form next to that grid, its working properly but I am trying to implement disable row selection when user is editing any existing row, please let me know how to resolve this. thanks.
Assuming you have something similar to this in your code:
<tr st-select-row="schedule" st-select-mode="multiple" ng-repeat="schedule in displaySchedules>
You should remove the attribute st-select-row="schedule" to disable selection functionality when editing flag is true or whatever is the condition you need to meet.

How to dynamically update grid cell color and tool tip based on user action in Extjs 4?

Based on a user action, like click of a button, we need to update a grid cell and modify its background color and tool-tip.
Please note that it has to be only a particular cell of grid record and not the entire column affecting all the records.
Thus, how can we update these two things for a particular grid record cell - background color and tool-tip - dynamically?
Thanks for help in advance.
PS: ExtJs version 4.1.1
I have been able to find a solution for this. Though, not sure if its the best way, but posting it here as it may help someone looking for the same.
The solution is to write custom renderer function for the column which needs to be updated and calling the following code on the user action at which the update is required (like in the handler of the button clicked):
grid.getView().refresh();
The above code will invoke the column renderer function and this renderer function should be able to judge which background color and tool-tip to be applied at the grid column as per the current state of application.
Hope this helps.

How can I add slickgrid checkboxes to specific rows depending on if a value is true or false, without adding it as a formatter?

Does anyone know how I can add checkboxes only to specific rows in slickgrid without using the formatter approach?
Currently I've just done a columns.push(checkboxSelector.getColumnDefinition()); but that adds checkboxes to all the rows.
When I tried to use the formatter approach like this https://groups.google.com/forum/?fromgroups=#!topic/slickgrid/uKq2aVU5luo I found that when I scrolled through the grid, it would not hold the 'check' that were already selected in the checkboxes of the rows?
Grateful for any help on this.

Set value for ExtJS.form.ComboBox

I have an Ext.grid.EditorGriPanel which has an combobox editor in its columnModel (the store of combox has just only 2 items: enabled/disabled). When a new blank row is inserted to grid, I want the combobox in that column have to be set to a default value (enabled), and the dropdown is not expanded.
I've tried to use
grid.colModel.columns[2].editor.select(0)
to get the combobox editor and set "enabled" value for it, but it did not work. Another way is using grid.colModel.columns[2].getCellEditor(rowIndex), but it returns an EditorGrid (I was so surprised because the ExtJS 3.3.1 API doesn't have this component).
Could you please help me on this problem?
Thank you so much!
When a new blank row is inserted to
grid, I want the combobox in that
column have to be set to a default
value (enabled), and the dropdown is
not expanded.
When the new record is inserted to the grid's store, the value of your column (in the record) needs to be set to "enabled". I'm not sure if you are doing it like this currently? In other words, the value must not be set to the editor of the column. Set it directly in the record.
(Also, you can define default values to be used for all records using the recordType property of the store - see ExtJS API documentation for more details - but this is optional.)
Finally, note that the combobox will not be displayed immediately after the row is added. The combobox is displayed only when you start editing that particular cell - this is the way EditorGrid works in ExtJS. But at least you should get the new row to immediately display the correct value ("enabled") with this advice.

How i can turn off autocompletion in Extjs combobox?

When I selected some item in combobox and then I'm trying to select another item in same combobox, I can see only one item - those which is selected right now. I believe that happens because of autocompletion. Does anybody know how I can disable it or something. I need to see all values on each click, regardless if something was selected already or not.
Add triggerAction:'all' to your config.
better add disableKeyFilter:'true' to your combo box

Resources