some changes
This commit is contained in:
parent
1869017ff3
commit
30fa2028ff
4 changed files with 152 additions and 19 deletions
|
|
@ -58,16 +58,16 @@ sub definition {
|
|||
purchaseTemplate => {
|
||||
tab => "display",
|
||||
fieldType => "template",
|
||||
namespace => "AdSku",
|
||||
defaultValue => 'eqb9sWjFEVq0yHunGV8IGw', # TODO
|
||||
namespace => "AdSku/Purchase",
|
||||
defaultValue => 'R5zzB-ElsYbbiaS7aS3Uxw',
|
||||
label => $i18n->get("property purchase template"),
|
||||
hoverHelp => $i18n->get("property purchase template help"),
|
||||
},
|
||||
manageTemplate => {
|
||||
tab => "display",
|
||||
fieldType => "template",
|
||||
namespace => "AdSku",
|
||||
defaultValue => 'eqb9sWjFEVq0yHunGV8IGw', # TODO
|
||||
namespace => "AdSku/Manage",
|
||||
defaultValue => 'xZyizWwkApUyvpHL9mI-FQ',
|
||||
label => $i18n->get("property manage template"),
|
||||
hoverHelp => $i18n->get("property manage template help"),
|
||||
},
|
||||
|
|
@ -78,6 +78,13 @@ sub definition {
|
|||
label => $i18n->get("property ad space"),
|
||||
hoverHelp => $i18n->get("property ad Space help"),
|
||||
},
|
||||
priority => {
|
||||
tab => "properties",
|
||||
defaultValue => '1',
|
||||
fieldType => "integer",
|
||||
label => $i18n->get("property priority"),
|
||||
hoverHelp => $i18n->get("property priority help"),
|
||||
},
|
||||
pricePerClick => {
|
||||
tab => "properties",
|
||||
defaultValue => '0.00',
|
||||
|
|
|
|||
|
|
@ -63,17 +63,9 @@ The following additional parameters have been added via this sub class.
|
|||
|
||||
How many rows should be displayed at once? Defaults to 1.
|
||||
|
||||
=head4 multiple
|
||||
|
||||
Set to "1" if multiple groups should be selectable. Defaults to 0.
|
||||
|
||||
=head4 excludeGroups
|
||||
|
||||
An array reference containing a list of groups to exclude from the list. Defaults to an empty array reference.
|
||||
|
||||
=head4 defaultValue
|
||||
|
||||
This will be used if no value is specified. Should be passed as an array reference. Defaults to 7 (Everyone).
|
||||
This will be used if no value is specified. Should be passed as an array reference. Defaults to 1.
|
||||
|
||||
=cut
|
||||
|
||||
|
|
@ -86,7 +78,7 @@ sub definition {
|
|||
defaultValue=>1
|
||||
},
|
||||
defaultValue=>{
|
||||
defaultValue=>[7]
|
||||
defaultValue=>[1]
|
||||
},
|
||||
});
|
||||
return $class->SUPER::definition($session, $definition);
|
||||
|
|
@ -114,7 +106,7 @@ Returns the human readable name of this control.
|
|||
|
||||
sub getName {
|
||||
my ($self, $session) = @_;
|
||||
return WebGUI::International->new($session, 'WebGUI')->get('Ad Space');
|
||||
return WebGUI::International->new($session, 'WebGUI')->get('Ad Space control name');
|
||||
}
|
||||
|
||||
#-------------------------------------------------------------------
|
||||
|
|
@ -127,9 +119,9 @@ Formats as a name.
|
|||
|
||||
sub getValueAsHtml {
|
||||
my $self = shift;
|
||||
my $group = WebGUI::Group->new($self->session, $self->getOriginalValue);
|
||||
if (defined $group) {
|
||||
return $group->name;
|
||||
my $item = WebGUI::AdSpace->new($self->session, $self->getOriginalValue);
|
||||
if (defined $item) {
|
||||
return $item->name;
|
||||
}
|
||||
return undef;
|
||||
}
|
||||
|
|
@ -186,7 +178,7 @@ Renders the form field to HTML as a table row complete with labels, subtext, hov
|
|||
sub toHtmlWithWrapper {
|
||||
my $self = shift;
|
||||
if ($self->session->user->isAdmin) {
|
||||
my $subtext = $self->session->icon->manage("op=listGroups");
|
||||
my $subtext = $self->session->icon->manage("op=manageAdSpaces");
|
||||
$self->set("subtext",$subtext . $self->get("subtext"));
|
||||
}
|
||||
return $self->SUPER::toHtmlWithWrapper;
|
||||
|
|
|
|||
128
lib/WebGUI/i18n/English/Asset_AdSku.pm
Normal file
128
lib/WebGUI/i18n/English/Asset_AdSku.pm
Normal file
|
|
@ -0,0 +1,128 @@
|
|||
package WebGUI::i18n::English::Asset_AdSku;
|
||||
use strict;
|
||||
|
||||
our $I18N = {
|
||||
'assetName' => {
|
||||
message => q|Ad Sales|,
|
||||
lastUpdated => 0,
|
||||
context => q|The name of the Ad Sales asset|,
|
||||
},
|
||||
|
||||
|
||||
'property purchase template' => {
|
||||
message => q|property purchase template|,
|
||||
lastUpdated => 0,
|
||||
context => q|TODO|
|
||||
},
|
||||
|
||||
'property purchase template help' => {
|
||||
message => q|property purchase template help|,
|
||||
lastUpdated => 0,
|
||||
context => q|TODO|
|
||||
},
|
||||
|
||||
'property manage template' => {
|
||||
message => q|property manage template|,
|
||||
lastUpdated => 0,
|
||||
context => q|TODO|
|
||||
},
|
||||
|
||||
'property manage template help' => {
|
||||
message => q|property manage template help|,
|
||||
lastUpdated => 0,
|
||||
context => q|TODO|
|
||||
},
|
||||
|
||||
'property ad space' => {
|
||||
message => q|property ad space|,
|
||||
lastUpdated => 0,
|
||||
context => q|TODO|
|
||||
},
|
||||
|
||||
'property ad Space help' => {
|
||||
message => q|property ad Space help|,
|
||||
lastUpdated => 0,
|
||||
context => q|TODO|
|
||||
},
|
||||
|
||||
'property priority' => {
|
||||
message => q|property priority|,
|
||||
lastUpdated => 0,
|
||||
context => q|TODO|
|
||||
},
|
||||
|
||||
'property price per click' => {
|
||||
message => q|property price per click|,
|
||||
lastUpdated => 0,
|
||||
context => q|TODO|
|
||||
},
|
||||
|
||||
'property price per click help' => {
|
||||
message => q|property price per click help|,
|
||||
lastUpdated => 1165511641,
|
||||
context => q|TODO|
|
||||
},
|
||||
|
||||
'property price per impression' => {
|
||||
message => q|property price per impression|,
|
||||
lastUpdated => 0,
|
||||
context => q|TODO|
|
||||
},
|
||||
|
||||
'property price per impression help' => {
|
||||
message => q|property price per impression help|,
|
||||
lastUpdated => 0,
|
||||
context => q|TODO|
|
||||
},
|
||||
|
||||
'property click discounts' => {
|
||||
message => q|property click discounts|,
|
||||
lastUpdated => 0,
|
||||
context => q|TODO|
|
||||
},
|
||||
|
||||
'property click discounts help' => {
|
||||
message => q|property click discounts help|,
|
||||
lastUpdated => 0,
|
||||
context => q|TODO|
|
||||
},
|
||||
|
||||
'property impression discounts' => {
|
||||
message => q|property impression discounts|,
|
||||
lastUpdated => 0,
|
||||
context => q|TODO|
|
||||
},
|
||||
|
||||
'property impression discounts help' => {
|
||||
message => q|property impression discounts help|,
|
||||
lastUpdated => 0,
|
||||
context => q|TODO|
|
||||
},
|
||||
|
||||
'property adsku karma' => {
|
||||
message => q|property adsku karma|,
|
||||
lastUpdated => 0,
|
||||
context => q|TODO|
|
||||
},
|
||||
|
||||
'property adsku karma description' => {
|
||||
message => q|property adsku karma description|,
|
||||
lastUpdated => 0,
|
||||
context => q|TODO|
|
||||
},
|
||||
|
||||
'Ad Space' => {
|
||||
message => q|Ad Space|,
|
||||
lastUpdated => 0,
|
||||
context => q|name for the Ad Space Sku|
|
||||
},
|
||||
|
||||
'TODO' => {
|
||||
message => q|TODO|,
|
||||
lastUpdated => 0,
|
||||
context => q|TODO|
|
||||
},
|
||||
|
||||
};
|
||||
|
||||
1;
|
||||
|
|
@ -4338,6 +4338,12 @@ Users may override this setting in their profile.
|
|||
'recaptcha public key' => {
|
||||
message => 'reCAPTCHA Public Key'
|
||||
},
|
||||
'Ad Space control name' => {
|
||||
message => q|Ad Space|,
|
||||
lastUpdated => 0,
|
||||
context => q|name for the Ad Space control|
|
||||
},
|
||||
|
||||
};
|
||||
|
||||
1;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue