# Business Logic - ZMW01904SFLogic.initEdit() [706 LOC]

| Field | Value |
|-------|-------|
| Fully Qualified Name | `eo.web.webview.ZMW01904SF.ZMW01904SFLogic` |
| Layer | Controller (Web view logic / presentation-layer business processing) |
| Module | `ZMW01904SF` (Package: `eo.web.webview.ZMW01904SF`) |

## 1. Role

### ZMW01904SFLogic.initEdit()

This method is the **initial display controller for the ENUM Switch (Number Portability) Edit screen** in K-Opticom's customer management system. "ENUM Switch" (ENUM切替) is the business process by which a telecom subscriber transfers their phone number between service providers - the Japanese regulatory "Number Portability" workflow. The method orchestrates the full pre-computation and display-value preparation for the initial screen load, resolving all UI-dependent state from the incoming data bean array.

The method handles **four order content types (注文種類)** - Number Portability Transfer (番号転送, code "1"), Number Portability Return (番号戻り, code "2"), Inter-Provider Switch (事業者間移転, code "3"), and Number Cancellation (番号廃止, code "4") - combined with **two customer types** (Individual/Kojin "1" and Corporate/Hojin "2") and **two switch-execute states** (Not Executed / Mijikkou "0" and Executed / Jikkou-zumi "1"). This produces 16 distinct business scenarios, each resolved into a specific display text for the application content (申請内容) field.

The method implements the **builder pattern** - it collects, transforms, and populates display-ready values across the entire X31SDataBeanAccess hierarchy, including nested data bean arrays for phone number consent details, port receipt info lists, ENUM switch history lists, and the post-change provider selection dropdown. It also validates the latest application data against a set of business rules (port-out status, availability flag, cancellation identifiers) to determine whether the data is usable for display.

In the larger system, this method serves as the **entry point for rendering the ENUM Switch edit screen at initial display time**. It is called by `getInfoInitData()` and prepares all display fields, dropdown lists, and row styling before the view is rendered to the user. It does not perform any create/update/delete database operations - it is purely a display preparation method.

Conditional branches summarize as follows:
- **No phone number data**: All display fields are cleared; the method is a no-op for screen data.
- **Port receipt info list is empty**: Same behavior as above.
- **Latest application data is valid**: The method processes 16 sub-scenarios based on chumn_kind, kojin_hojin_tln_tai_cd, and kirikaeshori_flg, plus handles previous application data lookup.
- **Post-change provider code editing**: Based on kirikaeshori_flg state and sinsei_naiyo_flg, the method populates before/after change provider codes and domain fields.

## 2. Processing Pattern (Detailed Business Logic)

```mermaid
flowchart TD
    START(["initEdit bean[]"])

    START --> S1["S1: Read jisha_jgs_cd and jisha_jgs_cd_nm from bean[0]"]
    S1 --> S2["S2: Get ezm0121InfoBean from EZM0121A010CBSMSG1LIST[0]"]
    S2 --> COND1{ezm0121InfoBean != null?}

    COND1 -->|Yes| S3["S3: Set tel_um=UM_U; read telno, kojin_hojin_tln_tai_cd_nm, kojin_hojin_tln_tai_cd, tln_stku_tsjgs_cd"]
    COND1 -->|No| S4["S4: tel_um stays UM_M; fields stay empty"]

    S3 --> S5["S5: Set DSP_TELNO (format if non-empty) and DSP_KOJIN_HOJIN_TLN_TAI_CD"]
    S4 --> S5

    S5 --> S6["S6: Get listZMSV013303SC_etu0151b040cbsmsg1list_ETU0151B040CBSMsg1List and cngaf_itnsk_jgs_cd_info"]
    S6 --> COND2{tel_um=UM_M or list is empty?}

    COND2 -->|Yes| BLOCK_EMPTY["Empty branch: Clear all display fields; set CNGAF lists to default 0"]
    BLOCK_EMPTY --> FINISH["FINISH: setRowStyleClass for ENUM switch history"]

    COND2 -->|No| INIT_VARS["Initialize latest application data variables"]
    INIT_VARS --> GET_LATEST["Get data from port receipt info list index 0"]
    GET_LATEST --> COND_VALID{Is latest data valid?}

    COND_VALID -->|No| NO_VALID["uk_flg stays ENDIS_DIS; skip processing"]
    COND_VALID -->|Yes| VALID_PROCESS["Valid latest data branch"]

    VALID_PROCESS --> SET_NEWTS["Set NEWTSHIN fields: port_out_no, gene_add_dtm, itd_jgs_cd, svc_kei_no"]
    SET_NEWTS --> COND_SWITCH{Is switch_sod_hakko_dtm empty?}

    COND_SWITCH -->|Yes| KIRIKAESHI_MIJ["kirikaeshori_flg=MIJIKKOU (not executed)"]
    COND_SWITCH -->|No| KIRIKAESHI_JIKK["kirikaeshori_flg=JIKKOUZUMI (executed)"]

    KIRIKAESHI_MIJ --> SET_DISPLAY["Set DSP_BNGSHUTK_JGS_CD, DSP_ITNMT_JGS_CD; uk_flg=ENDIS_EN"]
    KIRIKAESHI_JIKK --> SET_DISPLAY
    SET_DISPLAY --> LOOP_PREV["Loop i=1 to count-1: find valid previous application"]
    LOOP_PREV --> CHECK_PREV{prev status=050 and tk_kh=KAHI_KA and not cancelled?}

    CHECK_PREV -->|Yes| SAVE_PREV["Save previous data: port_out_no, gene_add_dtm; be_um_flg=UM_U"]
    CHECK_PREV -->|No| SKP_PREV["Skip: previous data invalid"]
    SAVE_PREV --> SET_SINSEI["Determine SINSEI_NAIYO based on chumn_kind + kirikaeshori_flg + kojin_hojin_tln_tai_cd"]
    SKP_PREV --> SET_SINSEI

    SET_SINSEI --> BLOCKS["Multiple IF/ELSE-IF branches: chumn_kind 1/2/3/4 x kojin_hojin_tln_tai_cd 1/2 x kirikaeshori_flg 0/1"]
    BLOCKS --> SET_DISPLAY2["Set DSP_SINSEI_NAIYO, SINSEI_NAIYO_FLG; sometimes clear DSP_KIRIKAESHORI"]
    SET_DISPLAY2 --> COND_KIRIKAESHI{kirikaeshori_flg=MIJIKKOU or JIKKOUZUMI?}

    COND_KIRIKAESHI -->|MIJIKKOU| PRE_BEFORE_CNG["Before/CNG: Set DSP_CNGBF_ITNSK_JGS_CD and DSP_CNGBF_ITNSK_DOMAIN"]
    COND_KIRIKAESHI -->|JIKKOUZUMI| PRE_AFTER_CNG["After/CNG: Set DSP_CNGBF_ITNSK_JGS_CD and DSP_CNGBF_ITNSK_DOMAIN"]

    PRE_BEFORE_CNG --> AFTER_CNG_SET["Set CNGAF_ITNSK_JGS_CD_LIST_01 and DSP_CNGAF_ITNSK_DOMAIN based on sinsei_naiyo"]
    PRE_AFTER_CNG --> AFTER_CNG_SET

    AFTER_CNG_SET --> FINISH

    style START fill:#e1f5e1
    style FINISH fill:#e1f5e1
```

**CRITICAL - Constant Resolution:**

All constants are resolved from `ZMW01904SFLogic` local constants:

| Constant | Value | Business Meaning |
|----------|-------|-----------------|
| `PORT_OUT_STAT_030` | `"030"` | Port-out status: CSV export complete |
| `PORT_OUT_STAT_050` | `"050"` | Port-out status: Work completed |
| `KAHI_KA` | `"1"` | Availability: Yes (can provide) |
| `UM_M` | `"0"` | Existence: No (empty) |
| `UM_U` | `"1"` | Existence: Yes (present) |
| `ENDIS_DIS` | `"0"` | Valid/Invalid: Invalid |
| `ENDIS_EN` | `"1"` | Valid/Invalid: Valid |
| `KIRIKAESHORIFLG_MIJIKKOU` | `"0"` | Switch processing: Not executed |
| `KIRIKAESHORIFLG_JIKKOUZUMI` | `"1"` | Switch processing: Executed |
| `CHUMN_KIND_1` | `"1"` | Order type: Number Portability Transfer (番号転送) |
| `CHUMN_KIND_2` | `"2"` | Order type: Number Portability Return (番号戻り) |
| `CHUMN_KIND_3` | `"3"` | Order type: Inter-Provider Switch (事業者間移転) |
| `CHUMN_KIND_4` | `"4"` | Order type: Number Cancellation (番号廃止) |
| `KOJIN_HOJIN_TLN_TAI_CD_KOJIN` | `"1"` | Customer type: Individual |
| `KOJIN_HOJIN_TLN_TAI_CD_HOJIN` | `"2"` | Customer type: Corporate |
| `SINSEI_NAIYO_1` | "Port-out (FTTH phone number)" | Application content: Port-out |
| `SINSEI_NAIYO_2` | "Inter-provider switch (FTTH phone number)" | Application content: Inter-provider switch |
| `SINSEI_NAIYO_3` | "Number cancellation (other provider receipt)" | Application content: Number cancellation |
| `SINSEI_NAIYO_4` | "Inter-provider switch (other company phone number)" | Application content: Inter-provider switch (other) |
| `SINSEI_NAIYO_5` | "Port-out (FTTH phone number) . Cancel" | Application content: Port-out with cancel |
| `SINSEI_NAIYO_6` | "Inter-provider switch (FTTH phone number) . Cancel" | Application content: Inter-provider switch with cancel |
| `SINSEI_NAIYO_7` | "Number cancellation (other provider receipt) . Cancel" | Application content: Number cancellation with cancel |
| `SINSEI_NAIYO_9` | `""` | No applicable content |
| `SINSEI_NAIYO_FLG_1` to `_7`, `_9` | `"1"` to `"7"`, `"9"` | Corresponding flags for display |

## 3. Parameter Analysis

| No | Parameter Name | Type | Business Description |
|----|---------------|------|---------------------|
| 1 | `bean` | `X31SDataBeanAccess[]` | Array of ENUM Switch service form data beans. Contains phone number consent info, port receipt info list, ENUM switch history list, and post-change provider code info. This is the primary input/output carrier for the entire initial display data preparation. |

**External state / instance fields read:** None directly in initEdit. The method accesses constants defined in the class itself and calls static utility methods (e.g., `JZMWebCommon.setRowStyleClass`).

## 4. CRUD Operations / Called Services

| CRUD | SC / CBS | SC Code | Entity / DB | Operation Description |
|------|----------|---------|-------------|----------------------|
| - | `JCNWebCommon.formatTelNo` | - | - | Formats phone number string for display (utility call) |
| - | `JZMWebCommon.setRowStyleClass` | - | - | Sets row style class for ENUM switch history list display |
| - | `bean.sendMessageString` (multiple) | - | - | Reads/writes values in data bean fields (view-level data access, not DB CRUD) |
| - | `bean.getDataBeanArray` (multiple) | - | - | Retrieves nested data bean arrays from the main bean |

**Note:** This method performs **zero database CRUD operations**. It is a pure display-preparation method that reads from and writes to the X31SDataBeanAccess hierarchy (in-memory view model objects). The only terminal operations are bean value access and the `setRowStyleClass` call. No SC (Service Component) or CBS (Common Business Service) methods are invoked. The pre-computed evidence table provided lists method calls that are called elsewhere in the class but not within `initEdit` itself.

## 5. Dependency Trace

| # | Caller (Screen/Batch) | Call Chain (Full Path to this Method) | Terminal (SC / CRUD / Entity) |
|---|----------------------|--------------------------------------|-------------------------------|
| 1 | `ZMW01904SFLogic.getInfoInitData()` | `getInfoInitData()` -> `initEdit(bean)` | `setRowStyleClass [-]`, `isNullBlank [-]`, `sendMessageString [-]` (no DB operations) |

**Terminal operations from this method:**
- `setRowStyleClass` - sets CSS class on ENUM switch history list rows
- `sendMessageString` - reads/writes display values in data bean fields
- `getDataBeanArray` - retrieves nested data bean arrays
- `formatTelNo` - formats phone number for display

## 6. Per-Branch Detail Blocks

**Block 1** — [SET] Read own company provider codes (L~623-624)

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `jisha_jgs_cd = bean[0].sendMessageString(JISHA_JGS_CD, DATABEAN_GET_VALUE)` |
| 2 | EXEC | `jisha_jgs_cd_nm = bean[0].sendMessageString(JISHA_JGS_CD_NM, DATABEAN_GET_VALUE)` |

> Reads the own company's provider code and provider name from the main bean for later comparison against the numbering acquisition provider code.

**Block 2** — [SET] Get phone number consent detail info bean (L~627)

| # | Type | Code |
|---|------|------|
| 1 | CALL | `ezm0121InfoBean = bean[0].getDataBeanArray(EZM0121A010CBSMSG1LIST).getDataBean(0)` |

> Retrieves the phone number consent detail info list and gets the first element. This contains phone number, individual/corporate phone number band code, and numbering acquisition provider code.

**Block 3** — [SET] Declare phone number display variables (L~629-637)

| # | Type | Code |
|---|------|------|
| 1 | SET | `telno = ""` // Phone number display field |
| 2 | SET | `kojin_hojin_tln_tai_cd_nm = ""` // Individual/corporate phone number band code name |
| 3 | SET | `kojin_hojin_tln_tai_cd = ""` // Individual/corporate phone number band code |
| 4 | SET | `tln_stku_tsjgs_cd = ""` // Numbering acquisition provider code |
| 5 | SET | `tel_um = UM_M` // Phone number data existence: "0" (none) [-> UM_M="0"] |

**Block 4** — [IF] Phone number consent info bean exists (L~639)

> If the phone number consent detail info bean is not null (data was transferred from a previous screen), populate display fields from it. Otherwise keep default empty values.

| # | Type | Code |
|---|------|------|
| 1 | SET | `tel_um = UM_U` // Data exists [-> UM_U="1"] |
| 2 | EXEC | `telno = ezm0121InfoBean.sendMessageString(TELNO_03, DATABEAN_GET_VALUE)` |
| 3 | EXEC | `kojin_hojin_tln_tai_cd_nm = ezm0121InfoBean.sendMessageString(KOJIN_HOJIN_TLN_TAI_CD_NM_03, ...)` |
| 4 | EXEC | `kojin_hojin_tln_tai_cd = ezm0121InfoBean.sendMessageString(KOJIN_HOJIN_TLN_TAI_CD_03, ...)` |
| 5 | EXEC | `tln_stku_tsjgs_cd = ezm0121InfoBean.sendMessageString(TLN_STKU_TSJGS_CD_03, ...)` |

> Reads the four key fields from the phone number consent info bean. The Japanese comment notes this handles cases where data is cleared during screen transitions (e.g., after completing "inter-provider switch to other company phone number").

