Skip to content

[CABINET FLOW][API] Return the department name list in API #112

Description

@ChanukaUOJ

Problem

Currently this is how the cabinet flow API returns the response for the sankey chart. value represent the number of department moved. This issue is created to send the department details list for each link. {department name and department id}

{
  "nodes": [
    {
      "id": "2398-39_min_1",
      "time": "2024-09-23",
      "name": "Non Cabinet Minister of Development Projects"
    },
    {
      "id": "2289-43_min_29",
      "time": "2024-09-23",
      "name": "Minister of Trade, Commerce and Food Security"
    },
    {
      "id": "2289-43_min_19",
      "time": "2024-09-23",
      "name": "Minister of Industries"
    },
    ...
  ],
  "links": [
    {
      "source": 4,
      "target": 32,
      "value": 1
    },
    {
      "source": 30,
      "target": 32,
      "value": 9
    },
    {
      "source": 9,
      "target": 32,
      "value": 6
    },
    {
      "source": 15,
      "target": 33,
      "value": 25
    },
   ...
  ],
  "dates": [
    {
      "date": "2024-09-23",
      "status": "ok",
      "departmentsCount": 449
    },
    {
      "date": "2026-06-22",
      "status": "ok",
      "departmentsCount": 469
    }
  ]
}

Solution

Add department name and department id object for each link item and send as the API response.

This issue is linked with LDFLK/openginxplore#168

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions