ee-query-builder
Advanced tools
Comparing version 0.1.15 to 0.1.16
@@ -9,5 +9,14 @@ !function(){ | ||
module.exports = new Class({ | ||
module.exports = new Class({ | ||
aggregateFunctions: { | ||
avg : 'AVG' | ||
, sum : 'SUM' | ||
, min : 'MIN' | ||
, max : 'MAX' | ||
, count : 'COUNT' | ||
} | ||
init: function(options){ | ||
, init: function(options){ | ||
this._escapeId = options.escapeId; | ||
@@ -18,2 +27,8 @@ this._escape = options.escape; | ||
, renderSelectFunction: function(tablename, command) { | ||
return this.aggregateFunctions[command.fn]+'('+this._escapeId(tablename)+'.'+this._escapeId(command.value)+')' | ||
} | ||
, in: function(command, paramaters){ | ||
@@ -20,0 +35,0 @@ //if (command.values.length) { |
@@ -294,2 +294,5 @@ !function(){ | ||
} | ||
else if (command.fn) { | ||
selects.push(this._functions.renderSelectFunction(tablename, command)); | ||
} | ||
break; | ||
@@ -296,0 +299,0 @@ } |
{ | ||
"name" : "ee-query-builder" | ||
, "description" : "query builder for ee-orm" | ||
, "version" : "0.1.15" | ||
, "version" : "0.1.16" | ||
, "homepage" : "https://github.com/eventEmitter/ee-query-builder" | ||
@@ -6,0 +6,0 @@ , "author" : "Michael van der Weg <michael@eventemitter.com> (http://eventemitter.com/)" |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
18607
430