$wamResult = WpAdsupplierMerchant::where('cate_id',$cateId)->field('merchant_id')->select();//所有門市ids
您好,想將所有的集合的id存到一個變數裡,例如:$ids = [12,21,23,32,11];
現在$wamResult 的結果是:
#[data: protected] => Array
(
[merchant_id] => 345
[merchant_id] => 345
)
[origin##protec#[origin#protected] => Array
( &nbs
是這樣,例如:$ids = "12,21,23,32,11";