Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
mentors.debian.net
debexpo
Commits
7a8a8184
Commit
7a8a8184
authored
Jul 06, 2012
by
Clément Schreiner
Browse files
Make result's data a dictionary.
parent
951e7a91
Changes
1
Hide whitespace changes
Inline
Side-by-side
debexpo/model/plugin_results.py
View file @
7a8a8184
...
...
@@ -33,6 +33,7 @@ Holds plugin_results table model.
from
sqlalchemy
import
orm
import
sqlalchemy
as
sa
from
sqlalchemy.orm.collections
import
attribute_mapped_collection
from
debexpo.model
import
meta
,
OrmObject
from
debexpo.model.package_versions
import
PackageVersion
...
...
@@ -67,13 +68,16 @@ plugin_result_mapper = orm.mapper(PluginResult,
polymorphic_identity
=
'plugin_results'
,
properties
=
{
'package_version'
:
orm
.
relation
(
PackageVersion
,
backref
=
'plugin_results'
),
backref
=
'plugin_results'
,
),
}
)
plugin_result_data_mapper
=
orm
.
mapper
(
PluginResultData
,
t_plugin_result_data
,
properties
=
{
'plugin_result'
:
orm
.
relation
(
PluginResult
,
backref
=
'result_data'
),
'plugin_result'
:
orm
.
relation
(
PluginResult
,
backref
=
orm
.
backref
(
'data'
,
collection_class
=
attribute_mapped_collection
(
'key'
))
)
}
)
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment