|
|
@@ -565,12 +565,11 @@ class Timeline extends LitElement {
|
|
|
|
|
|
const updateRessource = ressourceEditable
|
|
|
? (e: MouseEvent) => {
|
|
|
- const rowId = this.shadowRoot
|
|
|
+ const ressourceId = this.shadowRoot
|
|
|
?.elementsFromPoint(e.clientX, e.clientY)
|
|
|
.find((e) => e.tagName == "TD")
|
|
|
- ?.parentElement?.getAttribute("row-id");
|
|
|
- if (rowId) {
|
|
|
- const ressourceId = this.rows[Number(rowId)].id;
|
|
|
+ ?.parentElement?.getAttribute("ressourceid");
|
|
|
+ if (ressourceId) {
|
|
|
if (ressourceId !== localSlot.ressourceId) {
|
|
|
const oldRessource = this.getRessourceFromId(localSlot.ressourceId) as Ressource;
|
|
|
localSlot.ressourceId = ressourceId;
|