Commit c3898845 authored by agping's avatar agping

退款已审核

parent 166a7edd
...@@ -537,6 +537,8 @@ ...@@ -537,6 +537,8 @@
<div class="modal-footer noprint" id="hiddenOr" > <div class="modal-footer noprint" id="hiddenOr" >
<button type="button" class="btn btn-primary pass" href="#modal_pass" data-toggle="modal">审核通过</button> <button type="button" class="btn btn-primary pass" href="#modal_pass" data-toggle="modal">审核通过</button>
<button type="button" class="btn btn-primary turnback" href="#tuikuan_modal" data-toggle="modal">转到已退款</button> <button type="button" class="btn btn-primary turnback" href="#tuikuan_modal" data-toggle="modal">转到已退款</button>
<button type="button" class="btn btn-primary inReview" href="javascript:;">转到已审核</button>
<button type="button" class="btn btn-primary fail" href="#modal_false" data-toggle="modal">驳回</button> <button type="button" class="btn btn-primary fail" href="#modal_false" data-toggle="modal">驳回</button>
<button type="button" class="btn btn-primary" id="print" >打印</button> <button type="button" class="btn btn-primary" id="print" >打印</button>
</div> </div>
......
...@@ -13,6 +13,8 @@ define(['doT', 'text!temp/refund_office_template_tpl.html', 'css!style/home.css' ...@@ -13,6 +13,8 @@ define(['doT', 'text!temp/refund_office_template_tpl.html', 'css!style/home.css'
agent_id_phone : '', agent_id_phone : '',
check_status : 1 , check_status : 1 ,
deleteRefundId:'', deleteRefundId:'',
check_id:'',
init: function() { init: function() {
//初始化dot //初始化dot
$(document.body).append(template); $(document.body).append(template);
...@@ -77,7 +79,15 @@ define(['doT', 'text!temp/refund_office_template_tpl.html', 'css!style/home.css' ...@@ -77,7 +79,15 @@ define(['doT', 'text!temp/refund_office_template_tpl.html', 'css!style/home.css'
that.check_id = id ; that.check_id = id ;
that.refundText(id) that.refundText(id)
}); });
//退款转到审核中
_doc.on('click', '.inReview', function(e) {
e.preventDefault();
e.stopPropagation();
if(confirm('确认转到审核中?')){
refund.inReview();
};
});
//重置搜索条件 //重置搜索条件
$(document).on('click','#reset',function(e){ $(document).on('click','#reset',function(e){
that.resetAll(); that.resetAll();
...@@ -331,26 +341,36 @@ define(['doT', 'text!temp/refund_office_template_tpl.html', 'css!style/home.css' ...@@ -331,26 +341,36 @@ define(['doT', 'text!temp/refund_office_template_tpl.html', 'css!style/home.css'
$('.pass').show(); $('.pass').show();
$('.turnback').hide(); $('.turnback').hide();
$('.fail').show(); $('.fail').show();
$('.inReview').hide();//办公楼退款转到审核中
} else if (data.data.status == 2) { } else if (data.data.status == 2) {
str = '退款成功' str = '退款成功'
$('.pass').hide(); $('.pass').hide();
$('.turnback').hide(); $('.turnback').hide();
$('.fail').hide(); $('.fail').hide();
$('.inReview').show();//办公楼退款转到审核中
} else if (data.data.status == 3) { } else if (data.data.status == 3) {
str = '已审核' str = '已审核'
$('.pass').hide(); $('.pass').hide();
$('.turnback').show(); $('.turnback').show();
$('.fail').show(); $('.fail').show();
$('.inReview').hide();//办公楼退款转到审核中
} else if (data.data.status == 4) { } else if (data.data.status == 4) {
str = '驳回' str = '驳回'
$('.pass').hide(); $('.pass').hide();
$('.turnback').hide(); $('.turnback').hide();
$('.fail').hide(); $('.fail').hide();
$('.inReview').hide();//办公楼退款转到审核中
} else { } else {
str = '审核中' str = '审核中'
$('.pass').show(); $('.pass').show();
$('.turnback').hide(); $('.turnback').hide();
$('.fail').show(); $('.fail').show();
$('.inReview').hide();//办公楼退款转到审核中
} }
$('#chech_status').text(str); $('#chech_status').text(str);
var img = data.data.img ; var img = data.data.img ;
...@@ -480,7 +500,27 @@ define(['doT', 'text!temp/refund_office_template_tpl.html', 'css!style/home.css' ...@@ -480,7 +500,27 @@ define(['doT', 'text!temp/refund_office_template_tpl.html', 'css!style/home.css'
} }
}); });
}, },
//转到审核中
inReview: function() {
$.ajax({
url: '/office_index/recoverCheckRefund',
type: 'POST',
async: true,
data: {
'refund_id':refund.check_id,
},
dataType: 'json',
success: function(data) {
if(data.code == 200) {
alert('提交成功');
$('.modal').modal("hide");
refund.getList(refund.pageNo);
}else{
alert(data.msg);
}
}
});
},
countValue : function(){ countValue : function(){
var that = refund ; var that = refund ;
var data = that.listData ; var data = that.listData ;
......
...@@ -13,6 +13,7 @@ define(['doT', 'text!temp/refund_shop_template_tpl.html', 'css!style/home.css', ...@@ -13,6 +13,7 @@ define(['doT', 'text!temp/refund_shop_template_tpl.html', 'css!style/home.css',
agent_id_phone : '', agent_id_phone : '',
check_status : 1 , check_status : 1 ,
deleteRefundId:'', deleteRefundId:'',
check_id:'',
init: function() { init: function() {
//初始化dot //初始化dot
$(document.body).append(template); $(document.body).append(template);
...@@ -66,6 +67,15 @@ define(['doT', 'text!temp/refund_shop_template_tpl.html', 'css!style/home.css', ...@@ -66,6 +67,15 @@ define(['doT', 'text!temp/refund_shop_template_tpl.html', 'css!style/home.css',
$(document).on('click','#confirm_deleteMoney',function(e){ $(document).on('click','#confirm_deleteMoney',function(e){
that.deleteRefund(refund.deleteRefundId); that.deleteRefund(refund.deleteRefundId);
}); });
//退款转到审核中
_doc.on('click', '.inReview', function(e) {
e.preventDefault();
e.stopPropagation();
if(confirm('确认转到审核中?')){
refund.inReview();
};
});
//搜索 //搜索
$(document).on('click','#search',function(e){ $(document).on('click','#search',function(e){
...@@ -331,26 +341,36 @@ define(['doT', 'text!temp/refund_shop_template_tpl.html', 'css!style/home.css', ...@@ -331,26 +341,36 @@ define(['doT', 'text!temp/refund_shop_template_tpl.html', 'css!style/home.css',
$('.pass').show(); $('.pass').show();
$('.turnback').hide(); $('.turnback').hide();
$('.fail').show(); $('.fail').show();
$('.inReview').hide();//转到审核中
} else if (data.data.status == 2) { } else if (data.data.status == 2) {
str = '退款成功' str = '退款成功'
$('.pass').hide(); $('.pass').hide();
$('.turnback').hide(); $('.turnback').hide();
$('.inReview').show();//转到审核中
$('.fail').hide(); $('.fail').hide();
} else if (data.data.status == 3) { } else if (data.data.status == 3) {
str = '已审核' str = '已审核'
$('.pass').hide(); $('.pass').hide();
$('.turnback').show(); $('.turnback').show();
$('.fail').show(); $('.fail').show();
$('.inReview').hide();//转到审核中
} else if (data.data.status == 4) { } else if (data.data.status == 4) {
str = '驳回' str = '驳回'
$('.pass').hide(); $('.pass').hide();
$('.turnback').hide(); $('.turnback').hide();
$('.fail').hide(); $('.fail').hide();
$('.inReview').hide();//转到审核中
} else { } else {
str = '审核中' str = '审核中'
$('.pass').show(); $('.pass').show();
$('.turnback').hide(); $('.turnback').hide();
$('.fail').show(); $('.fail').show();
$('.inReview').hide();//转到审核中
} }
$('#chech_status').text(str); $('#chech_status').text(str);
var img = data.data.img ; var img = data.data.img ;
...@@ -405,6 +425,27 @@ define(['doT', 'text!temp/refund_shop_template_tpl.html', 'css!style/home.css', ...@@ -405,6 +425,27 @@ define(['doT', 'text!temp/refund_shop_template_tpl.html', 'css!style/home.css',
} }
}); });
}, },
//转到审核中
inReview: function() {
$.ajax({
url: '/index/recoverCheckRefund',
type: 'POST',
async: true,
data: {
'refund_id':refund.check_id,
},
dataType: 'json',
success: function(data) {
if(data.code == 200) {
alert('提交成功');
$('.modal').modal("hide");
refund.getList(refund.pageNo);
}else{
alert(data.msg);
}
}
});
},
//删除退款 //删除退款
deleteRefund: function(id) { deleteRefund: function(id) {
$.ajax({ $.ajax({
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment