Chromium Code Reviews| Index: dashboard/dashboard/models/table_config.py |
| diff --git a/dashboard/dashboard/models/table_config.py b/dashboard/dashboard/models/table_config.py |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..933619b5b346da93eb74d23256c4412c69c80c1c |
| --- /dev/null |
| +++ b/dashboard/dashboard/models/table_config.py |
| @@ -0,0 +1,39 @@ |
| +# Copyright 2017 The Chromium Authors. All rights reserved. |
| +# Use of this source code is governed by a BSD-style license that can be |
| +# found in the LICENSE file. |
| + |
| +"""The datastore model TableConfig, which specify which reports to generate. |
| + |
| +Each /speed_releasing report will be generated via creating a corresponding |
| +configuration which lists which bots and tests the user is interested in, |
| +as well as a user friendly name and the actual table layout. |
| + |
| +Example bots: [TODO @jessimb] |
| + |
| +Example tests: [TODO @jessimb] |
| + |
| +Example test_layout: [TODO @jessimb] |
|
sullivan
2017/01/11 20:59:15
These examples sshould be filled in.
jessimb
2017/01/12 02:10:30
These might change. Filled in for now.
|
| + |
| +""" |
| + |
| +from google.appengine.ext import ndb |
| + |
| +from dashboard.models import internal_only_model |
| + |
| + |
| +class TableConfig(internal_only_model.InternalOnlyModel): |
| + |
| + # A user friendly name for the set of speed releasing reports contained by |
| + # the entity. |
| + name = ndb.StringProperty() |
| + |
| + # A list of bots the speed releasing report will contain. |
| + bots = ndb.StringProperty(repeated=True) |
|
sullivan
2017/01/11 20:59:15
Shouldn't this be ndb.KeyProperty(repeated=True) f
jessimb
2017/01/11 21:31:21
Should there be a check in here (well, in the POST
sullivan
2017/01/11 21:38:03
Yep! Could either be in the POST or you could make
jessimb
2017/01/12 02:10:30
Done
|
| + |
| + # A list of testsuites/subtests that each speed releasing report will contain. |
| + tests = ndb.StringProperty(repeated=True) |
| + |
| + # Aids in displaying the table by showing groupings and giving pretty names. |
| + table_layout = ndb.TextProperty() |
|
sullivan
2017/01/11 20:59:15
This needs to be better documented.
jessimb
2017/01/12 02:10:30
Comments added at the top of the file.
|
| + |
| + internal_only = ndb.BooleanProperty(default=False, indexed=True) |