From d39d52aac8f38ea9115628039f0df5aa3ac826de Mon Sep 17 00:00:00 2001 From: ivan Date: Fri, 3 Dec 2004 20:40:48 +0000 Subject: import rt 3.2.2 --- rt/etc/upgrade/3.1.0/acl.Informix | 4 ++++ rt/etc/upgrade/3.1.0/acl.Oracle | 4 ++++ rt/etc/upgrade/3.1.0/acl.Pg | 19 +++++++++++++++++++ rt/etc/upgrade/3.1.0/acl.SQLite | 4 ++++ rt/etc/upgrade/3.1.0/acl.mysql | 4 ++++ rt/etc/upgrade/3.1.0/content | 2 ++ rt/etc/upgrade/3.1.0/schema.Informix | 17 +++++++++++++++++ rt/etc/upgrade/3.1.0/schema.Oracle | 17 +++++++++++++++++ rt/etc/upgrade/3.1.0/schema.Pg | 25 +++++++++++++++++++++++++ rt/etc/upgrade/3.1.0/schema.SQLite | 20 ++++++++++++++++++++ rt/etc/upgrade/3.1.0/schema.mysql | 21 +++++++++++++++++++++ rt/etc/upgrade/3.1.15/content | 7 +++++++ rt/etc/upgrade/3.1.17/content | 22 ++++++++++++++++++++++ 13 files changed, 166 insertions(+) create mode 100644 rt/etc/upgrade/3.1.0/acl.Informix create mode 100755 rt/etc/upgrade/3.1.0/acl.Oracle create mode 100755 rt/etc/upgrade/3.1.0/acl.Pg create mode 100755 rt/etc/upgrade/3.1.0/acl.SQLite create mode 100755 rt/etc/upgrade/3.1.0/acl.mysql create mode 100644 rt/etc/upgrade/3.1.0/content create mode 100644 rt/etc/upgrade/3.1.0/schema.Informix create mode 100644 rt/etc/upgrade/3.1.0/schema.Oracle create mode 100755 rt/etc/upgrade/3.1.0/schema.Pg create mode 100644 rt/etc/upgrade/3.1.0/schema.SQLite create mode 100755 rt/etc/upgrade/3.1.0/schema.mysql create mode 100644 rt/etc/upgrade/3.1.15/content create mode 100644 rt/etc/upgrade/3.1.17/content (limited to 'rt/etc/upgrade') diff --git a/rt/etc/upgrade/3.1.0/acl.Informix b/rt/etc/upgrade/3.1.0/acl.Informix new file mode 100644 index 0000000..73c16ae --- /dev/null +++ b/rt/etc/upgrade/3.1.0/acl.Informix @@ -0,0 +1,4 @@ +sub acl { + return (); +} +1; diff --git a/rt/etc/upgrade/3.1.0/acl.Oracle b/rt/etc/upgrade/3.1.0/acl.Oracle new file mode 100755 index 0000000..73c16ae --- /dev/null +++ b/rt/etc/upgrade/3.1.0/acl.Oracle @@ -0,0 +1,4 @@ +sub acl { + return (); +} +1; diff --git a/rt/etc/upgrade/3.1.0/acl.Pg b/rt/etc/upgrade/3.1.0/acl.Pg new file mode 100755 index 0000000..809e99a --- /dev/null +++ b/rt/etc/upgrade/3.1.0/acl.Pg @@ -0,0 +1,19 @@ +sub acl { + my $dbh = shift; + + my @acls; + + my @tables = qw ( + attributes_id_seq + attributes + ); + + foreach my $table (@tables) { + push @acls, + "GRANT SELECT, INSERT, UPDATE, DELETE ON $table to " + . $RT::DatabaseUser . ";"; + + } + return (@acls); +} +1; diff --git a/rt/etc/upgrade/3.1.0/acl.SQLite b/rt/etc/upgrade/3.1.0/acl.SQLite new file mode 100755 index 0000000..73c16ae --- /dev/null +++ b/rt/etc/upgrade/3.1.0/acl.SQLite @@ -0,0 +1,4 @@ +sub acl { + return (); +} +1; diff --git a/rt/etc/upgrade/3.1.0/acl.mysql b/rt/etc/upgrade/3.1.0/acl.mysql new file mode 100755 index 0000000..73c16ae --- /dev/null +++ b/rt/etc/upgrade/3.1.0/acl.mysql @@ -0,0 +1,4 @@ +sub acl { + return (); +} +1; diff --git a/rt/etc/upgrade/3.1.0/content b/rt/etc/upgrade/3.1.0/content new file mode 100644 index 0000000..3117daf --- /dev/null +++ b/rt/etc/upgrade/3.1.0/content @@ -0,0 +1,2 @@ +# nothing to do +1; diff --git a/rt/etc/upgrade/3.1.0/schema.Informix b/rt/etc/upgrade/3.1.0/schema.Informix new file mode 100644 index 0000000..722eb70 --- /dev/null +++ b/rt/etc/upgrade/3.1.0/schema.Informix @@ -0,0 +1,17 @@ +CREATE TABLE Attributes ( + id SERIAL, + Name VARCHAR(255) DEFAULT '' NOT NULL, + Description VARCHAR(255) DEFAULT NULL, + Content BYTE, + ContentType VARCHAR(16), + ObjectType VARCHAR(25) NOT NULL, + ObjectId INTEGER DEFAULT 0 NOT NULL, + Creator INTEGER DEFAULT 0 NOT NULL, + Created DATETIME YEAR TO SECOND, + LastUpdatedBy INTEGER DEFAULT 0 NOT NULL, + LastUpdated DATETIME YEAR TO SECOND, + PRIMARY KEY (id) +); + +CREATE INDEX Attributes1 on Attributes(Name); +CREATE INDEX Attributes2 on Attributes(ObjectType, ObjectId); diff --git a/rt/etc/upgrade/3.1.0/schema.Oracle b/rt/etc/upgrade/3.1.0/schema.Oracle new file mode 100644 index 0000000..a8aae18 --- /dev/null +++ b/rt/etc/upgrade/3.1.0/schema.Oracle @@ -0,0 +1,17 @@ +CREATE SEQUENCE ATTRIBUTES_seq; +CREATE TABLE Attributes ( + id NUMBER(11,0) PRIMARY KEY, + Name VARCHAR2(255) NOT NULL, + Description VARCHAR2(255), + Content CLOB, + ContentType VARCHAR(16), + ObjectType VARCHAR2(25) NOT NULL, + ObjectId NUMBER(11,0) DEFAULT 0 NOT NULL, + Creator NUMBER(11,0) DEFAULT 0 NOT NULL, + Created DATE, + LastUpdatedBy NUMBER(11,0) DEFAULT 0 NOT NULL, + LastUpdated DATE +); + +CREATE INDEX Attributes1 on Attributes(Name); +CREATE INDEX Attributes2 on Attributes(ObjectType, ObjectId); diff --git a/rt/etc/upgrade/3.1.0/schema.Pg b/rt/etc/upgrade/3.1.0/schema.Pg new file mode 100755 index 0000000..67ea738 --- /dev/null +++ b/rt/etc/upgrade/3.1.0/schema.Pg @@ -0,0 +1,25 @@ +-- {{{ Attributes + +CREATE SEQUENCE attributes_id_seq; + +CREATE TABLE Attributes ( + id INTEGER DEFAULT nextval('attributes_id_seq'), + Name varchar(255) NOT NULL , + Description varchar(255) NULL , + Content text, + ContentType varchar(16), + ObjectType varchar(64), + ObjectId integer, -- foreign key to anything + Creator integer NOT NULL DEFAULT 0 , + Created TIMESTAMP NULL , + LastUpdatedBy integer NOT NULL DEFAULT 0 , + LastUpdated TIMESTAMP NULL , + PRIMARY KEY (id) + +); + +CREATE INDEX Attributes1 on Attributes(Name); +CREATE INDEX Attributes2 on Attributes(ObjectType, ObjectId); + +-- }}} + diff --git a/rt/etc/upgrade/3.1.0/schema.SQLite b/rt/etc/upgrade/3.1.0/schema.SQLite new file mode 100644 index 0000000..87a1cc4 --- /dev/null +++ b/rt/etc/upgrade/3.1.0/schema.SQLite @@ -0,0 +1,20 @@ +--- {{{ Attributes +CREATE TABLE Attributes ( + id INTEGER PRIMARY KEY , + Name varchar(255) NOT NULL , + Description varchar(255) NULL , + Content LONGTEXT NULL , + ContentType varchar(16), + ObjectType varchar(25) NOT NULL , + ObjectId INTEGER default 0, + Creator integer NULL , + Created DATETIME NULL , + LastUpdatedBy integer NULL , + LastUpdated DATETIME NULL + +) ; +CREATE INDEX Attributes1 on Attributes(Name) +CREATE INDEX Attributes2 on Attributes(ObjectType, ObjectId); + +--- }}} + diff --git a/rt/etc/upgrade/3.1.0/schema.mysql b/rt/etc/upgrade/3.1.0/schema.mysql new file mode 100755 index 0000000..c4a345d --- /dev/null +++ b/rt/etc/upgrade/3.1.0/schema.mysql @@ -0,0 +1,21 @@ +# {{{ Attributes + +CREATE TABLE Attributes ( + id INTEGER NOT NULL AUTO_INCREMENT, + Name varchar(255) NULL , + Description varchar(255) NULL , + Content text, + ContentType varchar(16), + ObjectType varchar(64), + ObjectId integer, # foreign key to anything + Creator integer NOT NULL DEFAULT 0 , + Created DATETIME NULL , + LastUpdatedBy integer NOT NULL DEFAULT 0 , + LastUpdated DATETIME NULL , + PRIMARY KEY (id) +) TYPE=InnoDB; + +CREATE INDEX Attributes1 on Attributes(Name); +CREATE INDEX Attributes2 on Attributes(ObjectType, ObjectId); + +# }}} diff --git a/rt/etc/upgrade/3.1.15/content b/rt/etc/upgrade/3.1.15/content new file mode 100644 index 0000000..d23125a --- /dev/null +++ b/rt/etc/upgrade/3.1.15/content @@ -0,0 +1,7 @@ +@Scrips = ( + { ScripCondition => 'On Owner Change', + ScripAction => 'Notify Owner', + Template => 'Transaction' }, +); + +1; diff --git a/rt/etc/upgrade/3.1.17/content b/rt/etc/upgrade/3.1.17/content new file mode 100644 index 0000000..1d648d8 --- /dev/null +++ b/rt/etc/upgrade/3.1.17/content @@ -0,0 +1,22 @@ +@ScripActions = ( + { Name => 'Notify Ccs as Comment', # loc + Description => 'Sends mail to the Ccs as a comment', # loc + ExecModule => 'NotifyAsComment', + Argument => 'Cc' }, + { Name => 'Notify Ccs', # loc + Description => 'Sends mail to the Ccs', # loc + ExecModule => 'Notify', + Argument => 'Cc' }, +); + + +@ScripConditions = ( + { + Name => 'On Priority Change', # loc + Description => 'Whenever a ticket\'s priority changes', # loc + ApplicableTransTypes => 'Set', + ExecModule => 'PriorityChange', + }, +); + +1; -- cgit v1.1