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

New database model #239

Open
wants to merge 15 commits into
base: master
Choose a base branch
from
Open

New database model #239

wants to merge 15 commits into from

Conversation

Aziguy
Copy link
Collaborator

@Aziguy Aziguy commented Mar 3, 2022

closes #228

Copy link
Member

@bryan-brancotte bryan-brancotte left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is work in progress PR from what I observed, but in the right direction

.env-sample Outdated
@@ -0,0 +1,2 @@
login=
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

please add the new credentials in the already existing config file settings.ini and add constant in settings.py which will make the credentials available in the app

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done!

('collection', models.ManyToManyField(blank=True, to='ifbcat_api.Collection')),
('operating_system', models.ManyToManyField(blank=True, to='ifbcat_api.OperatingSystem')),
('scientific_topics', models.ManyToManyField(blank=True, to='ifbcat_api.Topic')),
('tool_credit', models.ManyToManyField(blank=True, to='ifbcat_api.ToolCredit')),
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

credit would be enough ?

('operating_system', models.ManyToManyField(blank=True, to='ifbcat_api.OperatingSystem')),
('scientific_topics', models.ManyToManyField(blank=True, to='ifbcat_api.Topic')),
('tool_credit', models.ManyToManyField(blank=True, to='ifbcat_api.ToolCredit')),
('tool_licence', models.ForeignKey(blank=True, help_text='Licence of the tool.', null=True, on_delete=django.db.models.deletion.SET_NULL, to='ifbcat_api.licence')),
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

licence would be enough, and more accurate

('scientific_topics', models.ManyToManyField(blank=True, to='ifbcat_api.Topic')),
('tool_credit', models.ManyToManyField(blank=True, to='ifbcat_api.ToolCredit')),
('tool_licence', models.ForeignKey(blank=True, help_text='Licence of the tool.', null=True, on_delete=django.db.models.deletion.SET_NULL, to='ifbcat_api.licence')),
('tool_type', models.ManyToManyField(blank=True, to='ifbcat_api.ToolType')),
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

more cleanup on the model is needed

@@ -53,6 +54,8 @@
# path('testapiview/', views.TestApiView.as_view()),
path('tool/<int:pk>/', views.ToolViewSet.as_view({'get': 'retrieve'})),
path('tool/<biotoolsID>/', views.ToolViewSet.as_view({'get': 'retrieve'})),
path('database/<int:pk>/', views.DatabaseViewSet.as_view({'get': 'retrieve'})),
path('tool/<fairsharingID>/', views.DatabaseViewSet.as_view({'get': 'retrieve'})),
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

typo

@@ -0,0 +1,205 @@
import json
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

File is not in the right place, should not be in tool/ directory

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

File is not in the right place, should not be in tool/ directory

Moved to /model/

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

Successfully merging this pull request may close these issues.

New Database model
2 participants