List of nested business variables.

1
0
-1

hello;

I have the following business data model:
1- Business variable EHC contains the PRODUCT_SERVICE_SECTION business variable (of list type) with an aggregation relationship, and other variables.
2- PRODUCT_SERVICE_SECTION business variable contains the PRODUCT_SERVICE_GROUP business variable (of list type) with an aggregation relationship, and other variables.
3- Business variable PRODUCT_SERVICE_GROUP contains the PATIENT_INFO business variable with an aggregation relationship and other variables.
4- PATIENT_INFO business variable contains the PID business variable with an aggregation relationship, and other variables.
5- Pid business variable contains a set of simple attributes.

I have the following questions:
- To facilitate the creation of forms, how can I create forms using contracts?
- What are the operations to add to assign values to these variables?

3 answers

1
0
-1

Hello,
Thank you for the process. It's a good one.

You have a lot of Business variables: do you really use all these variables? I have the feeling some are in fact CHILDREN

For example, in the PRAYOR processes (you didn't specify the process, assuming this is the first), I found the ehc_E01 variable you spoke about. This BO contains a msh child. So, why do you have an MSH BO? This information is DIFFERENT than the ehc_E01.msh variable?

Second, you talk about a " variable EHC in contract". In the Prayor, instantiation form (the one you should talk about because you didn't specify it), the contract is empty. So, just Add the BO variables by clicking on Add From Data and the studio will generate for you all the operation needed, plus the form. You just need to modify it.

I have the following questions:
- To facilitate the creation of forms, how can I create forms using contracts?

==> Do a Add from Data to populate the contact, then click on the Pencil in the form: a form is generated with all the contract requirement
- What are the operations to add to assign values to these variables?

==> In an instantiation form, look the script to initialize the data. In a task, look operations.

Due to the complexity of the process, you should consider contacting Bonitasoft, the professional service (I'm part of this service). I think 1 or 2 days is the minimum to help you with this kind of process. I have the feeling that you can simplify your data. it will be a good subject for the next PY's Tutorial video on Chanel.

Comments

Submitted by maouachria on Mon, 08/24/2020 - 23:55

Thanks sir

1- I have MSH BO because it contains a simple attributes. ehc_E01 have MSH as attribute.

2-i do this with secretary process (in prepare healthcare service invoice ) but I have the problem when I execute I can not write in the form.

How I can contact you or the professional service I need your help please?

1
0
-1

The Subscription studio mean you have a license key for the studio. it may be a Team Work, enterprise. Forms generation are different between type and different between version.

Could you share your BOS file? Which Bonita version are you using?

Normally, the studio should generate, for a list of items, all in read-only. But when you click on one item, it may refresh a sub panel with fields and you can edit them (maybe). If you want to edit fields in a table, use the Bear Widget, https://community.bonitasoft.com/project/widget-beartable

And yes, you may need to change/add other operations, without viewing the BOS that you have, hard to say.

Comments

Submitted by maouachria on Thu, 08/20/2020 - 16:33

this is a part of my project with Bonita Community Edition V 7.11.1:

https://drive.google.com/file/d/1ubx1Vb0MvI5qvd-X7TAKd9qnXN4RGB1H/view?usp=sharing

Since I do not master the web program (script and API rest. list.....) I used the contract to facilitate the creation of forms as well as the operations.

1
0
-1

Hello,

To facilitate the creation of forms, how can I create forms using contracts?

==> the subscription studio does that.

- What are the operations to add to assign values to these variables?

==> The subscription studio does that

Else, you have to do that manually

Note: is your relationship is a EAGER or a LAZY properties?

* If this is a LAZY, you may have issue to get the complete information. Use the REST API CONTEXT to get all in one call

https://community.bonitasoft.com/project/restapicontext

or use the new BDM Rest Api available in 7.11

* If this is a EAGER relation, attention to the performance ! If one day one object has a lot of data, it may take HOURS to load it. See this video which explain the phenomena https://youtu.be/dQisptr5PXM

To avoid that, use the REST API CONTEXT or the new BDM Rest API available in 7.11

Comments

Submitted by maouachria on Wed, 08/19/2020 - 22:45

In this case when I add the first business variable EHC in contact the form create with all other variables but when I execute i can not add a new value in the fielwds of this form.????

Submitted by Pierre-yves Monnet on Wed, 08/19/2020 - 23:15

Hello,

I don't get what you mean.

You can add a new value every time, it's just a question on what you are doing in the operation. If you add a new value is the list, then Bonita will automatically add (or change, or delete) the value in the database.

Submitted by maouachria on Thu, 08/20/2020 - 00:23

You mean subscription studio in community edition? Or entreprise one?

In community edition, i add the parent business variable EHC in cantract (mentioned above in my question) , studio create automatically the form and operations associated with the form. I found all the Childs of EHC business variable (PRODUCT_SERVICE_SECTION with his childsPRODUCT_SERVICE_Group....... ) with thier persistence Id. But I can not write in these fields.

You mean that I must add other operations ?

Notifications