author | Lennard de Rijk <ljvderijk@gmail.com> |
Tue, 14 Jul 2009 16:46:42 +0200 | |
changeset 2643 | 222be0eb4aab |
parent 1307 | 091a21cf3627 |
permissions | -rw-r--r-- |
791
30da180c4bca
Added the club_app view, logic and model
Sverre Rabbelier <srabbelier@gmail.com>
parents:
diff
changeset
|
1 |
#!/usr/bin/python2.5 |
30da180c4bca
Added the club_app view, logic and model
Sverre Rabbelier <srabbelier@gmail.com>
parents:
diff
changeset
|
2 |
# |
1307
091a21cf3627
Update the copyright notice for 2009.
Sverre Rabbelier <srabbelier@gmail.com>
parents:
1147
diff
changeset
|
3 |
# Copyright 2009 the Melange authors. |
791
30da180c4bca
Added the club_app view, logic and model
Sverre Rabbelier <srabbelier@gmail.com>
parents:
diff
changeset
|
4 |
# |
30da180c4bca
Added the club_app view, logic and model
Sverre Rabbelier <srabbelier@gmail.com>
parents:
diff
changeset
|
5 |
# Licensed under the Apache License, Version 2.0 (the "License"); |
30da180c4bca
Added the club_app view, logic and model
Sverre Rabbelier <srabbelier@gmail.com>
parents:
diff
changeset
|
6 |
# you may not use this file except in compliance with the License. |
30da180c4bca
Added the club_app view, logic and model
Sverre Rabbelier <srabbelier@gmail.com>
parents:
diff
changeset
|
7 |
# You may obtain a copy of the License at |
30da180c4bca
Added the club_app view, logic and model
Sverre Rabbelier <srabbelier@gmail.com>
parents:
diff
changeset
|
8 |
# |
30da180c4bca
Added the club_app view, logic and model
Sverre Rabbelier <srabbelier@gmail.com>
parents:
diff
changeset
|
9 |
# http://www.apache.org/licenses/LICENSE-2.0 |
30da180c4bca
Added the club_app view, logic and model
Sverre Rabbelier <srabbelier@gmail.com>
parents:
diff
changeset
|
10 |
# |
30da180c4bca
Added the club_app view, logic and model
Sverre Rabbelier <srabbelier@gmail.com>
parents:
diff
changeset
|
11 |
# Unless required by applicable law or agreed to in writing, software |
30da180c4bca
Added the club_app view, logic and model
Sverre Rabbelier <srabbelier@gmail.com>
parents:
diff
changeset
|
12 |
# distributed under the License is distributed on an "AS IS" BASIS, |
30da180c4bca
Added the club_app view, logic and model
Sverre Rabbelier <srabbelier@gmail.com>
parents:
diff
changeset
|
13 |
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
30da180c4bca
Added the club_app view, logic and model
Sverre Rabbelier <srabbelier@gmail.com>
parents:
diff
changeset
|
14 |
# See the License for the specific language governing permissions and |
30da180c4bca
Added the club_app view, logic and model
Sverre Rabbelier <srabbelier@gmail.com>
parents:
diff
changeset
|
15 |
# limitations under the License. |
30da180c4bca
Added the club_app view, logic and model
Sverre Rabbelier <srabbelier@gmail.com>
parents:
diff
changeset
|
16 |
|
30da180c4bca
Added the club_app view, logic and model
Sverre Rabbelier <srabbelier@gmail.com>
parents:
diff
changeset
|
17 |
"""Group Application (Model) query functions. |
30da180c4bca
Added the club_app view, logic and model
Sverre Rabbelier <srabbelier@gmail.com>
parents:
diff
changeset
|
18 |
""" |
30da180c4bca
Added the club_app view, logic and model
Sverre Rabbelier <srabbelier@gmail.com>
parents:
diff
changeset
|
19 |
|
30da180c4bca
Added the club_app view, logic and model
Sverre Rabbelier <srabbelier@gmail.com>
parents:
diff
changeset
|
20 |
__authors__ = [ |
30da180c4bca
Added the club_app view, logic and model
Sverre Rabbelier <srabbelier@gmail.com>
parents:
diff
changeset
|
21 |
'"Sverre Rabbelier" <sverre@rabbelier.nl>', |
30da180c4bca
Added the club_app view, logic and model
Sverre Rabbelier <srabbelier@gmail.com>
parents:
diff
changeset
|
22 |
] |
30da180c4bca
Added the club_app view, logic and model
Sverre Rabbelier <srabbelier@gmail.com>
parents:
diff
changeset
|
23 |
|
30da180c4bca
Added the club_app view, logic and model
Sverre Rabbelier <srabbelier@gmail.com>
parents:
diff
changeset
|
24 |
|
30da180c4bca
Added the club_app view, logic and model
Sverre Rabbelier <srabbelier@gmail.com>
parents:
diff
changeset
|
25 |
from soc.logic.models import base |
30da180c4bca
Added the club_app view, logic and model
Sverre Rabbelier <srabbelier@gmail.com>
parents:
diff
changeset
|
26 |
|
30da180c4bca
Added the club_app view, logic and model
Sverre Rabbelier <srabbelier@gmail.com>
parents:
diff
changeset
|
27 |
import soc.models.group_app |
30da180c4bca
Added the club_app view, logic and model
Sverre Rabbelier <srabbelier@gmail.com>
parents:
diff
changeset
|
28 |
|
30da180c4bca
Added the club_app view, logic and model
Sverre Rabbelier <srabbelier@gmail.com>
parents:
diff
changeset
|
29 |
|
30da180c4bca
Added the club_app view, logic and model
Sverre Rabbelier <srabbelier@gmail.com>
parents:
diff
changeset
|
30 |
class Logic(base.Logic): |
30da180c4bca
Added the club_app view, logic and model
Sverre Rabbelier <srabbelier@gmail.com>
parents:
diff
changeset
|
31 |
"""Logic methods for the Group Application model. |
30da180c4bca
Added the club_app view, logic and model
Sverre Rabbelier <srabbelier@gmail.com>
parents:
diff
changeset
|
32 |
""" |
30da180c4bca
Added the club_app view, logic and model
Sverre Rabbelier <srabbelier@gmail.com>
parents:
diff
changeset
|
33 |
|
30da180c4bca
Added the club_app view, logic and model
Sverre Rabbelier <srabbelier@gmail.com>
parents:
diff
changeset
|
34 |
def __init__(self, model=soc.models.group_app.GroupApplication, |
1147
5b5ce5056a2a
Changed group_app to use scope_logic in constructor.
Lennard de Rijk <ljvderijk@gmail.com>
parents:
1082
diff
changeset
|
35 |
base_model=None, scope_logic=None): |
791
30da180c4bca
Added the club_app view, logic and model
Sverre Rabbelier <srabbelier@gmail.com>
parents:
diff
changeset
|
36 |
"""Defines the name, key_name and model for this entity. |
30da180c4bca
Added the club_app view, logic and model
Sverre Rabbelier <srabbelier@gmail.com>
parents:
diff
changeset
|
37 |
""" |
30da180c4bca
Added the club_app view, logic and model
Sverre Rabbelier <srabbelier@gmail.com>
parents:
diff
changeset
|
38 |
|
1147
5b5ce5056a2a
Changed group_app to use scope_logic in constructor.
Lennard de Rijk <ljvderijk@gmail.com>
parents:
1082
diff
changeset
|
39 |
super(Logic, self).__init__(model=model, base_model=base_model, |
5b5ce5056a2a
Changed group_app to use scope_logic in constructor.
Lennard de Rijk <ljvderijk@gmail.com>
parents:
1082
diff
changeset
|
40 |
scope_logic=scope_logic) |
791
30da180c4bca
Added the club_app view, logic and model
Sverre Rabbelier <srabbelier@gmail.com>
parents:
diff
changeset
|
41 |
|
30da180c4bca
Added the club_app view, logic and model
Sverre Rabbelier <srabbelier@gmail.com>
parents:
diff
changeset
|
42 |
logic = Logic() |