blob: 6c1c9cca5240d01ff70578a72c0897388c15dfc4 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
|
package FS::part_event::Condition::pkg_status;
use strict;
use base qw( FS::part_event::Condition );
use FS::Record qw( qsearch );
sub description {
'Package Status';
}
sub eventtable_hashref {
{ 'cust_main' => 0,
'cust_bill' => 0,
'cust_pkg' => 1,
};
}
#something like this
sub option_fields {
(
'status' => { 'label' => 'Package Status',
'type' => 'select-cust_pkg-status',
'multiple' => 1,
},
);
}
sub condition {
my( $self, $cust_pkg ) = @_;
#XXX test
my $hashref = $self->option('status') || {};
$hashref->{ $cust_pkg->status };
}
1;
|