@@ -81,7 +81,7 @@ class AdminStrategy extends AbstractController
8181 /**
8282 * @var string
8383 */
84- private static $ admin_avatar ;
84+ private static $ admin_avatar = ' /bundles/phpzlcadmin/images/admin_avatar.png ' ;
8585
8686 /**
8787 * @var static 管理员角色名称
@@ -101,7 +101,7 @@ class AdminStrategy extends AbstractController
101101 /**
102102 * @var string 登陆页面背景图片
103103 */
104- private static $ login_lack_ground_im = '/bundles/phpzlcadmin/images/login_logo.png ' ;
104+ private static $ login_lack_ground_img = '/bundles/phpzlcadmin/images/login_logo.png ' ;
105105
106106 /**
107107 * @var Navigation[]
@@ -170,7 +170,11 @@ public function setFaviconIco($favicon_ico)
170170
171171 public function getFaviconIco ()
172172 {
173- return static ::$ favicon_ico ;
173+ if (substr (static ::$ favicon_ico , 0 , 4 ) == 'http ' ){
174+ return static ::$ favicon_ico ;
175+ }else {
176+ return $ this ->getAssetBaseUrl () . static ::$ favicon_ico ;
177+ }
174178 }
175179
176180 public function setLogo ($ logo )
@@ -420,15 +424,11 @@ public function setHendCode(string $hend_code)
420424 */
421425 public function getAdminAvatar (): string
422426 {
423- if (empty (self ::$ admin_avatar )){
424- if (empty ($ this ->getAssetBaseUrl ())){
425- return 'bundles/phpzlcadmin/images/admin_avatar.png ' ;
426- }else {
427- return $ this ->getAssetBaseUrl () . '/bundles/phpzlcadmin/images/admin_avatar.png ' ;
428- }
427+ if (substr (static ::$ admin_avatar , 0 , 4 ) == 'http ' ){
428+ return static ::$ admin_avatar ;
429+ }else {
430+ return $ this ->getAssetBaseUrl () . static ::$ admin_avatar ;
429431 }
430-
431- return self ::$ admin_avatar ;
432432 }
433433
434434 /**
0 commit comments