Commit 469600d5 authored by Bryan  BRANCOTTE's avatar Bryan BRANCOTTE
Browse files

update names when needed

parent 18b16c34
......@@ -338,6 +338,9 @@ class Ppi(AutoFillableModel):
def __str__(self):
return 'PPI #{} on {}'.format(self.id, self.name)
def is_autofill_done(self):
return self.name == ""
def autofill(self):
# name is denormalized and stored in the database to reduce SQL queries in query mode
self.name = self.compute_name_from_protein_names()
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment