diefenbach / django-lfs

An online-shop based on Django
http://www.getlfs.com
BSD 3-Clause "New" or "Revised" License
622 stars 222 forks source link

allow management of suppliers through the manage interface #103

Closed mthornhill closed 11 years ago

diefenbach commented 11 years ago

When I try to open the management I get:

File "/Users/Kai/Development/django/lfs/lfs-buildout-development/eggs/Django-1.4-py2.7.egg/django/core/handlers/base.py", line 111, in get_response response = callback(request, _callback_args, _callback_kwargs) File "/Users/Kai/Development/django/lfs/lfs-buildout-development/eggs/Django-1.4-py2.7.egg/django/contrib/auth/decorators.py", line 20, in _wrapped_view return view_func(request, _args, _kwargs) File "/Users/Kai/Development/django/lfs/lfs-buildout-development/src/lfs/lfs/manage/views/dashboard.py", line 11, in dashboard return render_to_response(template_name, RequestContext((request))) File "/Users/Kai/Development/django/lfs/lfs-buildout-development/eggs/Django-1.4-py2.7.egg/django/shortcuts/init.py", line 20, in render_to_response return HttpResponse(loader.render_to_string(_args, *_kwargs), **httpresponse_kwargs) File "/Users/Kai/Development/django/lfs/lfs-buildout-development/eggs/Django-1.4-py2.7.egg/django/template/loader.py", line 171, in render_to_string return t.render(Context(dictionary)) File "/Users/Kai/Development/django/lfs/lfs-buildout-development/eggs/Django-1.4-py2.7.egg/django/template/base.py", line 140, in render return self._render(context) File "/Users/Kai/Development/django/lfs/lfs-buildout-development/eggs/Django-1.4-py2.7.egg/django/template/base.py", line 134, in _render return self.nodelist.render(context) File "/Users/Kai/Development/django/lfs/lfs-buildout-development/eggs/Django-1.4-py2.7.egg/django/template/base.py", line 823, in render bit = self.render_node(node, context) File "/Users/Kai/Development/django/lfs/lfs-buildout-development/eggs/Django-1.4-py2.7.egg/django/template/debug.py", line 74, in render_node return node.render(context) File "/Users/Kai/Development/django/lfs/lfs-buildout-development/eggs/Django-1.4-py2.7.egg/django/template/loader_tags.py", line 123, in render return compiled_parent._render(context) File "/Users/Kai/Development/django/lfs/lfs-buildout-development/eggs/Django-1.4-py2.7.egg/django/template/base.py", line 134, in _render return self.nodelist.render(context) File "/Users/Kai/Development/django/lfs/lfs-buildout-development/eggs/Django-1.4-py2.7.egg/django/template/base.py", line 823, in render bit = self.render_node(node, context) File "/Users/Kai/Development/django/lfs/lfs-buildout-development/eggs/Django-1.4-py2.7.egg/django/template/debug.py", line 74, in render_node return node.render(context) File "/Users/Kai/Development/django/lfs/lfs-buildout-development/eggs/django_compressor-1.1.2-py2.7.egg/compressor/templatetags/compress.py", line 91, in render rendered_output = compressor.output(self.mode, forced=forced) File "/Users/Kai/Development/django/lfs/lfs-buildout-development/eggs/django_compressor-1.1.2-py2.7.egg/compressor/base.py", line 214, in output verbatim_content, rendered_content = self.filtered_input(mode, forced) File "/Users/Kai/Development/django/lfs/lfs-buildout-development/eggs/django_compressor-1.1.2-py2.7.egg/compressor/base.py", line 173, in filtered_input for mode, hunk in self.hunks(mode, forced): File "/Users/Kai/Development/django/lfs/lfs-buildout-development/eggs/django_compressor-1.1.2-py2.7.egg/compressor/base.py", line 131, in hunks for kind, value, basename, elem in self.split_contents(): File "/Users/Kai/Development/django/lfs/lfs-buildout-development/eggs/django_compressor-1.1.2-py2.7.egg/compressor/js.py", line 22, in split_contents filename = self.get_filename(basename) File "/Users/Kai/Development/django/lfs/lfs-buildout-development/eggs/django_compressor-1.1.2-py2.7.egg/compressor/base.py", line 88, in get_filename self.finders and " or with staticfiles." or ".")) UncompressableFileError: 'tiny_mce-3.5.8/jquery.tinymce.js' could not be found in the COMPRESS_ROOT '/Users/Kai/Development/django/lfs/lfs-buildout-development/lfs_project/sitestatic' or with staticfiles.

Seems you have upgraded tinymce without pushing the sources.

diefenbach commented 11 years ago

When I try to add a new supplier I get:

File "/Users/Kai/Development/django/lfs/lfs-buildout-development/eggs/Django-1.4-py2.7.egg/django/core/handlers/base.py", line 111, in get_response response = callback(request, _callback_args, _callback_kwargs) File "/Users/Kai/Development/django/lfs/lfs-buildout-development/eggs/Django-1.4-py2.7.egg/django/contrib/auth/decorators.py", line 20, in _wrapped_view return view_func(request, _args, _kwargs) File "/Users/Kai/Development/django/lfs/lfs-buildout-development/src/lfs/lfs/manage/suppliers/views.py", line 78, in add_supplier new_supplier = form.save() File "/Users/Kai/Development/django/lfs/lfs-buildout-development/eggs/Django-1.4-py2.7.egg/django/forms/models.py", line 364, in save fail_message, commit, construct=False) File "/Users/Kai/Development/django/lfs/lfs-buildout-development/eggs/Django-1.4-py2.7.egg/django/forms/models.py", line 86, in save_instance instance.save() File "/Users/Kai/Development/django/lfs/lfs-buildout-development/eggs/Django-1.4-py2.7.egg/django/db/models/base.py", line 463, in save self.save_base(using=using, force_insert=force_insert, force_update=force_update) File "/Users/Kai/Development/django/lfs/lfs-buildout-development/eggs/Django-1.4-py2.7.egg/django/db/models/base.py", line 551, in save_base result = manager._insert([self], fields=fields, return_id=update_pk, using=using, raw=raw) File "/Users/Kai/Development/django/lfs/lfs-buildout-development/eggs/Django-1.4-py2.7.egg/django/db/models/manager.py", line 203, in _insert return insert_query(self.model, objs, fields, **kwargs) File "/Users/Kai/Development/django/lfs/lfs-buildout-development/eggs/Django-1.4-py2.7.egg/django/db/models/query.py", line 1576, in insert_query return query.get_compiler(using=using).execute_sql(return_id) File "/Users/Kai/Development/django/lfs/lfs-buildout-development/eggs/Django-1.4-py2.7.egg/django/db/models/sql/compiler.py", line 910, in execute_sql cursor.execute(sql, params) File "/Users/Kai/Development/django/lfs/lfs-buildout-development/eggs/Django-1.4-py2.7.egg/django/db/backends/util.py", line 40, in execute return self.cursor.execute(sql, params) File "/Users/Kai/Development/django/lfs/lfs-buildout-development/eggs/Django-1.4-py2.7.egg/django/db/backends/sqlite3/base.py", line 337, in execute return Database.Cursor.execute(self, query, params) IntegrityError: supplier_supplier.user_id may not be NULL

mthornhill commented 11 years ago

Hi Kai, I've merged the latest from master branch to resolve the tinymce issue and added the required user to the add supplier form. Thanks Michael

mthornhill commented 11 years ago

Closing this as it's more appropriate to include as an lfs_suppliers module