# Business Logic — JKKAdchgCancelHakkoSODCC.editErrorInfo_EKK1081D010CBS() [184 LOC]

| Field | Value |
|-------|-------|
| Fully Qualified Name | `com.fujitsu.futurity.bp.custom.common.JKKAdchgCancelHakkoSODCC` |
| Layer | CC/Common Component (shared business logic class for telecom order processing) |
| Module | `common` (Package: `com.fujitsu.futurity.bp.custom.common`) |

## 1. Role

### JKKAdchgCancelHakkoSODCC.editErrorInfo_EKK1081D010CBS()

This method is the **error information extraction and propagation utility** for the Order Condition Registration service flow (Joken Touro). It operates within the Fujitsu Futurity Order Data (SOD) pipeline, specifically after a Service Component (SC) CBS call for order condition registration has completed. The Javadoc describes it as: "Obtain service interface processing results (error information) for order condition registration" (サービスインターフェイス処理結果(エラー情報)の取得（オーダ発行条件登録）).

The method performs a **delegation pattern** with three distinct responsibilities. First, it performs **error status prioritization** by comparing the CBS template status code against the existing Business Program (BP) return code, and only overwrites the status and message when the template's error severity is higher (templateStatus > bpStatus). When the CBS return code is non-zero, the status is forced to `9000`, indicating a CBS invocation failure. A validation gate checks the formatted status against the `JCMAPLConstMgr` constants dictionary; if the return message key does not exist, the status is reset to `0` (success/no error).

Second, the method ensures **work area and data map initialization**, creating `HashMap` instances for both the mapping work area and the HAKKOSODCC work map if they do not already exist.

Third, it executes **structured error field extraction** across 17 distinct error fields from the CAANMsg template. These fields span service contract identifiers, order classification codes, equipment details, and system identifiers. For each field, if the template contains a non-null error value and the error key has not already been recorded in the work map, the value is copied into the work map. This deduplication logic ensures that the first error encountered takes precedence, preventing later identical errors from overwriting earlier ones. The method acts as a **shared utility** called by `editResultRP_EKK1081D010CBS` across all four order-related CC classes (`JKKAdchgCancelHakkoSODCC`, `JKKAdchgHakkoSODCC`, `JKKHakkoSODCC`, `JKKKikiDslAddCC`), making it a central component of the post-CBS error handling chain.

## 2. Processing Pattern (Detailed Business Logic)

```mermaid
flowchart TD
    START(["editErrorInfo_EKK1081D010CBS"])
    START --> GET_TEMPLATE["Get first CAANMsg template from templates array"]
    GET_TEMPLATE --> GET_STATUS["templateStatus = template.getInt(EKK1081D010CBSMsg.STATUS)"]
    GET_STATUS --> CHECK_RETURN{returnCode != 0?}
    CHECK_RETURN -->|Yes| SET_STATUS["templateStatus = 9000 (CBS invocation failure)"]
    CHECK_RETURN -->|No| CHECK_MSG{JCMAPLConstMgr.getString(RETURN_MESSAGE_XXXX) valid?}
    SET_STATUS --> CHECK_MSG
    CHECK_MSG -->|No| RESET_STATUS["templateStatus = 0 (no valid message for status)"]
    CHECK_MSG -->|Yes| GET_BP_STATUS
    RESET_STATUS --> GET_BP_STATUS
    GET_BP_STATUS["bpStatus = Integer.parseInt(RETURN_CODE from controlMapData)"]
    GET_BP_STATUS --> CHECK_BETTER{templateStatus > bpStatus?}
    CHECK_BETTER -->|No| INIT_WORKMAP
    CHECK_BETTER -->|Yes| FORMAT_STATUS["formatStatus = zero-padded templateStatus"]
    FORMAT_STATUS --> GET_MSG["message = JCMAPLConstMgr.getString(RETURN_MESSAGE + formatStatus)"]
    GET_MSG --> SET_CONTROL["setControlMapData(RETURN_CODE, formatStatus)"]
    SET_CONTROL --> SET_MSG["setControlMapData(RETURN_MESSAGE, message)"]
    SET_MSG --> INIT_WORKMAP
    INIT_WORKMAP["workMap = getMappingWorkArea or new HashMap"]
    INIT_WORKMAP --> INIT_INMAP["inMap = getData(HAKKOSODCCWORKMAP) or new HashMap"]
    INIT_INMAP --> FIELD_LOOP["Process 17 error fields"]
    FIELD_LOOP --> FIELD1{field1: SVC_KEI_NO_ERR not null?}
    FIELD1 -->|Yes| KEY1{key not in inMap?}
    KEY1 -->|Yes| PUT1["inMap.put(svc_kei_no_err, value)"]
    KEY1 -->|No| SKIP1["skip (already recorded)"]
    PUT1 --> FIELD2
    SKIP1 --> FIELD2
    FIELD1 -->|No| FIELD2
    FIELD2{field2: SVC_KEI_UCWK_NO_ERR not null?}
    FIELD2 -->|Yes| KEY2{key not in inMap?}
    KEY2 -->|Yes| PUT2["inMap.put(svc_kei_ucwk_no_err, value)"]
    KEY2 -->|No| SKIP2["skip (already recorded)"]
    PUT2 --> FIELD3
    SKIP2 --> FIELD3
    FIELD2 -->|No| FIELD3
    FIELD3{field3: KKTK_SVC_KEI_NO_ERR not null?}
    FIELD3 -->|Yes| KEY3{key not in inMap?}
    KEY3 -->|Yes| PUT3["inMap.put(kktk_svc_kei_no_err, value)"]
    KEY3 -->|No| SKIP3["skip (already recorded)"]
    PUT3 --> FIELD4
    SKIP3 --> FIELD4
    FIELD3 -->|No| FIELD4
    FIELD4{field4: OP_SVC_KEI_NO_ERR not null?}
    FIELD4 -->|Yes| KEY4{key not in inMap?}
    KEY4 -->|Yes| PUT4["inMap.put(op_svc_kei_no_err, value)"]
    KEY4 -->|No| SKIP4["skip (already recorded)"]
    PUT4 --> FIELD5
    SKIP4 --> FIELD5
    FIELD4 -->|No| FIELD5
    FIELD5{field5: SBOP_SVC_KEI_NO_ERR not null?}
    FIELD5 -->|Yes| KEY5{key not in inMap?}
    KEY5 -->|Yes| PUT5["inMap.put(sbop_svc_kei_no_err, value)"]
    KEY5 -->|No| SKIP5["skip (already recorded)"]
    PUT5 --> FIELD6
    SKIP5 --> FIELD6
    FIELD5 -->|No| FIELD6
    FIELD6{field6: SEIOPSVC_KEI_NO_ERR not null?}
    FIELD6 -->|Yes| KEY6{key not in inMap?}
    KEY6 -->|Yes| PUT6["inMap.put(seiopsvc_kei_no_err, value)"]
    KEY6 -->|No| SKIP6["skip (already recorded)"]
    PUT6 --> FIELD7
    SKIP6 --> FIELD7
    FIELD6 -->|No| FIELD7
    FIELD7{field7: ORDER_SBT_CD_ERR not null?}
    FIELD7 -->|Yes| KEY7{key not in inMap?}
    KEY7 -->|Yes| PUT7["inMap.put(order_sbt_cd_err, value)"]
    KEY7 -->|No| SKIP7["skip (already recorded)"]
    PUT7 --> FIELD8
    SKIP7 --> FIELD8
    FIELD7 -->|No| FIELD8
    FIELD8{field8: SVC_ORDER_CD_ERR not null?}
    FIELD8 -->|Yes| KEY8{key not in inMap?}
    KEY8 -->|Yes| PUT8["inMap.put(svc_order_cd_err, value)"]
    KEY8 -->|No| SKIP8["skip (already recorded)"]
    PUT8 --> FIELD9
    SKIP8 --> FIELD9
    FIELD8 -->|No| FIELD9
    FIELD9{field9: YOKYU_SBT_CD_ERR not null?}
    FIELD9 -->|Yes| KEY9{key not in inMap?}
    KEY9 -->|Yes| PUT9["inMap.put(yokyu_sbt_cd_err, value)"]
    KEY9 -->|No| SKIP9["skip (already recorded)"]
    PUT9 --> FIELD10
    SKIP9 --> FIELD10
    FIELD9 -->|No| FIELD10
    FIELD10{field10: ODR_HAKKO_JOKEN_CD_ERR not null?}
    FIELD10 -->|Yes| KEY10{key not in inMap?}
    KEY10 -->|Yes| PUT10["inMap.put(odr_hakko_joken_cd_err, value)"]
    KEY10 -->|No| SKIP10["skip (already recorded)"]
    PUT10 --> FIELD11
    SKIP10 --> FIELD11
    FIELD10 -->|No| FIELD11
    FIELD11{field11: SAME_TRN_NO_ERR not null?}
    FIELD11 -->|Yes| KEY11{key not in inMap?}
    KEY11 -->|Yes| PUT11["inMap.put(same_trn_no_err, value)"]
    KEY11 -->|No| SKIP11["skip (already recorded)"]
    PUT11 --> FIELD12
    SKIP11 --> FIELD12
    FIELD11 -->|No| FIELD12
    FIELD12{field12: TAKNKIKI_MODEL_CD_ERR not null?}
    FIELD12 -->|Yes| KEY12{key not in inMap?}
    KEY12 -->|Yes| PUT12["inMap.put(taknkiki_model_cd_err, value)"]
    KEY12 -->|No| SKIP12["skip (already recorded)"]
    PUT12 --> FIELD13
    SKIP12 --> FIELD13
    FIELD12 -->|No| FIELD13
    FIELD13{field13: KIKI_SEIZO_NO_ERR not null?}
    FIELD13 -->|Yes| KEY13{key not in inMap?}
    KEY13 -->|Yes| PUT13["inMap.put(kiki_seizo_no_err, value)"]
    KEY13 -->|No| SKIP13["skip (already recorded)"]
    PUT13 --> FIELD14
    SKIP13 --> FIELD14
    FIELD13 -->|No| FIELD14
    FIELD14{field14: MLAD_ERR not null?}
    FIELD14 -->|Yes| KEY14{key not in inMap?}
    KEY14 -->|Yes| PUT14["inMap.put(mlad_err, value)"]
    KEY14 -->|No| SKIP14["skip (already recorded)"]
    PUT14 --> FIELD15
    SKIP14 --> FIELD15
    FIELD14 -->|No| FIELD15
    FIELD15{field15: SPOT_LOGIN_SYSID_ERR not null?}
    FIELD15 -->|Yes| KEY15{key not in inMap?}
    KEY15 -->|Yes| PUT15["inMap.put(spot_login_sysid_err, value)"]
    KEY15 -->|No| SKIP15["skip (already recorded)"]
    PUT15 --> FIELD16
    SKIP15 --> FIELD16
    FIELD15 -->|No| FIELD16
    FIELD16{field16: SEND_REQ_FIN_DTM_ERR not null?}
    FIELD16 -->|Yes| KEY16{key not in inMap?}
    KEY16 -->|Yes| PUT16["inMap.put(send_req_fin_dtm_err, value)"]
    KEY16 -->|No| SKIP16["skip (already recorded)"]
    PUT16 --> FIELD17
    SKIP16 --> FIELD17
    FIELD16 -->|No| FIELD17
    FIELD17{field17: (final field) not null?}
    FIELD17 -->|Yes| KEY17{key not in inMap?}
    KEY17 -->|Yes| PUT17["inMap.put(final_key, value)"]
    KEY17 -->|No| SKIP17["skip (already recorded)"]
    PUT17 --> ALL_DONE
    SKIP17 --> ALL_DONE
    FIELD17 -->|No| ALL_DONE
    ALL_DONE["All 17 error fields processed"]
    ALL_DONE --> RETURN["return param"]
    RETURN --> END(["End"])
```

**Processing flow summary:**

1. **Extract template and status**: Get the first CAANMsg from the templates array and read the STATUS field.
2. **Override on CBS failure**: If the CBS return code is non-zero, force `templateStatus = 9000` to indicate a CBS invocation failure.
3. **Validate status message**: Check if the formatted status key (`RETURN_MESSAGE_XXXX`) exists in `JCMAPLConstMgr`. If not found, reset status to `0`.
4. **Read BP return code**: Parse the existing return code from the param's control map data. Handle null safely by defaulting to `-1`.
5. **Compare and propagate**: If the template's status is higher (more severe) than the BP's current status, overwrite the control map with the formatted status and its corresponding message.
6. **Initialize work maps**: Ensure the mapping work area and HAKKOSODCC work map exist.
7. **Extract error fields**: Process 17 distinct error fields from the template, each with a null check and a deduplication check before writing to the work map.
8. **Return**: Return the modified param object.

## 3. Parameter Analysis

| No | Parameter Name | Type | Business Description |
|----|---------------|------|---------------------|
| 1 | `param` | `IRequestParameterReadWrite` | Business data read/write interface carrying the request/response context. Contains control map data (return code, return message), the mapping work area, and the HAKKOSODCC work map which accumulates error information. Modified in-place: control map data is updated when template status exceeds BP status, and the work map accumulates error field values. |
| 2 | `templates` | `CAANMsg[]` | Array of CAANMsg objects returned from a Service Component (SC) CBS call. The first element (`templates[0]`) is the parent response message containing the STATUS field and all 17 error fields. Each error field may be null (no error for that field) or contain an error string value. |
| 3 | `returnCode` | `int` | The integer return code from the SC CBS invocation. A value of `0` indicates success. Any non-zero value indicates a CBS-level invocation failure, which triggers status override to `9000` (forced error). Cast from `Integer` by callers. |

**External state accessed:**

| Field | Type | Business Description |
|-------|------|---------------------|
| `SCControlMapKeys.RETURN_CODE` | Constant | Control map key for the business program return code. Used to read the existing BP status and write the new status/message. |
| `SCControlMapKeys.RETURN_MESSAGE` | Constant | Control map key for the human-readable return message string. |
| `SCControlMapKeys.ERROR_INFO` | Constant | Control map key (accessed by callers after this method returns) for the error info list extracted from the control map. |
| `EKK1081D010CBSMsg.STATUS` | Constant | Template message key for the CBS status code field. Read from the first CAANMsg. |
| `JKKHakkoSODConstCC.HAKKOSODCCWORKMAP` | Constant | Key used to store/retrieve the HAKKOSODCC work map (`HashMap`) within the param's data store. |
| `JCMAPLConstMgr` | Static class | Centralized constant/message manager providing `getString()` for internationalized return messages keyed by `RETURN_MESSAGE_XXXX`. |

## 4. CRUD Operations / Called Services

### Pre-computed evidence from code analysis graph:

| CRUD | SC / CBS | SC Code | Entity / DB | Operation Description |
|------|----------|---------|-------------|----------------------|
| - | `JKKAdchgCancelHakkoSODCC.editErrorInfo_EKK1081D010CBS` | EKK1081D010CBS | - | This method itself (utility, no direct DB access) |
| - | `CAANMsg.getInt` | - | - | Reads STATUS field value from CAANMsg template |
| - | `CAANMsg.isNull` | - | - | Checks if an error field in CAANMsg is null (N=17 calls) |
| - | `CAANMsg.getString` | - | - | Reads error field value from CAANMsg template (N=17 calls) |
| - | `IRequestParameterReadWrite.getControlMapData` | - | - | Reads RETURN_CODE from the control map data |
| - | `IRequestParameterReadWrite.setControlMapData` | - | - | Writes RETURN_CODE and RETURN_MESSAGE to the control map |
| - | `IRequestParameterReadWrite.getMappingWorkArea` | - | - | Reads the mapping work area Map |
| - | `IRequestParameterReadWrite.setMappingWorkArea` | - | - | Sets the mapping work area Map (if null) |
| - | `IRequestParameterReadWrite.getData` | - | - | Reads HAKKOSODCCWORKMAP from param data |
| - | `IRequestParameterReadWrite.setData` | - | - | Sets HAKKOSODCCWORKMAP in param data (if null) |
| - | `JCMAPLConstMgr.getString` | - | - | Looks up return message string by key (called twice: once for validation, once for message extraction) |
| - | `Integer.parseInt` | - | - | Parses the return code string to int |
| - | `String.format` | - | - | Zero-pads status code to 4-digit format (called twice) |

**How to classify:**
- This method performs **no direct database or SC CRUD operations**. It is a pure data extraction and transformation utility that operates on in-memory objects (`CAANMsg`, `IRequestParameterReadWrite`, `HashMap`).
- All read operations are on the `param` object and the `templates` array passed as arguments.
- All write operations are on the `param` object (in-place mutation of control map data, work area, and data work map).
- The `JCMAPLConstMgr.getString()` call performs a key-value lookup from a centralized constants/messages dictionary.

## 5. Dependency Trace

### Pre-computed evidence from code analysis graph:

No screen/batch entry points found within 8 hops. Direct callers found: 4 methods.
Terminal operations from this method: `isNull` [-] (N=17), `getString` [-] (N=19), `getInt` [-], `getControlMapData` [-], `setControlMapData` [-], `getMappingWorkArea` [-], `setMappingWorkArea` [-], `getData` [-], `setData` [-], `JCMAPLConstMgr.getString` [-].

| # | Caller (Screen/Batch) | Call Chain (Full Path to this Method) | Terminal (SC / CRUD / Entity) |
|---|----------------------|--------------------------------------|-------------------------------|
| 1 | `JKKAdchgCancelHakkoSODCC` | `editResultRP_EKK1081D010CBS` -> `editErrorInfo_EKK1081D010CBS` | `isNull` [R] x17, `getString` [R] x19 |
| 2 | `JKKAdchgHakkoSODCC` | `editResultRP_EKK1081D010CBS` -> `editErrorInfo_EKK1081D010CBS` | `isNull` [R] x17, `getString` [R] x19 |
| 3 | `JKKHakkoSODCC` | `editResultRP_EKK1081D010CBS` -> `editErrorInfo_EKK1081D010CBS` | `isNull` [R] x17, `getString` [R] x19 |
| 4 | `JKKKikiDslAddCC` | `editResultRP_EKK1081D010CBS` -> `editErrorInfo_EKK1081D010CBS` | `isNull` [R] x17, `getString` [R] x19 |

**Caller context:**

All four callers share the same pattern: they invoke `editResultRP_EKK1081D010CBS` (the "down-mapping" or service execution post-processing method for Order Condition Registration), which in turn calls `editErrorInfo_EKK1081D010CBS` after retrieving the CBS response `CAANMsg[]` templates and the return code from the message list.

| Class | Business Context |
|-------|-----------------|
| `JKKAdchgCancelHakkoSODCC` | Order Change+Cancellation issuance — handles combined order modification and cancellation workflows |
| `JKKAdchgHakkoSODCC` | Order Change issuance — handles order modification workflows |
| `JKKHakkoSODCC` | Order issuance — handles standard order registration workflows |
| `JKKKikiDslAddCC` | Equipment DSL Addition — handles equipment model/type addition workflows |

Each caller follows the identical sequence after invoking this method: retrieve the `ERROR_INFO` list from the control map and process accumulated error entries.

## 6. Per-Branch Detail Blocks

**Block 1** — [SET] Get first CAANMsg template (L11972)

> Extract the first element from the templates array (parent response from CBS).

| # | Type | Code |
|---|------|------|
| 1 | SET | `template = templates[0]` // First element is the parent CAANMsg from SC CBS response |

**Block 2** — [SET] Read CBS status from template (L11974)

| # | Type | Code |
|---|------|------|
| 1 | SET | `templateStatus = template.getInt(EKK1081D010CBSMsg.STATUS)` // CBS status code from template |

**Block 3** — [IF] Override status on CBS failure (L11975–L11978)

> If the CBS return code is non-zero, this indicates the CBS invocation itself failed (not a business-level error). Force the status to `9000` to signal CBS-level failure.

| # | Type | Code |
|---|------|------|
| 1 | IF | `returnCode != 0` [CBS invocation failure] |
| 2 | SET | `templateStatus = 9000` // Forced CBS failure status |

**Block 4** — [IF] Validate status message exists in constants (L11979–L11982)

> Check if the formatted status key (`RETURN_MESSAGE_XXXX`) has a corresponding entry in the JCMAPL constants manager. If the message key is not found (e.g., an unregistered or unexpected status code), reset the status to `0` (success) to avoid displaying invalid messages.

| # | Type | Code |
|---|------|------|
| 1 | IF | `JCMAPLConstMgr.getString("RETURN_MESSAGE_" + formatStatus) == null` [Invalid/unknown status message] |
| 2 | SET | `templateStatus = 0` // Reset to success for unknown status |

**Block 5** — [SET] Initialize BP status from control map (L11984–L11991)

> Read the existing return code from the param's control map. If the control map key does not exist (null), default BP status to `-1`, ensuring any valid template status will be considered higher priority.

| # | Type | Code |
|---|------|------|
| 1 | SET | `bpStatus = 0` // Default BP status |
| 2 | SET | `obj = param.getControlMapData(SCControlMapKeys.RETURN_CODE)` // Attempt to read existing BP return code |
| 3 | IF | `obj == null` [No existing return code in control map] (L11986) |
| 4 | SET | `bpStatus = -1` // Default to -1 so template status always wins |
| 5 | ELSE | (L11988) |
| 6 | SET | `bpStatus = Integer.parseInt((String) param.getControlMapData(SCControlMapKeys.RETURN_CODE))` // Parse existing BP return code |

**Block 6** — [IF] Status prioritization: overwrite if template is worse (L11993–L11999)

> If the CBS template's error status is numerically higher than the BP's current status, propagate the template's status and message to the control map. This implements a "worst status wins" policy. The status is zero-padded to 4 digits before message lookup.

| # | Type | Code |
|---|------|------|
| 1 | IF | `templateStatus > bpStatus` [Template status is more severe] (L11993) |
| 2 | SET | `formatStatus = String.format("%1$04d", templateStatus)` // Zero-pad to 4 digits (e.g., "0001", "9000") |
| 3 | SET | `message = JCMAPLConstMgr.getString("RETURN_MESSAGE_" + formatStatus)` // Look up human-readable message |
| 4 | SET | `param.setControlMapData(SCControlMapKeys.RETURN_CODE, formatStatus)` // Overwrite return code |
| 5 | SET | `param.setControlMapData(SCControlMapKeys.RETURN_MESSAGE, message)` // Overwrite return message |

**Block 7** — [SET] Initialize work map (L12002–L12007)

> Ensure the mapping work area exists in the param. If null (first invocation), create a new HashMap and store it.

| # | Type | Code |
|---|------|------|
| 1 | SET | `workMap = param.getMappingWorkArea()` // Get existing work area |
| 2 | IF | `workMap == null` [Work area not yet initialized] (L12004) |
| 3 | SET | `workMap = new HashMap()` // Create new empty work area |
| 4 | SET | `param.setMappingWorkArea(workMap)` // Store in param |

**Block 8** — [SET] Initialize HAKKOSODCC work map (L12010–L12015)

> Get the HAKKOSODCC work map from param data. This map stores the accumulated error information for the Order Condition Registration flow. If null, create a new HashMap.

| # | Type | Code |
|---|------|------|
| 1 | SET | `inMap = (HashMap) param.getData(JKKHakkoSODConstCC.HAKKOSODCCWORKMAP)` // Get existing work map |
| 2 | IF | `inMap == null` [Work map not yet initialized] (L12012) |
| 3 | SET | `inMap = new HashMap()` // Create new empty work map |
| 4 | SET | `param.setData(JKKHakkoSODConstCC.HAKKOSODCCWORKMAP, inMap)` // Store in param |

**Block 9** — [IF-ELSE] Error field extraction (L12018–L12153)

> Process each of the 17 error fields. For each field: check if the template contains a non-null value for that error field, and if so, check if the error key has not already been recorded in the work map. If both conditions are met, store the error value. This implements a "first error wins" deduplication strategy.

**Block 9.1** — [IF] SVC_KEI_NO_ERR (Service Contract Number) (L12019–L12024)

> オーダ発行条件登録マップ.サービス契約番号 → サービス契約番号 のエラー情報返却 (Order Condition Registration Map - Service Contract Number error info return)

| # | Type | Code |
|---|------|------|
| 1 | IF | `!template.isNull(EKK1081D010CBSMsg.SVC_KEI_NO_ERR)` [Error field has non-null value] (L12019) |
| 2 | IF | `!inMap.containsKey("svc_kei_no_err")` [Error not yet recorded] (L12020) |
| 3 | SET | `inMap.put("svc_kei_no_err", template.getString(EKK1081D010CBSMsg.SVC_KEI_NO_ERR))` // Store service contract number error |

**Block 9.2** — [IF] SVC_KEI_UCWK_NO_ERR (Service Contract Detail Work Number) (L12025–L12030)

> オーダ発行条件登録マップ.サービス契約内訳番号 → サービス契約内訳番号 のエラー情報返却 (Service Contract Detail Work Number error info return)

