Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
N
neptunesy_reading
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Star Neptune R. Sy
neptunesy_reading
Commits
404a8ebd
Commit
404a8ebd
authored
Mar 28, 2023
by
Star Neptune R. Sy
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
models are done and migrated
parent
cdbb82dc
Pipeline
#3037
failed with stages
Changes
4
Pipelines
1
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
29 additions
and
1 deletion
+29
-1
models.py
neptunesy_reading/bookshelf/models.py
+19
-1
urls.py
neptunesy_reading/bookshelf/urls.py
+10
-0
db.sqlite3
neptunesy_reading/db.sqlite3
+0
-0
urls.cpython-39.pyc
...reading/neptunesy_reading/__pycache__/urls.cpython-39.pyc
+0
-0
No files found.
neptunesy_reading/bookshelf/models.py
View file @
404a8ebd
from
django.db
import
models
import
datetime
# Create your models here.
class
Author
(
models
.
Model
):
first_name
=
models
.
CharField
(
max_length
=
50
,
blank
=
True
)
last_name
=
models
.
CharField
(
max_length
=
50
,
blank
=
True
)
age
=
models
.
IntegerField
(
blank
=
True
)
nationality
=
models
.
CharField
(
max_length
=
50
)
bio
=
models
.
TextField
(
blank
=
True
,)
class
Book
(
models
.
Model
):
title
=
models
.
CharField
(
max_length
=
50
,
blank
=
True
)
author
=
models
.
ForeignKey
(
Author
,
on_delete
=
models
.
CASCADE
,
)
publisher
=
models
.
CharField
(
max_length
=
50
,
blank
=
True
)
year_published
=
models
.
DateField
(
datetime
.
datetime
.
today
())
ISBN
=
models
.
CharField
(
max_length
=
50
,
unique
=
True
,
blank
=
False
,
default
=
"0000000000000"
)
blurb
=
models
.
TextField
(
blank
=
True
,)
\ No newline at end of file
neptunesy_reading/bookshelf/urls.py
0 → 100644
View file @
404a8ebd
# bookshelf/urls.py
from
django.urls
import
path
from
.views
import
index
urlpatterns
=
[
path
(
''
,
index
,
name
=
'index'
),
]
# This might be needed, depending on your Django version
app_name
=
"bookshelf"
\ No newline at end of file
neptunesy_reading/db.sqlite3
0 → 100644
View file @
404a8ebd
File added
neptunesy_reading/neptunesy_reading/__pycache__/urls.cpython-39.pyc
0 → 100644
View file @
404a8ebd
File added
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment