diff --git a/sigi/apps/diagnosticos/views.py b/sigi/apps/diagnosticos/views.py index 3768c57..5435bba 100644 --- a/sigi/apps/diagnosticos/views.py +++ b/sigi/apps/diagnosticos/views.py @@ -272,7 +272,7 @@ def diagnostico_pdf(request, id_diagnostico): def graficos(request): categorias = Categoria.objects.all() - sel_categoria = int(request.REQUEST.get("categoria", "3")) + sel_categoria = int(request.GET.get("categoria", "3")) perguntas = Pergunta.objects.filter(categoria=sel_categoria).all() context = RequestContext(request, { @@ -315,7 +315,7 @@ def grafico_api(request): '#BB9098', '#BDF1ED', ]) - pergunta_slug = request.REQUEST.get('id', None) + pergunta_slug = request.GET.get('id', None) pergunta = get_object_or_404(Pergunta, name=pergunta_slug) if pergunta.datatype == 'one': diff --git a/sigi/apps/solicitacoes/forms.py b/sigi/apps/solicitacoes/forms.py index 614e3c1..b3fda31 100644 --- a/sigi/apps/solicitacoes/forms.py +++ b/sigi/apps/solicitacoes/forms.py @@ -7,7 +7,7 @@ from django import forms from django.db import transaction from django.forms import ModelForm -from sigi.settings.prod import OSTICKET_API_KEY, OSTICKET_URL +from sigi.settings.prod import OSTICKET_API_KEY, OSTICKET_ATENDIMENTO_URL from .models import Solicitacao @@ -27,7 +27,8 @@ def open_osticket(solicitacao): "subject": solicitacao.titulo, "ip": "", "message": solicitacao.resumo} - response = requests.post(OSTICKET_URL, headers=headers, json=data) + response = requests.post(OSTICKET_ATENDIMENTO_URL, + headers=headers, json=data) if response.status_code == requests.codes.created: return response.text else: