aide-travaux / eco-ptz
工作援助 - 零利率生态贷款
v2.0.2
2020-03-05 15:35 UTC
Requires
- php: >=5.3.0
- aide-travaux/core: *
Requires (Dev)
- phpunit/phpunit: ^8.5
README
简介
EcoPTZ 类返回所有与零利率生态贷款相关的信息
描述
旨在能源改造的财政援助 - 零利率生态贷款。
常量
EcoPTZ::NOM 财政援助的名称
EcoPTZ::DESCRIPTION 财政援助的描述
EcoPTZ::DELAI 财政援助的支付期限
EcoPTZ::DISTRIBUTEUR 财政援助的发行者
EcoPTZ::REFERENCES 财政援助的法律或机构参考文献
EcoPTZ::CONDITIONS 财政援助的获取条件
方法
EcoPTZ::get(DataInterface $model): ?float;
根据提供的信息返回计算出的财政援助金额
EcoPTZ::getBareme(DataInterface $model): ?array;
返回提供的作品的现行标准
EcoPTZ::getPlafond(): int;
返回财政援助的上限
EcoPTZ::resolveConditions(ConditionInterface $model): array;
返回获取援助的条件以及每个条件是否基于提供的信息满足
EcoPTZ::isEligible(ConditionInterface $model): bool;
根据提供的信息返回项目对财政援助的资格
示例
<?php
use AideTravaux\EcoPTZ\Model\DataInterface;
use AideTravaux\EcoPTZ\Model\ConditionInterface;
use AideTravaux\EcoPTZ\EcoPTZ;
class Data implements DataInterface, ConditionInterface
{
public function getEcoPTZCodeTravaux(): string
{
return 'EPTZ-01';
}
public function getEptzTypeProjet(): string
{
return 'Bouquet de 2 travaux';
}
public function getCoutTTC(): float
{
return (float) 12000;
}
public function getTypeLogement(): string
{
return 'Maison individuelle';
}
public function getStatutOccupantLogement(): string
{
return 'Propriétaire occupant';
}
public function getTypeOccupationLogement(): string
{
return 'Résidence principale';
}
public function getAgeLogement(): int
{
return 30;
}
}
$data = new Data();
EcoPTZ::get($data);
EcoPTZ::resolveConditions($data);