@bee.js/node 0.0.40 → 0.0.41
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/beehive.js +7 -0
- package/lib/DBA/beeDBA.js +3 -0
- package/package.json +1 -1
package/beehive.js
CHANGED
|
@@ -284,6 +284,13 @@ module.exports = function hive(req = {}, res = {}, model = null) {
|
|
|
284
284
|
return this
|
|
285
285
|
},
|
|
286
286
|
|
|
287
|
+
orderByIf: function(condition, ...fields) {
|
|
288
|
+
if (condition)
|
|
289
|
+
script[0]['orderBy'].push(fields.join(', '))
|
|
290
|
+
|
|
291
|
+
return this
|
|
292
|
+
},
|
|
293
|
+
|
|
287
294
|
limit: function(...params) {
|
|
288
295
|
|
|
289
296
|
script[0]['limit'].push(params.join(","))
|
package/lib/DBA/beeDBA.js
CHANGED