Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
Gelencsér Szabolcs
/
cloud
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
97a5a111
authored
Sep 18, 2013
by
Dudás Ádám
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
storage: use sizefield for disk size
fixes !5
parent
e5e57a40
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
6 additions
and
3 deletions
+6
-3
circle/circle/settings/base.py
+1
-0
circle/storage/models.py
+3
-3
requirements/base.txt
+2
-0
No files found.
circle/circle/settings/base.py
View file @
97a5a111
...
...
@@ -223,6 +223,7 @@ THIRD_PARTY_APPS = (
'django_tables2'
,
'crispy_forms'
,
'djcelery'
,
'sizefield'
,
)
# Apps specific for this project go here.
...
...
circle/storage/models.py
View file @
97a5a111
...
...
@@ -4,12 +4,12 @@ import logging
import
uuid
from
django.db
import
models
from
django.utils.translation
import
ugettext_lazy
as
_
from
django.db.models.signals
import
post_delete
from
django.utils.translation
import
ugettext_lazy
as
_
from
model_utils.models
import
TimeStampedModel
from
sizefield.models
import
FileSizeField
from
manager
import
storage_manager
import
tasks
logger
=
logging
.
getLogger
(
__name__
)
...
...
@@ -46,7 +46,7 @@ class Disk(TimeStampedModel):
filename
=
models
.
CharField
(
max_length
=
256
,
verbose_name
=
_
(
'filename'
))
datastore
=
models
.
ForeignKey
(
DataStore
)
type
=
models
.
CharField
(
max_length
=
10
,
choices
=
TYPES
)
size
=
models
.
Integer
Field
()
size
=
FileSize
Field
()
base
=
models
.
ForeignKey
(
'self'
,
blank
=
True
,
null
=
True
,
related_name
=
'derivatives'
)
ready
=
models
.
BooleanField
(
default
=
False
)
...
...
requirements/base.txt
View file @
97a5a111
...
...
@@ -5,7 +5,9 @@ django-braces==1.2.2
django-celery==3.0.23
django-crispy-forms==1.4.0
django-model-utils==1.4.0
django-sizefield==0.4
django-tables2==0.14.0
django-taggit==0.10a1
logutils==0.3.3
netaddr==0.7.10
South==0.8.1
...
...
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