From cf2c7b1b28932867f70f7c198b576559ae54e964 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=B0=B1=E7=9C=A0=E4=BB=AA=E5=BC=8F?= <854085467@qq.com> Date: Fri, 10 Jul 2020 13:33:25 +0800 Subject: [PATCH] =?UTF-8?q?Logo=20=E5=8A=A0=E5=85=A5=E5=88=9D=E5=A7=8B?= =?UTF-8?q?=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- component/layui/lay/extends/pearAdmin.js | 10 +++++++++- index.html | 23 ++++++++++++++--------- 2 files changed, 23 insertions(+), 10 deletions(-) diff --git a/component/layui/lay/extends/pearAdmin.js b/component/layui/lay/extends/pearAdmin.js index 8d433e1..9040853 100644 --- a/component/layui/lay/extends/pearAdmin.js +++ b/component/layui/lay/extends/pearAdmin.js @@ -40,6 +40,7 @@ layui.define(['table', 'jquery', 'element', 'form', 'pearAuth', 'pearTab', 'pear this.themeRender(option); this.noticeRender(option); this.permissionRender(option); + this.logoRender(option); } this.permissionRender = function(option) { @@ -47,6 +48,13 @@ layui.define(['table', 'jquery', 'element', 'form', 'pearAuth', 'pearTab', 'pear pearAuth.loadPermission(option.auth); } } + + this.logoRender = function(option){ + + $(".layui-logo .logo").attr("src",option.logoImage); + + $(".layui-logo .title").html(option.logoTitle); + } this.menuRender = function(option) { sideMenu = pearMenu.render({ @@ -248,7 +256,7 @@ layui.define(['table', 'jquery', 'element', 'form', 'pearAuth', 'pearTab', 'pear theme += ''; $("iframe").contents().find("head").append(theme); - $("#pearone-bg-color").html(style); + $("#pearadmin-bg-color").html(style); } diff --git a/index.html b/index.html index 8a7b186..6df4874 100644 --- a/index.html +++ b/index.html @@ -12,10 +12,11 @@ - + + - +
@@ -42,11 +43,12 @@
  • +
    @@ -57,18 +59,19 @@
    - +
    - +
    - +
    - +
    +