Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rack from location children not available in floor plan tile #44

Open
albinpopote opened this issue Aug 31, 2023 · 1 comment
Open

Rack from location children not available in floor plan tile #44

albinpopote opened this issue Aug 31, 2023 · 1 comment

Comments

@albinpopote
Copy link

Environment

  • Python version: 3.10.12
  • Nautobot version: 1.6.1
  • nautobot-floor-plan version: 1.0.0

Context

I have the following location tree implemented in nautobot:
Room-1 (Location Type: Room)
--> Row A (Location Type: Row - Children of Room Type)
--> Row B (Location Type: Row - Children of Room Type)
--> Row C (Location Type: Row - Children of Room Type)
--> Row D (Location Type: Row - Children of Room Type)

With some racks affected to the different rows:
- A0 --> Row A
- A1 --> Row A
- B6 --> Row B
- ...

Expected Behavior

When I want to create the Floor plan for my Room-1, I want to affect the rack A0 to the first line and first column
From the floor plan tile, I would like to be able to select all racks assigned to my room or whose room is parent to the location of my racks

Observed Behavior

Nothing is selectable under the floor plan tile
When I change a rack from Row A location to the parent Room-1, the rack is selectable

Steps to Reproduce

  1. Create 2 types of Locations (Room and Row: Room is the parent of Row)
  2. Create a Location Room and one or many Location Row(s) in the room
  3. Create one or more rack unit affected to a Location Row
  4. Create a Floor Plan affected to the Room
  5. Try to select a rack in the Tile
@joewesch
Copy link
Contributor

joewesch commented Jul 3, 2024

I believe this is currently "working as intended". A Floor Plan Tile currently has a OneToOne relationship to a Rack, and a Rack currently has a ForeignKey relationship to Location (a single Location can have many Racks, but a Rack can only have a single Location). If I'm understanding your scenario correctly you want a Rack to be associated to both a Row Location (e.g. Row A) and a Room Location (e.g. Room-1) - which would not be allowed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants