[0] ThrowableError in Base.php line 109

致命错误: Call to a member function toArray() on null

  1. public function getCatalog($tid)
  2. {
  3. $model = new ArctypeModel();
  4. $res = $model->where('tid', $tid)
  5. ->
  6. find()
  7. ->
  8. toArray();
  9. return $res;
  10. }
  11. public function chnnlerson()
  12. {
  13. $tid = input('param.tid');
  14. if (empty($tid)){$tid=19;}
  15. $res = ArctypeModel::get([

Call Stack

  1. in Base.php line 109
  2. at Base->getCatalog('19') in Job.php line 60
  3. at Job->index()
  4. at ReflectionMethod->invokeArgs(object(Job), []) in Container.php line 395
  5. at Container->invokeReflectMethod(object(Job), object(ReflectionMethod), ['tid' => '19', 'convert' => false]) in Module.php line 131
  6. at Module->think\route\dispatch\{closure}(object(Request), object(Closure), null)
  7. at call_user_func_array(object(Closure), [object(Request), object(Closure), null]) in Middleware.php line 185
  8. at Middleware->think\{closure}(object(Request))
  9. at call_user_func(object(Closure), object(Request)) in Middleware.php line 130
  10. at Middleware->dispatch(object(Request), 'controller') in Module.php line 136
  11. at Module->exec() in Dispatch.php line 168
  12. at Dispatch->run() in App.php line 432
  13. at App->think\{closure}(object(Request), object(Closure), null)
  14. at call_user_func_array(object(Closure), [object(Request), object(Closure), null]) in Middleware.php line 185
  15. at Middleware->think\{closure}(object(Request))
  16. at call_user_func(object(Closure), object(Request)) in Middleware.php line 130
  17. at Middleware->dispatch(object(Request)) in App.php line 435
  18. at App->run() in index.php line 21

Environment Variables

GET Dataempty
POST Dataempty
Filesempty
Cookies
PHPSESSID qb2t7k4kfbujr77p6ft301v8k5
Sessionempty
Server/Request Data
DOCUMENT_ROOT /usr/home/wh-ab2xzw3txhh0bsj4xm9/htdocs
GATEWAY_INTERFACE CGI/1.1
HTTPS on
HTTP_ACCEPT */*
HTTP_ACCEPT_ENCODING gzip
HTTP_COOKIE PHPSESSID=qb2t7k4kfbujr77p6ft301v8k5
HTTP_HOST www.arctechsolar.cn
HTTP_USER_AGENT CCBot/2.0 (https://commoncrawl.org/faq/)
PATH /bin
PHPRC /var/www/php70/hichina_ini/wh-ab2xzw3txhh0bsj4xm9
QUERY_STRING
REDIRECT_DOCUMENT_ROOT /usr/home/wh-ab2xzw3txhh0bsj4xm9/htdocs
REDIRECT_GATEWAY_INTERFACE CGI/1.1
REDIRECT_HTTPS on
REDIRECT_HTTP_ACCEPT */*
REDIRECT_HTTP_ACCEPT_ENCODING gzip
REDIRECT_HTTP_COOKIE PHPSESSID=qb2t7k4kfbujr77p6ft301v8k5
REDIRECT_HTTP_HOST www.arctechsolar.cn
REDIRECT_HTTP_USER_AGENT CCBot/2.0 (https://commoncrawl.org/faq/)
REDIRECT_PATH /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
REDIRECT_PATH_INFO job
REDIRECT_QUERY_STRING
REDIRECT_REMOTE_ADDR 170.130.202.6
REDIRECT_REMOTE_PORT 34062
REDIRECT_REQUEST_METHOD GET
REDIRECT_REQUEST_URI /job
REDIRECT_SCRIPT_FILENAME /usr/home/wh-ab2xzw3txhh0bsj4xm9/htdocs/job
REDIRECT_SCRIPT_NAME /job
REDIRECT_SERVER_ADDR 172.22.250.27
REDIRECT_SERVER_ADMIN webmaster@wh-ab2xzw3txhh0bsj4xm9.my3w.com
REDIRECT_SERVER_NAME www.arctechsolar.cn
REDIRECT_SERVER_PORT 443
REDIRECT_SERVER_PROTOCOL HTTP/1.1
REDIRECT_SERVER_SIGNATURE
REDIRECT_SERVER_SOFTWARE Apache
REDIRECT_SSL_TLS_SNI www.arctechsolar.cn
REDIRECT_STATUS 200
REDIRECT_TZ Asia/Shanghai
REDIRECT_UNIQUE_ID Zh9IrqwW@hsAClxOgF0AAAAd
REDIRECT_URL /job
REMOTE_ADDR 170.130.202.6
REMOTE_PORT 34062
REQUEST_METHOD GET
REQUEST_URI /job
SCRIPT_FILENAME /usr/home/wh-ab2xzw3txhh0bsj4xm9/htdocs/index.php
SCRIPT_NAME /index.php
SERVER_ADDR 172.22.250.27
SERVER_ADMIN webmaster@wh-ab2xzw3txhh0bsj4xm9.my3w.com
SERVER_NAME www.arctechsolar.cn
SERVER_PORT 443
SERVER_PROTOCOL HTTP/1.1
SERVER_SIGNATURE
SERVER_SOFTWARE Apache
SSL_TLS_SNI www.arctechsolar.cn
TZ Asia/Shanghai
UNIQUE_ID Zh9IrqwW@hsAClxOgF0AAAAd
PHP_SELF /index.php
REQUEST_TIME_FLOAT 1713326254.5627
REQUEST_TIME 1713326254
Environment Variablesempty
ThinkPHP Constantsempty
XML 地图