Tag: jaydata

jaydata odata-server newsreader示例抛出没有方法'basicAuth'exception

我没有得到odata-server在我的机器上工作(Windows 8.1,nodejs 0.10.30,mongo 2.4.8)。 也试过干净的Ubuntu安装,同样的问题。 Reproscheme: 创build目录 npm安装odata-server cd node_modules / odata-server 节点newsreader.js 这给出了以下输出: Should be empty: [] Test data upload successful. 100 items inserted. Starting NewsReader OData server. C:\Projects\odata\node_modules\odata-server\node_modules\mongodb\lib\mongodb\connection\base.js:245 throw message; ^ TypeError: Object function createServer() { function app(req, res, next){ app.handle(req, res, next); } merge(app, proto); merge(app, EventEmitter.prototype); app.route = '/'; app.stack = […]

使用NodeJS和JayData的OData服务

我试图按照这个例子: http : //jaydata.org/blog/install-your-own-odata-server-with-nodejs-and-mongodb但它似乎是过时的,所以写在例子的评论我有更新一些代码行如下: 数据模型(data-model.js文件): $data.Class.define ( "dbTest.tblTest", $data.Entity, null, { ID: { type: "id", key: true, computed: true, nullable: false }, Data: { type: "string" } }, null ); $data.Class.defineEx ( "dbTest.Context", [ $data.EntityContext, $data.ServiceBase ], null, { tblTest: { type: $data.EntitySet, elementType: dbTest.tblTest } } ); exports = dbTest.Context; 服务器(server.js文件): var c = […]