kanwalnainsingh/OpenDesk

Organisation Landing Page to pull data from API

Opened this issue · 4 comments

Current State

At present, when user continue as organization and land here https://www.bookopendesk.com/organisation/
Data rendered in screen for site and floors are hardcoded.

image

Requirement

Change current hardcoding of sites and floor details.
In order to achieve this UI will call api /organisation/{orgId}/sites to retrieve all details for orgId passed. https://www.bookopendesk.com/organisation/{orgId}

Response structure would be like below.

{
"orgId": "string",
"id": "string",
"name": "string",
"location": "string",
"floors": [
{
"floorId": "string",
"name": "string",
"openDesk": "string",
"reservedDesk": "string"
}
]
}

Hi @kanwalnainsingh I would like to work on this issue. Please assign it to me.

@rajudevolla you can start this one, I will assign

@kanwalnainsingh , current information being shown as mutiles sites with each site having no of Floors, total desks, opendesk and location. But the API response having multiple floors for orgID. we just need to change hard coding to binding from API right? In this i think API response should as below.

{
"orgId": "string",
"id": "string",
"name": "string",

"sites": [
{
"siteId": "string",
"name": "string",
"floor":number,
"location":"string",
"openDesk": "string",
"reservedDesk": "string"
}
]
}

Please confirm.

@rajudevolla you will call organisation service which will below response.

[
{
"orgId": "string",
"companyName": "string",
"city": "string",
"headQuarters": "string",
"sites": [
{
"orgId": "string",
"id": "string",
"name": "string",
"location": "string",
"floors": [
{
"floorId": "string",
"name": "string",
"openDesk": "string",
"reservedDesk": "string"
}
]
}
]
}
]

https://bookopendesk.com/api/organisation-service/swagger-ui/index.html?configUrl=/api/organisation-service/v3/api-docs/swagger-config#/organisation-controller/getOrganisationList