Authored by shuaiguo

feat(入口图片): 增加删除操作

... ... @@ -120,6 +120,9 @@
<td><input type="file" id="iosSmallImageFirst" name="iosSmallImageFirst" value="[[iosSmallImageFirst]]"></td>
<td><input type="file" id="iosBigImageFirst" name="iosBigImageFirst" value="[[iosSmallImageFirst]]"></td>
<td><input type="file" id="androidImageFirst" name="androidImageFirst" value="[[androidImageFirst]]"></td>
<td>
<button class="btn btn-danger btn-sm del-btn" data-event="template-content" type="button" data-key="first">删除图片</button>
</td>
</tr>
</table>
... ...
... ... @@ -233,6 +233,20 @@ function appEntranceIconOP( url, item) {
});
});
$(".modal-dialog").css("width","800px");
/**
* 删除图片
*/
$(document).on("click", ".del-btn", function () {
var key = $(this).data('key');
var $parent = $(this).parent().parent();
$parent.find("input[type=file]").each(function(){
$(this).attr("value", "");
});
$parent.find(".upload-image-list .fileinput-button-icon").html('+');
});
a.init();
... ...