Thank you for reporting this bug. We will make it our priority to review this report.
  1. #1
    Sencha User MikeB's Avatar
    Join Date
    Feb 2008
    Location
    Northern Md
    Posts
    104
    Vote Rating
    0
    MikeB is on a distinguished road

      0  

    Default [4.1.1a] Ext.data.TreeStore with Ext.data.proxy.Rest still does not pass ids right

    [4.1.1a] Ext.data.TreeStore with Ext.data.proxy.Rest still does not pass ids right


    I know this has been reported previously and has been reported as fixed (EXTJSIV-6005 in 4.1), however I'm still seeing the same issue:


    On 4.1.1a, a TreeStore using a REST proxy should pass record ids (as well as the nodeParam) as part of the URL, like this: /path/to/ressource/<id>.
    Instead, it passes the id as a query string parameter, like this: /path/to/ressource?node=<node>&id=<id>

    Test Case:
    Code:
    <!doctype html>
    <!--[if lt IE 7]> <html class="no-js ie6 oldie" lang="en"> <![endif]-->
    <!--[if IE 7]>    <html class="no-js ie7 oldie" lang="en"> <![endif]-->
    <!--[if IE 8]>    <html class="no-js ie8 oldie" lang="en"> <![endif]-->
    <!--[if gt IE 8]><!--> <html class="no-js" lang="en"> <!--<![endif]-->
    <head>
    	<meta charset="utf-8">
    	<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    
    
    	<title></title>
    	<meta name="description" content="">
    	<meta name="author" content="">
    
    
    	<meta name="viewport" content="width=device-width,initial-scale=1">
    
    
    	<link rel="stylesheet" type="text/css" href="css/style.css">
    	<link rel="stylesheet" type="text/css" href="/libs/extjs-4.1.1/resources/css/ext-all.css">
    
    
    	<script src="/libs/modernizr-2.6.2.min.js"></script>
    	<script src="/libs/respond.min.js"></script>
    </head>
    <body>
    
    
    
    
    <div id="tree-div"></div>
    
    
    <script src="/libs/jquery-1.8.3.min.js"></script>
    <script src="/libs/ext-4.1.1a/ext-all-debug-w-comments.js"></script>
    <script>
    Ext.require([
        'Ext.tree.*',
        'Ext.data.*',
        'Ext.tip.*'
    ]);
    
    
    Ext.onReady(function() {
        Ext.QuickTips.init();
    
    
        var store = Ext.create('Ext.data.TreeStore', {
            proxy: {
                type: 'rest',
    			url: 'JSON',
    			pageParam: false, //to remove param "page"
    			startParam: false, //to remove param "start"
    			limitParam: false, //to remove param "limit"
    			noCache: false, //to remove param "_dc"
            },
    
    
    		// idParam : "id",
    		// nodeParam : "id",
    
    
            root: {
                text: 'Ext JS',
                expanded: true
            }
        });
    
    
        var tree = Ext.create('Ext.tree.Panel', {
            store: store,
            renderTo: 'tree-div',
            height: 300,
            width: 250,
            useArrows: true
        });
    });
    </script>
    
    
    
    
    </body>
    </html>
    "JSON" Data file to autoload:

    Code:
    [
    	{
    		"text":"ExtJS","id":"RootNode","cls":"folder"
    	},
    	{
    		"text":"sencha-touch","id":"./SomeData","leaf":true,"cls":"file"
    	},
    	{
    		"text":"SenchaCmd","id":"./SomeMoreData","leaf":true,"cls":"file"
    	},
    	{
    		"text":"SenchaExtJS","id":"./And More Data","leaf":true,"cls":"file"
    	},
    	{
    		"text":"Touch","id":"root/Touch","cls":"folder"
    	}
    ]
    Am I missing something in my configuration or has this been broken again?

    Thanks
    MikeB

  2. #2
    Sencha - Senior Forum Manager mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    37,144
    Vote Rating
    855
    mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute

      0  

    Default


    No, it's sending the id correctly and also as a url parameter. It sends it like:

    /path/to/resource/[id]?node=[id]&id=[id]

    In 4.1.3+ it removed the id param

    /path/to/resource/[id]?node=[id]
    Mitchell Simoens @SenchaMitch
    Sencha Inc, Senior Forum Manager
    ________________
    Check out my GitHub, lots of nice things for Ext JS 4 and Sencha Touch 2
    https://github.com/mitchellsimoens

    Think my support is good? Get more personalized support via a support subscription. https://www.sencha.com/store/

    Need more help with your app? Hire Sencha Services services@sencha.com

    Want to learn Sencha Touch 2? Check out Sencha Touch in Action that is in print!

    When posting code, please use BBCode's CODE tags.

  3. #3
    Sencha User MikeB's Avatar
    Join Date
    Feb 2008
    Location
    Northern Md
    Posts
    104
    Vote Rating
    0
    MikeB is on a distinguished road

      0  

    Default


    Thanks Mitchell, I thought the fix was put into 4.1.1 didn't realize it was in 4.1.3.

    MikeB

Thread Participants: 1