1 # BiaWeb Website content manager (c) 2010 V.Harishankar
2 # Templates dialog class
5 import ui_templates_dialog
8 class TemplatesDialog (PyQt4
.QtGui
.QDialog
, ui_templates_dialog
.Ui_TemplatesDialog
):
9 def __init__ (self
, master
, currentdb
):
10 PyQt4
.QtGui
.QDialog
.__init
__ (self
, master
)
13 # set the current database
14 self
.current_db
= currentdb
16 # populate the templates
17 tpls
= biaweb_db
.get_templates (self
.current_db
)
18 for tpl_name
, tpl_content
in tpls
:
19 self
.templates
.addItem (str (tpl_name
))