🚧 ajout constrcut flux

pull/2/head
Maxime POINT 1 year ago
parent 67b0b30be8
commit 67bc1f6234

@ -2,9 +2,16 @@
namespace model;
use DAL\FluxGateway;
use metier\Flux;
class FluxModel
{
private FluxGateway $gateway;
public function __construct(FluxGateway $fluxGateway){
$this->gateway = $fluxGateway;
}
public function FindAllFlux(){
$data = array();
$result = $this->gateway->findAllFlux();
@ -17,7 +24,7 @@ class FluxModel
public function addFlux(Flux $flux)
{
$data = findFlux($flux);
$data = $this->findFlux($flux);
if ($data == array()) {
$this->gateway->addFlux($flux);
}

Loading…
Cancel
Save