# Business Logic — JKKKikiDslAddCC.editInMsg_EKK1551D010CBS() [353 LOC]

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

## 1. Role

### JKKKikiDslAddCC.editInMsg_EKK1551D010CBS()

This method is an **upward mapping** method (上りマッピング — from the Javadoc) that prepares the request payload for the **Order Information Creation Work Registration** service component `EKK1551D010CBS`. It serves as a data transformation bridge between the application's business-layer request parameter object (`IRequestParameterReadOnly`) and the service component's expected input message format (`CAANMsg` wrapped in a `HashMap<String, Object>`).

The method implements a **map-and-wrap builder pattern**: it extracts SC (Service Component) common header data and user session control map data from the request parameter, creates a `CAANMsg` template instance for `EKK1551D010CBS`, populates it with approximately 29 domain fields (each with null-safety checks), wraps the template in an array, and returns the complete parameter map keyed under `TEMPLATE_LIST_KEY`.

The method performs **no external service calls, database reads, or write operations**. It is purely a data-mapping utility that prepares the input structure before the service component is invoked via `ServiceComponentRequestInvoker`. It is called by two other methods within `JKKKikiDslAddCC`: `executeOdrInfoSakseiWkAdd()` (Order Information Creation Work Add) and `executeOdrSetteiIchiranShokai()` (Order Setting List Introduction). The same method name and signature is also duplicated in `JKKAdchgHakkoSODCC`, `JKKHakkoSODCC`, and `JKKAdchgCancelHakkoSODCC` — indicating this is a shared DSL mapping method adapted across multiple order-related components.

## 2. Processing Pattern (Detailed Business Logic)

```mermaid
flowchart TD
    START(["editInMsg_EKK1551D010CBS"])

    subgraph Init["Initialization"]
        S1["Set template_id = EKK1551D010"]
        S2["Create paramMap HashMap"]
        S3["Map SC common data<br>TRANZACTION_ID, USECASE_ID, OPERATION_ID, CALL_TYPE"]
        S4["Map control map data<br>REQ_HOSTNAME, REQ_HOSTIP, REQ_VIEWID, OPERATOR_ID"]
        S5["Create CAANMsg template<br>new CAANMsg(EKK1551D010CBSMsg)"]
        S6["Set template fields<br>TEMPLATEID, FUNC_CODE, OPERATOR_ID, OPE_DATE, OPE_TIME"]
        S7["Get inMap = param.getData<br>HAKKOSODCCWORK"]
    end

    subgraph Fields["Field Mappings"]
        F1["Block 1: odr_hakko_joken_no"]
        F2["Block 2: odr_naiyo_cd"]
        F3["Block 3: svc_kei_no"]
        F4["Block 4: svkei_gadtm"]
        F5["Block 5: svc_kei_ucwk_no"]
        F6["Block 6: svkeiuw_gadtm"]
        F7["Block 7: kktk_svc_kei_no"]
        F8["Block 8: kktsvkei_gadtm"]
        F9["Block 9: op_svc_kei_no"]
        F10["Block 10: opsvkei_gadtm"]
        F11["Block 11: sbop_svc_kei_no"]
        F12["Block 12: sbopsvkei_gadtm"]
        F13["Block 13: seiopsvc_kei_no"]
        F14["Block 14: seiopsvkei_gadtm"]
        F15["Block 15: huka_inf_kei_no"]
        F16["Block 16: huka_inf_kei_gadtm"]
        F17["Block 17: chbf_svkei_gadtm"]
        F18["Block 18: chbf_svkeiuw_gadtm"]
        F19["Block 19: chbf_kktsvkei_gadtm"]
        F20["Block 20: chbf_opsvkei_gadtm"]
        F21["Block 21: chbf_sbopsvkei_gadtm"]
        F22["Block 22: chbf_seiopsvkei_gadtm"]
        F23["Block 23: svckei_gadtm"]
        F24["Block 24: huka_inf_kei_no<br>(duplicate)"]
        F25["Block 25: huka_inf_kei_gadtm<br>(duplicate)"]
        F26["Block 26: kkop_svc_kei_no_1"]
        F27["Block 27: kkosvkei_gadtm_1"]
        F28["Block 28: kkop_svc_kei_no_2"]
        F29["Block 29: kkosvkei_gadtm_2"]
    end

    subgraph Return["Result Assembly"]
        R1["Wrap template in CAANMsg array"]
        R2["Set TEMPLATE_LIST_KEY in paramMap"]
        R3["Return paramMap"]
    end

    START --> S1 --> S2 --> S3 --> S4 --> S5 --> S6 --> S7
    S7 --> F1 --> F2 --> F3 --> F4 --> F5 --> F6 --> F7 --> F8 --> F9 --> F10 --> F11 --> F12 --> F13 --> F14 --> F15 --> F16 --> F17 --> F18 --> F19 --> F20 --> F21 --> F22 --> F23 --> F24 --> F25 --> F26 --> F27 --> F28 --> F29 --> R1 --> R2 --> R3
```

**Constant Resolution:**
- `JKKHakkoSODConstCC.HAKKOSODCCWORKMAP = "HakkoSODCCWORK"` — the key used to retrieve the order creation work registration data map from the request parameter.
- `JPCModelConstant.FUNC_CD_1 = "1"` — hardcoded as the function code on the template, meaning "check and register" (チェックラッチ) operation.

**Processing flow summary:**
1. **Initialization** (L1350–1384): Set the template ID, create the parameter map, populate SC common header data (transaction ID, usecase ID, operation ID, call type), populate user control map data (hostname, IP, screen ID, operator), create the `CAANMsg` template of type `EKK1551D010CBSMsg`, and set template-level fields (TEMPLATEID, FUNC_CODE, OPERATOR_ID, OPE_DATE, OPE_TIME).
2. **Data extraction** (L1386): Retrieve the work registration map from `param.getData("HakkoSODCCWORK")`.
3. **Field-by-field mapping** (L1388–1697): For each of 29 fields, check if `inMap` is null or the field key is missing/empty. If null/empty, call `template.setNull()` on the corresponding `EKK1551D010CBSMsg` field. Otherwise, call `template.set()` with the string value from `inMap`.
4. **Result assembly** (L1698–1701): Wrap the single `CAANMsg` template in an array, store it in `paramMap` under `JCMConstants.TEMPLATE_LIST_KEY`, and return the `paramMap`.

## 3. Parameter Analysis

| No | Parameter Name | Type | Business Description |
|----|---------------|------|---------------------|
| 1 | `param` | `IRequestParameterReadOnly` | The business data acquisition interface carrying the full request context, including telegram/session metadata, user control map data (hostname, IP, screen ID, operator, operation date/time), and the order creation work registration map (`HakkoSODCCWORK`) that holds all order and service contract fields to be mapped to the CBS message. |

**Instance fields / external state read:**
- No instance fields are read from `this` (the `JKKKikiDslAddCC` object). This method is stateless.

## 4. CRUD Operations / Called Services

This method performs **no CRUD operations** and **makes no calls to external services, CBS components, or databases**. It is a pure data-mapping method that transforms request data into a `HashMap<String, Object>` containing a `CAANMsg` template. All method calls inside this method operate on local objects (`param`, `paramMap`, `template`, `inMap`, `templates` array) or on `JCMConstants`/`EKK1551D010CBSMsg` static constants.

| CRUD | SC / CBS | SC Code | Entity / DB | Operation Description |
|------|----------|---------|-------------|----------------------|
| R | `param.getTelegramID()` | — | — | Retrieves the telegram/session ID from the request parameter |
| R | `param.getUsecaseID()` | — | — | Retrieves the usecase ID from the request parameter |
| R | `param.getOperationID()` | — | — | Retrieves the operation ID from the request parameter |
| R | `param.getCallType()` | — | — | Retrieves the service call type discriminator |
| R | `param.getControlMapData(...)` | — | — | Retrieves user/session control data (hostname, IP, screen ID, operator ID, operation date/time) |
| R | `param.getData("HakkoSODCCWORK")` | — | — | Retrieves the order creation work registration map containing all service contract fields |
| - | `template.set(...)` / `template.setNull(...)` | — | — | Populates fields on the CAANMsg template (in-memory object, no DB/SC interaction) |
| - | `new CAANMsg(EKK1551D010CBSMsg.class.getName())` | — | — | Creates a new CAANMsg template instance of type EKK1551D010CBS |

## 5. Dependency Trace

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

No screen/batch entry points found within 8 hops. Direct callers found: 4 methods.
Terminal operations from this method: `setNull` [-], `set` [-], `set` [-], ...

| # | Caller (Screen/Batch) | Call Chain (Full Path to this Method) | Terminal (SC / CRUD / Entity) |
|---|----------------------|--------------------------------------|-------------------------------|
| 1 | Method: `JKKKikiDslAddCC.executeOdrInfoSakseiWkAdd` | `executeOdrInfoSakseiWkAdd` -> `editInMsg_EKK1551D010CBS` | `template.set/setNull [R] CAANMsg fields (no DB/SC call from this method)` |
| 2 | Method: `JKKKikiDslAddCC.executeOdrSetteiIchiranShokai` | `executeOdrSetteiIchiranShokai` -> `editInMsg_EKK1551D010CBS` | `template.set/setNull [R] CAANMsg fields (no DB/SC call from this method)` |
| 3 | Method: `JKKAdchgHakkoSODCC.editInMsg_EKK1551D010CBS` | (own class copy, same logic) | `template.set/setNull [R] CAANMsg fields` |
| 4 | Method: `JKKHakkoSODCC.editInMsg_EKK1551D010CBS` | (own class copy, same logic) | `template.set/setNull [R] CAANMsg fields` |
| 5 | Method: `JKKAdchgCancelHakkoSODCC.editInMsg_EKK1551D010CBS` | (own class copy, same logic) | `template.set/setNull [R] CAANMsg fields` |

**Note:** The two direct callers within `JKKKikiDslAddCC` each call this method and then pass the resulting `paramMap` to `ServiceComponentRequestInvoker.run()` to invoke the `EKK1551D010CBS` service component. The downstream CBS performs the actual database operations (not traceable from this method alone).

## 6. Per-Branch Detail Blocks

**Block 1** — SET (L1350)

> Set the template ID constant.

| # | Type | Code |
|---|------|------|
| 1 | SET | `template_id = "EKK1551D010"` // Template identifier for Order Information Creation Work Registration |

**Block 2** — EXEC (L1352)

> Create the parameter map that will hold SC input data.

| # | Type | Code |
|---|------|------|
| 1 | SET | `paramMap = new HashMap<String, Object>()` |

**Block 3** — EXEC (L1355–1362) — SC Common Data Mapping

> Map SC input common data (header fields from the telegram/handle).

| # | Type | Code |
|---|------|------|
| 1 | SET | `paramMap.put(JCMConstants.TRANZACTION_ID_KEY, param.getTelegramID())` // Telegram/Session ID |
| 2 | SET | `paramMap.put(JCMConstants.USECASE_ID_KEY, param.getUsecaseID())` // Usecase ID |
| 3 | SET | `paramMap.put(JCMConstants.OPERATION_ID_KEY, param.getOperationID())` // Operation ID |
| 4 | SET | `paramMap.put(JCMConstants.CALL_TYPE_KEY, param.getCallType())` // Service call type discriminator |

**Block 4** — EXEC (L1366–1373) — Control Map Data Mapping

> Map user/session control data from the control map.

| # | Type | Code |
|---|------|------|
| 1 | SET | `paramMap.put(JCMConstants.CLIENT_HOST_NAME_KEY, param.getControlMapData(SCControlMapKeys.REQ_HOSTNAME))` // Requestor hostname |
| 2 | SET | `paramMap.put(JCMConstants.CLIENT_IP_ADDRESS_KEY, param.getControlMapData(SCControlMapKeys.REQ_HOSTIP))` // Requestor IP address |
| 3 | SET | `paramMap.put(JCMConstants.INVOKE_GAMEN_ID_KEY, param.getControlMapData(SCControlMapKeys.REQ_VIEWID))` // Requestor screen ID |
| 4 | SET | `paramMap.put(JCMConstants.OPERATOR_ID_KEY, param.getControlMapData(SCControlMapKeys.OPERATOR_ID))` // Operator ID |

**Block 5** — EXEC (L1375–1378)

> Create the CAANMsg template instance for EKK1551D010CBS.

| # | Type | Code |
|---|------|------|
| 1 | SET | `template = new CAANMsg(EKK1551D010CBSMsg.class.getName())` |
| 2 | SET | `inMap = null` |

**Block 6** — EXEC (L1380–1384) — Template Field Setup

> Set template-level fields on the CAANMsg.

| # | Type | Code |
|---|------|------|
| 1 | SET | `template.set(EKK1551D010CBSMsg.TEMPLATEID, template_id)` |
| 2 | SET | `template.set(EKK1551D010CBSMsg.FUNC_CODE, JPCModelConstant.FUNC_CD_1)` // FUNC_CD_1 = "1" (Check & Register) |
| 3 | SET | `operatorId = param.getControlMapData(SCControlMapKeys.OPERATOR_ID)` |
| 4 | SET | `template.set(JCMConstants.OPERATOR_ID_KEY, operatorId)` |
| 5 | SET | `operateDate = param.getControlMapData(SCControlMapKeys.OPE_DATE)` |
| 6 | SET | `template.set(JCMConstants.OPERATE_DATE_KEY, operateDate)` |
| 7 | SET | `operateDateTime = param.getControlMapData(SCControlMapKeys.OPE_TIME)` |
| 8 | SET | `template.set(JCMConstants.OPERATE_DATETIME_KEY, operateDateTime)` |

**Block 7** — EXEC (L1386)

> Retrieve the order creation work registration map from the request parameter.

| # | Type | Code |
|---|------|------|
| 1 | SET | `inMap = (HashMap)param.getData(JKKHakkoSODConstCC.HAKKOSODCCWORKMAP)` // HAKKOSODCCWORKMAP = "HakkoSODCCWORK" |

**Block 8** — IF/ELSE (L1388–1394) — `odr_hakko_joken_no`

> Map the order creation condition number.

| # | Type | Code |
|---|------|------|
| 1 | IF | `null == inMap || null == inMap.get("odr_hakko_joken_no") || "".equals(inMap.get("odr_hakko_joken_no"))` |
| 2 | EXEC (else-branch=true) | `template.setNull(EKK1551D010CBSMsg.ODR_HAKKO_JOKEN_NO)` // Order creation condition number — null |
| 3 | EXEC (else-branch=false) | `template.set(EKK1551D010CBSMsg.ODR_HAKKO_JOKEN_NO, (String)inMap.get("odr_hakko_joken_no"))` // Order creation condition number — from work map |

**Block 9** — IF/ELSE (L1396–1402) — `odr_naiyo_cd`

> Map the order content code (classifies the type of order/service).

| # | Type | Code |
|---|------|------|
| 1 | IF | `null == inMap || null == inMap.get("odr_naiyo_cd") || "".equals(inMap.get("odr_naiyo_cd"))` |
| 2 | EXEC (else-branch=true) | `template.setNull(EKK1551D010CBSMsg.ODR_NAIYO_CD)` // Order content code — null |
| 3 | EXEC (else-branch=false) | `template.set(EKK1551D010CBSMsg.ODR_NAIYO_CD, (String)inMap.get("odr_naiyo_cd"))` // Order content code — from work map |

**Block 10** — IF/ELSE (L1404–1410) — `svc_kei_no`

> Map the service contract number.

| # | Type | Code |
|---|------|------|
| 1 | IF | `null == inMap || null == inMap.get("svc_kei_no") || "".equals(inMap.get("svc_kei_no"))` |
| 2 | EXEC (else-branch=true) | `template.setNull(EKK1551D010CBSMsg.SVC_KEI_NO)` // Service contract number — null |
| 3 | EXEC (else-branch=false) | `template.set(EKK1551D010CBSMsg.SVC_KEI_NO, (String)inMap.get("svc_kei_no"))` // Service contract number — from work map |

**Block 11** — IF/ELSE (L1412–1418) — `svkei_gadtm`

> Map the service contract generation (registration) date-time.

| # | Type | Code |
|---|------|------|
| 1 | IF | `null == inMap || null == inMap.get("svkei_gadtm") || "".equals(inMap.get("svkei_gadtm"))` |
| 2 | EXEC (else-branch=true) | `template.setNull(EKK1551D010CBSMsg.SVKEI_GADTM)` // Service contract registration date-time — null |
| 3 | EXEC (else-branch=false) | `template.set(EKK1551D010CBSMsg.SVKEI_GADTM, (String)inMap.get("svkei_gadtm"))` // Service contract registration date-time — from work map |

**Block 12** — IF/ELSE (L1420–1426) — `svc_kei_ucwk_no`

> Map the service contract detail work number.

| # | Type | Code |
|---|------|------|
| 1 | IF | `null == inMap || null == inMap.get("svc_kei_ucwk_no") || "".equals(inMap.get("svc_kei_ucwk_no"))` |
| 2 | EXEC (else-branch=true) | `template.setNull(EKK1551D010CBSMsg.SVC_KEI_UCWK_NO)` // Service contract detail work number — null |
| 3 | EXEC (else-branch=false) | `template.set(EKK1551D010CBSMsg.SVC_KEI_UCWK_NO, (String)inMap.get("svc_kei_ucwk_no"))` // Service contract detail work number — from work map |

**Block 13** — IF/ELSE (L1428–1434) — `svkeiuw_gadtm`

> Map the service contract detail registration date-time.

| # | Type | Code |
|---|------|------|
| 1 | IF | `null == inMap || null == inMap.get("svkeiuw_gadtm") || "".equals(inMap.get("svkeiuw_gadtm"))` |
| 2 | EXEC (else-branch=true) | `template.setNull(EKK1551D010CBSMsg.SVKEIUW_GADTM)` // Service contract detail registration date-time — null |
| 3 | EXEC (else-branch=false) | `template.set(EKK1551D010CBSMsg.SVKEIUW_GADTM, (String)inMap.get("svkeiuw_gadtm"))` // Service contract detail registration date-time — from work map |

**Block 14** — IF/ELSE (L1436–1442) — `kktk_svc_kei_no`

> Map the device-provided service contract number (機器提供サービス契約番号).

| # | Type | Code |
|---|------|------|
| 1 | IF | `null == inMap || null == inMap.get("kktk_svc_kei_no") || "".equals(inMap.get("kktk_svc_kei_no"))` |
| 2 | EXEC (else-branch=true) | `template.setNull(EKK1551D010CBSMsg.KKTK_SVC_KEI_NO)` // Device-provided service contract number — null |
| 3 | EXEC (else-branch=false) | `template.set(EKK1551D010CBSMsg.KKTK_SVC_KEI_NO, (String)inMap.get("kktk_svc_kei_no"))` // Device-provided service contract number — from work map |

**Block 15** — IF/ELSE (L1444–1450) — `kktsvkei_gadtm`

> Map the device-provided service contract registration date-time.

| # | Type | Code |
|---|------|------|
| 1 | IF | `null == inMap || null == inMap.get("kktsvkei_gadtm") || "".equals(inMap.get("kktsvkei_gadtm"))` |
| 2 | EXEC (else-branch=true) | `template.setNull(EKK1551D010CBSMsg.KKTSVKEI_GADTM)` // Device-provided service contract registration date-time — null |
| 3 | EXEC (else-branch=false) | `template.set(EKK1551D010CBSMsg.KKTSVKEI_GADTM, (String)inMap.get("kktsvkei_gadtm"))` // Device-provided service contract registration date-time — from work map |

**Block 16** — IF/ELSE (L1452–1458) — `op_svc_kei_no`

> Map the option service contract number.

| # | Type | Code |
|---|------|------|
| 1 | IF | `null == inMap || null == inMap.get("op_svc_kei_no") || "".equals(inMap.get("op_svc_kei_no"))` |
| 2 | EXEC (else-branch=true) | `template.setNull(EKK1551D010CBSMsg.OP_SVC_KEI_NO)` // Option service contract number — null |
| 3 | EXEC (else-branch=false) | `template.set(EKK1551D010CBSMsg.OP_SVC_KEI_NO, (String)inMap.get("op_svc_kei_no"))` // Option service contract number — from work map |

**Block 17** — IF/ELSE (L1460–1466) — `opsvkei_gadtm`

> Map the option service contract registration date-time.

| # | Type | Code |
|---|------|------|
| 1 | IF | `null == inMap || null == inMap.get("opsvkei_gadtm") || "".equals(inMap.get("opsvkei_gadtm"))` |
| 2 | EXEC (else-branch=true) | `template.setNull(EKK1551D010CBSMsg.OPSVKEI_GADTM)` // Option service contract registration date-time — null |
| 3 | EXEC (else-branch=false) | `template.set(EKK1551D010CBSMsg.OPSVKEI_GADTM, (String)inMap.get("opsvkei_gadtm"))` // Option service contract registration date-time — from work map |

**Block 18** — IF/ELSE (L1468–1474) — `sbop_svc_kei_no`

> Map the sub-option service contract number.

| # | Type | Code |
|---|------|------|
| 1 | IF | `null == inMap || null == inMap.get("sbop_svc_kei_no") || "".equals(inMap.get("sbop_svc_kei_no"))` |
| 2 | EXEC (else-branch=true) | `template.setNull(EKK1551D010CBSMsg.SBOP_SVC_KEI_NO)` // Sub-option service contract number — null |
| 3 | EXEC (else-branch=false) | `template.set(EKK1551D010CBSMsg.SBOP_SVC_KEI_NO, (String)inMap.get("sbop_svc_kei_no"))` // Sub-option service contract number — from work map |

**Block 19** — IF/ELSE (L1476–1482) — `sbopsvkei_gadtm`

> Map the sub-option service contract registration date-time.

| # | Type | Code |
|---|------|------|
| 1 | IF | `null == inMap || null == inMap.get("sbopsvkei_gadtm") || "".equals(inMap.get("sbopsvkei_gadtm"))` |
| 2 | EXEC (else-branch=true) | `template.setNull(EKK1551D010CBSMsg.SBOPSVKEI_GADTM)` // Sub-option service contract registration date-time — null |
| 3 | EXEC (else-branch=false) | `template.set(EKK1551D010CBSMsg.SBOPSVKEI_GADTM, (String)inMap.get("sbopsvkei_gadtm"))` // Sub-option service contract registration date-time — from work map |

**Block 20** — IF/ELSE (L1484–1490) — `seiopsvc_kei_no`

> Map the billing option service contract number.

| # | Type | Code |
|---|------|------|
| 1 | IF | `null == inMap || null == inMap.get("seiopsvc_kei_no") || "".equals(inMap.get("seiopsvc_kei_no"))` |
| 2 | EXEC (else-branch=true) | `template.setNull(EKK1551D010CBSMsg.SEIOPSVC_KEI_NO)` // Billing option service contract number — null |
| 3 | EXEC (else-branch=false) | `template.set(EKK1551D010CBSMsg.SEIOPSVC_KEI_NO, (String)inMap.get("seiopsvc_kei_no"))` // Billing option service contract number — from work map |

**Block 21** — IF/ELSE (L1492–1498) — `seiopsvkei_gadtm`

> Map the billing option service contract registration date-time.

| # | Type | Code |
|---|------|------|
| 1 | IF | `null == inMap || null == inMap.get("seiopsvkei_gadtm") || "".equals(inMap.get("seiopsvkei_gadtm"))` |
| 2 | EXEC (else-branch=true) | `template.setNull(EKK1551D010CBSMsg.SEIOPSVKEI_GADTM)` // Billing option service contract registration date-time — null |
| 3 | EXEC (else-branch=false) | `template.set(EKK1551D010CBSMsg.SEIOPSVKEI_GADTM, (String)inMap.get("seiopsvkei_gadtm"))` // Billing option service contract registration date-time — from work map |

**Block 22** — IF/ELSE (L1500–1506) — `huka_inf_kei_no`

> Map the additional information contract number.

| # | Type | Code |
|---|------|------|
| 1 | IF | `null == inMap || null == inMap.get("huka_inf_kei_no") || "".equals(inMap.get("huka_inf_kei_no"))` |
| 2 | EXEC (else-branch=true) | `template.setNull(EKK1551D010CBSMsg.HUKA_INF_KEI_NO)` // Additional information contract number — null |
| 3 | EXEC (else-branch=false) | `template.set(EKK1551D010CBSMsg.HUKA_INF_KEI_NO, (String)inMap.get("huka_inf_kei_no"))` // Additional information contract number — from work map |

**Block 23** — IF/ELSE (L1508–1514) — `huka_inf_kei_gadtm`

> Map the additional information contract registration date-time.

| # | Type | Code |
|---|------|------|
| 1 | IF | `null == inMap || null == inMap.get("huka_inf_kei_gadtm") || "".equals(inMap.get("huka_inf_kei_gadtm"))` |
| 2 | EXEC (else-branch=true) | `template.setNull(EKK1551D010CBSMsg.HUKA_INF_KEI_GADTM)` // Additional information contract registration date-time — null |
| 3 | EXEC (else-branch=false) | `template.set(EKK1551D010CBSMsg.HUKA_INF_KEI_GADTM, (String)inMap.get("huka_inf_kei_gadtm"))` // Additional information contract registration date-time — from work map |

**Block 24** — IF/ELSE (L1516–1522) — `chbf_svkei_gadtm`

> Map the pre-change service contract registration date-time.

| # | Type | Code |
|---|------|------|
| 1 | IF | `null == inMap || null == inMap.get("chbf_svkei_gadtm") || "".equals(inMap.get("chbf_svkei_gadtm"))` |
| 2 | EXEC (else-branch=true) | `template.setNull(EKK1551D010CBSMsg.CHBF_SVKEI_GADTM)` // Pre-change service contract registration date-time — null |
| 3 | EXEC (else-branch=false) | `template.set(EKK1551D010CBSMsg.CHBF_SVKEI_GADTM, (String)inMap.get("chbf_svkei_gadtm"))` // Pre-change service contract registration date-time — from work map |

**Block 25** — IF/ELSE (L1524–1530) — `chbf_svkeiuw_gadtm`

> Map the pre-change service contract detail registration date-time.

| # | Type | Code |
|---|------|------|
| 1 | IF | `null == inMap || null == inMap.get("chbf_svkeiuw_gadtm") || "".equals(inMap.get("chbf_svkeiuw_gadtm"))` |
| 2 | EXEC (else-branch=true) | `template.setNull(EKK1551D010CBSMsg.CHBF_SVKEIUW_GADTM)` // Pre-change service contract detail registration date-time — null |
| 3 | EXEC (else-branch=false) | `template.set(EKK1551D010CBSMsg.CHBF_SVKEIUW_GADTM, (String)inMap.get("chbf_svkeiuw_gadtm"))` // Pre-change service contract detail registration date-time — from work map |

**Block 26** — IF/ELSE (L1532–1538) — `chbf_kktsvkei_gadtm`

> Map the pre-change device-provided service contract registration date-time.

| # | Type | Code |
|---|------|------|
| 1 | IF | `null == inMap || null == inMap.get("chbf_kktsvkei_gadtm") || "".equals(inMap.get("chbf_kktsvkei_gadtm"))` |
| 2 | EXEC (else-branch=true) | `template.setNull(EKK1551D010CBSMsg.CHBF_KKTSVKEI_GADTM)` // Pre-change device-provided service contract registration date-time — null |
| 3 | EXEC (else-branch=false) | `template.set(EKK1551D010CBSMsg.CHBF_KKTSVKEI_GADTM, (String)inMap.get("chbf_kktsvkei_gadtm"))` // Pre-change device-provided service contract registration date-time — from work map |

**Block 27** — IF/ELSE (L1540–1546) — `chbf_opsvkei_gadtm`

> Map the pre-change option service contract registration date-time.

| # | Type | Code |
|---|------|------|
| 1 | IF | `null == inMap || null == inMap.get("chbf_opsvkei_gadtm") || "".equals(inMap.get("chbf_opsvkei_gadtm"))` |
| 2 | EXEC (else-branch=true) | `template.setNull(EKK1551D010CBSMsg.CHBF_OPSVKEI_GADTM)` // Pre-change option service contract registration date-time — null |
| 3 | EXEC (else-branch=false) | `template.set(EKK1551D010CBSMsg.CHBF_OPSVKEI_GADTM, (String)inMap.get("chbf_opsvkei_gadtm"))` // Pre-change option service contract registration date-time — fromwork map |

**Block 28** — IF/ELSE (L1548–1554) — `chbf_sbopsvkei_gadtm`

> Map the pre-change sub-option service contract registration date-time.

| # | Type | Code |
|---|------|------|
| 1 | IF | `null == inMap || null == inMap.get("chbf_sbopsvkei_gadtm") || "".equals(inMap.get("chbf_sbopsvkei_gadtm"))` |
| 2 | EXEC (else-branch=true) | `template.setNull(EKK1551D010CBSMsg.CHBF_SBOPSVKEI_GADTM)` // Pre-change sub-option service contract registration date-time — null |
| 3 | EXEC (else-branch=false) | `template.set(EKK1551D010CBSMsg.CHBF_SBOPSVKEI_GADTM, (String)inMap.get("chbf_sbopsvkei_gadtm"))` // Pre-change sub-option service contract registration date-time — from work map |

**Block 29** — IF/ELSE (L1556–1562) — `chbf_seiopsvkei_gadtm`

> Map the pre-change billing option service contract registration date-time.

| # | Type | Code |
|---|------|------|
| 1 | IF | `null == inMap || null == inMap.get("chbf_seiopsvkei_gadtm") || "".equals(inMap.get("chbf_seiopsvkei_gadtm"))` |
| 2 | EXEC (else-branch=true) | `template.setNull(EKK1551D010CBSMsg.CHBF_SEIOPSVKEI_GADTM)` // Pre-change billing option service contract registration date-time — null |
| 3 | EXEC (else-branch=false) | `template.set(EKK1551D010CBSMsg.CHBF_SEIOPSVKEI_GADTM, (String)inMap.get("chbf_seiopsvkei_gadtm"))` // Pre-change billing option service contract registration date-time — from work map |

**Block 30** — IF/ELSE (L1564–1570) — `svckei_gadtm`

> Map the service contract line registration date-time.

