Files
old-wiaas-legacy/api-wiaas/server/components/v1/financing/FinancingModel.php

53 lines
1.5 KiB
PHP
Raw Normal View History

2018-06-11 11:09:35 +02:00
<?php
class FinancingModel{
/**
* get interest rate
* @return HashArray interest rate value
*/
public function getInterestRate(){
$interestRate = new InterestRate();
return $interestRate->getInterestRate();
}
/**
* get interest rate for customers
* @return HashArray values for interest rate for each customer
*/
public function getInterestRateForCustomers(){
$interestRate = new InterestRate();
return $interestRate->getInterestRateForCustomers();
}
/**
* save interest rate
* @param Float $interestRateValue interest rate value
* @return Array update message
*/
public function saveInterestRate($interestRateValue){
$interestRate = new InterestRate();
return $interestRate->saveInterestRate($interestRateValue);
}
/**
* get customers discount
* @return HashArray customers discount
*/
public function getCustomersAndDiscount() {
$interestRate = new InterestRate();
return $interestRate->getCustomersAndDiscount();
}
/**
* save discount for customer - financing
* @param Array $discounts id of the customer and the discount applied for each
* @return Array update message
*/
public function saveCustomersDiscount($discounts) {
$interestRate = new InterestRate();
return $interestRate->saveCustomersDiscount($discounts);
}
}