|
Revision 2094, 0.7 kB
(checked in by alo, 2 months ago)
|
--
|
| Line | |
|---|
| 1 |
from Form import * |
|---|
| 2 |
from Table import * |
|---|
| 3 |
from ModuleHandler import * |
|---|
| 4 |
from consts import * |
|---|
| 5 |
|
|---|
| 6 |
NOTE_ERRORS = 'HTTP Error that you be used to reply the request.' |
|---|
| 7 |
|
|---|
| 8 |
HELPS = [ |
|---|
| 9 |
('modules_handlers_custom_error', "HTTP Custom Error") |
|---|
| 10 |
] |
|---|
| 11 |
|
|---|
| 12 |
class ModuleCustomError (ModuleHandler): |
|---|
| 13 |
PROPERTIES = [] |
|---|
| 14 |
|
|---|
| 15 |
def __init__ (self, cfg, prefix, submit_url): |
|---|
| 16 |
ModuleHandler.__init__ (self, 'custom_error', cfg, prefix, submit_url) |
|---|
| 17 |
self.show_document_root = False |
|---|
| 18 |
|
|---|
| 19 |
def _op_render (self): |
|---|
| 20 |
table = TableProps() |
|---|
| 21 |
self.AddPropOptions_Reload (table, "HTTP Error", "%s!error" % (self._prefix), ERROR_CODES, NOTE_ERRORS) |
|---|
| 22 |
return str(table) |
|---|
| 23 |
|
|---|
| 24 |
def _op_apply_changes (self, uri, post): |
|---|
| 25 |
self.ApplyChangesPrefix (self._prefix, [], post) |
|---|
| 26 |
|
|---|