web/views/boxes.py
branchtls-sprint
changeset 1721 694f6a50e138
parent 1672 2406667c90d6
child 1726 08918409815e
equal deleted inserted replaced
1720:14c9a0a1aca1 1721:694f6a50e138
    62                             # if self is composed of the target type, create mode
    62                             # if self is composed of the target type, create mode
    63                             mode = 'create'
    63                             mode = 'create'
    64                         else:
    64                         else:
    65                             # link mode by default
    65                             # link mode by default
    66                             mode = 'link'
    66                             mode = 'link'
    67                         cls.rmode.tag_relation(mode, (X, rschema, Y), role)
    67                         cls.rmode.tag_relation(X, rschema, Y, mode, tagged=role)
    68 
    68 
    69     @classmethod
    69     @classmethod
    70     def relation_mode(cls, rtype, etype, targettype, role='subject'):
    70     def relation_mode(cls, rtype, etype, targettype, role='subject'):
    71         """return a string telling if the given relation is usually created
    71         """return a string telling if the given relation is usually created
    72         to a new entity ('create' mode) or to an existant entity ('link' mode)
    72         to a new entity ('create' mode) or to an existant entity ('link' mode)