Commit dba28bb0 authored by agping's avatar agping

1

parent 6b24288e
......@@ -72,21 +72,7 @@
width: 80px;
display: none;
}
.is-submit-pass,.is-submit-passed{
background-color: #286090;
color: white;
padding: 0 3px;
border-radius: 6px;
width: 111px;
height: 32px;
line-height: 32px;
font-size: 15px;
text-align: center;
cursor: pointer;
display: none;
float: left;
margin-left: 100px;
}
</style>
<div id="page-content-wrapper">
<div class="container">
......@@ -174,7 +160,6 @@
<th class="text-center">转账户名</th>
<th class="text-center">业务员</th>
<th class="text-center">所属门店</th>
<th class="text-center">审核人</th>
<th class="text-center">意向金收条编号</th>
<th class="text-center">附件</th>
</tr>
......@@ -200,7 +185,6 @@
<th class="text-center">转账户名</th>
<th class="text-center">业务员</th>
<th class="text-center">所属门店</th>
<th class="text-center">审核人</th>
<th class="text-center">保管金收条编号</th>
<th class="text-center">附件</th>
</tr>
......@@ -235,9 +219,9 @@
</div>
<!--6-->
<h4>
以上入账金额:451223
以上出账金额:45123
入账应汇款:145222
以上入账金额:<span class="recorded_money"></span>
以上出账金额:<span class="adjustment_money"></span>
入账应汇款:<span class="remittance_money"></span>
</h4>
<div class="table-responsive">
<table class="table table-striped table-bordered table-hover table-condensed">
......@@ -310,30 +294,62 @@
<th class="text-center">其他</th>
<th class="text-center">审核人</th>
<th class="text-center">审核时间</th>
<th class="text-center">备注</th>
</tr>
</thead>
<tbody class="text-center" id="maintable_list_a">
<tbody class="text-center" id="maintable_list_f">
</tbody>
<tfoot class="text-center" id="maintable_list">
<tr>
<td class="text-center">555</td>
<td class="text-center">5</td>
<td class="text-center">6</td>
<td class="text-center">3</td>
<td class="text-center">2</td>
<td class="text-center">2</td>
<td class="text-center">33</td>
<td class="text-center">22</td>
<td class="text-center">15517301736</td>
<td class="text-center">2017.3.6</td>
<td class="text-center">
<span id="total_a">555</span>
</td>
<td class="text-center">
<span id="total_b"></span>
</td>
<td class="text-center">
<span id="total_c"></span>
</td>
<td class="text-center">
<span id="total_d"></span>
</td>
<td class="text-center">
<span id="total_e"></span>
</td>
<td class="text-center">
<span id="total_f"></span>
</td>
<td class="text-center">
<span id="total_g"></span>
</td>
<td class="text-center">
<span id="total_h"></span>
</td>
<td class="text-center">
<span id="total_f"></span>
</td>
<td class="text-center">
<span id="total_g"></span>
</td>
<td class="text-center">
<span id="total_h"></span>
</td>
</tr>
</tbody>
</tfoot>
</table>
</div>
</div>
<div class="is-submit-div">
<div class="is-submit">提交</div>
<div class="is-submit-pass">审核通过</div>
<div class="is-submit-passed">转到已审核</div>
<!--<div class="is-submit-pass">-->
<a class="btn btn-primary" href="#modal_financialremark" data-toggle="modal">审核通过</a>
<a class="btn btn-primary is-submit-passed">转到已审核</a>
</div>
......@@ -348,3 +364,49 @@
<div id="main_loading_pic">
<img src="/resource/image/jz2.gif">
</div>
<!--状态记录-->
<div class="modal fade" id="modal_financial" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
<div class="modal-dialog">
<div class="modal-content">
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal" aria-hidden="true">
×
</button>
<h4 class="modal-title">
收款图片
</h4>
</div>
<div class="modal-body">
666
</div>
<div class="modal-footer">
</div>
</div>
<!-- /.modal-content -->
</div>
<!-- /.modal -->
</div>
<!--审核通过 备注-->
<div class="modal fade" id="modal_financial" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
<div class="modal-dialog">
<div class="modal-content">
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal" aria-hidden="true">
×
</button>
<h4 class="modal-title">
审核通过
</h4>
</div>
<div class="modal-body">
<textarea name="" rows="" cols="" placeholder="请填写备注">
</textarea>
</div>
<div class="modal-footer">
</div>
</div>
<!-- /.modal-content -->
</div>
<!-- /.modal -->
</div>
\ No newline at end of file
......@@ -11,7 +11,10 @@ define(['doT', 'text!temp/financial_manager_daily_list_template_tpl.html', 'css!
order_id: 0,//订单id
maidTotalCommission: 0,//应收总佣金
financialTime: '',//应收总佣金
recordid: '', //收款id
isFinancial: 0, //收款id
operationStatus:0,
daily_id:0,//日报id
init: function() {
//初始化时间
var myDate = new Date();
......@@ -22,6 +25,7 @@ define(['doT', 'text!temp/financial_manager_daily_list_template_tpl.html', 'css!
$('#create_time_start').val(day_end);//店长日报默认当天
//初始化dot
if(getUrlParam('time')){
bargain.isFinancial = 1;
$('#create_time_start').hide();
$('.is-submit').hide();
$('.is-print').show();
......@@ -29,6 +33,7 @@ define(['doT', 'text!temp/financial_manager_daily_list_template_tpl.html', 'css!
$('.is-submit-passed').show();
bargain.financialTime = getUrlParam('time');
}else{
bargain.isFinancial = 0;
bargain.financialTime = $('#create_time_start').val();
}
$(document.body).append(template);
......@@ -58,6 +63,39 @@ define(['doT', 'text!temp/financial_manager_daily_list_template_tpl.html', 'css!
e.stopPropagation();
bargain.getList(1); //一级审核搜索
});
//点击资料 显示图片
_doc.on('click', '.record-pic', function(e) {
e.preventDefault();
e.stopPropagation();
bargain.recordid = $(this).attr("data-recordid");
bargain.getPic();
});
//店长提交日报
_doc.on('click', '.is-submit', function(e) {
e.preventDefault();
e.stopPropagation();
bargain.submitReport();
});
//财务审核 通过
_doc.on('click', '.is-submit-pass', function(e) {
e.preventDefault();
e.stopPropagation();
bargain.operationStatus = 0;
bargain.submitPassReport();
});
//财务 转到已审核
_doc.on('click', '.is-submit-passed', function(e) {
e.preventDefault();
e.stopPropagation();
bargain.operationStatus = 1;
bargain.submitPassReport();
});
//打印功能
_doc.on('click', '.is-print', function(e) {
e.preventDefault();
......@@ -116,10 +154,12 @@ define(['doT', 'text!temp/financial_manager_daily_list_template_tpl.html', 'css!
console.count('bar');
var params = {
'AuthToken':user_info_obj.AuthToken,
'store_id': 730,
'is_store': 0,
// 'daily_data': bargain.financialTime
'daily_data': '2018-12-01'
'store_id': user_info_obj.store_id,
'is_store': bargain.isFinancial,
'daily_data': bargain.financialTime
// 'store_id': 730,
// 'is_store': 0,
// 'daily_data': '2018-12-01'
};
$.ajax({
type: 'GET',
......@@ -149,39 +189,45 @@ define(['doT', 'text!temp/financial_manager_daily_list_template_tpl.html', 'css!
//调整出账
var doTtmpl = doT.template(document.getElementById('e_financial_daily_list_tpl').innerHTML);
$("#maintable_list_e").html(doTtmpl(data.data.list.adjustment));
//审核记录
var doTtmpl = doT.template(document.getElementById('f_financial_daily_list_tpl').innerHTML);
$("#maintable_list_f").html(doTtmpl(data.data.check_list));
//判断店长是否提交过
if(data.data.is_commit*1){//提交过
$('.is-submit').hide();
//总计commit_info
$('#pay_a').html(data.data.commit_info.other_bank);
$('#pay_b').html(data.data.commit_info.other_bank);
$('#pay_c').html(data.data.commit_info.other_bank);
$('#pay_d').html(data.data.commit_info.other_bank);
$('#pay_e').html(data.data.commit_info.other_bank);
$('#pay_f').html(data.data.commit_info.other_bank);
$('#pay_g').html(data.data.commit_info.other_bank);
bargain.daily_id = data.data.commit_info.id;
$('#pay_a').html(data.data.commit_info.alipay);
$('#pay_b').html(data.data.commit_info.tenpay);
$('#pay_c').html(data.data.commit_info.realty_pay);
$('#pay_d').html(data.data.commit_info.family_pay);
$('#pay_e').html(data.data.commit_info.private_bank);
$('#pay_f').html(data.data.commit_info.cash);
$('#pay_g').html(data.data.commit_info.pos);
$('#pay_h').html(data.data.commit_info.other_bank);
$('#pay_i').html(data.data.commit_info.other_bank);
$('#pay_j').html(data.data.commit_info.other_bank);
$('#pay_i').html();
$('#pay_j').html();
}else{//未提交
$('.is-submit').html('提交');
$('.audit-records').hide();
//未提交
$('#pay_a').html(data.data.total_info.alipay);
$('#pay_a').html(data.data.total_info.other_bank);
$('#pay_a').html(data.data.total_info.other_bank);
$('#pay_a').html(data.data.total_info.other_bank);
$('#pay_a').html(data.data.total_info.other_bank);
$('#pay_a').html(data.data.total_info.other_bank);
$('#pay_a').html(data.data.total_info.other_bank);
$('#pay_a').html(data.data.total_info.other_bank);
$('#pay_a').html(data.data.total_info.other_bank);
$('#pay_b').html(data.data.total_info.tenpay);
$('#pay_c').html(data.data.total_info.realty_pay);
$('#pay_d').html(data.data.total_info.family_pay);
$('#pay_e').html(data.data.total_info.private_bank);
$('#pay_f').html(data.data.total_info.cash);
$('#pay_g').html(data.data.total_info.pos);
$('#pay_h').html(data.data.total_info.other_bank);
$('#pay_i').html();
$('#pay_j').html();
}
//入账总计
$('.adjustment_money').html(data.data.adjustment_money);
$('.recorded_money').html(data.data.recorded_money);
$('.remittance_money').html(data.data.remittance_money);
/*分页代码*/
add_page(data.data.total, pageNo, bargain.pageSize, bargain.getList);
......@@ -244,6 +290,87 @@ define(['doT', 'text!temp/financial_manager_daily_list_template_tpl.html', 'css!
}
});
},
//店长提交日报
submitReport: function() {
$.ajax({
url: '/index/addDaily',
type: 'GET',
async: true,
data: {
'agent_id': user_info_obj.id,
"agent_name": user_info_obj.name,
'daily_date': bargain.financialTime,
"alipay": $('#pay_a').html(),
'tenpay': $('#pay_b').html(),
"realty_pay": $('#pay_c').html(),
'family_pay': $('#pay_d').html(),
"private_bank": $('#pay_e').html(),
"cash": $('#pay_f').html(),
"pos": $('#pay_g').html(),
"other_bank": $('#pay_h').html()
},
dataType: 'json',
success: function(data) {
if(data.code == 200) {
alert('提交成功');
bargain.getList();
}
}
});
},
//获取图片
getPic: function() {
$.ajax({
url: '/index/getPayLogImg',
type: 'GET',
async: true,
data: {
'pay_log_id': bargain.recordid,
'AuthToken':user_info_obj.AuthToken,
},
dataType: 'json',
success: function(data) {
if(data.code == 200 && data.data != null) {
fn && fn(data.data);
}
}
});
},
//财务审核通过 转到已审核
submitPassReport: function() {
$.ajax({
url: '/index/commitCheck',
type: 'GET',
async: true,
data: {
'daily_id':bargain.daily_id,
'agent_id': user_info_obj.id,
"agent_name": user_info_obj.name,
// 'daily_date': bargain.financialTime,
"alipay": $('#pay_a').html(),
'tenpay': $('#pay_b').html(),
"realty_pay": $('#pay_c').html(),
'family_pay': $('#pay_d').html(),
"private_bank": $('#pay_e').html(),
"cash": $('#pay_f').html(),
"pos": $('#pay_g').html(),
"other_bank": $('#pay_h').html(),
"operation_status" : bargain.operationStatus//0审核通过 1转为已审核
},
dataType: 'json',
success: function(data) {
if(data.code == 200) {
alert('提交成功');
bargain.getList();
}else{
alert(data.msg);
}
}
});
},
};
return bargain;
});
\ No newline at end of file
......@@ -84,10 +84,10 @@ define(['doT', 'text!temp/pk_week_list_template_tpl.html.html', 'css!style/home.
_this.removeClass('a-span').addClass('a-span-active').siblings().removeClass('a-span-active').addClass('a-span');
pkList.mainTabIndexTwo = _this.attr('data-id')*1 - 1;
if(pkList.mainTabIndexTeam){
var doTtmpl = doT.template(document.getElementById('team_pk_list_tpl').innerHTML);
var doTtmpl = doT.template(document.getElementById('team_pk_week_list_tpl').innerHTML);
}else{
var doTtmpl = doT.template(document.getElementById('pk_list_tpl').innerHTML);
var doTtmpl = doT.template(document.getElementById('pk_week_list_tpl').innerHTML);
}
$("#pk_list").html(doTtmpl(pkList.mainTabArr[pkList.mainTabIndexTwo]));
......
......@@ -17,7 +17,7 @@
<td>[%= it[item]['is_open'] %]</td>
<td>[%= it[item]['is_dividend']%]</td>
<td>
<a class="btn1 btn-info" href="#modal_financial" data-recordid="[%= it[item]['id'] %]" data-toggle="modal">资料</a>
<a class="btn1 btn-info record-pic" href="#modal_financial" data-recordid="[%= it[item]['id'] %]" data-toggle="modal">资料</a>
</td>
</tr>
[% } %]
......@@ -43,7 +43,7 @@
<td>[%= it[item]['store_name'] %]</td>
<td>[%= it[item]['is_open'] %]</td>
<td>[%= it[item]['is_dividend'] %]</td>
<td>[%= it[item]['is_open1'] %]</td>
<td>[%= it[item]['remark'] %]</td>
<td>
<a class="btn1 btn-info" href="#modal_financial" data-recordid="[%= it[item]['id'] %]" data-toggle="modal">资料</a>
</td>
......@@ -61,15 +61,14 @@
[% for(var item in it){ %]
<tr>
<td>[%= it[item]['id'] %]</td>
<td>[%= it[item]['bargain_id1'] %]</td>
<td>[%= it[item]['order_id'] %]</td>
<td>[%= it[item]['house_id'] %]</td>
<td>[%= it[item]['house_address']%]</td>
<td>[%= it[item]['price'] %]</td>
<td>[%= it[item]['money'] %]</td>
<td>[%= it[item]['pay_type'] %]</td>
<td>[%= it[item]['transfer_name'] %]</td>
<td>[%= it[item]['agent_name'] %]</td>
<td>[%= it[item]['store_name']%]</td>
<td>[%= it[item]['transfer_name1'] %]</td>
<td>[%= it[item]['receipt_number'] %]</td>
<td>
<a class="btn1 btn-info" href="#modal_financial" data-recordid="[%= it[item]['id'] %]" data-toggle="modal">资料</a>
......@@ -90,12 +89,11 @@
<td>[%= it[item]['id'] %]</td>
<td>[%= it[item]['house_id'] %]</td>
<td>[%= it[item]['house_address'] %]</td>
<td>[%= it[item]['price']%]</td>
<td>[%= it[item]['money']%]</td>
<td>[%= it[item]['pay_type'] %]</td>
<td>[%= it[item]['transfer_name'] %]</td>
<td>[%= it[item]['agent_name'] %]</td>
<td>[%= it[item]['store_name'] %]</td>
<td>[%= it[item]['pay_type1']%]</td>
<td>[%= it[item]['receipt_number'] %]</td>
<td>
<a class="btn1 btn-info" href="#modal_financial" data-recordid="[%= it[item]['id'] %]" data-toggle="modal">资料</a>
......@@ -119,7 +117,7 @@
<td>[%= it[item]['type']%]</td>
<td>[%= it[item]['create_time'] %]</td>
<td>[%= it[item]['receipt_number'] %]</td>
<td>[%= it[item]['price'] %]</td>
<td>[%= it[item]['money'] %]</td>
<td>
<a class="btn1 btn-info" href="#modal_financial" data-recordid="[%= it[item]['id'] %]" data-toggle="modal">资料</a>
</td>
......@@ -136,16 +134,18 @@
[% if(it.length) { %]
[% for(var item in it){ %]
<tr>
<td>[%= it[item]['id'] %]</td>
<td>[%= it[item]['house_id'] %]</td>
<td>[%= it[item]['house_address'] %]</td>
<td>[%= it[item]['type']%]</td>
<td>[%= it[item]['create_time'] %]</td>
<td>[%= it[item]['receipt_number'] %]</td>
<td>[%= it[item]['price'] %]</td>
<td>
<a class="btn1 btn-info" href="#modal_financial" data-recordid="[%= it[item]['id'] %]" data-toggle="modal">资料</a>
</td>
<td>[%= it[item]['alipay'] %]</td>
<td>[%= it[item]['tenpay'] %]</td>
<td>[%= it[item]['realty_pay'] %]</td>
<td>[%= it[item]['family_pay']%]</td>
<td>[%= it[item]['private_bank'] %]</td>
<td>[%= it[item]['cash'] %]</td>
<td>[%= it[item]['pos'] %]</td>
<td>[%= it[item]['other_bank'] %]</td>
<td>[%= it[item]['operation_name'] %]</td>
<td>[%= it[item]['update_time'] %]</td>
<td>[%= it[item]['remark'] %]</td>
</tr>
[% } %]
[% }else{ %]
......
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