date
-=item contract_end
-
-date
-
=item cancel
date
$self->start_date( timelocal_nocheck(0,0,0,1,$mon,$year) );
}
- foreach my $action ( qw(expire adjourn contract_end) ) {
+ foreach my $action ( qw(expire adjourn) ) {
my $months = $self->part_pkg->option("${action}_months",1);
if($months and !$self->$action) {
my $start = $self->start_date || $self->setup || time;
=cut
tie my %statuscolor, 'Tie::IxHash',
- 'not yet billed' => '009999', #teal? cyan?
+ 'not yet billed' => '000000',
'one-time charge' => '000000',
'active' => '00CC00',
'suspended' => 'FF9900',
"cust_pkg.cancel IS NOT NULL AND cust_pkg.cancel != 0";
}
-=item status_sql
-
-Returns an SQL expression to give the package status as a string.
-
-=cut
-
-sub status_sql {
-"CASE
- WHEN cust_pkg.cancel IS NOT NULL THEN 'cancelled'
- WHEN cust_pkg.susp IS NOT NULL THEN 'suspended'
- WHEN cust_pkg.setup IS NULL THEN 'not yet billed'
- WHEN ".onetime_sql()." THEN 'one-time charge'
- ELSE 'active'
-END"
-}
-
=item search HASHREF
(Class method)
"NOT (".FS::cust_pkg->onetime_sql . ")";
}
else {
- foreach my $field (qw( setup last_bill bill adjourn susp expire contract_end cancel )) {
+ foreach my $field (qw( setup last_bill bill adjourn susp expire cancel )) {
next unless exists($params->{$field});