rearranging text

This commit is contained in:
Arvind Tiwari 2017-09-21 02:50:07 +05:30
parent dd77f40707
commit 6dfbf67d7d
2 changed files with 79 additions and 70 deletions

View file

@ -23,41 +23,40 @@
<button class="btn-plain"><img src="{% static 'hosting/img/icon-print.svg' %}" class="svg-img"></button> <button class="btn-plain"><img src="{% static 'hosting/img/icon-print.svg' %}" class="svg-img"></button>
</div> </div>
</div> </div>
<div class="invoice-title"> <div class="order-details">
<h3> {% if order %}
{% trans "Order #"%} {{order.id}} <div>
</h3> <strong>{% trans "Order #"%} {{order.id}}</strong>
</div> </div>
<div class="row"> {% endif %}
<div class="col-xs-12 col-md-6 pull-right order-confirm-date"> <div>
<address> <strong>{% trans "Invoice Date"%}:</strong>
<strong>{% trans "Date"%}:</strong><br>
<span id="order-created_at"> <span id="order-created_at">
{% if order %} {% if order %}
{{order.created_at|date:'Y-m-d H:i'}} {{order.created_at|date:'Y-m-d H:i'}}
{% else %} {% else %}
{% now "Y-m-d H:i" %} {% now "Y-m-d H:i" %}
{% endif %} {% endif %}
</span><br><br> </span>
{% if order %}
<strong>{% trans "Status:"%}</strong><br>
{% if order.status == 'Approved' %}
<strong class="text-success">
{% trans "Approved" %}
</strong>
{% else %}
<strong class="text-danger">
{% trans "Declined" %}
</strong>
{% endif %}
<br><br>
{% endif %}
</address>
</div> </div>
<div class="col-xs-12 col-md-6"> {% if order %}
{% endif %}
<div>
<strong>{% trans "Status" %}: </strong>
<strong>
{% if order.status == 'Approved' %}
<span class="vm-status-active">{% trans "Approved" %}</span>
{% else %}
<span class="vm-status-failed">{% trans "Declined" %}</span>
{% endif %}
</strong>
</div>
<hr>
<div>
<address> <address>
<h3><b>{% trans "Billed To:"%}</b></h3> <h4>{% trans "Billed to" %}:</h4>
<div>
{% if order %} {% if order %}
{{user.name}}<br> {{user.name}}<br>
{{order.billing_address.street_address}},{{order.billing_address.postal_code}}<br> {{order.billing_address.street_address}},{{order.billing_address.postal_code}}<br>
@ -72,14 +71,13 @@
{{billing_address.country}}. {{billing_address.country}}.
{% endwith %} {% endwith %}
{% endif %} {% endif %}
</div>
</address> </address>
</div> </div>
<hr>
</div> <div>
<div class="row"> <h4>{% trans "Payment method" %}:</h4>
<div class="col-xs-6"> <div>
<address>
<strong>{% trans "Payment Method:"%}</strong><br>
{% if order %} {% if order %}
{{order.cc_brand}} {% trans "ending in" %} **** {{order.cc_brand}} {% trans "ending in" %} ****
{{order.last4}}<br> {{order.last4}}<br>
@ -89,15 +87,24 @@
{{cc_last4}}<br> {{cc_last4}}<br>
{{request.session.user.email}} {{request.session.user.email}}
{% endif %} {% endif %}
</address> </div>
</div>
<div>
<h4>{% trans "Order summary"%}</h4>
<div>
{% if request.session.specs %}
{% request.session.specs as vm %}
{% endif %}
<strong>{% trans "Product" %}:</strong> {{request.session.template.name}}
</div> </div>
</div> </div>
<h3><b>{% trans "Order summary"%}</b></h3> </div>
<h3><b></b></h3>
<hr> <hr>
<div class="content"> <div class="content">
{% if request.session.specs %}
{% with request.session.specs as vm %}
<p><b>{% trans "Cores"%}</b> <p><b>{% trans "Cores"%}</b>
<span class="pull-right">{{vm.cpu}}</span> <span class="pull-right">{{vm.cpu}}</span>
</p> </p>
@ -195,7 +202,7 @@
<script type="text/javascript"> <script type="text/javascript">
{% trans "Some problem encountered. Please try again later." as err_msg %} {% trans "Some problem encountered. Please try again later." as err_msg %}
var create_vm_error_message = '{{err_msg|safe}}.'; var create_vm_error_message = '{{err_msg|safe}}';
window.onload = function () { window.onload = function () {
var locale_date = moment.utc(document.getElementById("order-created_at").textContent, 'YYYY-MM-DD HH:mm').toDate(); var locale_date = moment.utc(document.getElementById("order-created_at").textContent, 'YYYY-MM-DD HH:mm').toDate();

View file

@ -41,13 +41,15 @@
<td data-header="IPv6">{{vm.ipv6}}</td> <td data-header="IPv6">{{vm.ipv6}}</td>
{% endif %} {% endif %}
<td data-header="{% trans 'Status' %}"> <td data-header="{% trans 'Status' %}">
<strong>
{% if vm.state == 'ACTIVE' %} {% if vm.state == 'ACTIVE' %}
<span class="vm-status-active"><strong>{{vm.state|title}}</strong></span> <span class="vm-status-active">{{vm.state|title}}</span>
{% elif vm.state == 'FAILED' %} {% elif vm.state == 'FAILED' %}
<span class="vm-status-failed"><strong>{{vm.state|title}}</strong></span> <span class="vm-status-failed">{{vm.state|title}}</span>
{% else %} {% else %}
<span class="vm-status"><strong>{{vm.state|title}}</strong></span> <span class="vm-status">{{vm.state|title}}</span>
{% endif %} {% endif %}
</strong>
</td> </td>
<td class="text-right last-td"> <td class="text-right last-td">
<a class="btn btn-vm-detail" href="{% url 'hosting:virtual_machines' vm.vm_id %}">{% trans "View Detail" %}</a> <a class="btn btn-vm-detail" href="{% url 'hosting:virtual_machines' vm.vm_id %}">{% trans "View Detail" %}</a>