mallService = Zc::singleton('MallService'); $this->affiliateAccountService = Zc::singleton('AffiliateAccountService'); $this->feedbackService = Zc::singleton(FeedbackService::class); } public function render($data = '') { $data = array(); $data['route'] = $_GET['route']; $data['nickname'] = $_SESSION[SessionConst::mallName]; $data['mallSubAccountId'] = $_SESSION[SessionConst::mallSubAccountId]; $data['imConfig'] = $this->feedbackService->getImConfig(); $data['isMallRoleFactory'] = $this->mallService->checkIsMallRoleFactory($_SESSION[SessionConst::mallId]); switch (Zc::C('appName')) { case AppConst::appMsPddOd: $tplFile = AppConst::isNewVersionPurchase() ? 'msod/common/header' : 'msod/common/header_old'; break; case AppConst::appPddRuby: if (AppConst::isRubyDesktop()) { $tplFile = 'msod/common/header'; } else { $tplFile = 'common/header'; } break; default: $tplFile = 'common/header'; break; } return $this->renderFile($tplFile, $data); } }