title: condition orWhere using laravel 6 not work
body: <p>I have two tables, <code>salaries</code> and <code>pointages</code>, and a <code>belongsTo</code>/<code>hasMany</code> relationship  between them. I want to select the sum of the <code>sold</code> and <code>payer</code> columns on condition of date and condition of <code>salarie_id</code> and <code>chantier_id</code>. I want to be optional, if I choose <code>salarie_id</code> or <code>chantier_id</code>, I want to give me either the <code>pointages</code> of <code>salarie_id</code> or <code>chantier_id</code> chosen or both. But in my case even when I chose <code>salarie_id</code> or <code>chantier_id</code>, it showed me all of the rows.</p>
  
  <pre><code>$dataP = DB::table('salaries')
           -&gt;join('pointages','pointages.salarie_id','salaries.id')
            -&gt;selectRaw('SUM(pointages.sold) as sold,salaries.nom,salaries.prenom,salaries.id,SUM(pointages.payer) as payer')
            -&gt;whereRaw(DB::raw('YEAR(pointages.datep) = ' .$request-&gt;annee))
            -&gt;whereRaw(DB::raw('MONTH(pointages.datep) = ' .$request-&gt;mois))
            -&gt;whereRaw( DB::raw('DAY(pointages.datep)&gt;0 AND DAY(pointages.datep)&lt;16')) 
            -&gt;Orwhere('pointages.salarie_id','=',$request-&gt;salarie_id)
            -&gt;OrWhere('pointages.chantier_id','=',$request-&gt;chantier_id)
            -&gt;groupBy('pointages.salarie_id')
            -&gt;get();
            return response($dataP);
  </code></pre>