refact ergo + page perso (vide)
[auf_rh_dae.git] / project / settings.py
CommitLineData
5e23d90d
OL
1# -*- encoding: utf-8 -*-
2
3import os
4import socket
5from conf import *
6
8ea41642 7
a16928b9 8PROJET_TITRE = "Ressources humaines"
3a2f12b2 9
5e23d90d
OL
10# Rapports d'erreurs
11EMAIL_SUBJECT_PREFIX = '[auf_rh_dae - %s] ' % socket.gethostname()
12ADMINS = (
13 ('Équipe ARI-SI', 'developpeurs@ca.auf.org'),
14)
15
16MANAGERS = ADMINS
17
18TIME_ZONE = 'Canada/Montreal'
fee4961a 19DATE_FORMAT = 'd F Y'
5e23d90d
OL
20LANGUAGE_CODE = 'fr-ca'
21
22# Absolute path to the directory that holds media.
23# Example: "/home/media/media.lawrence.com/"
24MEDIA_ROOT = os.path.join(os.path.dirname(__file__), 'media')
36341125 25PRIVE_MEDIA_ROOT = os.path.join(os.path.dirname(__file__), 'media_prive')
5e23d90d
OL
26
27# URL that handles the media served from MEDIA_ROOT. Make sure to use a
28# trailing slash if there is a path component (optional in other cases).
29# Examples: "http://media.lawrence.com", "http://example.com/media/"
30MEDIA_URL = '/media/'
d3cb467a 31PRIVE_MEDIA_URL = '/dae/prive/'
36341125 32
5e23d90d
OL
33
34# URL prefix for admin media -- CSS, JavaScript and images. Make sure to use a
35# trailing slash.
36# Examples: "http://foo.com/media/", "/media/".
21f749ab 37ADMIN_MEDIA_PREFIX = '/media/django/'
5e23d90d
OL
38
39# Don't share this with anybody.
40SECRET_KEY = '^2w#%abp_d+e#(7f5w$leef50)c@4y38cnn#ccji@84$2^rt#l'
41
42MIDDLEWARE_CLASSES = (
43 'django.middleware.common.CommonMiddleware',
44 'django.contrib.sessions.middleware.SessionMiddleware',
9cb4de55 45 'django.contrib.messages.middleware.MessageMiddleware',
5e23d90d
OL
46 'django.contrib.auth.middleware.AuthenticationMiddleware',
47 'django.middleware.doc.XViewMiddleware',
17353922 48 'reversion.middleware.RevisionMiddleware',
5e23d90d
OL
49)
50
51ROOT_URLCONF = 'project.urls'
52
5e23d90d
OL
53INSTALLED_APPS = (
54 'auf.django.skin',
55 'admin_tools',
56 'admin_tools.theming',
57 'admin_tools.menu',
58 'admin_tools.dashboard',
59 'django.contrib.auth',
60 'django.contrib.contenttypes',
9cb4de55 61 'django.contrib.messages',
5e23d90d
OL
62 'django.contrib.sessions',
63 'django.contrib.admin',
98bca02b 64 'auf.django.emploi',
fc18c1ca 65 'auf.django.admingroup',
3121c13c 66 'ajax_select',
5e23d90d 67 'south',
17353922 68 'reversion',
d00562e5 69 'project.rh',
e6f52402 70 'auf.django.workflow',
785c03cc 71 'project.rh_v1',
17353922 72 'project.dae',
55f635a6 73 #'project.budget',
7ffc5aa4 74 'alphafilter',
8ea41642 75 'project.recrutement',
76 'form_utils',
ec517164 77 'tinymce',
86caaf03 78 'captcha',
8ea41642 79# 'private_files',
5e23d90d
OL
80)
81
82TEMPLATE_CONTEXT_PROCESSORS = (
83 'django.core.context_processors.auth',
84 'django.core.context_processors.debug',
85 'django.core.context_processors.i18n',
86 'django.core.context_processors.media',
87 'django.contrib.messages.context_processors.messages',
88 'django.core.context_processors.request',
89 'auf.django.skin.context_processors.auf',
e993f3dc 90 'project.context_processors.utilisateur',
0f844142 91 'project.context_processors.this_employe',
e993f3dc 92 'project.context_processors.user_is_admin',
719b51ec 93 'dae.context_processors.user_in_dae_groupes',
94 'recrutement.context_processors.user_in_recrutement_groupes',
5e23d90d
OL
95)
96
8846b99e
OL
97AUTHENTICATION_BACKENDS = (
98 'auf.django.auth.backends.CascadeBackend',
99)
f8daa167 100LOGIN_URL = "/connexion"
5afb3da6 101LOGIN_REDIRECT_URL = "/"
5e23d90d
OL
102
103TEMPLATE_LOADERS = (
104 'django.template.loaders.filesystem.load_template_source',
105 'django.template.loaders.app_directories.load_template_source',
106)
107
108TEMPLATE_DIRS = (
109 os.path.join(os.path.dirname(__file__), "templates"),
110)
111
112
8846b99e 113ADMIN_TOOLS_INDEX_DASHBOARD = 'project.dashboard.CustomIndexDashboard'
3121c13c
OL
114
115AJAX_LOOKUP_CHANNELS = {
116 'responsables' : ('dae.catalogues', 'Responsable'),
03b395db 117 'dossiers' : ('dae.catalogues', 'Dossier'),
068d1462 118 'postes' : ('dae.catalogues', 'Poste'),
3121c13c 119}
8ea41642 120
ec517164 121TINYMCE_DEFAULT_CONFIG = {
122'theme': "advanced",
123'plugins':"paste",
124'theme_advanced_buttons1' : "bold,italic,underline,|,formatselect,|,bullist,numlist,|,undo,redo,|,link,unlink",
125'theme_advanced_buttons2' : "",
126'theme_advanced_buttons3' : "",
127'theme_advanced_statusbar_location' : "bottom",
128'theme_advanced_toolbar_align' : "left",
129'theme_advanced_styles' : "Titre=titre;Sous-titre=sous-titre;Normal=normal",
130'width' : "800",
131'height' : "200",
132'theme_advanced_resizing' : "true",
133'custom_undo_redo_levels': 10,
134'theme_advanced_toolbar_location' : 'top',
135'inline_styles' : 'false',
136'paste_use_dialog' : 'false',
137'paste_auto_cleanup_on_paste' : 'true',
138'paste_convert_headers_to_strong' : 'false',
139'paste_strip_class_attributes' : 'all',
140'paste_remove_spans' : 'true',
141'paste_remove_styles' : 'true',
142'content_css' : '/media/css/tinymce.css',
143}
144
89e948de 145EMAIL_HOST = 'localhost'
146EMAIL_PORT = '1025'
147
8ea41642 148#FILE_PROTECTION_METHOD = 'basic'