// get template codes for specified template
$templateListenerList = new TemplateListenerList();
$templateListenerList->getConditionBuilder()->add("template_listener.environment = ?", array($parameters['environment']));
+ $templateListenerList->sqlOrderBy = 'template_listener.niceValue ASC, template_listener.listenerID ASC';
$templateListenerList->readObjects();
$data = array();
* @see \wcf\system\package\plugin\AbstractXMLPackageInstallationPlugin::prepareImport()
*/
protected function prepareImport(array $data) {
+ $niceValue = isset($data['elements']['nice']) ? intval($data['elements']['nice']) : 0;
+ if ($niceValue < -128) {
+ $niceValue = -128;
+ }
+ else if ($niceValue > 127) {
+ $niceValue = 127;
+ }
+
return array(
'environment' => $data['elements']['environment'],
'eventName' => $data['elements']['eventname'],
+ 'niceValue' => $niceValue,
'name' => $data['attributes']['name'],
'templateCode' => $data['elements']['templatecode'],
'templateName' => $data['elements']['templatename']
templateName VARCHAR(80) NOT NULL DEFAULT '',
eventName VARCHAR(50) NOT NULL DEFAULT '',
templateCode TEXT NOT NULL,
+ niceValue TINYINT(3) NOT NULL DEFAULT 0,
KEY templateName (environment, templateName)
);