[Home] [Help]
251: FUNCTION fn_get_line_taxname( p_customer_trx_line_id IN number ) return varchar2 AS
252: cursor c_linetax is
253: SELECT v.tax_rate_name as printed_tax_name
254: from ra_customer_trx_lines ctl,
255: zx_rates_vl v
256: where
257: ctl.link_to_cust_trx_line_id = p_customer_trx_line_id
258: and ctl.line_type = 'TAX'
259: and ctl.vat_tax_id = v.tax_rate_id(+)
277: FUNCTION fn_get_line_taxcode( p_customer_trx_line_id IN number ) return varchar2 AS
278: cursor c_linetax is
279: SELECT v.tax_rate_code as tax_code
280: from ra_customer_trx_lines ctl,
281: zx_rates_vl v
282: where
283: ctl.link_to_cust_trx_line_id = p_customer_trx_line_id
284: and ctl.line_type = 'TAX'
285: and ctl.vat_tax_id = v.tax_rate_id(+)
359:
360: cursor c_linetax (id number) is
361: SELECT v.tax_rate_name as printed_tax_name
362: from ra_customer_trx_lines ctl,
363: zx_rates_vl v
364: where
365: ctl.link_to_cust_trx_line_id = id
366: and ctl.line_type = 'TAX'
367: and ctl.vat_tax_id = v.tax_rate_id(+)
407:
408: cursor c_linetax (id number) is
409: SELECT v.tax_rate_code as tax_code
410: from ra_customer_trx_lines ctl,
411: zx_rates_vl v
412: where
413: ctl.link_to_cust_trx_line_id = id
414: and ctl.line_type = 'TAX'
415: and ctl.vat_tax_id = v.tax_rate_id(+)
601: e varchar2(240);
602:
603: cursor tax_type_c( id in number ) is
604: select t.tax_type_code,t.compounding_precedence
605: from zx_taxes_vl t,zx_rates_vl r
606: where t.tax_regime_code = r.tax_regime_code
607: and t.tax = r.tax
608: and r.tax_rate_id = id;
609:
607: and t.tax = r.tax
608: and r.tax_rate_id = id;
609:
610: cursor vat_tax_c( id in number ) is
611: select tax_rate_code as tax_code, tax_rate_name as printed_tax_name from zx_rates_vl where tax_rate_id = id;
612:
613: cursor exem_c( id in number ) is
614: select
615: decode(nvl(product_id,-999),-999,'CUSTOMER','ITEM') as exemption_type,