Initial import
This commit is contained in:
commit
4043163fc4
427 changed files with 18387 additions and 0 deletions
BIN
gen/test/applications/AppyCar/Engine.odt
Normal file
BIN
gen/test/applications/AppyCar/Engine.odt
Normal file
Binary file not shown.
6
gen/test/applications/AppyCar/Engine.py
Normal file
6
gen/test/applications/AppyCar/Engine.py
Normal file
|
@ -0,0 +1,6 @@
|
|||
from appy.gen import *
|
||||
|
||||
class Engine:
|
||||
engineType = String()
|
||||
description = String(format=String.XHTML)
|
||||
pod = True
|
5
gen/test/applications/AppyCar/Interior/Radio.py
Normal file
5
gen/test/applications/AppyCar/Interior/Radio.py
Normal file
|
@ -0,0 +1,5 @@
|
|||
from appy.gen import *
|
||||
|
||||
class Radio:
|
||||
abstract = True
|
||||
name = String()
|
0
gen/test/applications/AppyCar/Interior/__init__.py
Normal file
0
gen/test/applications/AppyCar/Interior/__init__.py
Normal file
6
gen/test/applications/AppyCar/Wheel.py
Normal file
6
gen/test/applications/AppyCar/Wheel.py
Normal file
|
@ -0,0 +1,6 @@
|
|||
from appy.gen import *
|
||||
|
||||
class Wheel:
|
||||
title = String(multiplicity=(1,1))
|
||||
description = String(format=String.XHTML)
|
||||
|
37
gen/test/applications/AppyCar/__init__.py
Normal file
37
gen/test/applications/AppyCar/__init__.py
Normal file
|
@ -0,0 +1,37 @@
|
|||
from appy.gen import *
|
||||
from AppyCar.Interior.Radio import Radio
|
||||
|
||||
class RallyCarWorkflow:
|
||||
# Roles
|
||||
carDriver = 'CarDriver'
|
||||
driverM = ('Manager', carDriver)
|
||||
# Specific permissions
|
||||
readColor = ReadPermission('Car.color')
|
||||
writeColor = WritePermission('Car.color')
|
||||
# States
|
||||
created = State({r:driverM, w:driverM, d:driverM,
|
||||
readColor: driverM, writeColor: driverM}, initial=True)
|
||||
running = State({r:driverM, w:driverM, d:driverM,
|
||||
readColor: 'Manager', writeColor: 'Manager'})
|
||||
# Transitions
|
||||
run = Transition( (created, running), condition=driverM)
|
||||
stop = Transition( (running, created), condition=driverM)
|
||||
|
||||
class Car:
|
||||
sport = Boolean()
|
||||
color = String(specificReadPermission=True, specificWritePermission=True)
|
||||
description = String(format=String.TEXT)
|
||||
|
||||
class RallyCar(Car):
|
||||
root = True
|
||||
workflow = RallyCarWorkflow
|
||||
test = Integer()
|
||||
|
||||
class StandardRadio(Radio):
|
||||
test1 = Integer()
|
||||
|
||||
c = Config()
|
||||
c.languages = ('en', 'fr')
|
||||
|
||||
class CarFlavour(Flavour):
|
||||
explanation = String(group="userInterface")
|
Loading…
Add table
Add a link
Reference in a new issue