# Business Logic — KKW02701SF01DBean.listKoumokuIds() [25 LOC]

| Field | Value |
|-------|-------|
| Fully Qualified Name | `eo.web.webview.KKW02701SF.KKW02701SF01DBean` |
| Layer | Data Bean / UI Component (webview) |
| Module | `KKW02701SF` (Package: `eo.web.webview.KKW02701SF`) |

## 1. Role

### KKW02701SF01DBean.listKoumokuIds()

This method serves as a **metadata registry** for the Course History (コース履歴) screen. It returns a fixed, pre-defined ordered list of 21 item IDs (フィールド名 — field names) that define the columns or data fields available for display on the KKW02701SF screen. The returned list contains Japanese string labels representing business entity fields such as Service Contract Number, Differentiation Reason, Processing Division, Application Number, Service Code, Pricing Group Code, and various change-history fields (e.g., pre-change service code, pre-change pricing). The **design pattern** implemented is a **static factory** — the method is `public static` and requires no instance or parameters, allowing any calling code to retrieve the field list by a simple invocation. Its **role in the larger system** is as a shared data-bean utility: it is referenced by the parent `KKW02701SFBean.listKoumokuIds(String key)` method when the key does not match a special branch, providing the default set of column identifiers for data-type-boolean screen rendering. The method contains no conditional branches, no external calls, and no CRUD operations — it is a pure data-returning static factory.

## 2. Processing Pattern (Detailed Business Logic)

```mermaid
flowchart TD
    START(["listKoumokuIds()"])
    STEP1["Initialize: koumokuList = new ArrayList<String>()"]
    STEP2["Add 21 hardcoded item ID strings to koumokuList"]
    STEP3["Return koumokuList"]
    END(["Return ArrayList<String>"])

    START --> STEP1
    STEP1 --> STEP2
    STEP2 --> STEP3
    STEP3 --> END
```

The method executes a single linear path with no branches:

1. **Initialize** an empty `ArrayList<String>` named `koumokuList`.
2. **Populate** the list with 21 hardcoded field name strings in Japanese, each representing a data field shown on the Course History screen.
3. **Return** the populated list.

No conditional logic, no external calls, no constant resolution required — the method is a straightforward data factory.

## 3. Parameter Analysis

| No | Parameter Name | Type | Business Description |
|----|---------------|------|---------------------|
| - | (none) | - | This is a static method with no parameters. It returns a fixed list regardless of caller context. |

No instance fields or external state are read by this method.

## 4. CRUD Operations / Called Services

This method performs **no CRUD operations** and **calls no external services**. It is a pure data-returning factory method that returns hardcoded strings.

| CRUD | SC / CBS | SC Code | Entity / DB | Operation Description |
|------|----------|---------|-------------|----------------------|
| (none) | - | - | - | No data access — returns a hardcoded list of item IDs only. |

## 5. Dependency Trace

| # | Caller (Screen/Batch) | Call Chain (Full Path to this Method) | Terminal (SC / CRUD / Entity) |
|---|----------------------|--------------------------------------|-------------------------------|
| 1 | Screen:KKW02701 | `KKW02701SFBean.listKoumokuIds(key)` → `KKW02701SF01DBean.listKoumokuIds()` | N/A (no CRUD) |

The primary caller is `KKW02701SFBean.listKoumokuIds(String key)` (line 1088 in `KKW02701SFBean.java`). When the `key` parameter does not match any special branch (e.g., data-type-boolean view mode with item ID `hktgi_cust_kei_hktgi_list`), the bean delegates to `KKW02701SF01DBean.listKoumokuIds()` as the default field list provider. This screen belongs to the **Course History** (コース履歴) module, which displays historical records of service contract changes.

## 6. Per-Branch Detail Blocks

**Block 1** — [LINEAR EXECUTION] `(no condition — single path)` (L1167)

> Initialize the return list.

| # | Type | Code |
|---|------|------|
| 1 | SET | `ArrayList<String> koumokuList = new ArrayList<String>();` // Create empty list [L1168] |

**Block 2** — [LINEAR EXECUTION] `(no condition — sequential adds)` (L1169)

> Add 21 hardcoded field name strings. Each `add` call appends an item ID to the list.

