# Business Logic — JKKSeikyKeiBunkatsuCC.editInMsg_EKU0031C010() [1484 LOC]

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

## 1. Role

### JKKSeikyKeiBunkatsuCC.editInMsg_EKU0031C010()

This method constructs the inbound message template (CAANMsg) for the **"eo Light TV Various Changes" (eo光テレビ諸変更) work order screen (EKU0031)**. It is responsible for mapping all business data from the request parameter area, data map, and child map into a structured message template that will be passed downstream to the CBS (Common Business Service) layer for screen rendering and validation.

The method handles **two distinct data routing paths** based on the service contract status: when the status is "received" (010), the detail number comes directly from the child map; otherwise, it is extracted from the result list `KKSV054601SCWORKLIST`. For the **confirmation screen** (`funcCd = "2"`), the service contract number is sourced from the child map rather than the work data map, to reflect the pre-existing record.

The method implements the **Builder pattern** combined with **Delegation**: it delegates the base common-area initialization to `editInMsg(param)` (inherited from a parent class), then builds a `CAANMsg` template instance, populates dozens of fields through repetitive conditional assignment (null-check-then-set), resets a large set of irrelevant fields to null, and finally packages the result into a template array under `JCMConstants.TEMPLATE_LIST_KEY`.

This is a **shared utility method** called from the screen's execution entry point (`execEKU0031C010`). It serves as the central data-mapping and message-construction layer for the EKU0031 work order screen, ensuring all 140+ fields are properly populated before being passed to downstream components.

## 2. Processing Pattern (Detailed Business Logic)

