app/Http/Resources/InvestissementResource.php
/**
     * Transform the resource into an array.
     *
     * @param  \Illuminate\Http\Request  $request
     * @return array|\Illuminate\Contracts\Support\Arrayable|\JsonSerializable
     */
Transform the resource into an array.
Transform the resource into an array .
public function toArray($request)
    {
        return [
            "id" => $this->id,
            "annee" => $this->annee,
            "monnaie"=> $this->monnaie,
            "comments"=> $this->comments,
            "last_comment"=> $this->last_comment,
            "documents"=> $this->documents,
            "statut"=> $this->statut,
            "piliers"=> $this->piliers,
            "mode_financement"=>$this->mode_financement,
            'structure'=>$this->structure,
            "agent_execution"=>$this->agent_execution,
            "bailleur"=>$this->bailleur,
            "montant_global"=>$this->montant_global,
        ];
    }
public function toArray ( $ request ) { return [ " id " => $ this -> id , " annee " => $ this -> annee , " monnaie " => $ this -> monnaie , " comments " => $ this -> comments , " last_comment " => $ this -> last_comment , " documents " => $ this -> documents , " statut " => $ this -> statut , " piliers " => $ this -> piliers , " mode_financement " => $ this -> mode_financement , 'structure' => $ this -> structure , " agent_execution " => $ this -> agent_execution , " bailleur " => $ this -> bailleur , " montant_global " => $ this -> montant_global , ] ; }
Transform the resource into an array.
Transform the resource into an array .