Skip to content

Commit 6d8b457

Browse files
committed
Stable Version 0.10.0
1 parent 6e55299 commit 6d8b457

File tree

5 files changed

+74
-60
lines changed

5 files changed

+74
-60
lines changed

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
##### 0.10.0 - 19 September 2015
2+
3+
- #15, #16 - Removed the various database libs from peerDependencies.
4+
15
##### 0.9.2 - 16 July 2015
26

37
###### Backwards compatible bug fixes

CONTRIBUTING.md

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Contributing Guide
22

3-
First, support is handled via the [Mailing List](https://groups.io/org/groupsio/jsdata). Ask your questions there.
3+
First, support is handled via the [Gitter Channel](https://gitter.im/js-data/js-data) and the [Mailing List](https://groups.io/org/groupsio/jsdata). Ask your questions there.
44

55
When submitting issues on GitHub, please include as much detail as possible to make debugging quick and easy.
66

@@ -10,13 +10,15 @@ When submitting issues on GitHub, please include as much detail as possible to m
1010

1111
[Github Issues](https://github.com/js-data/js-data-sql/issues).
1212

13-
#### Pull Requests
13+
#### Submitting Pull Requests
1414

15-
1. Contribute to the issue that is the reason you'll be developing in the first place
15+
1. Contribute to the issue/discussion that is the reason you'll be developing in the first place
1616
1. Fork js-data-sql
17-
1. `git clone https://github.com/<you>/js-data-sql.git`
17+
1. `git clone git@github.com:<you>/js-data-sql.git`
1818
1. `cd js-data-sql; npm install; bower install;`
19-
1. `grunt go` (builds and starts a watch)
20-
1. (in another terminal) `grunt karma:dev` (runs the tests)
2119
1. Write your code, including relevant documentation and tests
22-
1. Submit a PR and we'll review
20+
1. Run `grunt test` (build and test)
21+
1. Your code will be linted and checked for formatting, the tests will be run
22+
1. The `dist/` folder & files will be generated, do NOT commit `dist/*`! They will be committed when a release is cut.
23+
1. Submit your PR and we'll review!
24+
1. Thanks!

README.md

Lines changed: 13 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,10 @@ __Supported Platforms:__
2222
### Quick Start
2323
`npm install --save js-data js-data-sql`.
2424

25+
You also need to install the driver for the database you want to connect to.
26+
27+
`npm install --save <mysql|mariasql|pg|sqlite3>`
28+
2529
```js
2630
var JSData = require('js-data');
2731
var DSSqlAdapter = require('js-data-sql');
@@ -54,7 +58,7 @@ store.registerAdapter('sql', adapter, { default: true });
5458

5559
### Contributing
5660

57-
First, support is handled via the [Mailing List](https://groups.io/org/groupsio/jsdata). Ask your questions there.
61+
First, support is handled via the [Gitter Channel](https://gitter.im/js-data/js-data) and the [Mailing List](https://groups.io/org/groupsio/jsdata). Ask your questions there.
5862

5963
When submitting issues on GitHub, please include as much detail as possible to make debugging quick and easy.
6064

@@ -64,16 +68,18 @@ When submitting issues on GitHub, please include as much detail as possible to m
6468

6569
[Github Issues](https://github.com/js-data/js-data-sql/issues).
6670

67-
#### Pull Requests
71+
#### Submitting Pull Requests
6872

69-
1. Contribute to the issue that is the reason you'll be developing in the first place
73+
1. Contribute to the issue/discussion that is the reason you'll be developing in the first place
7074
1. Fork js-data-sql
71-
1. `git clone https://github.com/<you>/js-data-sql.git`
75+
1. `git clone git@github.com:<you>/js-data-sql.git`
7276
1. `cd js-data-sql; npm install; bower install;`
73-
1. `grunt go` (builds and starts a watch)
74-
1. (in another terminal) `grunt karma:dev` (runs the tests)
7577
1. Write your code, including relevant documentation and tests
76-
1. Submit a PR and we'll review
78+
1. Run `grunt test` (build and test)
79+
1. Your code will be linted and checked for formatting, the tests will be run
80+
1. The `dist/` folder & files will be generated, do NOT commit `dist/*`! They will be committed when a release is cut.
81+
1. Submit your PR and we'll review!
82+
1. Thanks!
7783

7884
### License
7985

dist/js-data-sql.js

Lines changed: 36 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -55,10 +55,10 @@ module.exports =
5555

5656
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } }
5757

58-
var knex = __webpack_require__(2);
59-
var JSData = __webpack_require__(3);
60-
var map = __webpack_require__(4);
61-
var underscore = __webpack_require__(1);
58+
var knex = __webpack_require__(1);
59+
var JSData = __webpack_require__(2);
60+
var map = __webpack_require__(3);
61+
var underscore = __webpack_require__(4);
6262
var unique = __webpack_require__(5);
6363
var toString = __webpack_require__(6);
6464
var DSUtils = JSData.DSUtils;
@@ -111,34 +111,34 @@ module.exports =
111111
//} else if (op === 'isectNotEmpty') {
112112
// subQuery = subQuery ? subQuery.and(row(field).default([]).setIntersection(r.expr(v).default([])).count().ne(0)) : row(field).default([]).setIntersection(r.expr(v).default([])).count().ne(0);
113113
} else if (op === 'in') {
114-
query = query.where(field, 'in', v);
115-
} else if (op === 'notIn') {
116-
query = query.whereNotIn(field, v);
117-
} else if (op === 'like') {
118-
query = query.where(field, 'like', v);
119-
} else if (op === '|==' || op === '|===') {
120-
query = query.orWhere(field, v);
121-
} else if (op === '|!=' || op === '|!==') {
122-
query = query.orWhere(field, '!=', v);
123-
} else if (op === '|>') {
124-
query = query.orWhere(field, '>', v);
125-
} else if (op === '|>=') {
126-
query = query.orWhere(field, '>=', v);
127-
} else if (op === '|<') {
128-
query = query.orWhere(field, '<', v);
129-
} else if (op === '|<=') {
130-
query = query.orWhere(field, '<=', v);
131-
//} else if (op === '|isectEmpty') {
132-
// subQuery = subQuery ? subQuery.or(row(field).default([]).setIntersection(r.expr(v).default([])).count().eq(0)) : row(field).default([]).setIntersection(r.expr(v).default([])).count().eq(0);
133-
//} else if (op === '|isectNotEmpty') {
134-
// subQuery = subQuery ? subQuery.or(row(field).default([]).setIntersection(r.expr(v).default([])).count().ne(0)) : row(field).default([]).setIntersection(r.expr(v).default([])).count().ne(0);
135-
} else if (op === '|in') {
136-
query = query.orWhere(field, 'in', v);
137-
} else if (op === '|notIn') {
138-
query = query.orWhereNotIn(field, v);
139-
} else {
140-
throw new Error('Operator not found');
141-
}
114+
query = query.where(field, 'in', v);
115+
} else if (op === 'notIn') {
116+
query = query.whereNotIn(field, v);
117+
} else if (op === 'like') {
118+
query = query.where(field, 'like', v);
119+
} else if (op === '|==' || op === '|===') {
120+
query = query.orWhere(field, v);
121+
} else if (op === '|!=' || op === '|!==') {
122+
query = query.orWhere(field, '!=', v);
123+
} else if (op === '|>') {
124+
query = query.orWhere(field, '>', v);
125+
} else if (op === '|>=') {
126+
query = query.orWhere(field, '>=', v);
127+
} else if (op === '|<') {
128+
query = query.orWhere(field, '<', v);
129+
} else if (op === '|<=') {
130+
query = query.orWhere(field, '<=', v);
131+
//} else if (op === '|isectEmpty') {
132+
// subQuery = subQuery ? subQuery.or(row(field).default([]).setIntersection(r.expr(v).default([])).count().eq(0)) : row(field).default([]).setIntersection(r.expr(v).default([])).count().eq(0);
133+
//} else if (op === '|isectNotEmpty') {
134+
// subQuery = subQuery ? subQuery.or(row(field).default([]).setIntersection(r.expr(v).default([])).count().ne(0)) : row(field).default([]).setIntersection(r.expr(v).default([])).count().ne(0);
135+
} else if (op === '|in') {
136+
query = query.orWhere(field, 'in', v);
137+
} else if (op === '|notIn') {
138+
query = query.orWhereNotIn(field, v);
139+
} else {
140+
throw new Error('Operator not found');
141+
}
142142
});
143143
});
144144
}
@@ -468,25 +468,25 @@ module.exports =
468468
/* 1 */
469469
/***/ function(module, exports) {
470470

471-
module.exports = require("mout/string/underscore");
471+
module.exports = require("knex");
472472

473473
/***/ },
474474
/* 2 */
475475
/***/ function(module, exports) {
476476

477-
module.exports = require("knex");
477+
module.exports = require("js-data");
478478

479479
/***/ },
480480
/* 3 */
481481
/***/ function(module, exports) {
482482

483-
module.exports = require("js-data");
483+
module.exports = require("mout/array/map");
484484

485485
/***/ },
486486
/* 4 */
487487
/***/ function(module, exports) {
488488

489-
module.exports = require("mout/array/map");
489+
module.exports = require("mout/string/underscore");
490490

491491
/***/ },
492492
/* 5 */

package.json

Lines changed: 12 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "js-data-sql",
33
"description": "Postgres/MySQL/MariaDB/SQLite3 adapter for js-data.",
4-
"version": "0.9.2",
4+
"version": "0.10.0",
55
"homepage": "http://www.js-data.io/docs/dssqladapter",
66
"repository": {
77
"type": "git",
@@ -26,28 +26,30 @@
2626
"sqlite"
2727
],
2828
"devDependencies": {
29-
"babel-core": "5.6.17",
30-
"babel-loader": "5.3.1",
31-
"bluebird": "2.9.33",
32-
"chai": "3.0.0",
29+
"babel-core": "5.8.25",
30+
"babel-loader": "5.3.2",
31+
"bluebird": "2.10.0",
32+
"chai": "3.2.0",
3333
"grunt": "0.4.5",
3434
"grunt-contrib-watch": "0.6.1",
35-
"grunt-karma-coveralls": "2.5.3",
35+
"grunt-karma-coveralls": "2.5.4",
3636
"grunt-mocha-test": "0.12.7",
3737
"grunt-webpack": "1.0.11",
3838
"jit-grunt": "0.9.1",
3939
"jshint": "2.8.0",
4040
"jshint-loader": "0.8.3",
41-
"sinon": "1.15.4",
41+
"sinon": "1.16.1",
4242
"time-grunt": "1.2.1",
43-
"webpack-dev-server": "1.10.1"
43+
"webpack-dev-server": "1.11.0"
4444
},
4545
"scripts": {
4646
"test": "grunt test"
4747
},
4848
"dependencies": {
49-
"js-data": ">=2.0.0",
50-
"knex": ">=0.7.4",
5149
"mout": "0.11.0"
50+
},
51+
"peerDependencies": {
52+
"js-data": ">=2.0.0",
53+
"knex": ">=0.7.4"
5254
}
5355
}

0 commit comments

Comments
 (0)