Commit db21bff4 authored by 38823's avatar 38823

销项发票测试问题修复

parent 85d61209
......@@ -100,9 +100,9 @@
cf.cf_item,
(select i.description
from hls_cashflow_item i
where i.cf_item = t.cf_item) as cf_item_desc,
decode(con.division,95,'*经营租赁*'||t.due_amount||'('||to_char(cf.due_date,'MM')||')',decode(t.cf_item,250,'融资租赁挖掘机','融资租赁费')) as product_name,
decode(con.division,95,'*经营租赁*'||t.due_amount||'('||to_char(cf.due_date,'MM')||')',decode(t.cf_item,250,'融资租赁挖掘机','融资租赁费')) as product_name_desc,
where i.cf_item = cf.cf_item) as cf_item_desc,
decode(con.division,95,'*经营租赁*'||'租赁费'||'('||to_char(cf.due_date,'MM')||')',decode(t.cf_item,250,'融资租赁挖掘机','融资租赁费')) as product_name,
decode(con.division,95,'*经营租赁*'||'租赁费'||'('||to_char(cf.due_date,'MM')||')',decode(t.cf_item,250,'融资租赁挖掘机','融资租赁费')) as product_name_desc,
con.contract_status contract_status,
cf.cf_status cf_status,
t.invoice_kind_type,
......
......@@ -27,9 +27,9 @@
From con_contract c
Where c.contract_id = ah.contract_id) contract_number,
(Select c.search_term_1
from con_contract c
where c.contract_id = ah.contract_id) pur_contract_number,
(Select c.search_term_1
from con_contract c
where c.contract_id = ah.contract_id) pur_contract_number,
(Select p.project_number
from prj_project p,
......@@ -48,14 +48,14 @@
and v.code_value = cc.business_type
and cc.contract_id = ah.contract_id) business_type,
(Select hb.bp_code
From hls_bp_master hb
Where hb.bp_id = ah.bp_id) bp_code,
ah.bp_name,
nvl(cwo.times,
(Select t.times
From con_contract_cashflow t
Where t.cashflow_id = al.cashflow_id)) times,
(Select hb.bp_code
From hls_bp_master hb
Where hb.bp_id = ah.bp_id) bp_code,
ah.bp_name,
nvl(cwo.times,
(Select t.times
From con_contract_cashflow t
Where t.cashflow_id = al.cashflow_id)) times,
(Select to_char(h.journal_date, 'yyyy-mm')
From hls_journal_header h, hls_journal_detail l
......
......@@ -204,10 +204,75 @@
}
//融租开票
function acr515_invoice_post() {
var ds = $('acr515_invoiceVatDs');
var records = ds.getSelected();
if (records.length == 0) {
Leaf.showMessage('提示', '请选择要开票的数据');
return;
}
var param = {};
var saveData = [];
//var kind = $('acr515_invoiceVatParaDs').getAt(0).get('invoice_kind');
// if (kind=='0') { //如果是转票弹出 正常金税发票
// url = $('acr515_interface_excel_link').getUrl();
// } else {//否则弹出电子发票
// url = $('acr515_interface_network_link').getUrl();
// }
var invoice_apply_num0 = records[0].get('invoice_apply_num');
var detail_mask = Ext.getBody();
Leaf.Masker.mask(detail_mask, '${l:HLS.EXECUTING}');
for (var i = 0; i < records.length; i++) {
//判断金税状态,已经回传的不能再进行开票
if ('BACK' == records[i].get('vat_interface_status')) {
$L.showInfoMessage("提示", '所选择的单据中存在金税已回写状态,请检查后重试!');
Leaf.Masker.unmask(detail_mask, '${l:HLS.EXECUTING}');
return;
}
if ('TRANSFERED' == records[i].get('vat_interface_status')) {
$L.showInfoMessage("提示", '所选择的单据中存在已传金税状态,请检查后重试!');
Leaf.Masker.unmask(detail_mask, '${l:HLS.EXECUTING}');
return;
}
//不同批次的发票不能同时勾选
if (invoice_apply_num0 != records[i].get('invoice_apply_num')) {
$L.showInfoMessage("提示", '不同批次的发票不能同时勾选!');
Leaf.Masker.unmask(detail_mask, '${l:HLS.EXECUTING}');
return;
}
saveData.push({
'invoice_hd_id': records[i].get('invoice_hd_id'),
'_status': 'insert'
});
}
param['details'] = saveData;
param.invoice_apply_id = records[0].get('invoice_apply_id');
param.select_count = records.length;
Leaf.request({
url: $('acr515_update_post_link').getUrl(),
para: param,
success: function () {
Leaf.Masker.unmask(detail_mask);
var _url = $('acr515_interface_excel_link').getUrl();
window.open(_url);
ds.query();
},
failure: function () {
Leaf.Masker.unmask(detail_mask);
},
error: function () {
Leaf.Masker.unmask(detail_mask);
},
scope: this
});
}
var ds = $('acr515_invoiceVatDs');
//经租开票
function acr515_invoiceOp_post() {
debugger;
var ds = $('acr515_invoiceVatOpDs');
var records = ds.getSelected();
if (records.length == 0) {
Leaf.showMessage('提示', '请选择要开票的数据');
......@@ -361,7 +426,7 @@
<a:datas dataSource="/model/acr515_currency_list"/>
</a:dataSet>
<a:dataSet id="acr515_invoiceVatParaDs" autoCreate="true" model="acr.ACR515.acr515_invoice_hd_v">
<a:dataSet id="acr515_invoiceVatParaDs" autoCreate="true" model="acr.ACR515.acr515_invoice_hd_all_v">
<a:fields>
<a:field name="currency_desc" displayField="currency_name" options="acr515_currencyDs"
returnField="currency" valueField="currency_code"/>
......@@ -527,7 +592,8 @@
<a:textField name="invoice_apply_num" bindTarget="acr515_invoiceVatParaDs" prompt="申请编号"
width="120"/>
<a:comboBox name="full_elec_invoice_flag_n" bindTarget="acr515_invoiceVatParaDs" width="150" prompt="是否全电发票"/>
<a:textField name="search_term_1" bindTarget="acr515_invoiceVatParaDs" width="150" prompt="厂商合同编号"/>
<a:textField name="pur_number" bindTarget="acr515_invoiceVatParaDs" width="150" prompt="采购单编号"/>
</a:hBox>
</a:form>
<a:tabPanel id="acr515_invoice_vat_id" marginHeight="160" marginWidth="10">
......@@ -573,7 +639,7 @@
</a:grid>
</a:tab>
<a:tab prompt="经营租赁" width="150">
<a:grid id="acr515_invoiceVatOpDs_grid" bindTarget="acr515_invoiceVatDs" marginWidth="30" navBar="true"
<a:grid id="acr515_invoiceVatOpDs_grid" bindTarget="acr515_invoiceVatOpDs" marginWidth="30" navBar="true"
marginHeight="200">
<a:columns>
<a:column name="document_number" lock="true" width="120" renderer="acr512_document_number_render"/>
......
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