<?php
 namespace App\Utils\InvoiceDueDate; class Customer extends \App\Utils\InvoiceDueDate\GeneralAbstract { protected function getEntityPreferenceObject() { return \App\EntityPreference\Customer::getInstance($this->idEntity); } protected function getDefaultProfile() { $defaultProfileDays = \App\Config\InvoiceDueDates::getInstance()->get('customer'); if (!is_numeric($defaultProfileDays)) { return null; } $profile = new \App\Utils\InvoiceDueDate\Profile(); $profElem = new \App\Utils\InvoiceDueDate\Element(); $profElem->setType('days')->setServiceCodes([''])->setOffset($defaultProfileDays); $profile->addElement($profElem); return $profile; } } 