Service implementation
Following code is the service implementation for displaying the income column.
Line 12 associates the column with the sightly template
import java.util.Map;
import org.osgi.service.component.annotations.Component;
import com.adobe.cq.inbox.ui.InboxItem;
import com.adobe.cq.inbox.ui.column.Column;
import com.adobe.cq.inbox.ui.column.provider.ColumnProvider;
@Component(service = ColumnProvider.class, immediate = true)
public class IncomeProvider implements ColumnProvider {
@Override
public Column getColumn() {
return new Column("income", "Income", String.class.getName(),"inbox/customization/column-templates.html", "incomeTemplate");
}
@Override
public Object getValue(InboxItem inboxItem) {
Object val = null;
Map workflowMetadata = inboxItem.getWorkflowMetadata();
if (workflowMetadata != null && workflowMetadata.containsKey("income"))
val = workflowMetadata.get("income");
return val;
}
}
Test on your server
This article assumes you have installed the sample workflow and sample form from previous article in this series.
- Login to crx as admin user
- import sightly template
- Login to AEM web console
- Deploy and start inbox customization bundle
- Open your inbox
- Open Admin Control by clicking on List View next to Create button
- Add income column to Inbox and save your changes
- Preview the form
- Select the marital status and submit the form
- View inbox
Submitting the form will trigger the workflow and a task is assigned to “admin” user. You should see appropriate icon under the income column
Previous page2 - Add custom column
Next page1 - Introduction
Experience Manager
- Overview
- Best practices to follow
- Setting up OKTA authentication with AEM Author
- Creating your first Adaptive Form
- Handling Form Submissions
- Useful Integrations
- Creating OSGi bundle
- Adaptive Forms
- Fill a PDF form with ChatBot
- Core- Components based forms
- Select and assemble DAM folder content
- Prefilling adaptive form using form data model
- UI Tips and Tricks
- Customizing inbox
- Email form attachments
- Prefilling form with data and attachments
- Storing and Retrieving Adaptive Form
- Import data from pdf file
- Exporting Submitted Data in CSV Format
- HTML5 Forms
- AEM Forms and Acrobat Sign
- Sign Multiple Forms
- Custom workflow steps
- Custom workflow component
- Variables in AEM Workflow
- Review form data
- Storing and Retrieving Form Data in MySQL DB
- Triggering AEM Workflow on PDF Form submission
- Trigger AEM workflow on Mobile Form Submission
- Querying Form Submissions
- Listing Custom Asset Types in Forms Portal
- AEM Forms With Marketo
- AEM Forms with Adobe Campaign Standard
- Welcome Kit
- Headless Forms API
- React App with Forms and Acrobat Sign
- Document Services
- Forms Designer
- AEM Forms Workbench
- Interactive Communications for Print Channel
- Save and Retrieve Draft Letters
- Interactive Communications
- Interactive Communications For Web Channel
- Troubleshooting