# Business Logic — JKKSeikySakiHeigoCC.editInMsg_EKK0011D020() [271 LOC]

| Field | Value |
|-------|-------|
| Fully Qualified Name | `com.fujitsu.futurity.bp.custom.common.JKKSeikySakiHeigoCC` |
| Layer | CC / Common Component (extends `AbstractCommonComponent`) |
| Module | `common` (Package: `com.fujitsu.futurity.bp.custom.common`) |

## 1. Role

### JKKSeikySakiHeigoCC.editInMsg_EKK0011D020()

This method creates the input message template for the **Order Content Approval Registration** service (service code: EKK0011D020). In the K-Opticom customer core system, telecom orders for new installations (such as FTTH broadband connections) must pass through an approval workflow before activation. This method constructs the `CAANMsg` request payload that will be dispatched to the backend service component `EKK0011D020CBS` via the `scCall.run()` invocation.

The method implements the **Builder pattern** for CBS message construction: it instantiates a typed `CAANMsg` template keyed by `EKK0011D020CBSMsg`, populates common metadata fields (operator ID, operating date, operating datetime), maps 17 business-level fields from the `childMap` (which carries the form-submitted order content approval registration data submitted by the customer), and conditionally creates a nested detail message array for order detail items. It delegates common-area field extraction to `editInMsg(param)` which sets up shared control data.

The method serves as the **message-building stage** within the larger `execEKK0011D020()` flow, which chains this call with the actual SC invocation and result processing. It is a shared utility called by multiple screens — `JKKSeikySakiHeigoCC.execEKK0011D020()`, `JKKSeikyKeiHenkoCC`, `JKKEohTvCourseChgClCC`, `JKKEohTvCourseChgCC`, and `JKKCreateNhkDntIktCC` — all of which need to register order content approval as part of their service contract change or new subscription flows.

## 2. Processing Pattern (Detailed Business Logic)

```mermaid
flowchart TD
    START(["editInMsg_EKK0011D020"])
    COMMON_SETUP["editInMsg param
Common area setup"]
    CREATE_TEMPLATE["Create CAANMsg
EKK0011D020CBSMsg
TEMPLATE_ID_EKK0011D020"]
    SET_FUNC_CODE["Set FUNC_CODE to 1"]
    SET_OPERATOR["Set OPERATOR_ID from control map"]
    SET_OPE_DATE["Set OPERATE_DATE from control map"]
    SET_OPE_TIME["Set OPERATE_DATETIME from control map"]
    GET_WORKMAP["Get mappingWorkArea"]
    GET_USR_DATA["param getData KKSV0546CCList
User data info"]
    OVERWRITE_FUNC["Overwrite FUNC_CODE from dataMap"]

    START --> COMMON_SETUP
    COMMON_SETUP --> CREATE_TEMPLATE
    CREATE_TEMPLATE --> SET_FUNC_CODE
    SET_FUNC_CODE --> SET_OPERATOR
    SET_OPERATOR --> SET_OPE_DATE
    SET_OPE_DATE --> SET_OPE_TIME
    SET_OPE_TIME --> GET_WORKMAP
    GET_WORKMAP --> GET_USR_DATA
    GET_USR_DATA --> OVERWRITE_FUNC

    MAP_SYSID["Map sysid field"]
    MAP_MSKM_SBT["Map mskm_sbt_cd field"]
    MAP_MSMSHO_ARIV["Map mskmsho_ariv_ymd field"]
    MAP_MSKM_UK["Map mskm_uk_dtm field"]
    MAP_MSKM_UK_TNT["Map mskm_uk_tnt_user_id field"]
    MAP_MSKM_YMD["Map mskm_ymd field"]
    MAP_TTL_BIZ_CENTER["Map ttl_business_center_uk_no field"]
    MAP_TTL_BIZ_MSKM["Map ttl_business_mskm_opt_cd field"]
    MAP_MSKM_RRKS_TEL["Map mskm_rrks_telno field"]
    MAP_MSKM_JSSIS["Map mskm_jssis_sbt_cd field"]
    MAP_CUST_YOBO["Map cust_yobo_jiko field"]
    MAP_TEL_RRK_KIBO["Map tel_rrk_kibo_time_cd field"]
    MAP_TAKCHO_KIBO["Map takcho_kibo_time_cd field"]
    MAP_KARI_MSKM["Map kari_mskm_flg field"]
    MAP_REFERER["Map referer field"]
    MAP_KEPCO_CUST["Map kepco_custinfo_juju_doi_um field"]
    MAP_CONSMBSN["Map consmbsn_mskm_stat_skbt_cd field"]

    SET_NULL_UNCOND["Set 8 fields to null unconditionally"]

    OVERWRITE_FUNC --> MAP_SYSID
    MAP_SYSID --> MAP_MSKM_SBT
    MAP_MSKM_SBT --> MAP_MSMSHO_ARIV
    MAP_MSMSHO_ARIV --> MAP_MSKM_UK
    MAP_MSKM_UK --> MAP_MSKM_UK_TNT
    MAP_MSKM_UK_TNT --> MAP_MSKM_YMD
    MAP_MSKM_YMD --> MAP_TTL_BIZ_CENTER
    MAP_TTL_BIZ_CENTER --> MAP_TTL_BIZ_MSKM
    MAP_TTL_BIZ_MSKM --> MAP_MSKM_RRKS_TEL
    MAP_MSKM_RRKS_TEL --> MAP_MSKM_JSSIS
    MAP_MSKM_JSSIS --> MAP_CUST_YOBO
    MAP_CUST_YOBO --> MAP_TEL_RRK_KIBO
    MAP_TEL_RRK_KIBO --> MAP_TAKCHO_KIBO
    MAP_TAKCHO_KIBO --> MAP_KARI_MSKM
    MAP_KARI_MSKM --> MAP_REFERER
    MAP_REFERER --> MAP_KEPCO_CUST
    MAP_KEPCO_CUST --> MAP_CONSMBSN
    MAP_CONSMBSN --> SET_NULL_UNCOND

    GET_CHILD_LIST["Get childMap EKK0011D020CBSMsg1List"]
    CHECK_LIST_NULL{"inList == null"}
    CREATE_DETAIL_ARRAY["Create CAANMsg array 1
EKK0011D020CBSMsg1List
39 fields set to null"]
    SET_TEMPLATE_ARRAY["template set EKK0011D020CBSMSG1LIST"]

    SET_NULL_UNCOND --> GET_CHILD_LIST
    GET_CHILD_LIST --> CHECK_LIST_NULL
    CHECK_LIST_NULL -->|"Yes"| CREATE_DETAIL_ARRAY
    CHECK_LIST_NULL -->|"No"| SKIP_DETAIL["Skip detail creation"]
    CREATE_DETAIL_ARRAY --> SET_TEMPLATE_ARRAY
    SKIP_DETAIL --> WRAP_RETURN

    WRAP_RETURN["Wrap template in array
param put TEMPLATE_LIST_KEY
return paramMap"]
    SET_TEMPLATE_ARRAY --> WRAP_RETURN
    SKIP_DETAIL --> WRAP_RETURN

    WRAP_RETURN --> END(["Return paramMap"])
```

## 3. Parameter Analysis

| No | Parameter Name | Type | Business Description |
|----|---------------|------|---------------------|
| 1 | `param` | `IRequestParameterReadWrite` | The request parameter object that carries both **control data** (operator ID, operating date/time from the session control map) and **user data** (the `KKSV0546CCList` hash map containing order-related screen data). It is also mutated in-place by `editInMsg(param)` for common area setup, and by `param.put(TEMPLATE_LIST_KEY, templates)` to attach the assembled template for downstream SC dispatch. |
| 2 | `dataMap` | `Map<String, Object>` | A map containing execution context metadata. Specifically, it provides the **function code** (`JCMConstants.FUNC_CODE_KEY`) which overrides the default `"1"` value set during template initialization. The function code identifies the calling business scenario (e.g., new subscription, contract change). |
| 3 | `childMap` | `HashMap<String, Object>` | Carries the **Order Content Approval Registration data** submitted from the UI — this is the child/order detail data for the approval registration. Contains fields such as `sysid`, `mskm_sbt_cd` (application type code), `mskmsho_ariv_ymd` (application receipt date), `kari_mskm_flg` (provisional application flag), `cust_yobo_jiko` (customer request items), and 14 other customer-facing order fields. |

**External state / instance fields read:**

| Field | Type | Business Description |
|-------|------|---------------------|
| (none directly) | — | This method is stateless; all state is passed via parameters. It delegates to `editInMsg(param)` which may read instance-level template configuration. |

## 4. CRUD Operations / Called Services

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

| CRUD | SC / CBS | SC Code | Entity / DB | Operation Description |
|------|----------|---------|-------------|----------------------|
| U | `editInMsg` | JKKSeikySakiHeigoCC | - | Calls `editInMsg(param)` to populate common area fields (operator ID, operating date, etc.) from control map data |
| R | `param.getData` | - | - | Reads user data from `KKSV0546CCList` — the screen's user data hash map |

**Additional calls within this method (message builder operations, no database interaction):**

