# Business Logic - KKW04202SFLogic.actionFix() [1002 LOC]

| Field | Value |
|-------|-------|
| Fully Qualified Name | `eo.web.webview.KKW04202SF.KKW04202SFLogic` |
| Layer | Controller / Web Business Logic (Screen Logic) |
| Module | `KKW04202SF` (Package: `eo.web.webview.KKW04202SF`) |

## 1. Role

### KKW04202SFLogic.actionFix()

`actionFix` is the confirm-and-register entry point for the Address Change Registration feature (住所変更登録機能) within the eo Customer Core System operated by K-Opticom, a Japanese telecommunications provider. It serves as the terminal business-logic method invoked when a customer operations operator clicks the "confirm" (確定) button on the address change screen. The method orchestrates the entire lifecycle of address change: it first runs a pre-registration validation service (KKSV0698), then branches into sub-workflows depending on the transaction mode and registration phase, invokes the corresponding downstream service, and finally triggers a completion-registration batch (KKSV0325) when the operator performs manual main registration.

The method handles four broad service categories:

1. **Temporary Registration (KKSV0664)** - For input-in-progress cases where data is saved without final confirmation. First phase of a two-step registration workflow.

2. **Address Correction (KKSV0725)** - For the second phase where the operator reviews and confirms input content. Optionally invokes Number Temporary Return Correction (KKSV0868) for BMP (Furo-ichi temporary return) corrections. Processes all service types (Network, Telephone, TV) including work order updates, service agreement confirmations, contract modifications, and equipment registration.

3. **Main Registration (KKSV0674)** - The core address change workflow for manual main registration. Processes all three service domains (eo Light Network, eo Light Telephone, eo Light TV) with comprehensive service contract management, equipment handling, work order registration, pricing changes, delivery registration, and workflow updates.

4. **Completion Registration (KKSV0325)** - Finalizes the address change when the ad-mode manual registration path is triggered. Creates an electronic file attachment, calls the completion service, and integrates with the AxM administrative system if needed.

The method implements a **routing/dispatch pattern** based on `ido_div` (migration/division code) and `addPtn` (registration pattern) fields. It uses a **mapper delegation pattern** where each sub-service is invoked through a dedicated DB mapper (KKSV0664_KKSV0664OPDBMapper, KKSV0725_KKSV0725OPDBMapper, KKSV0674_KKSV0674OPDBMapper, KKSV0325_KKSV0325OPDBMapper). It acts as the central coordinator for the entire address change confirm process, called by multiple screen entry points.

Conditional branches:
- **Branch on `ido_div = "00019"` (Transfer/移動)**: Handles address transfer registration with sub-branches on `addPtn` (1=input-in-progress, 2=input-confirmed). Includes validation for construction work requests and smart balance discount status checks.
- **Branch on `ido_div = "00020"` (Transfer+Registration/移動・登録)**: Handles the combined transfer and main registration path with additional validation checks (checkAdchgFix, checkKojireq), electronic file creation, and completion registration invocation.
- **Else branch**: Throws `IllegalArgumentException` for unrecognized `ido_div` values.

## 2. Processing Pattern (Detailed Business Logic)

### Flowchart

```mermaid
flowchart TD
    START(["actionFix start"])
    PRE_CHECK(["Setup checkAdchgFix mapper"])
    CALL_CHECK_SVC["invokeService checkAdchgFix"]
    COND_SERVICE{"checkAdchgFix passed?"}
    SVC_FAIL["Service failed"]
    SVC_FAIL_RETURN["Return false"]
    DISPATCH["Dispatch by ido_div"]
    COND_TRANSFER{"ido_div = 00019?"}
    BR_TRANSFER["Transfer 00019"]
    COND_ADD_PTN{"addPtn = 1?"}
    BR_INPUT["Input-in-progress 1"]
    CALL_0664["invokeService KKSV0664"]
    COND_FIX{"addPtn = 2?"}
    BR_FIX["Input-confirmed 2"]
    COND_RVS{"rvsPtn = 2?"}
    COND_BMP{"BMP correction?"}
    CALL_0868["invokeService KKSV0868"]
    CALL_0725["invokeService KKSV0725"]
    BR_MAIN["Main reg"]
    CALL_0674["invokeService KKSV0674"]
    BR_OTHER["Other addPtn"]
    ERR_ILLEGAL["Error: illegal addPtn"]
    POST_CHECK["Post-check"]
    CALL_0325["invokeService KKSV0325"]
    AXM_NEEDED{"AxM needed?"}
    CALL_AXM["invokeService CKSV9001"]

    START --> PRE_CHECK --> CALL_CHECK_SVC --> COND_SERVICE
    COND_SERVICE -- No --> SVC_FAIL --> SVC_FAIL_RETURN
    COND_SERVICE -- Yes --> DISPATCH
    DISPATCH --> COND_TRANSFER
    COND_TRANSFER -- No --> BR_MAIN --> CALL_0674
    COND_TRANSFER -- Yes --> BR_TRANSFER --> COND_ADD_PTN
    COND_ADD_PTN -- Yes --> BR_INPUT --> CALL_0664 --> POST_CHECK
    COND_ADD_PTN -- No --> COND_FIX
    COND_FIX -- Yes --> BR_FIX --> COND_RVS
    COND_RVS -- Yes --> COND_BMP
    COND_BMP -- Yes --> CALL_0868 --> CALL_0725
    COND_BMP -- No --> CALL_0725
    COND_RVS -- No --> BR_MAIN --> CALL_0674
    COND_FIX -- No --> BR_OTHER --> ERR_ILLEGAL
    BR_MAIN --> POST_CHECK
    CALL_0725 --> POST_CHECK
    CALL_0674 --> POST_CHECK
    POST_CHECK --> SVC_OK["Post-check OK"]
    SVC_OK --> CALL_0325
    CALL_0325 --> AXM_NEEDED
    AXM_NEEDED -- Yes --> CALL_AXM --> END_OK
    AXM_NEEDED -- No --> END_OK
    END_OK["Return true"]
```

### Detailed Processing Steps

1. **Initialization (L4694-L4710)**: Get service form bean via `getServiceFormBean()`. Convert display data to codes via `dataConvertDispToCode(paramBean)`. Initialize `paramMap`, `inputMap`, `outputMap` HashMaps. Create `KKSV0698_KKSV0698OPDBMapper` for pre-registration validation.

2. **Pre-check Setup (L4713-L4738)**: Configure check mapper with check mode "2" (confirm). Set validation rules via 17 CC/SC calls: `setKKSV069804CC` through `setKKSV069824CC` covering address change integrity including construction request status, smart balance discount, and security pack checks.

3. **Pre-check Service Invocation (L4741-L4756)**: Set usecase ID `KKSV0698` and operation ID `KKSV0698OP`. Call `invokeService(paramMap, inputMap, outputMap)`. Capture result in `kKSV698Map`. If `isCheckRslt(outputMap, kksv698mapper)` returns false, generate common header and return `false`.

4. **Rozeo Restriction Check (L4759-L4790)**: Retrieve TV/Network/Telephone service division flags. Get work scope code `kjScopeCd`. If scope is "070" (rozeo-restricted), validate no fiber TV removal work alongside rozeo-restricted cases. If Network/Telephone are PDING (pending) and no removal work exists, display error `EKBE175-KW` and return `false`.

5. **Exception Handling (L4793-L4798)**: Catch `JCCWebServiceException` - generate common header and re-throw.

6. **Migration Division Dispatch (L4801-L4803)**: Get `ido_div` field. Two main paths: "00019" (Transfer) and "00020" (Transfer+Registration).

### Path: Transfer (ido_div = "00019")

7. **Get Parameters (L4808-L4812)**: Retrieve `addPtn` (registration pattern) and `rvsPtn` (recovery pattern).

8. **Construction Request Status Check (L4816-L4837)**: Call `getKKSV069807CC`. Get `nskjUm` (new construction existence). If: separate construction method + removal work + non-mansion property + no new construction, display error `EKB0290-JW` and return `false`.

9. **Sub-branch: addPtn = "1" - Input-in-progress (L4840)**: Set usecase `KKSV0664`, operation `KKSV0664OP`. Create `KKSV0664_KKSV0664OPDBMapper`. Set operation date. Call `setKKSV066401CC` (temporary registration CC). Call `invokeService` to save as temporary registration.

10. **Sub-branch: addPtn = "2", rvsPtn = "2" - BMP Correction (L4868-L4886)**: Get `bmpTmpRtrnHoseiCd` and `adchgAftMod`. If `adchgAftMod = MODIFY_RANGE_BMP_HOSEI` AND `bmpTmpRtrnHoseiCd` is `BMP_HOSEI_RTCLR` or `BMP_HOSEI_VASET`, invoke `KKSV0868` service (Number Temporary Return Correction) for equipment temporary return at previous address.

11. **Sub-branch: KKSV0725 - Address Correction (L4889-L5027)**: Sets up `KKSV0725_KKSV0725OPDBMapper` with 60+ CC/SC calls organized by domain:
    - **Common**: Address change date modification (KKSV072522CC), address change registration (KKSV072521CC)
    - **Construction**: Network/Telephone/TV change discrimination, frame cell change, general construction change
    - **Service Agreements**: Network (KKSV072501SC), Telephone (KKSV072502SC), TV (KKSV072503SC), Customer agreement (KKSV072504SC)
    - **Telephone**: Service cancellation mapping (KKSV0725301CC), withdrawal date change (KKSV0725302CC/304CC), S/T cancel (KKSV0725516CC/517CC), phone number registration 1st/2nd (KKSV072525CC/26CC), phone number info change (KKSV0725310CC), cancel execution (KKSV0725312CC), transfer token (KKSV0725315CC), Furo-ichi correction (KKSV072527CC/28CC), application registration (KKSV072508SC), discount auto-apply (KKSV072529CC), verification (KKSV072530CC/31CC/32CC), workflow (KKSV072533CC), delivery receipt (KKSV072535CC)
    - **TV**: Service agreement (KKSV0725504SC), registration (KKSV0725502CC), discount auto-apply (KKSV0725505CC), verification (KKSV0725507CC/509CC/510CC), workflow (KKSV0725512CC), progress registration (KKSV0725503SC), cancellation (KKSV0725515CC/516CC/517CC), device provision cancellation (KKSV0725518CC), SV0725719CC/701CC, service order issuance (KKSV072555CC), telephone VLAN order (KKSV072516SC), notice registration (KKSV072537CC/38CC/39CC), smart balance mapping (KKSV0725704CC), work order equipment info (KKSV0725337CC), work order processing (KKSV0725331CC/332CC/702CC), work domain (KKSV0725Work), same-number transfer (KKSV0725341CC/342CC)
    - Then calls `invokeService(paramMap, inputMap, outputMap)`

12. **Sub-branch: Main Registration KKSV0674 (L5030)**: Sets up `KKSV0674_KKSV0674OPDBMapper` with extensive calls:
    - **Common**: Customer agreement (KKSV0674005SC), billing contract number (KKSV0674080CC), application registration (KKSV0674001CC), withdrawal line registration (KKSV0674083CC/001SC), address corrections (gaidashi-saki KKSV0674002CC, billing KKSV0674003CC, contractor KKSV0674004CC)
    - **Network**: Network change discrimination (KKSV0674005CC), service agreement before change (KKSV0674011SC), usage location change (KKSV0674006CC), equipment delivery/installation (KKSV0674009CC), pricing code change (KKSV0674012CC), workflow (KKSV0674153CC/157CC), cancel execution (KKSV0674013CC), S/T cancel mapping (KKSV0674006SC), registration (KKSV0674014CC), option update (KKSV0674015CC), equipment continuation (KKSV0674016CC), device operation (KKSV0674270CC), device change (KKSV0674253CC), delivery receipt (KKSV0674046SC), indoor inventory (KKSV0674261CC), e-informing list (KKSV0674170CC), service cancellation (KKSV0674018CC), device provision cancellation (KKSV0674020CC), service agreement (KKSV0674008SC), discount auto-apply (KKSV0674021CC), verification (KKSV0674075CC/024CC/027CC), workflow (KKSV0674030CC), billing (KKSV0674147CC), billing number (KKSV0674033CC)
    - **Telephone**: Telephone change discrimination (KKSV0674036CC), service agreement before change (KKSV0674012SC), usage location change (KKSV0674007CC), equipment delivery/installation (KKSV0674010CC), cancel execution (KKSV0674038CC), phone reg 1st (KKSV0674037CC), phone reg 2nd (KKSV0674082CC), phone change 1st (KKSV0674041CC), cancel 1st (KKSV0674045CC), transfer token 1st (KKSV0674078CC), phone info 2nd (KKSV0674217CC), phone change 2nd (KKSV0674042CC), cancel 2nd (KKSV0674046CC), transfer token 2nd (KKSV0674079CC), e-informing (KKSV0674171CC), service cancellation (KKSV0674047CC), device change (KKSV0674257CC), delivery receipt (KKSV0674047SC), indoor inventory (KKSV0674263CC), VDSL exchange (KKSV0674267CC), service agreement (KKSV0674009SC), discount auto-apply (KKSV0674022CC), verification (KKSV0674076CC/025CC/028CC), workflow (KKSV0674031CC), billing (KKSV0674149CC), billing number (KKSV0674034CC), Furo-ichi registration (KKSV0674201CC/202CC)
    - **TV**: TV change discrimination (KKSV0674048CC), service agreement before change (KKSV0674013SC), usage location change (KKSV0674008CC), equipment delivery (KKSV0674011CC), pricing code change (KKSV0674049CC), cancel execution (KKSV0674050CC), registration (KKSV0674051CC), continuation (KKSV0674053CC), S/T code change (KKSV0674054CC), service cancellation (KKSV0674055CC), device registration (KKSV0674056CC), delivery receipt (KKSV0674015SC), device cancellation (KKSV0674057CC), device change (KKSV0674058CC), delivery receipt (KKSV0674017SC), service agreement (KKSV0674010SC), discount auto-apply (KKSV0674023CC), STAR CHANNEL (KKSV0674291CC), verification (KKSV0674077CC/026CC/029CC), workflow (KKSV0674032CC), billing (KKSV0674151CC), billing number (KKSV0674035CC), content change (KKSV0674066CC), equipment delivery line (KKSV0674276CC), device change line (KKSV0674278CC), delivery receipt line (KKSV0674048SC), indoor inventory line (KKSV0674282CC)
    - **Post-processing**: Withdrawal line start update (KKSV0674186CC/172CC), equipment provision (KKSV0674059CC), SV0674Work, service order Network (KKSV0674068CC), service order Telephone (KKSV0674265CC), billing notice (KKSV0674139CC/073CC), smart balance (KKSV0674302CC), temporary registration (KKSV0674247CC), registration (KKSV0674074CC)
    - **Progress Registrations**: Phone change (KKSV0674018SC/019SC), work order Network removal/new (KKSV0674020SC/021SC), Telephone removal/new (KKSV0674022SC/023SC), TV removal/new (KKSV0674024SC/026SC), phone cancel memo (KKSV0674015SC), equipment change (KKSV0674028SC/029SC/030SC/031SC/032SC/033SC/034SC/035SC/036SC/037SC/038SC/039SC/040SC), Network cancellation (KKSV0674041SC), phone cancel 1st (KKSV0674042SC), phone cancel 2nd (KKSV0674043SC), Telephone cancellation (KKSV0674044SC), TV cancellation (KKSV0674045SC), service group (KKSV0674295CC), use stop Network (KKSV0674296CC), use stop Telephone (KKSV0674297CC)
    - Then calls `invokeService(paramMap, inputMap, outputMap)`

13. **Error Handling**: If `addPtn` is neither "1" nor "2", throw `IllegalArgumentException`.

### Path: Transfer+Registration (ido_div = "00020")

14. **Ad-mode Check (L5073-L5082)**: If `CMN_AD_SWCH_PDN = "1"` AND `addPtn = "2"`, run `checkAdchgFix(paramBean, kKSV698Map)`. If fails, generate header and return `false`.

15. **Construction Request Check (L5085-L5091)**: Call `checkKojireq(paramBean, outputMap, kksv698mapper)`. If fails, generate header and return `false`.

16. **Electronic File Creation (L5094-L5112)**: Call `createEfile(svcFormBean)`. Set file attachment: identifier `SIF_ECC0111D010`, list `up_load_list`, item `efile`. Re-initialize maps.

17. **Completion Registration KKSV0325 (L5115-L5175)**: Create `KKSV0325_KKSV0325OPDBMapper`. Set usecase `KKSV0325`, operation `KKSV0325OP`:
    - Address change異動予約 reflection CC (KKSV032514CC)
    - Cancel execution CC with orgCd/orgNm (KKSV032512CC)
    - Address change date modification CC (KKSV032507CC)
    - Telephone service number addition CC/SC (KKSV032501CC/01SC)
    - Telephone 1: date/time (KKSV032504SC), cancel transfer (KKSV032502SC), change confirm (KKSV032502CC)
    - Telephone 2: date/time (KKSV032505SC), cancel transfer (KKSV032503SC), change confirm (KKSV032503CC)
    - Transfer token 1st (KKSV032504CC), 2nd (KKSV032505CC)
    - Device change confirm (KKSV032506CC), device operation (KKSV032511CC), VLAN-ID (KKSV032508CC), device re-location (KKSV032510CC), other provider異動 notification (KKSV032515CC), transfer dest update (KKSV032517CC)
    - Calls `invokeService(paramMap, inputMap, outputMap, uploadMap)` with file attachment

18. **Error Check (L5185-L5196)**: Call `getErrInfo(paramBean[0], outputMap, "KKSV032501CC")`. If `isErr`, generate header and return `false`.

19. **AxM Integration (L5100-L5125)**: If `isNeedAxMRenkei(outputMap)` is true, set up new maps with usecase `CKSV9001`, operation `CKSV9001OP`. Get `sysId` from form bean. Set `upd_trgt_sysid` in linkage map. Call `invokeService(paramMap2, inputMap2, outputMap2)`.

20. **Post-processing (L5199-L5215)**: Convert codes to display via `dataConvertCodeToDisp(paramBean)`. Set next screen to `KKW04210` (Address Change Registration Complete). Generate common header. Display message `EKB4390--I` ("Address change registration"). Return `true`.

## 3. Parameter Analysis

| No | Parameter Name | Type | Business Description |
|----|---------------|------|---------------------|
| - | (none) | - | - |

This method takes no explicit parameters. It operates on instance state and screen form beans obtained internally.

### Instance Fields / External State Read

| Source | Type | Business Description |
|--------|------|---------------------|
| `getServiceFormBean()` | `X31SDataBeanAccess` | Screen form bean containing address change input fields submitted by the operator |
| `getCommonInfoBean()` | `X31SDataBeanAccess` | Common info bean carrying cross-screen data including next screen ID and organization info |
| `KKW04202SFConst.CMN_IDO_DIV` | String | Migration/division code routing the method (00019=Transfer, 00020=Transfer+Registration) |
| `KKW04202SFConst.CTRL_AD_CHG_ADD_PTN` | String | Registration pattern: 1=input-in-progress, 2=input-confirmed, 3=clear |
| `KKW04202SFConst.CTRL_RVS_PAT` | String | Recovery pattern for second-phase confirmation |
| `KKW04202SFConst.EOH_TV_USE_SVC_CHG_DIV` | String | TV service change division (continuation/change/keep) |
| `KKW04202SFConst.EOH_NET_USE_SVC_CHG_DIV` | String | Network service change division |
| `KKW04202SFConst.EOH_TEL_USE_SVC_CHG_DIV` | String | Telephone service change division |
| `KKW04202SFConst.TEKKYO_AD_KJ_SCOPE_PDN` | String | Work scope dropdown (070=rozeo-restricted) |
| `KKW04202SFConst.MANSION_BUKKEN_CD_AF` | String | Mansion property code after change (001=mansion) |
| `KKW04202SFConst.KOJI_IRAI_WAY` | String | Construction request method (separate/joint) |
| `KKW04202SFConst.IRAI_KOJI` | String | Requested construction type (removal/new) |
| `KKW04202SFConst.NSKL_UM` | String | New construction existence flag |
| `KKW04202SFConst.USE_STP_STA_YMD` | String | Use stop period start date |
| `KKW04202SFConst.CMN_SYSID` | String | System ID for AxM integration |
| `CommonInfoCFConst.ORG_CD_01` | String | Organization code for operation attribution |
| `CommonInfoCFConst.ORG_NM_01` | String | Organization name for operation attribution |
| `KKW04202SFConst.CTRL_SVKEI_NO` | String | Service contract number |
| `KKW04202SFConst.CTRL_IDO_RSN` | String | Migration reason codes list |
| `KKW04202SFConst.BMP_TMP_RTRN_HOSEI_CD` | String | BMP temporary return correction code |
| `KKW04202SFConst.ADCHG_AFT_MOD` | String | Address change post-modification flag |
| `JPCModelConstant.FUNC_CD_1` | String | Function code 1 (registration) |
| `JPCModelConstant.FUNC_CD_2` | String | Function code 2 (update) |
| `JKKCommonConst.FUNC_CODE_1` | String | Function code 1 for CC/SC calls |
| `JKKCommonConst.FUNC_CODE_2` | String | Function code 2 for CC/SC calls |

## 4. CRUD Operations / Called Services

| CRUD | SC / CBS | SC Code | Entity / DB | Operation Description |
|------|----------|---------|-------------|---------------------|
| R | `checkAdchgFix` | (internal) | - | Internal pre-registration validation |
| R | `checkKojireq` | (internal) | - | Internal construction request status check |
| R | `createEfile` | (internal) | - | Creates electronic file for attachment |
| R | `isNeedAxMRenkei` | (internal) | - | Checks if AxM integration is required |
| R | `getErrInfo` | (internal) | - | Extracts error info from output map |
| R | `isChangeToAdd` | (internal) | - | Checks if change is for TV addition |
| R | `isChangeToKeiyakuNashi` | (internal) | - | Checks if change is to no-contract |
| R | `getPdnSelectedCd` | (internal) | - | Gets selected dropdown code value |
| - | `JCCBatCommon.invokeService` | JCCBatCommon | - | Core service invocation engine |
| - | `KKW04202SFLogic.makeAdchgCmnHeader` | KKW04202SFLogic | - | Generates address change common header |
| R | `OneStopDataBeanAccessArray.getDataBean` | OneStopDataBeanAccessArray | - | Retrieves data bean array |
| R | `OneStopDataBeanAccess.getDataBeanArray` | OneStopDataBeanAccess | - | Retrieves data bean array |
| - | `OneStopDataBeanAccess.sendMessageString` | OneStopDataBeanAccess | - | Sends message string to bean |
| - | `JKKAddSupportCC.setMessageInfo` | JKKAddSupportCC | - | Sets screen message info |
| R | `JCCBPCommon.getOpeDate` | JCCBPCommon | - | Gets operation date |
| R | `JCCBPCommon.getOpeDateTimeStamp` | JCCBPCommon | - | Gets operation date-time stamp |
| R | `JACModelCommon.getSysDateTimeStamp` | JACModelCommon | - | Gets system date-time stamp |
| R | `JCCModelCommon.getSysDateTimeStamp` | JCCModelCommon | - | Gets system date-time stamp |
| R | `JCHModelCommon.getSysDateTimeStamp` | JCHModelCommon | - | Gets system date-time stamp |
| R | `JKKModelCommon.getOpeDate` | JKKModelCommon | - | Gets operation date |

### Sub-services invoked (via invokeService):

| CRUD | SC / CBS | SC Code | Entity / DB | Operation Description |
|------|----------|---------|-------------|---------------------|
| R | `KKSV0698` | KKSV0698 | - | Pre-registration validation (checkAdchgFix) |
| C | `KKSV0664` | KKSV0664 | - | Address change temporary registration |
| C | `KKSV0868` | KKSV0868 | - | Number temporary return correction |
| C | `KKSV0725` | KKSV0725 | - | Address change correction (main workflow) |
| C | `KKSV0674` | KKSV0674 | - | Address change main registration (core) |
| C | `KKSV0325` | KKSV0325 | - | Address change completion registration |
| C | `CKSV9001` | CKSV9001 | - | AxM integration service |

The KKSV0674 and KKSV0725 services contain hundreds of CC/SC calls internally that handle individual operations across all three service domains.

## 5. Dependency Trace

### Who calls this method (callers):

| # | Caller (Screen/Batch) | Call Chain (Full Path to this Method) | Terminal (SC / CRUD / Entity) |
|---|----------------------|--------------------------------------|-------------------------------|
| 1 | Screen:KKSV0698 | `KKSV0698_controller.actionFix()` -> `KKW04202SFLogic.actionFix()` | `checkAdchgFix [R] -`, `KKSV0698 [C/R] -` |
| 2 | Screen:KKSV0664 | `KKSV0664_controller.actionFix()` -> `KKW04202SFLogic.actionFix()` | `KKSV0664 [C] -` |
| 3 | Screen:KKSV0725 | `KKSV0725_controller.actionFix()` -> `KKW04202SFLogic.actionFix()` | `KKSV0725 [C] -` |
| 4 | Screen:KKSV0674 | `KKSV0674_controller.actionFix()` -> `KKW04202SFLogic.actionFix()` | `KKSV0674 [C] -` |
| 5 | Screen:KKSV0325 | `KKSV0325_controller.actionFix()` -> `KKW04202SFLogic.actionFix()` | `KKSV0325 [C] -`, `CKSV9001 [C] -` |
| 6 | Screen:KKW04209 | `KKW04209_controller.actionFix()` -> `KKW04202SFLogic.actionFix()` | `checkAdchgFix [R] -`, `checkKojireq [R] -` |
| 7 | Screen:KKW04210 | `KKW04210_controller.actionFix()` -> `KKW04202SFLogic.actionFix()` | `createEfile [R] -`, `KKSV0325 [C] -` |

### Call hierarchy from actionFix():

```
actionFix()
  +-- dataConvertDispToCode()
  +-- KKW0698_KKSV0698OPDBMapper
  |     +-- setKKSV0698_checkMode()
  |     +-- setKKSV069804CC() ~ setKKSV069824CC() [17 calls]
  |     +-- getKKSV069804CC()
  |     +-- getKKSV069818CC()
  +-- invokeService(KKSV0698)
  +-- isCheckRslt()
  +-- makeAdchgCmnHeader()
  +-- getPdnSelectedCd()
  +-- [ido_div=00019 path]
  |     +-- getKKSV069807CC()
  |     +-- KKW0664_KKSV0664OPDBMapper
  |     |     +-- setOpeDate()
  |     |     +-- setKKSV066401CC()
  |     +-- invokeService(KKSV0664)
  |     +-- [addPtn=2, rvsPtn=2 path]
  |     |     +-- KKW0868_KKSV0868OPDBMapper
  |     |     |     +-- setKKSV086801CC()
  |     |     +-- invokeService(KKSV0868)
  |     +-- KKW0725_KKSV0725OPDBMapper
  |     |     +-- setOpeDate()
  |     |     +-- setKKSV072522CC ~ setKKSV0725Work() [60+ calls]
  |     |     +-- isChangeToAdd()
  |     |     +-- isChangeToKeiyakuNashi()
  |     +-- invokeService(KKSV0725)
  +-- [ido_div=00020 path]
  |     +-- checkAdchgFix()
  |     +-- checkKojireq()
  |     +-- createEfile()
  |     +-- KKW0325_KKSV0325OPDBMapper
  |     |     +-- setOpeDate()
  |     |     +-- setKKSV032514CC ~ setKKSV032517CC [15+ calls]
  |     |     +-- getErrInfo()
  |     +-- invokeService(KKSV0325, uploadMap)
  |     +-- [if isNeedAxMRenkei]
  |           +-- invokeService(CKSV9001)
  +-- dataConvertCodeToDisp()
  +-- getCommonInfoBean()
  +-- makeAdchgCmnHeader()
  +-- setMessageInfo()
```

## 6. Per-Branch Detail Blocks

**Block 1** — IF `(ido_div.equals("00019"))` (L4804) `[IDO_DIV_00019="00019"]`

> Address transfer (移動) registration path.

| # | Type | Code |
|---|------|------|
| 1 | GET | `paramBean[0].sendMessageString(CMN_IDO_DIV, DATABEAN_GET_VALUE)` |
| 2 | IF | `"00019".equals(ido_div)` [-> `IDO_DIV_00019="00019"`] |

**Block 1.1** — IF `(addPtn.equals(INPUT_CHU))` (L4839) `[INPUT_CHU="1"]`

> Temporary registration branch. Saves address change data without final confirmation.

