Switch to side-by-side view

--- a/OSSEval/analysis/models.py
+++ b/OSSEval/analysis/models.py
@@ -1,3 +1,18 @@
+# This Source Code Form of OSSEval is subject to the terms of the GNU AFFERO
+# GENERAL PUBLIC LICENSE, v. 3.0. If a copy of the AGPL was not
+# distributed with this file, You can obtain one at http://www.gnu.org/licenses/agpl.txt
+#
+# OSSeval is powered by the SOS Open Source AGPL edition.
+#  The AGPL requires that you do not remove the SOS Open Source attribution and copyright 
+#  notices from the user interface (see section 5.d below).
+#  Commercial licenses are available and do not require any SOS Open Source attributions
+#  or visible copyright notices but they are not permitted under this license.
+
+# OSSEval Copyright 2014 Bitergium SLL
+# SOS Open Source Copyright 2012 Roberto Galoppini
+# Author: Davide Galletti 
+
+
 import importlib
 from django.db import models
 from datetime import datetime
@@ -25,7 +40,7 @@
         self.name = xmlMinidom.getStringAttribute(xmldoc, 'Name')
         self.description = xmlMinidom.getString(xmldoc, 'Description')
         self.documentation = xmlMinidom.getString(xmldoc, 'Documentation')
-        self.active = xmlMinidom.getStringAttribute(xmldoc, 'Active')
+        self.active = (xmlMinidom.getStringAttribute(xmldoc, 'Active') == "True")
         e = Entity()
         xml_entity = xmldoc.getElementsByTagName('Entity')[0]
         e.from_xml(xml_entity, insert)
@@ -115,7 +130,7 @@
                 p = Page()
                 p.from_xml(xml_page, self, None, insert)
         #WeightScenarios
-        xml_weight_scenarios = xmldoc.getElementsByTagName('WeightScenarios')
+        xml_weight_scenarios = xmldoc.getElementsByTagName('WeightScenario')
         for xml_weight_scenario in xml_weight_scenarios:
             ws = WeightScenario()
             ws.from_xml(xml_weight_scenario, self, insert)
@@ -369,7 +384,7 @@
             self.id = xmlMinidom.getNaturalAttribute(xmldoc, 'Id')
         self.methodology_version = methodology_version
         self.name = xmlMinidom.getStringAttribute(xmldoc, 'Name')
-        self.active = xmlMinidom.getStringAttribute(xmldoc, 'Active')
+        self.active = (xmlMinidom.getStringAttribute(xmldoc, 'Active') == "True")
         self.save()
         #Weights
         xml_weights = xmldoc.getElementsByTagName('Weight')