| CRUD | SC / CBS | SC Code | Entity / DB | Operation Description |
|------|----------|---------|-------------|----------------------|
| U | `CAANMsg.set` / `CAANMsg.setNull` | - | - | Populates the `EKK0011D020CBSMsg` template with 17 mapped fields + common metadata (template ID, function code, operator info). These are in-memory field assignments. |
| U | `CAANMsg[]` creation | - | - | Creates the nested `EKK0011D020CBSMsg1List` detail message array with 39 null-initialized fields when `inList` is null. |
| U | `paramMap.put` | - | - | Inserts the assembled `CAANMsg[]` templates into the return parameter map keyed by `JCMConstants.TEMPLATE_LIST_KEY`. |

**Analysis:** This method performs **zero database operations**. It is purely a **message construction/builder** method. All operations are in-memory `set()` and `setNull()` calls on `CAANMsg` objects. The actual CRUD happens in the called CBS `EKK0011D020CBS` (invoked by `scCall.run()` in the caller `execEKK0011D020`).

## 5. Dependency Trace

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

No screen/batch entry points found within 8 hops. Direct callers found: 1 method within this class.

| # | Caller (Screen/Batch) | Call Chain (Full Path to this Method) | Terminal (SC / CRUD / Entity) |
|---|----------------------|--------------------------------------|-------------------------------|
| 1 | `JKKSeikySakiHeigoCC.execEKK0011D020()` | `execEKK0011D020()` -> `editInMsg_EKK0011D020()` | `editInMsg[paramMap.put]`, `setNull` [-] x15, `CAANMsg.set` [-] x17, `CAANMsg[]` creation [-] |

**Additional callers found across the codebase (same method name in different classes):**

| # | Caller (Screen/Batch) | Call Chain (Full Path to this Method) | Terminal (SC / CRUD / Entity) |
|---|----------------------|--------------------------------------|-------------------------------|
| 2 | `JKKSeikyKeiHenkoCC` | `JKKSeikyKeiHenkoCC` (own copy of `editInMsg_EKK0011D020`) | — (same class, different file) |
| 3 | `JKKEohTvCourseChgClCC` | `JKKEohTvCourseChgClCC` (own copy) | — (same class, different file) |
| 4 | `JKKEohTvCourseChgCC` | `JKKEohTvCourseChgCC` (own copy) | — (same class, different file) |
| 5 | `JKKCreateNhkDntIktCC` | `JKKCreateNhkDntIktCC` (own copy) | — (same class, different file) |

**Note:** The method `editInMsg_EKK0011D020` is **re-implemented** in multiple CC classes (`JKKSeikyKeiHenkoCC`, `JKKEohTvCourseChgClCC`, `JKKEohTvCourseChgCC`, `JKKCreateNhkDntIktCC`) with nearly identical logic. The version documented here is the canonical implementation in `JKKSeikySakiHeigoCC` which serves as the primary entry point via `execEKK0011D020()`. The actual CBS call (`EKK0011D020CBS`) reaches terminal operations in the CBS layer.

## 6. Per-Branch Detail Blocks

**Block 1** — [SET] `editInMsg(param)` Common area setup (L752)

> Calls `editInMsg(param)` to initialize common area data (control map fields, template configuration) in the parameter object. Returns a `paramMap` that will be returned at the end.

| # | Type | Code |
|---|------|------|
| 1 | CALL | `paramMap = editInMsg(param)` // Common area setup, returns paramMap [-> EDIT_IN_MSG] |

---

**Block 2** — [SET] Create CAANMsg template (L754)

> Instantiates a `CAANMsg` object typed to `EKK0011D020CBSMsg` for the Order Content Approval Registration service.

| # | Type | Code |
|---|------|------|
| 1 | SET | `template = new CAANMsg(EKK0011D020CBSMsg.class.getName())` // Create CBS message template |

---

**Block 3** — [SET] Set template ID (L757)

> Sets the template identifier to `"EKK0011D020"`.

| # | Type | Code |
|---|------|------|
| 1 | SET | `template.set(EKK0011D020CBSMsg.TEMPLATEID, TEMPLATE_ID_EKK0011D020)` // [-> TEMPLATE_ID_EKK0011D020 = "EKK0011D020"] |

---

**Block 4** — [SET] Set default FUNC_CODE (L759)

> Sets the initial function code to `"1"`, which will later be overridden by the actual function code from `dataMap`.

| # | Type | Code |
|---|------|------|
| 1 | SET | `template.set(EKK0011D020CBSMsg.FUNC_CODE, "1")` // Default function code |

---

**Block 5** — [SET] Read operator ID (L762-L763)

> Extracts the logged-in operator's user ID from the control map and sets it in the template.

| # | Type | Code |
|---|------|------|
| 1 | SET | `operatorId = param.getControlMapData(SCControlMapKeys.OPERATOR_ID)` // Read operator from control map |
| 2 | SET | `template.set(JCMConstants.OPERATOR_ID_KEY, operatorId)` // Set operator in template |

---

**Block 6** — [SET] Read operating date (L766-L767)

