Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
leaf-hlcm
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
hlcm
leaf-hlcm
Commits
219d7dbe
Commit
219d7dbe
authored
Aug 05, 2022
by
gzj34291
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
I-11321【建机】售后回租开票判断逻辑修改
parent
6d70eb6c
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
80 additions
and
39 deletions
+80
-39
acr_invoice_create.lwm
.../webapp/WEB-INF/classes/acr/ACR510/acr_invoice_create.lwm
+3
-1
sys_invoice_kind_type_v.lwm
.../webapp/WEB-INF/classes/basic/sys_invoice_kind_type_v.lwm
+53
-33
acr_invoice_create_invoice.lview
...ebapp/modules/acr/ACR510/acr_invoice_create_invoice.lview
+24
-5
No files found.
src/main/webapp/WEB-INF/classes/acr/ACR510/acr_invoice_create.lwm
View file @
219d7dbe
...
@@ -40,6 +40,7 @@
...
@@ -40,6 +40,7 @@
<bm:field
name=
"invoice_kind_type"
databaseType=
"VARCHAR2"
datatype=
"java.lang.String"
physicalName=
"INVOICE_KIND_TYPE"
/>
<bm:field
name=
"invoice_kind_type"
databaseType=
"VARCHAR2"
datatype=
"java.lang.String"
physicalName=
"INVOICE_KIND_TYPE"
/>
<bm:field
name=
"invoice_kind_type_n"
databaseType=
"VARCHAR2"
datatype=
"java.lang.String"
physicalName=
"INVOICE_KIND_TYPE_N"
prompt=
"发票种类"
/>
<bm:field
name=
"invoice_kind_type_n"
databaseType=
"VARCHAR2"
datatype=
"java.lang.String"
physicalName=
"INVOICE_KIND_TYPE_N"
prompt=
"发票种类"
/>
<bm:field
name=
"rl_flag"
/>
<bm:field
name=
"rl_flag"
/>
<bm:field
name=
"business_type"
/>
</bm:fields>
</bm:fields>
<bm:operations>
<bm:operations>
<bm:operation
name=
"query"
>
<bm:operation
name=
"query"
>
...
@@ -112,7 +113,8 @@
...
@@ -112,7 +113,8 @@
'N'
'N'
else
else
''
''
end rl_flag
end rl_flag,
con.business_type
from acr_invoice_create_tmp t,
from acr_invoice_create_tmp t,
con_contract_v con,
con_contract_v con,
con_contract_cashflow_all_v cf,
con_contract_cashflow_all_v cf,
...
...
src/main/webapp/WEB-INF/classes/basic/sys_invoice_kind_type_v.lwm
View file @
219d7dbe
...
@@ -10,32 +10,52 @@
...
@@ -10,32 +10,52 @@
AND v.code = 'ACR512_INVOICE_KIND_TYPE'
AND v.code = 'ACR512_INVOICE_KIND_TYPE'
AND EXISTS
AND EXISTS
(SELECT 1
(SELECT 1
FROM acr_invoice_create_tmp t
FROM acr_invoice_create_tmp t,con_contract cc
WHERE t.record_id = ${/parameter/@record_id}
WHERE t.record_id = ${/parameter/@record_id}
and cc.contract_id=t.contract_id
AND cc.business_type !='LEASEBACK'
AND t.invoice_type = 'PAPER'
AND t.invoice_type = 'PAPER'
AND v.code_value IN ('PAPER_GENERAL',
'PAPER_SPECIAL'))
AND v.code_value IN ('PAPER_GENERAL',
'PAPER_SPECIAL'))
UNION ALL
UNION ALL
SELECT v.code_value AS value_code, v.code_value_name AS value_name
SELECT v.code_value AS value_code, v.code_value_name AS value_name
FROM sys_code_values_v v
FROM sys_code_values_v v
WHERE v.code_enabled_flag = 'Y'
WHERE v.code_enabled_flag = 'Y'
AND v.code_value_enabled_flag = 'Y'
AND v.code_value_enabled_flag = 'Y'
AND v.code = 'ACR512_INVOICE_KIND_TYPE'
AND v.code = 'ACR512_INVOICE_KIND_TYPE'
AND EXISTS (SELECT 1
AND EXISTS
FROM acr_invoice_create_tmp t
(SELECT 1
FROM acr_invoice_create_tmp t,con_contract cc
WHERE t.record_id = ${/parameter/@record_id}
WHERE t.record_id = ${/parameter/@record_id}
AND cc.business_type !='LEASEBACK'
AND t.invoice_type = 'ECT'
AND t.invoice_type = 'ECT'
and cc.contract_id=t.contract_id
AND v.code_value IN ('ELECTRONIC_GENERAL','ELECTRONIC_SPECIAL'))
AND v.code_value IN ('ELECTRONIC_GENERAL','ELECTRONIC_SPECIAL'))
UNION ALL
UNION ALL
SELECT v.code_value AS value_code, v.code_value_name AS value_name
SELECT v.code_value AS value_code, v.code_value_name AS value_name
FROM sys_code_values_v v
FROM sys_code_values_v v
WHERE v.code_enabled_flag = 'Y'
WHERE v.code_enabled_flag = 'Y'
AND v.code_value_enabled_flag = 'Y'
AND v.code_value_enabled_flag = 'Y'
AND v.code = 'ACR512_INVOICE_KIND_TYPE'
AND v.code = 'ACR512_INVOICE_KIND_TYPE'
AND EXISTS (SELECT 1
AND EXISTS (SELECT 1
FROM acr_invoice_create_tmp t
FROM acr_invoice_create_tmp t,con_contract cc
WHERE t.record_id = ${/parameter/@record_id}
WHERE t.record_id = ${/parameter/@record_id}
AND t.invoice_type not in('PAPER','ECT')
AND cc.business_type !='LEASEBACK'
AND t.invoice_type not in ('PAPER', 'ECT')
and cc.contract_id=t.contract_id
AND v.code_value IN ('RECEIPT'))
AND v.code_value IN ('RECEIPT'))
UNION ALL
SELECT v.code_value AS value_code, v.code_value_name AS value_name
FROM sys_code_values_v v
WHERE v.code_enabled_flag = 'Y'
AND v.code_value_enabled_flag = 'Y'
AND v.code = 'ACR512_INVOICE_KIND_TYPE'
AND EXISTS
(SELECT 1
FROM acr_invoice_create_tmp t,con_contract cc
WHERE t.record_id = ${/parameter/@record_id}
and cc.contract_id=t.contract_id
AND cc.business_type='LEASEBACK'
AND v.code_value IN ('PAPER_GENERAL','ELECTRONIC_GENERAL'))
]]>
</bm:query-sql>
]]>
</bm:query-sql>
</bm:operation>
</bm:operation>
</bm:operations>
</bm:operations>
...
...
src/main/webapp/modules/acr/ACR510/acr_invoice_create_invoice.lview
View file @
219d7dbe
...
@@ -43,7 +43,7 @@
...
@@ -43,7 +43,7 @@
function createScreen_create()
function createScreen_create()
{
{
debugger
;
var message_flag =false
;
var win = $('acr_invoice_create_invoice');
var win = $('acr_invoice_create_invoice');
var ds=$('headDs');
var ds=$('headDs');
if(!ds.validate(true))
if(!ds.validate(true))
...
@@ -54,6 +54,7 @@
...
@@ -54,6 +54,7 @@
//判断本次开票金额是否为租金,本金,和利息之中某一个
//判断本次开票金额是否为租金,本金,和利息之中某一个
var selectedDs=$('selectedDs').getAll();
var selectedDs=$('selectedDs').getAll();
for(var i=0;i
<selectedDs.length
;i++){
for(var i=0;i
<selectedDs.length
;i++){
debugger;
var
billing_amount=
selectedDs[i].get('billing_amount');
var
billing_amount=
selectedDs[i].get('billing_amount');
var
due_amount=
selectedDs[i].get('due_amount');
var
due_amount=
selectedDs[i].get('due_amount');
var
principal=
selectedDs[i].get('principal');
var
principal=
selectedDs[i].get('principal');
...
@@ -70,18 +71,33 @@
...
@@ -70,18 +71,33 @@
$L.showErrorMessage("提示","该金额已经开票过!");
$L.showErrorMessage("提示","该金额已经开票过!");
return;
return;
}
}
//add
by
gzj
售后回租只能开普票
var
business_type=
selectedDs[i].get('business_type');
var
kind_type=
selectedDs[i].get('invoice_kind_type');
if(
business_type=
='LEASEBACK'&&(kind_type!='PAPER_GENERAL'&&kind_type!='ELECTRONIC_GENERAL')){
Leaf.showMessage("提示","售后回租只能开普通发票!");
return;
}
if(
business_type=
='LEASEBACK'&&kind_type!='ELECTRONIC_GENERAL'){
message_flag =
true;
//
Leaf.showMessage("提示","回租建议选择增值税电子普票!");
}
if(received_amount<plus(cf_billing_amount,billing_amount)&&selectedDs[i].get('cf_item')==1&&selectedDs[i].get('cf_status')=='BLOCK'&&selectedDs[i].get('contract_status')=='REPURING'){
if(received_amount<plus(cf_billing_amount,billing_amount)&&selectedDs[i].get('cf_item')==1&&selectedDs[i].get('cf_status')=='BLOCK'&&selectedDs[i].get('contract_status')=='REPURING'){
$L.showErrorMessage("提示","本次开票金额+已开票金额不能超过已核销金额!");
$L.showErrorMessage("提示","本次开票金额+已开票金额不能超过已核销金额!");
return;
return;
}
}
}
}
var
datas =
ds.getJsonData();
var
datas =
ds.getJsonData();
Leaf.showConfirm('${l:HLS.PROMPT}','是否确认开票?',function()
var
message_info;
if(
message_flag=
=false){
message_info=
'是否确认开票?'
;
}else
{
message_info=
"回租建议选择增值税电子普票!是否确认开票?"
;
}
Leaf.showConfirm('${l:HLS.PROMPT}',message_info,function()
{
{
Leaf.Masker.mask(Ext.getBody(),'${l:HLS.EXECUTING}');
Leaf.Masker.mask(Ext.getBody(),'${l:HLS.EXECUTING}');
Leaf.request({
Leaf.request({
...
@@ -100,7 +116,8 @@
...
@@ -100,7 +116,8 @@
Leaf.Masker.unmask(Ext.getBody());
Leaf.Masker.unmask(Ext.getBody());
},
},
scope:
this
scope:
this,
sync:
true
});
});
},function
(){
},function
(){
Leaf.Masker.unmask(Ext.getBody());
Leaf.Masker.unmask(Ext.getBody());
...
@@ -109,6 +126,8 @@
...
@@ -109,6 +126,8 @@
}
}
function
unSelect_selectedDs(ds,record){
function
unSelect_selectedDs(ds,record){
record.dirty =
false;
record.dirty =
false;
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment