APIs

Show:
  1. /**
  2. This class...
  3. @class QueueCollection
  4. @constructor
  5. @return {Object} instantiated QueueCollection
  6. **/
  7. define(['jquery', 'backbone', 'QueueModel'], function ($, Backbone, QueueModel) {
  8.  
  9. BB.SERVICES.COLLECTION_QUEUES = 'COLLECTION_QUEUES';
  10.  
  11. var QueuesCollection = Backbone.Collection.extend({
  12.  
  13. /**
  14. Constructor
  15. @method initialize
  16. **/
  17. initialize: function () {
  18. var self = this;
  19. BB.comBroker.setService(BB.SERVICES.COLLECTION_QUEUES, self);
  20. },
  21. comparator: function( collection ){
  22. return( collection.get( 'name' ) );
  23. },
  24. model: QueueModel,
  25. url: BB.CONSTS.ROOT_URL + '/Queues'
  26. });
  27.  
  28. return QueuesCollection;
  29.  
  30. });