> Extracts the operating date from the control map.

| # | Type | Code |
|---|------|------|
| 1 | SET | `operateDate = param.getControlMapData(SCControlMapKeys.OPE_DATE)` // Read operating date |
| 2 | SET | `template.set(JCMConstants.OPERATE_DATE_KEY, operateDate)` // Set in template |

---

**Block 7** — [SET] Read operating datetime (L770-L771)

> Extracts the operating time from the control map.

| # | Type | Code |
|---|------|------|
| 1 | SET | `operateDateTime = param.getControlMapData(SCControlMapKeys.OPE_TIME)` // Read operating time |
| 2 | SET | `template.set(JCMConstants.OPERATE_DATETIME_KEY, operateDateTime)` // Set in template |

---

**Block 8** — [SET] Get work map (L776)

> Retrieves the mapping work area (unused in current code; commented-out reference to `KKSV054407SCWORK`).

| # | Type | Code |
|---|------|------|
| 1 | SET | `workMap = param.getMappingWorkArea()` // Get work mapping area [-> UNUSED] |

---

**Block 9** — [SET] Read user data, overwrite FUNC_CODE (L784-L786)

> Reads the screen's user data hash map and overwrites the function code with the actual value from `dataMap`.

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `inMap = (HashMap)param.getData("KKSV0546CCList")` // Read user data info |
| 2 | SET | `template.set(EKK0011D020CBSMsg.FUNC_CODE, dataMap.get(JCMConstants.FUNC_CODE_KEY))` // Overwrite FUNC_CODE from dataMap |

---

**Block 10** — [IF-ELSE] Map sysid field (L789-L793)

> Maps the SYSID from childMap, or sets null if empty.

| # | Type | Code |
|---|------|------|
| 1 | IF | `"".equals(childMap.get("sysid"))` [-> CONDITION: empty string check] |
| 1.1 | SET | `template.setNull(EKK0011D020CBSMsg.SYSID)` // SYSID is empty, set null |
| 1.2 | SET | `template.set(EKK0011D020CBSMsg.SYSID, (String)childMap.get("sysid"))` // SYSID is present |

---

**Block 11** — [IF-ELSE] Map mskm_sbt_cd field (L796-L800)

> Maps the application type code — classifies what type of application this is (e.g., new subscription, change, renewal).

| # | Type | Code |
|---|------|------|
| 1 | IF | `"".equals(childMap.get("mskm_sbt_cd"))` [-> CONDITION: empty string check] |
| 1.1 | SET | `template.setNull(EKK0011D020CBSMsg.MSKM_SBT_CD)` // Application type code is empty |
| 1.2 | SET | `template.set(EKK0011D020CBSMsg.MSKM_SBT_CD, (String)childMap.get("mskm_sbt_cd"))` // Application type code is present |

---

**Block 12** — [IF-ELSE] Map mskmsho_ariv_ymd field (L803-L807)

> Maps the application receipt date (year/month/day when the application was received).

| # | Type | Code |
|---|------|------|
| 1 | IF | `"".equals(childMap.get("mskmsho_ariv_ymd"))` |
| 1.1 | SET | `template.setNull(EKK0011D020CBSMsg.MSKMSHO_ARIV_YMD)` // Empty |
| 1.2 | SET | `template.set(EKK0011D020CBSMsg.MSKMSHO_ARIV_YMD, (String)childMap.get("mskmsho_ariv_ymd"))` // Has value |

---

**Block 13** — [IF-ELSE] Map mskm_uk_dtm field (L810-L814)

> Maps the application receipt datetime (year/month/day + hour:minute:second when the application was received).

| # | Type | Code |
|---|------|------|
| 1 | IF | `"".equals(childMap.get("mskm_uk_dtm"))` |
| 1.1 | SET | `template.setNull(EKK0011D020CBSMsg.MSKM_UK_DTM)` // Empty |
| 1.2 | SET | `template.set(EKK0011D020CBSMsg.MSKM_UK_DTM, (String)childMap.get("mskm_uk_dtm"))` // Has value |

---

**Block 14** — [IF-ELSE] Map mskm_uk_tnt_user_id field (L817-L821)

> Maps the application receipt responsible user ID — the user ID of the person who received/processed this application.

| # | Type | Code |
|---|------|------|
| 1 | IF | `"".equals(childMap.get("mskm_uk_tnt_user_id"))` |
| 1.1 | SET | `template.setNull(EKK0011D020CBSMsg.MSKM_UK_TNT_USER_ID)` // Empty |
| 1.2 | SET | `template.set(EKK0011D020CBSMsg.MSKM_UK_TNT_USER_ID, (String)childMap.get("mskm_uk_tnt_user_id"))` // Has value |

---

**Block 15** — [IF-ELSE] Map mskm_ymd field (L824-L828)

> Maps the application date (year/month/day of the application).

| # | Type | Code |
|---|------|------|
| 1 | IF | `"".equals(childMap.get("mskm_ymd"))` |
| 1.1 | SET | `template.setNull(EKK0011D020CBSMsg.MSKM_YMD)` // Empty |
| 1.2 | SET | `template.set(EKK0011D020CBSMsg.MSKM_YMD, (String)childMap.get("mskm_ymd"))` // Has value |

---

**Block 16** — [IF-ELSE] Map ttl_business_center_uk_no field (L831-L835)

> Maps the total business center receipt number — the internal receipt number for the comprehensive business center.

| # | Type | Code |
|---|------|------|
| 1 | IF | `"".equals(childMap.get("ttl_business_center_uk_no"))` |
| 1.1 | SET | `template.setNull(EKK0011D020CBSMsg.TTL_BUSINESS_CENTER_UK_NO)` // Empty |
| 1.2 | SET | `template.set(EKK0011D020CBSMsg.TTL_BUSINESS_CENTER_UK_NO, (String)childMap.get("ttl_business_center_uk_no"))` // Has value |

---

**Block 17** — [IF-ELSE] Map ttl_business_mskm_opt_cd field (L838-L842)

> Maps the total business application option code — the option/plan selected for the comprehensive business application.

| # | Type | Code |
|---|------|------|
| 1 | IF | `"".equals(childMap.get("ttl_business_mskm_opt_cd"))` |
| 1.1 | SET | `template.setNull(EKK0011D020CBSMsg.TTL_BUSINESS_MSKM_OPT_CD)` // Empty |
| 1.2 | SET | `template.set(EKK0011D020CBSMsg.TTL_BUSINESS_MSKM_OPT_CD, (String)childMap.get("ttl_business_mskm_opt_cd"))` // Has value |

---

**Block 18** — [IF-ELSE] Map mskm_rrks_telno field (L845-L849)

> Maps the application contact phone number — the phone number provided for application-related communication.

| # | Type | Code |
|---|------|------|
| 1 | IF | `"".equals(childMap.get("mskm_rrks_telno"))` |
| 1.1 | SET | `template.setNull(EKK0011D020CBSMsg.MSKM_RRKS_TELNO)` // Empty |
| 1.2 | SET | `template.set(EKK0011D020CBSMsg.MSKM_RRKS_TELNO, (String)childMap.get("mskm_rrks_telno"))` // Has value |

---

**Block 19** — [IF-ELSE] Map mskm_jssis_sbt_cd field (L852-L856)

> Maps the application executor type code — the type/category of the entity executing the application (e.g., self, agent, dealer).

| # | Type | Code |
|---|------|------|
| 1 | IF | `"".equals(childMap.get("mskm_jssis_sbt_cd"))` |
| 1.1 | SET | `template.setNull(EKK0011D020CBSMsg.MSKM_JSSIS_SBT_CD)` // Empty |
| 1.2 | SET | `template.set(EKK0011D020CBSMsg.MSKM_JSSIS_SBT_CD, (String)childMap.get("mskm_jssis_sbt_cd"))` // Has value |

---

**Block 20** — [IF-ELSE] Map cust_yobo_jiko field (L859-L863)

> Maps the customer request items — free-text or coded field capturing any special requests from the customer.

| # | Type | Code |
|---|------|------|
| 1 | IF | `"".equals(childMap.get("cust_yobo_jiko"))` |
| 1.1 | SET | `template.setNull(EKK0011D020CBSMsg.CUST_YOBO_JIKO)` // Empty |
| 1.2 | SET | `template.set(EKK0011D020CBSMsg.CUST_YOBO_JIKO, (String)childMap.get("cust_yobo_jiko"))` // Has value |

---

**Block 21** — [IF-ELSE] Map tel_rrk_kibo_time_cd field (L866-L870)

> Maps the preferred contact time period code — the customer's preferred time window for phone contact.

| # | Type | Code |
|---|------|------|
| 1 | IF | `"".equals(childMap.get("tel_rrk_kibo_time_cd"))` |
| 1.1 | SET | `template.setNull(EKK0011D020CBSMsg.TEL_RRK_KIBO_TIME_CD)` // Empty |
| 1.2 | SET | `template.set(EKK0011D020CBSMsg.TEL_RRK_KIBO_TIME_CD, (String)childMap.get("tel_rrk_kibo_time_cd"))` // Has value |

---

**Block 22** — [IF-ELSE] Map takcho_kibo_time_cd field (L873-L877)

> Maps the preferred home survey time period code — the customer's preferred time window for on-site installation surveys.

