Is there an API reference for interacting with the admin back-end? For example, I want to remove a particular tab from the product entry page.
Page 1 of 1
Customising the admin
#2
Posted 01 February 2012 - 03:56 PM
Hi Dominic,
To remove a tab from the Create/Edit Product form you should remove all controls from this tab. Models in LemonStand have the delete_form_field() method, which allows to remove a specific field. Example (for blog comment): http://forum.lemonst...endcommentform/
You should create a custom module and handle the shop:onExtendProductForm event in it (http://lemonstandapp...ductform_event/). In the handler you can remove all fields which are not needed. You can find a list of native fields in the modules/shop/models/shop_product.php class (see define_form_fields() method).
I hope this helps.
Thank you
To remove a tab from the Create/Edit Product form you should remove all controls from this tab. Models in LemonStand have the delete_form_field() method, which allows to remove a specific field. Example (for blog comment): http://forum.lemonst...endcommentform/
You should create a custom module and handle the shop:onExtendProductForm event in it (http://lemonstandapp...ductform_event/). In the handler you can remove all fields which are not needed. You can find a list of native fields in the modules/shop/models/shop_product.php class (see define_form_fields() method).
I hope this helps.
Thank you
#4
Posted 10 February 2012 - 05:26 PM
So what if I just want to HIDE a field, instead of deleting a field. For example, I want to hide the notes field on the customer tab, but not remove the actual database column. I want a simple way of hiding/showing fields on different sites based on a stock install of Lemonstand.
#5
Posted 10 February 2012 - 07:36 PM
Dominic, on 10 February 2012 - 05:26 PM, said:
So what if I just want to HIDE a field, instead of deleting a field. For example, I want to hide the notes field on the customer tab, but not remove the actual database column. I want a simple way of hiding/showing fields on different sites based on a stock install of Lemonstand.
Somebody asked this in chat today. I believe the solution was to call defaultInvisible() on the define_column(). You'll have to $customer->find_column_definition('notes')->defaultInvisible(). LMK if that doesn't work.
Share this topic:
Page 1 of 1

Help














