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

Can't add buildings to a node added through the admin panel #281

Closed
WillNilges opened this issue Mar 27, 2024 · 7 comments · Fixed by #344
Closed

Can't add buildings to a node added through the admin panel #281

WillNilges opened this issue Mar 27, 2024 · 7 comments · Fixed by #344
Assignees
Labels
Admin Panel Issues pertaining to the Admin Panel, its workflow, and its UI bug Something isn't working

Comments

@WillNilges
Copy link
Collaborator

There's simply no option. I believe it's possible to add a node to a building, but a building cannot be added to a node.

image

On the building page...
This should be a search field
image

@WillNilges WillNilges self-assigned this Mar 27, 2024
@WillNilges WillNilges added bug Something isn't working Admin Panel Issues pertaining to the Admin Panel, its workflow, and its UI labels Mar 27, 2024
@WillNilges
Copy link
Collaborator Author

Fixed the search fields. Now need to do the same with the installs and buildings. I think I can just hack the inline template I hacked already to do this.

Did you know that this URL works? It'll populate the fields.

http://127.0.0.1:8000/admin/meshapi/building/add/?primary_node=7985

@WillNilges
Copy link
Collaborator Author

Might have a solution to this. Stay tuned.

@WillNilges WillNilges linked a pull request Apr 19, 2024 that will close this issue
@WillNilges
Copy link
Collaborator Author

So, I hacked in a button to create a new object, but I don't think there's an easy way to add existing objects. I'd need to write a custom widget for that.

https://forum.djangoproject.com/t/manytoone-dropdown-inline/25931/4

@WillNilges
Copy link
Collaborator Author

I might need to table this for a bit and think about it. I think the workaround is to create a building first, then create a node, then go back to the building and add the node.

@WillNilges
Copy link
Collaborator Author

@WillNilges
Copy link
Collaborator Author

OK now I have a fix for it. Trying to make it look pretty.

@WillNilges
Copy link
Collaborator Author

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Admin Panel Issues pertaining to the Admin Panel, its workflow, and its UI bug Something isn't working
Projects
Development

Successfully merging a pull request may close this issue.

2 participants