short name for save

feature/docker
Dmitriy Shesterkin 9 years ago
parent 469e1692f1
commit 0fcd633da1
  1. 4
      src/customer/views/profile.py
  2. 3
      src/docs/views/base_views.py

@ -4,7 +4,7 @@ import json
import tempfile
from email.header import Header
from django.shortcuts import render, redirect, get_object_or_404
from django.shortcuts import render, redirect
from django.core.files import File
from django.views.decorators.csrf import csrf_protect
from django.contrib.auth.decorators import login_required
@ -14,13 +14,11 @@ from django.utils.encoding import smart_str
from django.conf import settings
from django.http import Http404, HttpResponse
# from sorl.thumbnail import get_thumbnail
from easy_thumbnails.files import get_thumbnailer
from commons.pdf_tools import render_pdf_to_string, pdf_to_response
from customer import models, forms
from customer.decorators import license_required
from customer.utils import raise_if_no_profile
PDF_PROFILE_NAME = u'Реквизиты.pdf'

@ -185,7 +185,8 @@ class BaseViews(object):
def get_filename(self, *args, **kwargs):
obj = self.get_obj(kwargs['id'])
client = obj.client.name.replace('\n', ' ').replace('\r', ' ').strip()
client = obj.client.name_short_dadata.replace('\n', ' ').replace('\r', ' ').strip()
return self.FILENAME % (obj.doc_num, client,)
def update_list_dict(self, dictionary):

Loading…
Cancel
Save