Modify Basic price viewpoint

Hello,

The basic price viewpoint only performs the sum of the currentPrice variable when a physical component has sub components. What I want to do is to add a new variable and performs the sum too.

Captura

As can be seen in this image. Only the Value 1 performs the sum of the sub components. How can I perform the sum of Value 2 ?

Thank you,

I.B.

Hi,

You should first take a look at the viewpoint practice option #1. Either you import the viewpoint or you take the code from the github repo.
Then you will have to modify the data aspect of the viewpoint.
And finally modify the code of the viewpoint to add your new value computation. Take a look at the PriceService class for an entry point.

Regards,
Arnaud

Hi,

Thanks for the answer. Another thing I don’t understand is why there is Value in the Price Class and a currentPrice in the PartPrice Class. In the diagram it is used price.data.PartPrice.currentPrice but in the UI: Field valueField label: Value , mapped-to price.data.Price.value . It seems that the variable Value is saved in price.data.Price.value and not in price.data.PartPrice.currentprice.

When I try to replicate this I find that my Value 2 never change. I try to write a number but it remains with a 0. How can I solve this?

Thanks!

I.B

Hi,
I have another generic question about cumulative viewpoints:
They all cumulate data from the only PCN. Pending on the detail level of the product model, some PL may represent parts, that weight, cost, even if they are considered as not impacting items they convey. In some cases, their impact may be substancial. At the moment the only way is to promote them as PCN, and then allocate there PCB and PF… which raise model complexity.
Is there any plans about this?
Thanks
Thierry Poupon

Hi,

The difference between these two values lies in the fact that an element itself contributes a price (price.data.Price.value) and its total price is computed from this value and is set to the value currentPrice.

Regards,
Arnaud

Hi Arnaud,

Could you please give me more indications on what to do next? I imported the viewpoint and I know how to modify the data aspect of the viewpoint (I am capable of create new variables and assign a value through UI) but I don’t know which parts I have to modify in the viewpoint code to add a new value computation. I have been looking the PriceService class as you mentioned but I don’t know what to implement.

Thank you,
I.B

Hi,

If I understand correctly your point, you may want to specify “cumulative” information (price, mass…) earlier in the system design (at Logical, System or Operational architecture levels) as it is for now necessary to create model elements up to the Physical architecture level in order to attach such information.

The basic viewpoints are meant to be examples for the development of viewpoints for Capella models. As such there is no plans to make them evolve. Further evolution of these viewpoints should be somehow financed.

Regards,
Arnaud

Hi,

Sorry but the only information I could give you is to look at the entry point of the code in the .odesign file where calls to services are done, the PriceLevelHelper may also be of help. Using theses, you should find your path to the use of the PriceService. At this point you have to carefully dive into the code.

Regards,
Arnaud

Hi,
Thanks for the answer, I understand about the example value of the viewpoints…
Still, to precise my remark: to me what cumulates costs (in money, manufacturing energy or any cumulative value) or weights is attached to product solution. This relates more to configuration items in Capella than to PC Nodes. The reason why a PL may represent a product in a irreductible way is because it would be left alone in its CI, this because this CI will be linked to a supply solution alone. So my wish would not to start viewpoints before but to delay it to EPBS layer and attach CI instead of PCN… But I understand your answer once again.

Regards

Thierry Poupon

Hi,

Oh I now understand. Thanks for the clarification.

Regards,
Arnaud

Copyright © Eclipse Capella, the Eclipse Capella logo, Eclipse and the Eclipse logo are Trademarks of The Eclipse Foundation.