| # | Type | Code |
|---|------|------|
| 1 | ADD | `koumokuList.add("SSPID")` // System Screen Parameter ID [L1169] |
| 2 | ADD | `koumokuList.add("サービス契約番号")` // Service Contract Number [L1170] |
| 3 | ADD | `koumokuList.add("異動区分")` // Differentiation Type [L1171] |
| 4 | ADD | `koumokuList.add("異動理由コード")` // Differentiation Reason Code [L1172] |
| 5 | ADD | `koumokuList.add("異動理由メモ")` // Differentiation Reason Memo [L1173] |
| 6 | ADD | `koumokuList.add("オプションサービス契約番号")` // Option Service Contract Number [L1174] |
| 7 | ADD | `koumokuList.add("処理区分")` // Processing Type [L1175] |
| 8 | ADD | `koumokuList.add("申請番号")` // Application Number [L1176] |
| 9 | ADD | `koumokuList.add("申請明細番号")` // Application Detail Number [L1177] |
| 10 | ADD | `koumokuList.add("特定IT項目名")` // Specific IT Item Name [L1178] |
| 11 | ADD | `koumokuList.add("特定IT項目値")` // Specific IT Item Value [L1179] |
| 12 | ADD | `koumokuList.add("ポップアップモード")` // Popup Mode [L1180] |
| 13 | ADD | `koumokuList.add("サービスコード")` // Service Code [-> SVC_CD="サービスコード"] |
| 14 | ADD | `koumokuList.add("料金グループコード")` // Pricing Group Code [-> PRC_GRP_CD="料金グループコード"] |
| 15 | ADD | `koumokuList.add("料金コースコード")` // Pricing Course Code [L1183] |
| 16 | ADD | `koumokuList.add("料金プランコード")` // Pricing Plan Code [L1184] |
| 17 | ADD | `koumokuList.add("変更前サービスコード")` // Pre-change Service Code [L1185] |
| 18 | ADD | `koumokuList.add("変更前料金グループコード")` // Pre-change Pricing Group Code [L1186] |
| 19 | ADD | `koumokuList.add("変更前料金コースコード")` // Pre-change Pricing Course Code [L1187] |
| 20 | ADD | `koumokuList.add("変更前料金プランコード")` // Pre-change Pricing Plan Code [L1188] |
| 21 | ADD | `koumokuList.add("割引自動適用対象外フラグ")` // Discount Auto-Application Exclusion Flag [-> WRIB_AUTO_APLY_TG_GAI_FLG="割引自動適用対象外フラグ"] [L1189] |

**Block 3** — [RETURN] `(end of method)` (L1190)

> Return the populated list to the caller.

| # | Type | Code |
|---|------|------|
| 1 | RETURN | `return koumokuList;` // Return the 21-item ArrayList [L1190] |

## 7. Glossary

| Term | Type | Business Meaning |
|------|------|------------------|
| `SSPID` | Field | System Screen Parameter ID — internal system identifier used as a primary key for screen data parameters |
| `サービス契約番号` (Service Contract Number) | Field | The unique contract number assigned to a customer's service agreement |
| `異動区分` (Differentiation Type) | Field | Classification code indicating the type of change made to a service contract (e.g., addition, modification, cancellation) |
| `異動理由コード` (Differentiation Reason Code) | Field | The specific reason code for the contract change |
| `異動理由メモ` (Differentiation Reason Memo) | Field | Free-text memo explaining the reason for the contract change |
| `オプションサービス契約番号` (Option Service Contract Number) | Field | Contract number for an optional/add-on service attached to the main contract |
| `処理区分` (Processing Type) | Field | Classification of the processing stage or type (e.g., new registration, modification, cancellation) |
| `申請番号` (Application Number) | Field | The application/request number identifying a service change request |
| `申請明細番号` (Application Detail Number) | Field | The detail/line-item number within a multi-item application |
| `特定IT項目名` (Specific IT Item Name) | Field | A specific IT field name used in internal systems for tracking additional data |
| `特定IT項目値` (Specific IT Item Value) | Field | The value associated with the Specific IT Item Name |
| `ポップアップモード` (Popup Mode) | Field | Flag indicating whether the screen is displayed in popup mode |
| `サービスコード` (Service Code) | Field | The service type code identifying the specific service (e.g., FTTH, Mail). [Constant: `KKW02701SFConst.SVC_CD`] |
| `料金グループコード` (Pricing Group Code) | Field | The pricing group classification code. [Constant: `KKW02701SFConst.PRC_GRP_CD`] |
| `料金コースコード` (Pricing Course Code) | Field | The pricing course code identifying a specific pricing tier |
| `料金プランコード` (Pricing Plan Code) | Field | The pricing plan code identifying a specific pricing plan |
| `変更前サービスコード` (Pre-change Service Code) | Field | The service code before a modification was applied (historical value) |
| `変更前料金グループコード` (Pre-change Pricing Group Code) | Field | The pricing group code before a modification (historical value) |
| `変更前料金コースコード` (Pre-change Pricing Course Code) | Field | The pricing course code before a modification (historical value) |
| `変更前料金プランコード` (Pre-change Pricing Plan Code) | Field | The pricing plan code before a modification (historical value) |
| `割引自動適用対象外フラグ` (Discount Auto-Application Exclusion Flag) | Field | Flag indicating whether a discount is excluded from automatic application. [Constant: `KKW02701SFConst.WRIB_AUTO_APLY_TG_GAI_FLG`] |
| `KKW02701SF` | Module | Course History (コース履歴) screen module — displays historical records of service contract changes |
| `DBean` | Type | Data Bean — a static data holder class that provides metadata or fixed data for UI rendering |
| `コース履歴` (Course History) | Business term | The screen/module that displays historical records of service contract modifications and changes |
