[Rt-commit] r15417 - in rt/branches/3.999-DANGEROUS: . lib/RT lib/RT/Model t/web
sunnavy at bestpractical.com
sunnavy at bestpractical.com
Sun Aug 24 22:47:43 EDT 2008
Author: sunnavy
Date: Sun Aug 24 22:47:42 2008
New Revision: 15417
Modified:
rt/branches/3.999-DANGEROUS/ (props changed)
rt/branches/3.999-DANGEROUS/lib/RT/Model/CustomField.pm
rt/branches/3.999-DANGEROUS/lib/RT/Model/Queue.pm
rt/branches/3.999-DANGEROUS/lib/RT/Record.pm
rt/branches/3.999-DANGEROUS/t/ticket/action_linear_escalate.t
rt/branches/3.999-DANGEROUS/t/web/cf_onqueue.t
Log:
r16035 at sunnavys-mb: sunnavy | 2008-08-25 10:47:22 +0800
mainly fix cases
Modified: rt/branches/3.999-DANGEROUS/lib/RT/Model/CustomField.pm
==============================================================================
--- rt/branches/3.999-DANGEROUS/lib/RT/Model/CustomField.pm (original)
+++ rt/branches/3.999-DANGEROUS/lib/RT/Model/CustomField.pm Sun Aug 24 22:47:42 2008
@@ -276,7 +276,8 @@
return ( $rv, $msg ) unless exists $args{'queue'};
# Compat code -- create a new ObjectCustomField mapping
- my $OCF = RT::Model::ObjectCustomField->new;
+ my $OCF =
+ RT::Model::ObjectCustomField->new( current_user => RT->system_user );
$OCF->create(
custom_field => $self->id,
object_id => $args{'queue'},
Modified: rt/branches/3.999-DANGEROUS/lib/RT/Model/Queue.pm
==============================================================================
--- rt/branches/3.999-DANGEROUS/lib/RT/Model/Queue.pm (original)
+++ rt/branches/3.999-DANGEROUS/lib/RT/Model/Queue.pm Sun Aug 24 22:47:42 2008
@@ -96,7 +96,7 @@
column final_priority => max_length is 11, type is 'int', default is '0';
column default_due_in => max_length is 11, type is 'int', default is '0';
column creator => references RT::Model::User;
- column Created => type is 'timestamp';
+ column created => type is 'timestamp';
column last_updated_by => references RT::Model::User;
column last_updated => type is 'timestamp';
column disabled => max_length is 6, type is 'smallint', default is '0';
Modified: rt/branches/3.999-DANGEROUS/lib/RT/Record.pm
==============================================================================
--- rt/branches/3.999-DANGEROUS/lib/RT/Record.pm (original)
+++ rt/branches/3.999-DANGEROUS/lib/RT/Record.pm Sun Aug 24 22:47:42 2008
@@ -113,10 +113,10 @@
my $self = shift;
my ($rv) = $self->SUPER::delete;
if ($rv) {
- return ( $rv, _("object deleted") );
+ return ( $rv, _("Object deleted") );
} else {
- return ( 0, _("object could not be deleted") );
+ return ( 0, _("Object could not be deleted") );
}
}
@@ -294,7 +294,7 @@
unless ($id) {
if (wantarray) {
- return ( $id, _('object could not be Created') );
+ return ( $id, _('Object could not be created') );
} else {
return ($id);
}
@@ -308,7 +308,7 @@
$self->load($id) if ($id);
if (wantarray) {
- return ( $id, _('object Created') );
+ return ( $id, _('Object created') );
} else {
return ($id);
}
Modified: rt/branches/3.999-DANGEROUS/t/ticket/action_linear_escalate.t
==============================================================================
--- rt/branches/3.999-DANGEROUS/t/ticket/action_linear_escalate.t (original)
+++ rt/branches/3.999-DANGEROUS/t/ticket/action_linear_escalate.t Sun Aug 24 22:47:42 2008
@@ -71,7 +71,7 @@
my $due = RT::Date->new( current_user => RT->system_user );
$due->unix(time() + ( 7 * 24 * 60**2 ));
- my $ticket = RT::Model::Ticket->new($user);
+ my $ticket = RT::Model::Ticket->new( current_user => $user);
($id, $msg) = $ticket->create( queue => $q->id,
subject => "Escalation test",
priority => 0,
Modified: rt/branches/3.999-DANGEROUS/t/web/cf_onqueue.t
==============================================================================
--- rt/branches/3.999-DANGEROUS/t/web/cf_onqueue.t (original)
+++ rt/branches/3.999-DANGEROUS/t/web/cf_onqueue.t Sun Aug 24 22:47:42 2008
@@ -38,7 +38,7 @@
$m->submit_form(
form_name => 'edit_custom_fields',
fields => {
- 'Object--CF-1' => '1',
+ 'object--CF-1' => '1',
},
);
$m->content_like( qr/Object created/, 'CF QueueCFTest enabled globally' );
@@ -54,9 +54,9 @@
$m->submit_form(
form_number => 3,
# The following doesn't want to works :(
- #with_fields => { 'Object-RT::Model::Queue-1-CustomField-1-Value' },
+ #with_fields => { 'object-RT::Model::Queue-1-CustomField-1-value' },
fields => {
- 'Object-RT::Model::Queue-1-CustomField-1-Value' => 'QueueCFTest content',
+ 'object-RT::Model::Queue-1-CustomField-1-value' => 'QueueCFTest content',
},
);
$m->content_like( qr/QueueCFTest QueueCFTest content added/, 'Content filed in CF QueueCFTest for default queue' );
More information about the Rt-commit
mailing list