2
0
mirror of https://github.com/esiur/esiur-dotnet.git synced 2025-06-27 05:23:13 +00:00
This commit is contained in:
2021-05-14 18:24:34 +03:00
parent 0af14009be
commit 5bf258673d
48 changed files with 1032 additions and 383 deletions

View File

@ -40,7 +40,7 @@ using Microsoft.EntityFrameworkCore.Metadata.Internal;
namespace Esiur.Stores.EntityCore
{
public class EsiurProxyRewrite : IModelFinalizingConvention
public class EsiurProxyRewrite : IModelFinalizingConvention
{
private static readonly MethodInfo _createInstance
= typeof(EsiurProxyRewrite).GetTypeInfo().GetDeclaredMethod(nameof(EsiurProxyRewrite.CreateInstance));
@ -79,7 +79,7 @@ namespace Esiur.Stores.EntityCore
var obj = Warehouse.New(entityType.ClrType).Wait() as EntityResource;//, "", options.Store, null, manager);
//obj._PrimaryId = id;
options.Store.TypesByType[entityType.ClrType].PrimaryKey.SetValue(obj, id);
Warehouse.Put(obj, id.ToString(), options.Store, null, null, 0, manager).Wait();
Warehouse.Put(id.ToString(), obj, options.Store, null, null, 0, manager).Wait();
// obj.Instance.IntVal = id;//.Variables.Add("eid", id);