Alberto Valverde <[EMAIL PROTECTED]> writes:

> I've you're looking for the former DataGrid, it's been renamed to
> FastDataGrid as Datagrid is being refactored out to remove all model
> dependancy.

And what is its syntax? :-)  'Cause I get the same error with it as well.  

================================================================================
from turbogears.fastdata import datawidgets

grid_clientes = datawidgets.FastDataGrid(
    fields = [
    (lazy_gettext('Cliente'), 'nomeAbreviado'),
    (lazy_gettext('Contrato assinado em'), grid_contrato_assinatura),
    (lazy_gettext(u'Contrato válido até'), grid_contrato_vencimento),
    (lazy_gettext('Ativo?'), 'isAtivo'),
    ],
    )
================================================================================

and the Traceback:

================================================================================
Traceback (most recent call last):
  File 
"/usr/lib/python2.4/site-packages/CherryPy-2.2.0beta-py2.4.egg/cherrypy/_cphttptools.py",
 line 99, in _run
    self.main()
  File 
"/usr/lib/python2.4/site-packages/CherryPy-2.2.0beta-py2.4.egg/cherrypy/_cphttptools.py",
 line 247, in main
    body = page_handler(*virtual_path, **self.params)
  File "<string>", line 3, in index
  File 
"/home/godoy/desenvolvimento/python/TurboGears/trunk/turbogears/controllers.py",
 line 188, in expose
    func, tg_format, html, fragment, *args, **kw)
  File 
"/home/godoy/desenvolvimento/python/TurboGears/trunk/turbogears/database.py", 
line 193, in run_with_transaction
    retval = func(*args, **kw)
  File 
"/home/godoy/desenvolvimento/python/TurboGears/trunk/turbogears/controllers.py",
 line 200, in _execute_func
    output = errorhandling.try_call(func, self, *args, **kw)
  File 
"/home/godoy/desenvolvimento/python/TurboGears/trunk/turbogears/errorhandling.py",
 line 64, in try_call
    output = dispatch_error(func, self, error, *args, **kw)
  File "<string>", line 5, in dispatch_error
  File 
"/home/godoy/desenvolvimento/python/TurboGears/trunk/turbogears/errorhandling.py",
 line 27, in _default_error_handler
    return getattr(self, error_source.__name__ )(*args, **kw)
  File "<string>", line 3, in index
  File 
"/home/godoy/desenvolvimento/python/TurboGears/trunk/turbogears/controllers.py",
 line 183, in expose
    output = _execute_func(self, func, tg_format, html, fragment,
  File 
"/home/godoy/desenvolvimento/python/TurboGears/trunk/turbogears/controllers.py",
 line 200, in _execute_func
    output = errorhandling.try_call(func, self, *args, **kw)
  File 
"/home/godoy/desenvolvimento/python/TurboGears/trunk/turbogears/errorhandling.py",
 line 55, in try_call
    output = func(self, *args, **kw)
  File "/home/godoy/.eclipse/LATAM/site_amostras/site_amostras/clientes.py", 
line 60, in index
    return self.clientes(cliente_id)
  File "<string>", line 3, in clientes
  File 
"/home/godoy/desenvolvimento/python/TurboGears/trunk/turbogears/controllers.py",
 line 183, in expose
    output = _execute_func(self, func, tg_format, html, fragment,
  File 
"/home/godoy/desenvolvimento/python/TurboGears/trunk/turbogears/controllers.py",
 line 205, in _execute_func
    return _process_output(tg_format, output, html, fragment)
  File 
"/home/godoy/desenvolvimento/python/TurboGears/trunk/turbogears/controllers.py",
 line 68, in _process_output
    fragment=fragment)
  File 
"/home/godoy/desenvolvimento/python/TurboGears/trunk/turbogears/view.py", line 
60, in render
    return engine.render(info, format, fragment, template)
  File 
"/usr/lib/python2.4/site-packages/TurboKid-0.9.0-py2.4.egg/turbokid/kidsupport.py",
 line 136, in render
    return t.serialize(encoding=self.defaultencoding, output=format, 
fragment=fragment)
  File 
"/home/godoy/desenvolvimento/python/TurboGears/trunk/thirdparty/kid/kid/__init__.py",
 line 236, in serialize
    return serializer.serialize(self, encoding, fragment)
  File 
"/home/godoy/desenvolvimento/python/TurboGears/trunk/thirdparty/kid/kid/serialization.py",
 line 51, in serialize
    text = list(self.generate(stream, encoding, fragment))
  File 
"/home/godoy/desenvolvimento/python/TurboGears/trunk/thirdparty/kid/kid/serialization.py",
 line 327, in generate
    for ev, item in self.apply_filters(stream):
  File 
"/home/godoy/desenvolvimento/python/TurboGears/trunk/thirdparty/kid/kid/serialization.py",
 line 84, in balancing_filter
    for ev, item in stream:
  File 
"/home/godoy/desenvolvimento/python/TurboGears/trunk/thirdparty/kid/kid/pull.py",
 line 206, in _coalesce
    for ev, item in stream:
  File 
"/home/godoy/desenvolvimento/python/TurboGears/trunk/thirdparty/kid/kid/filter.py",
 line 21, in transform_filter
    for ev, item in apply_matches(stream, template, templates, apply_func):
  File 
"/home/godoy/desenvolvimento/python/TurboGears/trunk/thirdparty/kid/kid/filter.py",
 line 31, in apply_matches
    item = stream.expand()
  File 
"/home/godoy/desenvolvimento/python/TurboGears/trunk/thirdparty/kid/kid/pull.py",
 line 95, in expand
    for ev, item in self._iter:
  File 
"/home/godoy/desenvolvimento/python/TurboGears/trunk/thirdparty/kid/kid/pull.py",
 line 164, in _track
    for p in stream:
  File 
"/home/godoy/desenvolvimento/python/TurboGears/trunk/thirdparty/kid/kid/pull.py",
 line 206, in _coalesce
    for ev, item in stream:
  File 
"/home/godoy/.eclipse/LATAM/site_amostras/site_amostras/templates/clientes.py", 
line 86, in _pull
  File 
"/home/godoy/desenvolvimento/python/TurboGears/trunk/thirdparty/kid/kid/filter.py",
 line 21, in transform_filter
    for ev, item in apply_matches(stream, template, templates, apply_func):
  File 
"/home/godoy/desenvolvimento/python/TurboGears/trunk/thirdparty/kid/kid/filter.py",
 line 25, in apply_matches
    for ev, item in stream:
  File 
"/home/godoy/desenvolvimento/python/TurboGears/trunk/thirdparty/kid/kid/pull.py",
 line 164, in _track
    for p in stream:
  File 
"/home/godoy/desenvolvimento/python/TurboGears/trunk/thirdparty/kid/kid/pull.py",
 line 206, in _coalesce
    for ev, item in stream:
  File 
"/home/godoy/desenvolvimento/python/TurboGears/trunk/turbogears/fastdata/templates/datagrid.py",
 line 31, in _pull
NameError: name 'name' is not defined
================================================================================


-- 
Jorge Godoy      <[EMAIL PROTECTED]>

Reply via email to