Version 4.7.23

This commit is contained in:
Neo committed 2025-12-19 16:21:27 -08:00
1 parent 7124a02564
commit 25ddeb65d6
1791 files changed
+76990 -44452

No files matched your search

@@ -318,6 +318,18 @@ class _Purchase extends \IPS\Node\Model
}
$this->_data['active'] = $active;
/* Set any child purchases to match this state.
Note that this will not be executed if editing a purchase in the ACP,
as the purchases are temporarily ungrouped at this point. */
foreach( $this->children() as $child )
{
if( $child->grouped_renewals and !$child->cancelled )
{
$child->active = $active;
$child->save();
}
}
}
/**
@@ -401,6 +413,17 @@ class _Purchase extends \IPS\Node\Model
{
$this->onExpirationDateChange();
}
/* If we have a parent purchase and the renewals are grouped,
set the active flag to match */
try
{
if( $parent = $this->parent() and $this->grouped_renewals )
{
$this->active = $parent->active;
}
}
catch ( \OutOfRangeException $e ){}
}
/**