Nov 27, 2017, 4:25 PM
[CLOSED] Trying to activate child event before the parents' event using (beforeselect)
Trying to activate child event before the parents' event using [beforeselect]
Any equivalent to "beforeselect" and "beforedeselect" listener functionality?
It seems to be missing and I am in need of this particular functionality.
I have a populated list and the itemTpl containing textboxes.. I need to be able to click and edit the textboxes populated in the lsit without actually selecting (or deselecting) and highlighting the row, hence the reason why I require this functionality.
Any help (or hint) would be much appreciated.
Here is an example:
Currently whenever I click on the row , it gets selected as normal.. But I want to stop the select/deselect event when the textbox is clicked/focused. I mean of course i can nullify the click even by setting triggerEvent to false..But then I won't be able to select/deselect.
Any equivalent to "beforeselect" and "beforedeselect" listener functionality?
It seems to be missing and I am in need of this particular functionality.
I have a populated list and the itemTpl containing textboxes.. I need to be able to click and edit the textboxes populated in the lsit without actually selecting (or deselecting) and highlighting the row, hence the reason why I require this functionality.
Any help (or hint) would be much appreciated.
Here is an example:
<script runat="server">
public object[] People
{
get
{
var rv = new List<object>();
for (var x = 1; x < 50; x++)
{
rv.Add(new
{
Name = "King Kung" + x
});
}
return rv.ToArray();
}
}
</script>
<ext:Container runat="server">
<Items>
<ext:List runat="server" AllowDeselect="true" EmptyText="Nothing to display" Mode="Multi" TriggerEvent="true" >
<ItemTpl runat="server">
<Html>
<div><input id="test" type="number" onclick="getTest(this)" value="8" /> {Name}</div>
</Html>
</ItemTpl>
<Listeners>
<Select Fn="selected" />
<Deselect Fn="deSelected" />
</Listeners>
<Store>
<ext:Store runat="server" DataSource="<%# this.People %>">
<Model>
<ext:Model runat="server">
<Fields>
<ext:ModelField Name="Name" />
</Fields>
</ext:Model>
</Model>
</ext:Store>
</Store>
</ext:List>
</Items>
</ext:Container>
As you can see I have an itemTpl html code that includes a textbox with onclick event. Currently whenever I click on the row , it gets selected as normal.. But I want to stop the select/deselect event when the textbox is clicked/focused. I mean of course i can nullify the click even by setting triggerEvent to false..But then I won't be able to select/deselect.
Last edited by fabricio.murta; Dec 01, 2017 at 12:25 AM.