Commit 14d56a1f authored by Penom Nom's avatar Penom Nom
Browse files

Add possibility to change template.

parent 52743119
......@@ -258,6 +258,12 @@ class Analysis (Component):
except :
return None
def get_template(self):
"""
Return the name of the template used for the visualisation.
"""
return self.__class__.__name__
def save(self):
"""
update the database info
......@@ -266,7 +272,7 @@ class Analysis (Component):
t3mysql = t3MySQLdb()
if self.parent: parent_uid = self.parent.id
else: parent_uid = 0
self.id = t3mysql.add_analysis(self.__class__.__name__, self.name, self.description, self.admin_login,
self.id = t3mysql.add_analysis(self.get_template(), self.name, self.description,
datetime.date.today(), self.directory, self.software, self.version,
self.options, self.is_editable, parent_uid=parent_uid)
......
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