| # | Type | Code |
|---|------|------|
| 1 | IF | `!template.isNull(EKK1081D010CBSMsg.SVC_KEI_UCWK_NO_ERR)` [Error field has non-null value] (L12025) |
| 2 | IF | `!inMap.containsKey("svc_kei_ucwk_no_err")` [Error not yet recorded] (L12026) |
| 3 | SET | `inMap.put("svc_kei_ucwk_no_err", template.getString(EKK1081D010CBSMsg.SVC_KEI_UCWK_NO_ERR))` // Store service contract detail work number error |

**Block 9.3** — [IF] KKTK_SVC_KEI_NO_ERR (Equipment Provider Service Contract Number) (L12031–L12036)

> オーダ発行条件登録マップ.機器提供サービス契約番号 → 機器提供サービス契約番号 のエラー情報返却 (Equipment Provider Service Contract Number error info return)

| # | Type | Code |
|---|------|------|
| 1 | IF | `!template.isNull(EKK1081D010CBSMsg.KKTK_SVC_KEI_NO_ERR)` [Error field has non-null value] (L12031) |
| 2 | IF | `!inMap.containsKey("kktk_svc_kei_no_err")` [Error not yet recorded] (L12032) |
| 3 | SET | `inMap.put("kktk_svc_kei_no_err", template.getString(EKK1081D010CBSMsg.KKTK_SVC_KEI_NO_ERR))` // Store equipment provider service contract number error |

**Block 9.4** — [IF] OP_SVC_KEI_NO_ERR (Optional Service Contract Number) (L12037–L12042)

> オーダ発行条件登録マップ.オプションサービス契約番号 → オプションサービス契約番号 のエラー情報返却 (Optional Service Contract Number error info return)

| # | Type | Code |
|---|------|------|
| 1 | IF | `!template.isNull(EKK1081D010CBSMsg.OP_SVC_KEI_NO_ERR)` [Error field has non-null value] (L12037) |
| 2 | IF | `!inMap.containsKey("op_svc_kei_no_err")` [Error not yet recorded] (L12038) |
| 3 | SET | `inMap.put("op_svc_kei_no_err", template.getString(EKK1081D010CBSMsg.OP_SVC_KEI_NO_ERR))` // Store optional service contract number error |

**Block 9.5** — [IF] SBOP_SVC_KEI_NO_ERR (Sub-Optional Service Contract Number) (L12043–L12048)

> オーダ発行条件登録マップ.サブオプションサービス契約番号 → サブオプションサービス契約番号 のエラー情報返却 (Sub-Optional Service Contract Number error info return)

| # | Type | Code |
|---|------|------|
| 1 | IF | `!template.isNull(EKK1081D010CBSMsg.SBOP_SVC_KEI_NO_ERR)` [Error field has non-null value] (L12043) |
| 2 | IF | `!inMap.containsKey("sbop_svc_kei_no_err")` [Error not yet recorded] (L12044) |
| 3 | SET | `inMap.put("sbop_svc_kei_no_err", template.getString(EKK1081D010CBSMsg.SBOP_SVC_KEI_NO_ERR))` // Store sub-optional service contract number error |

**Block 9.6** — [IF] SEIOPSVC_KEI_NO_ERR (Billing Optional Service Contract Number) (L12049–L12054)

> オーダ発行条件登録マップ.請求オプションサービス契約番号 → 請求オプションサービス契約番号 のエラー情報返却 (Billing Optional Service Contract Number error info return)

| # | Type | Code |
|---|------|------|
| 1 | IF | `!template.isNull(EKK1081D010CBSMsg.SEIOPSVC_KEI_NO_ERR)` [Error field has non-null value] (L12049) |
| 2 | IF | `!inMap.containsKey("seiopsvc_kei_no_err")` [Error not yet recorded] (L12050) |
| 3 | SET | `inMap.put("seiopsvc_kei_no_err", template.getString(EKK1081D010CBSMsg.SEIOPSVC_KEI_NO_ERR))` // Store billing optional service contract number error |

**Block 9.7** — [IF] ORDER_SBT_CD_ERR (Order Type Code) (L12055–L12060)

> オーダ発行条件登録マップ.オーダ種別コード → オーダ種別コード のエラー情報返却 (Order Type Code error info return)

| # | Type | Code |
|---|------|------|
| 1 | IF | `!template.isNull(EKK1081D010CBSMsg.ORDER_SBT_CD_ERR)` [Error field has non-null value] (L12055) |
| 2 | IF | `!inMap.containsKey("order_sbt_cd_err")` [Error not yet recorded] (L12056) |
| 3 | SET | `inMap.put("order_sbt_cd_err", template.getString(EKK1081D010CBSMsg.ORDER_SBT_CD_ERR))` // Store order type code error |

**Block 9.8** — [IF] SVC_ORDER_CD_ERR (Service Order Code) (L12061–L12066)

> オーダ発行条件登録マップ.サービスオーダコード → サービスオーダコード のエラー情報返却 (Service Order Code error info return)

