0

I'm trying to do a column in a grid wich displays the name of customer. when the user click on it , it worked like an url redirection to the customer edit page. i've tried using type="actions" attribute of addcolumn method and using render attribute too .but that didn't solved the problem exactly the result i want. Here is my code : Grid.php `

            $this->addColumn('customer_name', array ('index'=>'customer_id',
            'header' => Mage::helper('klikpack')->__('Customer'),
            'width' => '50px',
            'align' =>'left',
            'sortable' => false,
            'format' =>'$customer_name',
        'filter_condition_callback' => array($this, '_filterSponsortName'),

    ));`

look that im using a variable $customer_name to show customer name instead of customer_id. I hope you'll be able to help me, thanks !

khaldoun
  • 11
  • 1

1 Answers1

0

you tried to change 'customer_name' by other and 'customer_id' by other

ex:

$this->addColumn('customername', array ('index'=>'customerid',
                'header' => Mage::helper('klikpack')->__('Customer'),
                'width' => '50px',
                'align' =>'left',
                'sortable' => false,
                'format' =>'$customer_name',
            'filter_condition_callback' => array($this, '_filterSponsortName'),

        ));`

PD: i don't know if working

Marc
  • 6,154
  • 1
  • 15
  • 10