Ignore:
Timestamp:
07/29/12 16:04:45 (13 years ago)
Author:
hendrikvanantwerpen
Message:
  • Changed questions view to return null for empty topic/categorie and leave presentation of null to TabbedQuestionWidget?.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • Dev/branches/rest-dojo-ui/client/config/docs.json

    r382 r386  
    6969            },
    7070            "questions": {
    71                 "map": "function(doc){ if ( doc.type === 'Question' ) { if ( doc.categories && doc.categories.length > 0 ) { for (var i = 0; i < doc.categories.length; i++) { emit([doc.categories[i],doc.topic || '[No topic]'],1); } } else { emit(['[No category]','[No topic]'],1); } } }",
     71                "map": "function(doc){ if ( doc.type === 'Question' ) { if ( doc.categories && doc.categories.length > 0 ) { for (var i = 0; i < doc.categories.length; i++) { emit([doc.categories[i],doc.topic || null],1); } } else { emit([null,null],1); } } }",
    7272                "reduce": "function(keys,values) { return sum(values); }"
    7373            },
Note: See TracChangeset for help on using the changeset viewer.