bpmn-io/bpmn-js-properties-panel

On superfluous variables in bpmn/properties/TimerProps

miyuesc opened this issue ยท 5 comments

Describe the Bug

image

Here in position 1, the props argument is passed in with only one 'element' attribute, which causes the 'listener' to always be undefined.

But here in position 2 there is a function call that determines the type of the listener.

I'm confused, since the listener is always undefined, is there any need for the determination here?

nikku commented

@philippfromme Can you have a look into this one?

Will have a look as I'm currently working on the properties panel anyway. ๐Ÿ‘๐Ÿป

Will have a look as I'm currently working on the properties panel anyway. ๐Ÿ‘๐Ÿป

This is great news!

I've been working on a new properties panel using Vue 3 and TypeScript, and a lot of the content is referenced from this project.

But I found that there are a lot of duplicate functions in it, and there are also a lot of places where there are problems with the props parameters, I hope you can review it again.

Thank you very much!

This is not a bug, but the BPMN and Camunda Platform 7 concerns are mixed up. As part of 0a6f2c4#diff-8f65c96244d2035d79af366d94fdef782c34a33283d612fbbe6477f373fc153c TimerProps was reused for camunda:TaskListener elements. However, the vanilla BPNN groups and entries should contain any logic specific to Camunda 7 or 8. I'll consider cleaning this up. Everything works as expected, though.

Never mind my comment. It turns out that it's not actually being reused. It seems like we forgot to remove the logic specific to Camunda 7. Thanks for pointing out.