- Fixed a bug where a blank page would be displayed if a user logged out on a
page that visitors could not access. - Fixed a bug in the make printable macro that used the wrong default template. - Added a context menu to inline editing that is accessible by right-click or by left-click-hold on the asset's class icon. - The context menu in the asset manager is now accessible via left-click-hold for more familiarity with mac users. - Added "create shortcut" as a context menu option in the asset manager.
This commit is contained in:
parent
626356fe09
commit
504c88e293
10 changed files with 213 additions and 137 deletions
|
|
@ -805,7 +805,7 @@ manager.disableDisplay(0) is added to the script if parameter is defined.
|
|||
sub getAssetManagerControl {
|
||||
my $self = shift;
|
||||
my $children = shift;
|
||||
my $controlType = shift;
|
||||
my $controlType = shift || "ManageAssets";
|
||||
my $removeRank = shift;
|
||||
WebGUI::Style::setLink($session{config}{extrasURL}.'/assetManager/assetManager.css', {rel=>"stylesheet",type=>"text/css"});
|
||||
WebGUI::Style::setScript($session{config}{extrasURL}.'/assetManager/Tools.js', {type=>"text/javascript"});
|
||||
|
|
@ -816,7 +816,7 @@ sub getAssetManagerControl {
|
|||
WebGUI::Style::setScript($session{config}{extrasURL}.'/assetManager/AssetManager.js', {type=>"text/javascript"});
|
||||
WebGUI::Style::setScript($session{config}{extrasURL}.'/assetManager/AssetManagerAsset.js', {type=>"text/javascript"});
|
||||
WebGUI::Style::setScript($session{config}{extrasURL}.'/assetManager/CrumbTrailAsset.js', {type=>"text/javascript"});
|
||||
WebGUI::Style::setScript($session{config}{extrasURL}.'/assetManager/'.$controlType.'.js', {type=>"text/javascript"}) if (defined $controlType);
|
||||
WebGUI::Style::setScript($session{config}{extrasURL}.'/assetManager/'.$controlType.'.js', {type=>"text/javascript"});# if (defined $controlType);
|
||||
my $output = '
|
||||
<div id="contextMenu" class="contextMenu"></div>
|
||||
<div id="propertiesWindow" class="propertiesWindow"></div>
|
||||
|
|
@ -855,8 +855,9 @@ sub getAssetManagerControl {
|
|||
$output .= "labels['view'] = 'View';\n";
|
||||
$output .= "labels['delete'] = 'Delete';\n";
|
||||
$output .= "labels['restore'] = 'Restore';\n";
|
||||
$output .= "labels['shortcut'] = 'Create Shortcut';\n";
|
||||
$output .= "labels['purge'] = 'Purge';\n";
|
||||
$output .= "labels['go'] = 'Go';\n";
|
||||
$output .= "labels['go'] = 'Manage';\n";
|
||||
$output .= "labels['properties'] = 'Properties';\n";
|
||||
$output .= "labels['editTree'] = 'Edit Branch';\n";
|
||||
$output .= "var manager = new AssetManager(assets,columnHeadings,labels,crumbtrail);\n";
|
||||
|
|
@ -1319,7 +1320,7 @@ sub getLineage {
|
|||
my @familyTree = ($lineage =~ /(.{6})/g);
|
||||
while (pop(@familyTree)) {
|
||||
push(@specificFamilyMembers,join("",@familyTree)) if (scalar(@familyTree));
|
||||
last if ($i >= $rules->{ancestorLimit});
|
||||
last if ($i >= $rules->{ancestorLimit} && exists $rules->{ancestorLimit});
|
||||
$i++;
|
||||
}
|
||||
}
|
||||
|
|
@ -1655,8 +1656,6 @@ sub getToolbar {
|
|||
my $self = shift;
|
||||
my $toolbar = deleteIcon('func=delete',$self->get("url"),WebGUI::International::get(43,"Asset"))
|
||||
.editIcon('func=edit',$self->get("url"))
|
||||
.moveUpIcon('func=promote',$self->get("url"))
|
||||
.moveDownIcon('func=demote',$self->get("url"))
|
||||
.cutIcon('func=cut',$self->get("url"))
|
||||
.copyIcon('func=copy',$self->get("url"));
|
||||
$toolbar .= shortcutIcon('func=createShortcut',$self->get("url")) unless ($self->get("className") =~ /Shortcut/);
|
||||
|
|
@ -1667,8 +1666,8 @@ sub getToolbar {
|
|||
var contextMenu = new contextMenu_create("'.$self->getIcon(1).'","'.$self->getId.'","'.$self->getName.'");
|
||||
contextMenu.addLink("'.$self->getUrl("func=promote").'","Promote");
|
||||
contextMenu.addLink("'.$self->getUrl("func=demote").'","Demote");
|
||||
contextMenu.addLink("'.$self->getUrl("func=createShortcut").'","Create Shortcut");
|
||||
contextMenu.addLink("'.$self->getUrl("func=manageAssets").'","Manage");
|
||||
contextMenu.addLink("'.$self->getUrl.'","View");
|
||||
contextMenu.draw();
|
||||
</script>'.$toolbar;
|
||||
}
|
||||
|
|
@ -2510,6 +2509,7 @@ sub www_createShortcut () {
|
|||
templateId=>'PBtmpl0000000000000140'
|
||||
});
|
||||
$child->cut;
|
||||
return $self->getContainer->www_manageAssets if ($session{form}{proceed} eq "manageAssets");
|
||||
return $self->getContainer->www_view;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -1195,7 +1195,7 @@ sub HTMLArea {
|
|||
if ($session{user}{richEditor} eq 'none') {
|
||||
return $var{textarea};
|
||||
} else {
|
||||
return WebGUI::Asset::Template->new($session{user}{richEditor})->process(\%var);
|
||||
#return WebGUI::Asset::Template->new($session{user}{richEditor})->process(\%var);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -38,7 +38,11 @@ sub process {
|
|||
} else {
|
||||
$var{'printable.text'} = WebGUI::International::get(53,'Macro_r_printable');
|
||||
}
|
||||
$temp = WebGUI::Asset::Template->newByUrl($param[2] || "default_make_printable")->process(\%var);
|
||||
if ($param[2]) {
|
||||
$temp = WebGUI::Asset::Template->newByUrl($param[2])->process(\%var);
|
||||
} else {
|
||||
$temp = WebGUI::Asset::Template->new("PBtmpl0000000000000045")->process(\%var);
|
||||
}
|
||||
}
|
||||
return $temp;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -53,7 +53,7 @@ sub www_auth {
|
|||
my $auth;
|
||||
($auth) = WebGUI::SQL->quickArray("select authMethod from users where username=".quote($session{form}{username})) if($session{form}{username});
|
||||
my $authMethod = getInstance($auth);
|
||||
my $methodCall = $session{form}{method} || $_[0] || "init";
|
||||
my $methodCall = shift || $session{form}{method} || "init";
|
||||
if(!$authMethod->isCallable($methodCall)){
|
||||
WebGUI::ErrorHandler::security("access uncallable auth method on page '".$session{page}{title}."' [".$session{page}{pageId}."].");
|
||||
return WebGUI::International::get(1077);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue