diff options
| author | Ivan Kohler <ivan@freeside.biz> | 2021-03-17 19:28:06 -0700 |
|---|---|---|
| committer | Ivan Kohler <ivan@freeside.biz> | 2021-03-17 19:28:06 -0700 |
| commit | 853dc7fbb572fdf15d257412ede37d45f793715c (patch) | |
| tree | 356f5367a27989cf5d400fb732ba6f1a5a98858f /FS | |
| parent | 02b7d15afbee7e1837cd091905b311754b31894d (diff) | |
disable fcc 477 deployment zones, RT#85668
Diffstat (limited to 'FS')
| -rw-r--r-- | FS/FS/Schema.pm | 1 | ||||
| -rw-r--r-- | FS/FS/deploy_zone.pm | 9 |
2 files changed, 9 insertions, 1 deletions
diff --git a/FS/FS/Schema.pm b/FS/FS/Schema.pm index b043afc15..af8025c5f 100644 --- a/FS/FS/Schema.pm +++ b/FS/FS/Schema.pm @@ -5092,6 +5092,7 @@ sub tables_hashref { 'is_business', 'char', 'NULL', 1, '', '', 'active_date', @date_type, '', '', 'expire_date', @date_type, '', '', + 'disabled', 'char', 'NULL', 1, '', '', ], 'primary_key' => 'zonenum', 'unique' => [], diff --git a/FS/FS/deploy_zone.pm b/FS/FS/deploy_zone.pm index 306b4fb44..723b491c8 100644 --- a/FS/FS/deploy_zone.pm +++ b/FS/FS/deploy_zone.pm @@ -187,8 +187,15 @@ returns the error, otherwise returns false. =cut -# the replace method can be inherited from FS::Record +sub replace { + my $self = shift; + my $old = shift || $self->replace_old; + + $self->expire_date(time) + if $self->disabled eq 'Y' && ! $old->disabled && ! $self->expire_date; + $self->SUPER::replace($old, @_); +} =item check Checks all fields to make sure this is a valid zone record. If there is |
