About the issue of duplicate card in the menu

  1. When I copy a card, the order of processing events is as follows: add-card → send API → duplicate-card. It’s strange that the duplicate-card event comes after add-card. Shouldn’t it handle the copied data in the duplicate-card event, and then send the request in the add-card event?

  2. When I inspect the data in the duplicate-card event, only the label property of the card object is available, and modifying or adding properties has no effect.

I don’t quite understand the sequence of events and their roles.


Hello @jmh.yy ,

  1. This behaviour is because of the inner Event Bus logic. It is the order for the actions (events) in whose handlers other actions are called (exec duplicate → exec add, select-card → set-edit).
    The actions (exec duplicate → then exec add) are called recursively. The events handlers are called as soon as the actions finish, and because of the way recursive calls work, they complete in the reverse order as a result.

  2. For modifying or/and adding properties to have effect, you could use api.intercept: DHTMLX Snippet Tool .