代码拉取完成,页面将自动刷新
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width,initial-scale=1,user-scalable=0">
<meta name="apple-mobile-web-app-capable" content="yes">
<title>申请售后</title>
<link rel="stylesheet" href="./css/same-css.css">
<link rel="stylesheet" href="./css/me-shop-after-css.css">
<script src="./js/jquery-3.1.0.min.js"></script>
<script src="./js/lrz.bundle.js"></script>
</head>
<body>
<!--售后类型-->
<div class="head">售后类型<span class="light">*</span></div>
<div class="type">
<ul>
<li class="active">
<span> 申请退款(无需退货)</span> <i class="action"></i>
</li>
<li>
<span> 申请退货</span> <i></i>
</li>
</ul>
</div>
<!--退款原因-->
<div class="head">退款原因<span class="light">*</span></div>
<div class="reason">
<div class="reason-head">退款原因</div><i></i>
<div class="reason-view" style="display: none;">
<ul>
<li>未收到货1</li>
<li>未收到货2</li>
<li>未收到货3</li>
</ul>
</div>
</div>
<!--退款金额-->
<div class="head">退款金额<span class="light">*</span><span class="note">不超过¥29.9</span></div>
<div class="money">
<div>
<input type="text" placeholder="请输入退款金额">
</div>
</div>
<!--退款说明-->
<div class="head">退款说明</div>
<div class="explain">
<div>
<input type="text" placeholder="请输入退款说明">
</div>
</div>
<!--退款凭证-->
<div class="head">退款凭证</div>
<div class="upload">
<div class="upload-main">
<input type="file" id="uploadphoto1" name="uploadfile" value="请点击上传图片" style="display:none;" />
<div class="img-list"></div>
<a href="javascript:void(0);" onclick="uploadphoto1.click()" class="uploadbtn"></a>
</div>
<div class="upload-main">
<input type="file" id="uploadphoto2" name="uploadfile" value="请点击上传图片" style="display:none;" />
<div class="img-list"></div>
<a href="javascript:void(0);" onclick="uploadphoto2.click()" class="uploadbtn"></a>
</div>
<div class="upload-main">
<input type="file" id="uploadphoto3" name="uploadfile" value="请点击上传图片" style="display:none;" />
<div class="img-list"></div>
<a href="javascript:void(0);" onclick="uploadphoto3.click()" class="uploadbtn"></a>
</div>
</div>
<button>提交申请</button>
<script>
$(document).ready(function(){
$('.type ul li').click(function(){
removeAll();
$(this).addClass('active');
$(this).find('i').addClass('action');
});
function removeAll(){
$('.type ul li').removeClass('active');
$('.type ul li i').removeClass('action');
}
$('.reason-head').click(function(){
$('.reason-view').slideToggle(100);
});
$('.reason-view ul li').click(function(){
$('.reason-view').hide();
$('.reason-head').text($(this).text());
});
$('input[name=uploadfile]').on('change', function(){
var $this = $(this);
lrz(this.files[0], {width: 220}).then(function (rst) {
console.log(rst);
var attrSrc = '<img src="'+rst.base64+'" alt="" />';
$this.parent().find('.img-list').append(attrSrc);
$this.parent().find('.img-list img').on('load', function () {
var picWidth = $this.parent().find('.img-list img').width();
var picHeight = $this.parent().find('.img-list img').height();
// console.log('高:'+ picHeight + ';' + '宽:' + picWidth );
if(picWidth >= picHeight){
$this.parent().find('.img-list img').css('height','100%');
} else if(picHeight > picWidth){
$this.parent().find('.img-list img').css('width','100%');
}
});
$this.parent().find('.img-list').show();
$this.parent().find('a').hide();
/*$.ajax({
url: '',
type: 'post',
data: {img: rst.base64},
dataType: 'json',
timeout: 200000,
success: function (response) {
if (response.ecd == '0') {
alert('成功');
return true;
} else {
return alert(response.msg);
}
},
error: function (jqXHR, textStatus, errorThrown) {
if (textStatus == 'timeout') {
alert('请求超时');
return false;
}
alert(jqXHR.responseText);
}
});*/
})
.catch(function (err) {
})
.always(function () {
});
});
});
</script>
</body>
</html>
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。