[8] ErrorException in Product.php line 102

未定义变量: product

  1. }
  2. $count = count(collection($this->model->where('find_in_set(:id,category_id)',['id'=>$id])->where(['status'=>1,'lang'=>cookie('lang')])->order('weigh asc')->order('id desc')->select())->toArray());
  3. }else{
  4. $catalogName['id'] = '';
  5. $catalogName['name'] = '';
  6. $catalogName['comments'] = '';
  7. }
  8. $this->view->assign('productList',$product);
  9. //dump($product);die;
  10. $this->view->assign('count',$count);
  11. $this->view->assign('catalogName', $catalogName);
  12. return $this->view->fetch();
  13. }
  14. /**
  15. * 详情页
  16. *
  17. */

Call Stack

  1. in Product.php line 102
  2. at Error::appError(8, 'Undefined variable: ...', '/www/wwwroot/www.ret...', 102, ['where' => ['lang' => 'en'], 'top' => ['lang' => 'en'], 'id' => null, ...]) in Product.php line 102
  3. at Product->list()
  4. at ReflectionMethod->invokeArgs(object(Product), []) in App.php line 343
  5. at App::invokeMethod([object(Product), 'list'], []) in App.php line 598
  6. at App::module(['index', 'Product', 'list'], ['app_host' => '', 'app_debug' => true, 'app_trace' => false, ...], true) in App.php line 456
  7. at App::exec(['type' => 'module', 'module' => 'index/Product/list'], ['app_host' => '', 'app_debug' => true, 'app_trace' => false, ...]) in App.php line 139
  8. at App::run() in start.php line 19
  9. at require('/www/wwwroot/www.ret...') in index.php line 17

Environment Variables

GET Data
empty
POST Data
empty
Files
empty

Cookies

lang
en
Session
empty

Server/Request Data

USER
www
HOME
/home/www
HTTP_USER_AGENT
claudebot
HTTP_ACCEPT
*/*
HTTP_HOST
retechfarming.com
PATH_INFO
/product/list/cid/113
REDIRECT_STATUS
200
SERVER_NAME
www.retechfarming.com
SERVER_PORT
443
SERVER_ADDR
172.27.206.53
REMOTE_PORT
52516
REMOTE_ADDR
34.230.68.214
SERVER_SOFTWARE
nginx/1.22.1
GATEWAY_INTERFACE
CGI/1.1
HTTPS
on
REQUEST_SCHEME
https
SERVER_PROTOCOL
HTTP/2.0
DOCUMENT_ROOT
/www/wwwroot/www.retechfarming.com/public
DOCUMENT_URI
/index.php
REQUEST_URI
/product/list/cid/113
SCRIPT_NAME
/index.php
CONTENT_LENGTH
CONTENT_TYPE
REQUEST_METHOD
GET
QUERY_STRING
s=/product/list/cid/113
SCRIPT_FILENAME
/www/wwwroot/www.retechfarming.com/public/index.php
FCGI_ROLE
RESPONDER
PHP_SELF
/index.php
REQUEST_TIME_FLOAT
1711628001.8633
REQUEST_TIME
1711628001
Environment Variables
empty

ThinkPHP Constants

APP_PATH
/www/wwwroot/www.retechfarming.com/public/../application/
THINK_VERSION
5.0.15
THINK_START_TIME
1711628001.8637
THINK_START_MEM
404128
EXT
.php
DS
/
THINK_PATH
/www/wwwroot/www.retechfarming.com/thinkphp/
LIB_PATH
/www/wwwroot/www.retechfarming.com/thinkphp/library/
CORE_PATH
/www/wwwroot/www.retechfarming.com/thinkphp/library/think/
TRAIT_PATH
/www/wwwroot/www.retechfarming.com/thinkphp/library/traits/
ROOT_PATH
/www/wwwroot/www.retechfarming.com/
EXTEND_PATH
/www/wwwroot/www.retechfarming.com/extend/
VENDOR_PATH
/www/wwwroot/www.retechfarming.com/vendor/
RUNTIME_PATH
/www/wwwroot/www.retechfarming.com/runtime/
LOG_PATH
/www/wwwroot/www.retechfarming.com/runtime/log/
CACHE_PATH
/www/wwwroot/www.retechfarming.com/runtime/cache/
TEMP_PATH
/www/wwwroot/www.retechfarming.com/runtime/temp/
CONF_PATH
/www/wwwroot/www.retechfarming.com/public/../application/
CONF_EXT
.php
ENV_PREFIX
PHP_
IS_CLI
false
IS_WIN
false
ADDON_PATH
/www/wwwroot/www.retechfarming.com/addons/