**Block 5** — [IF/ELSE] Set display phone number (L~651)

> Formats the phone number using `JCNWebCommon.formatTelNo()` if non-empty; otherwise sets empty string.

| # | Type | Code |
|---|------|------|
| 1 | IF | `!StringUtils.isEmpty(telno)` [L651] |
| 2 | SET | `bean[0].sendMessageString(DSP_TELNO, DATABEAN_SET_VALUE, JCNWebCommon.formatTelNo(telno))` |
| 3 | ELSE | [L653] |
| 4 | SET | `bean[0].sendMessageString(DSP_TELNO, DATABEAN_SET_VALUE, "")` |

| # | Type | Code |
|---|------|------|
| 1 | SET | `bean[0].sendMessageString(DSP_KOJIN_HOJIN_TLN_TAI_CD, DATABEAN_SET_VALUE, kojin_hojin_tln_tai_cd_nm)` |

**Block 6** — [SET] Get port receipt info and post-change provider info (L~657-660)

| # | Type | Code |
|---|------|------|
| 1 | CALL | `listZMSV013303SC_etu0151b040cbsmsg1list_ETU0151B040CBSMsg1List = bean[0].getDataBeanArray(ETU0151B040CBSMSG1LIST)` |
| 2 | SET | `subbean_1 = null` |
| 3 | CALL | `cngaf_itnsk_jgs_cd_info = bean[0].getDataBeanArray(CNGAF_ITNSK_JGS_CD_INFO)` |
| 4 | CALL | `subbean3 = cngaf_itnsk_jgs_cd_info.getDataBean(0)` |

**Block 7** — [IF] No phone number data or empty port receipt list (L~664)

> When there is no phone number data (`tel_um = UM_M`) or the port receipt info list is empty, the method clears all display fields and sets the post-change provider code list to default.

| # | Type | Code |
|---|------|------|
| 1 | IF | `UM_M.equals(tel_um) || list.getCount() == 0` [L664] |
| 2 | SET | `bean[0].sendMessageString(DSP_SINSEI_NAIYO, DATABEAN_SET_VALUE, "")` |
| 3 | SET | `bean[0].sendMessageString(DSP_KIRIKAESHORI, DATABEAN_SET_VALUE, "")` |
| 4 | SET | `bean[0].sendMessageString(DSP_BNGSHUTK_JGS_CD, DATABEAN_SET_VALUE, "")` |
| 5 | SET | `bean[0].sendMessageString(DSP_ITNMT_JGS_CD, DATABEAN_SET_VALUE, "")` |
| 6 | SET | `bean[0].sendMessageString(DSP_CNGBF_ITNSK_JGS_CD, DATABEAN_SET_VALUE, "")` |
| 7 | EXEC | `subbean3.sendMessage(CNGAF_ITNSK_JGS_CD_LIST_01, DATABEAN_CLEAR)` |
| 8 | EXEC | `subbean3.sendMessage(CNGAF_ITNSK_JGS_NM_LIST_01, DATABEAN_CLEAR)` |
| 9 | SET | `subbean3.sendMessageString(CNGAF_ITNSK_JGS_CD_LIST_01, DATABEAN_ADD_VALUE, "0")` |
| 10 | SET | `subbean3.sendMessageString(CNGAF_ITNSK_JGS_NM_LIST_01, DATABEAN_ADD_VALUE, "")` |
| 11 | SET | `bean[0].sendMessageString(DSP_CNGBF_ITNSK_DOMAIN, DATABEAN_SET_VALUE, "")` |
| 12 | SET | `bean[0].sendMessageString(DSP_CNGAF_ITNSK_DOMAIN, DATABEAN_SET_VALUE, "")` |

**Block 8** — [ELSE] Port receipt info exists - process latest application data (L~667)

**Block 8.1** — [SET] Initialize variables for latest application data (L~673-709)

| # | Type | Code |
|---|------|------|
| 1 | SET | `port_out_no_1 = ""` |
| 2 | SET | `gene_add_dtm_1 = ""` |
| 3 | SET | `port_out_stat_1 = ""` |
| 4 | SET | `tk_kh_1 = ""` |
| 5 | SET | `odkh_judge_tk_kh_1 = ""` |
| 6 | SET | `cancel_skbt_1 = ""` |
| 7 | SET | `cl_skbt_1 = ""` |
| 8 | SET | `chumn_kind_1 = ""` |
| 9 | SET | `kirikaeshori_flg = KIRIKAESHORIFLG_MIJIKKOU` [-> "0"] |
| 10 | SET | `switch_sod_hakko_dtm_1 = ""` |
| 11 | SET | Various intermediate variables for provider info and validity flags |
| 12 | SET | `uk_flg_1 = ENDIS_DIS` [-> "0"] |
| 13 | SET | `bef_um_flg_2 = UM_M` [-> "0"] |

**Block 8.2** — [SET] Get first data bean and extract fields (L~714-727)

| # | Type | Code |
|---|------|------|
| 1 | CALL | `subbean_1 = list.getDataBean(0)` |
| 2 | EXEC | `port_out_no_1 = subbean_1.sendMessageString(PORT_OUT_NO_04, DATABEAN_GET_VALUE)` |
| 3 | EXEC | `gene_add_dtm_1 = subbean_1.sendMessageString(GENE_ADD_DTM_04, DATABEAN_GET_VALUE)` |
| 4 | EXEC | `port_out_stat_1 = subbean_1.sendMessageString(PORT_OUT_STAT_04, DATABEAN_GET_VALUE)` |
| 5 | EXEC | `tk_kh_1 = subbean_1.sendMessageString(TK_KH_04, DATABEAN_GET_VALUE)` |
| 6 | EXEC | `odkh_judge_tk_kh_1 = subbean_1.sendMessageString(ODKH_JUDGE_TK_KH_04, ...)` |
| 7 | EXEC | `cancel_skbt_1 = subbean_1.sendMessageString(CANCEL_SKBT_04, ...)` |
| 8 | EXEC | `cl_skbt_1 = subbean_1.sendMessageString(CL_SKBT_04, ...)` |
| 9 | EXEC | `chumn_kind_1 = subbean_1.sendMessageString(CHUMN_KIND_04, ...)` |
| 10 | EXEC | `switch_sod_hakko_dtm_1 = subbean_1.sendMessageString(SWITCH_SOD_HAKKO_DTM_04, ...)` |
| 11 | EXEC | Provider name and domain fields retrieval |

**Block 8.3** — [IF] Latest application data validity check (L~729)

> Determines whether the latest application data is valid based on multiple criteria. All conditions must be true:
> - Port-out status is "030" (CSV export complete) or "050" (work completed)
> - Availability is "1" (can provide)
> - Order-ability judgment is NULL or "1" (can provide)
> - Cancellation identifier is "0" (not cancelled)
> - Cancellation flag is "0" (not cancelled)

| # | Type | Code |
|---|------|------|
| 1 | IF | `(PORT_OUT_STAT_030.equals(stat) OR PORT_OUT_STAT_050.equals(stat)) AND KAHI_KA.equals(tk_kh) AND (isNullBlank(odkh) OR KAHI_KA.equals(odkh)) AND UM_M.equals(cancel_skbt) AND UM_M.equals(cl_skbt)` [L729] |

**Block 8.3.1** — [SET] Valid latest data - set new application fields (L~750-756)

| # | Type | Code |
|---|------|------|
| 1 | SET | `bean[0].sendMessageString(NEWTSHIN_PORT_OUT_NO, ..., port_out_no_1)` |
| 2 | SET | `bean[0].sendMessageString(NEWTSHIN_GENE_ADD_DTM, ..., gene_add_dtm_1)` |
| 3 | SET | `bean[0].sendMessageString(NEWTSHIN_ITNSK_JGS_CD, ..., subbean_1.itens_jigyosha_no_04)` |
| 4 | SET | `bean[0].sendMessageString(NEWTSHIN_SVC_KEI_NO, ..., subbean_1.svc_kei_no_04)` |

**Block 8.3.2** — [IF/ELSE] Switch SOD execution date check (L~758)

> If switch SOD issuance datetime is not set, the switch processing is "not executed". If it is set, the switch processing is "executed".

| # | Type | Code |
|---|------|------|
| 1 | IF | `StringUtils.isEmpty(switch_sod_hakko_dtm_1)` [L758] |
| 2 | SET | `DSP_KIRIKAESHORI = KIRIKAESHORI_MIJIKKOU` ("未実行") |
| 3 | SET | `KIRIKAESHORI_FLG = KIRIKAESHORIFLG_MIJIKKOU` [-> "0"] |
| 4 | SET | `kirikaeshori_flg = KIRIKAESHORIFLG_MIJIKKOU` |
| 5 | ELSE | [L767] |
| 6 | SET | `DSP_KIRIKAESHORI = KIRIKAESHORI_JIKKOUZUMI` ("実行済み") |
| 7 | SET | `KIRIKAESHORI_FLG = KIRIKAESHORIFLG_JIKKOUZUMI` [-> "1"] |
| 8 | SET | `kirikaeshori_flg = KIRIKAESHORIFLG_JIKKOUZUMI` |

| # | Type | Code |
|---|------|------|
| 1 | SET | `DSP_BNGSHUTK_JGS_CD = nosk_daihyo_jgs_no_nm_1` |
| 2 | SET | `DSP_ITNMT_JGS_CD = itenm_daihyo_jigyosha_no_nm_1` |
| 3 | SET | `uk_flg_1 = ENDIS_EN` [-> "1"] |

**Block 8.4** — [IF] Latest data is valid - check previous application (L~778)

> Only enters if `uk_flg_1 = ENDIS_EN` (latest data was valid). Iterates through the port receipt info list from index 1 onward to find a valid previous application.

| # | Type | Code |
|---|------|------|
| 1 | IF | `ENDIS_EN.equals(uk_flg_1)` [L778] |

**Block 8.4.1** — [FOR] Previous application data validation loop (L~783)

| # | Type | Code |
|---|------|------|
| 1 | FOR | `i = 1; i < list.getCount()` [L783] |

**Block 8.4.2** — [IF] Previous application validity check (L~811)

> Checks if previous application has status "050" (work completed), is available, and is not cancelled.

| # | Type | Code |
|---|------|------|
| 1 | IF | `PORT_OUT_STAT_050.equals(port_out_stat_2) AND KAHI_KA.equals(tk_kh_2) AND (isNullBlank(odkh_2) OR KAHI_KA.equals(odkh_2)) AND UM_M.equals(cancel_skbt_2) AND UM_M.equals(cl_skbt_2)` [L811] |
| 2 | SET | `ZNKISHIN_PORT_OUT_NO = subbean_2.port_out_no_04` |
| 3 | SET | `ZNKISHIN_GENE_ADD_DTM = subbean_2.gene_add_dtm_04` |
| 4 | SET | `itens_jigyosha_no_nm_2 = subbean_2.itens_jigyosha_no_nm_04` |
| 5 | SET | `itens_jigyosha_domain_2 = subbean_2.itens_jigyosha_domain_04` |
| 6 | SET | `bef_um_flg_2 = UM_U` [-> "1"] |
| 7 | EXEC | `break` |

**Block 9** — [IF/ELSE-IF chain] Application content determination (L~823-1018)

> This is the core decision block of the method. It determines what text to display for the "application content" (申請内容) field based on a 3-way combination:
> - `chumn_kind` (order type): 1=Port Transfer, 2=Return, 3=Inter-provider, 4=Cancellation
> - `kojin_hojin_tln_tai_cd` (customer type): 1=Individual, 2=Corporate
> - `kirikaeshori_flg` (switch executed): 0=Not executed, 1=Executed

**Block 9.1** — [IF] chumn_kind=1, own provider, individual, not executed (L~823)

> Port-out (FTTH phone number) - displayed

| # | Type | Code |
|---|------|------|
| 1 | IF | `CHUMN_KIND_1.equals(chumn_kind_1) AND jisha_jgs_cd.equals(tln_stku_tsjgs_cd) AND KOJIN_HOJIN_TLN_TAI_CD_KOJIN.equals(kojin_hojin_tln_tai_cd) AND KIRIKAESHORIFLG_MIJIKKOU.equals(kirikaeshori_flg)` [L823] |
| 2 | SET | `DSP_SINSEI_NAIYO = SINSEI_NAIYO_1` ("Port-out (FTTH phone number)") |
| 3 | SET | `SINSEI_NAIYO_FLG = SINSEI_NAIYO_FLG_1` [-> "1"] |

**Block 9.2** — [ELSE-IF] chumn_kind=1, own provider, individual, executed (L~840)

> Port-out (FTTH phone number) . Cancel - displayed

| # | Type | Code |
|---|------|------|
| 1 | IF | `CHUMN_KIND_1.equals(chumn_kind_1) AND jisha_jgs_cd.equals(tln_stku_tsjgs_cd) AND KOJIN_HOJIN_TLN_TAI_CD_KOJIN.equals(kojin_hojin_tln_tai_cd) AND KIRIKAESHORIFLG_JIKKOUZUMI.equals(kirikaeshori_flg)` [L840] |
| 2 | SET | `DSP_SINSEI_NAIYO = SINSEI_NAIYO_5` ("Port-out (FTTH phone number) . Cancel") |
| 3 | SET | `SINSEI_NAIYO_FLG = SINSEI_NAIYO_FLG_5` [-> "5"] |

**Block 9.3** — [ELSE-IF] chumn_kind=1, own provider, corporate (L~857)

> Individual/corporate band code = 2 (corporate) - both display fields and switch processing cleared

| # | Type | Code |
|---|------|------|
| 1 | IF | `CHUMN_KIND_1.equals(chumn_kind_1) AND jisha_jgs_cd.equals(tln_stku_tsjgs_cd) AND KOJIN_HOJIN_TLN_TAI_CD_HOJIN.equals(kojin_hojin_tln_tai_cd)` [L857] |
| 2 | SET | `DSP_SINSEI_NAIYO = SINSEI_NAIYO_9` ("") |
| 3 | SET | `SINSEI_NAIYO_FLG = SINSEI_NAIYO_FLG_9` [-> "9"] |
| 4 | SET | `DSP_KIRIKAESHORI = ""` |
| 5 | SET | `KIRIKAESHORI_FLG = ""` |
| 6 | SET | `kirikaeshori_flg = ""` |

**Block 9.4** — [ELSE-IF] chumn_kind=1, not own provider, individual, not executed (L~872)

> Inter-provider switch (other company phone number) - displayed

| # | Type | Code |
|---|------|------|
| 1 | IF | `CHUMN_KIND_1.equals(chumn_kind_1) AND (isNullBlank(tln_stku_tsjgs_cd) OR jisha_jgs_cd != tln_stku_tsjgs_cd) AND KOJIN_HOJIN_TLN_TAI_CD_KOJIN.equals(kojin_hojin_tln_tai_cd) AND KIRIKAESHORIFLG_MIJIKKOU.equals(kirikaeshori_flg)` [L872] |
| 2 | SET | `DSP_SINSEI_NAIYO = SINSEI_NAIYO_4` ("Inter-provider switch (other company phone number)") |
| 3 | SET | `SINSEI_NAIYO_FLG = SINSEI_NAIYO_FLG_4` [-> "4"] |

