UNPKG

tastypie

Version:

Tastypie is a webservice API framework for Node.js based on Django's Tastypie Framework. It provides a convenient, yet powerful and highly customizable, abstraction for creating REST-style interfaces

17 lines (13 loc) 277 B
define(function () { /** * gets date quarter */ function quarter(date){ var month = date.getMonth(); if (month < 3) return 1; if (month < 6) return 2; if (month < 9) return 3; return 4; } return quarter; });