| # | Type | Code |
|---|------|------|
| 1 | GET | `paramBean[0].sendMessageString(CTRL_AD_CHG_ADD_PTN, DATABEAN_GET_VALUE)` [-> `INPUT_CHU="1"`] |
| 2 | GET | `paramBean[0].sendMessageString(CTRL_RVS_PAT, DATABEAN_GET_VALUE)` |
| 3 | SET | `paramMap.put(TELEGRAM_INFO_USECASE_ID, "KKSV0664")` |
| 4 | SET | `paramMap.put(TELEGRAM_INFO_OPERATION_ID, "KKSV0664OP")` |
| 5 | NEW | `KKSV0664_KKSV0664OPDBMapper mapper = new KKSV0664_KKSV0664OPDBMapper()` |
| 6 | CALL | `mapper.setOpeDate(JCCWebCommon.getOpeDate(this, null))` |
| 7 | CALL | `mapper.setKKSV066401CC(paramBean, inputMap, JKKCommonConst.FUNC_CODE_1)` |
| 8 | CALL | `invokeService(paramMap, inputMap, outputMap)` |

**Block 1.2** — IF `(addPtn.equals(INPUT_FIX))` (L4868) `[INPUT_FIX="2"]`

> Input content confirmed branch. Invokes address correction service (KKSV0725).

| # | Type | Code |
|---|------|------|
| 1 | IF | `INPUT_FIX.equals(rvsPtn)` [-> `INPUT_FIX="2"`] |

**Block 1.2.1** — IF `(BMP correction)` (L4872) `[MODIFY_RANGE_BMP_HOSEI, BMP_HOSEI_RTCLR, BMP_HOSEI_VASET]`

> BMP temporary return correction. Invoke Number Temporary Return Correction service.

| # | Type | Code |
|---|------|------|
| 1 | GET | `paramBean[0].sendMessageString(BMP_TMP_RTRN_HOSEI_CD, DATABEAN_GET_VALUE)` |
| 2 | GET | `paramBean[0].sendMessageString(ADCHG_AFT_MOD, DATABEAN_GET_VALUE)` |
| 3 | IF | `MODIFY_RANGE_BMP_HOSEI.equals(adchgAftMod) && (BMP_HOSEI_RTCLR.equals(bmpTmpRtrnHoseiCd) || BMP_HOSEI_VASET.equals(bmpTmpRtrnHoseiCd))` |
| 4 | SET | `paramMap.put(TELEGRAM_INFO_USECASE_ID, "KKSV0868")` |
| 5 | SET | `paramMap.put(TELEGRAM_INFO_OPERATION_ID, "KKSV0868OP")` |
| 6 | NEW | `KKSV0868_KKSV0868OPDBMapper mapper = new KKSV0868_KKSV0868OPDBMapper()` |
| 7 | CALL | `mapper.setKKSV086801CC(paramBean, inputMap, JKKCommonConst.FUNC_CODE_1)` |
| 8 | CALL | `invokeService(paramMap, inputMap, outputMap)` |

**Block 1.2.2** — KKSV0725 Address Correction (L4889)

> Largest block. 60+ CC/SC calls across all three service domains (Network, Telephone, TV).

| # | Type | Code |
|---|------|------|
| 1 | SET | `paramMap.put(TELEGRAM_INFO_USECASE_ID, "KKSV0725")` |
| 2 | SET | `paramMap.put(TELEGRAM_INFO_OPERATION_ID, "KKSV0725OP")` |
| 3 | NEW | `KKSV0725_KKSV0725OPDBMapper mapper = new KKSV0725_KKSV0725OPDBMapper()` |
| 4 | CALL | `mapper.setOpeDate(JCCWebCommon.getOpeDate(this, null))` |
| 5 | CALL | `mapper.setKKSV072522CC(paramBean, inputMap, JKKCommonConst.FUNC_CODE_1)` // Address change date modification |
| 6 | CALL | `mapper.setKKSV072500CC(paramBean, inputMap, JKKCommonConst.FUNC_CODE_1)` // Construction info |
| 7 | CALL | `mapper.setKKSV072501SC(paramBean, inputMap, JKKCommonConst.FUNC_CODE_1)` // Service agreement (Network) |
| 8 | CALL | `mapper.setKKSV072504SC(paramBean, inputMap, JKKCommonConst.FUNC_CODE_1)` // Customer agreement |
| 9 | CALL | `mapper.setKKSV072525CC(paramBean, inputMap, JKKCommonConst.FUNC_CODE_1)` // Phone reg 1st |
| 10 | CALL | `mapper.setKKSV0725500CC(paramBean, inputMap, isTvAddAfFix, isTvDelAfFix)` // TV change check |
| 11 | CALL | `mapper.setKKSV0725503SC(paramBean, inputMap, JKKCommonConst.FUNC_CODE_1, getSysDateTimeStamp())` // Progress reg (TV) |
| 12 | CALL | `mapper.setKKSV0725Work(paramBean, inputMap, JKKCommonConst.FUNC_CODE_1)` // Work area |
| 13 | CALL | `invokeService(paramMap, inputMap, outputMap)` |

**Block 1.3** — ELSE (not rvsPtn=2) (L5030)

> Main registration branch. Invokes KKSV0674 for comprehensive address change.

| # | Type | Code |
|---|------|------|
| 1 | SET | `paramMap.put(TELEGRAM_INFO_USECASE_ID, "KKSV0674")` |
| 2 | SET | `paramMap.put(TELEGRAM_INFO_OPERATION_ID, "KKSV0674OP")` |
| 3 | NEW | `KKSV0674_KKSV0674OPDBMapper mapper = new KKSV0674_KKSV0674OPDBMapper()` |
| 4 | CALL | `mapper.setOpeDate(JCCWebCommon.getOpeDate(this, null))` |
| 5 | CALL | `mapper.setKKSV0674005SC(paramBean, inputMap, JKKCommonConst.FUNC_CODE_1)` // Customer agreement |
| 6 | CALL | `mapper.setKKSV0674001CC(paramBean, inputMap, JKKCommonConst.FUNC_CODE_1, getOpeDateTimeStamp())` // Application reg |
| 7 | CALL | `mapper.setKKSV0674001SC(paramBean, inputMap, JKKCommonConst.FUNC_CODE_1)` // Withdrawal line reg |
| 8 | CALL | `mapper.setKKSV0674002CC(paramBean, inputMap, JKKCommonConst.FUNC_CODE_1)` // Gaidashi-saki address |
| 9 | CALL | `mapper.setKKSV0674003CC(paramBean, inputMap, JKKCommonConst.FUNC_CODE_1)` // Billing address |
| 10 | CALL | `mapper.setKKSV0674004CC(paramBean, inputMap, JKKCommonConst.FUNC_CODE_1)` // Contractor address |
| 11-40 | CALL | Multiple CC/SC calls for Network, Telephone, TV domains (see Section 2) |
| 41 | CALL | `mapper.setKKSV0674041SC(paramBean, inputMap, JKKCommonConst.FUNC_CODE_1, getSysDateTimeStamp())` // Network cancellation |
| 42 | CALL | `mapper.setKKSV0674295CC(paramBean, inputMap, JKKCommonConst.FUNC_CODE_1, getSysDateTimeStamp())` // Service group setting |
| 43-55 | CALL | Various CC/SC calls for use stop period, post-processing |
| 56 | CALL | `mapper.setKKSV0674Work(paramBean, inputMap, JKKCommonConst.FUNC_CODE_1)` // Work area |
| 57 | CALL | `invokeService(paramMap, inputMap, outputMap)` |

**Block 2** — IF `(ido_div.equals("00020"))` (L5065) `[IDO_DIV_00020="00020"]`

> Transfer+Registration branch for ad-mode manual registration.

| # | Type | Code |
|---|------|------|
| 1 | IF | `ido_div.equals("00020") && addPtn.equals("2") && CMN_AD_SWCH_PDN.equals("1")` |

**Block 2.1** — IF `(checkAdchgFix fails)` (L5073)

| # | Type | Code |
|---|------|------|
| 1 | CALL | `checkAdchgFix(paramBean, kKSV698Map)` |
| 2 | IF | `!result` |
| 3 | CALL | `makeAdchgCmnHeader(svcFormBean)` |
| 4 | RETURN | `false` |

**Block 2.2** — IF `(checkKojireq fails)` (L5085)

| # | Type | Code |
|---|------|------|
| 1 | CALL | `checkKojireq(paramBean, outputMap, kksv698mapper)` |
| 2 | IF | `!result` |
| 3 | CALL | `makeAdchgCmnHeader(svcFormBean)` |
| 4 | RETURN | `false` |

**Block 2.3** — Electronic file creation + KKSV0325 (L5094)

| # | Type | Code |
|---|------|------|
| 1 | CALL | `byte[] eFile = createEfile(svcFormBean)` |
| 2 | SET | `fileMap.put(TELEGRAM_INFO_ATTACH_IDENTIFUCD, "SIF_ECC0111D010")` |
| 3 | NEW | `KKSV0325_KKSV0325OPDBMapper mapper0325 = new KKSV0325_KKSV0325OPDBMapper()` |
| 4 | SET | `paramMap.put(TELEGRAM_INFO_USECASE_ID, UCID_KKSV0325)` |
| 5 | SET | `paramMap.put(TELEGRAM_INFO_OPERATION_ID, OPID_KKSV0325OP)` |
| 6 | CALL | `mapper0325.setOpeDate(JCCWebCommon.getOpeDate(this, null))` |
| 7 | CALL | `mapper0325.setKKSV032514CC(paramBean, inputMap, JPCModelConstant.FUNC_CD_1)` |
| 8 | CALL | `mapper0325.setKKSV032512CC(paramBean, inputMap, JPCModelConstant.FUNC_CD_1, orgCd, orgNm)` |
| 9 | CALL | `mapper0325.setKKSV032507CC(paramBean, inputMap, JPCModelConstant.FUNC_CD_1)` |
| 10 | CALL | `mapper0325.setKKSV032501CC(paramBean, inputMap, JPCModelConstant.FUNC_CD_1, orgCd, orgNm, kKSV698Map)` |
| 11 | CALL | `mapper0325.setKKSV032501SC(paramBean, inputMap, JPCModelConstant.FUNC_CD_1)` |
| 12 | CALL | `mapper0325.setKKSV032504SC(paramBean, inputMap, JPCModelConstant.FUNC_CD_1)` // Telephone 1 date/time |
| 13 | CALL | `mapper0325.setKKSV032502SC(paramBean, inputMap, JPCModelConstant.FUNC_CD_1)` // Telephone 1 cancel |
| 14 | CALL | `mapper0325.setKKSV032502CC(paramBean, inputMap, JPCModelConstant.FUNC_CD_1)` // Telephone 1 confirm |
| 15 | CALL | `mapper0325.setKKSV032505SC(paramBean, inputMap, JPCModelConstant.FUNC_CD_1)` // Telephone 2 date/time |
| 16 | CALL | `mapper0325.setKKSV032503SC(paramBean, inputMap, JPCModelConstant.FUNC_CD_1)` // Telephone 2 cancel |
| 17 | CALL | `mapper0325.setKKSV032503CC(paramBean, inputMap, JPCModelConstant.FUNC_CD_1)` // Telephone 2 confirm |
| 18 | CALL | `mapper0325.setKKSV032504CC(paramBean, inputMap, JPCModelConstant.FUNC_CD_1)` // Transfer token 1st |
| 19 | CALL | `mapper0325.setKKSV032505CC(paramBean, inputMap, JPCModelConstant.FUNC_CD_1)` // Transfer token 2nd |
| 20 | CALL | `mapper0325.setKKSV032506CC(paramBean, inputMap, JPCModelConstant.FUNC_CD_1)` // Device change |
| 21-28 | CALL | Device operation, VLAN-ID, device re-location, other provider notification, transfer dest update |
| 29 | CALL | `invokeService(paramMap, inputMap, outputMap, uploadMap)` |
| 30 | CALL | `getErrInfo(paramBean[0], outputMap, "KKSV032501CC")` |
| 31 | IF | `isErr` |
| 32 | CALL | `makeAdchgCmnHeader(svcFormBean)` |
| 33 | RETURN | `false` |

**Block 3** — IF `(isNeedAxMRenkei(outputMap))` (L5100)

> AxM (administrative system) integration.

| # | Type | Code |
|---|------|------|
| 1 | IF | `isNeedAxMRenkei(outputMap)` |
| 2 | NEW | `paramMap2 = new HashMap<>()` |
| 3 | SET | `paramMap2.put(TELEGRAM_INFO_USECASE_ID, "CKSV9001")` |
| 4 | SET | `paramMap2.put(TELEGRAM_INFO_OPERATION_ID, "CKSV9001OP")` |
| 5 | GET | `sysId = svcFormBean.sendMessageString(CMN_SYSID, DATABEAN_GET_VALUE)` |
| 6 | NEW | `mapRenkeiCC = new HashMap<>()` |
| 7 | SET | `mapRenkeiCC.put("upd_trgt_sysid", sysId)` |
| 8 | SET | `inputMap2.put("CKSV900101CC", mapRenkeiCC)` |
| 9 | CALL | `invokeService(paramMap2, inputMap2, outputMap2)` |

**Block 4** — Post-processing (L5199)

| # | Type | Code |
|---|------|------|
| 1 | CALL | `dataConvertCodeToDisp(paramBean)` |
| 2 | CALL | `commonInfoBean.sendMessageString(NEXT_SCREEN_ID, DATABEAN_SET_VALUE, SCREEN_ID_KKW04210)` |
| 3 | CALL | `commonInfoBean.sendMessageString(NEXT_SCREEN_NAME, DATABEAN_SET_VALUE, SCREEN_NAME_KKW04210)` |
| 4 | CALL | `makeAdchgCmnHeader(svcFormBean)` |
| 5 | CALL | `setMessageInfo(this, "EKB4390--I", new String[]{"Address change registration"})` |
| 6 | RETURN | `true` |

## 7. Glossary

| Term | Type | Business Meaning |
|------|------|------------------|
| `ido_div` | Field | Migration/division code - classifies transaction type (00019=Transfer, 00020=Transfer+Registration) |
| `addPtn` | Field | Registration pattern - current phase (1=input-in-progress, 2=input-confirmed, 3=clear) |
| `rvsPtn` | Field | Recovery pattern - indicates second-phase confirmation operation |
| `kjScopeCd` | Field | Work scope code (070=rozeo-restricted scope) |
| `kojiIraiWay` | Field | Construction request method (separate/joint) |
| `iraiKoji` | Field | Requested construction type (removal/new) |
| `nskjUm` | Field | New construction existence flag |
| `mansionBukkenCdAf` | Field | Mansion property code after change (001=mansion, 002=mezone) |
| `bmpTmpRtrnHoseiCd` | Field | BMP temporary return correction code |
| `adchgAftMod` | Field | Address change post-modification flag |
| `tvUseKbn` | Field | TV service change division (continuation/change/keep) |
| `netUseKbn` | Field | Network service change division |
| `telUseKbn` | Field | Telephone service change division |
| `useStpStatymd` | Field | Use stop period start date |
| `nyukyoRsvYmd` | Field | Move destination residence reservation date |
| `svc_kei_ucwk_no` | Field | Service detail work number - internal tracking for service contracts |
| CC | Acronym | Change Checker / Cross Component - validation and business logic component |
| SC | Acronym | Service Controller - service layer controller |
| BMP | Acronym | Buro-ichi (Furo-ichi) temporary return - temporary equipment return at previous address |
| Furo-ichi | Business term | First phone number in a multi-number setup |
| Rozeo | Business term | Bundled service package offered by K-Opticom |
| eo Light Network | Business term | eo光ネット - K-Opticom fiber-optic broadband internet service |
| eo Light Telephone | Business term | eo光電話 - K-Opticom fiber-optic telephone service |
| eo Light TV | Business term | eo光テレビ - K-Opticom fiber-optic television service |
| VDSL | Acronym | Very-high-bit-rate Digital Subscriber Line |
| ONU | Acronym | Optical Network Unit |
| STB | Acronym | Set-Top Box |
| BBR | Acronym | Broadband Radio wireless broadband service |
| VA | Acronym | Value Added services |
| S/T | Acronym | Service/Termination - service cancellation processing |
| UCID | Acronym | Usecase ID |
| OPID | Acronym | Operation ID |
| FUNC_CD_1 | Constant | Function code 1 for registration |
| FUNC_CD_2 | Constant | Function code 2 for update |
| KKW0698 | Service | Pre-registration validation service |
| KKW0664 | Service | Address change temporary registration service |
| KKW0868 | Service | Number temporary return correction service |
| KKW0725 | Service | Address change correction service |
| KKW0674 | Service | Address change main registration service |
| KKW0325 | Service | Address change completion registration service |
| CKSV9001 | Service | AxM integration service |
| KKW04210 | Screen | Address Change Registration Complete screen |
| 住所変更登録 | Business term | Address Change Registration |
| 移動 | Business term | Transfer/Migration between addresses |
| 確定 | Business term | Confirm/Finalize |
| 仮登録 | Business term | Temporary Registration |
| 工事 | Business term | Construction/Installation work |
| 解約 | Business term | Termination/Cancellation |
| PDING | Acronym | Pending - service in pending state |
| NET | Acronym | Network (eo Light Network) |
| TEL | Acronym | Telephone (eo Light Telephone) |
| SVKEI_NO | Field | Service detail contract number |
| AxM | Business term | Administrative Management System |
