# Business Logic — JFUAddSvcKeiTelCC.editErrInfoEKK0191D010() [471 LOC]

| Field | Value |
|-------|-------|
| Fully Qualified Name | `com.fujitsu.futurity.bp.custom.common.JFUAddSvcKeiTelCC` |
| Layer | CC / Common Component (Package: `com.fujitsu.futurity.bp.custom.common` — shared business component for service contract operations) |
| Module | `common` |

## 1. Role

### JFUAddSvcKeiTelCC.editErrInfoEKK0191D010()

This method performs **error information mapping** for the "Service Contract Detail <eo Light Telephone> Registration" screen (EKK0191D010). When the CBS (Core Business System) returns validation errors after a service registration request, the CBS response includes error fields in a `CAANMsg` template object — each field suffixed with `_ERR` indicates a validation failure on that data item. This method transfers those error messages from the CBS template into the screen's front-end data map (`inMap`) so that the UI can display appropriate error messages to the user.

The method implements a **parallel field-routing pattern**: for each of the 47 error fields, it independently checks whether the CBS template contains an error value (via `template.isNull()`). If an error exists AND the front-end map has not already populated an error for that field, it copies the error string into the map. This "write-once" guard ensures that previously-set error values (from earlier validation passes) are not silently overwritten.

Additionally, the method handles **return status management** at the top: if the CBS returned a non-zero return code, it overrides the template status to `9000`, validates the corresponding return message exists in constants, retrieves the BP-level return code, and only overrides the return code/message if the template's status is higher — ensuring more critical CBS errors take precedence over lower-priority BP errors.

The method is a **shared utility** called from the broader `editErrorInfo()` dispatcher, which iterates over multiple phone number entries (since a single service contract can contain multiple phone number line items) and invokes this method once per line item.

## 2. Processing Pattern (Detailed Business Logic)

```mermaid
flowchart TD
    START(["editErrInfoEKK0191D010 called"])

    START --> GET_STATUS["template.getInt(STATUS)"]
    GET_STATUS --> CHECK_RETURN{"returnCode != 0"}

    CHECK_RETURN --> |"true"| SET_9000["templateStatus = 9000"]
    CHECK_RETURN --> |"false"| SKIP_9000["skip keep templateStatus"]
    SET_9000 --> CHECK_MESSAGE["Check RETURN_MESSAGE exists for templateStatus"]
    SKIP_9000 --> CHECK_MESSAGE

    CHECK_MESSAGE --> |"true"| SET_ZERO["templateStatus = 0"]
    CHECK_MESSAGE --> |"false"| SKIP_ZERO["keep templateStatus"]
    SET_ZERO --> GET_BP_STATUS["param.getControlMapData(RETURN_CODE)"]
    SKIP_ZERO --> GET_BP_STATUS

    GET_BP_STATUS --> BP_NULL{"obj == null"}
    BP_NULL --> |"true"| BP_STATUS_NEG1["bpStatus = -1"]
    BP_NULL --> |"false"| BP_STATUS_PARSE["bpStatus = Integer.parseInt(obj)"]
    BP_STATUS_NEG1 --> COMPARE_STATUS{"templateStatus > bpStatus"}
    BP_STATUS_PARSE --> COMPARE_STATUS

    COMPARE_STATUS --> |"true"| UPDATE_RETURN["Set RETURN_CODE and RETURN_MESSAGE from template"]
    COMPARE_STATUS --> |"false"| SKIP_RETURN["skip keep BP status"]
    UPDATE_RETURN --> INIT_WORK["workMap = get or create mappingWorkArea"]
    SKIP_RETURN --> INIT_WORK

    INIT_WORK --> GET_DATA["inMap = EKK0191D010List.get(index)"]

    GET_DATA --> MAP_SERV_CONTRACT["Map svc_kei_no_err"]
    MAP_SERV_CONTRACT --> MAP_DETAIL_NO["Map mskm_dtl_no_err"]
    MAP_DETAIL_NO --> MAP_PROVIDE_NO["Map tk_hoshiki_kei_no_err"]
    MAP_PROVIDE_NO --> MAP_PAYWAY["Map payway_keizoku_flg_err"]
    MAP_PAYWAY --> MAP_WEB_OP["Map web_op_add_fail_flg_err"]
    MAP_WEB_OP --> MAP_WORK_BIKO["Map biko_err"]
    MAP_WORK_BIKO --> MAP_SVC_USE["Map svc_use_sta_kibo_ymd_err"]
    MAP_SVC_USE --> MAP_RSV_TSTA["Map rsv_tsta_kibo_ymd_err"]
    MAP_RSV_TSTA --> MAP_FTRIAL["Map ftrial_kanyu_ymd_err and ftrial_prd_endymd_err"]
    MAP_FTRIAL --> MAP_HONKANYU["Map honkanyu_ymd_err and honkanyu_iko_kigen_ymd_err"]
    MAP_HONKANYU --> MAP_PNLTY_IDO["Map pnlty_hassei_cd_err and ido_div_err"]
    MAP_PNLTY_IDO --> MAP_TELNO["Map telno_err"]
    MAP_TELNO --> MAP_EMG_ADDR["Map emg_ad_cd_err and emg address fields"]
    MAP_EMG_ADDR --> MAP_TELNO_JUN["Map telno_jun_err and ntt_no_guide_um_err"]
    MAP_TELNO_JUN --> MAP_HELLOPAGE["Map hellopage_keisai_um_err and pcall_dtl_kokai_yh_err"]
    MAP_HELLOPAGE --> MAP_TSJGS["Map tsjgs_cd_err and dsl_pause_toki_kibo_um_err"]
    MAP_TSJGS --> MAP_DSL_PAUSE["Map dsl_pause_toki_sbt_cd_err and townpage fields"]
    MAP_DSL_PAUSE --> MAP_TOWNPAGE["Map townpage_keisai_nm_err and bmp_doji_open_ymd_err"]
    MAP_TOWNPAGE --> MAP_EMG_ADD["Map emg_hosei_pcd_err and SIF address fields"]
    MAP_EMG_ADD --> MAP_EMG_CONT["Map emg_bnchigo_err and emg_ksh fields"]
    MAP_EMG_CONT --> MAP_NTT_ADDR["Map ntt_keisha address fields"]
    MAP_NTT_ADDR --> MAP_NTT_SAI["Map ntt_ksh_ad_ksh_ad_sai_flg_err"]
    MAP_NTT_SAI --> MAP_DOBANITEN["Map dobaniten_jdg_cd_err and itens_opaf_toki_kibo_um_err"]
    MAP_DOBANITEN --> RETURN_PARAM["return param"]

    classDef processing fill:#e1f5fe,stroke:#01579b
    classDef condition fill:#fff9c4,stroke:#f57f17
    classDef mapOp fill:#e8f5e9,stroke:#2e7d32
```

## 3. Parameter Analysis

| No | Parameter Name | Type | Business Description |
|----|---------------|------|---------------------|
| 1 | `param` | `IRequestParameterReadWrite` | The request parameter object carrying the screen's data context. Contains the `EKK0191D010` data map (which holds the list of phone number line items), the control map (for return code/message management), and the mapping work area. Represents the full state of the current screen request. |
| 2 | `template` | `CAANMsg` | The CBS response message template (`EKK0191D010CBSMsg`) containing error fields returned from the core business system. Each field with an `_ERR` suffix holds an error message string when that validation field failed. |
| 3 | `returnCode` | `int` | The return code from the CBS call. If non-zero, indicates the CBS encountered an error condition. The method uses this to override the template status to `9000` (system error) and validate the corresponding return message exists. |
| 4 | `fixedText` | `String` | A fixed text identifier (e.g., `"EKK0191D010"`) used for screen-level identification. Passed through to the caller but not actively consumed within this method body — used for tracing and debugging. |
| 5 | `index` | `int` | The index into the `EKK0191D010List` ArrayList, identifying which phone number line item within a multi-line service contract this error mapping applies to. When `editErrorInfo()` iterates over phone numbers, `index` is incremented for each line item. |

**External state read:**
- `SCControlMapKeys.RETURN_CODE` — control map key for the current BP-level return code
- `SCControlMapKeys.RETURN_MESSAGE` — control map key for the current BP-level return message
- `JCMAPLConstMgr.getString()` — application constant manager used to look up return messages by status code

## 4. CRUD Operations / Called Services

