Index: branches/RC/core/install/upgrades.php =================================================================== diff -u -N -r11523 -r11572 --- branches/RC/core/install/upgrades.php (.../upgrades.php) (revision 11523) +++ branches/RC/core/install/upgrades.php (.../upgrades.php) (revision 11572) @@ -822,6 +822,41 @@ $this->Conn->Query($sql); } } + + // 5. add missing event + $sql = 'SELECT EventId + FROM ' . TABLE_PREFIX . 'Events + WHERE (Event = "FORM.SUBMITTED") AND (Type = 1)'; + $event_id = $this->Conn->GetOne($sql); + + if (!$event_id) { + $sql = "INSERT INTO " . TABLE_PREFIX . "Events VALUES (DEFAULT, 'FORM.SUBMITTED', NULL, 1, 0, 'Core:Category', 'la_CMS_FormSubmitted', 1)"; + $this->Conn->Query($sql); + } + + $sql = 'SELECT EventId + FROM ' . TABLE_PREFIX . 'Events + WHERE (Event = "FORM.SUBMITTED") AND (Type = 0)'; + $event_id = $this->Conn->GetOne($sql); + + if (!$event_id) { + $sql = "INSERT INTO " . TABLE_PREFIX . "Events VALUES (DEFAULT, 'FORM.SUBMITTED', NULL, 1, 0, 'Core:Category', 'la_CMS_FormSubmitted', 0)"; + $this->Conn->Query($sql); + } + + // 6. add missing variable + $sql = 'SELECT VariableId + FROM ' . TABLE_PREFIX . 'ConfigurationValues + WHERE VariableName = "cms_DefaultDesign"'; + $variable_id = $this->Conn->GetOne($sql); + + if (!$variable_id) { + $sql = "INSERT INTO " . TABLE_PREFIX . "ConfigurationAdmin VALUES ('cms_DefaultDesign', 'la_Text_General', 'la_prompt_DefaultDesignTemplate', 'text', NULL, NULL, 10.29, 0, 0)"; + $this->Conn->Query($sql); + + $sql = "INSERT INTO " . TABLE_PREFIX . "ConfigurationValues VALUES (DEFAULT, 'cms_DefaultDesign', '/platform/designs/default_design.des', 'In-Portal', 'in-portal:configure_categories')"; + $this->Conn->Query($sql); + } } } \ No newline at end of file