Jun 11, 2012, 12:00 PM
[CLOSED] Remote action refusal when moving a node
Hi Folks, i have a TreePanel where user is able to move nodes. I implemented it using https://examples2.ext.net/#/TreePane..._with_Service/ as example. The difference between mine example and the mentioned one is that mine is implemented in MVC. In my case, i always get RemoteActionRefusal. Any idea to overcome this problem?
<ext:TreePanel ID="TreePanel1" runat="server" Title="Ext" Width="500"
Height="300" Collapsible="true" UseArrows="true" RootVisible="false" RemoteMoveUrl="/Example/MoveNode"
Mode="Remote" RemoteJson="true">
<View>
<ext:TreeView>
<Plugins>
<ext:TreeViewDragDrop runat="server" AllowLeafDrop="true" />
</Plugins>
</ext:TreeView>
</View>
<DirectEventConfig Method="POST" />
<Listeners>
<RemoteActionException Handler="alert('Exception')" />
<RemoteActionRefusal Handler="alerts('refused')" />
<RemoteActionSuccess Handler="alert('succeeded')" />
</Listeners>
<Fields>
<ext:ModelField Name="identifier" />
</Fields>
<SelectionSubmitConfig Encode="true" />
<ColumnModel>
<Columns>
<ext:TreeColumn ID="TreeColumn1" runat="server" Text="identifier" Flex="2" Sortable="true"
DataIndex="identifier" />
</Columns>
</ColumnModel>
<Root>
<ext:Node Icon="Folder" NodeID="1" Expanded="true">
<CustomAttributes>
<ext:ConfigItem Name="identifier" Value="1" Mode="Value" />
</CustomAttributes>
<Children>
<ext:Node Leaf="true" NodeID="2">
<CustomAttributes>
<ext:ConfigItem Name="identifier" Value="2" Mode="Value" />
</CustomAttributes>
</ext:Node>
<ext:Node Leaf="true" NodeID="3">
<CustomAttributes>
<ext:ConfigItem Name="identifier" Value="3" Mode="Value" />
</CustomAttributes>
</ext:Node>
<ext:Node Leaf="true" NodeID="4">
<CustomAttributes>
<ext:ConfigItem Name="identifier" Value="4" Mode="Value" />
</CustomAttributes>
</ext:Node>
<ext:Node Leaf="true" NodeID="5">
<CustomAttributes>
<ext:ConfigItem Name="identifier" Value="5" Mode="Value" />
</CustomAttributes>
</ext:Node>
</Children>
</ext:Node>
</Root>
</ext:TreePanel>
public object MoveNode(string[] ids, string targetId, string point)
{
return new { actionSuccess = true };
}
Last edited by Daniil; Jan 11, 2013 at 5:42 AM.
Reason: [CLOSED]