**Block 9.5** — [ELSE-IF] chumn_kind=1, not own provider, individual, executed (L~890)

> Cleared (no applicable content, switch processing cleared)

| # | Type | Code |
|---|------|------|
| 1 | IF | `CHUMN_KIND_1.equals(chumn_kind_1) AND (isNullBlank(tln_stku_tsjgs_cd) OR jisha_jgs_cd != tln_stku_tsjgs_cd) AND KOJIN_HOJIN_TLN_TAI_CD_KOJIN.equals(kojin_hojin_tln_tai_cd) AND KIRIKAESHORIFLG_JIKKOUZUMI.equals(kirikaeshori_flg)` [L890] |
| 2 | SET | `DSP_SINSEI_NAIYO = SINSEI_NAIYO_9` ("") |
| 3 | SET | `SINSEI_NAIYO_FLG = SINSEI_NAIYO_FLG_9` [-> "9"] |
| 4 | SET | `DSP_KIRIKAESHORI = ""` |
| 5 | SET | `KIRIKAESHORI_FLG = ""` |
| 6 | SET | `kirikaeshori_flg = ""` |

**Block 9.6** — [ELSE-IF] chumn_kind=1, not own provider, corporate (L~907)

> Cleared

| # | Type | Code |
|---|------|------|
| 1 | IF | `CHUMN_KIND_1.equals(chumn_kind_1) AND (isNullBlank(tln_stku_tsjgs_cd) OR jisha_jgs_cd != tln_stku_tsjgs_cd) AND KOJIN_HOJIN_TLN_TAI_CD_HOJIN.equals(kojin_hojin_tln_tai_cd)` [L907] |
| 2 | SET | `DSP_SINSEI_NAIYO = SINSEI_NAIYO_9` ("") |
| 3 | SET | `SINSEI_NAIYO_FLG = SINSEI_NAIYO_FLG_9` [-> "9"] |
| 4 | SET | `DSP_KIRIKAESHORI = ""` |
| 5 | SET | `kirikaeshori_flg = ""` |

**Block 9.7** — [ELSE-IF] chumn_kind=3, own provider, individual, not executed (L~922)

> Inter-provider switch (FTTH phone number) - displayed

| # | Type | Code |
|---|------|------|
| 1 | IF | `CHUMN_KIND_3.equals(chumn_kind_1) AND jisha_jgs_cd.equals(tln_stku_tsjgs_cd) AND KOJIN_HOJIN_TLN_TAI_CD_KOJIN.equals(kojin_hojin_tln_tai_cd) AND KIRIKAESHORIFLG_MIJIKKOU.equals(kirikaeshori_flg)` [L922] |
| 2 | SET | `DSP_SINSEI_NAIYO = SINSEI_NAIYO_2` ("Inter-provider switch (FTTH phone number)") |
| 3 | SET | `SINSEI_NAIYO_FLG = SINSEI_NAIYO_FLG_2` [-> "2"] |

**Block 9.8** — [ELSE-IF] chumn_kind=3, own provider, individual, executed (L~940)

> Inter-provider switch (FTTH phone number) . Cancel - displayed

| # | Type | Code |
|---|------|------|
| 1 | IF | `CHUMN_KIND_3.equals(chumn_kind_1) AND jisha_jgs_cd.equals(tln_stku_tsjgs_cd) AND KOJIN_HOJIN_TLN_TAI_CD_KOJIN.equals(kojin_hojin_tln_tai_cd) AND KIRIKAESHORIFLG_JIKKOUZUMI.equals(kirikaeshori_flg)` [L940] |
| 2 | SET | `DSP_SINSEI_NAIYO = SINSEI_NAIYO_6` ("Inter-provider switch (FTTH phone number) . Cancel") |
| 3 | SET | `SINSEI_NAIYO_FLG = SINSEI_NAIYO_FLG_6` [-> "6"] |

**Block 9.9** — [ELSE-IF] chumn_kind=3, own provider, corporate, not executed (L~957)

> Inter-provider switch (FTTH phone number) - displayed

| # | Type | Code |
|---|------|------|
| 1 | IF | `CHUMN_KIND_3.equals(chumn_kind_1) AND jisha_jgs_cd.equals(tln_stku_tsjgs_cd) AND KOJIN_HOJIN_TLN_TAI_CD_HOJIN.equals(kojin_hojin_tln_tai_cd) AND KIRIKAESHORIFLG_MIJIKKOU.equals(kirikaeshori_flg)` [L957] |
| 2 | SET | `DSP_SINSEI_NAIYO = SINSEI_NAIYO_2` ("Inter-provider switch (FTTH phone number)") |
| 3 | SET | `SINSEI_NAIYO_FLG = SINSEI_NAIYO_FLG_2` [-> "2"] |

**Block 9.10** — [ELSE-IF] chumn_kind=3, own provider, corporate, executed (L~975)

> Inter-provider switch (FTTH phone number) . Cancel - displayed

| # | Type | Code |
|---|------|------|
| 1 | IF | `CHUMN_KIND_3.equals(chumn_kind_1) AND jisha_jgs_cd.equals(tln_stku_tsjgs_cd) AND KOJIN_HOJIN_TLN_TAI_CD_HOJIN.equals(kojin_hojin_tln_tai_cd) AND KIRIKAESHORIFLG_JIKKOUZUMI.equals(kirikaeshori_flg)` [L975] |
| 2 | SET | `DSP_SINSEI_NAIYO = SINSEI_NAIYO_6` ("Inter-provider switch (FTTH phone number) . Cancel") |
| 3 | SET | `SINSEI_NAIYO_FLG = SINSEI_NAIYO_FLG_6` [-> "6"] |

**Block 9.11** — [ELSE-IF] chumn_kind=3, not own provider, individual, not executed (L~990)

> Inter-provider switch (other company phone number) - displayed

| # | Type | Code |
|---|------|------|
| 1 | IF | `CHUMN_KIND_3.equals(chumn_kind_1) AND (isNullBlank(tln_stku_tsjgs_cd) OR jisha_jgs_cd != tln_stku_tsjgs_cd) AND KOJIN_HOJIN_TLN_TAI_CD_KOJIN.equals(kojin_hojin_tln_tai_cd) AND KIRIKAESHORIFLG_MIJIKKOU.equals(kirikaeshori_flg)` [L990] |
| 2 | SET | `DSP_SINSEI_NAIYO = SINSEI_NAIYO_4` ("Inter-provider switch (other company phone number)") |
| 3 | SET | `SINSEI_NAIYO_FLG = SINSEI_NAIYO_FLG_4` [-> "4"] |

**Block 9.12** — [ELSE-IF] chumn_kind=3, not own provider, individual, executed (L~1007)

> Cleared

| # | Type | Code |
|---|------|------|
| 1 | IF | `CHUMN_KIND_3.equals(chumn_kind_1) AND (isNullBlank(tln_stku_tsjgs_cd) OR jisha_jgs_cd != tln_stku_tsjgs_cd) AND KOJIN_HOJIN_TLN_TAI_CD_KOJIN.equals(kojin_hojin_tln_tai_cd) AND KIRIKAESHORIFLG_JIKKOUZUMI.equals(kirikaeshori_flg)` [L1007] |
| 2 | SET | `DSP_SINSEI_NAIYO = SINSEI_NAIYO_9` ("") |
| 3 | SET | `SINSEI_NAIYO_FLG = SINSEI_NAIYO_FLG_9` [-> "9"] |
| 4 | SET | `DSP_KIRIKAESHORI = ""` |
| 5 | SET | `KIRIKAESHORI_FLG = ""` |
| 6 | SET | `kirikaeshori_flg = ""` |

