From af29303c3139a556b353330fd028c01c566892e3 Mon Sep 17 00:00:00 2001 From: Colin Kuskie Date: Sat, 27 May 2006 17:39:05 +0000 Subject: [PATCH] Reformat Wobject template variables to use the new Help based template variable system. Break TimeTracking i18n into paragraphs for easy parsing. Add missing comment line to break POD and paragraphs in Operation/Help --- lib/WebGUI/Help/Asset_Wobject.pm | 20 +++++++ lib/WebGUI/Operation/Help.pm | 4 +- lib/WebGUI/i18n/English/Asset_TimeTracking.pm | 40 +++++++------- lib/WebGUI/i18n/English/Asset_Wobject.pm | 52 +++++++++++-------- 4 files changed, 72 insertions(+), 44 deletions(-) diff --git a/lib/WebGUI/Help/Asset_Wobject.pm b/lib/WebGUI/Help/Asset_Wobject.pm index 88f786d46..2250d27ce 100644 --- a/lib/WebGUI/Help/Asset_Wobject.pm +++ b/lib/WebGUI/Help/Asset_Wobject.pm @@ -83,6 +83,26 @@ our $HELP = { body => '828', fields => [ ], + variables => [ + { + 'name' => 'title' + }, + { + 'name' => 'displayTitle' + }, + { + 'name' => 'description' + }, + { + 'name' => 'assetId' + }, + { + 'name' => 'isShortcut' + }, + { + 'name' => 'originalURL' + }, + ], related => [ { tag => 'pagination template variables', diff --git a/lib/WebGUI/Operation/Help.pm b/lib/WebGUI/Operation/Help.pm index bad5f2b64..ed8b12c87 100644 --- a/lib/WebGUI/Operation/Help.pm +++ b/lib/WebGUI/Operation/Help.pm @@ -120,6 +120,8 @@ sub _linkTOC { return $session->url->page('op=viewHelpChapter;namespace='.$_[0]); } +#------------------------------------------------------------------- + =head2 _getHelpFilesList ( $session ) Utility routine for returning a list of all Help files in the lib/WebGUI/Help folder. @@ -302,7 +304,7 @@ sub _getTemplateVars { } push ( @{$template}, { title => $row->{name}, - description=> $i18n->get($row->{description} || $row->{name}, $row->{namespace}), + description=> $i18n->get(($row->{description} || $row->{name}), $row->{namespace}), $label => $indent }); } diff --git a/lib/WebGUI/i18n/English/Asset_TimeTracking.pm b/lib/WebGUI/i18n/English/Asset_TimeTracking.pm index e79a797d7..a883b41e4 100644 --- a/lib/WebGUI/i18n/English/Asset_TimeTracking.pm +++ b/lib/WebGUI/i18n/English/Asset_TimeTracking.pm @@ -30,12 +30,12 @@ our $I18N = { message => q|Group to Manage Time|, lastUpdated => 0 }, - + 'timeRowTemplateId hoverhelp' => { message => q|Template to user for building rows in the time tracker|, lastUpdated => 0 }, - + 'timeRowTemplateId label' => { message => q|Default Time Tracker Row|, lastUpdated => 0 @@ -45,7 +45,7 @@ our $I18N = { message => q|Time Tracking System|, lastUpdated => 0 }, - + 'time report header' => { message => q|Time entry for week ending %s|, lastUpdated => 0 @@ -55,17 +55,17 @@ our $I18N = { message => q|Total Hours|, lastUpdated => 0 }, - + 'time report date label' => { message => q|Date|, lastUpdated => 0 }, - + 'time report project label' => { message => q|Project|, lastUpdated => 0 }, - + 'time report task label' => { message => q|Task|, lastUpdated => 0 @@ -75,27 +75,27 @@ our $I18N = { message => q|Hours|, lastUpdated => 0 }, - + 'time report comments label' => { message => q|Comments|, lastUpdated => 0 }, - + 'project manage label' => { message => q|Manage Projects|, lastUpdated => 0 }, - + 'manage project name label' => { message => q|Project Name|, lastUpdated => 0 }, - + 'manage project available task label' => { message => q|Available Tasks|, lastUpdated => 0 }, - + 'manage project resource label' => { message => q|Available Resources|, lastUpdated => 0 @@ -105,17 +105,17 @@ our $I18N = { message => q|Manage Projects|, lastUpdated => 0 }, - + 'add project label' => { message => q|Add New Project|, lastUpdated => 0 }, - + 'edit project label' => { message => q|Edit Project|, lastUpdated => 0 }, - + 'edit project name label' => { message => q|Project Name|, lastUpdated => 0 @@ -125,12 +125,12 @@ our $I18N = { message => q|Enter the name of the project you wish to show up in the projects drop down menu for this time tracker|, lastUpdated => 0 }, - + 'edit project id label' => { message => q|Project Id|, lastUpdated => 0 }, - + 'edit project id hoverhelp' => { message => q|Project Identifier|, lastUpdated => 0 @@ -144,12 +144,12 @@ our $I18N = { message => q|Project Resource|, lastUpdated => 0 }, - + 'edit project tasks label' => { message => q|Project Tasks|, lastUpdated => 0 }, - + 'edit project tasks hoverhelp' => { message => q|Enter the project tasks, one per line, that you would like to track time against for this project|, lastUpdated => 0 @@ -159,12 +159,12 @@ our $I18N = { message => q|Edit Project|, lastUpdated => 0 }, - + 'no project message' => { message => q|No projects created. Click here to add a new project|, lastUpdated => 0 }, - + '' => { message => q||, lastUpdated => 0 diff --git a/lib/WebGUI/i18n/English/Asset_Wobject.pm b/lib/WebGUI/i18n/English/Asset_Wobject.pm index d9ae28d1f..0ef856432 100644 --- a/lib/WebGUI/i18n/English/Asset_Wobject.pm +++ b/lib/WebGUI/i18n/English/Asset_Wobject.pm @@ -2,35 +2,40 @@ package WebGUI::i18n::English::Asset_Wobject; our $I18N = { - '828' => { - lastUpdated => 1053469640, - message => q|

Most wobjects have templates that allow you to change the layout of the wobject's user interface. Those wobjects that do have templates all have a common set of template variables that you can use for layout, as well as their own custom variables. The following is a list of the common template variables shared among all wobjects.

+ 'title' => { + message => q|The title for this wobject.|, + lastUpdated => 1148750705, + }, -

title
-The title for this wobject. -

+ 'displayTitle' => { + message => q|A conditional variable for whether or not the title should be displayed.|, + lastUpdated => 1148750705, + }, -

displayTitle
-A conditional variable for whether or not the title should be displayed. -

+ 'description' => { + message => q|The description of this wobject.|, + lastUpdated => 1148750705, + }, -

description
-The description of this wobject. -

+ 'assetId' => { + message => q|The unique identifier that WebGUI uses to control this asset.|, + lastUpdated => 1148750705, + }, -

assetId
-The unique identifier that WebGUI uses to control this asset. -

+ 'isShortcut' => { + message => q|A conditional indicating if this wobject is a shortcut to an original asset.|, + lastUpdated => 1148750705, + }, -

isShortcut
-A conditional indicating if this wobject is a shortcut to an original asset. -

+ 'originalURL' => { + message => q|If this wobject is a shortcut, then this URL will direct you to the original asset.|, + lastUpdated => 1148750705, + }, -

originalURL
-If this wobject is a shortcut, then this URL will direct you to the original asset. -

- -| + '828' => { + message => q|

Most wobjects have templates that allow you to change the layout of the wobject's user interface. Those wobjects that do have templates all have a common set of template variables that you can use for layout, as well as their own custom variables. The following is a list of the common template variables shared among all wobjects.

+|, + lastUpdated => 1148750840, }, '1079' => { lastUpdated => 1073152790, @@ -40,6 +45,7 @@ If this wobject is a shortcut, then this URL will direct you to the original ass lastUpdated => 1052046436, message => q|Wobject Template| }, + '632' => { lastUpdated => 1119410914, message => q|

You can add wobjects by selecting from the ^International("1","WebGUI"); pulldown menu. You can edit them by clicking on the "Edit" button that appears directly above an instance of a particular wobject while in Admin mode.