```mermaid
flowchart TD
    START(["editInMsg_EKU0031C010 params"])

    START --> S1["S1: Common area setup
call editInMsg(param)
create CAANMsg template"]
    S1 --> S2["S2: Set template ID
FUNC_CODE \"1\"
operator/date/time from control map"]
    S2 --> S3["S3: Get work mapping area"]
    S3 --> S4["S4: Get service contract status code
from childMap"]
    S4 --> S5{stateCd == "010"
(received)?}

    S5 -- Yes --> S6["S6-A: Detail number from childMap
kksv040325_mskm_dtl_no"]
    S5 -- No --> S7["S6-B: Get meisaiList from
KKSV054601SCWORKLIST"]
    S7 --> S7A{meisaiList empty?}
    S7A -- Yes --> S6A["S6-B1: Set MSKM_DTL_NO to null"]
    S7A -- No --> S7B["S6-B2: Extract meisai from
list[0].ekk0011d020_mskm_dtl_no"]
    S7B --> S7C{meisai null or empty?}
    S7C -- Yes --> S6A
    S7C -- No --> S6B["S6-B3: Set MSKM_DTL_NO = meisai"]

    S6 --> S8["S8: Get funcCd from dataMap"]
    S6B --> S8
    S6A --> S8

    S8 --> S9{funcCd == "2"
(confirmation)?}
    S9 -- Yes --> S10["S9-A: Set SEIKY_KEI_NO from
childMap kksv040325_seiky_kei_no"]
    S9 -- No --> S11["S9-B: Set SEIKY_KEI_NO from
dataMap ekk0491d010_seiky_kei_no"]
    S10 --> S12["S12: Set FUNC_CODE = funcCd"]
    S11 --> S12

    S12 --> S13["S13: Map childMap fields to template
Service info, pricing, plan, address
Customer info, residence details
Construction info, GPS coords
Move-before/after addresses
New building, schedule dates
Contact preferences, notes"]

    S13 --> S14["S14: Reset place fields to null
Set place, delivery address, etc."]

    S14 --> S15["S15: Reset device fields to null
Construction info, device1-20
Change-before device1-20
Memo1-20, ChgNo1-20
Original T-CaseNo1-20"]

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

**Key processing logic:**

| Step | Description |
|------|-------------|
| S1-S3 | Common area initialization — delegates to `editInMsg(param)`, creates `CAANMsg` template with class `EKU0031C010CBSMsg`, sets TEMPLATE_ID_EKU0031C010 = "EKU0031C010", FUNC_CODE = "1" (placeholder, overridden at S12), and extracts operator ID, operate date, and operate time from the control map. |
| S4-S6 | Detail number mapping — branches on `stateCd`. If "010" (Service Contract Received), reads `kksv040325_mskm_dtl_no` from childMap. Otherwise, reads from the `KKSV054601SCWORKLIST` list in dataMap, extracting the first item's `ekk0011d020_mskm_dtl_no`. |
| S8-S12 | Service contract number and function code — if `funcCd = "2"` (confirmation mode), reads `kksv040325_seiky_kei_no` from childMap (pre-existing record); otherwise reads from dataMap. Then overrides FUNC_CODE with the actual `funcCd` value. |
| S13 | Core field mapping — 100+ if/else blocks map fields from childMap to template, each checking for empty string and calling `set()` or `setNull()` accordingly. |
| S14-S15 | Reset irrelevant fields — bulk `setNull()` calls clear set-place fields, device fields (20 devices x ~17 fields each), and memo fields. |

## 3. Parameter Analysis

| No | Parameter Name | Type | Business Description |
|----|---------------|------|---------------------|
| 1 | `param` | `IRequestParameterReadWrite` | The request parameter I/O interface carrying all screen-bound data. Contains the control map (operator ID, operate date, operate time), the work mapping area (key data repository), and serves as the output channel for the built template list via `paramMap.put()`. |
| 2 | `dataMap` | `Map<String, Object>` | The work data map carrying business data retrieved from SC (Service Component) calls. Contains fields like `ekk0491d010_seiky_kei_no_work` (service contract number work field), `KKSV054601SCWORKLIST` (order detail list from SC), and `JCMConstants.FUNC_CODE_KEY` (function code identifying the screen mode). |
| 3 | `childMap` | `HashMap<String, Object>` | The child/child-data map carrying work-order-specific details and customer information for the eo Light TV various changes screen. Contains over 80 fields covering service contract number, work order number, customer name/address, construction details, GPS coordinates, and device configurations. |

**Control data read from `param`:**
- `SCControlMapKeys.OPERATOR_ID` — Current operator/user ID
- `SCControlMapKeys.OPE_DATE` — Operation date
- `SCControlMapKeys.OPE_TIME` — Operation time
- `param.getMappingWorkArea()` — Work mapping area reference

## 4. CRUD Operations / Called Services

| CRUD | SC / CBS | SC Code | Entity / DB | Operation Description |
|------|----------|---------|-------------|----------------------|
| U | `JKKSeikyKeiBunkatsuCC.editInMsg` | - | - | Delegates to parent method `editInMsg(param)` to initialize common area fields in the parameter map (operator ID, date, time, etc.). |
| R | `SCW00701SFLogic.getName` | SCW00701SFLogic | - | Called indirectly via the pre-computed caller chain for SC lookups (used for name resolution in the data retrieval path). |

**Note:** This method is a **pure message builder** — it does not directly call any database or SC methods that perform CRUD operations. It consumes data already populated in `dataMap` and `childMap` by upstream caller methods (e.g., `execEKU0031C010`), then maps them into a `CAANMsg` template. The `setNull()` and `set()` calls are template population operations, not database operations.

## 5. Dependency Trace

| # | Caller (Screen/Batch) | Call Chain (Full Path to this Method) | Terminal (SC / CRUD / Entity) |
|---|----------------------|--------------------------------------|-------------------------------|
| 1 | CBS: `JKKSeikyKeiBunkatsuCC.execEKU0031C010` | `execEKU0031C010` -> `editInMsg_EKU0031C010` | `editInMsg` [U] - (common area init), `setNull` [-] (template field reset) |

**Note:** The method is exclusively called from `JKKSeikyKeiBunkatsuCC.execEKU0031C010()` within the same class. This execution method is the screen entry point for the "eo Light TV Various Changes" work order screen (EKU0031). No other screen or batch entry points were found that call this method directly.

## 6. Per-Branch Detail Blocks

**Block 1** — [SET] Common Area Initialization (L11082)

> Initializes the base parameter map and creates the message template.

| # | Type | Code |
|---|------|------|
| 1 | CALL | `editInMsg(param)` // Delegate to parent for common area setup [-> paramMap] |
| 2 | SET | `template = new CAANMsg(EKU0031C010CBSMsg.class.getName())` // Create message template |
| 3 | SET | `template.set(EKU0031C010CBSMsg.TEMPLATEID, TEMPLATE_ID_EKU0031C010)` // TEMPLATE_ID_EKU0031C010 = "EKU0031C010" |
| 4 | SET | `template.set(EKU0031C010CBSMsg.FUNC_CODE, "1")` // Placeholder FUNC_CODE, overridden later |
| 5 | SET | `operatorId = param.getControlMapData(SCControlMapKeys.OPERATOR_ID)` |
| 6 | EXEC | `template.set(JCMConstants.OPERATOR_ID_KEY, operatorId)` |
| 7 | SET | `operateDate = param.getControlMapData(SCControlMapKeys.OPE_DATE)` |
| 8 | EXEC | `template.set(JCMConstants.OPERATE_DATE_KEY, operateDate)` |
| 9 | SET | `operateDateTime = param.getControlMapData(SCControlMapKeys.OPE_TIME)` |
| 10 | EXEC | `template.set(JCMConstants.OPERATE_DATETIME_KEY, operateDateTime)` |
| 11 | SET | `workMap = param.getMappingWorkArea()` // Get work mapping area |

---

**Block 2** — [IF] Detail Number Mapping — Service Contract Status Check (L11111)

> Branches on service contract status code to determine which data source to use for the detail number.

| # | Type | Code |
|---|------|------|
| 1 | SET | `stateCd = (String)childMap.get("kksv040321_svc_kei_stat_cd")` // Service contract status code |
| 2 | IF | `"010".equals(stateCd)` // "010" = Service Contract Received (受診済) |

**Block 2.1** — [IF-TRUE] stateCd == "010" Detail Number (L11115)

> When the service contract is "received", the detail number comes directly from childMap.

| # | Type | Code |
|---|------|------|
| 1 | IF | `"".equals(childMap.get("kksv040325_mskm_dtl_no"))` // Detail number is empty |
| 1.1 | EXEC | `template.setNull(EKU0031C010CBSMsg.MSKM_DTL_NO)` // Set null |
| 1.2 | ELSE | |
| 1.2.1 | EXEC | `template.set(EKU0031C010CBSMsg.MSKM_DTL_NO, (String)childMap.get("kksv040325_mskm_dtl_no"))` |

**Block 2.2** — [IF-FALSE] stateCd != "010" Detail Number from List (L11124)

> When not "received", extract from the SC work list.

| # | Type | Code |
|---|------|------|
| 1 | SET | `meisaiList = (ArrayList<HashMap<String,String>>)dataMap.get("KKSV054601SCWORKLIST")` // Order detail list |
| 2 | IF | `meisaiList == null \|\| meisaiList.size() == 0` |
| 2.1 | EXEC | `template.setNull(EKU0031C010CBSMsg.MSKM_DTL_NO)` |
| 2.2 | ELSE | |
| 2.2.1 | SET | `workdMap = (HashMap)meisaiList.get(0)` |
| 2.2.2 | SET | `meisai = (String)workdMap.get("ekk0011d020_mskm_dtl_no")` |
| 2.2.3 | IF | `meisai == null \|\| "".equals(meisai)` |
| 2.2.3.1 | EXEC | `template.setNull(EKU0031C010CBSMsg.MSKM_DTL_NO)` |
| 2.2.3.2 | ELSE | |
| 2.2.3.3 | EXEC | `template.set(EKU0031C010CBSMsg.MSKM_DTL_NO, meisai)` |

---

**Block 3** — [IF] Service Contract Number — Confirmation Mode Check (L11148)

> The service contract number is sourced differently in confirmation mode vs. normal mode.

| # | Type | Code |
|---|------|------|
| 1 | SET | `funcCd = (String)dataMap.get(JCMConstants.FUNC_CODE_KEY)` |
| 2 | IF | `"2".equals(funcCd)` // "2" = Confirmation screen mode (確認) |

**Block 3.1** — [IF-TRUE] Confirmation Mode — ChildMap Source (L11151)

> In confirmation mode, read the pre-existing service contract number from childMap.

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `template.set(EKU0031C010CBSMsg.SEIKY_KEI_NO, (String)childMap.get("kksv040325_seiky_kei_no"))` |

**Block 3.2** — [IF-FALSE] Normal Mode — DataMap Source (L11152)

> In normal mode, read from the data map work field.

| # | Type | Code |
|---|------|------|
| 1 | IF | `dataMap == null \|\| dataMap.get("ekk0491d010_seiky_kei_no_work") == null \|\| "".equals(dataMap.get("ekk0491d010_seiky_kei_no_work"))` |
| 1.1 | EXEC | `template.setNull(EKU0031C010CBSMsg.SEIKY_KEI_NO)` |
| 1.2 | ELSE | |
| 1.2.1 | EXEC | `template.set(EKU0031C010CBSMsg.SEIKY_KEI_NO, (String)dataMap.get("ekk0491d010_seiky_kei_no_work"))` |

---

**Block 4** — [SET] Function Code Override (L11159)

> Override the initial placeholder FUNC_CODE with the actual function code.

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `template.set(EKU0031C010CBSMsg.FUNC_CODE, funcCd)` |

---

**Block 5** — [IF chain] Core Field Mapping — Service/Contract Info (L11162–L11253)

> Maps childMap fields to the template. Every block follows the same null-check pattern:
> if empty/null -> `setNull()`, else -> `set()`.

| # | Type | Code |
|---|------|------|
| 1 | IF | `kksv040325_svc_kei_no` -> `SVC_KEI_NO` (Service Contract Number) |
| 2 | IF | `kksv040325_svc_kei_kaisen_ucwk_no` -> `SVC_KEI_KAISEN_UCWK_NO` (Service Contract Modification Work Number) |
| 3 | IF | `kojiak_no` -> `KOJIAK_NO` (Work Order Number) |
| 4 | IF | `kksv040325_koji_uk_cd` -> `KOJI_UK_CD` (Work Order Receipt Code) |
| 5 | IF | `kksv040325_koji_uk_dtail_cd` -> `KOJI_UK_DTAIL_CD` (Work Order Receipt Detail Code) |
| 6 | IF | `kksv040325_koji_uk_optnty_ido_dtm` -> `KOJI_UK_OPTNTY_IDO_DTM` (Work Order Receipt Contract Change DateTime) |
| 7 | IF | `kksv040325_svc_cd` -> `SVC_CD` (Service Code) |
| 8 | IF | `kksv040325_prc_grp_cd` -> `PRC_GRP_CD` (Price Group Code) |
| 9 | IF | `kksv040325_pcrs_cd` -> `PCRS_CD` (Price Course Code) |
| 10 | IF | `plan_chg_fix_ymd` -> `PLAN_CHG_FIX_YMD` (Plan Change Confirmation DateTime) |
| 11 | IF | `ad_chg_fix_dtm` -> `AD_CHG_FIX_DTM` (Address Change Completion DateTime) |
| 12 | IF | `menkaihat_anken_no` -> `MENKAIHAT_ANKEN_NO` (Surface Development Work Order Number) |
| 13 | IF | `mnkht_koji_cd` -> `MNKHT_KOJI_CD` (Surface Development Work Code) |
| 14 | IF | `ownr_kei_no` -> `OWNR_KEI_NO` (Owner Contract Number) |
| 15 | IF | `pid` -> `PID` (P-ID) |
| 16 | IF | `kksv040325_sysid` -> `SYSID` (System ID) |

---

**Block 6** — [IF chain] Core Field Mapping — Customer Information (L11256–L11298)

| # | Type | Code |
|---|------|------|
| 1 | IF | `kksv040325_cust_nm` -> `CUST_NM` (Customer Name) |
| 2 | IF | `kksv040325_cust_kana` -> `CUST_KANA` (Customer Kana Name) |
| 3 | IF | `cust_home_tel_no` -> `CUST_HOME_TEL_NO` (Customer Home Phone Number) |
| 4 | IF | `cust_ktai_tel_no` -> `CUST_KTAI_TEL_NO` (Customer Mobile Phone Number) |
| 5 | IF | `cust_rrks_tel_no` -> `CUST_RRKS_TEL_NO` (Customer Contact Phone Number) |
| 6 | IF | `rrks_offc_nm` -> `RRKS_OFFC_NM` (Contact Office Name) |

---

**Block 7** — [IF chain] Core Field Mapping — Contract Party Address (L11301–L11368)

| # | Type | Code |
|---|------|------|
| 1 | IF | `kksv040325_keisha_ad_cd` -> `KEISHA_AD_CD` (Contract Party Address Code) |
| 2 | IF | `kksv040325_keisha_pcd` -> `KEISHA_PCD` (Contract Party Postal Code) |
| 3 | IF | `kksv040325_keisha_state_nm` -> `KEISHA_STATE_NM` (Contract Party Prefecture Name) |
| 4 | IF | `kksv040325_keisha_city_nm` -> `KEISHA_CITY_NM` (Contract Party City/Town/Village Name) |
| 5 | IF | `kksv040325_keisha_oaztsu_nm` -> `KEISHA_OAZTSU_NM` (Contract Party Oaztsu Name) |
| 6 | IF | `kksv040325_keisha_azcho_nm` -> `KEISHA_AZCHO_NM` (Contract Party Azcho Name) |
| 7 | IF | `kksv040325_keisha_ad_bnchigo` -> `KEISHA_AD_BNCHIGO` (Contract Party Address Reference) |
| 8 | IF | `kksv040325_keisha_adrttm` -> `KEISHA_ADRTTM` (Contract Party Address Supplementary/Building Name) |
| 9 | IF | `kksv040325_keisha_adrrm` -> `KEISHA_ADRRM` (Contract Party Address Supplementary/Room Number) |

---

**Block 8** — [IF] Installation Equipment System Link Remarks (L11373)

| # | Type | Code |
|---|------|------|
| 1 | IF | `kksv040325_manssbsys_rnki_kijiran` -> `MANSSBSYS_RNKI_KIJIRAN` (Installation Equipment System Link Remarks) |

---

**Block 9** — [EXEC] Reset Place Fields to Null (L11383–L11393)

> Resets all set/place address-related fields to null.

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `template.setNull(SETPLACE_AZCHO_NM)` |
| 2 | EXEC | `template.setNull(SETPLACE_STATE_NM)` |
| 3 | EXEC | `template.setNull(SETPLACE_ADRTTM)` |
| 4 | EXEC | `template.setNull(SETPLACE_ADRRM)` |
| 5 | EXEC | `template.setNull(SETPLACE_AD_CD)` |
| 6 | EXEC | `template.setNull(SETPLACE_CITY_NM)` |
| 7 | EXEC | `template.setNull(SETPLACE_AD_BNCHIGO)` |
| 8 | EXEC | `template.setNull(PLACE_NO)` |
| 9 | EXEC | `template.setNull(SETPLACE_PCD)` |
| 10 | EXEC | `template.setNull(SETPLACE_OAZTSU_NM)` |

---

**Block 10** — [IF chain] Core Field Mapping — Construction Info (L11396–L11542)

| # | Type | Code |
|---|------|------|
| 1 | IF | `koji_saki_ad_mi_fix_flg` -> `KOJI_SAKI_AD_MI_FIX_FLG` (Pre-Work Address Unfixed Flag) |
| 2 | IF | `kaisen_place_telno` -> `KAISEN_PLACE_TELNO` (Line Location Phone Number) |
| 3 | IF | `kepco_busioffice_no` -> `KEPCO_BUSIOFFICE_NO` (Kepco Business Office Number) |
| 4 | IF | `lgtd` -> `LGTD` (Longitude) |
| 5 | IF | `lttd` -> `LTTD` (Latitude) |
| 6 | IF | `zahyo_hosei_um` -> `ZAHYO_HOSEI_UM` (Coordinate Correction Validity) |
| 7 | IF | `ad_form_cd` -> `AD_FORM_CD` (Residence Form Code) |
| 8 | IF | `nyukyo_flr_cnt_cd` -> `NYUKYO_FLR_CNT_CD` (Move-in Floor Count Code) |
| 9 | IF | `kcku_flr_cnt_cd` -> `KCKU_FLR_CNT_CD` (Building Floor Count Code) |
| 10 | IF | `direction_cd_1` -> `DIRECTION_CD_1` (Direction Code 1) |
| 11 | IF | `direction_cd_2` -> `DIRECTION_CD_2` (Direction Code 2) |

---

**Block 11** — [IF chain] Core Field Mapping — Move Before Address (L11546–L11618)

| # | Type | Code |
|---|------|------|
| 1 | IF | `tentaku_bf_ad_cd` -> `TENTAKU_BF_AD_CD` (Move Before Address Code) |
| 2 | IF | `tentaku_bf_pcd` -> `TENTAKU_BF_PCD` (Move Before Postal Code) |
| 3 | IF | `tentaku_bf_state_nm` -> `TENTAKU_BF_STATE_NM` (Move Before Prefecture Name) |
| 4 | IF | `tentaku_bf_city_nm` -> `TENTAKU_BF_CITY_NM` (Move Before City/Town/Village Name) |
| 5 | IF | `tentaku_bf_oaztsu_nm` -> `TENTAKU_BF_OAZTSU_NM` (Move Before Oaztsu Name) |
| 6 | IF | `tentaku_bf_azcho_nm` -> `TENTAKU_BF_AZCHO_NM` (Move Before Azcho Name) |
| 7 | IF | `tentaku_bf_ad_bnchigo` -> `TENTAKU_BF_AD_BNCHIGO` (Move Before Address Reference) |
| 8 | IF | `tentaku_bf_adrttm` -> `TENTAKU_BF_ADRTTM` (Move Before Address Supplementary/Building Name) |
| 9 | IF | `tentaku_bf_adrrm` -> `TENTAKU_BF_ADRRM` (Move Before Address Supplementary/Room Number) |

---

**Block 12** — [IF chain] Core Field Mapping — Move After Address (L11621–L11693)

| # | Type | Code |
|---|------|------|
| 1 | IF | `tentaku_saki_ad_cd` -> `TENTAKU_SAKI_AD_CD` (Move After Address Code) |
| 2 | IF | `tentaku_saki_pcd` -> `TENTAKU_SAKI_PCD` (Move After Postal Code) |
| 3 | IF | `tentaku_saki_state_nm` -> `TENTAKU_SAKI_STATE_NM` (Move After Prefecture Name) |
| 4 | IF | `tentaku_saki_city_nm` -> `TENTAKU_SAKI_CITY_NM` (Move After City/Town/Village Name) |
| 5 | IF | `tentaku_saki_oaztsu_nm` -> `TENTAKU_SAKI_OAZTSU_NM` (Move After Oaztsu Name) |
| 6 | IF | `tentaku_saki_azcho_nm` -> `TENTAKU_SAKI_AZCHO_NM` (Move After Azcho Name) |
| 7 | IF | `tentaku_saki_ad_bnchigo` -> `TENTAKU_SAKI_AD_BNCHIGO` (Move After Address Reference) |
| 8 | IF | `tentaku_saki_adrttm` -> `TENTAKU_SAKI_ADRTTM` (Move After Address Supplementary/Building Name) |
| 9 | IF | `tentaku_saki_adrrm` -> `TENTAKU_SAKI_ADRRM` (Move After Address Supplementary/Room Number) |

---

**Block 13** — [IF chain] Core Field Mapping — Additional Info (L11696–L11802)

| # | Type | Code |
|---|------|------|
| 1 | IF | `newconst_bukken_cd` -> `NEWCONST_BUKKEN_CD` (New Building Code) |
| 2 | IF | `hukkat_anken_flg` -> `HUKKAT_ANKEN_FLG` (Reactivation Work Order Flag) |
| 3 | IF | `same_equip_re_mskm_cd` -> `SAME_EQUIP_RE_MSKM_CD` (Same Equipment Re-submission Code) |
| 4 | IF | `koji_scope_cd` -> `KOJI_SCOPE_CD` (Work Scope Code) |
| 5 | IF | `isetsu_cd` -> `ISETSU_CD` (Relocation Code) |
| 6 | IF | `koji_kibo_ymd` -> `KOJI_KIBO_YMD` (Work Desired Date) |
| 7 | IF | `dsl_kibo_ymd` -> `DSL_KIBO_YMD` (Cancellation Desired Date) |
| 8 | IF | `shunko_rsv_ymd` -> `SHUNKO_RSV_YMD` (Completion Scheduled Date) |
| 9 | IF | `nyukyo_rsv_ymd` -> `NYUKYO_RSV_YMD` (Move-in Scheduled Date) |
| 10 | IF | `hikiwatashi_rsv_ymd` -> `HIKIWATASHI_RSV_YMD` (Handover Scheduled Date) |
| 11 | IF | `epower_soden_rsv_ymd` -> `EPOWER_SODEN_RSV_YMD` (Power Transmission Scheduled Date) |
| 12 | IF | `tel_rrk_kibo_ymd` -> `TEL_RRK_KIBO_YMD` (Phone Contact Desired Date) |
| 13 | IF | `tel_rrk_kibo_time_cd` -> `TEL_RRK_KIBO_TIME_CD` (Phone Contact Desired Time Slot Code) |
| 14 | IF | `takcho_kibo_apo_kigen_ymd` -> `TAKCHO_KIBO_APO_KIGEN_YMD` (Indoor Survey Desired Appointment Deadline) |
| 15 | IF | `tnkj_kibo_apo_kigen_ymd` -> `TNKJ_KIBO_APO_KIGEN_YMD` (Indoor Work Desired Appointment Deadline) |
| 16 | IF | `koji_apo_rrks_shitei_cd` -> `KOJI_APO_RRKS_SHITEI_CD` (Work Appointment Contact Designation Code) |
| 17 | IF | `rrk_way_cd` -> `RRK_WAY_CD` (Contact Method Code) |
| 18 | IF | `rrk_way_hoki` -> `RRK_WAY_HOKI` (Contact Method Remarks) |
| 19 | IF | `kojiak_biko` -> `KOJIAK_BIKO` (Work Order Remarks) |
| 20 | IF | `kojiak_biko_1` -> `KOJIAK_BIKO_1` (Work Order Remarks 1) |
| 21 | IF | `kojiak_biko_2` -> `KOJIAK_BIKO_2` (Work Order Remarks 2) |

---

**Block 14** — [EXEC] Reset Equipment and Special Fields to Null (L11812–L11824)

> Clears fields that do not apply to the eo Light TV various changes screen.

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `template.setNull(DMPS_ANKEN_NO)` (Radio Wave Obstruction Work Order Number) |
| 2 | EXEC | `template.setNull(DMPSANK_SBT_CD)` (Radio Wave Obstruction Work Order Type Code) |
| 3 | EXEC | `template.setNull(KEPCO_CTINFO_JUJU_DOI_UM)` (Kepco Customer Info Consent Validity) |

---

**Block 15** — [EXEC] Reset Device 1–20 Fields (L11827–L12494)

> For each of 20 devices, resets 17 fields: device type code, device change code, service contract number, model code, serial number, STB-ID, HDD capacity, BS passthrough capability, STB contract TV course code, and 7 change-before fields.

| # | Type | Code |
|---|------|------|
| 1-17 | EXEC | Device 1: `TAKNKIKI_SBT_CD_1` through `CHGB_OLD_STB_ID_1` |
| 18-34 | EXEC | Device 2: `TAKNKIKI_SBT_CD_2` through `CHGB_OLD_STB_ID_2` |
| 35-51 | EXEC | Device 3: `TAKNKIKI_SBT_CD_3` through `CHGB_OLD_STB_ID_3` |
| ... | ... | (Devices 4-20 follow same pattern) |

Each device block resets:
- `TAKNKIKI_SBT_CD_N` — Indoor Equipment Type Code
- `TAKNKIKI_IDO_CD_N` — Indoor Equipment Change Code
- `KKTK_SVC_KEI_NO_N` — Equipment Provider Service Contract Number
- `TAKNKIKI_MODEL_CD_N` — Indoor Equipment Model Code
- `KKSEIZO_NO_N` — Equipment Serial Number
- `STB_ID_N` — STB-ID
- `HDD_CAPA_CD_N` — HDD Capacity Code
- `VONU_BSPT_KH_N` — BS Passthrough Capability
- `STB_KEI_TV_COURSE_CD_N` — STB Contract TV Course Code
- `CHGB_TAKNIKK_MODEL_CD_N` — Pre-Change Indoor Equipment Model Code
- `CHGB_KKSEIZO_NO_N` — Pre-Change Equipment Serial Number
- `CHGB_STB_ID_N` — Pre-Change STB-ID
- `CHGB_HDD_CAPA_CD_N` — Pre-Change HDD Capacity Code
- `CHGB_VONU_BSPT_KH_N` — Pre-Change BS Passthrough Capability
- `CHGB_STB_KEI_TV_COURSE_CD_N` — Pre-Change STB Contract TV Course Code
- `CHGB_OLD_STB_ID_N` — Pre-Change Old STB-ID

---

**Block 16** — [EXEC] Reset Additional Fields (L12498–L12560)

> Clears memo fields, equipment change numbers, and original transaction case numbers.

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `template.setNull(MSKMSHA_NM)` (Applicant Name) |
| 2 | EXEC | `template.setNull(SVC_STAYMD)` (Service Start Date) |
| 3 | EXEC | `template.setNull(KOJI_APO_RRKS_TELNO)` (Work Appointment Contact Phone) |
| 4 | EXEC | `template.setNull(CUST_SOS_USE_UM)` (Customer SOS Usage Validity) |
| 5-20 | EXEC | `KKTK_SVC_KEI_CHGE_MEMO_N` — Equipment Provider Service Contract Change Memo (N=1..20) |
| 21-40 | EXEC | `KIKI_CHG_NO_N` — Equipment Change Number (N=1..20) |
| 41-60 | EXEC | `MOTO_TCASE_NO_N` — Original Transaction Case Number (N=1..20) |

---

**Block 17** — [SET] Build Template Array and Return (L12562–L12564)

| # | Type | Code |
|---|------|------|
| 1 | SET | `templates = new CAANMsg[1]` |
| 2 | SET | `templates[0] = template` |
| 3 | SET | `paramMap.put(JCMConstants.TEMPLATE_LIST_KEY, templates)` |
| 4 | RETURN | `return paramMap` |

## 7. Glossary

| Term | Type | Business Meaning |
|------|------|------------------|
| `eko_r_gure` | - | (Contextual) Indicates the screen belongs to the eo Light TV various changes workflow domain |
| EKU0031 | Screen ID | "eo Light TV Various Changes Work Order" screen — handles modifications to existing eo Light TV subscriptions |
| eo Light TV | Business term | "eo光テレビ" — NTT East's fiber-optic cable television service |
| CAANMsg | Class | Message template class used for building inbound/outbound message structures between screens and CBS layers |
| SC Code | - | Service Component Code — the business logic component handling specific domain operations |
| CBS | Abbreviation | Common Business Service — the service layer that executes domain logic |
| TEMPLATE_ID_EKU0031C010 | Constant | Template identifier = "EKU0031C010" — identifies the message template for this screen's data structure |
| stateCd | Field | Service contract status code — "010" means "received" (受診済), used to route data source selection |
| funcCd | Field | Function code — "1" = normal operation, "2" = confirmation mode (確認) |
| MSKM_DTL_NO | Field | Detail number (明細番号) — line item number of a service contract |
| SEIKY_KEI_NO | Field | Service contract number (請求契約番号) — unique identifier for a service contract |
| SVC_KEI_NO | Field | Service contract number (サービス契約番号) — internal service contract reference |
| KOJIAK_NO | Field | Work order number (工事案件番号) — identifies a specific work order for field installation |
| SVC_CD | Field | Service code (サービスコード) — identifies the type of telecom service |
| PRC_GRP_CD | Field | Price group code (料金グループコード) — pricing tier for the service |
| PCR_S_CD | Field | Price course code (料金コースコード) — specific pricing plan code |
| CUST_NM | Field | Customer name (お客様名) |
| CUST_KANA | Field | Customer kana name (お客様カナ名) — phonetic representation of customer name |
| CUST_HOME_TEL_NO | Field | Customer home phone number (お客様自宅電話番号) |
| CUST_KTAI_TEL_NO | Field | Customer mobile phone number (お客様携帯電話番号) |
| CUST_RRKS_TEL_NO | Field | Customer contact phone number (お客様連絡先電話番号) |
| KEISHA_AD_CD | Field | Contract party address code (契約者住所コード) |
| KEISHA_PCD | Field | Contract party postal code (契約者郵便番号) |
| KEISHA_STATE_NM | Field | Contract party prefecture name (契約者都道府県名) |
| KEISHA_CITY_NM | Field | Contract party city/town/village name (契約者市区町村名) |
| TENTAKU_BF_* | Fields | Move before address fields — address information before the service change/move |
| TENTAKU_SAKI_* | Fields | Move after address fields — address information after the service change/move |
| lgtd / lttd | Field | Longitude/latitude (経度/緯度) — GPS coordinates for installation location |
| AD_FORM_CD | Field | Residence form code (住居形態コード) — type of residence (house, apartment, etc.) |
| DIRECTION_CD_N | Field | Direction code (方角コード) — direction of installation point |
| koji_scope_cd | Field | Work scope code (工事範囲コード) — defines the scope of installation work |
| isetsu_cd | Field | Relocation code (移設コード) — indicates if the installation is being relocated |
| koji_kibo_ymd | Field | Work desired date (工事希望年月日) |
| shunko_rsv_ymd | Field | Completion scheduled date (竣工予定年月日) |
| nyukyo_rsv_ymd | Field | Move-in scheduled date (入居予定年月日) |
| TAKNKIKI_SBT_CD_N | Field | Indoor equipment type code (屋内機器種類コード) N=1..20 — up to 20 devices |
| STB_ID_N | Field | STB-ID (Set-Top Box identifier) N=1..20 |
| HDD_CAPA_CD_N | Field | HDD capacity code (HDD容量コード) N=1..20 |
| CHGB_*_N | Fields | Pre-change equipment fields — data about equipment before the change/modification N=1..20 |
| KKTK_SVC_KEI_CHGE_MEMO_N | Field | Equipment provider service contract change memo (機器提供サービス契約変更メモ) N=1..20 |
| KIKI_CHG_NO_N | Field | Equipment change number (機器変更番号) N=1..20 |
| MOTO_TCASE_NO_N | Field | Original transaction case number (元トモソコンケース番号) N=1..20 |
| WORK_AREA | - | Work mapping area — a shared data repository between SC calls and screen processing |
| KKSV054601SCWORKLIST | Field | Work list from SC call KKSV054601 — contains order detail records for the various changes workflow |
| ekk0491d010_seiky_kei_no_work | Field | Service contract number work field — temporary storage for the service contract number during processing |
| ekk0011d020_mskm_dtl_no | Field | Detail number from order detail record |
| IRequestParameterReadWrite | Interface | Request parameter I/O interface — provides read/write access to screen data including control maps, work areas, and mapping areas |
| JCMConstants | Class | JCM constants class — provides standard key names for operator ID, date, time, function code, and template list |
| SCControlMapKeys | Class | Control map key constants — provides keys for OPERATOR_ID, OPE_DATE, OPE_TIME |
