couchdb-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From garrensmith <...@git.apache.org>
Subject [GitHub] couchdb pull request: Group log messages by date - COUCHDB-2136
Date Mon, 21 Apr 2014 15:20:43 GMT
Github user garrensmith commented on a diff in the pull request:

    https://github.com/apache/couchdb/pull/214#discussion_r11811045
  
    --- Diff: src/fauxton/app/addons/logs/resources.js ---
    @@ -110,7 +119,28 @@ function (app, FauxtonAPI, Backbone, d3) {
         },
     
         serialize: function () {
    -      return { logs: new Log.Collection(this.createFilteredCollection())};
    +      var collection = new Log.Collection(this.createFilteredCollection());
    +
    +      return {
    +        days: this.sortLogsIntoDays(collection)
    +      };
    +    },
    +
    +    sortLogsIntoDays: function (collection) {
    --- End diff --
    
    I think it would make more sense for the collection have have this function than the view.
The collection knows what data it holds. It would also make it easier to use this method elsewhere
it we needed.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

Mime
View raw message