magento - Add attribute to sales->order->Create new order -


i want add new attribute in magento admin panes:

> sales > order > create new order

i want sales persons name fetched current user login in admin panel.
order type drop down , referred drop down.

please tell me how move ahead it?
files edit , on details properly?

firstly need create new attribute on order entity:

$installer = new mage_sales_model_resource_setup('core_setup'); $installer ->addattribute('order', 'my_attribute', array(     'label'     => 'my new attribute',     'type'      => 'varchar',     'input'     => 'text',     'visible'   => true,     'required'  => false,     'position'  => 1, )); 

now need modify admin view show new attribute:

app/design/adminhtml/default/default/template/sales/order/view/info.phtml

<?php if($_order->getmyattribute()): ?> <tr>     <td class="label"><label><?php echo mage::helper('sales')->__('my attribute') ?></label></td>     <td class="value"><strong><?php echo $_order->getmyattribute() ?></strong></td> </tr> <?php endif ?> 

Comments

Popular posts from this blog

java - Jmockit String final length method mocking Issue -

asp.net - Razor Page Hosted on IIS 6 Fails Every Morning -

c++ - wxwidget compiling on windows command prompt -