web/views/boxes.py
branchtls-sprint
changeset 1533 bcd4bfff658b
parent 1450 8edb0806dde4
child 1539 b0d583d30508
equal deleted inserted replaced
1532:111c52e0022f 1533:bcd4bfff658b
    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.set_rtag(mode, rschema, role, X, Y)
    67                         cls.rmode.tag_relation(mode, (X, rschema, Y), 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)