Project

General

Profile

Revision 858d88aa

ID858d88aa7d63cc68c696f561f6b9683de60bd152
Parent 9494bbb3
Child b3c692c6

Added by Francois POIROTTE about 14 years ago

Ajout d'un préfix dans les settings de développement.
Nettoyage du app_cfg.py (les réglages correspondant sont désormais présents dans vigilo.turbogears).
Légère correction du Makefile (problème de l'inclusion).

git-svn-id: https://vigilo-dev.si.c-s.fr/svn@1990 b22e2e97-25c9-44ff-b637-2e5ceca36478

View differences:

Makefile
1 1
NAME := vigiboard
2
MODULE := $(NAME)
3
CODEPATH := $(NAME)
4

  
5 2
all: build
6 3

  
7 4
include ../glue/Makefile.common
5

  
6
MODULE := $(NAME)
7
CODEPATH := $(NAME)
8

  
8 9
lint: lint_pylint
9 10
tests: tests_tg
10 11
clean: clean_python
development.ini
22 22
[app:main]
23 23
use = egg:vigiboard
24 24

  
25
db_basename=
25
db_basename=vigilo_
26 26
;password_hashing_function=md5
27 27
lang=fr
28 28
use_kerberos=False
vigiboard/config/app_cfg.py
14 14
 
15 15
"""
16 16

  
17
from vigilo import models
18

  
19 17
from vigilo.turbogears import VigiloAppConfig
20 18
from pylons.i18n import lazy_ugettext as l_
21 19

  
......
33 31

  
34 32
#Configure the base SQLALchemy Setup
35 33
base_config.use_sqlalchemy = True
36
base_config.model = models
37 34

  
38 35
# Configure the authentication backend
39 36
base_config.auth_backend = 'sqlalchemy'
40 37

  
41
# what is the class you want to use to search for users in the database
42
base_config.sa_auth.user_class = models.User
43
# what is the class you want to use to search for groups in the database
44
base_config.sa_auth.group_class = models.UserGroup
45
# what is the class you want to use to search for permissions in the database
46
base_config.sa_auth.permission_class = models.Permission
47
# The name "groups" is already used for groups of hosts.
48
# We use "usergroups" when referering to users to avoid confusion.
49
base_config.sa_auth.translations.groups = 'usergroups'
50

  
51 38
# override this if you would like to provide a different who plugin for
52 39
# managing login and logout of your application
53 40
base_config.sa_auth.form_plugin = None
vigiboard/controllers/root.py
455 455
            raise redirect(request.environ.get('HTTP_REFERER', url('/')))
456 456
        
457 457
        # Vérification que au moins un des identifiants existe et est éditable
458
        if events.num_rows() <= 0 :
458
        if events.num_rows() <= 0:
459 459
            flash(_('No access to this event'), 'error')
460 460
            redirect('/')
461 461
        

Also available in: Unified diff