country model

This commit is contained in:
CHIEFSOFT\ameye
2025-10-06 06:02:24 -04:00
parent 2558b51aa4
commit 3d4fbba98e
7 changed files with 322 additions and 7 deletions
+7
View File
@@ -22,6 +22,13 @@ class Country(db.Model):
return None
return country_list
@classmethod
def get_all_countries(cls):
country_list = cls.query.all()
if not country_list:
return None
return country_list
def to_dict(self):
return {
"id": self.id,