| CRUD | SC / CBS | SC Code | Entity / DB | Operation Description |
|------|----------|---------|-------------|----------------------|
| - | `JCMAPLConstMgr.getString` | - | - | Reads return message constant by status code key (`RETURN_MESSAGE_XXXX`). Used for status 0, 9000, and the actual template status. |
| R | `template.getInt` | EKK0191D010CBS | - | Reads the `STATUS` field from the CBS response template to determine the error severity level. |
| R | `param.getControlMapData` | - | - | Reads the BP-level return code from the control map for status comparison. |
| R | `param.getMappingWorkArea` | - | - | Reads or initializes the mapping work area HashMap for the current request. |
| R | `param.getData` | - | - | Reads the `EKK0191D010` data map, then navigates to the `EKK0191D010List` ArrayList and extracts the specific phone number entry at the given index. |
| R | `template.isNull` | EKK0191D010CBS | - | Checks each of the 47 error fields to determine if an error was returned by the CBS. Returns false if the field has a non-null value (i.e., an error exists). |
| R | `template.getString` | EKK0191D010CBS | - | Retrieves the error message string for each field where an error was detected. |
| - | `inMap.containsKey` | - | - | Checks if the front-end map already has an error value set for the field (write-once guard). |
| - | `inMap.put` | - | - | Maps the error string from the CBS template into the front-end data map under the `_err` suffixed key. |
| - | `param.setControlMapData` | - | - | Sets the return code and return message in the control map when template status takes precedence over BP status. |
| - | `param.setMappingWorkArea` | - | - | Sets the newly-created work map if the work area was null. |

No direct database or SC code calls are made within this method. It is purely an **in-memory data mapping** method that transforms CBS error response data into front-end display format.

## 5. Dependency Trace

| # | Caller (Screen/Batch) | Call Chain (Full Path to this Method) | Terminal (SC / CRUD / Entity) |
|---|----------------------|--------------------------------------|-------------------------------|
| 1 | Class: JFUAddSvcKeiTelCC.editRetEKK0191D010 | `editRetEKK0191D010` -> `editErrInfoEKK0191D010(param, template, returnCode, fixedText, index)` | `isNull [R]`, `getString [R]` (x47 template error fields) |
| 2 | Class: JFUAddSvcKeiTelCC.editErrorInfo | `editErrorInfo(templates[], returnCode)` -> loop over EKK0191D010List -> `editErrInfoEKK0191D010(param, templates[i+idx], returnCode, "EKK0191D010", i)` | `isNull [R]`, `getString [R]` (x47 template error fields per phone number entry) |
| 3 | Class: JKKUpdSvcKeiTelCC (update path) | `editErrInfoEKK0191D010` variant (different signature, calls the same underlying method) | Same terminal operations as above |
| 4 | Class: JKKAddSvcKeiTelCC (add path) | `editErrInfoEKK0191D010` variant (different signature, calls the same underlying method) | Same terminal operations as above |
| 5 | Class: JKKAdchgAddSvcKeiTelCC (add/change path) | `editErrInfoEKK0191D010(templates[], returnCode, fixedText)` -> iterates templates -> `editErrInfoEKK0191D010(param, templates[...], returnCode, fixedText)` | Same terminal operations as above |

**Note:** This method is a leaf-level error-mapping utility. It does not reach any SC codes or database entities directly. All terminal operations are read-only (`isNull`, `getString`) on the `EKK0191D010CBSMsg` template fields. The error fields are sourced from the CBS response that was received prior to this method's invocation.

## 6. Per-Branch Detail Blocks

### Block 1 — IF `[returnCode != 0]` (L3280)

> If the CBS returned a non-zero return code, override the template status to `9000` (system-level error).

| # | Type | Code |
|---|------|------|
| 1 | SET | `templateStatus = 9000` // Override status to system error code when returnCode is non-zero |

### Block 2 — IF `[JCMAPLConstMgr.getString("RETURN_MESSAGE_" + formatStatus) == null]` (L3284)

> Validate the return message constant exists for the computed status. If the formatted status code (e.g., `9000` -> `RETURN_MESSAGE_9000`) has no matching constant, reset status to `0` to avoid unknown message lookups.

| # | Type | Code |
|---|------|------|
| 1 | SET | `formatStatus = String.format("%1$04d", templateStatus)` // Zero-padded 4-digit status string |
| 2 | SET | `message = JCMAPLConstMgr.getString("RETURN_MESSAGE_" + formatStatus)` // Lookup return message by status |
| 3 | SET | `templateStatus = 0` // Reset to default if no message constant found |

### Block 3 — IF/ELSE `[obj == null for return code]` (L3288–3295)

> Read the BP-level return code from the control map. If absent (first pass), set `bpStatus` to `-1` to ensure the template status always wins on the first comparison.

| # | Type | Code |
|---|------|------|
| 1 | SET | `obj = param.getControlMapData(SCControlMapKeys.RETURN_CODE)` |
| 2 | SET | `bpStatus = -1` // [IF obj == null] Default BP status to -1 |
| 3 | SET | `bpStatus = Integer.parseInt((String) obj)` // [ELSE] Parse BP return code from control map |

### Block 4 — IF `[templateStatus > bpStatus]` (L3298)

> Compare CBS template status against BP-level status. If the template's status is higher (more severe), override the BP's return code and message with the template's values. This implements **priority-based error overriding**: CBS errors (higher status) take precedence over local BP errors.

| # | Type | Code |
|---|------|------|
| 1 | SET | `formatStatus = String.format("%1$04d", templateStatus)` // Zero-padded 4-digit status |
| 2 | SET | `message = JCMAPLConstMgr.getString("RETURN_MESSAGE_" + formatStatus)` // Message text for this status |
| 3 | EXEC | `param.setControlMapData(SCControlMapKeys.RETURN_CODE, formatStatus)` // Override BP return code |
| 4 | EXEC | `param.setControlMapData(SCControlMapKeys.RETURN_MESSAGE, message)` // Override BP return message |

### Block 5 — INIT workMap (L3305–3310)

> Ensure the mapping work area exists. If null, create a new HashMap and set it on the parameter.

| # | Type | Code |
|---|------|------|
| 1 | SET | `workMap = (Map) param.getMappingWorkArea()` |
| 2 | SET | `workMap = new HashMap()` // [IF workMap == null] |
| 3 | EXEC | `param.setMappingWorkArea(workMap)` // [IF workMap was null] |

### Block 6 — DATA EXTRACTION (L3314–3317)

> Extract the specific phone number line item's data map from the `EKK0191D010List` ArrayList at the given index. This is how the method targets individual phone number entries within a multi-line service contract.

| # | Type | Code |
|---|------|------|
| 1 | SET | `inMap = (HashMap) param.getData("EKK0191D010")` // Get parent data map |
| 2 | SET | `inMap = (HashMap) ((ArrayList) inMap.get("EKK0191D010List")).get(index)` // Extract specific line item |

### Block 7 — FIELD MAPPING: Service Contract Identification (L3320–3331)

> Map service contract identification error fields. Each follows the same pattern: check if template has error value, check if map already has error, then copy.

**Block 7.1** — `[!template.isNull(SVC_KEI_NO_ERR)]` (L3320)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("svc_kei_no_err", template.getString(EKK0191D010CBSMsg.SVC_KEI_NO_ERR))` // Service contract number error |

**Block 7.2** — `[!template.isNull(MSKM_DTL_NO_ERR)]` (L3327)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("mskm_dtl_no_err", template.getString(EKK0191D010CBSMsg.MSKM_DTL_NO_ERR))` // Application detail number error |

**Block 7.3** — `[!template.isNull(TK_HOSHIKI_KEI_NO_ERR)]` (L3333)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("tk_hoshiki_kei_no_err", template.getString(EKK0191D010CBSMsg.TK_HOSHIKI_KEI_NO_ERR))` // Provision method contract number error |

### Block 8 — FIELD MAPPING: Payment & Service Options (L3339–3372)

**Block 8.1** — `[!template.isNull(PAYWAY_KEIZOKU_FLG_ERR)]` (L3339)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("payway_keizoku_flg_err", template.getString(...))` // Payment method continuation flag error |

**Block 8.2** — `[!template.isNull(WEB_OP_ADD_FAIL_FLG_ERR)]` (L3345)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("web_op_add_fail_flg_err", template.getString(...))` // Web option addition failure flag error |

**Block 8.3** — `[!template.isNull(WORK_RRK_BIKO_ERR)]` (L3351)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("biko_err", template.getString(EKK0191D010CBSMsg.WORK_RRK_BIKO_ERR))` // Business liaison remarks error |

**Block 8.4** — `[!template.isNull(SVC_USE_STA_KIBO_YMD_ERR)]` (L3357)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("svc_use_sta_kibo_ymd_err", template.getString(...))` // Service usage start desired date error |

### Block 9 — FIELD MAPPING: Scheduling Dates (L3366–3403)

**Block 9.1** — `[!template.isNull(RSV_TSTA_KIBO_YMD_ERR)]` (L3366)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("rsv_tsta_kibo_ymd_err", template.getString(...))` // Reservation application start desired date error |

**Block 9.2** — `[!template.isNull(FTRIAL_KANYU_YMD_ERR)]` (L3372)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("ftrial_kanyu_ymd_err", template.getString(...))` // Trial period entry date error |

**Block 9.3** — `[!template.isNull(FTRIAL_PRD_ENDYMD_ERR)]` (L3378)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("ftrial_prd_endymd_err", template.getString(...))` // Trial period end date error |

**Block 9.4** — `[!template.isNull(HONKANYU_YMD_ERR)]` (L3384)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("honkanyu_ymd_err", template.getString(...))` // Actual installation date error |

**Block 9.5** — `[!template.isNull(HONKANYU_IKO_KIGEN_YMD_ERR)]` (L3390)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("honkanyu_iko_kigen_ymd_err", template.getString(...))` // Actual installation transfer deadline date error |

### Block 10 — FIELD MAPPING: Penalties, Identity, Phone Number (L3396–3428)

**Block 10.1** — `[!template.isNull(PNLTY_HASSEI_CD_ERR)]` (L3396)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("pnlty_hassei_cd_err", template.getString(...))` // Penalty occurrence code error |

**Block 10.2** — `[!template.isNull(IDO_DIV_ERR)]` (L3402)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("ido_div_err", template.getString(...))` // Identity division error |

**Block 10.3** — `[!template.isNull(TELNO_ERR)]` (L3408)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("telno_err", template.getString(...))` // Phone number error |

### Block 11 — FIELD MAPPING: Emergency Contact Address (L3414–3457)

**Block 11.1** — `[!template.isNull(EMG_AD_CD_ERR)]` (L3414)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("emg_ad_cd_err", template.getString(...))` // Emergency contact address code error |

**Block 11.2** — `[!template.isNull(EMG_ADRTTM_ERR)]` (L3420)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("emg_adrttm_err", template.getString(...))` // Emergency contact address supplemental/building name error |

**Block 11.3** — `[!template.isNull(EMG_ADRRM_ERR)]` (L3426)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("emg_adrrm_err", template.getString(...))` // Emergency contact address supplemental/room number error |

**Block 11.4** — `[!template.isNull(TELNO_JUN_ERR)]` (L3432)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("telno_jun_err", template.getString(...))` // Phone number sequence error |

**Block 11.5** — `[!template.isNull(NTT_NO_GUIDE_UM_ERR)]` (L3438)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("ntt_no_guide_um_err", template.getString(...))` // NTT number guidance presence/absence error |

**Block 11.6** — `[!template.isNull(HELLOPAGE_KEISAI_UM_ERR)]` (L3444)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("hellopage_keisai_um_err", template.getString(...))` // HelloPage listing presence/absence error |

**Block 11.7** — `[!template.isNull(TUWA_DTL_KOKAI_YH_ERR)]` (L3450)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("pcall_dtl_kokai_yh_err", template.getString(EKK0191D010CBSMsg.TUWA_DTL_KOKAI_YH_ERR))` // Call details disclosure yes/no error |

### Block 12 — FIELD MAPPING: Telecom Provider & Pause/Contract (L3456–3496)

**Block 12.1** — `[!template.isNull(TSJGS_CD_ERR)]` (L3456)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("tsjgs_cd_err", template.getString(...))` // Telecommunications provider code error |

**Block 12.2** — `[!template.isNull(DSL_PAUSE_TOKI_KIBO_UM_ERR)]` (L3462)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("dsl_pause_toki_kibo_um_err", template.getString(...))` // Suspension/cancellation work desired presence/absence error |

**Block 12.3** — `[!template.isNull(DSL_PAUSE_TOKI_SBT_CD_ERR)]` (L3468)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("dsl_pause_toki_sbt_cd_err", template.getString(...))` // Suspension/cancellation work type code error |

**Block 12.4** — `[!template.isNull(TOWNPAGE_KEISAI_KANA_ERR)]` (L3474)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("townpage_keisai_kana_err", template.getString(...))` // Townpage listing kana name error |

### Block 13 — FIELD MAPPING: Townpage & Banpo (L3480–3496)

**Block 13.1** — `[!template.isNull(TOWNPAGE_KEISAI_NM_ERR)]` (L3480)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("townpage_keisai_nm_err", template.getString(...))` // Townpage listing name error |

**Block 13.2** — `[!template.isNull(BMP_DOJI_OPEN_YMD_ERR)]` (L3486)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("bmp_doji_open_ymd_err", template.getString(...))` // Banpo simultaneous opening date error |

### Block 14 — FIELD MAPPING: Emergency Supplementary Postal Code (L3492)

**Block 14.1** — `[!template.isNull(EMG_HOSEI_PCD_ERR)]` (L3492)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("emg_hosei_pcd_err", template.getString(...))` // Emergency supplementary postal code error |

### Block 15 — FIELD MAPPING: SIF Address Fields (2012/04/26 Addition) (L3500–3533)

> These fields were added as part of the SIF (Service Information File) address standardization update.

**Block 15.1** — `[!template.isNull(EMG_STATE_NM_ERR)]` (L3500)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("emg_state_nm_err", template.getString(...))` // Emergency contact prefecture name error |

**Block 15.2** — `[!template.isNull(EMG_CITY_NM_ERR)]` (L3506)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("emg_city_nm_err", template.getString(...))` // Emergency contact city/town/village name error |

**Block 15.3** — `[!template.isNull(EMG_OAZTSU_NM_ERR)]` (L3512)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("emg_oaztsu_nm_err", template.getString(...))` // Emergency contact large street name error |

**Block 15.4** — `[!template.isNull(EMG_AZCHO_NM_ERR)]` (L3518)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("emg_azcho_nm_err", template.getString(...))` // Emergency contact block/number error |

### Block 16 — FIELD MAPPING: Emergency Additional Fields (L3526–3568)

**Block 16.1** — `[!template.isNull(EMG_BNCHIGO_ERR)]` (L3526)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("emg_bnchigo_err", template.getString(...))` // Emergency contact lot number error |

**Block 16.2** — `[!template.isNull(EMG_KSH_KSITEI_FLG_ERR)]` (L3532)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("emg_ksh_ksitei_flg_err", template.getString(...))` // Emergency contract individual designation flag error |

**Block 16.3** — `[!template.isNull(EMG_KSH_NM_ERR)]` (L3538)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("emg_ksh_nm_err", template.getString(...))` // Emergency contract holder name error |

**Block 16.4** — `[!template.isNull(EMG_KSH_KANA_ERR)]` (L3544)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("emg_ksh_kana_err", template.getString(...))` // Emergency contract holder kana name error |

### Block 17 — FIELD MAPPING: NTT Customer Address (L3552–3602)

> Maps NTT (Nippon Telegraph and Telephone) customer address error fields, used when the NTT customer address differs from the contract address.

**Block 17.1** — `[!template.isNull(NTT_KEISHA_AD_CD_ERR)]` (L3552)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("ntt_keisha_ad_cd_err", template.getString(...))` // NTT customer address code error |

**Block 17.2** — `[!template.isNull(NTT_KEISHA_PCD_ERR)]` (L3558)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("ntt_keisha_pcd_err", template.getString(...))` // NTT customer postal code error |

**Block 17.3** — `[!template.isNull(NTT_KEISHA_STATE_NM_ERR)]` (L3564)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("ntt_keisha_state_nm_err", template.getString(...))` // NTT customer prefecture name error |

**Block 17.4** — `[!template.isNull(NTT_KEISHA_CITY_NM_ERR)]` (L3570)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("ntt_keisha_city_nm_err", template.getString(...))` // NTT customer city/town/village name error |

**Block 17.5** — `[!template.isNull(NTT_KEISHA_OAZTSU_NM_ERR)]` (L3576)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("ntt_keisha_oaztsu_nm_err", template.getString(...))` // NTT customer large street name error |

**Block 17.6** — `[!template.isNull(NTT_KEISHA_AZCHO_NM_ERR)]` (L3582)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("ntt_keisha_azcho_nm_err", template.getString(...))` // NTT customer block/number error |

**Block 17.7** — `[!template.isNull(NTT_KEISHA_BNCHIGO_ERR)]` (L3588)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("ntt_keisha_bnchigo_err", template.getString(...))` // NTT customer lot number error |

**Block 17.8** — `[!template.isNull(NTT_KEISHA_ADRTTM_ERR)]` (L3594)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("ntt_keisha_adrttm_err", template.getString(...))` // NTT customer address supplemental/building name error |

**Block 17.9** — `[!template.isNull(NTT_KEISHA_ADRRM_ERR)]` (L3600)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("ntt_keisha_adrrm_err", template.getString(...))` // NTT customer address supplemental/room number error |

**Block 17.10** — `[!template.isNull(NTT_KEISHA_AD_CD_ERR)]` (L3606)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("ntt_keisha_kana_err", template.getString(EKK0191D010CBSMsg.NTT_KEISHA_AD_CD_ERR))` // NTT customer kana name error (maps to `ntt_keisha_kana_err` key) |

**Block 17.11** — `[!template.isNull(NTT_KEISHA_NM_ERR)]` (L3612)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("ntt_keisha_nm_err", template.getString(...))` // NTT customer name error |

### Block 18 — FIELD MAPPING: NTT Address Discrepancy Flag (L3618)

**Block 18.1** — `[!template.isNull(NTT_KSH_AD_KSH_AD_SAI_FLG_ERR)]` (L3618)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("ntt_ksh_ad_ksh_ad_sai_flg_err", template.getString(...))` // NTT customer address vs contract address discrepancy flag error |

### Block 19 — FIELD MAPPING: Same Number Transfer (2012.09.21 Addition) (L3625–3639)

> Added by Otsuka on 2012/09/21. Maps same-number portability (number porting) related error fields.

**Block 19.1** — `[!template.isNull(DOBANITEN_JDG_CD_ERR)]` (L3625)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("dobaniten_jdg_cd_err", template.getString(...))` // Same number portability judgment code error |

**Block 19.2** — `[!template.isNull(ITENS_OPAF_TOKI_KIBO_UM_ERR)]` (L335)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap.put("itens_opaf_toki_kibo_um_err", template.getString(...))` // Post-portability work desired presence/absence error |

### Block 20 — RETURN (L3645)

> Return the updated parameter with all error information mapped into the front-end data map.

| # | Type | Code |
|---|------|------|
| 1 | RETURN | `return param` // Return param with error fields populated |

## 7. Glossary

| Term | Type | Business Meaning |
|------|------|------------------|
| `svc_kei_no` | Field | Service contract number — the primary identifier for a service contract line item |
| `mskm_dtl_no` | Field | Application detail number — sub-identifier within a service contract for specific application details |
| `tk_hoshiki_kei_no` | Field | Provision method contract number — identifier for how the service is provisioned |
| `payway_keizoku_flg` | Field | Payment method continuation flag — indicates whether to continue the existing payment method |
| `web_op_add_fail_flg` | Field | Web option addition failure flag — indicates if a web option could not be added |
| `work_rrk_biko` | Field | Business liaison remarks — free-text field for coordination notes between business teams |
| `svc_use_sta_kibo_ymd` | Field | Service usage start desired date (YMD) — the date the customer wants service to begin |
| `rsv_tsta_kibo_ymd` | Field | Reservation application start desired date — when the reservation application process should start |
| `ftrial_kanyu_ymd` | Field | Trial period entry date — when the trial period begins |
| `ftrial_prd_endymd` | Field | Trial period end date — when the trial period expires |
| `honkanyu_ymd` | Field | Actual installation date (YMD) — when the service becomes fully active |
| `honkanyu_iko_kigen_ymd` | Field | Actual installation transfer deadline date — deadline for transferring to the installed service |
| `pnlty_hassei_cd` | Field | Penalty occurrence code — code indicating if/when penalties are charged |
| `ido_div` | Field | Identity division — classification code for identity/type division |
| `telno` | Field | Phone number — the telephone number being registered |
| `telno_jun` | Field | Phone number sequence — the order of this phone number when multiple numbers exist |
| `emg_ad_cd` | Field | Emergency contact address code — code identifying the emergency contact address |
| `emg_adrttm` | Field | Emergency contact address supplemental/building name — building or structure name for emergency contact |
| `emg_adrrm` | Field | Emergency contact address supplemental/room number — room number for emergency contact |
| `emg_hosei_pcd` | Field | Emergency supplementary postal code — postal code for emergency contact supplementary address |
| `emg_state_nm` | Field | Emergency contact prefecture name — prefecture for emergency contact address |
| `emg_city_nm` | Field | Emergency contact city/town/village name — municipality for emergency contact address |
| `emg_oaztsu_nm` | Field | Emergency contact large street name — major road/street for emergency contact address |
| `emg_azcho_nm` | Field | Emergency contact block/number — block and number for emergency contact address |
| `emg_bnchigo` | Field | Emergency contact lot number — lot/parcel number for emergency contact address |
| `emg_ksh_ksitei_flg` | Field | Emergency contract individual designation flag — flag for individually-designated emergency contract |
| `emg_ksh_nm` | Field | Emergency contract holder name — name of the emergency contact person/organization |
| `emg_ksh_kana` | Field | Emergency contract holder kana name — kana reading of the emergency contact holder name |
| `ntt_keisha_ad_cd` | Field | NTT customer address code — address code for the NTT customer (when different from contract) |
| `ntt_keisha_pcd` | Field | NTT customer postal code — postal code for NTT customer address |
| `ntt_keisha_state_nm` | Field | NTT customer prefecture name — prefecture of NTT customer address |
| `ntt_keisha_city_nm` | Field | NTT customer city/town/village name — municipality of NTT customer address |
| `ntt_keisha_oaztsu_nm` | Field | NTT customer large street name — major road of NTT customer address |
| `ntt_keisha_azcho_nm` | Field | NTT customer block/number — block/number of NTT customer address |
| `ntt_keisha_bnchigo` | Field | NTT customer lot number — lot/parcel number of NTT customer address |
| `ntt_keisha_adrttm` | Field | NTT customer address supplemental/building name — building of NTT customer address |
| `ntt_keisha_adrrm` | Field | NTT customer address supplemental/room number — room number of NTT customer address |
| `ntt_keisha_nm` | Field | NTT customer name — name of the NTT customer |
| `ntt_ksh_ad_ksh_ad_sai_flg` | Field | NTT customer address vs contract address discrepancy flag — indicates if NTT address differs from contract address |
| `dobaniten_jdg_cd` | Field | Same number portability judgment code — result code for number portability eligibility judgment |
| `itens_opaf_toki_kibo_um` | Field | Post-portability work desired presence/absence — whether additional work is desired after number portability |
| `ntt_no_guide_um` | Field | NTT number guidance presence/absence — whether NTT number guidance information is available |
| `hellopage_keisai_um` | Field | HelloPage listing presence/absence — whether the number is listed on NTT's HelloPage directory |
| `pcall_dtl_kokai_yh` | Field | Call details disclosure yes/no — whether call detail information may be publicly disclosed |
| `tsjgs_cd` | Field | Telecommunications provider code — code identifying the telecom carrier/provider |
| `dsl_pause_toki_kibo_um` | Field | Suspension/cancellation work desired presence/absence — whether pause/cancellation work is desired |
| `dsl_pause_toki_sbt_cd` | Field | Suspension/cancellation work type code — code for the type of suspension/cancellation work |
| `townpage_keisai_kana` | Field | Townpage listing kana name — kana name for Townpage directory listing |
| `townpage_keisai_nm` | Field | Townpage listing name — name for Townpage directory listing |
| `bmp_doji_open_ymd` | Field | Banpo simultaneous opening date — date for simultaneous opening of banpo (phone book) listing |
| `STATUS` | Constant | CBS response status field — numeric severity level of the CBS response (0=OK, 9000=system error) |
| `RETURN_MESSAGE_XXXX` | Constant | Application constant key for looking up human-readable return messages by status code |
| `EKK0191D010` | Screen/Process ID | Service Contract Detail <eo Light Telephone> Registration screen — the EKK-prefix screen for registering light telephone service contract details |
| `eo` | Business term | "Eo Light Telephone" — Fujitsu's branded fiber-optic internet telephone service (eoヒカリ電話) |
| `CAANMsg` | Technical | Fujitsu CAAN message framework class — a key-value message container for CBS communication, extending `CAANSchemaInfo` |
| `EKK0191D010CBSMsg` | Technical | CBS message schema class defining all fields for the EKK0191D010 service contract registration interface |
| `IRequestParameterReadWrite` | Technical | Interface for bidirectional parameter passing between screen and business logic layers |
| `SIF` | Acronym | Service Information File — address data standardization initiative (fields added 2012/04/26) |
| `_ERR` | Convention | Suffix appended to field names in CBS error responses — a non-null value in a `_ERR` field means that field has an error |
| BP | Acronym | Business Process — the application-level business logic layer (as opposed to CBS which is the core system) |
| CBS | Acronym | Core Business System — the central telecom operations system that processes service registrations |
