From a261a1054982d8e9d60bc9045f606ea1f8896a7e Mon Sep 17 00:00:00 2001 From: AirIce <940173803@qq.com> Date: Mon, 20 Apr 2020 18:09:36 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E5=8E=9F=E5=9B=BE=E7=BC=96?= =?UTF-8?q?=E8=BE=91bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/Crop.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/Crop.php b/src/Crop.php index 2825395..6da1ebb 100644 --- a/src/Crop.php +++ b/src/Crop.php @@ -160,7 +160,9 @@ function cropper(imgSrc,cropperFileE,w,h) //默认关闭框 cropperFileE.nextAll('.cropper-img').attr('src',imgSrc); //替换提交数据 - cropperFileE.nextAll('.cropper-input').val(imgSrc); + if (cropperFileE.nextAll('.cropper-input').val() == '') { + cropperFileE.nextAll('.cropper-input').val(imgSrc); + } //销毁剪裁器实例 cropper.destroy(); },