From fc1ddbdd3b51c4f56e7360e96ff15f2e772f4621 Mon Sep 17 00:00:00 2001 From: PCoder Date: Thu, 17 Aug 2017 04:22:23 +0530 Subject: [PATCH] Added StripePlan model --- datacenterlight/models.py | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/datacenterlight/models.py b/datacenterlight/models.py index fdfebc96..d8237ed2 100644 --- a/datacenterlight/models.py +++ b/datacenterlight/models.py @@ -59,3 +59,15 @@ class VMTemplate(models.Model): def create(cls, name, opennebula_vm_template_id): vm_template = cls(name=name, opennebula_vm_template_id=opennebula_vm_template_id) return vm_template + + +class StripePlan(models.Model): + """ + A model to store Data Center Light's created Stripe plans + """ + stripe_plan_id = models.CharField(max_length=100, null=True) + + @classmethod + def create(cls, stripe_plan_id): + stripe_plan = cls(stripe_plan_id=stripe_plan_id) + return stripe_plan