I work in a large project in which we investigate the process experience in the context of business process management. For this I want to extend BPMN.
In the example [bpmn-js-example-custom-elements](https://github.com/bpmn-io/bpmn-js-example-custom-elements) this is partly discussed. So i would take this example as the basis of my Question.
with the getExtensionElement function i can access the attributes of the respective element. Here for example ‘qa:AnalysisDetails’
let analysisDetails = getExtensionElement(businessObject, 'qa:AnalysisDetails'); console.log("output: " + analysisDetails.lastChecked)
But how can I access the child element? In this example i maybe want to access the attributes of “comment”. If i try to do it like before, i’ll get a undefined variable:
let comment = getExtensionElement(businessObject, 'qa:comment'); console.log("output2: " + comment.author)
<bpmn2:task id="Task_1" name="Examine Situation" qa:suitable="70"> <bpmn2:outgoing>SequenceFlow_1</bpmn2:outgoing> <bpmn2:extensionElements> <qa:analysisDetails lastChecked="2019-03-27T13:59:37.098Z" nextCheck="2019-03-28T13:59:37.098Z"> <qa:comment author="Klaus"> Our operators always have a hard time to figure out, what they need to do here. </qa:comment> <qa:comment author="Walter"> I believe this can be split up in a number of activities and partly automated. </qa:comment> </qa:analysisDetails> </bpmn2:extensionElements> </bpmn2:task>