**Block 9.13** — [ELSE-IF] chumn_kind=3, not own provider, corporate (L~1024)

> Cleared

| # | Type | Code |
|---|------|------|
| 1 | IF | `CHUMN_KIND_3.equals(chumn_kind_1) AND (isNullBlank(tln_stku_tsjgs_cd) OR jisha_jgs_cd != tln_stku_tsjgs_cd) AND KOJIN_HOJIN_TLN_TAI_CD_HOJIN.equals(kojin_hojin_tln_tai_cd)` [L1024] |
| 2 | SET | `DSP_SINSEI_NAIYO = SINSEI_NAIYO_9` ("") |
| 3 | SET | `SINSEI_NAIYO_FLG = SINSEI_NAIYO_FLG_9` [-> "9"] |
| 4 | SET | `DSP_KIRIKAESHORI = ""` |
| 5 | SET | `KIRIKAESHORI_FLG = ""` |
| 6 | SET | `kirikaeshori_flg = ""` |

**Block 9.14** — [ELSE-IF] chumn_kind=4, own provider, individual, not executed (L~1041)

> Number cancellation (other provider receipt) - displayed

| # | Type | Code |
|---|------|------|
| 1 | IF | `CHUMN_KIND_4.equals(chumn_kind_1) AND jisha_jgs_cd.equals(tln_stku_tsjgs_cd) AND KOJIN_HOJIN_TLN_TAI_CD_KOJIN.equals(kojin_hojin_tln_tai_cd) AND KIRIKAESHORIFLG_MIJIKKOU.equals(kirikaeshori_flg)` [L1041] |
| 2 | SET | `DSP_SINSEI_NAIYO = SINSEI_NAIYO_3` ("Number cancellation (other provider receipt)") |
| 3 | SET | `SINSEI_NAIYO_FLG = SINSEI_NAIYO_FLG_3` [-> "3"] |

**Block 9.15** — [ELSE-IF] chumn_kind=4, own provider, individual, executed (L~1057)

> Number cancellation (other provider receipt) . Cancel - displayed

| # | Type | Code |
|---|------|------|
| 1 | IF | `CHUMN_KIND_4.equals(chumn_kind_1) AND jisha_jgs_cd.equals(tln_stku_tsjgs_cd) AND KOJIN_HOJIN_TLN_TAI_CD_KOJIN.equals(kojin_hojin_tln_tai_cd) AND KIRIKAESHORIFLG_JIKKOUZUMI.equals(kirikaeshori_flg)` [L1057] |
| 2 | SET | `DSP_SINSEI_NAIYO = SINSEI_NAIYO_7` ("Number cancellation (other provider receipt) . Cancel") |
| 3 | SET | `SINSEI_NAIYO_FLG = SINSEI_NAIYO_FLG_7` [-> "7"] |

**Block 9.16** — [ELSE-IF] chumn_kind=4, own provider, corporate, not executed (L~1073)

> Number cancellation (other provider receipt) - displayed

| # | Type | Code |
|---|------|------|
| 1 | IF | `CHUMN_KIND_4.equals(chumn_kind_1) AND jisha_jgs_cd.equals(tln_stku_tsjgs_cd) AND KOJIN_HOJIN_TLN_TAI_CD_HOJIN.equals(kojin_hojin_tln_tai_cd) AND KIRIKAESHORIFLG_MIJIKKOU.equals(kirikaeshori_flg)` [L1073] |
| 2 | SET | `DSP_SINSEI_NAIYO = SINSEI_NAIYO_3` ("Number cancellation (other provider receipt)") |
| 3 | SET | `SINSEI_NAIYO_FLG = SINSEI_NAIYO_FLG_3` [-> "3"] |

**Block 9.17** — [ELSE-IF] chumn_kind=4, own provider, corporate, executed (L~1089)

> Number cancellation (other provider receipt) . Cancel - displayed

| # | Type | Code |
|---|------|------|
| 1 | IF | `CHUMN_KIND_4.equals(chumn_kind_1) AND jisha_jgs_cd.equals(tln_stku_tsjgs_cd) AND KOJIN_HOJIN_TLN_TAI_CD_HOJIN.equals(kojin_hojin_tln_tai_cd) AND KIRIKAESHORIFLG_JIKKOUZUMI.equals(kirikaeshori_flg)` [L1089] |
| 2 | SET | `DSP_SINSEI_NAIYO = SINSEI_NAIYO_7` ("Number cancellation (other provider receipt) . Cancel") |
| 3 | SET | `SINSEI_NAIYO_FLG = SINSEI_NAIYO_FLG_7` [-> "7"] |

**Block 9.18** — [ELSE-IF] chumn_kind=4, not own provider, individual (L~1104)

> Cleared

| # | Type | Code |
|---|------|------|
| 1 | IF | `CHUMN_KIND_4.equals(chumn_kind_1) AND (isNullBlank(tln_stku_tsjgs_cd) OR jisha_jgs_cd != tln_stku_tsjgs_cd) AND KOJIN_HOJIN_TLN_TAI_CD_KOJIN.equals(kojin_hojin_tln_tai_cd)` [L1104] |
| 2 | SET | `DSP_SINSEI_NAIYO = SINSEI_NAIYO_9` ("") |
| 3 | SET | `SINSEI_NAIYO_FLG = SINSEI_NAIYO_FLG_9` [-> "9"] |
| 4 | SET | `DSP_KIRIKAESHORI = ""` |
| 5 | SET | `KIRIKAESHORI_FLG = ""` |
| 6 | SET | `kirikaeshori_flg = ""` |

**Block 9.19** — [ELSE-IF] chumn_kind=4, not own provider, corporate (L~1119)

> Cleared

| # | Type | Code |
|---|------|------|
| 1 | IF | `CHUMN_KIND_4.equals(chumn_kind_1) AND (isNullBlank(tln_stku_tsjgs_cd) OR jisha_jgs_cd != tln_stku_tsjgs_cd) AND KOJIN_HOJIN_TLN_TAI_CD_HOJIN.equals(kojin_hojin_tln_tai_cd)` [L1119] |
| 2 | SET | `DSP_SINSEI_NAIYO = SINSEI_NAIYO_9` ("") |
| 3 | SET | `SINSEI_NAIYO_FLG = SINSEI_NAIYO_FLG_9` [-> "9"] |
| 4 | SET | `DSP_KIRIKAESHORI = ""` |
| 5 | SET | `KIRIKAESHORI_FLG = ""` |
| 6 | SET | `kirikaeshori_flg = ""` |

**Block 9.20** — [ELSE-IF] chumn_kind=2, own provider (L~1134)

> Number portability return - cleared regardless of customer type

| # | Type | Code |
|---|------|------|
| 1 | IF | `CHUMN_KIND_2.equals(chumn_kind_1) AND jisha_jgs_cd.equals(tln_stku_tsjgs_cd) AND (KOJIN_HOJIN_TLN_TAI_CD_KOJIN.equals(kojin_hojin_tln_tai_cd) OR KOJIN_HOJIN_TLN_TAI_CD_HOJIN.equals(kojin_hojin_tln_tai_cd))` [L1134] |
| 2 | SET | `DSP_SINSEI_NAIYO = SINSEI_NAIYO_9` ("") |
| 3 | SET | `SINSEI_NAIYO_FLG = SINSEI_NAIYO_FLG_9` [-> "9"] |
| 4 | SET | `DSP_KIRIKAESHORI = ""` |
| 5 | SET | `KIRIKAESHORI_FLG = ""` |
| 6 | SET | `kirikaeshori_flg = ""` |

