[pyar] Inconveniente con Django-Bootstrap ({% datetime_widget_css_path as datetime_widget_css %})

Javier Roa Benitez jroabenitez en gmail.com
Mie Feb 7 15:10:50 ART 2018


Muchas Gracias, me resolvio.
Habia leido algo de compatibilidad pero no se me estaba instalando.
Saludos
Javier

2018-02-07 14:19 GMT-03:00 Willian Morais <williandmorais en gmail.com>:

> Hola Javier,
>
> Utilice la versión 0.3.7.1 que es compatible con Django 1.8.
>
>
> *pip install bootstrap-admin==0.3.7.1*
>>
> 2018-02-07 14:32 GMT-02:00 Javier Roa Benitez <jroabenitez en gmail.com>:
>
>> Buenas tardes:
>> Preciso de la ayuda de ustedes si este es el ambito, tango instalado
>> django 1.8 y quiero trabajar con django-boostrap(instael bootstrap-admin
>> 0.3.7), segui las intrucciones de los tutoriales y supuestamente deberia
>> funcionar, pero al hacer http://localhost:8000/admin/login/?next=/admin/ me
>> da este error.( {% datetime_widget_css_path as datetime_widget_css %} )
>> Espero puedan ayudarme, pues busque en google y no soncegui encontrar una
>> orientacion que me ayude a resolverlo.
>> Saludos
>> --
>> Lic. Javier Roa Benitez
>> Analista de Sistemas
>> Consultor Informatico
>> adjunto detalle:
>> Environment:
>>
>>
>> Request Method: GET
>> Request URL: http://localhost:8000/admin/login/?next=/admin/
>>
>> Django Version: 1.8
>> Python Version: 2.7.0
>> Installed Applications:
>> ['bootstrap_admin',
>>  'django.contrib.admin',
>>  'django.contrib.auth',
>>  'django.contrib.contenttypes',
>>  'django.contrib.sessions',
>>  'django.contrib.messages',
>>  'django.contrib.staticfiles',
>>  'irp']
>> Installed Middleware:
>> ['django.middleware.security.SecurityMiddleware',
>>  'django.contrib.sessions.middleware.SessionMiddleware',
>>  'django.middleware.common.CommonMiddleware',
>>  'django.middleware.csrf.CsrfViewMiddleware',
>>  'django.contrib.auth.middleware.AuthenticationMiddleware',
>>  'django.contrib.messages.middleware.MessageMiddleware',
>>  'django.middleware.clickjacking.XFrameOptionsMiddleware']
>>
>>
>> Template error:
>> In template C:\entjrb\lib\site-packages\bootstrap_admin\templates\admin\base.html,
>> error at line 14
>>    'datetime_widget_css_path' received too many positional arguments
>>
>>    4 : <head>
>>
>>
>>
>>    5 :   <meta http-equiv="X-UA-Compatible" content="IE=edge">
>>
>>
>>
>>    6 :   <meta name="viewport" content="width=device-width,
>> initial-scale=1">
>>
>>
>>
>>    7 :   <title>{% block title %}{% endblock %}</title>
>>
>>
>>
>>    8 :
>>
>>
>>
>>    9 :   {% block bootstrap_admin_css %}
>>
>>
>>
>>    10 :     <link rel="stylesheet" type="text/css" href="{% static
>> 'bootstrap_admin/css/bootstrap.min.css' %}" />
>>
>>
>>
>>    11 :   {% endblock bootstrap_admin_css %}
>>
>>
>>
>>    12 :
>>
>>
>>
>>    13 :   <link rel="stylesheet" type="text/css" href="{% block
>> stylesheet %}{% static 'admin/css/base.css' %}{% endblock %}" />
>>
>>
>>
>>    14 :    {% datetime_widget_css_path as datetime_widget_css %}
>>
>>
>>
>>    15 :   {% if datetime_widget_css %}
>>
>>
>>
>>    16 :     <link rel="stylesheet" type="text/css" href="{% static
>> datetime_widget_css %}" />
>>
>>
>>
>>    17 :   {% endif %}
>>
>>
>>
>>    18 :
>>
>>
>>
>>    19 : {% block extrastyle %}{% endblock %}
>>
>>
>>
>>    20 :
>>
>>
>>
>>    21 : {% if LANGUAGE_BIDI %}
>>
>>
>>
>>    22 :   {# PUT HERE YOUR CUSTOM RTL STYLESHEET #}
>>
>>
>>
>>    23 :   {% comment %}
>>
>>
>>
>>    24 :   <link rel="stylesheet" type="text/css" href="{% block
>> stylesheet_rtl %}{% static "admin/css/rtl.css" %}{% endblock %}" />
>>
>>
>> Traceback:
>> File "C:\entjrb\lib\site-packages\django\core\handlers\base.py" in
>> get_response
>>   164.                 response = response.render()
>> File "C:\entjrb\lib\site-packages\django\template\response.py" in render
>>   158.             self.content = self.rendered_content
>> File "C:\entjrb\lib\site-packages\django\template\response.py" in
>> rendered_content
>>   135.         content = template.render(context, self._request)
>> File "C:\entjrb\lib\site-packages\django\template\backends\django.py" in
>> render
>>   74.         return self.template.render(context)
>> File "C:\entjrb\lib\site-packages\django\template\base.py" in render
>>   209.                     return self._render(context)
>> File "C:\entjrb\lib\site-packages\django\template\base.py" in _render
>>   201.         return self.nodelist.render(context)
>> File "C:\entjrb\lib\site-packages\django\template\base.py" in render
>>   903.                 bit = self.render_node(node, context)
>> File "C:\entjrb\lib\site-packages\django\template\debug.py" in
>> render_node
>>   79.             return node.render(context)
>> File "C:\entjrb\lib\site-packages\django\template\loader_tags.py" in
>> render
>>   135.         return compiled_parent._render(context)
>> File "C:\entjrb\lib\site-packages\django\template\base.py" in _render
>>   201.         return self.nodelist.render(context)
>> File "C:\entjrb\lib\site-packages\django\template\base.py" in render
>>   903.                 bit = self.render_node(node, context)
>> File "C:\entjrb\lib\site-packages\django\template\debug.py" in
>> render_node
>>   79.             return node.render(context)
>> File "C:\entjrb\lib\site-packages\django\template\loader_tags.py" in
>> render
>>   113.         compiled_parent = self.get_parent(context)
>> File "C:\entjrb\lib\site-packages\django\template\loader_tags.py" in
>> get_parent
>>   110.         return context.template.engine.get_template(parent)
>> File "C:\entjrb\lib\site-packages\django\template\engine.py" in
>> get_template
>>   167.         template, origin = self.find_template(template_name, dirs)
>> File "C:\entjrb\lib\site-packages\django\template\engine.py" in
>> find_template
>>   141.                 source, display_name = loader(name, dirs)
>> File "C:\entjrb\lib\site-packages\django\template\loaders\base.py" in
>> __call__
>>   13.         return self.load_template(template_name, template_dirs)
>> File "C:\entjrb\lib\site-packages\django\template\loaders\base.py" in
>> load_template
>>   23.             template = Template(source, origin, template_name,
>> self.engine)
>> File "C:\entjrb\lib\site-packages\django\template\base.py" in __init__
>>   190.         self.nodelist = engine.compile_string(template_string,
>> origin)
>> File "C:\entjrb\lib\site-packages\django\template\engine.py" in
>> compile_string
>>   261.         return parser.parse()
>> File "C:\entjrb\lib\site-packages\django\template\base.py" in parse
>>   341.                     compiled_result = compile_func(self, token)
>> File "C:\entjrb\lib\site-packages\django\template\base.py" in
>> generic_tag_compiler
>>   1094.                               defaults, takes_context, name)
>> File "C:\entjrb\lib\site-packages\django\template\base.py" in parse_bits
>>   1074.                             name)
>>
>> Exception Type: TemplateSyntaxError at /admin/login/
>> Exception Value: 'datetime_widget_css_path' received too many positional
>> arguments
>>
>>
>> _______________________________________________
>> Lista de Correo de PyAr - Python Argentina - pyar en python.org.ar
>> Sitio web: http://www.python.org.ar/
>>
>> Para administrar la lista (o desuscribirse) entrar a
>> http://listas.python.org.ar/listinfo/pyar
>>
>> La lista de PyAr esta Hosteada en USLA - Usuarios de Software Libre de
>> Argentina - http://www.usla.org.ar
>>
>
>
>
> --
> Abraços!
>
> Willian de Morais
> Hangout: williandmorais en gmail.com
> Skype: wmorais90
> Celular: (48) 8811-9660/9676-8976
>
> _______________________________________________
> Lista de Correo de PyAr - Python Argentina - pyar en python.org.ar
> Sitio web: http://www.python.org.ar/
>
> Para administrar la lista (o desuscribirse) entrar a
> http://listas.python.org.ar/listinfo/pyar
>
> La lista de PyAr esta Hosteada en USLA - Usuarios de Software Libre de
> Argentina - http://www.usla.org.ar
>



-- 
Lic. Javier Roa Benitez
Analista de Sistemas
Consultor Informatico
------------ próxima parte ------------
Se ha borrado un adjunto en formato HTML...
URL: <http://listas.python.org.ar/pipermail/pyar/attachments/20180207/4e19e019/attachment-0001.html>


Más información sobre la lista de distribución pyar