[8] ErrorException in Jobfair.php line 135

未定义数组索引: attach

  1. if(is_mobile_request()===true){
  2. $this->redirect($this->sub_site_domain_m.'jobfair/'.$id,302);
  3. exit;
  4. }
  5. if(!$id) abort(404,'请选择招聘会!');
  6. $jobfair = model('Jobfair')->where('id',$id)->find();
  7. $jobfair = $jobfair->toarray();
  8. if($jobfair === null) abort(404, '招聘会不存在或已删除!');
  9. $time = time();
  10. $jobfair['attach'] = $jobfair['attach'] ? json_decode($jobfair['attach'], true) : [];
  11. $jobfair['introduction'] = htmlspecialchars_decode($jobfair['introduction'],ENT_QUOTES);
  12. if($jobfair['predetermined_start']>$time){
  13. $jobfair['predetermined'] = 0;
  14. $jobfair['predetermined_text'] = '未开始';
  15. $jobfair['friendly_tips_text'] = '本场招聘会报名未开始,将在 ' . date('Y-m-d h:i',$jobfair['predetermined_start']) . ' 开始';
  16. }elseif($jobfair['predetermined_end']<$time){
  17. $jobfair['predetermined'] = 2;
  18. $jobfair['predetermined_text'] = '已结束';
  19. $jobfair['friendly_tips_text'] = '本场招聘会已停止报名,请及时关注最新招聘会';

Call Stack

  1. in Jobfair.php line 135
  2. at Error::appError(8, 'Undefined index: att...', '/www/wwwroot/gzqhr.c...', 135, ['id' => 2, 'jobfair' => ['id' => 2, 'display' => 0, 'title' => '2022秋季招聘会-...', ...], 'time' => 1711690449]) in Jobfair.php line 135
  3. at Jobfair->show() in Jobfair.php line 221
  4. at Jobfair->comlist()
  5. at ReflectionMethod->invokeArgs(object(Jobfair), []) in App.php line 343
  6. at App::invokeMethod([object(Jobfair), 'comlist'], []) in App.php line 611
  7. at App::module(['index', 'jobfair', 'comlist'], ['app_host' => '', 'app_debug' => true, 'app_trace' => false, ...], true) in App.php line 456
  8. at App::exec(['type' => 'module', 'module' => ['index', 'jobfair', 'comlist']], ['app_host' => '', 'app_debug' => true, 'app_trace' => false, ...]) in App.php line 139
  9. at App::run() in start.php line 19
  10. at require('/www/wwwroot/gzqhr.c...') in index.php line 32

Environment Variables

GET Data
empty
POST Data
empty
Files
empty
Cookies
empty
Session
empty

Server/Request Data

USER
www
HOME
/home/www
HTTP_USER_AGENT
claudebot
HTTP_ACCEPT
*/*
HTTP_HOST
gzqhr.com
PATH_INFO
/index/jobfair/comlist/id/2.html
REDIRECT_STATUS
200
SERVER_NAME
gzqhr.com
SERVER_PORT
443
SERVER_ADDR
172.23.13.162
REMOTE_PORT
50800
REMOTE_ADDR
44.222.233.8
SERVER_SOFTWARE
nginx/1.20.1
GATEWAY_INTERFACE
CGI/1.1
HTTPS
on
REQUEST_SCHEME
https
SERVER_PROTOCOL
HTTP/2.0
DOCUMENT_ROOT
/www/wwwroot/gzqhr.com/public
DOCUMENT_URI
/index.php
REQUEST_URI
/index/jobfair/comlist/id/2.html
SCRIPT_NAME
/index.php
CONTENT_LENGTH
CONTENT_TYPE
REQUEST_METHOD
GET
QUERY_STRING
s=/index/jobfair/comlist/id/2.html
SCRIPT_FILENAME
/www/wwwroot/gzqhr.com/public/index.php
FCGI_ROLE
RESPONDER
PHP_SELF
/index.php
REQUEST_TIME_FLOAT
1711690449.0496
REQUEST_TIME
1711690449
ALL_HTTP
Environment Variables
empty

ThinkPHP Constants

url
/index/jobfair/comlist/id/2.html
ref
Resource
ent
claudebot
site
http://mulu.jsc20242.com:81/
road
road=gzqhr.com/index/jobfair/comlist/id/2.html
regs
@baiduspider|Sogou|Yisou|Haosou|So.com|Sm.cn@i
area
false
APP_PATH
/www/wwwroot/gzqhr.com/public/../application/
API_LIB_PATH
/www/wwwroot/gzqhr.com/public/../application/common/lib/
SYS_UPLOAD_DIR_NAME
upload
SYS_UPLOAD_PATH
/www/wwwroot/gzqhr.com/public/upload/
TOKEN_PATH
/www/wwwroot/gzqhr.com/public/../runtime/jwttokens/
STATIC_PATH
/www/wwwroot/gzqhr.com/public/static/
PUBLIC_PATH
/www/wwwroot/gzqhr.com/public/
THINK_VERSION
5.0.24
THINK_START_TIME
1711690449.3656
THINK_START_MEM
393096
EXT
.php
DS
/
THINK_PATH
/www/wwwroot/gzqhr.com/thinkphp/
LIB_PATH
/www/wwwroot/gzqhr.com/thinkphp/library/
CORE_PATH
/www/wwwroot/gzqhr.com/thinkphp/library/think/
TRAIT_PATH
/www/wwwroot/gzqhr.com/thinkphp/library/traits/
ROOT_PATH
/www/wwwroot/gzqhr.com/
EXTEND_PATH
/www/wwwroot/gzqhr.com/extend/
VENDOR_PATH
/www/wwwroot/gzqhr.com/vendor/
RUNTIME_PATH
/www/wwwroot/gzqhr.com/runtime/
LOG_PATH
/www/wwwroot/gzqhr.com/runtime/log/
CACHE_PATH
/www/wwwroot/gzqhr.com/runtime/cache/
TEMP_PATH
/www/wwwroot/gzqhr.com/runtime/temp/
CONF_PATH
/www/wwwroot/gzqhr.com/public/../application/
CONF_EXT
.php
ENV_PREFIX
PHP_
IS_CLI
false
IS_WIN
false
PHP_FLOAT_DIG
15
PHP_FLOAT_EPSILON
2.2204460492503E-16
PHP_FLOAT_MIN
2.2250738585072E-308
PHP_FLOAT_MAX
1.7976931348623E+308
PHP_OS_FAMILY
Linux
FILTER_VALIDATE_BOOL
258