Child: [35a781] (diff)

Download this file

admin.py    25 lines (20 with data), 667 Bytes

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
from pylons import c
from formencode import validators as fev
import ew as ew_core
import ew.jinja2_ew as ew
from allura.lib.widgets import forms as ff
class OptionsAdmin(ff.ForgeForm):
defaults=dict(
ff.ForgeForm.defaults,
submit_text = 'Save')
@property
def fields(self):
fields = [
ew.SingleSelectField(
name='PostingPolicy',
label='Posting Policy',
options=[
ew.Option(py_value='ApproveOnceModerated', label='Approve Once Moderated'),
ew.Option(py_value='ApproveAll', label='Approve All')])
]
return fields