You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello, thanks a lot for providing this kind of widget. I'm having a problem using this widget. I see the widget in the page with the icon. I push the icon and nothing occurs. I see in the debugger this error:
TypeError: 'undefined' is not a function (evaluating '$("#f4f0d394302e4843a2f0863dd7c428ee").datetimepicker')
global code (39, line 144)
I've tried to follow closely the example, but I do not know where the problem is.
In the base template I have:
<link href="{% static 'css/bootstrap.min.css' %}" rel="stylesheet" media="screen">
<link href="{% static 'css/bootstrap-responsive.min.css' %}" rel="stylesheet">
<!-- This file store project specific CSS -->
<link href="{% static 'css/project.css' %}" rel="stylesheet">
<!-- Use this to quickly test CSS changes in a template,
then move to project.css -->
{% block extra_css %}{% endblock extra_css %}
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.9.1/jquery.min.js"></script>
<script src="{% static 'js/jquery.ui.datepicker.js' %}"></script>
<script src="{% static 'js/bootstrap.min.js' %}"></script>
{{ form.media }}
Then in the template where these widgets are I have:
{% csrf_token %}
{{ formset.management_form }}
{% for miform in formset %}
{{ miform.id}}
{% if miform.instance.indicador.esIntervalo %}
{{ miform.instance.indicador.nombre }}:
{% else %}
{% endif %}
{% endfor %}
Hey Diego, looks like jQuery may not be defined. I haven't tried this solution yet, but you could try looking at the following link for a proposed solution: #61
Hello, thanks a lot for providing this kind of widget. I'm having a problem using this widget. I see the widget in the page with the icon. I push the icon and nothing occurs. I see in the debugger this error:
TypeError: 'undefined' is not a function (evaluating '$("#f4f0d394302e4843a2f0863dd7c428ee").datetimepicker')
global code (39, line 144)
I've tried to follow closely the example, but I do not know where the problem is.
In the base template I have:
{{ form.media }}
Then in the template where these widgets are I have:
{% csrf_token %} {{ formset.management_form }} {% for miform in formset %} {{ miform.id}} {% if miform.instance.indicador.esIntervalo %} {{ miform.instance.indicador.nombre }}: {% else %} {% endif %} {% endfor %}The form for the formset is:
class InsIndicForm(forms.ModelForm):
#valor = forms.FloatField(widget=forms.TextInput(attrs={'size':'5'}))
class Meta:
model=InstanciaIndicador
fields=('valor','fecha1','fecha2','numero', 'total')
widgets = {
'fecha1': DateTimeWidget(attrs={'id':"fecha1"}, usel10n = True),
'fecha2': DateTimeWidget(attrs={'id':"fecha2"}, usel10n = True),
Please, do you see where is the error?
Thanks in advance,
Diego.
The text was updated successfully, but these errors were encountered: