Revision a49ab807
Von Tamino Steinert vor etwa 1 Jahr hinzugefügt
| SL/DB/Part.pm | ||
|---|---|---|
|
sub is_type {
|
||
|
my $self = shift;
|
||
|
my $type = lc(shift || '');
|
||
|
die 'invalid type' unless $type =~ /^(?:part|service|assembly|assortment|parent_variant|variant)$/;
|
||
|
die 'invalid type' unless $type =~ /^(?:part|service|assembly|assortment)$/;
|
||
|
|
||
|
return $self->type eq $type ? 1 : 0;
|
||
|
}
|
||
Auch abrufbar als: Unified diff
Varianten: FIX für alle Artikeltypen ermöglicht