1
0
Fork 0
This repository has been archived on 2024-02-17. You can view files and clone it, but cannot push or open issues or pull requests.
Administrator-py/db/WarnAction.py

19 lines
599 B
Python

from datetime import timedelta
from db import Base
from sqlalchemy import Column, Integer, BigInteger, String
class WarnAction(Base):
__tablename__ = "warn_actions"
id = Column(Integer, primary_key=True)
guild = Column(BigInteger, nullable=False)
count = Column(Integer, nullable=False, unique=True)
action = Column(String, nullable=False)
duration = Column(BigInteger)
def __init__(self, guild: int, count: int, action: str, duration: float = None):
self.guild = guild
self.count = count
self.action = action
self.duration = duration