diff --git a/datacenterlight/locale/de/LC_MESSAGES/django.mo b/datacenterlight/locale/de/LC_MESSAGES/django.mo index 8f4d30cd..60da107c 100644 Binary files a/datacenterlight/locale/de/LC_MESSAGES/django.mo and b/datacenterlight/locale/de/LC_MESSAGES/django.mo differ diff --git a/datacenterlight/locale/de/LC_MESSAGES/django.po b/datacenterlight/locale/de/LC_MESSAGES/django.po index 45629dab..014a31d9 100644 --- a/datacenterlight/locale/de/LC_MESSAGES/django.po +++ b/datacenterlight/locale/de/LC_MESSAGES/django.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2017-05-23 17:26-0500\n" +"POT-Creation-Date: 2017-06-05 15:23-0500\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -67,6 +67,7 @@ msgstr "Vielen Dank!" #: templates/datacenterlight/index.html:62 #: templates/datacenterlight/pricing.html:62 +#: templates/datacenterlight/success.html:62 msgid "What is it" msgstr "Was ist es?" @@ -74,7 +75,8 @@ msgstr "Was ist es?" #: templates/datacenterlight/index.html:171 #: templates/datacenterlight/index.html:331 #: templates/datacenterlight/pricing.html:65 -#: templates/datacenterlight/pricing.html:188 +#: templates/datacenterlight/pricing.html:198 +#: templates/datacenterlight/success.html:65 msgid "Scale out" msgstr "Skalierung" @@ -82,19 +84,22 @@ msgstr "Skalierung" #: templates/datacenterlight/index.html:197 #: templates/datacenterlight/index.html:334 #: templates/datacenterlight/pricing.html:68 -#: templates/datacenterlight/pricing.html:191 +#: templates/datacenterlight/pricing.html:201 +#: templates/datacenterlight/success.html:68 msgid "Reliable and light" msgstr "Zuverlässig und leicht" #: templates/datacenterlight/index.html:71 #: templates/datacenterlight/pricing.html:71 +#: templates/datacenterlight/success.html:71 msgid "Buy VM" msgstr "VM Kaufen" #: templates/datacenterlight/index.html:74 #: templates/datacenterlight/index.html:341 #: templates/datacenterlight/pricing.html:74 -#: templates/datacenterlight/pricing.html:198 +#: templates/datacenterlight/pricing.html:208 +#: templates/datacenterlight/success.html:74 msgid "Contact" msgstr "Kontakt" @@ -112,7 +117,7 @@ msgstr "Das will ich haben!" #: templates/datacenterlight/index.html:142 #: templates/datacenterlight/index.html:328 -#: templates/datacenterlight/pricing.html:185 +#: templates/datacenterlight/pricing.html:195 msgid "How it works" msgstr "Wie es funktioniert" @@ -177,11 +182,13 @@ msgid "Based in Switzerland" msgstr "Standort des Datacenters ist in der Schweiz" #: templates/datacenterlight/index.html:243 -msgid "15 GB Storage (SSD)" +#, fuzzy +#| msgid "15 GB Storage (SSD)" +msgid "10 GB Storage (SSD)" msgstr "15 GB Storage (SSD)" #: templates/datacenterlight/index.html:246 -#: templates/datacenterlight/pricing.html:156 +#: templates/datacenterlight/pricing.html:166 msgid "Order Now!" msgstr "Bestelle jetzt!" @@ -202,12 +209,12 @@ msgid "Contact us!" msgstr "Kontaktiere uns!" #: templates/datacenterlight/index.html:324 -#: templates/datacenterlight/pricing.html:181 +#: templates/datacenterlight/pricing.html:191 msgid "Home" msgstr "Home" #: templates/datacenterlight/index.html:337 -#: templates/datacenterlight/pricing.html:194 +#: templates/datacenterlight/pricing.html:204 msgid "Pricing" msgstr "Preise" @@ -217,14 +224,22 @@ msgstr "Preise" msgid "Hosted in Switzerland" msgstr "Standort des Datacenters ist in der Schweiz" -#: templates/datacenterlight/pricing.html:136 +#: templates/datacenterlight/pricing.html:139 msgid "GB Storage (SSD)" msgstr "GB Storage (SSD)" -#: templates/datacenterlight/pricing.html:163 +#: templates/datacenterlight/pricing.html:173 msgid "Simple and affordable: Try our virtual machine with featherlight price." msgstr "" +#: templates/datacenterlight/success.html:101 +msgid "Thank you for order! Our team will contact you via email" +msgstr "Vielen Dank für die Bestellung. Unser Team setzt sich sobald wie möglich mit Ihnen via E-Mail in Verbindung." + +#: templates/datacenterlight/success.html:102 +msgid "as soon as possible!" +msgstr "" + #~ msgid "Buy Now!" #~ msgstr "Kaufe jetzt!" diff --git a/datacenterlight/static/datacenterlight/css/landing-page.css b/datacenterlight/static/datacenterlight/css/landing-page.css index 74671e1a..5c878fc7 100755 --- a/datacenterlight/static/datacenterlight/css/landing-page.css +++ b/datacenterlight/static/datacenterlight/css/landing-page.css @@ -243,6 +243,10 @@ h6 { align-items: center; position: relative; } +.intro-pricing.success-pricing{ + height: 100vh; + max-height: 100vh; +} .intro-pricing::before{ content: ""; position: absolute; @@ -631,12 +635,32 @@ h6 { height: 40px; width: 200px; text-align: center; - font-size: 18px; + font-size: 16px; + margin-left: 10px; } .price-calc-section .card .check-ip{ font-size: 18px; } - +.price-calc-section .card .description.input{ + justify-content: center; +} +.price-calc-section .card .description.input label{ + font-size: 15px; + font-weight: 800; + font-family: 'Montserrat-Regular'; + margin-bottom: 0; + width: 40px; +} +.price-calc-section .card .description.input input{ + width: 200px; + font-size: 14px; + text-align: left; + padding: 5px 10px; + border-radius: 4px; + border: 1px solid #d0d0d0; + background: #fff; + margin-left: 10px; +} .price-calc-section .card .check-ip input[type=checkbox]{ font-size: 17px; margin: 0 8px; @@ -735,6 +759,10 @@ h6 { left: 50%; transform: translate(-50%, 0); } + + .intro-pricing .intro-message .section-heading { + font-size: 30px; + } } diff --git a/datacenterlight/templates/datacenterlight/order.html b/datacenterlight/templates/datacenterlight/order.html index ab224172..61ab149a 100644 --- a/datacenterlight/templates/datacenterlight/order.html +++ b/datacenterlight/templates/datacenterlight/order.html @@ -1,5 +1,7 @@ +{% load staticfiles i18n%} +{% get_current_language as LANGUAGE_CODE %} - + @@ -9,19 +11,24 @@ - Rails Hosting.ch - Ruby on Rails as easy as possible + datacenterlight.ch - Featherlight Swiss VM - + - - + + - - - - + + + + + + + + + @@ -36,7 +43,7 @@ +
- - - -
-
-
 
- -
-

-

Order Now

-

 

- -
-   -
- - - -
- -

 

- -
-
-   -
- - - -
-

VM size sliders to be inserted

- - -
- - -
-
- - -
- - -

-
    - -
 
-
-
-
- +
+

{% trans "We are cutting down the costs significantly!" %}

- - +
- + +
+
+ +
+
+ {% csrf_token %} + +
+

{% trans "VM hosting" %}

+
+
+ 15 + CHF +
+
+
+

{% trans "Hosted in Switzerland" %}

+
+
+ + + Core + +
+
+ + + GB RAM + +
+
+ + + {% trans "GB Storage (SSD)" %} + +
+ + +
+ + +
+ + + +
+ + +
+
+ + +
+
+ + +
+
+
+ +
+

{% trans "Simple and affordable: Try our virtual machine with featherlight price." %}

+ +
+

Our VMs are hosted in Glarus, Switzerland. WARNING: We are currently running in BETA mode, especially our website We hope you will not encounter any hiccups, but if you, please let us know at support@datacenterlight.ch

+
+
+
+ + +
- + + + + + - + + diff --git a/datacenterlight/templates/datacenterlight/pricing.html b/datacenterlight/templates/datacenterlight/pricing.html index 1674f82e..da13d5e1 100644 --- a/datacenterlight/templates/datacenterlight/pricing.html +++ b/datacenterlight/templates/datacenterlight/pricing.html @@ -1,7 +1,7 @@ {% load staticfiles i18n%} {% get_current_language as LANGUAGE_CODE %} - + @@ -141,7 +141,8 @@ -
+
+ +
+
+ + +
diff --git a/datacenterlight/templates/datacenterlight/success.html b/datacenterlight/templates/datacenterlight/success.html new file mode 100644 index 00000000..bf7f982a --- /dev/null +++ b/datacenterlight/templates/datacenterlight/success.html @@ -0,0 +1,134 @@ +{% load staticfiles i18n%} +{% get_current_language as LANGUAGE_CODE %} + + + + + + + + + + + + datacenterlight.ch - Featherlight Swiss VM + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+