| # | Type | Code |
|---|------|------|
| 1 | IF | `"".equals(childMap.get("takcho_kibo_time_cd"))` |
| 1.1 | SET | `template.setNull(EKK0011D020CBSMsg.TAKCHO_KIBO_TIME_CD)` // Empty |
| 1.2 | SET | `template.set(EKK0011D020CBSMsg.TAKCHO_KIBO_TIME_CD, (String)childMap.get("takcho_kibo_time_cd"))` // Has value |

---

**Block 23** — [IF-ELSE] Map kari_mskm_flg field (L880-L884)

> Maps the provisional application flag — indicates whether this is a provisional/pending application (as opposed to a confirmed one).

| # | Type | Code |
|---|------|------|
| 1 | IF | `"".equals(childMap.get("kari_mskm_flg"))` |
| 1.1 | SET | `template.setNull(EKK0011D020CBSMsg.KARI_MSKM_FLG)` // Empty |
| 1.2 | SET | `template.set(EKK0011D020CBSMsg.KARI_MSKM_FLG, (String)childMap.get("kari_mskm_flg"))` // Has value |

---

**Block 24** — [IF-ELSE] Map referer field (L887-L891)

> Maps the referer — the source/referrer from which the application was submitted (e.g., web page URL).

| # | Type | Code |
|---|------|------|
| 1 | IF | `"".equals(childMap.get("referer"))` |
| 1.1 | SET | `template.setNull(EKK0011D020CBSMsg.REFERER)` // Empty |
| 1.2 | SET | `template.set(EKK0011D020CBSMsg.REFERER, (String)childMap.get("referer"))` // Has value |

---

**Block 25** — [IF-ELSE] Map kepco_custinfo_juju_doi_um field (L894-L898)

> Maps the KEPCO customer information consent yes/no flag — whether the customer has consented to sharing information with KEPCO (Kansai Electric Power Company).

| # | Type | Code |
|---|------|------|
| 1 | IF | `"".equals(childMap.get("kepco_custinfo_juju_doi_um"))` |
| 1.1 | SET | `template.setNull(EKK0011D020CBSMsg.KEPCO_CUSTINFO_JUJU_DOI_UM)` // Empty |
| 1.2 | SET | `template.set(EKK0011D020CBSMsg.KEPCO_CUSTINFO_JUJU_DOI_UM, (String)childMap.get("kepco_custinfo_juju_doi_um"))` // Has value |

---

**Block 26** — [IF-ELSE] Map consmbsn_mskm_stat_skbt_cd field (L901-L905)

> Maps the consumer business application status subclass code — the sub-category of application status for consumer services.

| # | Type | Code |
|---|------|------|
| 1 | IF | `"".equals(childMap.get("consmbsn_mskm_stat_skbt_cd"))` |
| 1.1 | SET | `template.setNull(EKK0011D020CBSMsg.CONSMBSN_MSKM_STAT_SKBT_CD)` // Empty |
| 1.2 | SET | `template.set(EKK0011D020CBSMsg.CONSMBSN_MSKM_STAT_SKBT_CD, (String)childMap.get("consmbsn_mskm_stat_skbt_cd"))` // Has value |

---

**Block 27** — [SET] Set 8 fields to null unconditionally (L908-L915)

> These fields are not mapped from childMap and are always initialized to null. They may be populated by downstream CBS processing or left for future use.

| # | Type | Code |
|---|------|------|
| 1 | SET | `template.setNull(EKK0011D020CBSMsg.TAKCHO_KIBOD_SBT_CD)` // Home survey preferred action type code |
| 2 | SET | `template.setNull(EKK0011D020CBSMsg.TEL_RRK_KIBOD_SBT_CD)` // Phone contact preferred action type code |
| 3 | SET | `template.setNull(EKK0011D020CBSMsg.SHOSA_BF_RRK_JIKO_YH)` // Pre-survey request hours |
| 4 | SET | `template.setNull(EKK0011D020CBSMsg.SHOSA_BF_RRK_JIKO)` // Pre-survey request items |
| 5 | SET | `template.setNull(EKK0011D020CBSMsg.USE_SVC_KEIZK_SBT_CD)` // Active service details type code |
| 6 | SET | `template.setNull(EKK0011D020CBSMsg.KOJI_REQ_INFO_RRK_JIKO)` // Construction request information items |
| 7 | SET | `template.setNull(EKK0011D020CBSMsg.UK_TNTSHA_SKBT_CD)` // Receipt contact subclass code |
| 8 | SET | `template.setNull(EKK0011D020CBSMsg.MSKM_ROUTE_SKBT_CD)` // Application route subclass code |

---

**Block 28** — [IF-ELSE] Create detail message array (L918-L1009)

> Retrieves the `EKK0011D020CBSMsg1List` from childMap. If it is null, creates a new CAANMsg array with a detail message object containing 39 fields (all initialized to null) for order content detail items. This is the only conditional branch in the method.

