mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-05-30 23:34:33 -04:00
Auto bill flag enable/disable auto_bill_enabled
This commit is contained in:
parent
d4e2a0071a
commit
c41fb6e00f
@ -91,16 +91,27 @@ class UpdateRecurringInvoiceRequest extends Request
|
|||||||
$this->replace($input);
|
$this->replace($input);
|
||||||
}
|
}
|
||||||
|
|
||||||
private function setAutoBillFlag($auto_bill)
|
/**
|
||||||
|
* if($auto_bill == '')
|
||||||
|
* off / optin / optout will reset the status of this field to off to allow
|
||||||
|
* the client to choose whether to auto_bill or not.
|
||||||
|
*
|
||||||
|
* @param enum $auto_bill off/always/optin/optout
|
||||||
|
*
|
||||||
|
* @return bool
|
||||||
|
*/
|
||||||
|
private function setAutoBillFlag($auto_bill) :bool
|
||||||
{
|
{
|
||||||
|
|
||||||
if($auto_bill == 'always')
|
if($auto_bill == 'always')
|
||||||
return true;
|
return true;
|
||||||
|
|
||||||
if($auto_bill == 'off')
|
// if($auto_bill == '')
|
||||||
return false;
|
// off / optin / optout will reset the status of this field to off to allow
|
||||||
|
// the client to choose whether to auto_bill or not.
|
||||||
//todo do we need to handle optin / optout here?
|
|
||||||
|
|
||||||
|
return false;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user