| # | Type | Code |
|---|------|------|
| 1 | IF | `!template.isNull(EKK1081D010CBSMsg.SVC_ORDER_CD_ERR)` [Error field has non-null value] (L12061) |
| 2 | IF | `!inMap.containsKey("svc_order_cd_err")` [Error not yet recorded] (L12062) |
| 3 | SET | `inMap.put("svc_order_cd_err", template.getString(EKK1081D010CBSMsg.SVC_ORDER_CD_ERR))` // Store service order code error |

**Block 9.9** — [IF] YOKYU_SBT_CD_ERR (Request Type Code) (L12067–L12072)

> オーダ発行条件登録マップ.要求種別コード → 要求種別コード のエラー情報返却 (Request Type Code error info return)

| # | Type | Code |
|---|------|------|
| 1 | IF | `!template.isNull(EKK1081D010CBSMsg.YOKYU_SBT_CD_ERR)` [Error field has non-null value] (L12067) |
| 2 | IF | `!inMap.containsKey("yokyu_sbt_cd_err")` [Error not yet recorded] (L12068) |
| 3 | SET | `inMap.put("yokyu_sbt_cd_err", template.getString(EKK1081D010CBSMsg.YOKYU_SBT_CD_ERR))` // Store request type code error |

**Block 9.10** — [IF] ODR_HAKKO_JOKEN_CD_ERR (Order Issuance Condition Code) (L12073–L12078)

> オーダ発行条件登録マップ.オーダ発行条件コード → オーダ発行条件コード のエラー情報返却 (Order Issuance Condition Code error info return)

| # | Type | Code |
|---|------|------|
| 1 | IF | `!template.isNull(EKK1081D010CBSMsg.ODR_HAKKO_JOKEN_CD_ERR)` [Error field has non-null value] (L12073) |
| 2 | IF | `!inMap.containsKey("odr_hakko_joken_cd_err")` [Error not yet recorded] (L12074) |
| 3 | SET | `inMap.put("odr_hakko_joken_cd_err", template.getString(EKK1081D010CBSMsg.ODR_HAKKO_JOKEN_CD_ERR))` // Store order issuance condition code error |

**Block 9.11** — [IF] SAME_TRN_NO_ERR (Same Processing Number) (L12079–L12084)

> オーダ発行条件登録マップ.同一処理番号 → 同一処理番号 のエラー情報返却 (Same Processing Number error info return)

| # | Type | Code |
|---|------|------|
| 1 | IF | `!template.isNull(EKK1081D010CBSMsg.SAME_TRN_NO_ERR)` [Error field has non-null value] (L12079) |
| 2 | IF | `!inMap.containsKey("same_trn_no_err")` [Error not yet recorded] (L12080) |
| 3 | SET | `inMap.put("same_trn_no_err", template.getString(EKK1081D010CBSMsg.SAME_TRN_NO_ERR))` // Store same processing number error |

**Block 9.12** — [IF] TAKNKIKI_MODEL_CD_ERR (Indoor Equipment Model Code) (L12085–L12090)

> オーダ発行条件登録マップ.宅内機器型式コード → 宅内機器型式コード のエラー情報返却 (Indoor Equipment Model Code error info return)

| # | Type | Code |
|---|------|------|
| 1 | IF | `!template.isNull(EKK1081D010CBSMsg.TAKNKIKI_MODEL_CD_ERR)` [Error field has non-null value] (L12085) |
| 2 | IF | `!inMap.containsKey("taknkiki_model_cd_err")` [Error not yet recorded] (L12086) |
| 3 | SET | `inMap.put("taknkiki_model_cd_err", template.getString(EKK1081D010CBSMsg.TAKNKIKI_MODEL_CD_ERR))` // Store indoor equipment model code error |

**Block 9.13** — [IF] KIKI_SEIZO_NO_ERR (Equipment Serial Number) (L12091–L12096)

> オーダ発行条件登録マップ.機器製造番号 → 機器製造番号 のエラー情報返却 (Equipment Serial Number error info return)

| # | Type | Code |
|---|------|------|
| 1 | IF | `!template.isNull(EKK1081D010CBSMsg.KIKI_SEIZO_NO_ERR)` [Error field has non-null value] (L12091) |
| 2 | IF | `!inMap.containsKey("kiki_seizo_no_err")` [Error not yet recorded] (L12092) |
| 3 | SET | `inMap.put("kiki_seizo_no_err", template.getString(EKK1081D010CBSMsg.KIKI_SEIZO_NO_ERR))` // Store equipment serial number error |

**Block 9.14** — [IF] MLAD_ERR (Mail Address) (L12097–L12102)

> オーダ発行条件登録マップ.メールアドレヌス → メールアドレヌス のエラー情報返却 (Mail Address error info return)

| # | Type | Code |
|---|------|------|
| 1 | IF | `!template.isNull(EKK1081D010CBSMsg.MLAD_ERR)` [Error field has non-null value] (L12097) |
| 2 | IF | `!inMap.containsKey("mlad_err")` [Error not yet recorded] (L12098) |
| 3 | SET | `inMap.put("mlad_err", template.getString(EKK1081D010CBSMsg.MLAD_ERR))` // Store mail address error |

**Block 9.15** — [IF] SPOT_LOGIN_SYSID_ERR (Spot Login System ID) (L12103–L12108)