| # | Type | Code |
|---|------|------|
| 1 | SET | `inList = (ArrayList)childMap.get("EKK0011D020CBSMsg1List")` // Get child detail list |
| 2 | IF | `inList == null` [-> CONDITION: detail list is absent] |
| 2.1 | SET | `templateArray = new CAANMsg[1]` // Create array of size 1 |
| 2.2 | SET | `templateArray[0] = new CAANMsg(EKK0011D020CBSMsg1List.class.getName())` // Create detail message |
| 2.3 | SET | `templateArray[0].setNull(...)` x39 // Set 39 detail fields to null |
| 2.4 | SET | `template.set(EKK0011D020CBSMsg.EKK0011D020CBSMSG1LIST, templateArray)` // Attach detail array |
| 2.5 | ELSE | // inList is not null — skip detail creation (detail data already available from childMap) |

**Block 28.1** — Detail fields set to null (within Block 28.1.1)

| # | Type | Code |
|---|------|------|
| 1 | SET | `setNull(MSKMSHO_NO)` // Application number |
| 2 | SET | `setNull(WEB_UK_NO)` // Web receipt number |
| 3 | SET | `setNull(MSKM_FORM_CD)` // Application form code |
| 4 | SET | `setNull(MSKM_DTL_SBT_CD)` // Application detail type code |
| 5 | SET | `setNull(RRKS_KTAI_TELNO)` // Contact mobile phone number |
| 6 | SET | `setNull(RRKS_OFFC_NM)` // Contact business name |
| 7 | SET | `setNull(DT_RRKS_TELNO)` // Daytime contact phone number |
| 8 | SET | `setNull(NEW_MSKM_SBT_CD)` // New application type code |
| 9 | SET | `setNull(MSKM_OPTNTY_CD)` // Application contract code |
| 10 | SET | `setNull(TAKCHO_KIBO_APO_KIGEN_YMD)` // Home survey preferred appointment deadline |
| 11 | SET | `setNull(KOJI_APO_RRKS_SHITEI_CD)` // Construction appointment contact designation code |
| 12 | SET | `setNull(KOJI_APO_RRKS_TELNO)` // Construction appointment contact phone |
| 13 | SET | `setNull(RRK_JIKO_ADD_DTM)` // Contact items registration datetime |
| 14 | SET | `setNull(MSKM_RRKS_MLAD)` // Application contact email address |
| 15 | SET | `setNull(KOJI_PRG_TCHI_MLAD)` // Construction progress notification email address |
| 16 | SET | `setNull(RRK_JIKO)` // Contact items |
| 17 | SET | `setNull(KJSC_TCH_KTAI_MLAD)` // Construction progress notification mobile email |
| 18 | SET | `setNull(ML_SEND_JGI_FLG)` // Email send exclusion flag |
| 19 | SET | `setNull(ML_SEND_JGI_RSN_MEMO)` // Email send exclusion reason memo |
| 20 | SET | `setNull(BMP_MSKM_RRKS_TLN)` // Telemarketing application contact phone |
| 21 | SET | `setNull(RRK_WAY_HOKI)` // Contact method supplement |
| 22 | SET | `setNull(NEWCONST_BUKKEN_CD)` // New building code |
| 23 | SET | `setNull(HUKKAT_ANKEN_FLG)` // Reactivation case flag |
| 24 | SET | `setNull(SAME_EQUIP_RE_MSKM_CD)` // Same equipment re-application code |
| 25 | SET | `setNull(OP_SVC_HKTGI_UM)` // Optional service target flag |
| 26 | SET | `setNull(MSKMSHO_SBT_CD)` // Application receipt type code |
| 27 | SET | `setNull(DSL_ATICLE_SOHU_KIBO_UM)` // ADSL article source preference flag |
| 28 | SET | `setNull(MAP_TEMP_UM)` // Map temperature flag |
| 29 | SET | `setNull(KCN_STB_KIND_CD)` // Set-top box type code |
| 30 | SET | `setNull(KCN_STB_MSKM_CNT)` // Set-top box application count |
| 31 | SET | `setNull(HNIN_CFM_ATICLE_SBT_CD)` // NHK contract confirmation article type code |
| 32 | SET | `setNull(KEI_HUKA_CD)` // Contract add-on code |
| 33 | SET | `setNull(MANSSBSYS_RNKI_YO_KIJIRAN)` // Mansion system integration remarks |
| 34 | SET | `setNull(MANSION_ID)` // Mansion ID |
| 35 | SET | `setNull(CATID)` // CAT-ID |
| 36 | SET | `setNull(MKM_UK_SBT_CD)` // Application receipt type code |
| 37 | SET | `setNull(MSKMSHO_TRAT_IF_TNTSHA_NM)` // Application receipt handling contact person name |
| 38 | SET | `setNull(MSKMSHO_TRAT_IF_TELNO)` // Application receipt handling contact phone |

