[ 
https://issues.apache.org/jira/browse/FINERACT-2904?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Adam Saghy updated FINERACT-2904:
---------------------------------
    Fix Version/s: 1.16.0

> Entity Data Table Checks: Center/Office CREATE checks not enforced and 
> templates return incorrect data tables
> -------------------------------------------------------------------------------------------------------------
>
>                 Key: FINERACT-2904
>                 URL: https://issues.apache.org/jira/browse/FINERACT-2904
>             Project: Apache Fineract
>          Issue Type: Bug
>          Components: Client, Data Tables
>            Reporter: Foo Developer
>            Assignee: Foo Developer
>            Priority: Major
>             Fix For: 1.16.0
>
>
> # Entity Data Table Checks: Center/Office CREATE checks not enforced and 
> templates return incorrect data tables
> ## Description
> Two issues were identified with **Entity Data Table Checks** for Center and 
> Office:
> 1. **Center CREATE** — the configured check is not enforced, and 
> `/centers/template` returns the **Group** data table instead of the Center 
> data table.
> 2. **Office CREATE** — the configured check is not enforced, and 
> `/offices/template` returns no data tables.
> The same Entity Data Table Check mechanism works correctly for **Group, Loan 
> Product, Loan CREATE/APPROVE, and Savings**, where the API rejects the 
> request with `403` until the required data table entry is provided.
> ## Environment
> * **Environment:** CBS DEV
> * **Portal build:** `c-496230`
> * **Test date:** 05/10/2026
> * **User:** Admin
> * **API base:** `/api/fineract-provider/api/v1`
> ## Preconditions
> The following mandatory data tables and Entity Data Table Checks were 
> configured:
> | Entity       | Check            | Data Table          |
> | ------------ | ---------------- | ------------------- |
> | Center       | CREATE           | `QA_DT_Center`      |
> | Office       | CREATE           | `QA_DT_Office`      |
> | Group        | CREATE           | `QA_DT_Group`       |
> | Loan Product | CREATE           | `QA_DT_LoanProduct` |
> | Loan         | CREATE / APPROVE | `QA_DT_Loan`        |
> | Savings      | CREATE           | `QA_DT_Savings`     |
> Each data table contains a mandatory String column `qa_note`.
> ## Bug 1 — Center CREATE check is not enforced and template returns the wrong 
> data table
> With the Center CREATE check active, calling `POST /centers` without 
> providing a datatables entry succeeds.
> **Expected:**
> * CREATE should return `403` until `QA_DT_Center` is provided.
> * `GET /centers/template` should return `QA_DT_Center`.
> **Actual:**
> * Center is created successfully without the required data table entry.
> * `GET /centers/template` returns `QA_DT_Group` instead of `QA_DT_Center`.
> ## Bug 2 — Office CREATE check is not enforced and template returns no data 
> tables
> With the Office CREATE check active, calling `POST /offices` without 
> providing a datatables entry succeeds.
> **Expected:**
> * CREATE should return `403` until `QA_DT_Office` is provided.
> * `GET /offices/template` should return `QA_DT_Office`.
> **Actual:**
> * Office is created successfully without the required data table entry.
> * `GET /offices/template` returns an empty `datatables` array.
> ## Expected behavior
> Center and Office should behave consistently with the already working 
> entities:
> * The configured Entity Data Table Check must be enforced at the 
> **API/service level**, not only by the portal UI.
> * The corresponding entity template must return the data tables configured 
> for that entity.
> * A CREATE request without a required data table entry should be rejected 
> with `403`.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to