[Bps-public-commit] r14686 - in Prophet/trunk: .

spang at bestpractical.com spang at bestpractical.com
Thu Jul 31 07:47:15 EDT 2008


Author: spang
Date: Thu Jul 31 07:47:12 2008
New Revision: 14686

Modified:
   Prophet/trunk/   (props changed)
   Prophet/trunk/lib/Prophet/CLI/Command/Create.pm

Log:
 r47462 at loki:  spang | 2008-07-31 12:35:40 +0100
 make create stow the newly created record object in an attribute


Modified: Prophet/trunk/lib/Prophet/CLI/Command/Create.pm
==============================================================================
--- Prophet/trunk/lib/Prophet/CLI/Command/Create.pm	(original)
+++ Prophet/trunk/lib/Prophet/CLI/Command/Create.pm	Thu Jul 31 07:47:12 2008
@@ -4,6 +4,12 @@
 with 'Prophet::CLI::RecordCommand';
 has '+uuid' => ( required => 0);
 
+has record => (
+    is  => 'rw',
+    isa => 'Prophet::Record',
+    documentation => 'The record object of the created record.',
+);
+
 sub run {
     my $self   = shift;
     my $record = $self->_get_record_class;
@@ -16,8 +22,9 @@
         return;
     }
 
-    print "Created " . $record->record_type . " " . $record->luid . " (".$record->uuid.")"."\n";
+    $self->record($record);
 
+    print "Created " . $record->record_type . " " . $record->luid . " (".$record->uuid.")"."\n";
 }
 
 __PACKAGE__->meta->make_immutable;



More information about the Bps-public-commit mailing list