diff --git a/app/views/results/map.coffee b/app/views/results/map.coffee new file mode 100755 index 00000000..15257228 --- /dev/null +++ b/app/views/results/map.coffee @@ -0,0 +1,12 @@ +( doc ) -> + + return unless doc.collection is 'result' + + if doc.klassId? + type = "klass" + id = doc.klassId + else + type = "assessment" + id = doc.assessmentId + + emit id, type