From 84710923bcd5252088926089a6f450c117c68e7f Mon Sep 17 00:00:00 2001 From: Baryshnikov Nikolay Date: Thu, 2 Mar 2017 14:40:39 +0300 Subject: [PATCH] =?UTF-8?q?=D0=9F=D1=80=D0=B0=D0=B2=D0=BA=D0=B8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- management/api.py | 5 ++--- service/models.py | 1 - 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/management/api.py b/management/api.py index ff1ef0b..cf0ed3a 100755 --- a/management/api.py +++ b/management/api.py @@ -94,9 +94,8 @@ def new_bill(request, context): service = Price.objects.get(id=request.POST['new_bill_checked_service']) bill = Bill.objects.create(user=user, service=service, - file=bill.service.course.get_description_file(), - manager=request.user.get_full_name(), - manager_phone=request.user.get_phone(), + file=service.course.get_description_file(), + manager=request.user.get_full_name(), price=request.POST['new_bill_cost'], description=request.POST.get('new_bill_comment') if request.POST.get( 'new_bill_comment') else '') diff --git a/service/models.py b/service/models.py index bddf409..82d12a0 100755 --- a/service/models.py +++ b/service/models.py @@ -75,7 +75,6 @@ class MailBox(models.Model): msg = EmailMessage(self.title, self.result, u'{1} <{0}>'.format(DEFAULT_FROM_EMAIL, NAME), [self._to if not TESTING else TEST_EMAIL]) msg.content_subtype = "html" - msg.attach(u'Описание курса', file) try: msg.send() except smtplib.SMTPDataError as e: