我需要解析这个数据集我已经但我尝试了几种方法,但它不起作用。Laravel数据集解析错误
{"id":2,"area_id":"1","payment_term_id":"1","payment_type_id":"1","trade_channel_id":"1","salesman_id":1,"customer_name":"xxx","contact_number":"1231212","fax_number":"1231232","home_address":"asd","delivery_address":"dasd","email_address":"[email protected]","created_by":"4","updated_by":"4","is_active":"1","created_at":"2017-10-17 06:02:59","updated_at":"2017-10-17 06:13:22"}
我想这一个,但这个错误说
(1/1)ErrorException 试图让非对象的属性
$details = $request->get('details');
return $details->id;
我也试过这个
$details = $request->get('details');
return $details['id'];
(1/1)ErrorException 非法字符串偏移'id '
我使用laravel 5.4
这工作感谢@alexey –