equal
deleted
inserted
replaced
31 self.entity.eid, self.rtype, self.email.eid) |
31 self.entity.eid, self.rtype, self.email.eid) |
32 self.session.unsafe_execute( |
32 self.session.unsafe_execute( |
33 'SET X %s Y WHERE X eid %%(x)s, Y eid %%(y)s' % self.rtype, |
33 'SET X %s Y WHERE X eid %%(x)s, Y eid %%(y)s' % self.rtype, |
34 {'x': self.entity.eid, 'y': self.email.eid}, 'x') |
34 {'x': self.entity.eid, 'y': self.email.eid}, 'x') |
35 |
35 |
|
36 |
36 class SetPrimaryEmailRelationOp(SetUseEmailRelationOp): |
37 class SetPrimaryEmailRelationOp(SetUseEmailRelationOp): |
37 rtype = 'primary_email' |
38 rtype = 'primary_email' |
38 |
39 |
39 def condition(self): |
40 def condition(self): |
40 """check entity has no primary_email set""" |
41 """check entity has no primary_email set""" |