DBA Data[Home] [Help]

APPS.AP_WEB_EXPENSE_WF dependencies on AP_WEB_DB_EXPRPT_PKG

Line 307: l_ResubmitReport := AP_WEB_DB_EXPRPT_PKG.ResubmitExpenseReport(

303: p_employee_id,
304: FND_PROFILE.VALUE('USER_ID'),
305: l_employee_project_enabled);
306:
307: l_ResubmitReport := AP_WEB_DB_EXPRPT_PKG.ResubmitExpenseReport(
308: p_workflow_flag);
309:
310: -- Grants Integration
311: IF (GMS_OIE_INT_PKG.IsGrantsEnabled()) THEN

Line 464: if p_workflow_flag = AP_WEB_DB_EXPRPT_PKG.C_WORKFLOW_APPROVED_WITHDRAW then

460: -------------------------------------------------
461: l_debug_info := 'Update Withdraw Message';
462: -------------------------------------------------
463: --ER 1552747 - withdraw expense report
464: if p_workflow_flag = AP_WEB_DB_EXPRPT_PKG.C_WORKFLOW_APPROVED_WITHDRAW then
465: FND_MESSAGE.SET_NAME('SQLAP','OIE_WITHDRAW_WARNING');
466: l_mess := FND_MESSAGE.GET;
467: WF_ENGINE.SetItemAttrText(l_item_type,
468: l_item_key,

Line 595: IF (NOT AP_WEB_DB_EXPRPT_PKG.getPaymentDueFromReport(p_report_header_id,l_textValArr(iText))) THEN

591: --------------------------------------------------------------
592: iText := iText + 1;
593: l_textNameArr(iText) := 'PAYMENT_DUE_FROM';
594:
595: IF (NOT AP_WEB_DB_EXPRPT_PKG.getPaymentDueFromReport(p_report_header_id,l_textValArr(iText))) THEN
596: l_debug_info := 'Could not set workflow attribute Payment_Due_From';
597: END IF;
598:
599: -------------------------------------------------------------

Line 844: AP_WEB_DB_EXPRPT_PKG.clearAuditReturnReasonInstr(p_report_header_id);

840:
841: ------------------------------------------------------------
842: l_debug_info := 'clear the header/line level return/audit reason/instructions in AERH/AERL';
843: ------------------------------------------------------------
844: AP_WEB_DB_EXPRPT_PKG.clearAuditReturnReasonInstr(p_report_header_id);
845: AP_WEB_DB_EXPLINE_PKG.clearAuditReturnReasonInstr(p_report_header_id);
846:
847: ----------------------------------------------------------
848: l_debug_info := 'clear Item Attribute AUDIT_RETURN_REASON';

Line 936: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;

932: l_item_type VARCHAR2(7);
933: l_item_key VARCHAR2(15);
934:
935: l_currency VARCHAR2(50);
936: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
937: l_num_lines NUMBER := 0;
938:
939: l_n_org_id Number;
940:

Line 1196: IF (AP_WEB_DB_EXPRPT_PKG.GetOrgIdByReportHeaderId(

1192: when others then
1193: if (wf_core.error_name = 'WFENG_ITEM_ATTR') then
1194: -- ORG_ID item attribute doesn't exist, need to add it
1195: WF_ENGINE.AddItemAttr(l_item_type, l_item_key, 'ORG_ID');
1196: IF (AP_WEB_DB_EXPRPT_PKG.GetOrgIdByReportHeaderId(
1197: to_number(l_item_key),
1198: l_n_org_id) <> TRUE ) THEN
1199: l_n_org_id := NULL;
1200: END IF;

Line 1222: IF (AP_WEB_DB_EXPRPT_PKG.GetOrgIdByReportHeaderId(to_number(l_item_key), l_n_org_id) <> TRUE ) THEN

1218: else
1219: -- Report was submitted before org_id being added, hence org_id
1220: -- item attributes hasn't been set yet. Need to get it from
1221: -- report header
1222: IF (AP_WEB_DB_EXPRPT_PKG.GetOrgIdByReportHeaderId(to_number(l_item_key), l_n_org_id) <> TRUE ) THEN
1223: l_n_org_id := NULL;
1224: END IF;
1225:
1226: IF (l_n_org_id is not null) then

Line 1532: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;

1528: p_actid IN NUMBER,
1529: p_funmode IN VARCHAR2,
1530: p_result OUT NOCOPY VARCHAR2) IS
1531: ------------------------------------------------------------------------
1532: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
1533:
1534: l_emp_cost_center VARCHAR2(240);
1535: l_doc_cost_center VARCHAR2(240);
1536:

Line 1875: l_default_currency_code AP_WEB_DB_EXPRPT_PKG.expHdr_defaultCurrCode;

1871: l_sys_allow_awt_flag AP_WEB_DB_AP_INT_PKG.apSetUp_allowAwtFlag;
1872: l_sys_default_xrate_type AP_WEB_DB_AP_INT_PKG.apSetUp_defaultExchRateType;
1873: l_sys_make_rate_mandatory AP_WEB_DB_AP_INT_PKG.apSetUp_makeMandatoryFlag;
1874: l_chart_of_accounts_id AP_WEB_DB_AP_INT_PKG.glsob_chartOfAccountsID;
1875: l_default_currency_code AP_WEB_DB_EXPRPT_PKG.expHdr_defaultCurrCode;
1876: l_week_end_date AP_WEB_DB_EXPRPT_PKG.expHdr_weekEndDate;
1877: l_exp_check_address_flag AP_WEB_DB_HR_INT_PKG.empCurrent_checkAddrFlag;
1878: l_ven_allow_awt_flag AP_WEB_DB_AP_INT_PKG.vendors_allowAWTFlag;
1879: l_ven_awt_group_id AP_WEB_DB_AP_INT_PKG.vendors_awtGroupID;

Line 1876: l_week_end_date AP_WEB_DB_EXPRPT_PKG.expHdr_weekEndDate;

1872: l_sys_default_xrate_type AP_WEB_DB_AP_INT_PKG.apSetUp_defaultExchRateType;
1873: l_sys_make_rate_mandatory AP_WEB_DB_AP_INT_PKG.apSetUp_makeMandatoryFlag;
1874: l_chart_of_accounts_id AP_WEB_DB_AP_INT_PKG.glsob_chartOfAccountsID;
1875: l_default_currency_code AP_WEB_DB_EXPRPT_PKG.expHdr_defaultCurrCode;
1876: l_week_end_date AP_WEB_DB_EXPRPT_PKG.expHdr_weekEndDate;
1877: l_exp_check_address_flag AP_WEB_DB_HR_INT_PKG.empCurrent_checkAddrFlag;
1878: l_ven_allow_awt_flag AP_WEB_DB_AP_INT_PKG.vendors_allowAWTFlag;
1879: l_ven_awt_group_id AP_WEB_DB_AP_INT_PKG.vendors_awtGroupID;
1880: l_default_emp_ccid AP_WEB_DB_HR_INT_PKG.empCurrent_defaultCodeCombID;

Line 1885: l_employee_ccid AP_WEB_DB_EXPRPT_PKG.expHdr_employeeCCID;

1881: l_default_emp_segments AP_OIE_KFF_SEGMENTS_T;
1882: l_exp_dist_ccid AP_WEB_DB_EXPLINE_PKG.expLines_codeCombID;
1883: l_id_flex_structure_name fnd_id_flex_structures_vl.id_flex_structure_name%TYPE;
1884:
1885: l_employee_ccid AP_WEB_DB_EXPRPT_PKG.expHdr_employeeCCID;
1886: l_employee_id AP_WEB_DB_EXPRPT_PKG.expHdr_employeeID;
1887: l_personalParameterId AP_WEB_DB_EXPTEMPLATE_PKG.expTempl_paramID;
1888: l_category AP_WEB_DB_CCARD_PKG.ccTrxn_category;
1889: l_default_exchange_rate AP_WEB_DB_EXPRPT_PKG.expHdr_defaultExchRate;

Line 1886: l_employee_id AP_WEB_DB_EXPRPT_PKG.expHdr_employeeID;

1882: l_exp_dist_ccid AP_WEB_DB_EXPLINE_PKG.expLines_codeCombID;
1883: l_id_flex_structure_name fnd_id_flex_structures_vl.id_flex_structure_name%TYPE;
1884:
1885: l_employee_ccid AP_WEB_DB_EXPRPT_PKG.expHdr_employeeCCID;
1886: l_employee_id AP_WEB_DB_EXPRPT_PKG.expHdr_employeeID;
1887: l_personalParameterId AP_WEB_DB_EXPTEMPLATE_PKG.expTempl_paramID;
1888: l_category AP_WEB_DB_CCARD_PKG.ccTrxn_category;
1889: l_default_exchange_rate AP_WEB_DB_EXPRPT_PKG.expHdr_defaultExchRate;
1890: l_base_currency_code AP_WEB_DB_AP_INT_PKG.apSetUp_baseCurrencyCode;

Line 1889: l_default_exchange_rate AP_WEB_DB_EXPRPT_PKG.expHdr_defaultExchRate;

1885: l_employee_ccid AP_WEB_DB_EXPRPT_PKG.expHdr_employeeCCID;
1886: l_employee_id AP_WEB_DB_EXPRPT_PKG.expHdr_employeeID;
1887: l_personalParameterId AP_WEB_DB_EXPTEMPLATE_PKG.expTempl_paramID;
1888: l_category AP_WEB_DB_CCARD_PKG.ccTrxn_category;
1889: l_default_exchange_rate AP_WEB_DB_EXPRPT_PKG.expHdr_defaultExchRate;
1890: l_base_currency_code AP_WEB_DB_AP_INT_PKG.apSetUp_baseCurrencyCode;
1891: l_sys_base_currency_code AP_WEB_DB_AP_INT_PKG.apSetUp_baseCurrencyCode;
1892: exchange_rate_exception EXCEPTION;
1893: l_available_prepays NUMBER;

Line 1923: V_EmployeeID AP_WEB_DB_EXPRPT_PKG.expHdr_employeeID;

1919: V_UserName VARCHAR2(30);
1920: V_VendorID AP_WEB_DB_AP_INT_PKG.vendors_vendorID;
1921: V_IsSessionProjectEnabled VARCHAR2(1);
1922:
1923: V_EmployeeID AP_WEB_DB_EXPRPT_PKG.expHdr_employeeID;
1924: l_cost_center AP_WEB_DB_EXPRPT_PKG.expHdr_flexConcat;
1925: V_HeaderAttributeCategory AP_WEB_DB_EXPRPT_PKG.expHdr_attrCategory;
1926: V_HeaderAttribute1 AP_WEB_DB_EXPRPT_PKG.expHdr_attr1;
1927: V_HeaderAttribute2 AP_WEB_DB_EXPRPT_PKG.expHdr_attr2;

Line 1924: l_cost_center AP_WEB_DB_EXPRPT_PKG.expHdr_flexConcat;

1920: V_VendorID AP_WEB_DB_AP_INT_PKG.vendors_vendorID;
1921: V_IsSessionProjectEnabled VARCHAR2(1);
1922:
1923: V_EmployeeID AP_WEB_DB_EXPRPT_PKG.expHdr_employeeID;
1924: l_cost_center AP_WEB_DB_EXPRPT_PKG.expHdr_flexConcat;
1925: V_HeaderAttributeCategory AP_WEB_DB_EXPRPT_PKG.expHdr_attrCategory;
1926: V_HeaderAttribute1 AP_WEB_DB_EXPRPT_PKG.expHdr_attr1;
1927: V_HeaderAttribute2 AP_WEB_DB_EXPRPT_PKG.expHdr_attr2;
1928: V_HeaderAttribute3 AP_WEB_DB_EXPRPT_PKG.expHdr_attr3;

Line 1925: V_HeaderAttributeCategory AP_WEB_DB_EXPRPT_PKG.expHdr_attrCategory;

1921: V_IsSessionProjectEnabled VARCHAR2(1);
1922:
1923: V_EmployeeID AP_WEB_DB_EXPRPT_PKG.expHdr_employeeID;
1924: l_cost_center AP_WEB_DB_EXPRPT_PKG.expHdr_flexConcat;
1925: V_HeaderAttributeCategory AP_WEB_DB_EXPRPT_PKG.expHdr_attrCategory;
1926: V_HeaderAttribute1 AP_WEB_DB_EXPRPT_PKG.expHdr_attr1;
1927: V_HeaderAttribute2 AP_WEB_DB_EXPRPT_PKG.expHdr_attr2;
1928: V_HeaderAttribute3 AP_WEB_DB_EXPRPT_PKG.expHdr_attr3;
1929: V_HeaderAttribute4 AP_WEB_DB_EXPRPT_PKG.expHdr_attr4;

Line 1926: V_HeaderAttribute1 AP_WEB_DB_EXPRPT_PKG.expHdr_attr1;

1922:
1923: V_EmployeeID AP_WEB_DB_EXPRPT_PKG.expHdr_employeeID;
1924: l_cost_center AP_WEB_DB_EXPRPT_PKG.expHdr_flexConcat;
1925: V_HeaderAttributeCategory AP_WEB_DB_EXPRPT_PKG.expHdr_attrCategory;
1926: V_HeaderAttribute1 AP_WEB_DB_EXPRPT_PKG.expHdr_attr1;
1927: V_HeaderAttribute2 AP_WEB_DB_EXPRPT_PKG.expHdr_attr2;
1928: V_HeaderAttribute3 AP_WEB_DB_EXPRPT_PKG.expHdr_attr3;
1929: V_HeaderAttribute4 AP_WEB_DB_EXPRPT_PKG.expHdr_attr4;
1930: V_HeaderAttribute5 AP_WEB_DB_EXPRPT_PKG.expHdr_attr5;

Line 1927: V_HeaderAttribute2 AP_WEB_DB_EXPRPT_PKG.expHdr_attr2;

1923: V_EmployeeID AP_WEB_DB_EXPRPT_PKG.expHdr_employeeID;
1924: l_cost_center AP_WEB_DB_EXPRPT_PKG.expHdr_flexConcat;
1925: V_HeaderAttributeCategory AP_WEB_DB_EXPRPT_PKG.expHdr_attrCategory;
1926: V_HeaderAttribute1 AP_WEB_DB_EXPRPT_PKG.expHdr_attr1;
1927: V_HeaderAttribute2 AP_WEB_DB_EXPRPT_PKG.expHdr_attr2;
1928: V_HeaderAttribute3 AP_WEB_DB_EXPRPT_PKG.expHdr_attr3;
1929: V_HeaderAttribute4 AP_WEB_DB_EXPRPT_PKG.expHdr_attr4;
1930: V_HeaderAttribute5 AP_WEB_DB_EXPRPT_PKG.expHdr_attr5;
1931: V_HeaderAttribute6 AP_WEB_DB_EXPRPT_PKG.expHdr_attr6;

Line 1928: V_HeaderAttribute3 AP_WEB_DB_EXPRPT_PKG.expHdr_attr3;

1924: l_cost_center AP_WEB_DB_EXPRPT_PKG.expHdr_flexConcat;
1925: V_HeaderAttributeCategory AP_WEB_DB_EXPRPT_PKG.expHdr_attrCategory;
1926: V_HeaderAttribute1 AP_WEB_DB_EXPRPT_PKG.expHdr_attr1;
1927: V_HeaderAttribute2 AP_WEB_DB_EXPRPT_PKG.expHdr_attr2;
1928: V_HeaderAttribute3 AP_WEB_DB_EXPRPT_PKG.expHdr_attr3;
1929: V_HeaderAttribute4 AP_WEB_DB_EXPRPT_PKG.expHdr_attr4;
1930: V_HeaderAttribute5 AP_WEB_DB_EXPRPT_PKG.expHdr_attr5;
1931: V_HeaderAttribute6 AP_WEB_DB_EXPRPT_PKG.expHdr_attr6;
1932: V_HeaderAttribute7 AP_WEB_DB_EXPRPT_PKG.expHdr_attr7;

Line 1929: V_HeaderAttribute4 AP_WEB_DB_EXPRPT_PKG.expHdr_attr4;

1925: V_HeaderAttributeCategory AP_WEB_DB_EXPRPT_PKG.expHdr_attrCategory;
1926: V_HeaderAttribute1 AP_WEB_DB_EXPRPT_PKG.expHdr_attr1;
1927: V_HeaderAttribute2 AP_WEB_DB_EXPRPT_PKG.expHdr_attr2;
1928: V_HeaderAttribute3 AP_WEB_DB_EXPRPT_PKG.expHdr_attr3;
1929: V_HeaderAttribute4 AP_WEB_DB_EXPRPT_PKG.expHdr_attr4;
1930: V_HeaderAttribute5 AP_WEB_DB_EXPRPT_PKG.expHdr_attr5;
1931: V_HeaderAttribute6 AP_WEB_DB_EXPRPT_PKG.expHdr_attr6;
1932: V_HeaderAttribute7 AP_WEB_DB_EXPRPT_PKG.expHdr_attr7;
1933: V_HeaderAttribute8 AP_WEB_DB_EXPRPT_PKG.expHdr_attr8;

Line 1930: V_HeaderAttribute5 AP_WEB_DB_EXPRPT_PKG.expHdr_attr5;

1926: V_HeaderAttribute1 AP_WEB_DB_EXPRPT_PKG.expHdr_attr1;
1927: V_HeaderAttribute2 AP_WEB_DB_EXPRPT_PKG.expHdr_attr2;
1928: V_HeaderAttribute3 AP_WEB_DB_EXPRPT_PKG.expHdr_attr3;
1929: V_HeaderAttribute4 AP_WEB_DB_EXPRPT_PKG.expHdr_attr4;
1930: V_HeaderAttribute5 AP_WEB_DB_EXPRPT_PKG.expHdr_attr5;
1931: V_HeaderAttribute6 AP_WEB_DB_EXPRPT_PKG.expHdr_attr6;
1932: V_HeaderAttribute7 AP_WEB_DB_EXPRPT_PKG.expHdr_attr7;
1933: V_HeaderAttribute8 AP_WEB_DB_EXPRPT_PKG.expHdr_attr8;
1934: V_HeaderAttribute9 AP_WEB_DB_EXPRPT_PKG.expHdr_attr9;

Line 1931: V_HeaderAttribute6 AP_WEB_DB_EXPRPT_PKG.expHdr_attr6;

1927: V_HeaderAttribute2 AP_WEB_DB_EXPRPT_PKG.expHdr_attr2;
1928: V_HeaderAttribute3 AP_WEB_DB_EXPRPT_PKG.expHdr_attr3;
1929: V_HeaderAttribute4 AP_WEB_DB_EXPRPT_PKG.expHdr_attr4;
1930: V_HeaderAttribute5 AP_WEB_DB_EXPRPT_PKG.expHdr_attr5;
1931: V_HeaderAttribute6 AP_WEB_DB_EXPRPT_PKG.expHdr_attr6;
1932: V_HeaderAttribute7 AP_WEB_DB_EXPRPT_PKG.expHdr_attr7;
1933: V_HeaderAttribute8 AP_WEB_DB_EXPRPT_PKG.expHdr_attr8;
1934: V_HeaderAttribute9 AP_WEB_DB_EXPRPT_PKG.expHdr_attr9;
1935: V_HeaderAttribute10 AP_WEB_DB_EXPRPT_PKG.expHdr_attr10;

Line 1932: V_HeaderAttribute7 AP_WEB_DB_EXPRPT_PKG.expHdr_attr7;

1928: V_HeaderAttribute3 AP_WEB_DB_EXPRPT_PKG.expHdr_attr3;
1929: V_HeaderAttribute4 AP_WEB_DB_EXPRPT_PKG.expHdr_attr4;
1930: V_HeaderAttribute5 AP_WEB_DB_EXPRPT_PKG.expHdr_attr5;
1931: V_HeaderAttribute6 AP_WEB_DB_EXPRPT_PKG.expHdr_attr6;
1932: V_HeaderAttribute7 AP_WEB_DB_EXPRPT_PKG.expHdr_attr7;
1933: V_HeaderAttribute8 AP_WEB_DB_EXPRPT_PKG.expHdr_attr8;
1934: V_HeaderAttribute9 AP_WEB_DB_EXPRPT_PKG.expHdr_attr9;
1935: V_HeaderAttribute10 AP_WEB_DB_EXPRPT_PKG.expHdr_attr10;
1936: V_HeaderAttribute11 AP_WEB_DB_EXPRPT_PKG.expHdr_attr11;

Line 1933: V_HeaderAttribute8 AP_WEB_DB_EXPRPT_PKG.expHdr_attr8;

1929: V_HeaderAttribute4 AP_WEB_DB_EXPRPT_PKG.expHdr_attr4;
1930: V_HeaderAttribute5 AP_WEB_DB_EXPRPT_PKG.expHdr_attr5;
1931: V_HeaderAttribute6 AP_WEB_DB_EXPRPT_PKG.expHdr_attr6;
1932: V_HeaderAttribute7 AP_WEB_DB_EXPRPT_PKG.expHdr_attr7;
1933: V_HeaderAttribute8 AP_WEB_DB_EXPRPT_PKG.expHdr_attr8;
1934: V_HeaderAttribute9 AP_WEB_DB_EXPRPT_PKG.expHdr_attr9;
1935: V_HeaderAttribute10 AP_WEB_DB_EXPRPT_PKG.expHdr_attr10;
1936: V_HeaderAttribute11 AP_WEB_DB_EXPRPT_PKG.expHdr_attr11;
1937: V_HeaderAttribute12 AP_WEB_DB_EXPRPT_PKG.expHdr_attr12;

Line 1934: V_HeaderAttribute9 AP_WEB_DB_EXPRPT_PKG.expHdr_attr9;

1930: V_HeaderAttribute5 AP_WEB_DB_EXPRPT_PKG.expHdr_attr5;
1931: V_HeaderAttribute6 AP_WEB_DB_EXPRPT_PKG.expHdr_attr6;
1932: V_HeaderAttribute7 AP_WEB_DB_EXPRPT_PKG.expHdr_attr7;
1933: V_HeaderAttribute8 AP_WEB_DB_EXPRPT_PKG.expHdr_attr8;
1934: V_HeaderAttribute9 AP_WEB_DB_EXPRPT_PKG.expHdr_attr9;
1935: V_HeaderAttribute10 AP_WEB_DB_EXPRPT_PKG.expHdr_attr10;
1936: V_HeaderAttribute11 AP_WEB_DB_EXPRPT_PKG.expHdr_attr11;
1937: V_HeaderAttribute12 AP_WEB_DB_EXPRPT_PKG.expHdr_attr12;
1938: V_HeaderAttribute13 AP_WEB_DB_EXPRPT_PKG.expHdr_attr13;

Line 1935: V_HeaderAttribute10 AP_WEB_DB_EXPRPT_PKG.expHdr_attr10;

1931: V_HeaderAttribute6 AP_WEB_DB_EXPRPT_PKG.expHdr_attr6;
1932: V_HeaderAttribute7 AP_WEB_DB_EXPRPT_PKG.expHdr_attr7;
1933: V_HeaderAttribute8 AP_WEB_DB_EXPRPT_PKG.expHdr_attr8;
1934: V_HeaderAttribute9 AP_WEB_DB_EXPRPT_PKG.expHdr_attr9;
1935: V_HeaderAttribute10 AP_WEB_DB_EXPRPT_PKG.expHdr_attr10;
1936: V_HeaderAttribute11 AP_WEB_DB_EXPRPT_PKG.expHdr_attr11;
1937: V_HeaderAttribute12 AP_WEB_DB_EXPRPT_PKG.expHdr_attr12;
1938: V_HeaderAttribute13 AP_WEB_DB_EXPRPT_PKG.expHdr_attr13;
1939: V_HeaderAttribute14 AP_WEB_DB_EXPRPT_PKG.expHdr_attr14;

Line 1936: V_HeaderAttribute11 AP_WEB_DB_EXPRPT_PKG.expHdr_attr11;

1932: V_HeaderAttribute7 AP_WEB_DB_EXPRPT_PKG.expHdr_attr7;
1933: V_HeaderAttribute8 AP_WEB_DB_EXPRPT_PKG.expHdr_attr8;
1934: V_HeaderAttribute9 AP_WEB_DB_EXPRPT_PKG.expHdr_attr9;
1935: V_HeaderAttribute10 AP_WEB_DB_EXPRPT_PKG.expHdr_attr10;
1936: V_HeaderAttribute11 AP_WEB_DB_EXPRPT_PKG.expHdr_attr11;
1937: V_HeaderAttribute12 AP_WEB_DB_EXPRPT_PKG.expHdr_attr12;
1938: V_HeaderAttribute13 AP_WEB_DB_EXPRPT_PKG.expHdr_attr13;
1939: V_HeaderAttribute14 AP_WEB_DB_EXPRPT_PKG.expHdr_attr14;
1940: V_HeaderAttribute15 AP_WEB_DB_EXPRPT_PKG.expHdr_attr15;

Line 1937: V_HeaderAttribute12 AP_WEB_DB_EXPRPT_PKG.expHdr_attr12;

1933: V_HeaderAttribute8 AP_WEB_DB_EXPRPT_PKG.expHdr_attr8;
1934: V_HeaderAttribute9 AP_WEB_DB_EXPRPT_PKG.expHdr_attr9;
1935: V_HeaderAttribute10 AP_WEB_DB_EXPRPT_PKG.expHdr_attr10;
1936: V_HeaderAttribute11 AP_WEB_DB_EXPRPT_PKG.expHdr_attr11;
1937: V_HeaderAttribute12 AP_WEB_DB_EXPRPT_PKG.expHdr_attr12;
1938: V_HeaderAttribute13 AP_WEB_DB_EXPRPT_PKG.expHdr_attr13;
1939: V_HeaderAttribute14 AP_WEB_DB_EXPRPT_PKG.expHdr_attr14;
1940: V_HeaderAttribute15 AP_WEB_DB_EXPRPT_PKG.expHdr_attr15;
1941:

Line 1938: V_HeaderAttribute13 AP_WEB_DB_EXPRPT_PKG.expHdr_attr13;

1934: V_HeaderAttribute9 AP_WEB_DB_EXPRPT_PKG.expHdr_attr9;
1935: V_HeaderAttribute10 AP_WEB_DB_EXPRPT_PKG.expHdr_attr10;
1936: V_HeaderAttribute11 AP_WEB_DB_EXPRPT_PKG.expHdr_attr11;
1937: V_HeaderAttribute12 AP_WEB_DB_EXPRPT_PKG.expHdr_attr12;
1938: V_HeaderAttribute13 AP_WEB_DB_EXPRPT_PKG.expHdr_attr13;
1939: V_HeaderAttribute14 AP_WEB_DB_EXPRPT_PKG.expHdr_attr14;
1940: V_HeaderAttribute15 AP_WEB_DB_EXPRPT_PKG.expHdr_attr15;
1941:
1942: ExpenseReportLinesCursor AP_WEB_DB_EXPLINE_PKG.XpenseLineAcctCursor;

Line 1939: V_HeaderAttribute14 AP_WEB_DB_EXPRPT_PKG.expHdr_attr14;

1935: V_HeaderAttribute10 AP_WEB_DB_EXPRPT_PKG.expHdr_attr10;
1936: V_HeaderAttribute11 AP_WEB_DB_EXPRPT_PKG.expHdr_attr11;
1937: V_HeaderAttribute12 AP_WEB_DB_EXPRPT_PKG.expHdr_attr12;
1938: V_HeaderAttribute13 AP_WEB_DB_EXPRPT_PKG.expHdr_attr13;
1939: V_HeaderAttribute14 AP_WEB_DB_EXPRPT_PKG.expHdr_attr14;
1940: V_HeaderAttribute15 AP_WEB_DB_EXPRPT_PKG.expHdr_attr15;
1941:
1942: ExpenseReportLinesCursor AP_WEB_DB_EXPLINE_PKG.XpenseLineAcctCursor;
1943: l_dist_line_number AP_WEB_DB_EXPLINE_PKG.expLines_distLineNum;

Line 1940: V_HeaderAttribute15 AP_WEB_DB_EXPRPT_PKG.expHdr_attr15;

1936: V_HeaderAttribute11 AP_WEB_DB_EXPRPT_PKG.expHdr_attr11;
1937: V_HeaderAttribute12 AP_WEB_DB_EXPRPT_PKG.expHdr_attr12;
1938: V_HeaderAttribute13 AP_WEB_DB_EXPRPT_PKG.expHdr_attr13;
1939: V_HeaderAttribute14 AP_WEB_DB_EXPRPT_PKG.expHdr_attr14;
1940: V_HeaderAttribute15 AP_WEB_DB_EXPRPT_PKG.expHdr_attr15;
1941:
1942: ExpenseReportLinesCursor AP_WEB_DB_EXPLINE_PKG.XpenseLineAcctCursor;
1943: l_dist_line_number AP_WEB_DB_EXPLINE_PKG.expLines_distLineNum;
1944: l_report_distribution_id AP_WEB_DB_EXPDIST_PKG.expDist_REPORT_DISTRIBUTION_ID;

Line 2025: IF (NOT AP_WEB_DB_EXPRPT_PKG.GetAccountingInfo(

2021:
2022: --------------------------------------------------------------------
2023: l_debug_info := 'Retrieve values from system parameters, employees';
2024: --------------------------------------------------------------------
2025: IF (NOT AP_WEB_DB_EXPRPT_PKG.GetAccountingInfo(
2026: p_report_header_id,
2027: l_sys_apply_advances_default,
2028: l_sys_allow_awt_flag,
2029: l_sys_default_xrate_type,

Line 2060: IF (NOT AP_WEB_DB_EXPRPT_PKG.GetChartOfAccountsID(

2056:
2057: -----------------------------------------------------
2058: l_debug_info := 'Get the Employee Chart of Accounts ID';
2059: -----------------------------------------------------
2060: IF (NOT AP_WEB_DB_EXPRPT_PKG.GetChartOfAccountsID(
2061: p_employee_id => l_employee_id,
2062: p_chart_of_accounts_id => l_chart_of_accounts_id)) THEN
2063: NULL;
2064: END IF;

Line 2573: IF (NOT AP_WEB_DB_EXPRPT_PKG.SetDefaultExchRateType(p_report_header_id, l_sys_default_xrate_type)) THEN

2569: ----------------------------------------------
2570: IF ((l_sys_default_xrate_type = 'User') AND
2571: (l_sys_make_rate_mandatory = 'Y')) THEN
2572:
2573: IF (NOT AP_WEB_DB_EXPRPT_PKG.SetDefaultExchRateType(p_report_header_id, l_sys_default_xrate_type)) THEN
2574: NULL;
2575: END IF; /* SetDefaultExchRateType */
2576:
2577: FND_MESSAGE.SET_NAME('SQLAP','AP_WEB_USER_EXCH_RATE_REQD');

Line 2621: IF (NOT AP_WEB_DB_EXPRPT_PKG.SetExpenseHeaderInfo(p_report_header_id,

2617:
2618: ---------------------------------------------------
2619: l_debug_info := 'Update ap_expense_report_headers';
2620: ---------------------------------------------------
2621: IF (NOT AP_WEB_DB_EXPRPT_PKG.SetExpenseHeaderInfo(p_report_header_id,
2622: l_exp_check_address_flag,
2623: 'WebExpense',
2624: '', -- clear out potentially-rejected/returned status
2625: l_sys_apply_advances_default,

Line 2842: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;

2838: p_actid IN NUMBER,
2839: p_funmode IN VARCHAR2,
2840: p_result OUT NOCOPY VARCHAR2) IS
2841: ----------------------------------------------------------------------
2842: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
2843: l_debug_info VARCHAR2(200);
2844: BEGIN
2845:
2846: AP_WEB_UTILITIES_PKG.logProcedure('AP_WEB_EXPENSE_WF', 'start ManagerApproved');

Line 2861: IF (NOT AP_WEB_DB_EXPRPT_PKG.SetWkflApprvdFlag(l_report_header_id)) THEN

2857:
2858: ----------------------------------------------------------------
2859: l_debug_info := 'Update the Expense Report as Manager Approved';
2860: ----------------------------------------------------------------
2861: IF (NOT AP_WEB_DB_EXPRPT_PKG.SetWkflApprvdFlag(l_report_header_id)) THEN
2862: NULL;
2863: END IF;
2864:
2865: ----------------------------------------------------------

Line 3340: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;

3336: p_actid IN NUMBER,
3337: p_funmode IN VARCHAR2,
3338: p_result OUT NOCOPY VARCHAR2) IS
3339: ----------------------------------------------------------------------
3340: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
3341: l_ap_review_status AP_WEB_DB_EXPRPT_PKG.expHdr_wkflApprvdFlag;
3342: l_debug_info VARCHAR2(200);
3343:
3344: l_WorkflowRec AP_WEB_DB_EXPRPT_PKG.ExpWorkflowRec;

Line 3341: l_ap_review_status AP_WEB_DB_EXPRPT_PKG.expHdr_wkflApprvdFlag;

3337: p_funmode IN VARCHAR2,
3338: p_result OUT NOCOPY VARCHAR2) IS
3339: ----------------------------------------------------------------------
3340: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
3341: l_ap_review_status AP_WEB_DB_EXPRPT_PKG.expHdr_wkflApprvdFlag;
3342: l_debug_info VARCHAR2(200);
3343:
3344: l_WorkflowRec AP_WEB_DB_EXPRPT_PKG.ExpWorkflowRec;
3345: C_WF_Version NUMBER := 0;

Line 3344: l_WorkflowRec AP_WEB_DB_EXPRPT_PKG.ExpWorkflowRec;

3340: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
3341: l_ap_review_status AP_WEB_DB_EXPRPT_PKG.expHdr_wkflApprvdFlag;
3342: l_debug_info VARCHAR2(200);
3343:
3344: l_WorkflowRec AP_WEB_DB_EXPRPT_PKG.ExpWorkflowRec;
3345: C_WF_Version NUMBER := 0;
3346: BEGIN
3347:
3348: AP_WEB_UTILITIES_PKG.logProcedure('AP_WEB_EXPENSE_WF', 'start APReviewComplete');

Line 3386: IF (AP_WEB_DB_EXPRPT_PKG.GetExpWorkflowInfo(l_report_header_id,

3382:
3383: -------------------------------------------------
3384: l_debug_info := 'Retrieve The AP Reviewed Flag';
3385: -------------------------------------------------
3386: IF (AP_WEB_DB_EXPRPT_PKG.GetExpWorkflowInfo(l_report_header_id,
3387: l_WorkflowRec)) THEN
3388: l_ap_review_status := nvl(l_WorkflowRec.workflow_flag, 'N');
3389: END IF;
3390:

Line 3396: l_ap_review_status = AP_WEB_DB_EXPRPT_PKG.C_WORKFLOW_APPROVED_REJECTED or -- already AP rejected

3392: l_debug_info := 'Check flag to determine if AP Review Complete and
3393: return Y if so, otherwise N';
3394: ------------------------------------------------------------------
3395: IF (l_ap_review_status = 'Y' or
3396: l_ap_review_status = AP_WEB_DB_EXPRPT_PKG.C_WORKFLOW_APPROVED_REJECTED or -- already AP rejected
3397: l_ap_review_status = AP_WEB_DB_EXPRPT_PKG.C_WORKFLOW_APPROVED_REQUEST) THEN -- already AP requests more info
3398: -- p_result := wf_engine.eng_null;
3399: -- dtong changed p_result for bug # 839208
3400: p_result := 'COMPLETE:Y';

Line 3397: l_ap_review_status = AP_WEB_DB_EXPRPT_PKG.C_WORKFLOW_APPROVED_REQUEST) THEN -- already AP requests more info

3393: return Y if so, otherwise N';
3394: ------------------------------------------------------------------
3395: IF (l_ap_review_status = 'Y' or
3396: l_ap_review_status = AP_WEB_DB_EXPRPT_PKG.C_WORKFLOW_APPROVED_REJECTED or -- already AP rejected
3397: l_ap_review_status = AP_WEB_DB_EXPRPT_PKG.C_WORKFLOW_APPROVED_REQUEST) THEN -- already AP requests more info
3398: -- p_result := wf_engine.eng_null;
3399: -- dtong changed p_result for bug # 839208
3400: p_result := 'COMPLETE:Y';
3401: ELSE

Line 3462: l_exp_report_amount AP_WEB_DB_EXPRPT_PKG.expHdr_total;

3458: p_result OUT NOCOPY VARCHAR2) IS
3459: ----------------------------------------------------------------------
3460: l_report_header_id AP_WEB_DB_EXPLINE_PKG.expLines_headerID;
3461: l_orig_expe_report_amt NUMBER;
3462: l_exp_report_amount AP_WEB_DB_EXPRPT_PKG.expHdr_total;
3463: l_orig_exp_report_amt NUMBER;
3464: l_expense_type AP_WEB_DB_EXPTEMPLATE_PKG.expTempl_webFriendlyPrompt;
3465: l_amount AP_WEB_DB_EXPLINE_PKG.expLines_amount;
3466: l_adjustment_reason AP_WEB_DB_EXPLINE_PKG.expLines_adjReason;

Line 3477: l_ccard_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueCCardCompany;

3473: i INTEGER;
3474: j INTEGER;
3475: l_payment_due VARCHAR2(10) := C_IndividualPay;
3476: l_total NUMBER := 0;
3477: l_ccard_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueCCardCompany;
3478: l_emp_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueEmployee;
3479: C_CreditLineVersion CONSTANT NUMBER := 1;
3480: C_WF_Version NUMBER := 0;
3481:

Line 3478: l_emp_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueEmployee;

3474: j INTEGER;
3475: l_payment_due VARCHAR2(10) := C_IndividualPay;
3476: l_total NUMBER := 0;
3477: l_ccard_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueCCardCompany;
3478: l_emp_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueEmployee;
3479: C_CreditLineVersion CONSTANT NUMBER := 1;
3480: C_WF_Version NUMBER := 0;
3481:
3482: /* jrautiai ADJ Fix Start */

Line 3496: l_ExpRec AP_WEB_DB_EXPRPT_PKG.ExpInfoRec;

3492: l_policy_emp_amt NUMBER := 0;
3493: l_policy_shortpay_total NUMBER := 0;
3494: /* jrautiai ADJ Fix End */
3495:
3496: l_ExpRec AP_WEB_DB_EXPRPT_PKG.ExpInfoRec;
3497: l_reimb_currency ap_expense_report_headers_all.payment_currency_code%type;
3498: BEGIN
3499:
3500: AP_WEB_UTILITIES_PKG.logProcedure('AP_WEB_EXPENSE_WF', 'start AnyAPAdjustments');

Line 3579: IF (AP_WEB_DB_EXPRPT_PKG.GetReportInfo(l_report_header_id, l_ExpRec)) THEN

3575:
3576: --------------------------------------------------------
3577: l_debug_info := 'Retrieve Current Expense Report Total';
3578: --------------------------------------------------------
3579: IF (AP_WEB_DB_EXPRPT_PKG.GetReportInfo(l_report_header_id, l_ExpRec)) THEN
3580: l_exp_report_amount := l_ExpRec.total;
3581: ELSE
3582: l_exp_report_amount := 0;
3583: END IF;

Line 3613: IF (NOT AP_WEB_DB_EXPRPT_PKG.SetAmtDuesAndTotal(

3609: ----------------------------------------------------------
3610: l_debug_info := 'Update the Headers table with the new Amt
3611: Dues and Total columns';
3612: ----------------------------------------------------------
3613: IF (NOT AP_WEB_DB_EXPRPT_PKG.SetAmtDuesAndTotal(
3614: l_report_header_id,
3615: nvl(l_ccard_amt,0),
3616: nvl(l_emp_amt,0),
3617: l_total)) THEN

Line 3903: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;

3899: p_actid IN NUMBER,
3900: p_funmode IN VARCHAR2,
3901: p_result OUT NOCOPY VARCHAR2) IS
3902: ----------------------------------------------------------------------
3903: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
3904: l_payment_due VARCHAR2(10) := C_IndividualPay;
3905: l_debug_info VARCHAR2(200);
3906: C_WF_Version NUMBER := 0;
3907: BEGIN

Line 3947: IF (NOT AP_WEB_DB_EXPRPT_PKG.SetWkflApprvdFlagAndSource(

3943: --SetStatusApproverAndDate, from oie.g expense_status_code is updated
3944: --at the end in SetStatusApproverAndDate
3945:
3946: IF (C_WF_Version >= AP_WEB_EXPENSE_WF.C_OIEJ_Version) THEN
3947: IF (NOT AP_WEB_DB_EXPRPT_PKG.SetWkflApprvdFlagAndSource(
3948: l_report_header_id, NULL, NULL)) THEN
3949: NULL;
3950: END IF;
3951: ELSE

Line 3952: IF (NOT AP_WEB_DB_EXPRPT_PKG.SetWkflApprvdFlagAndSource(

3948: l_report_header_id, NULL, NULL)) THEN
3949: NULL;
3950: END IF;
3951: ELSE
3952: IF (NOT AP_WEB_DB_EXPRPT_PKG.SetWkflApprvdFlagAndSource(
3953: l_report_header_id, NULL, 'SelfService')) THEN
3954: NULL;
3955: END IF;
3956: END IF;

Line 4330: PROCEDURE CreateShortPayExpReport(p_orig_expense_report_id IN AP_WEB_DB_EXPRPT_PKG.expHdr_headerID,

4326:
4327: END GetNewShortPayDocumentNum;
4328:
4329: ------------------------------------------------------------------------------
4330: PROCEDURE CreateShortPayExpReport(p_orig_expense_report_id IN AP_WEB_DB_EXPRPT_PKG.expHdr_headerID,
4331: p_new_expense_report_id IN AP_WEB_DB_EXPRPT_PKG.expHdr_headerID,
4332: p_new_expense_report_num IN AP_WEB_DB_EXPRPT_PKG.expHdr_invNum,
4333: p_new_expense_report_total IN AP_WEB_DB_EXPRPT_PKG.expHdr_total,
4334: p_new_ccard_amt IN AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueCcardCompany,

Line 4331: p_new_expense_report_id IN AP_WEB_DB_EXPRPT_PKG.expHdr_headerID,

4327: END GetNewShortPayDocumentNum;
4328:
4329: ------------------------------------------------------------------------------
4330: PROCEDURE CreateShortPayExpReport(p_orig_expense_report_id IN AP_WEB_DB_EXPRPT_PKG.expHdr_headerID,
4331: p_new_expense_report_id IN AP_WEB_DB_EXPRPT_PKG.expHdr_headerID,
4332: p_new_expense_report_num IN AP_WEB_DB_EXPRPT_PKG.expHdr_invNum,
4333: p_new_expense_report_total IN AP_WEB_DB_EXPRPT_PKG.expHdr_total,
4334: p_new_ccard_amt IN AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueCcardCompany,
4335: p_new_emp_amt IN AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueEmployee,

Line 4332: p_new_expense_report_num IN AP_WEB_DB_EXPRPT_PKG.expHdr_invNum,

4328:
4329: ------------------------------------------------------------------------------
4330: PROCEDURE CreateShortPayExpReport(p_orig_expense_report_id IN AP_WEB_DB_EXPRPT_PKG.expHdr_headerID,
4331: p_new_expense_report_id IN AP_WEB_DB_EXPRPT_PKG.expHdr_headerID,
4332: p_new_expense_report_num IN AP_WEB_DB_EXPRPT_PKG.expHdr_invNum,
4333: p_new_expense_report_total IN AP_WEB_DB_EXPRPT_PKG.expHdr_total,
4334: p_new_ccard_amt IN AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueCcardCompany,
4335: p_new_emp_amt IN AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueEmployee,
4336: p_shortpay_type IN VARCHAR2)

Line 4333: p_new_expense_report_total IN AP_WEB_DB_EXPRPT_PKG.expHdr_total,

4329: ------------------------------------------------------------------------------
4330: PROCEDURE CreateShortPayExpReport(p_orig_expense_report_id IN AP_WEB_DB_EXPRPT_PKG.expHdr_headerID,
4331: p_new_expense_report_id IN AP_WEB_DB_EXPRPT_PKG.expHdr_headerID,
4332: p_new_expense_report_num IN AP_WEB_DB_EXPRPT_PKG.expHdr_invNum,
4333: p_new_expense_report_total IN AP_WEB_DB_EXPRPT_PKG.expHdr_total,
4334: p_new_ccard_amt IN AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueCcardCompany,
4335: p_new_emp_amt IN AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueEmployee,
4336: p_shortpay_type IN VARCHAR2)
4337: ------------------------------------------------------------------------------

Line 4334: p_new_ccard_amt IN AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueCcardCompany,

4330: PROCEDURE CreateShortPayExpReport(p_orig_expense_report_id IN AP_WEB_DB_EXPRPT_PKG.expHdr_headerID,
4331: p_new_expense_report_id IN AP_WEB_DB_EXPRPT_PKG.expHdr_headerID,
4332: p_new_expense_report_num IN AP_WEB_DB_EXPRPT_PKG.expHdr_invNum,
4333: p_new_expense_report_total IN AP_WEB_DB_EXPRPT_PKG.expHdr_total,
4334: p_new_ccard_amt IN AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueCcardCompany,
4335: p_new_emp_amt IN AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueEmployee,
4336: p_shortpay_type IN VARCHAR2)
4337: ------------------------------------------------------------------------------
4338: IS

Line 4335: p_new_emp_amt IN AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueEmployee,

4331: p_new_expense_report_id IN AP_WEB_DB_EXPRPT_PKG.expHdr_headerID,
4332: p_new_expense_report_num IN AP_WEB_DB_EXPRPT_PKG.expHdr_invNum,
4333: p_new_expense_report_total IN AP_WEB_DB_EXPRPT_PKG.expHdr_total,
4334: p_new_ccard_amt IN AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueCcardCompany,
4335: p_new_emp_amt IN AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueEmployee,
4336: p_shortpay_type IN VARCHAR2)
4337: ------------------------------------------------------------------------------
4338: IS
4339: l_debug_info VARCHAR2(2000);

Line 4340: l_ExpenseRec AP_WEB_DB_EXPRPT_PKG.XpenseInfoRec;

4336: p_shortpay_type IN VARCHAR2)
4337: ------------------------------------------------------------------------------
4338: IS
4339: l_debug_info VARCHAR2(2000);
4340: l_ExpenseRec AP_WEB_DB_EXPRPT_PKG.XpenseInfoRec;
4341: l_receipts_status AP_EXPENSE_REPORT_HEADERS.receipts_status%TYPE;
4342: l_received_date AP_EXPENSE_REPORT_HEADERS.receipts_received_date%TYPE;
4343: l_img_receipts_status AP_EXPENSE_REPORT_HEADERS.image_receipts_status%TYPE;
4344: l_img_received_date AP_EXPENSE_REPORT_HEADERS.image_receipts_received_date%TYPE;

Line 4406: IF (NOT AP_WEB_DB_EXPRPT_PKG.InsertReportHeaderLikeExisting(

4402: l_ExpenseRec.image_receipts_status := l_img_receipts_status;
4403: l_ExpenseRec.image_receipts_received_date := l_img_received_date;
4404: END IF;
4405:
4406: IF (NOT AP_WEB_DB_EXPRPT_PKG.InsertReportHeaderLikeExisting(
4407: p_orig_expense_report_id, l_ExpenseRec)) THEN
4408: NULL;
4409: END IF;
4410:

Line 4417: AP_WEB_DB_EXPRPT_PKG.CopyAttachments(p_orig_expense_report_id,

4413: --------------------------------------------------------------------
4414: l_debug_info := 'Creating reference for Header Attachments';
4415: --------------------------------------------------------------------
4416:
4417: AP_WEB_DB_EXPRPT_PKG.CopyAttachments(p_orig_expense_report_id,
4418: p_new_expense_report_id,
4419: 'OIE_HEADER_ATTACHMENTS');
4420:
4421: IF (p_shortpay_type = 'POLICY') THEN

Line 4521: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;

4517: p_actid IN NUMBER,
4518: p_funmode IN VARCHAR2,
4519: p_result OUT NOCOPY VARCHAR2) IS
4520: ----------------------------------------------------------------------
4521: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
4522: l_num_req_receipt_not_verified NUMBER;
4523: l_policy_shortpay_total AP_WEB_DB_EXPRPT_PKG.expHdr_total;
4524: l_no_receipts_shortpay_total AP_WEB_DB_EXPRPT_PKG.expHdr_total;
4525: l_policy_shortpay_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;

Line 4523: l_policy_shortpay_total AP_WEB_DB_EXPRPT_PKG.expHdr_total;

4519: p_result OUT NOCOPY VARCHAR2) IS
4520: ----------------------------------------------------------------------
4521: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
4522: l_num_req_receipt_not_verified NUMBER;
4523: l_policy_shortpay_total AP_WEB_DB_EXPRPT_PKG.expHdr_total;
4524: l_no_receipts_shortpay_total AP_WEB_DB_EXPRPT_PKG.expHdr_total;
4525: l_policy_shortpay_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
4526: l_no_receipts_shortpay_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
4527: l_no_img_receipts_shortpay_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;

Line 4524: l_no_receipts_shortpay_total AP_WEB_DB_EXPRPT_PKG.expHdr_total;

4520: ----------------------------------------------------------------------
4521: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
4522: l_num_req_receipt_not_verified NUMBER;
4523: l_policy_shortpay_total AP_WEB_DB_EXPRPT_PKG.expHdr_total;
4524: l_no_receipts_shortpay_total AP_WEB_DB_EXPRPT_PKG.expHdr_total;
4525: l_policy_shortpay_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
4526: l_no_receipts_shortpay_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
4527: l_no_img_receipts_shortpay_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
4528: l_no_both_receipts_shortpay_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;

Line 4525: l_policy_shortpay_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;

4521: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
4522: l_num_req_receipt_not_verified NUMBER;
4523: l_policy_shortpay_total AP_WEB_DB_EXPRPT_PKG.expHdr_total;
4524: l_no_receipts_shortpay_total AP_WEB_DB_EXPRPT_PKG.expHdr_total;
4525: l_policy_shortpay_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
4526: l_no_receipts_shortpay_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
4527: l_no_img_receipts_shortpay_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
4528: l_no_both_receipts_shortpay_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
4529: l_policy_shortpay_doc_num AP_WEB_DB_EXPRPT_PKG.expHdr_invNum;

Line 4526: l_no_receipts_shortpay_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;

4522: l_num_req_receipt_not_verified NUMBER;
4523: l_policy_shortpay_total AP_WEB_DB_EXPRPT_PKG.expHdr_total;
4524: l_no_receipts_shortpay_total AP_WEB_DB_EXPRPT_PKG.expHdr_total;
4525: l_policy_shortpay_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
4526: l_no_receipts_shortpay_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
4527: l_no_img_receipts_shortpay_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
4528: l_no_both_receipts_shortpay_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
4529: l_policy_shortpay_doc_num AP_WEB_DB_EXPRPT_PKG.expHdr_invNum;
4530: l_no_receipts_shortpay_doc_num AP_WEB_DB_EXPRPT_PKG.expHdr_invNum;

Line 4527: l_no_img_receipts_shortpay_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;

4523: l_policy_shortpay_total AP_WEB_DB_EXPRPT_PKG.expHdr_total;
4524: l_no_receipts_shortpay_total AP_WEB_DB_EXPRPT_PKG.expHdr_total;
4525: l_policy_shortpay_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
4526: l_no_receipts_shortpay_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
4527: l_no_img_receipts_shortpay_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
4528: l_no_both_receipts_shortpay_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
4529: l_policy_shortpay_doc_num AP_WEB_DB_EXPRPT_PKG.expHdr_invNum;
4530: l_no_receipts_shortpay_doc_num AP_WEB_DB_EXPRPT_PKG.expHdr_invNum;
4531: l_document_number AP_WEB_DB_EXPRPT_PKG.expHdr_invNum;

Line 4528: l_no_both_receipts_shortpay_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;

4524: l_no_receipts_shortpay_total AP_WEB_DB_EXPRPT_PKG.expHdr_total;
4525: l_policy_shortpay_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
4526: l_no_receipts_shortpay_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
4527: l_no_img_receipts_shortpay_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
4528: l_no_both_receipts_shortpay_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
4529: l_policy_shortpay_doc_num AP_WEB_DB_EXPRPT_PKG.expHdr_invNum;
4530: l_no_receipts_shortpay_doc_num AP_WEB_DB_EXPRPT_PKG.expHdr_invNum;
4531: l_document_number AP_WEB_DB_EXPRPT_PKG.expHdr_invNum;
4532: l_payment_due VARCHAR2(10) := C_IndividualPay;

Line 4529: l_policy_shortpay_doc_num AP_WEB_DB_EXPRPT_PKG.expHdr_invNum;

4525: l_policy_shortpay_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
4526: l_no_receipts_shortpay_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
4527: l_no_img_receipts_shortpay_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
4528: l_no_both_receipts_shortpay_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
4529: l_policy_shortpay_doc_num AP_WEB_DB_EXPRPT_PKG.expHdr_invNum;
4530: l_no_receipts_shortpay_doc_num AP_WEB_DB_EXPRPT_PKG.expHdr_invNum;
4531: l_document_number AP_WEB_DB_EXPRPT_PKG.expHdr_invNum;
4532: l_payment_due VARCHAR2(10) := C_IndividualPay;
4533: l_count NUMBER;

Line 4530: l_no_receipts_shortpay_doc_num AP_WEB_DB_EXPRPT_PKG.expHdr_invNum;

4526: l_no_receipts_shortpay_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
4527: l_no_img_receipts_shortpay_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
4528: l_no_both_receipts_shortpay_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
4529: l_policy_shortpay_doc_num AP_WEB_DB_EXPRPT_PKG.expHdr_invNum;
4530: l_no_receipts_shortpay_doc_num AP_WEB_DB_EXPRPT_PKG.expHdr_invNum;
4531: l_document_number AP_WEB_DB_EXPRPT_PKG.expHdr_invNum;
4532: l_payment_due VARCHAR2(10) := C_IndividualPay;
4533: l_count NUMBER;
4534: l_personal_total NUMBER := 0;

Line 4531: l_document_number AP_WEB_DB_EXPRPT_PKG.expHdr_invNum;

4527: l_no_img_receipts_shortpay_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
4528: l_no_both_receipts_shortpay_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
4529: l_policy_shortpay_doc_num AP_WEB_DB_EXPRPT_PKG.expHdr_invNum;
4530: l_no_receipts_shortpay_doc_num AP_WEB_DB_EXPRPT_PKG.expHdr_invNum;
4531: l_document_number AP_WEB_DB_EXPRPT_PKG.expHdr_invNum;
4532: l_payment_due VARCHAR2(10) := C_IndividualPay;
4533: l_count NUMBER;
4534: l_personal_total NUMBER := 0;
4535: l_policy_ccard_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueCcardCompany;

Line 4535: l_policy_ccard_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueCcardCompany;

4531: l_document_number AP_WEB_DB_EXPRPT_PKG.expHdr_invNum;
4532: l_payment_due VARCHAR2(10) := C_IndividualPay;
4533: l_count NUMBER;
4534: l_personal_total NUMBER := 0;
4535: l_policy_ccard_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueCcardCompany;
4536: l_no_receipts_ccard_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueCcardCompany;
4537: l_policy_emp_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueEmployee;
4538: l_no_receipts_emp_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueEmployee;
4539: l_ccard_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueCcardCompany;

Line 4536: l_no_receipts_ccard_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueCcardCompany;

4532: l_payment_due VARCHAR2(10) := C_IndividualPay;
4533: l_count NUMBER;
4534: l_personal_total NUMBER := 0;
4535: l_policy_ccard_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueCcardCompany;
4536: l_no_receipts_ccard_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueCcardCompany;
4537: l_policy_emp_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueEmployee;
4538: l_no_receipts_emp_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueEmployee;
4539: l_ccard_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueCcardCompany;
4540: l_emp_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueEmployee;

Line 4537: l_policy_emp_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueEmployee;

4533: l_count NUMBER;
4534: l_personal_total NUMBER := 0;
4535: l_policy_ccard_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueCcardCompany;
4536: l_no_receipts_ccard_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueCcardCompany;
4537: l_policy_emp_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueEmployee;
4538: l_no_receipts_emp_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueEmployee;
4539: l_ccard_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueCcardCompany;
4540: l_emp_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueEmployee;
4541: l_currency VARCHAR2(50);

Line 4538: l_no_receipts_emp_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueEmployee;

4534: l_personal_total NUMBER := 0;
4535: l_policy_ccard_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueCcardCompany;
4536: l_no_receipts_ccard_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueCcardCompany;
4537: l_policy_emp_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueEmployee;
4538: l_no_receipts_emp_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueEmployee;
4539: l_ccard_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueCcardCompany;
4540: l_emp_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueEmployee;
4541: l_currency VARCHAR2(50);
4542: l_debug_info VARCHAR2(500);

Line 4539: l_ccard_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueCcardCompany;

4535: l_policy_ccard_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueCcardCompany;
4536: l_no_receipts_ccard_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueCcardCompany;
4537: l_policy_emp_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueEmployee;
4538: l_no_receipts_emp_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueEmployee;
4539: l_ccard_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueCcardCompany;
4540: l_emp_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueEmployee;
4541: l_currency VARCHAR2(50);
4542: l_debug_info VARCHAR2(500);
4543: l_audit_tag VARCHAR2(80);

Line 4540: l_emp_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueEmployee;

4536: l_no_receipts_ccard_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueCcardCompany;
4537: l_policy_emp_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueEmployee;
4538: l_no_receipts_emp_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueEmployee;
4539: l_ccard_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueCcardCompany;
4540: l_emp_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueEmployee;
4541: l_currency VARCHAR2(50);
4542: l_debug_info VARCHAR2(500);
4543: l_audit_tag VARCHAR2(80);
4544:

Line 4547: l_amtDueCCardCompany AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueCcardCompany;

4543: l_audit_tag VARCHAR2(80);
4544:
4545: l_no_data_found_flag1 BOOLEAN := TRUE;
4546: l_no_data_found_flag2 BOOLEAN := TRUE;
4547: l_amtDueCCardCompany AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueCcardCompany;
4548: l_amtDueEmp AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueEmployee;
4549:
4550: /* jrautiai ADJ Fix - Start */
4551: l_total NUMBER := 0;

Line 4548: l_amtDueEmp AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueEmployee;

4544:
4545: l_no_data_found_flag1 BOOLEAN := TRUE;
4546: l_no_data_found_flag2 BOOLEAN := TRUE;
4547: l_amtDueCCardCompany AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueCcardCompany;
4548: l_amtDueEmp AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueEmployee;
4549:
4550: /* jrautiai ADJ Fix - Start */
4551: l_total NUMBER := 0;
4552: l_policy_count NUMBER := 0;

Line 4632: IF (NOT AP_WEB_DB_EXPRPT_PKG.GetNextExpReportID(l_policy_shortpay_id)) THEN

4628:
4629: -----------------------------------------------------------------
4630: l_debug_info := 'Retrieve Policy ShortPay New Expense Report Id';
4631: -----------------------------------------------------------------
4632: IF (NOT AP_WEB_DB_EXPRPT_PKG.GetNextExpReportID(l_policy_shortpay_id)) THEN
4633: NULL;
4634: END IF;
4635:
4636: l_policy_shortpay_doc_num := l_document_number || '-1';

Line 4664: IF (NOT AP_WEB_DB_EXPRPT_PKG.SetAmtDuesAndTotal(l_policy_shortpay_id,

4660: l_policy_emp_amt:=0;
4661: l_policy_ccard_amt:=0;
4662: l_policy_shortpay_total := 0;
4663: END IF;
4664: IF (NOT AP_WEB_DB_EXPRPT_PKG.SetAmtDuesAndTotal(l_policy_shortpay_id,
4665: l_policy_ccard_amt,
4666: l_policy_emp_amt,
4667: l_policy_shortpay_total)) THEN
4668: NULL;

Line 4697: IF (NOT AP_WEB_DB_EXPRPT_PKG.GetNextExpReportID(l_no_receipts_shortpay_id)) THEN

4693: IF (l_missing_receipt_count > 0) THEN
4694: -----------------------------------------------------------------
4695: l_debug_info := 'Retrieve Policy ShortPay New Expense Report Id';
4696: -----------------------------------------------------------------
4697: IF (NOT AP_WEB_DB_EXPRPT_PKG.GetNextExpReportID(l_no_receipts_shortpay_id)) THEN
4698: l_no_receipts_shortpay_id := NULL;
4699: END IF;
4700:
4701: IF (l_policy_count > 0) THEN

Line 4734: IF (NOT AP_WEB_DB_EXPRPT_PKG.SetAmtDuesAndTotal(l_no_receipts_shortpay_id,

4730: l_no_receipts_emp_amt:=0;
4731: l_no_receipts_ccard_amt:=0;
4732: l_no_receipts_shortpay_total := 0;
4733: END IF;
4734: IF (NOT AP_WEB_DB_EXPRPT_PKG.SetAmtDuesAndTotal(l_no_receipts_shortpay_id,
4735: l_no_receipts_ccard_amt,
4736: l_no_receipts_emp_amt,
4737: l_no_receipts_shortpay_total)) THEN
4738: NULL;

Line 4763: IF (NOT AP_WEB_DB_EXPRPT_PKG.GetNextExpReportID(l_no_img_receipts_shortpay_id)) THEN

4759: IF (l_image_count > 0) THEN
4760: -----------------------------------------------------------------
4761: l_debug_info := 'Retrieve Policy ShortPay New Expense Report Id';
4762: -----------------------------------------------------------------
4763: IF (NOT AP_WEB_DB_EXPRPT_PKG.GetNextExpReportID(l_no_img_receipts_shortpay_id)) THEN
4764: l_no_img_receipts_shortpay_id := NULL;
4765: END IF;
4766:
4767: IF (l_policy_count > 0 AND l_missing_receipt_count > 0) THEN

Line 4805: IF (NOT AP_WEB_DB_EXPRPT_PKG.SetAmtDuesAndTotal(l_no_img_receipts_shortpay_id,

4801: l_no_receipts_emp_amt:=0;
4802: l_no_receipts_ccard_amt:=0;
4803: l_no_receipts_shortpay_total := 0;
4804: END IF;
4805: IF (NOT AP_WEB_DB_EXPRPT_PKG.SetAmtDuesAndTotal(l_no_img_receipts_shortpay_id,
4806: l_no_receipts_ccard_amt,
4807: l_no_receipts_emp_amt,
4808: l_no_receipts_shortpay_total)) THEN
4809: NULL;

Line 4834: IF (NOT AP_WEB_DB_EXPRPT_PKG.GetNextExpReportID(l_no_both_receipts_shortpay_id)) THEN

4830: IF (l_both_count > 0) THEN
4831: -----------------------------------------------------------------
4832: l_debug_info := 'Retrieve Policy ShortPay New Expense Report Id';
4833: -----------------------------------------------------------------
4834: IF (NOT AP_WEB_DB_EXPRPT_PKG.GetNextExpReportID(l_no_both_receipts_shortpay_id)) THEN
4835: l_no_img_receipts_shortpay_id := NULL;
4836: END IF;
4837:
4838:

Line 4867: IF (NOT AP_WEB_DB_EXPRPT_PKG.SetAmtDuesAndTotal(l_no_both_receipts_shortpay_id,

4863: l_no_receipts_emp_amt:=0;
4864: l_no_receipts_ccard_amt:=0;
4865: l_no_receipts_shortpay_total := 0;
4866: END IF;
4867: IF (NOT AP_WEB_DB_EXPRPT_PKG.SetAmtDuesAndTotal(l_no_both_receipts_shortpay_id,
4868: l_no_receipts_ccard_amt,
4869: l_no_receipts_emp_amt,
4870: l_no_receipts_shortpay_total)) THEN
4871: NULL;

Line 4934: IF (NOT AP_WEB_DB_EXPRPT_PKG.DeleteExpenseReport(l_report_header_id)) THEN

4930: -----------------------------------------
4931: l_debug_info := 'Delete the original expense report if everything
4932: is getting shortpaid';
4933: ----------------------------------------------------------------------
4934: IF (NOT AP_WEB_DB_EXPRPT_PKG.DeleteExpenseReport(l_report_header_id)) THEN
4935: NULL;
4936: END IF;
4937:
4938: ELSE

Line 4955: IF (NOT AP_WEB_DB_EXPRPT_PKG.SetAmtDuesAndTotal(l_report_header_id,

4951: l_amtDueCCardCompany:=0;
4952: l_total := 0;
4953: END IF;
4954:
4955: IF (NOT AP_WEB_DB_EXPRPT_PKG.SetAmtDuesAndTotal(l_report_header_id,
4956: l_amtDueCCardCompany,
4957: l_amtDueEmp,
4958: l_total)) THEN
4959: /* jrautiai ADJ Fix End */

Line 4982: PROCEDURE DeleteExpReportFromAPTables(p_report_header_id IN AP_WEB_DB_EXPRPT_PKG.expHdr_headerID) IS

4978: END SplitExpenseReport;
4979:
4980:
4981:
4982: PROCEDURE DeleteExpReportFromAPTables(p_report_header_id IN AP_WEB_DB_EXPRPT_PKG.expHdr_headerID) IS
4983: l_debug_info VARCHAR2(200);
4984: l_payment_due VARCHAR2(10) := C_IndividualPay;
4985: l_item_type VARCHAR2(100) := 'APEXP';
4986: l_item_key VARCHAR2(100) := to_char(p_report_header_id);

Line 5027: IF (NOT AP_WEB_DB_EXPRPT_PKG.DeleteExpenseReport(p_report_header_id)) THEN

5023:
5024: ----------------------------------------------------
5025: l_debug_info := 'Delete the expense report header';
5026: ----------------------------------------------------
5027: IF (NOT AP_WEB_DB_EXPRPT_PKG.DeleteExpenseReport(p_report_header_id)) THEN
5028: NULL;
5029: END IF;
5030:
5031: AP_WEB_UTILITIES_PKG.logProcedure('AP_WEB_EXPENSE_WF', 'end DeleteExpReportFromAPTables');

Line 5059: l_override_approver_id AP_WEB_DB_EXPRPT_PKG.expHdr_overrideApprID;

5055: I NUMBER;
5056: l_debug_info VARCHAR2(200);
5057: C_WF_VERSION NUMBER := 0;
5058: -- Bug 668037
5059: l_override_approver_id AP_WEB_DB_EXPRPT_PKG.expHdr_overrideApprID;
5060:
5061: BEGIN
5062:
5063: AP_WEB_UTILITIES_PKG.logProcedure('AP_WEB_EXPENSE_WF', 'start ResetAttrValues');

Line 5249: IF (NOT AP_WEB_DB_EXPRPT_PKG.GetOverrideApproverID(to_number(p_item_key), l_override_approver_id)) THEN

5245: --
5246: -- Bug 668037
5247: -- Reset approver attributes
5248: --
5249: IF (NOT AP_WEB_DB_EXPRPT_PKG.GetOverrideApproverID(to_number(p_item_key), l_override_approver_id)) THEN
5250: l_override_approver_id := NULL;
5251: END IF;
5252:
5253: IF (l_override_approver_id IS NOT NULL) THEN

Line 5375: l_ap_review_status AP_WEB_DB_EXPRPT_PKG.expHdr_wkflApprvdFlag;

5371: l_itemtype varchar2(30);
5372: l_AmeRejectedChildItemKey varchar2(30);
5373: l_AmeApprovedChildItemKey varchar2(30);
5374: l_ap_reject_return varchar2(1);
5375: l_ap_review_status AP_WEB_DB_EXPRPT_PKG.expHdr_wkflApprvdFlag;
5376: l_WorkflowRec AP_WEB_DB_EXPRPT_PKG.ExpWorkflowRec;
5377: BEGIN
5378:
5379: l_itemtype := 'APEXP';

Line 5376: l_WorkflowRec AP_WEB_DB_EXPRPT_PKG.ExpWorkflowRec;

5372: l_AmeRejectedChildItemKey varchar2(30);
5373: l_AmeApprovedChildItemKey varchar2(30);
5374: l_ap_reject_return varchar2(1);
5375: l_ap_review_status AP_WEB_DB_EXPRPT_PKG.expHdr_wkflApprvdFlag;
5376: l_WorkflowRec AP_WEB_DB_EXPRPT_PKG.ExpWorkflowRec;
5377: BEGIN
5378:
5379: l_itemtype := 'APEXP';
5380: l_itemkey := to_char(p_rep_header_id);

Line 5410: IF (AP_WEB_DB_EXPRPT_PKG.GetExpWorkflowInfo(to_number(l_itemkey),

5406:
5407: -------------------------------------------------
5408: l_debug_info := 'Retrieve The AP Reviewed Flag';
5409: -------------------------------------------------
5410: IF (AP_WEB_DB_EXPRPT_PKG.GetExpWorkflowInfo(to_number(l_itemkey),
5411: l_WorkflowRec)) THEN
5412: l_ap_review_status := nvl(l_WorkflowRec.workflow_flag, 'N');
5413: END IF;
5414:

Line 5416: IF (l_ap_review_status = AP_WEB_DB_EXPRPT_PKG.C_WORKFLOW_APPROVED_REJECTED or -- already AP rejected

5412: l_ap_review_status := nvl(l_WorkflowRec.workflow_flag, 'N');
5413: END IF;
5414:
5415: l_ap_reject_return := 'N';
5416: IF (l_ap_review_status = AP_WEB_DB_EXPRPT_PKG.C_WORKFLOW_APPROVED_REJECTED or -- already AP rejected
5417: l_ap_review_status = AP_WEB_DB_EXPRPT_PKG.C_WORKFLOW_APPROVED_REQUEST) THEN -- already AP requests more info
5418: l_ap_reject_return := 'Y';
5419: END IF;
5420:

Line 5417: l_ap_review_status = AP_WEB_DB_EXPRPT_PKG.C_WORKFLOW_APPROVED_REQUEST) THEN -- already AP requests more info

5413: END IF;
5414:
5415: l_ap_reject_return := 'N';
5416: IF (l_ap_review_status = AP_WEB_DB_EXPRPT_PKG.C_WORKFLOW_APPROVED_REJECTED or -- already AP rejected
5417: l_ap_review_status = AP_WEB_DB_EXPRPT_PKG.C_WORKFLOW_APPROVED_REQUEST) THEN -- already AP requests more info
5418: l_ap_reject_return := 'Y';
5419: END IF;
5420:
5421: if (l_childItemKeySeq >= 1) then

Line 5501: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;

5497: p_funmode IN VARCHAR2,
5498: p_result OUT NOCOPY VARCHAR2) IS
5499: ----------------------------------------------------------------------
5500: l_debug_info VARCHAR2(200);
5501: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
5502: l_payment_due VARCHAR2(10) := C_IndividualPay;
5503: l_AMEEnabled VARCHAR2(1);
5504: l_No VARCHAR2(1) := 'N';
5505: C_WF_Version NUMBER := 0;

Line 5530: IF (NOT AP_WEB_DB_EXPRPT_PKG.SetWkflApprvdFlagAndSource(l_report_header_id,

5526:
5527: ------------------------------------------------------------
5528: l_debug_info := 'Set reject status in report header';
5529: ------------------------------------------------------------
5530: IF (NOT AP_WEB_DB_EXPRPT_PKG.SetWkflApprvdFlagAndSource(l_report_header_id,
5531: AP_WEB_DB_EXPRPT_PKG.C_WORKFLOW_APPROVED_REJECTED,
5532: 'NonValidatedWebExpense')) THEN
5533: NULL;
5534: END IF;

Line 5531: AP_WEB_DB_EXPRPT_PKG.C_WORKFLOW_APPROVED_REJECTED,

5527: ------------------------------------------------------------
5528: l_debug_info := 'Set reject status in report header';
5529: ------------------------------------------------------------
5530: IF (NOT AP_WEB_DB_EXPRPT_PKG.SetWkflApprvdFlagAndSource(l_report_header_id,
5531: AP_WEB_DB_EXPRPT_PKG.C_WORKFLOW_APPROVED_REJECTED,
5532: 'NonValidatedWebExpense')) THEN
5533: NULL;
5534: END IF;
5535:

Line 5668: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;

5664: p_actid IN NUMBER,
5665: p_funmode IN VARCHAR2,
5666: p_result OUT NOCOPY VARCHAR2) IS
5667: ----------------------------------------------------------------------
5668: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
5669: l_debug_info VARCHAR2(200);
5670: BEGIN
5671:
5672: AP_WEB_UTILITIES_PKG.logProcedure('AP_WEB_EXPENSE_WF', 'start DeleteExpenseReport');

Line 5950: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;

5946: p_actid IN NUMBER,
5947: p_funmode IN VARCHAR2,
5948: p_result OUT NOCOPY VARCHAR2) IS
5949: ----------------------------------------------------------------------
5950: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
5951: l_debug_info VARCHAR2(200);
5952: l_No VARCHAR2(1) := 'N';
5953: BEGIN
5954:

Line 5971: IF (NOT AP_WEB_DB_EXPRPT_PKG.SetWkflApprvdFlag2(l_report_header_id)) THEN

5967: --------------------------------------------------------------
5968: l_debug_info := 'Update all expense lines as receipt missing';
5969: --------------------------------------------------------------
5970: -- Bug 884248
5971: IF (NOT AP_WEB_DB_EXPRPT_PKG.SetWkflApprvdFlag2(l_report_header_id)) THEN
5972: NULL;
5973: END IF;
5974:
5975: ----------------------------------------------------------

Line 6125: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;

6121: p_funmode IN VARCHAR2,
6122: p_result OUT NOCOPY VARCHAR2)
6123: ------------------------------------------------------------------------------
6124: IS
6125: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
6126: l_total AP_WEB_DB_EXPRPT_PKG.expHdr_total := NULL;
6127: l_new_report_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
6128: l_document_number AP_WEB_DB_EXPRPT_PKG.expHdr_invNum;
6129: l_description AP_WEB_DB_EXPRPT_PKG.expHdr_description := NULL;

Line 6126: l_total AP_WEB_DB_EXPRPT_PKG.expHdr_total := NULL;

6122: p_result OUT NOCOPY VARCHAR2)
6123: ------------------------------------------------------------------------------
6124: IS
6125: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
6126: l_total AP_WEB_DB_EXPRPT_PKG.expHdr_total := NULL;
6127: l_new_report_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
6128: l_document_number AP_WEB_DB_EXPRPT_PKG.expHdr_invNum;
6129: l_description AP_WEB_DB_EXPRPT_PKG.expHdr_description := NULL;
6130: l_vendor_id AP_WEB_DB_CCARD_PKG.cardProgs_vendorID := NULL;

Line 6127: l_new_report_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;

6123: ------------------------------------------------------------------------------
6124: IS
6125: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
6126: l_total AP_WEB_DB_EXPRPT_PKG.expHdr_total := NULL;
6127: l_new_report_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
6128: l_document_number AP_WEB_DB_EXPRPT_PKG.expHdr_invNum;
6129: l_description AP_WEB_DB_EXPRPT_PKG.expHdr_description := NULL;
6130: l_vendor_id AP_WEB_DB_CCARD_PKG.cardProgs_vendorID := NULL;
6131: l_vendor_site_id AP_WEB_DB_CCARD_PKG.cardProgs_vendorSiteID := NULL;

Line 6128: l_document_number AP_WEB_DB_EXPRPT_PKG.expHdr_invNum;

6124: IS
6125: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
6126: l_total AP_WEB_DB_EXPRPT_PKG.expHdr_total := NULL;
6127: l_new_report_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
6128: l_document_number AP_WEB_DB_EXPRPT_PKG.expHdr_invNum;
6129: l_description AP_WEB_DB_EXPRPT_PKG.expHdr_description := NULL;
6130: l_vendor_id AP_WEB_DB_CCARD_PKG.cardProgs_vendorID := NULL;
6131: l_vendor_site_id AP_WEB_DB_CCARD_PKG.cardProgs_vendorSiteID := NULL;
6132: l_ccard_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueCcardCompany := 0;

Line 6129: l_description AP_WEB_DB_EXPRPT_PKG.expHdr_description := NULL;

6125: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
6126: l_total AP_WEB_DB_EXPRPT_PKG.expHdr_total := NULL;
6127: l_new_report_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
6128: l_document_number AP_WEB_DB_EXPRPT_PKG.expHdr_invNum;
6129: l_description AP_WEB_DB_EXPRPT_PKG.expHdr_description := NULL;
6130: l_vendor_id AP_WEB_DB_CCARD_PKG.cardProgs_vendorID := NULL;
6131: l_vendor_site_id AP_WEB_DB_CCARD_PKG.cardProgs_vendorSiteID := NULL;
6132: l_ccard_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueCcardCompany := 0;
6133: l_XpenseRec AP_WEB_DB_EXPRPT_PKG.XpenseInfoRec;

Line 6132: l_ccard_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueCcardCompany := 0;

6128: l_document_number AP_WEB_DB_EXPRPT_PKG.expHdr_invNum;
6129: l_description AP_WEB_DB_EXPRPT_PKG.expHdr_description := NULL;
6130: l_vendor_id AP_WEB_DB_CCARD_PKG.cardProgs_vendorID := NULL;
6131: l_vendor_site_id AP_WEB_DB_CCARD_PKG.cardProgs_vendorSiteID := NULL;
6132: l_ccard_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueCcardCompany := 0;
6133: l_XpenseRec AP_WEB_DB_EXPRPT_PKG.XpenseInfoRec;
6134: l_accts_pay_comb_id AP_WEB_DB_EXPRPT_PKG.expHdr_acctsPayCodeCombID := NULL;
6135: l_debug_info VARCHAR2(2000);
6136: l_ccard_exists BOOLEAN := TRUE;

Line 6133: l_XpenseRec AP_WEB_DB_EXPRPT_PKG.XpenseInfoRec;

6129: l_description AP_WEB_DB_EXPRPT_PKG.expHdr_description := NULL;
6130: l_vendor_id AP_WEB_DB_CCARD_PKG.cardProgs_vendorID := NULL;
6131: l_vendor_site_id AP_WEB_DB_CCARD_PKG.cardProgs_vendorSiteID := NULL;
6132: l_ccard_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueCcardCompany := 0;
6133: l_XpenseRec AP_WEB_DB_EXPRPT_PKG.XpenseInfoRec;
6134: l_accts_pay_comb_id AP_WEB_DB_EXPRPT_PKG.expHdr_acctsPayCodeCombID := NULL;
6135: l_debug_info VARCHAR2(2000);
6136: l_ccard_exists BOOLEAN := TRUE;
6137: l_report_submitted_date DATE;

Line 6134: l_accts_pay_comb_id AP_WEB_DB_EXPRPT_PKG.expHdr_acctsPayCodeCombID := NULL;

6130: l_vendor_id AP_WEB_DB_CCARD_PKG.cardProgs_vendorID := NULL;
6131: l_vendor_site_id AP_WEB_DB_CCARD_PKG.cardProgs_vendorSiteID := NULL;
6132: l_ccard_amt AP_WEB_DB_EXPRPT_PKG.expHdr_amtDueCcardCompany := 0;
6133: l_XpenseRec AP_WEB_DB_EXPRPT_PKG.XpenseInfoRec;
6134: l_accts_pay_comb_id AP_WEB_DB_EXPRPT_PKG.expHdr_acctsPayCodeCombID := NULL;
6135: l_debug_info VARCHAR2(2000);
6136: l_ccard_exists BOOLEAN := TRUE;
6137: l_report_submitted_date DATE;
6138: l_org_id NUMBER;

Line 6171: IF (NOT AP_WEB_DB_EXPRPT_PKG.GetNextExpReportID(l_new_report_id) ) THEN

6167:
6168: -----------------------------------------------------------------
6169: l_debug_info := 'Retrieve Credit Card New Expense Report Id';
6170: -----------------------------------------------------------------
6171: IF (NOT AP_WEB_DB_EXPRPT_PKG.GetNextExpReportID(l_new_report_id) ) THEN
6172: l_new_report_id := NULL;
6173: END IF;
6174:
6175:

Line 6180: IF (NOT AP_WEB_DB_EXPRPT_PKG.GetExpReportInfo(l_report_header_id,

6176: -------------------------------------------------------------------
6177: l_debug_info := 'Obtain the card number and the full name and the
6178: vendor information for the new expense report';
6179: --------------------------------------------------------------------
6180: IF (NOT AP_WEB_DB_EXPRPT_PKG.GetExpReportInfo(l_report_header_id,
6181: l_description, l_ccard_amt, l_total)) THEN
6182: l_description := NULL;
6183: l_total := 0;
6184: l_ccard_amt := 0;

Line 6282: IF (NOT AP_WEB_DB_EXPRPT_PKG.InsertReportHeaderLikeExisting(

6278: END IF;
6279:
6280: l_XpenseRec.expense_status_code := l_expense_status_code;
6281:
6282: IF (NOT AP_WEB_DB_EXPRPT_PKG.InsertReportHeaderLikeExisting(
6283: l_report_header_id, l_XpenseRec)) THEN
6284: NULL;
6285: END IF;
6286:

Line 6293: AP_WEB_DB_EXPRPT_PKG.CopyAttachments(l_report_header_id,

6289: --------------------------------------------------------------------
6290: l_debug_info := 'Creating reference for Header Attachments';
6291: --------------------------------------------------------------------
6292:
6293: AP_WEB_DB_EXPRPT_PKG.CopyAttachments(l_report_header_id,
6294: l_new_report_id,
6295: 'OIE_HEADER_ATTACHMENTS');
6296:
6297: ------------------------------------------------------------------

Line 6571: IF (AP_WEB_DB_EXPRPT_PKG.GetOrgIdByReportHeaderId(

6567: if (wf_core.error_name = 'WFENG_ITEM_ATTR') then
6568: -- ORG_ID item attribute doesn't exist, need to add it
6569: wf_engine.AddItemAttr(p_item_type, p_item_key, 'ORG_ID');
6570: -- get the org_id from header for old reports
6571: IF (AP_WEB_DB_EXPRPT_PKG.GetOrgIdByReportHeaderId(
6572: to_number(p_item_key),
6573: l_n_org_id) <> TRUE ) THEN
6574: l_n_org_id := NULL;
6575: END IF;

Line 7091: l_override_approver_id AP_WEB_DB_EXPRPT_PKG.expHdr_overrideApprID;

7087: l_document_number VARCHAR2(50);
7088: l_orig_expense_report_num VARCHAR2(50);
7089: l_emp_cost_center VARCHAR2(240);
7090: l_doc_cost_center VARCHAR2(240);
7091: l_override_approver_id AP_WEB_DB_EXPRPT_PKG.expHdr_overrideApprID;
7092: l_approver_name wf_users.name%type;
7093: l_approver_display_name wf_users.display_name%type;
7094: l_total NUMBER;
7095: l_credit_total NUMBER;

Line 7309: IF (AP_WEB_DB_EXPRPT_PKG.GetOrgIdByReportHeaderId(

7305: if (wf_core.error_name = 'WFENG_ITEM_ATTR') then
7306: -- ORG_ID item attribute doesn't exist, need to add it
7307: wf_engine.AddItemAttr(p_item_type, p_item_key, 'ORG_ID');
7308: -- get the org_id from header for old reports
7309: IF (AP_WEB_DB_EXPRPT_PKG.GetOrgIdByReportHeaderId(
7310: to_number(p_item_key),
7311: l_n_org_id) <> TRUE ) THEN
7312: l_n_org_id := NULL;
7313: END IF;

Line 7632: IF (AP_WEB_DB_EXPRPT_PKG.GetOverrideApproverID(to_number(l_item_key),

7628: 'EXPENSE_DETAILS',
7629: l_url);
7630:
7631:
7632: IF (AP_WEB_DB_EXPRPT_PKG.GetOverrideApproverID(to_number(l_item_key),
7633: l_override_approver_id)) THEN
7634:
7635: WF_DIRECTORY.GetUserName('PER',
7636: l_override_approver_id,

Line 8077: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;

8073: p_manager_target IN VARCHAR2) IS
8074: --------------------------------------------------------
8075: l_manager_name wf_users.name%type;
8076: l_manager_display_name wf_users.display_name%type;
8077: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
8078: l_debug_info VARCHAR2(200);
8079: BEGIN
8080:
8081: AP_WEB_UTILITIES_PKG.logProcedure('AP_WEB_EXPENSE_WF', 'start SetPersonAs');

Line 9042: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;

9038: p_actid IN NUMBER,
9039: p_funmode IN VARCHAR2,
9040: p_result OUT NOCOPY VARCHAR2) IS
9041: ---------------------------------------------------------
9042: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
9043: l_WorkflowRec AP_WEB_DB_EXPRPT_PKG.ExpWorkflowRec;
9044: l_debug_info VARCHAR2(200);
9045: l_rejection_reason Wf_Item_Attribute_Values.TEXT_VALUE%TYPE := NULL;
9046: BEGIN

Line 9043: l_WorkflowRec AP_WEB_DB_EXPRPT_PKG.ExpWorkflowRec;

9039: p_funmode IN VARCHAR2,
9040: p_result OUT NOCOPY VARCHAR2) IS
9041: ---------------------------------------------------------
9042: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
9043: l_WorkflowRec AP_WEB_DB_EXPRPT_PKG.ExpWorkflowRec;
9044: l_debug_info VARCHAR2(200);
9045: l_rejection_reason Wf_Item_Attribute_Values.TEXT_VALUE%TYPE := NULL;
9046: BEGIN
9047:

Line 9078: IF (NOT AP_WEB_DB_EXPRPT_PKG.GetExpWorkflowInfo(l_report_header_id,

9074: END IF;
9075:
9076:
9077:
9078: IF (NOT AP_WEB_DB_EXPRPT_PKG.GetExpWorkflowInfo(l_report_header_id,
9079: l_WorkflowRec)) THEN
9080: l_WorkflowRec.workflow_flag := NULL;
9081: END IF;
9082:

Line 9335: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;

9331: p_actid IN NUMBER,
9332: p_funmode IN VARCHAR2,
9333: p_result OUT NOCOPY VARCHAR2) IS
9334: ----------------------------------------------------------------------
9335: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
9336: l_debug_info VARCHAR2(200);
9337: BEGIN
9338:
9339: AP_WEB_UTILITIES_PKG.logProcedure('AP_WEB_EXPENSE_WF', 'start DeleteShortPayExpReport');

Line 9835: IF (AP_WEB_DB_EXPRPT_PKG.GetOrgIdByReportHeaderId(

9831: when others then
9832: if (wf_core.error_name = 'WFENG_ITEM_ATTR') then
9833: -- ORG_ID item attribute doesn't exist, need to add it
9834: WF_ENGINE.AddItemAttr(l_itemtype, l_itemkey, 'ORG_ID');
9835: IF (AP_WEB_DB_EXPRPT_PKG.GetOrgIdByReportHeaderId(
9836: to_number(l_itemkey),
9837: l_n_org_id) <> TRUE ) THEN
9838: l_n_org_id := NULL;
9839: END IF;

Line 9861: IF (AP_WEB_DB_EXPRPT_PKG.GetOrgIdByReportHeaderId(

9857: else
9858: -- Report was submitted before org_id being added, hence org_id
9859: -- item attributes hasn't been set yet. Need to get it from
9860: -- report header
9861: IF (AP_WEB_DB_EXPRPT_PKG.GetOrgIdByReportHeaderId(
9862: to_number(l_itemkey),
9863: l_n_org_id) <> TRUE ) THEN
9864: l_n_org_id := NULL;
9865: END IF;

Line 10079: IF (AP_WEB_DB_EXPRPT_PKG.GetOrgIdByReportHeaderId(

10075: if (wf_core.error_name = 'WFENG_ITEM_ATTR') then
10076: -- ORG_ID item attribute doesn't exist, need to add it
10077: wf_engine.AddItemAttr(p_s_item_type, p_s_item_key, 'ORG_ID');
10078: -- get the org_id from header for old reports
10079: IF (AP_WEB_DB_EXPRPT_PKG.GetOrgIdByReportHeaderId(
10080: to_number(p_s_item_key),
10081: l_n_org_id) <> TRUE ) THEN
10082: l_n_org_id := NULL;
10083: END IF;

Line 10197: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;

10193: ----------------------------------------------------------------------
10194:
10195: l_debug_info VARCHAR2(1000);
10196:
10197: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
10198: l_entered_by NUMBER := fnd_global.user_id;
10199: l_role_info_tbl wf_directory.wf_local_roles_tbl_type;
10200:
10201: l_orig_language_code ap_expense_params.note_language_code%type := null;

Line 10333: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;

10329: l_approver_name varchar2(240);
10330: l_approverResponse varchar2(80);
10331: l_approvalStatusIn varchar2(20);
10332:
10333: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
10334: l_entered_by NUMBER := fnd_global.user_id;
10335: l_role_info_tbl wf_directory.wf_local_roles_tbl_type;
10336:
10337: l_orig_language_code ap_expense_params.note_language_code%type := null;

Line 10387: IF (AP_WEB_DB_EXPRPT_PKG.GetOrgIdByReportHeaderId(

10383: l_temp_item_key,
10384: 'ORG_ID');
10385: exception
10386: when others then
10387: IF (AP_WEB_DB_EXPRPT_PKG.GetOrgIdByReportHeaderId(
10388: to_number(l_temp_item_key),
10389: l_n_org_id) <> TRUE ) THEN
10390: l_n_org_id := NULL;
10391: END IF;

Line 11050: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;

11046: p_funmode IN VARCHAR2,
11047: p_result OUT NOCOPY VARCHAR2) IS
11048: ----------------------------------------------------------------------
11049: l_debug_info VARCHAR2(200);
11050: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
11051: l_payment_due VARCHAR2(10) := C_IndividualPay;
11052: l_No VARCHAR2(1) := 'N';
11053: l_AMEEnabled VARCHAR2(1);
11054: C_WF_Version NUMBER := 0;

Line 11098: /*IF (NOT AP_WEB_DB_EXPRPT_PKG.SetWkflApprvdFlagAndSource(l_report_header_id,

11094:
11095: ------------------------------------------------------------
11096: l_debug_info := 'Set Returned status in report header';
11097: ------------------------------------------------------------
11098: /*IF (NOT AP_WEB_DB_EXPRPT_PKG.SetWkflApprvdFlagAndSource(l_report_header_id,
11099: AP_WEB_DB_EXPRPT_PKG.C_WORKFLOW_APPROVED_RETURNED,
11100: 'NonValidatedWebExpense')) THEN
11101: NULL;
11102: END IF;*/

Line 11099: AP_WEB_DB_EXPRPT_PKG.C_WORKFLOW_APPROVED_RETURNED,

11095: ------------------------------------------------------------
11096: l_debug_info := 'Set Returned status in report header';
11097: ------------------------------------------------------------
11098: /*IF (NOT AP_WEB_DB_EXPRPT_PKG.SetWkflApprvdFlagAndSource(l_report_header_id,
11099: AP_WEB_DB_EXPRPT_PKG.C_WORKFLOW_APPROVED_RETURNED,
11100: 'NonValidatedWebExpense')) THEN
11101: NULL;
11102: END IF;*/
11103:

Line 11190: IF (NOT AP_WEB_DB_EXPRPT_PKG.SetWkflApprvdFlagAndSource(l_report_header_id,

11186: l_debug_info := 'Raise Receipts Aborted Event';
11187: ------------------------------------------------------------
11188: AP_WEB_RECEIPTS_WF.RaiseAbortedEvent(l_report_header_id);
11189: -- Bug 12859250: Update the workflow approved flag after raising the aborted event
11190: IF (NOT AP_WEB_DB_EXPRPT_PKG.SetWkflApprvdFlagAndSource(l_report_header_id,
11191: AP_WEB_DB_EXPRPT_PKG.C_WORKFLOW_APPROVED_RETURNED,
11192: 'NonValidatedWebExpense')) THEN
11193: NULL;
11194: END IF;

Line 11191: AP_WEB_DB_EXPRPT_PKG.C_WORKFLOW_APPROVED_RETURNED,

11187: ------------------------------------------------------------
11188: AP_WEB_RECEIPTS_WF.RaiseAbortedEvent(l_report_header_id);
11189: -- Bug 12859250: Update the workflow approved flag after raising the aborted event
11190: IF (NOT AP_WEB_DB_EXPRPT_PKG.SetWkflApprvdFlagAndSource(l_report_header_id,
11191: AP_WEB_DB_EXPRPT_PKG.C_WORKFLOW_APPROVED_RETURNED,
11192: 'NonValidatedWebExpense')) THEN
11193: NULL;
11194: END IF;
11195:

Line 11644: l_document_number AP_WEB_DB_EXPRPT_PKG.expHdr_invNum;

11640: p_rep_header_id IN AP_EXPENSE_REPORT_LINES.report_header_id%TYPE)
11641: IS
11642: l_itemkey wf_items.item_key%TYPE;
11643: l_itemtype wf_items.item_type%TYPE := 'APEXP';
11644: l_document_number AP_WEB_DB_EXPRPT_PKG.expHdr_invNum;
11645: l_doc_cctr VARCHAR2(2000);
11646: l_preparer_name VARCHAR2(2000);
11647: l_employee_name VARCHAR2(2000);
11648: l_purpose VARCHAR2(2400);

Line 11764: IF (NOT AP_WEB_DB_EXPRPT_PKG.SetWkflApprvdFlagAndSource(p_rep_header_id,

11760: end if;
11761:
11762:
11763: l_debug_info := 'Set withdraw status in report header';
11764: IF (NOT AP_WEB_DB_EXPRPT_PKG.SetWkflApprvdFlagAndSource(p_rep_header_id,
11765: AP_WEB_DB_EXPRPT_PKG.C_WORKFLOW_APPROVED_WITHDRAW,
11766: 'NonValidatedWebExpense')) THEN
11767: NULL;
11768: END IF;

Line 11765: AP_WEB_DB_EXPRPT_PKG.C_WORKFLOW_APPROVED_WITHDRAW,

11761:
11762:
11763: l_debug_info := 'Set withdraw status in report header';
11764: IF (NOT AP_WEB_DB_EXPRPT_PKG.SetWkflApprvdFlagAndSource(p_rep_header_id,
11765: AP_WEB_DB_EXPRPT_PKG.C_WORKFLOW_APPROVED_WITHDRAW,
11766: 'NonValidatedWebExpense')) THEN
11767: NULL;
11768: END IF;
11769:

Line 12169: IF (AP_WEB_DB_EXPRPT_PKG.GetOrgIdByReportHeaderId(

12165: when others then
12166: if (wf_core.error_name = 'WFENG_ITEM_ATTR') then
12167: -- ORG_ID item attribute doesn't exist, need to add it
12168: WF_ENGINE.AddItemAttr(l_itemtype, l_itemkey, 'ORG_ID');
12169: IF (AP_WEB_DB_EXPRPT_PKG.GetOrgIdByReportHeaderId(
12170: to_number(l_itemkey),
12171: l_n_org_id) <> TRUE ) THEN
12172: l_n_org_id := NULL;
12173: END IF;

Line 12195: IF (AP_WEB_DB_EXPRPT_PKG.GetOrgIdByReportHeaderId(to_number(l_itemkey), l_n_org_id) <> TRUE ) THEN

12191: else
12192: -- Report was submitted before org_id being added, hence org_id
12193: -- item attributes hasn't been set yet. Need to get it from
12194: -- report header
12195: IF (AP_WEB_DB_EXPRPT_PKG.GetOrgIdByReportHeaderId(to_number(l_itemkey), l_n_org_id) <> TRUE ) THEN
12196: l_n_org_id := NULL;
12197: END IF;
12198:
12199: IF (l_n_org_id is not null) then

Line 12225: IF (NOT AP_WEB_DB_EXPRPT_PKG.getPaymentDueFromReport(to_number(l_itemkey),l_payment)) THEN

12221: ----------------------------------------------------------------
12222: l_debug_info := 'Retrieve Profile Option Payment Due From';
12223: ----------------------------------------------------------------
12224:
12225: IF (NOT AP_WEB_DB_EXPRPT_PKG.getPaymentDueFromReport(to_number(l_itemkey),l_payment)) THEN
12226: l_debug_info := 'Could not set workflow attribute Payment_Due_From';
12227: END IF;
12228:
12229: IF (l_payment = 'BOTH' and l_num_both_personal_lines > 0) THEN

Line 12839: IF (NOT AP_WEB_DB_EXPRPT_PKG.getPaymentDueFromReport(l_report_header_id,l_payment)) THEN

12835:
12836: --------------------------------------------
12837: l_debug_info := 'Check to see if Both Pay scenario';
12838: --------------------------------------------
12839: IF (NOT AP_WEB_DB_EXPRPT_PKG.getPaymentDueFromReport(l_report_header_id,l_payment)) THEN
12840: l_debug_info := 'Could not set workflow attribute Payment_Due_From';
12841: END IF;
12842: if (l_show_message = 'N' AND C_BothPay = l_payment) then
12843: --------------------------------------------

Line 13790: l_reimb_curr AP_WEB_DB_EXPRPT_PKG.expHdr_payemntCurrCode;

13786: l_base_min_acct_unit NUMBER;
13787: l_total NUMBER;
13788: l_total_dsp VARCHAR2(50);
13789: l_bHeaderUpdated BOOLEAN := FALSE;
13790: l_reimb_curr AP_WEB_DB_EXPRPT_PKG.expHdr_payemntCurrCode;
13791: l_over_threshold_distance NUMBER := 0;
13792: l_sh_distance_thresholds_flag VARCHAR2(1);
13793:
13794: l_report_header_info AP_WEB_DFLEX_PKG.ExpReportHeaderRec;

Line 14183: IF (NOT AP_WEB_DB_EXPRPT_PKG.UpdateHeaderTotal(l_report_header_id)) THEN

14179: -----------------------------------------------------------------------
14180: l_debug_info := 'update display_total item attribute if ap_expense_report_headers has been updated';
14181: -----------------------------------------------------------------------
14182: IF (l_bHeaderUpdated = TRUE) THEN
14183: IF (NOT AP_WEB_DB_EXPRPT_PKG.UpdateHeaderTotal(l_report_header_id)) THEN
14184: NULL;
14185: END IF;
14186:
14187: IF (NOT AP_WEB_DB_EXPRPT_PKG.GetHeaderTotal(l_report_header_id,

Line 14187: IF (NOT AP_WEB_DB_EXPRPT_PKG.GetHeaderTotal(l_report_header_id,

14183: IF (NOT AP_WEB_DB_EXPRPT_PKG.UpdateHeaderTotal(l_report_header_id)) THEN
14184: NULL;
14185: END IF;
14186:
14187: IF (NOT AP_WEB_DB_EXPRPT_PKG.GetHeaderTotal(l_report_header_id,
14188: l_total)) THEN
14189: NULL;
14190: END IF;
14191:

Line 14192: IF (NOT AP_WEB_DB_EXPRPT_PKG.GetReimbCurr(l_report_header_id,

14188: l_total)) THEN
14189: NULL;
14190: END IF;
14191:
14192: IF (NOT AP_WEB_DB_EXPRPT_PKG.GetReimbCurr(l_report_header_id,
14193: l_reimb_curr)) THEN
14194:
14195: NULL;
14196: END IF;

Line 14225: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;

14221: p_result OUT NOCOPY VARCHAR2) IS
14222: -------------------------------------------------------------------------------
14223: l_debug_info VARCHAR2(200);
14224: l_violations_count NUMBER:=0;
14225: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
14226: BEGIN
14227:
14228:
14229: AP_WEB_UTILITIES_PKG.logProcedure('AP_WEB_EXPENSE_WF', 'start hasCompanyViolations');

Line 14427: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;

14423: BETWEEN TRUNC(NVL(rsa.START_DATE,SYSDATE))
14424: AND TRUNC(NVL(rsa.END_DATE,SYSDATE));
14425:
14426: l_debug_info VARCHAR2(200);
14427: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
14428: audit_rec audit_cur%ROWTYPE;
14429: rule_rec rule_cur%ROWTYPE;
14430: recpt_rec recpt_cur%ROWTYPE;
14431: l_image_receipts_status VARCHAR2(30);

Line 14846: l_document_number AP_WEB_DB_EXPRPT_PKG.expHdr_invNum;

14842: p_result OUT NOCOPY VARCHAR2) IS
14843: ------------------------------------------------------------------------
14844: l_debug_info VARCHAR2(2000);
14845: l_mess Wf_Item_Attribute_Values.TEXT_VALUE%TYPE;
14846: l_document_number AP_WEB_DB_EXPRPT_PKG.expHdr_invNum;
14847: l_preparer_name VARCHAR2(2000);
14848: BEGIN
14849:
14850: AP_WEB_UTILITIES_PKG.logProcedure('AP_WEB_EXPENSE_WF', 'start SetProvideMissingInfo');

Line 14939: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;

14935: p_actid IN NUMBER,
14936: p_funmode IN VARCHAR2,
14937: p_result OUT NOCOPY VARCHAR2) IS
14938: ----------------------------------------------------------------------
14939: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
14940: l_workflow_approved_flag AP_WEB_DB_EXPRPT_PKG.expHdr_wkflApprvdFlag;
14941:
14942: l_return_reason VARCHAR2(80);
14943: l_return_instruction Wf_Item_Attribute_Values.TEXT_VALUE%TYPE;

Line 14940: l_workflow_approved_flag AP_WEB_DB_EXPRPT_PKG.expHdr_wkflApprvdFlag;

14936: p_funmode IN VARCHAR2,
14937: p_result OUT NOCOPY VARCHAR2) IS
14938: ----------------------------------------------------------------------
14939: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
14940: l_workflow_approved_flag AP_WEB_DB_EXPRPT_PKG.expHdr_wkflApprvdFlag;
14941:
14942: l_return_reason VARCHAR2(80);
14943: l_return_instruction Wf_Item_Attribute_Values.TEXT_VALUE%TYPE;
14944:

Line 14968: if (not AP_WEB_DB_EXPRPT_PKG.getAuditReturnReasonInstr(l_report_header_id,

14964:
14965: ------------------------------------------------------------
14966: l_debug_info := 'Retrieve Return Reason and Instruction';
14967: ------------------------------------------------------------
14968: if (not AP_WEB_DB_EXPRPT_PKG.getAuditReturnReasonInstr(l_report_header_id,
14969: l_return_reason,
14970: l_return_instruction)) then
14971: l_debug_info := 'Could not retrieve Return Reason and Instruction';
14972: end if;

Line 15006: IF (l_workflow_approved_flag = AP_WEB_DB_EXPRPT_PKG.C_WORKFLOW_APPROVED_REJECTED) THEN

15002: INTO l_workflow_approved_flag
15003: FROM AP_EXPENSE_REPORT_HEADERS
15004: WHERE REPORT_HEADER_ID = l_report_header_id;
15005:
15006: IF (l_workflow_approved_flag = AP_WEB_DB_EXPRPT_PKG.C_WORKFLOW_APPROVED_REJECTED) THEN
15007: p_result := 'COMPLETE:REJECTED';
15008: ELSIF (l_workflow_approved_flag = AP_WEB_DB_EXPRPT_PKG.C_WORKFLOW_APPROVED_REQUEST) THEN
15009: p_result := 'COMPLETE:REQUEST_MORE_INFO';
15010: ELSE

Line 15008: ELSIF (l_workflow_approved_flag = AP_WEB_DB_EXPRPT_PKG.C_WORKFLOW_APPROVED_REQUEST) THEN

15004: WHERE REPORT_HEADER_ID = l_report_header_id;
15005:
15006: IF (l_workflow_approved_flag = AP_WEB_DB_EXPRPT_PKG.C_WORKFLOW_APPROVED_REJECTED) THEN
15007: p_result := 'COMPLETE:REJECTED';
15008: ELSIF (l_workflow_approved_flag = AP_WEB_DB_EXPRPT_PKG.C_WORKFLOW_APPROVED_REQUEST) THEN
15009: p_result := 'COMPLETE:REQUEST_MORE_INFO';
15010: ELSE
15011: p_result := 'COMPLETE:REVIEWED';
15012: END IF;

Line 15043: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;

15039: p_actid IN NUMBER,
15040: p_funmode IN VARCHAR2,
15041: p_result OUT NOCOPY VARCHAR2) IS
15042: ----------------------------------------------------------------------
15043: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
15044: l_debug_info VARCHAR2(200);
15045: l_manager_approved VARCHAR2(5);
15046: l_workflow_flag VARCHAR2(5);
15047:

Line 15094: IF (NOT AP_WEB_DB_EXPRPT_PKG.SetWkflApprvdFlagAndSource(l_report_header_id,

15090:
15091: ----------------------------------------------------------------------
15092: l_debug_info := 'Update the Expense Report as Mgr Approved so that it can be auditable';
15093: ----------------------------------------------------------------------
15094: IF (NOT AP_WEB_DB_EXPRPT_PKG.SetWkflApprvdFlagAndSource(l_report_header_id,
15095: l_workflow_flag, NULL)) THEN
15096: NULL;
15097: END IF;
15098:

Line 15148: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;

15144: p_actid IN NUMBER,
15145: p_funmode IN VARCHAR2,
15146: p_result OUT NOCOPY VARCHAR2) IS
15147: ----------------------------------------------------------------------
15148: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
15149: l_debug_info VARCHAR2(200);
15150: BEGIN
15151:
15152: AP_WEB_UTILITIES_PKG.logProcedure('AP_WEB_EXPENSE_WF', 'start RemoveFromAuditQueue');

Line 15215: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;

15211: p_actid IN NUMBER,
15212: p_funmode IN VARCHAR2,
15213: p_result IN OUT NOCOPY VARCHAR2) IS
15214: ----------------------------------------------------------------------
15215: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
15216: l_debug_info VARCHAR2(200);
15217:
15218: l_message_name fnd_new_messages.message_name%type;
15219: l_result_type varchar2(80);

Line 15469: AP_WEB_DB_EXPRPT_PKG.clearAuditReturnReasonInstr(l_report_header_id);

15465: if (l_result_type <> 'WFSTD_APPROVAL') then
15466: ------------------------------------------------------------
15467: l_debug_info := 'clear the header/line level return/audit reason/instructions in AERH/AERL';
15468: ------------------------------------------------------------
15469: AP_WEB_DB_EXPRPT_PKG.clearAuditReturnReasonInstr(l_report_header_id);
15470: AP_WEB_DB_EXPLINE_PKG.clearAuditReturnReasonInstr(l_report_header_id);
15471:
15472: ----------------------------------------------------------
15473: l_debug_info := 'clear Item Attribute AUDIT_RETURN_REASON';

Line 16210: IF (NOT AP_WEB_DB_EXPRPT_PKG.getPaymentDueFromReport(p_item_key,l_payment)) THEN

16206:
16207: ----------------------------------------------------------------
16208: l_debug_info := 'Retrieve Profile Option Payment Due From';
16209: ----------------------------------------------------------------
16210: IF (NOT AP_WEB_DB_EXPRPT_PKG.getPaymentDueFromReport(p_item_key,l_payment)) THEN
16211: l_debug_info := 'Could not set workflow attribute Payment_Due_From';
16212: END IF;
16213:
16214: IF (l_payment = 'BOTH' and l_num_personal_lines > 0 ) THEN

Line 17315: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;

17311: p_actid IN NUMBER,
17312: p_funmode IN VARCHAR2,
17313: p_result OUT NOCOPY VARCHAR2) IS
17314: ----------------------------------------------------------------------
17315: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
17316: l_req_mgr_appr VARCHAR2(1);
17317: l_img_recpt_status VARCHAR2(30);
17318: BEGIN
17319: IF (p_funmode = 'RUN') THEN

Line 17377: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;

17373: p_funmode IN VARCHAR2,
17374: p_result OUT NOCOPY VARCHAR2) IS
17375: ----------------------------------------------------------------------
17376: l_re_appr_flag VARCHAR2(1);
17377: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
17378: BEGIN
17379:
17380: IF (p_funmode = 'RUN') THEN
17381: l_report_header_id := WF_ENGINE.GetItemAttrNumber(p_item_type,

Line 17423: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;

17419: p_funmode IN VARCHAR2,
17420: p_result OUT NOCOPY VARCHAR2) IS
17421: ----------------------------------------------------------------------
17422:
17423: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
17424: l_image_receipts_status VARCHAR2(50);
17425: BEGIN
17426:
17427: IF (p_funmode = 'RUN') THEN

Line 17457: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;

17453: p_funmode IN VARCHAR2,
17454: p_result OUT NOCOPY VARCHAR2) IS
17455: ----------------------------------------------------------------------
17456:
17457: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
17458: l_orig_receipts_status VARCHAR2(50);
17459: BEGIN
17460:
17461: IF (p_funmode = 'RUN') THEN

Line 17493: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;

17489: p_funmode IN VARCHAR2,
17490: p_result OUT NOCOPY VARCHAR2) IS
17491: ----------------------------------------------------------------------
17492:
17493: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
17494: l_expense_status_code VARCHAR2(50);
17495: BEGIN
17496:
17497: IF (p_funmode = 'RUN') THEN

Line 17534: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;

17530: l_shortpay_count number;
17531: l_policy_count number;
17532: l_img_count number;
17533: l_both_count number;
17534: l_report_header_id AP_WEB_DB_EXPRPT_PKG.expHdr_headerID;
17535: BEGIN
17536: IF (p_funmode = 'RUN') THEN
17537: l_report_header_id := WF_ENGINE.GetItemAttrNumber(p_item_type,
17538: p_item_key,