Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
D
Djangoldp Invoice
Project overview
Project overview
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
1
Issues
1
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Container Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Startin blox
djangoldp-packages
Djangoldp Invoice
Commits
86794592
Commit
86794592
authored
Nov 12, 2018
by
Claire Zuliani
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Rename Invoice to ClientInvoice
parent
a99f737b
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
28 additions
and
6 deletions
+28
-6
.gitignore
.gitignore
+3
-0
admin.py
admin.py
+2
-2
migrations/0002_auto_20181112_1912.py
migrations/0002_auto_20181112_1912.py
+19
-0
models.py
models.py
+1
-1
urls.py
urls.py
+3
-3
No files found.
.gitignore
0 → 100644
View file @
86794592
__pycache__/*
/db.sqlite3
*.pyc
\ No newline at end of file
admin.py
View file @
86794592
from
django.contrib
import
admin
from
guardian.admin
import
GuardedModelAdmin
from
.models
import
Invoice
from
.models
import
Client
Invoice
admin
.
site
.
register
(
Invoice
)
admin
.
site
.
register
(
Client
Invoice
)
migrations/0002_auto_20181112_1912.py
0 → 100644
View file @
86794592
# -*- coding: utf-8 -*-
# Generated by Django 1.11.16 on 2018-11-12 19:12
from
__future__
import
unicode_literals
from
django.db
import
migrations
class
Migration
(
migrations
.
Migration
):
dependencies
=
[
(
'djangoldp_invoices'
,
'0001_initial'
),
]
operations
=
[
migrations
.
RenameModel
(
old_name
=
'Invoice'
,
new_name
=
'ClientInvoice'
,
),
]
models.py
View file @
86794592
...
...
@@ -2,7 +2,7 @@ from django.conf import settings
from
django.db
import
models
import
datetime
class
Invoice
(
models
.
Model
):
class
Client
Invoice
(
models
.
Model
):
# customer = models.ForeignKey(User, on_delete=models.CASCADE)
# provider = models.ForeignKey(User, on_delete=models.CASCADE)
STATES
=
(
...
...
urls.py
View file @
86794592
from
django.conf.urls
import
url
,
include
from
django.conf
import
settings
from
djangoldp.views
import
LDPViewSet
from
.models
import
Invoice
from
.models
import
Client
Invoice
urlpatterns
=
[
url
(
r'^
'
,
LDPViewSet
.
urls
(
model
=
Invoice
)),
]
url
(
r'^
client-invoices'
,
LDPViewSet
.
urls
(
model
=
Client
Invoice
)),
]
\ No newline at end of file
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