Page 1 of 1

Editing of Order and fulfillment information in admin

Posted: Wed Jan 30, 2013 1:01 am
by sharathcu
Hi everyone,

I am new to broadleaf and I am able to run the admin and the site section of broadleaf demo. I want to edit the order and fullfillment information in admin section(for now the fields are read-only). I have gone through a link which address this but not succeeded. Please guide me what has to be done to edit the information in admin



Thank you in advance

Re: Editing of Order and fulfillment information in admin

Posted: Fri Feb 01, 2013 11:33 am
by phillipuniverse
Editing any of the information about an order is currently unsupported; anything you would do here is 100% custom.

What did you go through already and where were you running into trouble? One solution to this (although unsupported) would be to subclass the Broadleaf module/view/presenter to make those views non read-only. This is usually code in the GWT presenter itself when creating the view objects.

Re: Editing of Order and fulfillment information in admin

Posted: Mon Feb 04, 2013 1:21 am
by sharathcu
Hi phillip, thanks for your reply.

Here is the link that i have gone through
viewtopic.php?f=13&t=1453

and i created the class which extended the CustomerCareModule and subclass which extends OrderPresenter

MyCustomerCareModule.java code:

Code: Select all

public class MyCompanyCustomerCareModule extends CustomerCareModule{
   
   @Override
   public void onModuleLoad(){
      super.onModuleLoad();
      ModuleFactory.getInstance().put("orderPresenter", "com.mycompany.admin.module.MyCompanyPresenter");
   }
}


MyCompanyPresenter.java Code:

Code: Select all

public class MyCompanyPresenter extends OrderPresenter{
   @Override
   public void bind(){
      super.bind();
      setReadOnly(false);
      orderItemPresenter.enable();
      orderItemPresenter.setStartState();
   }
}

and i created a xxx.gwt.xml like placed under resources of admin module

<module>
<inherits name="com.google.gwt.user.User" />
<inherits name="org.broadleafcommerce.cms.admin.contentManagementModule" />
<inherits name="org.broadleafcommerce.admin.customerCareModule" />

<source path="client" />
<entry-point class="com.mycompany.admin.module.MyCompanyCustomerCareModule" />
</module>

kindly let me know where i am going wrong.


Thanks