| # | Type | Code |
|---|------|------|
| 1 | IF | `null == inMap || null == inMap.get("svckei_gadtm") || "".equals(inMap.get("svckei_gadtm"))` |
| 2 | EXEC (else-branch=true) | `template.setNull(EKK1551D010CBSMsg.SVKEI_GADTM)` // Service contract line registration date-time — null |
| 3 | EXEC (else-branch=false) | `template.set(EKK1551D010CBSMsg.SVKEI_GADTM, (String)inMap.get("svckei_gadtm"))` // Service contract line registration date-time — from work map |

**Block 31** — IF/ELSE (L1573–1579) — `huka_inf_kei_no` (duplicate)

> **NOTE:** This field is mapped a second time (duplicate of Block 22), overwriting the previous value.

| # | Type | Code |
|---|------|------|
| 1 | IF | `null == inMap || null == inMap.get("huka_inf_kei_no") || "".equals(inMap.get("huka_inf_kei_no"))` |
| 2 | EXEC (else-branch=true) | `template.setNull(EKK1551D010CBSMsg.HUKA_INF_KEI_NO)` // Additional information contract number — null (duplicate) |
| 3 | EXEC (else-branch=false) | `template.set(EKK1551D010CBSMsg.HUKA_INF_KEI_NO, (String)inMap.get("huka_inf_kei_no"))` // Additional information contract number — from work map (duplicate) |

**Block 32** — IF/ELSE (L1582–1588) — `huka_inf_kei_gadtm` (duplicate)

> **NOTE:** This field is mapped a second time (duplicate of Block 23), overwriting the previous value.

| # | Type | Code |
|---|------|------|
| 1 | IF | `null == inMap || null == inMap.get("huka_inf_kei_gadtm") || "".equals(inMap.get("huka_inf_kei_gadtm"))` |
| 2 | EXEC (else-branch=true) | `template.setNull(EKK1551D010CBSMsg.HUKA_INF_KEI_GADTM)` // Additional information contract registration date-time — null (duplicate) |
| 3 | EXEC (else-branch=false) | `template.set(EKK1551D010CBSMsg.HUKA_INF_KEI_GADTM, (String)inMap.get("huka_inf_kei_gadtm"))` // Additional information contract registration date-time — from work map (duplicate) |

**Block 33** — IF/ELSE (L1591–1597) — `kkop_svc_kei_no_1`

> Map device option service contract number 1.

| # | Type | Code |
|---|------|------|
| 1 | IF | `null == inMap || null == inMap.get("kkop_svc_kei_no_1") || "".equals(inMap.get("kkop_svc_kei_no_1"))` |
| 2 | EXEC (else-branch=true) | `template.setNull(EKK1551D010CBSMsg.KKOP_SVC_KEI_NO_1)` // Device option service contract number 1 — null |
| 3 | EXEC (else-branch=false) | `template.set(EKK1551D010CBSMsg.KKOP_SVC_KEI_NO_1, (String)inMap.get("kkop_svc_kei_no_1"))` // Device option service contract number 1 — from work map |

**Block 34** — IF/ELSE (L1600–1606) — `kkosvkei_gadtm_1`

> Map device option service contract registration date-time 1.

| # | Type | Code |
|---|------|------|
| 1 | IF | `null == inMap || null == inMap.get("kkosvkei_gadtm_1") || "".equals(inMap.get("kkosvkei_gadtm_1"))` |
| 2 | EXEC (else-branch=true) | `template.setNull(EKK1551D010CBSMsg.KKOSVKEI_GADTM_1)` // Device option service contract registration date-time 1 — null |
| 3 | EXEC (else-branch=false) | `template.set(EKK1551D010CBSMsg.KKOSVKEI_GADTM_1, (String)inMap.get("kkosvkei_gadtm_1"))` // Device option service contract registration date-time 1 — from work map |

**Block 35** — IF/ELSE (L1609–1615) — `kkop_svc_kei_no_2`

> Map device option service contract number 2.

| # | Type | Code |
|---|------|------|
| 1 | IF | `null == inMap || null == inMap.get("kkop_svc_kei_no_2") || "".equals(inMap.get("kkop_svc_kei_no_2"))` |
| 2 | EXEC (else-branch=true) | `template.setNull(EKK1551D010CBSMsg.KKOP_SVC_KEI_NO_2)` // Device option service contract number 2 — null |
| 3 | EXEC (else-branch=false) | `template.set(EKK1551D010CBSMsg.KKOP_SVC_KEI_NO_2, (String)inMap.get("kkop_svc_kei_no_2"))` // Device option service contract number 2 — from work map |

**Block 36** — IF/ELSE (L1618–1624) — `kkosvkei_gadtm_2`

> Map device option service contract registration date-time 2.

| # | Type | Code |
|---|------|------|
| 1 | IF | `null == inMap || null == inMap.get("kkosvkei_gadtm_2") || "".equals(inMap.get("kkosvkei_gadtm_2"))` |
| 2 | EXEC (else-branch=true) | `template.setNull(EKK1551D010CBSMsg.KKOSVKEI_GADTM_2)` // Device option service contract registration date-time 2 — null |
| 3 | EXEC (else-branch=false) | `template.set(EKK1551D010CBSMsg.KKOSVKEI_GADTM_2, (String)inMap.get("kkosvkei_gadtm_2"))` // Device option service contract registration date-time 2 — from work map |

**Block 37** — EXEC (L1627–1631) — Result Assembly

> Wrap the single `CAANMsg` template in an array, store it under `TEMPLATE_LIST_KEY` in `paramMap`, and return the map.

| # | 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 |
|------|------|------------------|
| `HakkoSODCCWORK` | Constant | Order creation work registration map key — the internal map containing all order/service fields for work registration |
| `odr_hakko_joken_no` | Field | Order creation condition number — internal tracking ID for order creation conditions |
| `odr_naiyo_cd` | Field | Order content code — classifies the type of order (e.g., new FTTH registration, mail change, number portability) |
| `svc_kei_no` | Field | Service contract number — unique identifier for a service contract line item |
| `svkei_gadtm` | Field | Service contract generation date-time — timestamp when the service contract was registered/created |
| `svc_kei_ucwk_no` | Field | Service contract detail work number — internal tracking ID for service contract detail work |
| `svkeiuw_gadtm` | Field | Service contract detail registration date-time — timestamp when the service contract detail was registered |
| `kktk_svc_kei_no` | Field | Device-provided service contract number — service contract number for devices provided by the carrier (機器提供) |
| `kktsvkei_gadtm` | Field | Device-provided service contract registration date-time — timestamp for device-provided contract registration |
| `op_svc_kei_no` | Field | Option service contract number — service contract number for optional add-on services |
| `opsvkei_gadtm` | Field | Option service contract registration date-time — timestamp for option service contract registration |
| `sbop_svc_kei_no` | Field | Sub-option service contract number — service contract number for secondary/additional optional services |
| `sbopsvkei_gadtm` | Field | Sub-option service contract registration date-time — timestamp for sub-option contract registration |
| `seiopsvc_kei_no` | Field | Billing option service contract number — service contract number for billing-related optional services (請求オプション) |
| `seiopsvkei_gadtm` | Field | Billing option service contract registration date-time — timestamp for billing option registration |
| `huka_inf_kei_no` | Field | Additional information contract number — service contract number for supplementary/additional information services (付加情報契約番号) |
| `huka_inf_kei_gadtm` | Field | Additional information contract registration date-time — timestamp for additional info contract registration |
| `chbf_svkei_gadtm` | Field | Pre-change service contract registration date-time — timestamp from before a service modification/change (変更前) |
| `chbf_svkeiuw_gadtm` | Field | Pre-change service contract detail registration date-time — timestamp from before a service modification |
| `chbf_kktsvkei_gadtm` | Field | Pre-change device-provided service contract registration date-time — timestamp from before a device-provided contract change |
| `chbf_opsvkei_gadtm` | Field | Pre-change option service contract registration date-time — timestamp from before an option service change |
| `chbf_sbopsvkei_gadtm` | Field | Pre-change sub-option service contract registration date-time — timestamp from before a sub-option change |
| `chbf_seiopsvkei_gadtm` | Field | Pre-change billing option service contract registration date-time — timestamp from before a billing option change |
| `svckei_gadtm` | Field | Service contract line registration date-time — timestamp for the service contract line item registration |
| `kkop_svc_kei_no_1` / `kkop_svc_kei_no_2` | Field | Device option service contract number 1/2 — optional device-related service contracts (multiple) |
| `kkosvkei_gadtm_1` / `kkosvkei_gadtm_2` | Field | Device option service contract registration date-time 1/2 — timestamps for multiple device option contracts |
| FUNC_CD_1 | Constant | Function code "1" — represents "check and register" (チェック＆登録) operation mode |
| `EKK1551D010CBS` | Service Component | Order Information Creation Work Registration CBS — the backend service component that processes the order creation work |
| `EKK1551D010CBSMsg` | Message Class | CAANMsg schema class defining all fields for the EKK1551D010CBS service message |
| CAANMsg | Pattern | Fujitsu's custom message class for service component communication — carries typed fields in a schema-based structure |
| `IRequestParameterReadOnly` | Interface | Request parameter read-only interface — provides access to session data, control map data, and business data maps |
| `IRequestParameterReadWrite` | Interface | Request parameter read-write interface — extends ReadOnly with write capabilities; used after CBS returns results |
| `ServiceComponentRequestInvoker` | Pattern | Service component invocation utility — creates and executes SC calls from parameter maps |
| SC | Acronym | Service Component — a backend business logic component in the K-Opticom architecture |
| CBS | Acronym | Component-Based Service — the service component tier in the Fujiku/Futurity framework |
| SOD | Acronym | Service Order Data — the order/service order entity in the K-Opticom telecom OSS |
| FTTH | Business term | Fiber To The Home — fiber-optic broadband service type in the telecom domain |
| 上りマッピング | Term | Upward mapping — data flow from the application layer up to the service component layer (pre-SC execution) |
| 下りマッピング | Term | Downward mapping — data flow from the service component layer back down to the application layer (post-SC execution) |
| 変更前 | Term | Pre-change — fields prefixed with `chbf_` store the state of service contracts before a modification event |
