Commit 8e5ecb6e authored by agping's avatar agping

收款记录修改

parent c99b5a1d
...@@ -60,7 +60,7 @@ ...@@ -60,7 +60,7 @@
<span class="btn btn-info btn3 ld-Marheight" id="search">搜索</span> <span class="btn btn-info btn3 ld-Marheight" id="search">搜索</span>
<span class="btn btn-info btn3 ld-Marheight" id="reset">重置</span> <span class="btn btn-info btn3 ld-Marheight" id="reset">重置</span>
<span class="money_total_two fore-span ld-Marheight ">总额:</span><span id="money_total" class="money_total_two fore-span ld-Marheight"></span> <span class="money_total_two fore-span ld-Marheight ">总额:</span><span id="money_total" class="money_total_two fore-span ld-Marheight"></span>
<span class="btn btn-info btn3 ld-Marheight" id="exporting_report">导出报表</span> <span class="btn btn-info btn3 ld-Marheight" id="export">导出报表</span>
</form> </form>
</form> </form>
</td> </td>
......
...@@ -33,6 +33,9 @@ define(['doT', 'text!temp/get_collection_template_tpl.html', 'css!style/home.css ...@@ -33,6 +33,9 @@ define(['doT', 'text!temp/get_collection_template_tpl.html', 'css!style/home.css
$("#reset").click(function() { //重置 $("#reset").click(function() { //重置
document.getElementById("form_search").reset(); document.getElementById("form_search").reset();
}); });
$("#export").click(function() { //导出列表
follow.exportList();
});
$ (document).delegate (".submit_edit2", "click", function () {//提交 $ (document).delegate (".submit_edit2", "click", function () {//提交
follow.house_id2 = $ (this).attr ("data-id"); follow.house_id2 = $ (this).attr ("data-id");
console.log(follow.house_id2); console.log(follow.house_id2);
...@@ -102,6 +105,39 @@ define(['doT', 'text!temp/get_collection_template_tpl.html', 'css!style/home.css ...@@ -102,6 +105,39 @@ define(['doT', 'text!temp/get_collection_template_tpl.html', 'css!style/home.css
} }
}); });
}, },
// 导出列表
exportList: function(pageNo) {
console.log(2);
follow.pageNo = pageNo;
var params = {};
var excel_two = 1;
var user_name = $.trim($('#customer_name').val());
var start_time = $('#start_date').val();
var end_time = $('#end_date').val();
var internal_title = $('#shop_name').val();
var user_phone = $('#customer_phone').val();
var id = $('#shop_num').val() * 1;
var store_name = $('#store_name').val();
var report_phone = $('#applicant_phone').val();
var report_name = $('#applicant_name').val();
//start_time false sting 开始时间
//end_time false sting 开始时间
//internal_title false string 楼盘名
//user_name false string 客户姓名
//user_phone false string 客户手机号
//id false int 商铺id
//store_name false string 门店名
//report_phone false string 报备人手机号
//report_name false string 报备人姓名
//excel false int 1导出
window.open('/index/getCollection?'+
'excel='+ excel_two +'&user_name =' + user_name + '&start_time =' + start_time + '&end_time =' + end_time + '&internal_title =' + internal_title + '&user_phone =' + user_phone + '&id =' + id+ '&store_name =' + store_name+ '&report_phone =' + report_phone+ '&report_name =' + report_name);
},
getList: function(pageNo) { getList: function(pageNo) {
console.log($('#customer_name').val()); console.log($('#customer_name').val());
console.log($('#start_date').val()); console.log($('#start_date').val());
......
...@@ -61,9 +61,15 @@ define (['doT', 'text!temp/user_template_tpl.html','ckfinder','ckfinderStart', ' ...@@ -61,9 +61,15 @@ define (['doT', 'text!temp/user_template_tpl.html','ckfinder','ckfinderStart', '
$("input[name = 'user_status']:checked").removeAttr("checked"); $("input[name = 'user_status']:checked").removeAttr("checked");
user.getGenjinLabel(); user.getGenjinLabel();
}); });
$ (document).delegate (".add_alert", "click", function () {//新增客户
document.getElementById("add_user_form").reset();
});
// ===========================新增客户==================== // ===========================新增客户====================
$ (document).delegate ("#add_user", "click", function () {//新增客户 $ (document).delegate ("#add_user", "click", function () {//新增客户
user.user_id = $ (this).attr ("data-id"); user.user_id = $ (this).attr ("data-id");
user.add_user(); user.add_user();
}); });
...@@ -433,6 +439,7 @@ define (['doT', 'text!temp/user_template_tpl.html','ckfinder','ckfinderStart', ' ...@@ -433,6 +439,7 @@ define (['doT', 'text!temp/user_template_tpl.html','ckfinder','ckfinderStart', '
params.price_demand=$("#price_type2").val(); params.price_demand=$("#price_type2").val();
params.area_demand=$("#area_type2").val(); params.area_demand=$("#area_type2").val();
params.industry_type=$("#industry_type2").val(); params.industry_type=$("#industry_type2").val();
params.type='add';
if (params.user_nick == '') { if (params.user_nick == '') {
alert('姓名不能为空'); alert('姓名不能为空');
...@@ -464,7 +471,8 @@ define (['doT', 'text!temp/user_template_tpl.html','ckfinder','ckfinderStart', ' ...@@ -464,7 +471,8 @@ define (['doT', 'text!temp/user_template_tpl.html','ckfinder','ckfinderStart', '
success: function (data) { success: function (data) {
if (data.code == 200) { if (data.code == 200) {
user.getList(1); user.getList(1);
document.getElementById("add_user_form").reset(); alert('提交成功')
// document.getElementById("add_user_form").reset();
} else { } else {
alert(data.msg); alert(data.msg);
} }
......
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