Creating a Widget with Google Web Toolkit and opentaps
Create new hot-deploy/crmsfa/src/org/opentaps/gwt/crmsfa/cases with cases.gwt.xml
Create hot-deploy/crmsfa/src/org/opentaps/gwt/crmsfa/cases/client/Entry.java
Link Entry.java to opentaps page by modifying hot-deploy/crmsfa/webapp/crmsfa/cases/screenlets/quickCreateCase.ftl and adding:
<@gwtWidget id="quickNewCase"/>
Entry.java references the same quickNewCase:
private static final String QUICK_CREATE_CASE_ID = "quickNewCase"; public void onModuleLoad() { if (RootPanel.get(QUICK_CREATE_CASE_ID) != null) { // ...
Add cases to crmsfa build.xml:
<property name="gwt.module.list" value="contacts,accounts,leads,partners,orders,cases"/>
Now create QuickNewCaseForm and QuickNewCaseConfiguration. QuickNewCaseForm extends ScreenletFormPanel and is the form. For example, it has a TextField for subjectInput and so forth. QuickNewCaseConfiguration is used to hold the literal values on the QuickNewCaseForm, such as the names of the fields. They could be strings in QuickNewCaseForm as well. UI labels are available through UtilUi.MSG: for example, UtilUi.MSG.crmCreateCase() is CrmCreateCase