02-13-2017 03:06 AM
I'm trying to map people type variable with data Entity Model, I have created CustomDataModelService to process the data based on assignee in people type field.my service is executing fine and returning all model attibutes value but the object or mapped variable that I have taken for assignee variable is empty.I tried same taking a text form field from form field to data model mapping property which is running fine but I'm facing challenge mapping assignee field (people) with data model.
can any body help me with the situation?
02-13-2017 11:11 AM
02-14-2017 09:32 AM
From the above three images you will find that I have taken a start form which has two fields in it , assignee and assignee id.
Now you see I have configured form field to data mapping , with 'assignee Id' form field. but there is no way I can find to map my model with 'assignee' which i want to achieve.
Here you see I have defined a mapped variable name through which I can access my model attributes. I configured form field to data mapping , with 'assignee Id' and In this way I am able to access all model attributes values through 'custom' variable. but here problem is I have to manually insert the assignee or user Id in the text field which is not way it should work.
To map with assignee I tried other way through process variable , so what I did is I created a process variable with the name 'assignee'.
so here I stepped to variables and created one like -
when configuring data model like this, execution reaches my customDatamodelService with field value assignee Id and returns the data as in previous case, but custom attributes values I'm getting are empty.
I hope its clear to you now what I really want to achieve.I need help on this.
02-15-2017 11:39 AM
Hi,
Thanks for a long answer but I'm afraid I'm still not getting your problem statement. Sorry.
Is this your main issue?
but there is no way I can find to map my model with 'assignee' which i want to achieve.
Do you mean you can't map non-primitive variable to your forms? I believe 'assignee' is a complex data model that you have defined?
when configuring data model like this, execution reaches my customDatamodelService with field value assignee Id and returns the data as in previous case, but custom attributes values I'm getting are empty.
You gotta have some running code and stack trace right? Could you extract your problematic code to a unit test and share it so everybody can really see your problems?
Thanks,
Thong
Explore our Alfresco products with the links below. Use labels to filter content by product module.