Projet

General

Profil

How to build your own model

To build your model, you can access to the Model Designer (beCPG -> Model Designer).

1- Selecting Model file and adding Imports :

First, go to Models and select your Model xml file. Here, we are selecting the file existing by default extCustomModel.xml. If you want to add a new file, go to repository -> Dictionnaire de données -> Models and upload your empty xml file there. Then you can load it with the Model Designer as we just did with extCustomModel.xml.

After selecting your file, go to Model. Do the imports you need in Imports. For example, add the Content Import like this : Imports -> New Item :


2- Creating a new Type :

You can now add a new type. To do so, go do Types -> New Item -> Name of your Type -> Specify the Association as Types -> Specify the Element Type as Type. In this example, I am creating a new Type Accounting.


2.1- Adding properties to your type :

To the Type Accounting that I have created, I am adding properties. To do so, you just have to select your type Accounting -> Click on New Item -> Name your property -> Put Association as Properties -> Put Element type as Property -> Clik Ok. After that, you have to specify the property type, its Title and also you can specify if it has a default value and/or is mandatory. Here, I added a property called "Accounts Payable". Its property Type is double and It is not mandatory.

You can add as many properties as you need. In my example, I added three properties: Item, Accounts Payable and Accounts Receivable.

3- Creating a new aspect :

To create an aspect, go to Aspect and click New Item. An aspect is a group of properties or/and associations that you can add to any type. For example, if you have a type Task and a Type project. Every type has its own properties but both of them have Start date and End date. For that, I can add an aspect called "Time" having two properties, Start and End date. Then, I have just to add the aspect to the Task and Project Type. To do so, you have to select your type and add the aspect in "Mandatory Aspects".

In my previous example, I am creating an aspect Finance. After that I am adding to this aspect some properties, exactly the same way I added properties to the type "Accounting". The properties I added are budget and assets.


Then, I added the Finance aspect to my type Accounting as a mandatory aspect :

After this, do not forget to publish your model. If you don't, nothing will be taken into consideration.
Select your model file and click publish.

After building your model, you have to create your forms. Please refer to the page [[https://www.becpg.fr/redmine/projects/becpg-community/wiki/How_to_create_your_forms?parent=Data_Models_and_Forms]] .