3 # Copyright (c) 1996-2003 Jesse Vincent <jesse@bestpractical.com>
5 # (Except where explictly superceded by other copyright notices)
7 # This work is made available to you under the terms of Version 2 of
8 # the GNU General Public License. A copy of that license should have
9 # been provided with this software, but in any event can be snarfed
12 # This work is distributed in the hope that it will be useful, but
13 # WITHOUT ANY WARRANTY; without even the implied warranty of
14 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 # General Public License for more details.
17 # Unless otherwise specified, all modifications, corrections or
18 # extensions to this work which alter its source code become the
19 # property of Best Practical Solutions, LLC when submitted for
20 # inclusion in the work.
24 # Autogenerated by DBIx::SearchBuilder factory (by <jesse@bestpractical.com>)
25 # WARNING: THIS FILE IS AUTOGENERATED. ALL CHANGES TO THIS FILE WILL BE LOST.
27 # !! DO NOT EDIT THIS FILE !!
46 package RT::Transaction;
52 @ISA= qw( RT::Record );
57 $self->Table('Transactions');
58 $self->SUPER::_Init(@_);
65 =item Create PARAMHASH
67 Create takes a hash of values and creates a row in the database:
69 int(11) 'EffectiveTicket'.
74 varchar(255) 'OldValue'.
75 varchar(255) 'NewValue'.
86 EffectiveTicket => '0',
97 EffectiveTicket => $args{'EffectiveTicket'},
98 Ticket => $args{'Ticket'},
99 TimeTaken => $args{'TimeTaken'},
100 Type => $args{'Type'},
101 Field => $args{'Field'},
102 OldValue => $args{'OldValue'},
103 NewValue => $args{'NewValue'},
104 Data => $args{'Data'},
113 Returns the current value of id.
114 (In the database, id is stored as int(11).)
120 =item EffectiveTicket
122 Returns the current value of EffectiveTicket.
123 (In the database, EffectiveTicket is stored as int(11).)
127 =item SetEffectiveTicket VALUE
130 Set EffectiveTicket to VALUE.
131 Returns (1, 'Status message') on success and (0, 'Error Message') on failure.
132 (In the database, EffectiveTicket will be stored as a int(11).)
140 Returns the current value of Ticket.
141 (In the database, Ticket is stored as int(11).)
145 =item SetTicket VALUE
149 Returns (1, 'Status message') on success and (0, 'Error Message') on failure.
150 (In the database, Ticket will be stored as a int(11).)
158 Returns the Ticket Object which has the id returned by Ticket
165 my $Ticket = RT::Ticket->new($self->CurrentUser);
166 $Ticket->Load($self->__Value('Ticket'));
172 Returns the current value of TimeTaken.
173 (In the database, TimeTaken is stored as int(11).)
177 =item SetTimeTaken VALUE
180 Set TimeTaken to VALUE.
181 Returns (1, 'Status message') on success and (0, 'Error Message') on failure.
182 (In the database, TimeTaken will be stored as a int(11).)
190 Returns the current value of Type.
191 (In the database, Type is stored as varchar(20).)
199 Returns (1, 'Status message') on success and (0, 'Error Message') on failure.
200 (In the database, Type will be stored as a varchar(20).)
208 Returns the current value of Field.
209 (In the database, Field is stored as varchar(40).)
217 Returns (1, 'Status message') on success and (0, 'Error Message') on failure.
218 (In the database, Field will be stored as a varchar(40).)
226 Returns the current value of OldValue.
227 (In the database, OldValue is stored as varchar(255).)
231 =item SetOldValue VALUE
234 Set OldValue to VALUE.
235 Returns (1, 'Status message') on success and (0, 'Error Message') on failure.
236 (In the database, OldValue will be stored as a varchar(255).)
244 Returns the current value of NewValue.
245 (In the database, NewValue is stored as varchar(255).)
249 =item SetNewValue VALUE
252 Set NewValue to VALUE.
253 Returns (1, 'Status message') on success and (0, 'Error Message') on failure.
254 (In the database, NewValue will be stored as a varchar(255).)
262 Returns the current value of Data.
263 (In the database, Data is stored as varchar(100).)
271 Returns (1, 'Status message') on success and (0, 'Error Message') on failure.
272 (In the database, Data will be stored as a varchar(100).)
280 Returns the current value of Creator.
281 (In the database, Creator is stored as int(11).)
289 Returns the current value of Created.
290 (In the database, Created is stored as datetime.)
297 sub _ClassAccessible {
301 {read => 1, type => 'int(11)', default => ''},
303 {read => 1, write => 1, type => 'int(11)', default => '0'},
305 {read => 1, write => 1, type => 'int(11)', default => '0'},
307 {read => 1, write => 1, type => 'int(11)', default => '0'},
309 {read => 1, write => 1, type => 'varchar(20)', default => ''},
311 {read => 1, write => 1, type => 'varchar(40)', default => ''},
313 {read => 1, write => 1, type => 'varchar(255)', default => ''},
315 {read => 1, write => 1, type => 'varchar(255)', default => ''},
317 {read => 1, write => 1, type => 'varchar(100)', default => ''},
319 {read => 1, auto => 1, type => 'int(11)', default => '0'},
321 {read => 1, auto => 1, type => 'datetime', default => ''},
327 eval "require RT::Transaction_Overlay";
328 if ($@ && $@ !~ qr{^Can't locate RT/Transaction_Overlay.pm}) {
332 eval "require RT::Transaction_Vendor";
333 if ($@ && $@ !~ qr{^Can't locate RT/Transaction_Vendor.pm}) {
337 eval "require RT::Transaction_Local";
338 if ($@ && $@ !~ qr{^Can't locate RT/Transaction_Local.pm}) {
347 This class allows "overlay" methods to be placed
348 into the following files _Overlay is for a System overlay by the original author,
349 _Vendor is for 3rd-party vendor add-ons, while _Local is for site-local customizations.
351 These overlay files can contain new subs or subs to replace existing subs in this module.
353 If you'll be working with perl 5.6.0 or greater, each of these files should begin with the line
355 no warnings qw(redefine);
357 so that perl does not kick and scream when you redefine a subroutine or variable in your overlay.
359 RT::Transaction_Overlay, RT::Transaction_Vendor, RT::Transaction_Local