Results 1 to 2 of 2

Thread: Sequence column in treepanel

  1. #1
    Sencha User
    Join Date
    Jul 2011
    Posts
    17

    Default Sequence column in treepanel

    I have treepanel item. I want to add column with sequence number of line. I tried to do this, but nothing good
    Code:
    itemId: 'order_lines',                            xtype: 'treepanel',
                                title: 'Order Lines',
                                cls: 'crazy_order_lines',
                                loadMask: {msg: 'Fetching...'},
                                rootVisible: false, // Das ist nicht nur f�r diese Darstellung sinnvoll, sondern der Tree funktioniert auch nicht richtig, wenn man den Rootknoten sichtbar hat, aber nicht angibt (sondern versucht, ihn asynchron laden zu lassen)
                                multiSelect: true,
                                
                                columns: [
                                    {xtype: 'treecolumn', header: 'Pos', sortable: true, dataIndex: 'INHERENT_SORTING', width: 55, renderer: function () { return ''; }, style: {cursor: 'help'}, tooltip: 'Click here to sort in original order'},
                                    {header: 'order_line_id', sortable: true, hidden: true, dataIndex: 'order_line_id', width: 100},
                                    // {header: 'order_id', sortable: true, hidden: true, dataIndex: 'order_id', width: 100},
                                    {header: 'article_id', sortable: true, hidden: true, dataIndex: 'article_id', width: 100},
                                    // {header: 'INHERENT_SORTING', sortable: true, hidden: true, dataIndex: 'INHERENT_SORTING', width: 250},
                                    {header: 'order_piece_id', sortable: true, hidden: true, dataIndex: 'order_piece_id', width: 100},
                                    {header: 'piece_id', sortable: true, hidden: true, dataIndex: 'piece_id', width: 100},
                                    {header: 'sequence_number', sortable: true, hidden: false, dataIndex: 'sequence_number', width: 100, renderer: function(){
                                        return '2';
                                    }},
    ....

  2. #2
    Sencha Premium User mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    40,379
    Answers
    3997

    Default

    Have you tried using the Ext.grid.RowNumberer to see if that would work in the tree grid?
    Mitchell Simoens @LikelyMitch

    Check out my GitHub:
    https://github.com/mitchellsimoens

    Posts are my own, not any current, past or future employer's.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •