asp.net-mvc-4 - BreezeJS 从服务器获取元数据,而不使用复杂对象(嵌套对象)的 Entity Framework

标签 asp.net-mvc-4 asp.net-web-api odata breeze

这是我在服务器端的模型。我不想使用 Entity Framework ,如何从服务器生成 BreezeJS 元数据。 Breeze 元数据格式在这里找到 http://www.breezejs.com/documentation/breeze-metadata-format不起作用。

public class User
{
    public string Id { get; set; }
    public string Name { get; set; }
    public List<App> Apps { get; set; }
}

public class App
{
    public string Id { get; set; }
    public string Name { get; set; }
    public Dictionary<string, string> Info { get; set; }
}

有人在不使用 EF 的情况下尝试过与上述类似的复杂对象(嵌套对象)吗?

使用 Breeze Metdata API 或 OData ?

最佳答案

看这个例子http://www.breezejs.com/samples/nodb它应该给你一个线索。

关于asp.net-mvc-4 - BreezeJS 从服务器获取元数据,而不使用复杂对象(嵌套对象)的 Entity Framework ,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/15862691/

相关文章:

c# - 使用枚举连接列表中的对象

asp.net-mvc - 类型 'System.Web.Mvc.MvcWebRazorHostFactory' 的表达式不能用于返回类型 'System.Web.WebPages.Razor.WebRazorHostFactory'

javascript - 来自 WebApi2 response.data 的 Angular ng-repeat 刷新

http-headers - 具有 ASP.NET MVC Web API 的 ASP.NET MVC 站点,结果类型/ Controller 由 Accept header 确定

c# - ODataProperties NextLink 为空

azure - 如何使用 OData 筛选器对逻辑应用中的唯一姓氏筛选 Azure 存储表?

c# - 如何解决错误 :the type does not appear to implement microsoft. practices.servicelocation.iservicelocator?

c# - MVC 获取错误 - 创建数据库权限被拒绝

.net - ASP.NET WebApi - 为多个来源启用 CORS

OData 多重扩展和过滤