Add a getter for destinations to the Source.

This commit is contained in:
2023-11-10 16:50:44 +02:00
parent d3bc4bd5a2
commit 66c389abfa
+8
View File
@@ -90,6 +90,14 @@ class Source(BaseModel):
path=destination_path
)
def get_destinations(self):
destionations = []
for dest in self.destinations:
destionations.append(dest.path)
return destionations
def update_label(self, new_label):
self.label = new_label
self.save()