**我试图把if if并结束如果在html标签中(连接但是它不工作的属性你会帮助我它因为我是laravel的新手**
$output .= '
<tr>
<td>'.$row->total_price.'</td>
<td><a href="/orderview/'.$row->order_id.'">
<button data-toggle="tooltip" title="View"
class="pd-setting-ed"><i class="fa fa-search-plus"
aria-hidden="true"></i></button></a>
</td>
<td>' .(($row->aproval == 1)).' <label
class="switch">
<input type="checkbox" checked="checked"
onclick="aproveorder('.$row->order_id.')">
<span class="slider round"> Yes</span>
</label>
</td>
' .(($row->aproval == 0)). '<label class="switch">
<input type="checkbox" value="" id="product_status"
onclick="aproveorder('.$row->order_id.')">
<span class="slider round"> Yes</span>
</label></td>
<td> <label class="switch">
<input type="checkbox" checked="checked" value="" id=""
onclick="deliverystatus('.$row->order_id.')">
<span class="slider round"> Done</span>
</label>
</td>
'.($row->payment_status == 0).'<label
class="switch">
<input type="checkbox" value="" onclick="deliverystatus('.$row-
>order_id.')">
<span class="slider round"> No</span>
</label></td></td>
Laravel有'刀片'(模板)。我认为你应该使用params:@each('view.name', $row)
,就像这样。阅读文档了解更多信息:https://laravel.com/docs/5.8/blade