@@ -235,6 +235,7 @@ class PurchaseOrderService extends Service
//总社id
$top_depart_id = $user['head'] ?? [];
+ $top_depart_id = $top_depart_id['id'] ?? 0;
if(empty($order['state'])) {
//分社的采购单 供应商是总社
if($order['top_depart_id'] != $top_depart_id && ! empty($supplier->is_main)) {