Auto-generate the pricing table from the database #4
No reviewers
Labels
No Label
No Milestone
No Assignees
3 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: 3wordchant/capsul-flask#4
Loading…
Reference in New Issue
Block a user
No description provided.
Delete Branch "generated-prices"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
All the information that's displayed on the "Pricing" page lives in the database.
Loading the VM sizes from the DB, like the supported operating systems, means less repeating-yourself: if you change the size options in the database, it'll immediately update the pricing page.
I went with a table because I couldn't work out how to do precise text alignment within the
<pre>
tags using Jinja, but there probably is a way. Anyway, it looks a little different:I used the already-existing
<table class="small">
style.💯
@ -9,0 +25,4 @@
<td>${{ vm_size['dollars_per_month'] }}</td>
<td>{{ vm_size['vcpus'] }}</td>
<td>{{ vm_size['memory_mb'] }}</td>
<td>25G</td>
Still hard-coded?
Ah yes, correction:
I'm forest johnson and I approve this message