1. #11
    Sencha User
    Join Date
    Jul 2011
    Location
    Belgrade / Serbia
    Posts
    6
    Vote Rating
    0
    stbeli is on a distinguished road

      0  

    Default


    Hm, try default name
    Code:
    "total":1000,
    Work for me.

    Try to analyse code from this link
    http://extdirectspring.ralscha.ch/demo/simple/

  2. #12
    Sencha User
    Join Date
    Jul 2011
    Location
    Belgrade / Serbia
    Posts
    6
    Vote Rating
    0
    stbeli is on a distinguished road

      0  

    Default


    I think that I found. Move your total one position above like this

    Code:
    {
    "type":"rpc",
    "tid":1,
    "action":"QueryEmployee",
    "method":"readEmployee",
    "result":{"total":1000,"records":[{"id":"13",  <-- put total in result array

  3. #13
    Sencha User
    Join Date
    Nov 2011
    Posts
    25
    Vote Rating
    0
    danielleng is on a distinguished road

      0  

    Default


    stbeli: THANK YOU SO MUCH. I got it to work! Damn I actually thought of putting the total inside the 'result' array yesterday too.... but I had to take a break from coding for a while and forgot about it. Many thanks to you guys. This clears up a lot of my questions regarding Ext.direct.

  4. #14
    Sencha User
    Join Date
    Nov 2011
    Posts
    25
    Vote Rating
    0
    danielleng is on a distinguished road

      0  

    Default


    So to summarize, I did not need to change my router.php at all. I just needed to change my server-side PHP method to return the results in the correct format like so:

    Code:
                
                $results = array();
                 $results['total'] = $totalResults;
                
                $temp_array = array();
                $result = $stmt->get_result();
                while ($row = $result->fetch_array (MYSQL_ASSOC))
                {
                    array_push($temp_array, $row);
                }
                $results['records'] = $temp_array;
    
                return $results;
    I also had to declare a reader in my store's proxy to tell it the root key of the array containing my results.
    Code:
            reader:{
                type: 'json',
                root: 'records'
            }

  5. #15
    Sencha User
    Join Date
    Aug 2011
    Posts
    53
    Vote Rating
    1
    Erikvip is on a distinguished road

      0  

    Default


    Oh nevermind, I missed the fix.

film izle

hd film izle

film sitesi

takipci kazanma sitesi

takipci kazanma sitesi

güzel olan herşey

takipci alma sitesi

komik eğlenceli videolar