webgui_newsletter/lib/WebGUI/Mailing.pm
2010-05-06 13:52:49 +02:00

47 lines
987 B
Perl

package WebGUI::Mailing;
use strict;
use warnings;
use base 'WebGUI::Crud';
sub crud_definition {
my $class = shift;
my $session = shift;
my $definition = $class->SUPER::crud_definition( $session );
$definition->{ tableName } = 'WGMailing';
$definition->{ tableKey } = 'mailingId';
$definition->{ sequenceKey } = 'issueId';
my %properties = (
assetId => {
fieldType => 'guid',
},
issueId => {
fieldType => 'guid',
},
configuration => {
fieldType => 'textarea',
},
sendDate => {
fieldType => 'dateTime',
},
active => {
fieldType => 'yesNo',
defaultValue => 0,
},
);
$definition->{ properties } = {
%{ $definition->{ properties } || {} },
%properties,
};
return $definition;
}
1;