Generate proposal .pdf with project name

Hi,

Im trying to add the project label to the proposal .pdf
$file = $dir.“/”.$objectref.“.pdf”;

I want the file name to be some thing like (PR0501-0001 - Project Name.pdf)