how to show all fields of pivot table in laravel code example
Example: laravel pivot select fields
public function products()
{
return $this->belongsToMany('\Duplicolor\Models\Product\Line', 'project_products', 'project_post_id', 'product_line_id')->withPivot('id');
}