From 967f73aa98a222aecb8ce3fd487f75cf1f07787d Mon Sep 17 00:00:00 2001 From: Anyon Date: Mon, 21 Sep 2020 16:17:18 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E5=9B=BE=E7=89=87=E5=88=87?= =?UTF-8?q?=E6=8D=A2=E5=8A=A8=E7=94=BB?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/data/view/config/slider.html | 39 +++++++++++++++++++++----------- public/static/admin.js | 4 ++-- 2 files changed, 28 insertions(+), 15 deletions(-) diff --git a/app/data/view/config/slider.html b/app/data/view/config/slider.html index 216127311..08a569daf 100644 --- a/app/data/view/config/slider.html +++ b/app/data/view/config/slider.html @@ -2,24 +2,27 @@ {block name="content"}
-
-
{$title|default='图片数据管理'}(建议尺寸:690px 250px)
-
-
- + +
+ {$title|default='图片数据管理'} ( 建议上传图片尺寸:690px 250px )
-
-
- +
+
+ +
+
+
+ +
-
-
+
+
@@ -49,6 +52,16 @@ margin-left: 5px; } + [data-rule-item] { + padding-left: 40px; + margin-bottom: 20px; + } + + [data-rule-item] .uploadimage { + width: 135px; + height: 100px; + } + [data-item-dn], [data-item-up], [data-item-rm] { margin-top: -4px; margin-left: 5px; diff --git a/public/static/admin.js b/public/static/admin.js index 60508626f..23a65c7e0 100644 --- a/public/static/admin.js +++ b/public/static/admin.js @@ -511,7 +511,7 @@ $(function () { /*! 上传单张图片 */ $.fn.uploadOneImage = function () { return this.each(function (input, template) { - input = $(this), template = $(''); + input = $(this), template = $(''); template.attr('data-type', input.data('type') || 'png,jpg,gif'); template.attr('data-field', input.attr('name') || 'image').data('input', this); template.find('span').on('click', function (event) { @@ -536,7 +536,7 @@ $(function () { function showImageContainer(srcs) { $(srcs).each(function (idx, src, $image) { - $image = $(''); + $image = $(''); $image.attr('data-tips-image', encodeURI(src)).css('backgroundImage', 'url(' + encodeURI(src) + ')').on('click', 'a', function (event, index, prevs, $item) { event.stopPropagation(), $item = $(this).parent(), index = $(this).index(), prevs = $button.prevAll('div.uploadimage').length; if (index === 0 && $item.index() !== prevs) $item.next().after($item);