Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7543445
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 30, 20262026-05-30T08:25:50+00:00 2026-05-30T08:25:50+00:00

I just cannot seem to get the tree grid up and running. I have

  • 0

I just cannot seem to get the tree grid up and running.
I have defined the model, the store and the treegrid (as seen below).
The tree grid shows inside target, the data is loaded async (checked with fiddler, two rows came back) however the treegrid just shows two rows with empty cells.

I tried debugging and the store’s root node indeed has two child nodes, the model data is under child’s raw property (except some fields such as leaf and iconCls which are also in data property), yet the tree grid shows two empty rows, despite dataIndex pointing to a proper model field.

It’s like tree grid cannot find the field defined by the model?!?

Here’s the source (I am using sandbox because I am integrating this into salesforce vforce, the salesforce merge fields {!} are also valid and render properly)

Ext4.onReady(function() {

    var target = '{!$Component.childBlock.childTreeDiv}';


    Ext4.define('ConfigurationItem', {
        extend: 'Ext4.data.Model',
        fields: [
            {
            id: 'id',
            type: 'string'},
        {
            id: 'name',
            type: 'string'},
        {
            id: 'recordType',
            type: 'string'},
        {
            id: 'ciName',
            type: 'string'},
        {
            id: 'alias',
            type: 'string'},
        {
            id: 'model',
            type: 'string'},
        {
            id: 'status',
            type: 'string'},
        {
            id: 'description',
            type: 'string'},
        {
            id: 'leaf',
            type: 'bool'},
        {
            id: 'iconCls',
            type: 'string'}
        ]
    });

    var store = Ext4.create('Ext4.data.TreeStore', {
        model: 'ConfigurationItem',
        root: {
            nodetype: 'async',
            id: '{!CI__c.Id}',
            expanded: true
        },
        proxy: {
            type: 'ajax',
            url: 'json_CIChildren',
            reader: {
                type: 'json',
                root: 'children'
            }
        }
    });

    tree = Ext4.create('Ext4.tree.Panel', {
        width: document.getElementById(target).offsetWidth,
        autoHeight: true,
        title: 'Child Configuration Items',
        collapsible: true,
        titleCollapse: true,
        renderTo: target,
        rootVisible: false,
        store: store,
        multiSelect: true,
        singleExpand: true,
        columns: [
            {
            type: 'treecolumn',
            text: 'CI#',
            dataIndex: 'name'},
        {
            text: 'Type',
            dataIndex: 'recordType'}
        ]
    });
});​

The request to json_CIChildren?_dc=1329830854458&node=a0NT0000006tYKzMAM was valid (the parentID in root.id got propagated ok) and came back with valid json:

{ "children" : [
         {
             "id": "a0NT0000006tswhMAA",
             "name": "CI334593834",
             "recordType": "Rack",
             "ciName": "Empty rack",
             "alias": "",
             "model": "",
             "status": "",
             "description": "",
             "leaf": "true",
             "iconCls": "x4-ciicon-Rack"
         },
         {
             "id": "a0NT0000006tYKuMAM",
             "name": "CI2345234",
             "recordType": "Service",
             "ciName": "Business Connect - Premium",
             "alias": "",
             "model": "",
             "status": "",
             "description": "",
             "leaf": "true",
             "iconCls": "x4-ciicon-Service"
         }
 ]}

What am I doing wrong? Why isn’t the treegrid seeing name and recordType fields?

Is this because store only saw NodeInterface-like fields and there is none of my custom data in data property?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-30T08:25:51+00:00Added an answer on May 30, 2026 at 8:25 am

    I think the problem is your model fields aren’t mapped right. The “id” property for each field should be the ‘name’ property instead.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I just cannot seem to get my head around what exactly is the MODEL
So obviously I am doing something wrong, but I just cannot seem to get
Trying to manipulate a table with jQuery, and I just cannot seem to get
I have a problem with an MVC view that I just cannot seem to
I have a UITableview in a popover. I cannot seem to get the deselection
I just cannot get this to work, would appreciate if someone can help. So
I have just heard that the iphone cannot do double natively thereby making them
I have just started using silverlight 2 beta and cannot find how to or
I cannot seem to get CI's session library to function the way I want
I cannot seem to get a nested form to generate in a rails view

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.