rfe #640: Refactored autocommit and autocomment
Autocommit assets like CS posts or Calendar Events can now be added before the parent is committed. They will go into the same version tag as their parent.
This commit is contained in:
parent
71fc839c83
commit
99a9da626d
22 changed files with 218 additions and 259 deletions
|
|
@ -371,21 +371,13 @@ sub www_manage {
|
|||
}
|
||||
}
|
||||
|
||||
# Handle Auto Request Commit setting
|
||||
if ($session->setting->get("autoRequestCommit")) {
|
||||
# Make sure version tag hasn't already been committed by another process
|
||||
my $versionTag = WebGUI::VersionTag->getWorking($session, "nocreate");
|
||||
|
||||
if ($versionTag && $session->setting->get("skipCommitComments")) {
|
||||
$versionTag->requestCommit;
|
||||
}
|
||||
elsif ($versionTag) {
|
||||
$session->http->setRedirect(
|
||||
$currentAsset->getUrl("op=commitVersionTag;tagId=".WebGUI::VersionTag->getWorking($session)->getId)
|
||||
);
|
||||
return undef;
|
||||
}
|
||||
}
|
||||
# Handle autocommit workflows
|
||||
if (WebGUI::VersionTag->autoCommitWorkingIfEnabled($session, {
|
||||
allowComments => 1,
|
||||
returnUrl => $currentAsset->getUrl,
|
||||
})) {
|
||||
return undef;
|
||||
};
|
||||
|
||||
# Show the page
|
||||
# i18n we'll need later
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue