[jboss-user] [jBPM] - Re: I18NText with Oracle

Andrey Trakhirov do-not-reply at jboss.com
Thu Oct 4 12:15:47 EDT 2012


Andrey Trakhirov [https://community.jboss.org/people/andreytr] created the discussion

"Re: I18NText with Oracle"

To view the discussion, visit: https://community.jboss.org/message/763260#763260

--------------------------------------------------------------
I have the same problem.

My temporary temporary solution:

public class HumanTaskWorkItemHandler extends AsyncGenericHTWorkItemHandler {


    public HumanTaskWorkItemHandler(KnowledgeRuntime session) {
        super(session);
    }


    @Override
    protected Task createTaskBasedOnWorkItemParams(WorkItem workItem) {
        Task task = super.createTaskBasedOnWorkItemParams(workItem);
        addDefaultDescriptionToText(task.getNames());
        addDefaultDescriptionToText(task.getSubjects());
        addDefaultDescriptionToText(task.getDescriptions());
        return task;
    }


    private void addDefaultDescriptionToText(List<I18NText> textList) {
        for(I18NText text: textList) {
            if (text.getText() == null || text.getText().equals("")) {
                text.setText(" ");
            }
        }
    }
}
--------------------------------------------------------------

Reply to this message by going to Community
[https://community.jboss.org/message/763260#763260]

Start a new discussion in jBPM at Community
[https://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2034]

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-user/attachments/20121004/4227ec64/attachment.html 


More information about the jboss-user mailing list