Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
itminedu
djnro
Commits
7ee6a39a
Commit
7ee6a39a
authored
Feb 08, 2013
by
Leonidas Poulopoulos
Browse files
Moved Realm countries selection in settings.py
parent
85da1c7f
Changes
2
Show whitespace changes
Inline
Side-by-side
edumanage/models.py
View file @
7ee6a39a
...
@@ -16,6 +16,7 @@ from django import forms
...
@@ -16,6 +16,7 @@ from django import forms
from
django.db
import
models
from
django.db
import
models
from
django.utils.text
import
capfirst
from
django.utils.text
import
capfirst
from
django.core
import
exceptions
from
django.core
import
exceptions
from
django.conf
import
settings
class
MultiSelectFormField
(
forms
.
MultipleChoiceField
):
class
MultiSelectFormField
(
forms
.
MultipleChoiceField
):
...
@@ -490,11 +491,7 @@ class Realm(models.Model):
...
@@ -490,11 +491,7 @@ class Realm(models.Model):
Realm
Realm
'''
'''
COUNTRIES
=
(
country
=
models
.
CharField
(
max_length
=
2
,
choices
=
settings
.
REALM_COUNTRIES
)
(
'gr'
,
'Greece'
),
)
country
=
models
.
CharField
(
max_length
=
2
,
choices
=
COUNTRIES
)
stype
=
models
.
PositiveIntegerField
(
max_length
=
1
,
default
=
0
,
editable
=
False
)
stype
=
models
.
PositiveIntegerField
(
max_length
=
1
,
default
=
0
,
editable
=
False
)
# TODO: multiple names can be specified [...] name in English is required
# TODO: multiple names can be specified [...] name in English is required
org_name
=
generic
.
GenericRelation
(
Name_i18n
)
org_name
=
generic
.
GenericRelation
(
Name_i18n
)
...
...
settings.py.dist
View file @
7ee6a39a
...
@@ -217,6 +217,11 @@ MAP_CENTER = (36.97, 23.71)
...
@@ -217,6 +217,11 @@ MAP_CENTER = (36.97, 23.71)
#Helpdesk, used in base.html:
#Helpdesk, used in base.html:
NRO_DOMAIN_HELPDESK_DICT = {"name": _("Domain Helpdesk"), 'email':'helpdesk@example.com', 'phone': '12324567890', 'uri': 'helpdesk.example.com'}
NRO_DOMAIN_HELPDESK_DICT = {"name": _("Domain Helpdesk"), 'email':'helpdesk@example.com', 'phone': '12324567890', 'uri': 'helpdesk.example.com'}
#Countries for Realm model:
REALM_COUNTRIES = (
('country_2letters', 'Country' ),
)
# Overview LDAP
# Overview LDAP
LDAP_AUTH_SETTINGS = (
LDAP_AUTH_SETTINGS = (
{'url': 'ldap://ds.example.com', 'base': 'dc=dept,dc=example,dc=com'},
{'url': 'ldap://ds.example.com', 'base': 'dc=dept,dc=example,dc=com'},
...
...
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