array_push() 我已经给了数组了,但是获取的为空,麻烦各位大佬帮我看一下?
{"data":{"message":"array_push() expects parameter 1 to be array, null given","exception":"ErrorException","file":"D:\\laragon\\www\\szh.s3.natapp\\app\\Repositories\\FranchiserRepository.php","line":55,"trace":[{"function":"handleError","class":"Illuminate\\Foundation\\Bootstrap\\HandleExceptions","type":"->"},{"file":"D:\\laragon\\www\\szh.s3.natapp\\app\\Repositories\\FranchiserRepository.php","line":55,"function":"array_push"},{"file":"D:\\laragon\\www\\szh.s3.natapp\\app\\Http\\Controllers\\Api\\Customer\\CityController.php","line":22,"function":"getCities","class":"App\\Repositories\\FranchiserRepository","type":"->"},{"file":"D:\\laragon\\www\\szh.s3.natapp\\vendor\\laravel\\framework\\src\\Illuminate\\Routing\\ControllerDispatcher.php","line":48,"function":"franchiserCities","class":"App\\Http\\Controllers\\Api\\Customer\\CityController","type":"->"},{"file":"D:\\laragon\\www\\szh.s3.natapp\\vendor\\laravel\\framework\\src\\Illuminate\\Routing\\Route.php","line":212,"function":"dispatch","class":"Illuminate\\Routing\\ControllerDispatcher","type":"->"},{"file":"D:\\laragon\\www\\szh.s3.natapp\\vendor\\laravel\\framework\\src\\Illuminate\\Routing\\Route.php","line":169,"function":"runController","class":"Illuminate\\Routing\\Route","type":"->"},{"file":"D:\\laragon\\www\\szh.s3.natapp\\vendor\\laravel\\framework\\src\\Illuminate\\Routing\\Router.php","line":658,"function":"run","class":"Illuminate\\Routing\\Route","type":"->"},{"file":"D:\\laragon\\www\\szh.s3.natapp\\vendor\\laravel\\framework\\src\\Illuminate\\Routing\\Pipeline.php","line":30,"function":"Illuminate\\Routing\\{closure}","class":"Illuminate\\Routing\\Router","type":"->"},{"file":"D:\\laragon\\www\\szh.s3.natapp\\vendor\\laravel\\framework\\src\\Illuminate\\Routing\\Middleware\\SubstituteBindings.php","line":41,"function":"Illuminate\\Routing\\{closure}","class":"Illuminate\\Routing\\Pipeline","type":"->"},{"file":"D:\\laragon\\www\\szh.s3.natapp\\vendor\\laravel\\framework\\src\\Illuminate\\Pipeline\\Pipeline.php","line":149,"function":"handle","class":"Illuminate\\Routing\\Middleware\\SubstituteBindings","type":"->"},{"file":"D:\\laragon\\www\\szh.s3.natapp\\vendor\\laravel\\framework\\src\\Illuminate\\Routing\\Pipeline.php","line":53,"function":"Illuminate\\Pipeline\\{closure}","class":"Illuminate\\Pipeline\\Pipeline","type":"->"},{"file":"D:\\laragon\\www\\szh.s3.natapp\\vendor\\laravel\\framework\\src\\Illuminate\\Routing\\Middleware\\ThrottleRequests.php","line":57,"function":"Illuminate\\Routing\\{closure}","class":"Illuminate\\Routing\\Pipeline","type":"->"},{"file":"D:\\laragon\\www\\szh.s3.natapp\\vendor\\laravel\\framework\\src\\Illuminate\\Pipeline\\Pipeline.php","line":149,"function":"handle","class":"Illuminate\\Routing\\Middleware\\ThrottleRequests","type":"->"},{"file":"D:\\laragon\\www\\szh.s3.natapp\\vendor\\laravel\\framework\\src\\Illuminate\\Routing\\Pipeline.php","line":53,"function":"Illuminate\\Pipeline\\{closure}","class":"Illuminate\\Pipeline\\Pipeline","type":"->"},{"file":"D:\\laragon\\www\\szh.s3.natapp\\vendor\\laravel\\framework\\src\\Illuminate\\Pipeline\\Pipeline.php","line":102,"function":"Illuminate\\Routing\\{closure}","class":"Illuminate\\Routing\\Pipeline","type":"->"},{"file":"D:\\laragon\\www\\szh.s3.natapp\\vendor\\laravel\\framework\\src\\Illuminate\\Routing\\Router.php","line":660,"function":"then","class":"Illuminate\\Pipeline\\Pipeline","type":"->"},{"file":"D:\\laragon\\www\\szh.s3.natapp\\vendor\\laravel\\framework\\src\\Illuminate\\Routing\\Router.php","line":635,"function":"runRouteWithinStack","class":"Illuminate\\Routing\\Router","type":"->"},{"file":"D:\\laragon\\www\\szh.s3.natapp\\vendor\\laravel\\framework\\src\\Illuminate\\Routing\\Router.php","line":601,"function":"runRoute","class":"Illuminate\\Routing\\Router","type":"->"},{"file":"D:\\laragon\\www\\szh.s3.natapp\\vendor\\laravel\\framework\\src\\Illuminate\\Routing\\Router.php","line":590,"function":"dispatchToRoute","class":"Illuminate\\Routing\\Router","type":"->"},{"file":"D:\\laragon\\www\\szh.s3.nata
 cid=13,dataIndex=0, curNavIndex=0, page.num=1, page.size=10, pageData.length=10 at pages/article.html:277
Csdn user default icon
上传中...
上传图片
插入图片
抄袭、复制答案,以达到刷声望分或其他目的的行为,在CSDN问答是严格禁止的,一经发现立刻封号。是时候展现真正的技术了!
立即提问