DBA Data[Home] [Help]

APPS.CS_SR_RES_CODE_MAPPING_PKG dependencies on CS_SR_RES_CODE_MAPPING

Line 1: PACKAGE BODY CS_SR_RES_CODE_MAPPING_PKG AS

1: PACKAGE BODY CS_SR_RES_CODE_MAPPING_PKG AS
2: /* $Header: csxrscdb.pls 120.0 2005/12/12 16:12:29 smisra noship $ */
3:
4: PROCEDURE VALIDATE_RESOLUTION_CODE
5: ( p_api_version IN NUMBER,

Line 7: p_rescode_criteria_rec IN CS_SR_RES_CODE_MAPPING_PKG.rescode_search_rec,

3:
4: PROCEDURE VALIDATE_RESOLUTION_CODE
5: ( p_api_version IN NUMBER,
6: p_init_msg_list IN VARCHAR2,
7: p_rescode_criteria_rec IN CS_SR_RES_CODE_MAPPING_PKG.rescode_search_rec,
8: p_resolution_code IN VARCHAR2,
9: x_return_status OUT NOCOPY VARCHAR2,
10: x_msg_count OUT NOCOPY NUMBER,
11: x_msg_data OUT NOCOPY VARCHAR2

Line 57: cs_sr_res_code_mapping_detail cstl

53: cslkup.lookup_type='REQUEST_RESOLUTION_CODE' and
54: cslkup.lookup_code = l_resolution_code and
55: not exists
56: ( select 'X' from
57: cs_sr_res_code_mapping_detail cstl
58: where
59: cstl.resolution_code = cslkup.lookup_code and
60: (cstl.map_start_date_active is null or trunc(cstl.map_start_date_active) <= trunc(sysdate)) and
61: (cstl.map_end_date_active is null or trunc(cstl.map_end_date_active) >= trunc(sysdate)) and

Line 89: cs_sr_res_code_mapping_detail cstl

85: cslkup.lookup_type='REQUEST_RESOLUTION_CODE' and
86: cslkup.lookup_code = l_resolution_code and
87: exists
88: ( select 'X' from
89: cs_sr_res_code_mapping_detail cstl
90: where
91: cstl.resolution_code = cslkup.lookup_code and
92: (cstl.map_start_date_active is null or trunc(cstl.map_start_date_active) <= trunc(sysdate)) and
93: (cstl.map_end_date_active is null or trunc(cstl.map_end_date_active) >= trunc(sysdate)) and

Line 153: cs_sr_res_code_mapping_detail cstl

149: cslkup.lookup_type='REQUEST_RESOLUTION_CODE' and
150: cslkup.lookup_code = l_resolution_code and
151: exists
152: ( select 'X' from
153: cs_sr_res_code_mapping_detail cstl
154: where
155: cstl.resolution_code = cslkup.lookup_code and
156: (cstl.map_start_date_active is null or trunc(cstl.map_start_date_active) <= trunc(sysdate)) and
157: (cstl.map_end_date_active is null or trunc(cstl.map_end_date_active) >= trunc(sysdate)) and

Line 187: cs_sr_res_code_mapping_detail cstl

183: cslkup.lookup_type='REQUEST_RESOLUTION_CODE' and
184: cslkup.lookup_code = l_resolution_code and
185: exists
186: ( select 'X' from
187: cs_sr_res_code_mapping_detail cstl
188: where
189: cstl.resolution_code = cslkup.lookup_code and
190: (cstl.map_start_date_active is null or trunc(cstl.map_start_date_active) <= trunc(sysdate)) and
191: (cstl.map_end_date_active is null or trunc(cstl.map_end_date_active) >= trunc(sysdate)) and

Line 228: cs_sr_res_code_mapping_detail cstl

224: cslkup.lookup_type='REQUEST_RESOLUTION_CODE' and
225: cslkup.lookup_code = l_resolution_code and
226: exists
227: ( select 'X' from
228: cs_sr_res_code_mapping_detail cstl
229: where
230: cstl.resolution_code = cslkup.lookup_code and
231: (cstl.map_start_date_active is null or trunc(cstl.map_start_date_active) <= trunc(sysdate)) and
232: (cstl.map_end_date_active is null or trunc(cstl.map_end_date_active) >= trunc(sysdate)) and

Line 269: cs_sr_res_code_mapping_detail cstl

265: cslkup.lookup_type='REQUEST_RESOLUTION_CODE' and
266: cslkup.lookup_code = l_resolution_code and
267: exists
268: ( select 'X' from
269: cs_sr_res_code_mapping_detail cstl
270: where
271: cstl.resolution_code = cslkup.lookup_code and
272: (cstl.map_start_date_active is null or trunc(cstl.map_start_date_active) <= trunc(sysdate)) and
273: (cstl.map_end_date_active is null or trunc(cstl.map_end_date_active) >= trunc(sysdate)) and

Line 323: cs_sr_res_code_mapping_detail cstl

319: cslkup.lookup_type='REQUEST_RESOLUTION_CODE' and
320: cslkup.lookup_code = l_resolution_code and
321: exists
322: ( select 'X' from
323: cs_sr_res_code_mapping_detail cstl
324: where
325: cstl.resolution_code = cslkup.lookup_code and
326: (cstl.map_start_date_active is null or trunc(cstl.map_start_date_active) <= trunc(sysdate)) and
327: (cstl.map_end_date_active is null or trunc(cstl.map_end_date_active) >= trunc(sysdate)) and

Line 640: FND_MSG_PUB.Add_Exc_Msg('CS_SR_RES_CODE_MAPPING_PKG', l_api_name);

636: END IF;
637:
638: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
639: IF FND_MSG_PUB.Check_Msg_Level(FND_MSG_PUB.G_MSG_LVL_UNEXP_ERROR) THEN
640: FND_MSG_PUB.Add_Exc_Msg('CS_SR_RES_CODE_MAPPING_PKG', l_api_name);
641: END IF;
642: FND_MSG_PUB.Count_And_Get
643: ( p_count => x_msg_count,
644: p_data => x_msg_data

Line 693: SELECT resolution_map_id,start_date_active, end_date_active from cs_sr_res_code_mapping

689:
690: l_res_code_index BINARY_INTEGER;
691:
692: CURSOR c_sr_criteria_exists_csr IS
693: SELECT resolution_map_id,start_date_active, end_date_active from cs_sr_res_code_mapping
694: WHERE incident_type_id = l_service_request_type_id
695: AND category_id = l_product_category_id
696: AND inventory_item_id = l_inventory_item_id
697: AND organization_id = l_organization_id

Line 719: SELECT resolution_map_detail_id,start_date_active, end_date_active from cs_sr_res_code_mapping_detail

715: (end_date_active is null or
716: trunc(end_date_active) >= trunc(sysdate));
717:
718: CURSOR c_sr_res_code_map_exists_csr IS
719: SELECT resolution_map_detail_id,start_date_active, end_date_active from cs_sr_res_code_mapping_detail
720: WHERE resolution_map_id = l_resolution_map_id
721: AND resolution_code = l_resolution_code
722: AND (start_date_active is null or trunc(start_date_active) <= trunc(sysdate)) and
723: (end_date_active is null or trunc(end_date_active) >= trunc(sysdate));

Line 744: #4) the search criteria should not already be present in the cs_sr_res_code_mapping table

740: /* The following validation checks will be executed on the search criteria:
741: #1) the product categroy and product cannot be part of the same search criteria
742: #2) all search criteria attributes should NOT be null in the search criteria
743: #3) Organization Id cannot be null if product is not null
744: #4) the search criteria should not already be present in the cs_sr_res_code_mapping table
745: #5) the product category of the new search criteria, if passed, should belong to the default category set
746: whose value is held in the profile option - CS_SR_DEFAULT_CATEGORY_SET
747: #6) the start date of the new search criteria should NOT be greater than the end date
748: */

Line 810: cs_sr_res_code_MAPPING table */

806: RAISE fnd_api.g_exc_unexpected_error;
807: END IF;
808:
809: /* All validations have passed for the search criteria. Hence we can create a search criteria record in
810: cs_sr_res_code_MAPPING table */
811: CS_SR_RESOLUTION_CODE_MAP_PKG.INSERT_ROW (
812: PX_RESOLUTION_MAP_ID => l_resolution_map_id,
813: P_INCIDENT_TYPE_ID => l_service_request_type_id,
814: P_INVENTORY_ITEM_ID => l_inventory_item_id,

Line 851: CS_SR_RES_CODE_MAPPING_DETAIL table */

847: RAISE fnd_api.g_exc_unexpected_error;
848: END IF;
849:
850: /* Now, we need to create the actual resolution code -> search criteria mapping details in
851: CS_SR_RES_CODE_MAPPING_DETAIL table */
852:
853: /* First, the following validation checks :
854: #1) the resolution code should be a CS lookup code with lookup type = 'REQUEST_RESOLUTION_CODE'
855: #2) the resolution code mapping should not already be present. Though this is creation API, it is

Line 893: /* We can create the resolution code mapping in cs_sr_res_code_MAPPING_DETAIL table now */

889: l_start_date_active >= l_end_date_active) THEN
890: RAISE fnd_api.g_exc_unexpected_error;
891: END IF;
892:
893: /* We can create the resolution code mapping in cs_sr_res_code_MAPPING_DETAIL table now */
894: CS_SR_RES_CODE_MAP_DETAIL_PKG.INSERT_ROW (
895: PX_RESOLUTION_MAP_DETAIL_ID => l_resolution_map_detail_id,
896: P_RESOLUTION_MAP_ID => l_resolution_map_id,
897: P_INCIDENT_TYPE_ID => l_service_request_type_id,

Line 999: FND_MSG_PUB.Add_Exc_Msg('CS_SR_RES_CODE_MAPPING_PKG', l_api_name);

995:
996: ROLLBACK TO create_mapping_rules;
997: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
998: IF FND_MSG_PUB.Check_Msg_Level(FND_MSG_PUB.G_MSG_LVL_UNEXP_ERROR) THEN
999: FND_MSG_PUB.Add_Exc_Msg('CS_SR_RES_CODE_MAPPING_PKG', l_api_name);
1000: END IF;
1001: FND_MSG_PUB.Count_And_Get
1002: ( p_count => x_msg_count,
1003: p_data => x_msg_data

Line 1053: FROM CS_SR_RES_CODE_MAPPING

1049:
1050:
1051: CURSOR cs_sr_resmapid_crit_csr IS
1052: SELECT incident_type_id,category_id,inventory_item_id,problem_code,organization_id
1053: FROM CS_SR_RES_CODE_MAPPING
1054: WHERE resolution_map_id = l_resolution_map_id
1055: AND (start_date_active is null or trunc(start_date_active) <= trunc(sysdate)) and
1056: (end_date_active is null or trunc(end_date_active) >= trunc(sysdate));
1057:

Line 1064: FROM CS_SR_RES_CODE_MAPPING

1060:
1061:
1062: CURSOR cs_sr_resmapid_exists_csr IS
1063: SELECT resolution_map_id,incident_type_id,category_id,inventory_item_id,problem_code,organization_id
1064: FROM CS_SR_RES_CODE_MAPPING
1065: WHERE resolution_map_id <> l_resolution_map_id AND
1066: incident_type_id = l_service_request_type_id AND
1067: category_id = l_product_category_id AND
1068: inventory_item_id = l_inventory_item_id AND

Line 1087: SELECT resolution_code,start_date_active,end_date_active from CS_SR_RES_CODE_MAPPING_DETAIL

1083: (end_date_active is null or
1084: trunc(end_date_active) >= trunc(sysdate));
1085:
1086: CURSOR cs_sr_rescode_mapped_csr IS
1087: SELECT resolution_code,start_date_active,end_date_active from CS_SR_RES_CODE_MAPPING_DETAIL
1088: WHERE resolution_map_id = l_resolution_map_id and
1089: resolution_map_detail_id <> l_resolution_map_detail_id and
1090: resolution_code = l_resolution_code and
1091: (start_date_active is null or

Line 1356: FROM CS_SR_RES_CODE_MAPPING;

1352: l_res_code_index BINARY_INTEGER;
1353:
1354: CURSOR cs_sr_resmapid_crit_csr IS
1355: SELECT resolution_map_id, start_date_active, end_date_active
1356: FROM CS_SR_RES_CODE_MAPPING;
1357: cs_sr_resmapid_crit_rec cs_sr_resmapid_crit_csr%ROWTYPE;
1358:
1359:
1360: CURSOR cs_sr_resmapid_rules_csr IS

Line 1366: FROM CS_SR_RES_CODE_MAPPING_DETAIL

1362: map_start_date_active, map_end_date_active,
1363: start_date_active, end_date_active,
1364: incident_type_id, inventory_item_id, organization_id,
1365: category_id, problem_code, resolution_code
1366: FROM CS_SR_RES_CODE_MAPPING_DETAIL
1367: WHERE
1368: resolution_map_id = l_resolution_map_id;
1369: cs_sr_resmapid_rules_rec cs_sr_resmapid_rules_csr%ROWTYPE;
1370:

Line 1394: update CS_SR_RES_CODE_MAPPING_DETAIL

1390:
1391: IF(cs_sr_resmapid_crit_rec.start_date_active is not null AND
1392: nvl(cs_sr_resmapid_rules_rec.map_start_date_active, cs_sr_resmapid_crit_rec.start_date_active+1) <> cs_sr_resmapid_crit_rec.start_date_active) THEN
1393:
1394: update CS_SR_RES_CODE_MAPPING_DETAIL
1395: set
1396: map_start_date_active = cs_sr_resmapid_crit_rec.start_date_active,
1397: map_end_date_active = cs_sr_resmapid_crit_rec.end_date_active
1398: where

Line 1404: update CS_SR_RES_CODE_MAPPING_DETAIL

1400: ELSIF (cs_sr_resmapid_crit_rec.start_date_active is null AND
1401: cs_sr_resmapid_crit_rec.end_date_active is not null AND
1402: nvl(cs_sr_resmapid_rules_rec.map_end_date_active, cs_sr_resmapid_crit_rec.end_date_active+1) <> cs_sr_resmapid_crit_rec.end_date_active) THEN
1403:
1404: update CS_SR_RES_CODE_MAPPING_DETAIL
1405: set
1406: map_start_date_active = cs_sr_resmapid_crit_rec.start_date_active,
1407: map_end_date_active = cs_sr_resmapid_crit_rec.end_date_active
1408: where

Line 1495: END; -- Package Body CS_SR_RES_CODE_MAPPING_PKG

1491:
1492:
1493:
1494: -- Enter further code below as specified in the Package spec.
1495: END; -- Package Body CS_SR_RES_CODE_MAPPING_PKG