diff --git a/osinaweb/db.sqlite3 b/osinaweb/db.sqlite3 index aaf759d5..05ef66dc 100644 Binary files a/osinaweb/db.sqlite3 and b/osinaweb/db.sqlite3 differ diff --git a/osinaweb/osinacore/__pycache__/custom_context.cpython-311.pyc b/osinaweb/osinacore/__pycache__/custom_context.cpython-311.pyc new file mode 100644 index 00000000..1ad246cb Binary files /dev/null and b/osinaweb/osinacore/__pycache__/custom_context.cpython-311.pyc differ diff --git a/osinaweb/osinacore/__pycache__/views.cpython-311.pyc b/osinaweb/osinacore/__pycache__/views.cpython-311.pyc index 798637de..a06b3aba 100644 Binary files a/osinaweb/osinacore/__pycache__/views.cpython-311.pyc and b/osinaweb/osinacore/__pycache__/views.cpython-311.pyc differ diff --git a/osinaweb/osinacore/views.py b/osinaweb/osinacore/views.py index 22bbd912..b5143e7d 100644 --- a/osinaweb/osinacore/views.py +++ b/osinaweb/osinacore/views.py @@ -621,11 +621,12 @@ def save_business(request): return render(request, 'add-business.html') + @login_required def save_business_modal(request): if request.method == 'POST': name = request.POST.get('name') - email= request.POST.get('email') + email = request.POST.get('email') financial_number = request.POST.get('financial_number') phone_number = request.POST.get('phone_number') vat = request.POST.get('vat') @@ -635,20 +636,28 @@ def save_business_modal(request): logo = request.POST.get('logo') business = Business( - name = name, - email = email, - financial_number = financial_number, - vat = vat, - commercial_registration = commercial_registration, - website = website, - business_type = business_type, - logo = logo, - phone_number = phone_number, + name=name, + email=email, + financial_number=financial_number, + vat=vat, + commercial_registration=commercial_registration, + website=website, + business_type=business_type, + logo=logo, + phone_number=phone_number, ) business.save() - return render(request, 'addbusiness-modal.html') + # Fetch the updated options for the {% for business in businesses %} @@ -76,6 +76,7 @@ + + + + + + +
+ + +
+ + + + + + + + + + + + +
+ +
+ + + + + + + + + + - + +
+ + +