{% trans "Thank you for order! Our team will contact you via email" %}

+ {% if LANGUAGE_CODE == 'en-us'%} +

{% trans "as soon as possible!" %}

+ {% endif %} +
+ +
+ + + + + + + + + + + + + diff --git a/datacenterlight/urls.py b/datacenterlight/urls.py index 9c3c84fb..c3f9f98d 100644 --- a/datacenterlight/urls.py +++ b/datacenterlight/urls.py @@ -1,6 +1,6 @@ from django.conf.urls import url -from .views import IndexView, BetaProgramView, LandingProgramView, BetaAccessView, PricingView +from .views import IndexView, BetaProgramView, LandingProgramView, BetaAccessView, PricingView, SuccessView, OrderView urlpatterns = [ @@ -8,5 +8,7 @@ urlpatterns = [ url(r'^/beta-program/?$', BetaProgramView.as_view(), name='beta'), url(r'^/landing/?$', LandingProgramView.as_view(), name='landing'), url(r'^/pricing/?$', PricingView.as_view(), name='pricing'), + url(r'^/order/?$', OrderView.as_view(), name='order'), + url(r'^/order-success/?$', SuccessView.as_view(), name='success'), url(r'^/beta_access?$', BetaAccessView.as_view(), name='beta_access'), ] diff --git a/datacenterlight/views.py b/datacenterlight/views.py index b68f7408..e2673f8c 100644 --- a/datacenterlight/views.py +++ b/datacenterlight/views.py @@ -14,6 +14,9 @@ from opennebula_api.serializers import VirtualMachineTemplateSerializer class LandingProgramView(TemplateView): template_name = "datacenterlight/landing.html" +class SuccessView(TemplateView): + template_name = "datacenterlight/success.html" + class PricingView(TemplateView): template_name = "datacenterlight/pricing.html" @@ -63,6 +66,54 @@ class PricingView(TemplateView): return redirect(reverse('hosting:payment')) +class OrderView(TemplateView): + template_name = "datacenterlight/order.html" + + def get(self, request, *args, **kwargs): + try: + manager = OpenNebulaManager() + templates = manager.get_templates() + + context = { + 'templates': VirtualMachineTemplateSerializer(templates, many=True).data, + } + except: + messages.error( request, + 'We could not load the VM templates due to a backend connection \ + error. Please try again in a few minutes' + ) + context = { + 'error' : 'connection' + } + + return render(request, self.template_name, context) + + + def post(self, request): + + cores = request.POST.get('cpu') + memory = request.POST.get('ram') + storage = request.POST.get('storage') + price = request.POST.get('total') + + template_id = int(request.POST.get('config')) + + manager = OpenNebulaManager() + template = manager.get_template(template_id) + + request.session['template'] = VirtualMachineTemplateSerializer(template).data + + if not request.user.is_authenticated(): + request.session['next'] = reverse('hosting:payment') + + request.session['specs'] = { + 'cpu':cores, + 'memory': memory, + 'disk_size': storage, + 'price': price, + } + + return redirect(reverse('hosting:payment')) class BetaAccessView(FormView): template_name = "datacenterlight/beta_access.html"