Merge "Remove @expression from tags"
This commit is contained in:
commit
6077dd1a45
@ -12,7 +12,6 @@
|
||||
|
||||
from oslo_log import log
|
||||
from six import text_type
|
||||
from sqlalchemy.ext.hybrid import hybrid_property
|
||||
from sqlalchemy import orm
|
||||
|
||||
from keystone.common import driver_hints
|
||||
@ -316,7 +315,7 @@ class Project(sql.ModelBase, sql.ModelDictMixinWithExtras):
|
||||
# rather than just only 'name' being unique
|
||||
__table_args__ = (sql.UniqueConstraint('domain_id', 'name'),)
|
||||
|
||||
@hybrid_property
|
||||
@property
|
||||
def tags(self):
|
||||
if self._tags:
|
||||
return [tag.name for tag in self._tags]
|
||||
@ -332,10 +331,6 @@ class Project(sql.ModelBase, sql.ModelDictMixinWithExtras):
|
||||
new_tags.append(tag_ref)
|
||||
self._tags = new_tags
|
||||
|
||||
@tags.expression
|
||||
def tags(cls):
|
||||
return ProjectTag.name
|
||||
|
||||
|
||||
class ProjectTag(sql.ModelBase, sql.ModelDictMixin):
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user