This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import datetime | |
| from dateutil.relativedelta import relativedelta | |
| from dateutil.rrule import rrule, MONTHLY | |
| today = datetime.datetime.today() | |
| end1 = today + relativedelta(years=1) | |
| end2 = today + relativedelta(years=2) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| from .base_model import BaseModel | |
| from ..extensions import db | |
| from .classes.foreign_key_cascade import ForeignKeyCascade | |
| # Association table between Payment and Subscription | |
| payment_subscription = db.Table( | |
| 'payment_subscription', | |
| db.Column('payment_id', db.Integer, db.ForeignKey('payment.id'), primary_key=True), | |
| db.Column('subscription_id', db.Integer, db.ForeignKey('subscription.id'), | |
| primary_key=True) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| from os import environ | |
| from logging.config import dictConfig | |
| from werkzeug.security import generate_password_hash | |
| class BaseConfig(object): | |
| def _config_logger(self): | |
| """ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| class ExampleParent(object): | |
| def run(self, *args, **kwargs): | |
| print(args[0]) | |
| print(kwargs['a']) | |
| class ExampleChild(ExampleParent): |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| def upload(line): | |
| """ | |
| Executes some operation using a dict and returns some output | |
| This is where the Eloqua POST function would go, | |
| I haven't implemented anything | |
| :param line: | |
| :return: | |
| """ | |
| raise NotImplementedError |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| def upload(line): | |
| """ | |
| Executes some operation using a dict and returns some output | |
| This is where the Eloqua POST function would go, | |
| I haven't implemented anything | |
| :param line: | |
| :return: | |
| """ | |
| return list(line.values()) |
OlderNewer