**Block 9.21** — [ELSE-IF] chumn_kind=2, not own provider, individual, not executed (L~1152)

> Inter-provider switch (other company phone number) - displayed

| # | Type | Code |
|---|------|------|
| 1 | IF | `CHUMN_KIND_2.equals(chumn_kind_1) AND (isNullBlank(tln_stku_tsjgs_cd) OR jisha_jgs_cd != tln_stku_tsjgs_cd) AND KOJIN_HOJIN_TLN_TAI_CD_KOJIN.equals(kojin_hojin_tln_tai_cd) AND KIRIKAESHORIFLG_MIJIKKOU.equals(kirikaeshori_flg)` [L1152] |
| 2 | SET | `DSP_SINSEI_NAIYO = SINSEI_NAIYO_4` ("Inter-provider switch (other company phone number)") |
| 3 | SET | `SINSEI_NAIYO_FLG = SINSEI_NAIYO_FLG_4` [-> "4"] |

**Block 9.22** — [ELSE-IF] chumn_kind=2, not own provider, individual, executed (L~1167)

> Cleared

| # | Type | Code |
|---|------|------|
| 1 | IF | `CHUMN_KIND_2.equals(chumn_kind_1) AND (isNullBlank(tln_stku_tsjgs_cd) OR jisha_jgs_cd != tln_stku_tsjgs_cd) AND KOJIN_HOJIN_TLN_TAI_CD_KOJIN.equals(kojin_hojin_tln_tai_cd) AND KIRIKAESHORIFLG_JIKKOUZUMI.equals(kirikaeshori_flg)` [L1167] |
| 2 | SET | `DSP_SINSEI_NAIYO = SINSEI_NAIYO_9` ("") |
| 3 | SET | `SINSEI_NAIYO_FLG = SINSEI_NAIYO_FLG_9` [-> "9"] |
| 4 | SET | `DSP_KIRIKAESHORI = ""` |
| 5 | SET | `KIRIKAESHORI_FLG = ""` |
| 6 | SET | `kirikaeshori_flg = ""` |

**Block 9.23** — [ELSE-IF] chumn_kind=2, not own provider, corporate (L~1182)

> Cleared

| # | Type | Code |
|---|------|------|
| 1 | IF | `CHUMN_KIND_2.equals(chumn_kind_1) AND (isNullBlank(tln_stku_tsjgs_cd) OR jisha_jgs_cd != tln_stku_tsjgs_cd) AND KOJIN_HOJIN_TLN_TAI_CD_HOJIN.equals(kojin_hojin_tln_tai_cd)` [L1182] |
| 2 | SET | `DSP_SINSEI_NAIYO = SINSEI_NAIYO_9` ("") |
| 3 | SET | `SINSEI_NAIYO_FLG = SINSEI_NAIYO_FLG_9` [-> "9"] |
| 4 | SET | `DSP_KIRIKAESHORI = ""` |
| 5 | SET | `KIRIKAESHORI_FLG = ""` |
| 6 | SET | `kirikaeshori_flg = ""` |

**Block 9.24** — [ELSE] Fallback (L~1197)

> Any combination not matched above - cleared

| # | Type | Code |
|---|------|------|
| 1 | ELSE | [L1197] |
| 2 | SET | `DSP_SINSEI_NAIYO = SINSEI_NAIYO_9` ("") |
| 3 | SET | `SINSEI_NAIYO_FLG = SINSEI_NAIYO_FLG_9` [-> "9"] |
| 4 | SET | `DSP_KIRIKAESHORI = ""` |
| 5 | SET | `KIRIKAESHORI_FLG = ""` |
| 6 | SET | `kirikaeshori_flg = ""` |

**Block 10** — [IF/ELSE-IF] Before/after change provider code editing (L~1203)

> Based on the kirikaeshori_flg and sinsei_naiyo_flg, populates the before-change and after-change provider codes and domains.

**Block 10.1** — [IF] kirikaeshori_flg = MIJIKKOU (not executed) (L~1203)

> When switch processing is not yet executed:
> - If application content is "Inter-provider switch (other company phone number)", set before-change to own company and enum SOD domain
> - Otherwise: if no previous data exists, set before-change to own company; if previous data exists, set it to previous application's transfer destination provider

| # | Type | Code |
|---|------|------|
| 1 | IF | `KIRIKAESHORIFLG_MIJIKKOU.equals(kirikaeshori_flg)` [L1203] |
| 2 | IF | `SINSEI_NAIYO_FLG_4.equals(DSP_SINSEI_NAIYO)` |
| 3 | SET | `DSP_CNGBF_ITNSK_JGS_CD = jisha_jgs_cd_nm` |
| 4 | SET | `DSP_CNGBF_ITNSK_DOMAIN = ENUMSOD_DOMAIN` |
| 5 | ELSE | |
| 6 | IF | `UM_M.equals(bef_um_flg_2)` (no previous data) |
| 7 | SET | `DSP_CNGBF_ITNSK_JGS_CD = jisha_jgs_cd_nm` |
| 8 | SET | `DSP_CNGBF_ITNSK_DOMAIN = ENUMSOD_DOMAIN` |
| 9 | ELSE | (previous data exists) |
| 10 | SET | `DSP_CNGBF_ITNSK_JGS_CD = itens_jigyosha_no_nm_2` |
| 11 | SET | `DSP_CNGBF_ITNSK_DOMAIN = itens_jigyosha_domain_2` |

**Block 10.1.1** — [IF/ELSE] After-change provider code (L~1230)

| # | Type | Code |
|---|------|------|
| 1 | IF | `SINSEI_NAIYO_FLG_3.equals(DSP_SINSEI_NAIYO)` (Number cancellation) |
| 2 | EXEC | Clear CNGAF lists; set to default "0" then "1" + own company name |
| 3 | SET | `DSP_CNGAF_ITNSK_DOMAIN = ENUMSOD_DOMAIN` |
| 4 | ELSE | (not number cancellation) |
| 5 | EXEC | Clear CNGAF lists; set to default "0" then "1" + latest application's transfer destination provider name |
| 6 | SET | `DSP_CNGAF_ITNSK_DOMAIN = itens_jigyosha_domain_1` |

**Block 10.2** — [ELSE-IF] kirikaeshori_flg = JIKKOUZUMI (executed) (L~1256)

> When switch processing has already been executed:
> - If application content is "Number cancellation . Cancel", set before-change to own company
> - Otherwise, set before-change to latest application's transfer destination provider
> - For after-change: if previous data exists, use it; otherwise check if it's a cancel scenario (empty display) or default to own company + enum SOD domain

| # | Type | Code |
|---|------|------|
| 1 | IF | `KIRIKAESHORIFLG_JIKKOUZUMI.equals(kirikaeshori_flg)` [L1256] |
| 2 | IF | `SINSEI_NAIYO_FLG_7.equals(DSP_SINSEI_NAIYO)` (Number cancellation . Cancel) |
| 3 | SET | `DSP_CNGBF_ITNSK_JGS_CD = jisha_jgs_cd_nm` |
| 4 | SET | `DSP_CNGBF_ITNSK_DOMAIN = ENUMSOD_DOMAIN` |
| 5 | ELSE | |
| 6 | SET | `DSP_CNGBF_ITNSK_JGS_CD = itens_jigyosha_no_nm_1` |
| 7 | SET | `DSP_CNGBF_ITNSK_DOMAIN = itens_jigyosha_domain_1` |
| 8 | IF | `UM_U.equals(bef_um_flg_2)` (previous data exists) |
| 9 | EXEC | Clear CNGAF lists; set to default "0" then "1" + previous application's transfer destination provider |
| 10 | SET | `DSP_CNGAF_ITNSK_DOMAIN = itens_jigyosha_domain_2` |
| 11 | ELSE | |
| 12 | IF | `SINSEI_NAIYO_FLG_6.equals(...) OR SINSEI_NAIYO_FLG_7.equals(...)` |
| 13 | EXEC | Clear CNGAF lists; set to default "0" only (empty - registration not possible) |
| 14 | SET | `DSP_CNGAF_ITNSK_DOMAIN = ""` |
| 15 | ELSE | |
| 16 | EXEC | Clear CNGAF lists; set to default "0" then "1" + own company name |
| 17 | SET | `DSP_CNGAF_ITNSK_DOMAIN = ENUMSOD_DOMAIN` |

**Block 11** — [EXEC] Set row style class for ENUM switch history list (L~1287)

| # | Type | Code |
|---|------|------|
| 1 | CALL | `JZMWebCommon.setRowStyleClass(bean[0], EZM0541B010CBSMSG1LIST, ROW_STYLE_CLASS_02)` |

> Applies a CSS row style class to the ENUM switch history list for visual highlighting on the display screen.

## 7. Glossary

| Term | Type | Business Meaning |
|------|------|------------------|
| `jisha_jgs_cd` | Field | Own company provider code - the K-Opticom internal code identifying the provider (e.g., "5100" for K-Opticom) |
| `jisha_jgs_cd_nm` | Field | Own company provider name - the display name for the own company |
| `telno` | Field | Phone number - the subscriber's phone number for display (formatted with dashes) |
| `kojin_hojin_tln_tai_cd` | Field | Individual/Corporate phone number band code - "1" = Individual (個人), "2" = Corporate (法人) |
| `kojin_hojin_tln_tai_cd_nm` | Field | Individual/Corporate phone number band code name - the display label for the customer type |
| `tln_stku_tsjgs_cd` | Field | Numbering acquisition provider code - the provider from which the phone number was originally acquired |
| `tel_um` | Field | Phone number data existence flag - "0" = No data (UM_M), "1" = Has data (UM_U) |
| `port_out_no` | Field | Port-out number - the port-out request number for tracking the number transfer process |
| `gene_add_dtm` | Field | Registration date/time - when the port-out data was first registered |
| `port_out_stat` | Field | Port-out status - "030" = CSV export complete, "050" = Work completed |
| `tk_kh` | Field | Availability flag - "1" = Can provide (可), "0" = Cannot provide (否) |
| `odkh_judge_tk_kh` | Field | Order-ability judgment availability - NULL or "1" = Can provide |
| `cancel_skbt` | Field | Cancellation identifier - "0" = Not cancelled |
| `cl_skbt` | Field | Cancellation flag - "0" = Not cancelled |
| `chumn_kind` | Field | Order type - "1" = Number Portability Transfer, "2" = Number Portability Return, "3" = Inter-Provider Switch, "4" = Number Cancellation |
| `kirikaeshori_flg` | Field | Switch processing flag - "0" = Not executed (未実行), "1" = Executed (実行済み) |
| `switch_sod_hakko_dtm` | Field | Switch SOD issuance date/time - when the switch Service Order Data was issued |
| `uk_flg` | Field | Validity flag - "0" = Invalid (無効), "1" = Valid (有効) |
| `bef_um_flg` | Field | Previous existence flag - "0" = No previous data, "1" = Previous data exists |
| `nosk_daihyo_jgs_no_nm` | Field | Numbering acquisition representative provider name |
| `itenm_daihyo_jigyosha_no_nm` | Field | Pre-switch representative provider name name |
| `itens_jigyosha_no_nm` | Field | Post-transfer destination provider name (latest application) |
| `itens_jigyosha_domain` | Field | Post-transfer destination provider domain (latest application) |
| `SINSEI_NAIYO_1` | Display value | Port-out (FTTH phone number) |
| `SINSEI_NAIYO_2` | Display value | Inter-provider switch (FTTH phone number) |
| `SINSEI_NAIYO_3` | Display value | Number cancellation (other provider receipt) |
| `SINSEI_NAIYO_4` | Display value | Inter-provider switch (other company phone number) |
| `SINSEI_NAIYO_5` | Display value | Port-out (FTTH phone number) . Cancel |
| `SINSEI_NAIYO_6` | Display value | Inter-provider switch (FTTH phone number) . Cancel |
| `SINSEI_NAIYO_7` | Display value | Number cancellation (other provider receipt) . Cancel |
| `SINSEI_NAIYO_9` | Display value | No applicable (該当なし - empty string) |
| `ENUM` | Acronym | ENUM Switch (ENUM切替) - the number portability / ENUM switching business process |
| `ENUM Switch` | Business term | The Japanese telecom number portability process where subscribers transfer phone numbers between providers |
| `SOD` | Acronym | Service Order Data - the order data entity for switch processing |
| `FTTH` | Business term | Fiber To The Home - K-Opticom's fiber-optic broadband internet service |
| `番号転送` | Japanese | Number Portability Transfer - the standard number port-out process |
| `番号戻り` | Japanese | Number Portability Return - returning a ported number back to the original provider |
| `事業者間移転` | Japanese | Inter-Provider Switch - switching between different telecom providers |
| `番号廃止` | Japanese | Number Cancellation - cancelling a phone number |
| `個人` | Japanese | Individual (customer type) |
| `法人` | Japanese | Corporate (customer type) |
| `未実行` | Japanese | Not executed (switch processing not yet performed) |
| `実行済み` | Japanese | Executed (switch processing has been completed) |
| `X31SDataBeanAccess` | Technical | The X31 framework data bean class used for passing screen data between layers |
| `X31SDataBeanAccessArray` | Technical | Array wrapper for X31SDataBeanAccess objects, supporting list operations |
| `EZM0121A010CBSMSG1LIST` | Field | Phone number consent detail info list data bean key |
| `ETU0151B040CBSMSG1LIST` | Field | Port receipt info list data bean key |
| `EZM0541B010CBSMSG1LIST` | Field | ENUM switch history list data bean key |
| `CNGAF_ITNSK_JGS_CD_INFO` | Field | Post-change provider code info data bean key |
| `CNGAF_ITNSK_JGS_CD_LIST_01` | Field | Post-change provider code list (dropdown) key |
| `DSP_TELNO` | Field | Phone number (for display) - the display-key field for the formatted phone number |
| `DSP_SINSEI_NAIYO` | Field | Application content (for display) - the display-key field showing the business operation type |
| `DSP_KIRIKAESHORI` | Field | Switch processing (for display) - shows "Not executed" or "Executed" |
| `DSP_CNGBF_ITNSK_JGS_CD` | Field | Pre-change provider code (for display) |
| `DSP_CNGAF_ITNSK_DOMAIN` | Field | Post-change provider domain (for display) |
| `ENUMSOD_DOMAIN` | Field | ENUM SOD own company domain - the internal domain "eonet.ne.jp" |
| `K-Opticom` | Business term | The telecom service provider (K-Opticom Inc., a Japanese FTTH provider) |
| `番号ポータル` | Japanese | Number Portal - the Japanese number portability system |