This commit is contained in:
@@ -73,7 +73,7 @@ namespace AyaNova.Biz
|
|||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
PartAssembly newObject = new PartAssembly();
|
PartAssembly newObject = new PartAssembly();
|
||||||
CopyObject.Copy(dbObject, newObject, "Wiki");
|
CopyObject.Copy(dbObject, newObject, "Wiki,Id");
|
||||||
string newUniqueName = string.Empty;
|
string newUniqueName = string.Empty;
|
||||||
bool NotUnique = true;
|
bool NotUnique = true;
|
||||||
long l = 1;
|
long l = 1;
|
||||||
@@ -85,6 +85,11 @@ namespace AyaNova.Biz
|
|||||||
newObject.Name = newUniqueName;
|
newObject.Name = newUniqueName;
|
||||||
newObject.Id = 0;
|
newObject.Id = 0;
|
||||||
newObject.Concurrency = 0;
|
newObject.Concurrency = 0;
|
||||||
|
foreach (PartAssemblyItem pai in newObject.Items)
|
||||||
|
{
|
||||||
|
pai.Id = 0;
|
||||||
|
pai.Concurrency = 0;
|
||||||
|
}
|
||||||
await ct.PartAssembly.AddAsync(newObject);
|
await ct.PartAssembly.AddAsync(newObject);
|
||||||
await ct.SaveChangesAsync();
|
await ct.SaveChangesAsync();
|
||||||
await EventLogProcessor.LogEventToDatabaseAsync(new Event(UserId, newObject.Id, BizType, AyaEvent.Created), ct);
|
await EventLogProcessor.LogEventToDatabaseAsync(new Event(UserId, newObject.Id, BizType, AyaEvent.Created), ct);
|
||||||
|
|||||||
Reference in New Issue
Block a user