Hi,
My scenario is this. I have an entity with a lot of attributes to display. So, while I have a master editor page with all attributes displayed / editable, I also want to create “shortcut” editor pages on the master page that updates different subsets of attributes at a time. What I’ve done so far is:
- Created views on the entity that have the subset attributes and an editor page to match
- Launch the subset editor from within the main editor by code which also updates some of the attributes e.g.
// within the main editor controller ..
// load the customer entity from the injected customer datasource
Customer customer = (Customer)customerDs.getItem();
customer.setFirstName(customer.getFirstName()+"1");
// TODO how to update data on the new screen? setting it here only updates the main screen.
CustomerNewUpdateEdit editor = (CustomerNewUpdateEdit)openEditor("sample$CustomerNewUpdate.edit", customer, OpenType.THIS_TAB);
My questions are:
a) How do I set an updated value on the new editor I’m opening up? As per the code comment, it only updates the main editor, which I only see after I’ve closed the subset editor.
b) I’ve also tried looking for a way to pass a parameter into the editor, but couldn’t seem to find a way.
c) Is there a better way for me to “jump” from one editor / view to another? Not sure if it’s going to cause any problems by opening another editor on the same entity.
Thanks,
Eddy