Complete rework of Story autocommit.

Tests for status of Stories that have been autocommitted.
Keyword search interface with UI and tests.
This commit is contained in:
Colin Kuskie 2009-03-09 20:59:28 +00:00
parent 6dc31e64ae
commit 9487b7d4ac
4 changed files with 150 additions and 50 deletions

View file

@ -60,6 +60,8 @@ sub addChild {
Copy storage locations so that purging individual revisions works correctly.
Request autocommit.
=cut
sub addRevision {
@ -76,6 +78,7 @@ sub addRevision {
}
$newSelf->update($newProperties);
$newSelf->requestAutoCommit;
return $newSelf;
}
@ -233,6 +236,27 @@ sub getArchive {
return $self->{_archive};
}
#-------------------------------------------------------------------
=head2 getAutoCommitWorkflowId ( )
Get the autocommit workflow from the archive containing this Story and
use it.
=cut
sub getAutoCommitWorkflowId {
my $self = shift;
my $archive = $self->getArchive;
if ($archive->hasBeenCommitted) {
$self->session->log->warn($archive->get('approvalWorkflowId'));
return $archive->get('approvalWorkflowId')
|| $self->session->setting->get('defaultVersionTagWorkflow');
}
return undef;
}
#-------------------------------------------------------------------
=head2 getEditForm ( )