fixing bug created by new language system

This commit is contained in:
JT Smith 2004-06-27 16:06:09 +00:00
parent dae0123fae
commit 078a5ca108
2 changed files with 17 additions and 17 deletions

View file

@ -52,15 +52,15 @@ sub _reorderFields {
sub _submenu { sub _submenu {
my (%menu); my (%menu);
tie %menu, 'Tie::IxHash'; tie %menu, 'Tie::IxHash';
$menu{WebGUI::URL::page("op=editProfileCategory")} = WebGUI::International::get(490,"WebGUI-Profile"); $menu{WebGUI::URL::page("op=editProfileCategory")} = WebGUI::International::get(490,"WebGUIProfile");
$menu{WebGUI::URL::page("op=editProfileField")} = WebGUI::International::get(491,"WebGUI-Profile"); $menu{WebGUI::URL::page("op=editProfileField")} = WebGUI::International::get(491,"WebGUIProfile");
if (($session{form}{op} eq "editProfileField" && $session{form}{fid} ne "new") || $session{form}{op} eq "deleteProfileField") { if (($session{form}{op} eq "editProfileField" && $session{form}{fid} ne "new") || $session{form}{op} eq "deleteProfileField") {
$menu{WebGUI::URL::page('op=editProfileField&fid='.$session{form}{fid})} = WebGUI::International::get(787,"WebGUI-Profile"); $menu{WebGUI::URL::page('op=editProfileField&fid='.$session{form}{fid})} = WebGUI::International::get(787,"WebGUIProfile");
$menu{WebGUI::URL::page('op=deleteProfileField&fid='.$session{form}{fid})} = WebGUI::International::get(788,"WebGUI-Profile"); $menu{WebGUI::URL::page('op=deleteProfileField&fid='.$session{form}{fid})} = WebGUI::International::get(788,"WebGUIProfile");
} }
if (($session{form}{op} eq "editProfileCategory" && $session{form}{cid} ne "new") || $session{form}{op} eq "deleteProfileCategory") { if (($session{form}{op} eq "editProfileCategory" && $session{form}{cid} ne "new") || $session{form}{op} eq "deleteProfileCategory") {
$menu{WebGUI::URL::page('op=editProfileCategory&cid='.$session{form}{cid})} = WebGUI::International::get(789,"WebGUI-Profile"); $menu{WebGUI::URL::page('op=editProfileCategory&cid='.$session{form}{cid})} = WebGUI::International::get(789,"WebGUIProfile");
$menu{WebGUI::URL::page('op=deleteProfileCategory&cid='.$session{form}{cid})} = WebGUI::International::get(790,"WebGUI-Profile"); $menu{WebGUI::URL::page('op=deleteProfileCategory&cid='.$session{form}{cid})} = WebGUI::International::get(790,"WebGUIProfile");
} }
$menu{WebGUI::URL::page("op=editProfileSettings")} = WebGUI::International::get(492); $menu{WebGUI::URL::page("op=editProfileSettings")} = WebGUI::International::get(492);
$menu{WebGUI::URL::page('op=manageSettings')} = WebGUI::International::get(4); $menu{WebGUI::URL::page('op=manageSettings')} = WebGUI::International::get(4);
@ -73,7 +73,7 @@ sub www_deleteProfileCategory {
my ($output); my ($output);
return WebGUI::Privilege::vitalComponent() if ($session{form}{cid} < 1000); return WebGUI::Privilege::vitalComponent() if ($session{form}{cid} < 1000);
$output = '<h1>'.WebGUI::International::get(42).'</h1>'; $output = '<h1>'.WebGUI::International::get(42).'</h1>';
$output .= WebGUI::International::get(466,"WebGUI-Profile").'<p>'; $output .= WebGUI::International::get(466,"WebGUIProfile").'<p>';
$output .= '<div align="center"><a href="'.WebGUI::URL::page('op=deleteProfileCategoryConfirm&cid='.$session{form}{cid}). $output .= '<div align="center"><a href="'.WebGUI::URL::page('op=deleteProfileCategoryConfirm&cid='.$session{form}{cid}).
'">'.WebGUI::International::get(44).'</a>'; '">'.WebGUI::International::get(44).'</a>';
$output .= '&nbsp;&nbsp;&nbsp;&nbsp;<a href="'.WebGUI::URL::page('op=editProfileSettings').'">'. $output .= '&nbsp;&nbsp;&nbsp;&nbsp;<a href="'.WebGUI::URL::page('op=editProfileSettings').'">'.
@ -97,7 +97,7 @@ sub www_deleteProfileField {
($protected) = WebGUI::SQL->quickArray("select protected from userProfileField where fieldname=".quote($session{form}{fid})); ($protected) = WebGUI::SQL->quickArray("select protected from userProfileField where fieldname=".quote($session{form}{fid}));
return WebGUI::Privilege::vitalComponent() if ($protected); return WebGUI::Privilege::vitalComponent() if ($protected);
$output = '<h1>'.WebGUI::International::get(42).'</h1>'; $output = '<h1>'.WebGUI::International::get(42).'</h1>';
$output .= WebGUI::International::get(467,"WebGUI-Profile").'<p>'; $output .= WebGUI::International::get(467,"WebGUIProfile").'<p>';
$output .= '<div align="center"><a href="'.WebGUI::URL::page('op=deleteProfileFieldConfirm&fid='.$session{form}{fid}). $output .= '<div align="center"><a href="'.WebGUI::URL::page('op=deleteProfileFieldConfirm&fid='.$session{form}{fid}).
'">'.WebGUI::International::get(44).'</a>'; '">'.WebGUI::International::get(44).'</a>';
$output .= '&nbsp;&nbsp;&nbsp;&nbsp;<a href="'.WebGUI::URL::page('op=editProfileSettings').'">'. $output .= '&nbsp;&nbsp;&nbsp;&nbsp;<a href="'.WebGUI::URL::page('op=editProfileSettings').'">'.
@ -121,7 +121,7 @@ sub www_editProfileCategory {
return WebGUI::Privilege::adminOnly() unless (WebGUI::Grouping::isInGroup(3)); return WebGUI::Privilege::adminOnly() unless (WebGUI::Grouping::isInGroup(3));
my ($output, $f, %data); my ($output, $f, %data);
tie %data, 'Tie::CPHash'; tie %data, 'Tie::CPHash';
$output = '<h1>'.WebGUI::International::get(468,"WebGUI-Profile").'</h1>'; $output = '<h1>'.WebGUI::International::get(468,"WebGUIProfile").'</h1>';
$f = WebGUI::HTMLForm->new; $f = WebGUI::HTMLForm->new;
$f->hidden("op","editProfileCategorySave"); $f->hidden("op","editProfileCategorySave");
if ($session{form}{cid}) { if ($session{form}{cid}) {
@ -134,13 +134,13 @@ sub www_editProfileCategory {
$f->text("categoryName",WebGUI::International::get(470),$data{categoryName}); $f->text("categoryName",WebGUI::International::get(470),$data{categoryName});
$f->yesNo( $f->yesNo(
-name=>"visible", -name=>"visible",
-label=>WebGUI::International::get(473,"WebGUI-Profile"), -label=>WebGUI::International::get(473,"WebGUIProfile"),
-value=>$data{visible} -value=>$data{visible}
); );
$f->yesNo( $f->yesNo(
-name=>"editable", -name=>"editable",
-value=>$data{editable}, -value=>$data{editable},
-label=>WebGUI::International::get(897,"WebGUI-Profile") -label=>WebGUI::International::get(897,"WebGUIProfile")
); );
$f->submit; $f->submit;
$output .= $f->print; $output .= $f->print;
@ -171,7 +171,7 @@ sub www_editProfileField {
return WebGUI::Privilege::adminOnly() unless (WebGUI::Grouping::isInGroup(3)); return WebGUI::Privilege::adminOnly() unless (WebGUI::Grouping::isInGroup(3));
my ($output, $f, %data, %hash, $key); my ($output, $f, %data, %hash, $key);
tie %data, 'Tie::CPHash'; tie %data, 'Tie::CPHash';
$output = '<h1>'.WebGUI::International::get(471,"WebGUI-Profile").'</h1>'; $output = '<h1>'.WebGUI::International::get(471,"WebGUIProfile").'</h1>';
$f = WebGUI::HTMLForm->new; $f = WebGUI::HTMLForm->new;
$f->hidden("op","editProfileFieldSave"); $f->hidden("op","editProfileFieldSave");
if ($session{form}{fid}) { if ($session{form}{fid}) {
@ -185,17 +185,17 @@ sub www_editProfileField {
$f->text("fieldLabel",WebGUI::International::get(472),$data{fieldLabel}); $f->text("fieldLabel",WebGUI::International::get(472),$data{fieldLabel});
$f->yesNo( $f->yesNo(
-name=>"visible", -name=>"visible",
-label=>WebGUI::International::get(473,"WebGUI-Profile"), -label=>WebGUI::International::get(473,"WebGUIProfile"),
-value=>$data{visible} -value=>$data{visible}
); );
$f->yesNo( $f->yesNo(
-name=>"editable", -name=>"editable",
-value=>$data{editable}, -value=>$data{editable},
-label=>WebGUI::International::get(897,"WebGUI-Profile") -label=>WebGUI::International::get(897,"WebGUIProfile")
); );
$f->yesNo( $f->yesNo(
-name=>"required", -name=>"required",
-label=>WebGUI::International::get(474,"WebGUI-Profile"), -label=>WebGUI::International::get(474,"WebGUIProfile"),
-value=>$data{required} -value=>$data{required}
); );
$f->fieldType( $f->fieldType(
@ -213,7 +213,7 @@ sub www_editProfileField {
$f->select( $f->select(
-name=>"profileCategoryId", -name=>"profileCategoryId",
-options=>\%hash, -options=>\%hash,
-label=>WebGUI::International::get(489,"WebGUI-Profile"), -label=>WebGUI::International::get(489,"WebGUIProfile"),
-value=>[$data{profileCategoryId}] -value=>[$data{profileCategoryId}]
); );
$f->submit; $f->submit;

View file

@ -1,4 +1,4 @@
package WebGUI::i18n::English::WebGUI-Profile; package WebGUI::i18n::English::WebGUIProfile;
our $I18N = { our $I18N = {
471 => q|Edit User Profile Field|, 471 => q|Edit User Profile Field|,