mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-11-21 23:43:17 +01:00
Et2LinkList: Fix file uploads when entry is not yet saved doubled the list of links
This commit is contained in:
parent
86c014fb94
commit
25ff5fe490
@ -284,7 +284,10 @@ export class Et2LinkList extends Et2LinkString
|
|||||||
// Add in new links from LinkTo
|
// Add in new links from LinkTo
|
||||||
for(let link of <LinkInfo[]>Object.values(_ev.detail || []))
|
for(let link of <LinkInfo[]>Object.values(_ev.detail || []))
|
||||||
{
|
{
|
||||||
if(!this._link_list.some(l => l.app == link.app && l.id == link.id))
|
if(!this._link_list.some(l => l.app == link.app && (l.id == link.id ||
|
||||||
|
// Unsaved
|
||||||
|
typeof link.id == "object" && typeof l.id == "object" && link.id.id == l.id.id
|
||||||
|
)))
|
||||||
{
|
{
|
||||||
this._link_list.unshift(link);
|
this._link_list.unshift(link);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user