$_component : string
The name of the component, e.g. net.nehmer.static. Should be used whenever the component's name is required instead of hardcoding it.
Helper class to process subscription invoicing
Note, that the request data, for ease of use, already contains the L10n Databases of the Component and MidCOM itself located in this class. They are stored as 'l10n' and 'l10n_midcom'. Also available as 'config' is the current component configuration.
$_deliverable : \org_openpsa_sales_salesproject_deliverable_dba
The deliverable we're processing
get_workflow(string $identifier, array $options = array()) : \midcom\workflow\dialog
run_cycle( $cycle_number, $send_invoice = true)
Initiates a new subscription cycle and registers a midcom.services.at call for the next cycle.
The subscription cycles rely on midcom.services.at. I'm not sure if it is wise to rely on it for such a totally mission critical part of OpenPSA. Some safeguards might be wise to add.
calculate_cycles(integer $months = null, integer $start = null) : integer
Calculcate remaining cycles until salesproject's end or the specified number of months passes
The maximum number of months to look forward
The timestamp from which to begin
_add_month(integer $time, integer $offset) : \DateTime
Workaround for odd PHP DateTime behavior where for example 2012-10-31 + 1 month would return 2012-12-01. This function makes sure the new date is always in the expected month (so in the example above it would return 2012-11-30)
number of months to add
The new date object