Commit 1766ff4f authored by stone's avatar stone

【fix】付款申请审批界面增加发票状态的校验

parent 6eea6868
......@@ -11,7 +11,7 @@
<bm:query-sql><![CDATA[
select to_char(req_date,'yyyy')||'年'||to_char(req_date,'mm')||'月' req_date
select to_char(add_months(req_date,-1),'yyyy')||'年'||to_char(add_months(req_date,-1),'mm')||'月' req_date
from csh_payment_req_hd v
where v.payment_req_id=${@payment_req_id}
......
......@@ -75,6 +75,17 @@
cpr.amount,
c.lease_item_amount,
to_char(c.lease_item_amount,'FM999,999,999,990.00') lease_item_amount_print,
-- --开票状态
ccc.billing_status,
(SELECT code_value_name
FROM sys_code_values_v scv
WHERE scv.code = 'CON_BILLING_STATUS'
AND code_value= ccc.billing_status
AND scv.code_value_enabled_flag = 'Y'
AND scv.code_enabled_flag = 'Y') billing_status_n,
--发票状态
acp_invoice_pkg.return_invoice_status(p_contract_id=>c.contract_id) invoice_status_n,
--首付款抵充金额
(select to_char( nvl(hd.other_payment2, 0),'FM999,999,999,990.00')
......@@ -107,11 +118,17 @@
cpr.ref_doc_line_id,
cpr.ref_doc_category
from csh_payment_req_ln cpr, con_contract c, hls_bp_master hbm,con_contract_lease_item ccli
from csh_payment_req_ln cpr,
con_contract c,
hls_bp_master hbm,
con_contract_lease_item ccli,
con_contract_cashflow ccc
where cpr.ref_doc_category = 'CONTRACT'
AND ccli.contract_id=cpr.ref_doc_id
and c.contract_id = cpr.ref_doc_id
and hbm.bp_id = c.bp_id_tenant) v
and hbm.bp_id = c.bp_id_tenant
AND ccc.contract_id=c.contract_id
AND ccc.cf_item=0) v
#WHERE_CLAUSE#
]]></bm:query-sql>
</bm:operation>
......
......@@ -78,8 +78,8 @@
</p>
</tc>
<tc width="8">
<p align="center" width="4">
<t fontFamily="黑体" fontSize="14" fontColor="000000"> 客户名称 </t>
<p align="center">
<t fontFamily="黑体" fontSize="14" fontColor="000000">客户名称</t>
</p>
</tc>
<tc width="8">
......
......@@ -81,7 +81,25 @@
<script type="text/javascript"><![CDATA[
jQuery.noConflict();
//工作流审批界面校验发票状态
if ('${/parameter/@source_type}' == 'WFL_Y') {
zjwfl5110_ApproveChecker_add('zjwfl5110_submit', function (type) {
var lnds_id = get_dsid_by_basetable(window['${/parameter/@layout_code}_layoutDataSetList'], 'csh_payment_req_ln');
// if ('${/parameter/@re_param}' == 'node1') {
if (type == 'agree') {
var records = $(lnds_id).getAll();
for ( var i = 0;i< records.length;i++) {
if(records[i].get('billing_status_n')!='已开票' ||records[i].get('invoice_status_n')!='已确认'){
$L.showErrorMessage("提示",'请选择开票状态为已开票,发票状态为已确认的现金流!');
return false;
}
}
} else return true;
// }
});
}
//如果头id 不为空,就使用自在定义的ds进行查询
Leaf.onReady(function(){
var lnds_id = get_dsid_by_basetable(window['${/parameter/@layout_code}_layoutDataSetList'], 'csh_payment_req_ln');
......
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