|
@@ -71,8 +71,16 @@
|
|
|
display: flex;
|
|
display: flex;
|
|
|
align-items: center;
|
|
align-items: center;
|
|
|
justify-content: center;
|
|
justify-content: center;
|
|
|
|
|
+ margin-right: 10px;
|
|
|
position: relative;
|
|
position: relative;
|
|
|
}
|
|
}
|
|
|
|
|
+ .activityIconItemClear{
|
|
|
|
|
+ position: absolute;
|
|
|
|
|
+ top: -8px;
|
|
|
|
|
+ right: 0px;
|
|
|
|
|
+ font-size: 20px;
|
|
|
|
|
+ z-index: 100;
|
|
|
|
|
+ }
|
|
|
</style>
|
|
</style>
|
|
|
</head>
|
|
</head>
|
|
|
<body class="white-bg">
|
|
<body class="white-bg">
|
|
@@ -86,6 +94,7 @@
|
|
|
<i id="bgImageIcon" class="fa fa-plus" style="font-size: 40px"></i>
|
|
<i id="bgImageIcon" class="fa fa-plus" style="font-size: 40px"></i>
|
|
|
<input type="file" class="uploadImage" id="bgImage" name="bgImage" accept="image/*"/>
|
|
<input type="file" class="uploadImage" id="bgImage" name="bgImage" accept="image/*"/>
|
|
|
</div>
|
|
</div>
|
|
|
|
|
+ <div style="font-size: 12px;color: #999999;margin-top: 10px;">建议图片宽度640px,高度800px</div>
|
|
|
</div>
|
|
</div>
|
|
|
</div>
|
|
</div>
|
|
|
<div class="form-group">
|
|
<div class="form-group">
|
|
@@ -105,17 +114,11 @@
|
|
|
</div>
|
|
</div>
|
|
|
<div class="form-group">
|
|
<div class="form-group">
|
|
|
<label class="col-sm-3 control-label">活动图标设置:</label>
|
|
<label class="col-sm-3 control-label">活动图标设置:</label>
|
|
|
- <div class="col-sm-8">
|
|
|
|
|
- <div class="activityIconBox">
|
|
|
|
|
- <!--<div class="activityIconItem">-->
|
|
|
|
|
- <!--<img src="" style="width: 50px;height: 50px;">-->
|
|
|
|
|
- <!--<i class="fa"></i>-->
|
|
|
|
|
- <!--</div>-->
|
|
|
|
|
- <div id="activityImageDiv" style="width: 50px;height: 50px;display: none;"></div>
|
|
|
|
|
- <div class="file-wraps-small-icon">
|
|
|
|
|
- <i id="activityImageIcon" class="fa fa-plus" style="font-size: 30px"></i>
|
|
|
|
|
- <input type="file" class="uploadImage" id="activityImage" name="activityImage" accept="image/*"/>
|
|
|
|
|
- </div>
|
|
|
|
|
|
|
+ <div class="col-sm-8" style="flex-direction: row;display: flex;">
|
|
|
|
|
+ <div class="activityIconBox" id="activityIconBox"></div>
|
|
|
|
|
+ <div class="file-wraps-small-icon">
|
|
|
|
|
+ <i id="activityImageIcon" class="fa fa-plus" style="font-size: 30px"></i>
|
|
|
|
|
+ <input type="file" class="uploadImage" id="activityImage" name="activityImage" accept="image/*"/>
|
|
|
</div>
|
|
</div>
|
|
|
</div>
|
|
</div>
|
|
|
</div>
|
|
</div>
|
|
@@ -151,8 +154,8 @@
|
|
|
<th:block th:include="include :: cropbox-js"/>
|
|
<th:block th:include="include :: cropbox-js"/>
|
|
|
<script type="text/javascript">
|
|
<script type="text/javascript">
|
|
|
var prefix = ctx + "system/configuration"
|
|
var prefix = ctx + "system/configuration"
|
|
|
- var prefixEdit = "http://localhost:10002/oneportal/wxportal/magnet"
|
|
|
|
|
- // var prefixEdit = "https://suishenbangtest.nipponpaint.com.cn/oneportal/wxportal/magnet";
|
|
|
|
|
|
|
+ // var prefixEdit = "http://localhost:10002/oneportal/wxportal/magnet"
|
|
|
|
|
+ var prefixEdit = "https://suishenbangtest.nipponpaint.com.cn/oneportal/wxportal/magnet";
|
|
|
|
|
|
|
|
var bgImageUrl = '';
|
|
var bgImageUrl = '';
|
|
|
var smallImageUrlArray = {};
|
|
var smallImageUrlArray = {};
|
|
@@ -167,6 +170,15 @@
|
|
|
getThemeInfo();
|
|
getThemeInfo();
|
|
|
})
|
|
})
|
|
|
|
|
|
|
|
|
|
+ $('.activityIconBox').on('click','.activityIconItemClear', function (res) {
|
|
|
|
|
+ activityImageUrlArray.splice(res.currentTarget.dataset.index,1);
|
|
|
|
|
+ console.log(1111,activityImageUrlArray)
|
|
|
|
|
+ document.getElementById('activityIconBox').innerHTML = '';
|
|
|
|
|
+ activityImageUrlArray.forEach((item,index)=>{
|
|
|
|
|
+ $(".activityIconBox").append("<div class='activityIconItem'><img src='" + item + "' style='width: 50px;height: 50px;'><div class='activityIconItemClear'data-index='" + index + "'>×</div></div>")
|
|
|
|
|
+ })
|
|
|
|
|
+ })
|
|
|
|
|
+
|
|
|
$('.uploadImage').on('change', function (res) {
|
|
$('.uploadImage').on('change', function (res) {
|
|
|
var reader = new FileReader();
|
|
var reader = new FileReader();
|
|
|
reader.onload = function (e) {
|
|
reader.onload = function (e) {
|
|
@@ -230,10 +242,10 @@
|
|
|
document.getElementById("bgImageIcon").style.display = 'none';
|
|
document.getElementById("bgImageIcon").style.display = 'none';
|
|
|
} else if (imgType == 'activityImage'){
|
|
} else if (imgType == 'activityImage'){
|
|
|
activityImageUrlArray.push(result.data.url);
|
|
activityImageUrlArray.push(result.data.url);
|
|
|
- console.log('activityImageUrlArray',activityImageUrlArray);
|
|
|
|
|
- $(".activityIconBox").append("<img src='" + result.data.url + "' style='width:50px;height:50px;'>")
|
|
|
|
|
- // $("#activityImageDiv").html("<img src='" + result.data.url + "' style='width;100%;height:100%;'>");
|
|
|
|
|
- // document.getElementById("activityImageDiv").style.display = 'block';
|
|
|
|
|
|
|
+ document.getElementById('activityIconBox').innerHTML = '';
|
|
|
|
|
+ activityImageUrlArray.forEach((item,index)=>{
|
|
|
|
|
+ $(".activityIconBox").append("<div class='activityIconItem'><img src='" + item + "' style='width: 50px;height: 50px;'><div class='activityIconItemClear'data-index='" + index + "'>×</div></div>")
|
|
|
|
|
+ })
|
|
|
} else {
|
|
} else {
|
|
|
smallImageUrlArray[imgType] = result.data.url;
|
|
smallImageUrlArray[imgType] = result.data.url;
|
|
|
$("#"+imgType).html("<img src='" + result.data.url + "' style='width;100%;height:100%;'>");
|
|
$("#"+imgType).html("<img src='" + result.data.url + "' style='width;100%;height:100%;'>");
|
|
@@ -276,8 +288,8 @@
|
|
|
}
|
|
}
|
|
|
if (result.data.activityIconObject.length > 0){
|
|
if (result.data.activityIconObject.length > 0){
|
|
|
activityImageUrlArray = result.data.activityIconObject;
|
|
activityImageUrlArray = result.data.activityIconObject;
|
|
|
- activityImageUrlArray.forEach(item=>{
|
|
|
|
|
- $(".activityIconBox").append("<img src='" + item + "' style='width:50px;height:50px;'>")
|
|
|
|
|
|
|
+ activityImageUrlArray.forEach((item,index)=>{
|
|
|
|
|
+ $(".activityIconBox").append("<div class='activityIconItem'><img src='" + item + "' style='width: 50px;height: 50px;'><div class='activityIconItemClear'data-index='" + index + "'>×</div></div>")
|
|
|
})
|
|
})
|
|
|
// $("#activityImageDiv").html("<img src='" + result.data.activityIconObject[0] + "' style='width;100%;height:100%;'>");
|
|
// $("#activityImageDiv").html("<img src='" + result.data.activityIconObject[0] + "' style='width;100%;height:100%;'>");
|
|
|
// document.getElementById("activityImageDiv").style.display = 'block';
|
|
// document.getElementById("activityImageDiv").style.display = 'block';
|