---

**Block 29** — [SET] Wrap and return (L1012-L1015)

> Wraps the single `template` in a `CAANMsg[]` array, puts it into `paramMap` under `TEMPLATE_LIST_KEY`, and returns the map for the caller.

| # | Type | Code |
|---|------|------|
| 1 | SET | `templates = new CAANMsg[1]` // Create template array |
| 2 | SET | `templates[0] = template` // Assign assembled template |
| 3 | SET | `paramMap.put(JCMConstants.TEMPLATE_LIST_KEY, templates)` // Store in paramMap |
| 4 | RETURN | `return paramMap` // Return to execEKK0011D020 for SC dispatch |

## 7. Glossary

| Term | Type | Business Meaning |
|------|------|------------------|
| `sysid` | Field | System ID — internal system identifier for the order record |
| `mskm_sbt_cd` | Field | Application type code — classifies the type of application (e.g., new subscription, change, renewal) |
| `mskmsho_ariv_ymd` | Field | Application receipt date — the date (YYYYMMDD) when the application was received |
| `mskm_uk_dtm` | Field | Application receipt datetime — the full timestamp (year/month/day + hour/minute/second) when the application was received |
| `mskm_uk_tnt_user_id` | Field | Application receipt responsible user ID — the user ID of the operator who received/processed the application |
| `mskm_ymd` | Field | Application date — the date (YYYYMMDD) when the application was made |
| `ttl_business_center_uk_no` | Field | Total business center receipt number — the internal receipt number assigned by the comprehensive business center |
| `ttl_business_mskm_opt_cd` | Field | Total business application option code — the service option/plan selected for the application |
| `mskm_rrks_telno` | Field | Application contact phone number — the phone number for application-related communication |
| `mskm_jssis_sbt_cd` | Field | Application executor type code — the type of entity executing the application (self, agent, dealer, etc.) |
| `cust_yobo_jiko` | Field | Customer request items — special requests or notes provided by the customer |
| `tel_rrk_kibo_time_cd` | Field | Preferred contact time period code — the customer's preferred time window for phone contact |
| `takcho_kibo_time_cd` | Field | Preferred home survey time period code — the customer's preferred time window for on-site installation surveys |
| `kari_mskm_flg` | Field | Provisional application flag — indicates whether the application is provisional/pending |
| `referer` | Field | Referrer — the source page or channel from which the application was submitted |
| `kepco_custinfo_juju_doi_um` | Field | KEPCO customer information consent flag — whether the customer consented to sharing data with Kansai Electric Power Company |
| `consmbsn_mskm_stat_skbt_cd` | Field | Consumer business application status subclass code — sub-category of application status for consumer services |
| `TEMPLATE_ID_EKK0011D020` | Constant | Template identifier `"EKK0011D020"` — uniquely identifies the Order Content Approval Registration message template |
| FUNC_CODE | Field | Function code — identifies the calling business scenario (e.g., new subscription = "1") |
| EKK0011D020CBS | CBS | Order Content Approval Registration Service Component — the backend CBS that processes the approval registration |
| EKK0011D020CBSMsg | CBS Message | Root message class for the EKK0011D020 CBS — contains header/metadata fields |
| EKK0011D020CBSMsg1List | CBS Message | Detail message class — contains order detail line-item fields (39 fields total) |
| CAANMsg | Framework | Fujitsu's generic message wrapper class used for CBS communication in the x21 framework |
| CC | Acronym | Common Component — a shared service layer class (extends `AbstractCommonComponent`) providing reusable business logic |
| SC | Acronym | Service Component — the backend service tier invoked via `ServiceComponentRequestInvoker` |
| CBS | Acronym | Center Business System — the backend transaction processing system for telecom business operations |
| FTTH | Business term | Fiber To The Home — fiber-optic broadband internet service offered by K-Opticom |
| KKSV0546CCList | Field | Screen data key — the user data hash map identifier for the order approval registration screen data |
| NHK | Business term | Nippon Hoso Kyokai — Japan Broadcasting Corporation; `HNIN_CFM_ATICLE_SBT_CD` relates to NHK contract confirmation |
| KEPCO | Business term | Kansai Electric Power Company — regional utility provider; customer consent is required for data sharing |
| MSKM | Acronym | Moshikomi (申し込み) — Application / Order submission in Japanese telecom context |
| MSKMSHO | Acronym | Moshikomi-sho (申込書) — Application form / receipt |
| RRKS | Acronym | Renraku (連絡) — Contact / Communication |
| TAKCHO | Acronym | Tachichoucho (立町場調査) — On-site survey / site inspection for installation |
| KOJI | Acronym | Kouji (工事) — Construction / Installation work |
