Updated session schema for session aggregation

This commit is contained in:
Michael Schmatz 2014-02-17 08:51:07 -08:00
parent 1b0f15b5f3
commit 9b53873414

View file

@ -100,11 +100,14 @@ _.extend LevelSessionSchema.properties,
type: 'object'
source:
type: 'string'
# TODO: specify this more
# TODO: specify this more
code:
type: 'object'
submittedCode:
type: 'object'
teamSpells:
type: 'object'
additionalProperties:
@ -134,6 +137,38 @@ _.extend LevelSessionSchema.properties,
default: false
index:true
matches:
type: 'array'
items:
type: 'object'
properties:
date: c.date
title: 'Time'
metrics:
type: 'object'
properties:
rank:
type: 'number'
opponents:
type: 'array'
items:
type: 'object'
properties:
id:
type: ['object', 'string']
codeSubmitDate: c.date
title: 'Submitted'
metrics:
type: 'object'
properties:
rank:
type: 'number'
c.extendBasicProperties LevelSessionSchema, 'level.session'
c.extendPermissionsProperties LevelSessionSchema, 'level.session'