> オーダ発行条件登録マップ.スポットログインISWS ID → ス ポットログインISWS ID のエラー情報返却 (Spot Login ISWS System ID error info return)

| # | Type | Code |
|---|------|------|
| 1 | IF | `!template.isNull(EKK1081D010CBSMsg.SPOT_LOGIN_SYSID_ERR)` [Error field has non-null value] (L12103) |
| 2 | IF | `!inMap.containsKey("spot_login_sysid_err")` [Error not yet recorded] (L12104) |
| 3 | SET | `inMap.put("spot_login_sysid_err", template.getString(EKK1081D010CBSMsg.SPOT_LOGIN_SYSID_ERR))` // Store spot login system ID error |

**Block 9.16** — [IF] SEND_REQ_FIN_DTM_ERR (Transmission Request Completion Date/Time) (L12109–L12114)

> オーダ発行条件登録マップ.送信依頼完了年月日時刻 → 送信依頼完了年月日時刻 のエラー情報返却 (Transmission Request Completion Date/Time error info return)

| # | Type | Code |
|---|------|------|
| 1 | IF | `!template.isNull(EKK1081D010CBSMsg.SEND_REQ_FIN_DTM_ERR)` [Error field has non-null value] (L12109) |
| 2 | IF | `!inMap.containsKey("send_req_fin_dtm_err")` [Error not yet recorded] (L12110) |
| 3 | SET | `inMap.put("send_req_fin_dtm_err", template.getString(EKK1081D010CBSMsg.SEND_REQ_FIN_DTM_ERR))` // Store transmission request completion datetime error |

**Block 10** — [RETURN] Return modified param (L12116)

> Return the param object with updated control map data, work area, and error work map.

| # | Type | Code |
|---|------|------|
| 1 | RETURN | `return param` // Modified param with error information |

## 7. Glossary

| Term | Type | Business Meaning |
|------|------|------------------|
| `svc_kei_no_err` | Field | Service Contract Number Error — error value for the main service contract identifier |
| `svc_kei_ucwk_no_err` | Field | Service Contract Detail Work Number Error — error value for the service contract breakdown/line item number |
| `kktk_svc_kei_no_err` | Field | Equipment Provider Service Contract Number Error — error value for the equipment provider's service contract number (機器提供サービス契約番号) |
| `op_svc_kei_no_err` | Field | Optional Service Contract Number Error — error value for optional add-on service contract number |
| `sbop_svc_kei_no_err` | Field | Sub-Optional Service Contract Number Error — error value for sub-optional add-on service contract number |
| `seiopsvc_kei_no_err` | Field | Billing Optional Service Contract Number Error — error value for billing-related optional service contract number |
| `order_sbt_cd_err` | Field | Order Type Code Error — error value for the order type classification code |
| `svc_order_cd_err` | Field | Service Order Code Error — error value for the service order identifier code |
| `yokyu_sbt_cd_err` | Field | Request Type Code Error — error value for the request type classification code (要求種別コード) |
| `odr_hakko_joken_cd_err` | Field | Order Issuance Condition Code Error — error value for the order issuance condition classification code |
| `same_trn_no_err` | Field | Same Processing Number Error — error value for the duplicate processing/tracking number |
| `taknkiki_model_cd_err` | Field | Indoor Equipment Model Code Error — error value for the customer-premises equipment model code (宅内機器型式コード) |
| `kiki_seizo_no_err` | Field | Equipment Serial Number Error — error value for the equipment manufacturing/serial number (機器製造番号) |
| `mlad_err` | Field | Mail Address Error — error value for the customer mail address |
| `spot_login_sysid_err` | Field | Spot Login ISWS System ID Error — error value for the spot login system identifier |
| `send_req_fin_dtm_err` | Field | Transmission Request Completion Datetime Error — error value for the transmission request completion timestamp |
| `HAKKOSODCCWORKMAP` | Constant | Work map key for the HAKKOSODCC data area — stores all error-related fields in a HashMap |
| SOD | Acronym | Service Order Data — telecom order fulfillment entity/data model |
| CAANMsg | Acronym | Fujitsu CAAN message class — structured message container used for CBS (Common Business Service) communication |
| SC | Acronym | Service Component — service layer component that performs business operations (often database CRUD) |
| CBS | Acronym | Common Business Service — the service interface layer for business operations |
| CC | Acronym | Custom Component — custom business logic component class in the Fujitsu Futurity framework |
| BP | Acronym | Business Program — the business-level program layer within the SOD processing pipeline |
| BCM | Acronym | Business Control Message — framework message container |
| FTTH | Business term | Fiber To The Home — fiber-optic broadband internet service (common service type in telecom SOD) |
| Joken Touro | Business term | Order Condition Registration — the business process of registering order issuance conditions (オーダ発行条件登録) |
| JCMAPLConstMgr | Class | Centralized message constant manager — provides `getString()` lookup for internationalized return messages by key |
| EKK1081D010CBS | Code | Service Component code — the CBS identifier for Order Condition Registration error processing |
| RETURN_CODE | Constant | Control map key for the business program return code/status |
| RETURN_MESSAGE | Constant | Control map key for the human-readable return message string |
