From 68c57b6e2abf8d7926a6731c4e4c9710fd9c784c Mon Sep 17 00:00:00 2001 From: minghansun1 Date: Wed, 23 Oct 2024 00:10:24 -0400 Subject: [PATCH] renamed sublet to market --- backend/{sublet => market}/__init__.py | 0 backend/{sublet => market}/admin.py | 2 +- backend/{sublet => market}/apps.py | 0 backend/{sublet => market}/migrations/0001_initial.py | 0 .../migrations/0002_auto_20240209_1649.py | 0 .../migrations/0003_alter_sublet_baths.py | 0 .../migrations/0004_alter_sublet_external_link.py | 0 backend/{sublet => market}/migrations/__init__.py | 0 backend/{sublet => market}/models.py | 0 backend/{sublet => market}/permissions.py | 0 backend/{sublet => market}/serializers.py | 2 +- backend/{sublet => market}/urls.py | 2 +- backend/{sublet => market}/views.py | 6 +++--- backend/tests/sublet/test_permissions.py | 2 +- backend/tests/sublet/test_sublets.py | 2 +- 15 files changed, 8 insertions(+), 8 deletions(-) rename backend/{sublet => market}/__init__.py (100%) rename backend/{sublet => market}/admin.py (88%) rename backend/{sublet => market}/apps.py (100%) rename backend/{sublet => market}/migrations/0001_initial.py (100%) rename backend/{sublet => market}/migrations/0002_auto_20240209_1649.py (100%) rename backend/{sublet => market}/migrations/0003_alter_sublet_baths.py (100%) rename backend/{sublet => market}/migrations/0004_alter_sublet_external_link.py (100%) rename backend/{sublet => market}/migrations/__init__.py (100%) rename backend/{sublet => market}/models.py (100%) rename backend/{sublet => market}/permissions.py (100%) rename backend/{sublet => market}/serializers.py (98%) rename backend/{sublet => market}/urls.py (98%) rename backend/{sublet => market}/views.py (98%) diff --git a/backend/sublet/__init__.py b/backend/market/__init__.py similarity index 100% rename from backend/sublet/__init__.py rename to backend/market/__init__.py diff --git a/backend/sublet/admin.py b/backend/market/admin.py similarity index 88% rename from backend/sublet/admin.py rename to backend/market/admin.py index 0dbdd521..db11398e 100644 --- a/backend/sublet/admin.py +++ b/backend/market/admin.py @@ -1,7 +1,7 @@ from django.contrib import admin from django.utils.html import mark_safe -from sublet.models import Amenity, Offer, Sublet, SubletImage +from market.models import Amenity, Offer, Sublet, SubletImage class SubletAdmin(admin.ModelAdmin): diff --git a/backend/sublet/apps.py b/backend/market/apps.py similarity index 100% rename from backend/sublet/apps.py rename to backend/market/apps.py diff --git a/backend/sublet/migrations/0001_initial.py b/backend/market/migrations/0001_initial.py similarity index 100% rename from backend/sublet/migrations/0001_initial.py rename to backend/market/migrations/0001_initial.py diff --git a/backend/sublet/migrations/0002_auto_20240209_1649.py b/backend/market/migrations/0002_auto_20240209_1649.py similarity index 100% rename from backend/sublet/migrations/0002_auto_20240209_1649.py rename to backend/market/migrations/0002_auto_20240209_1649.py diff --git a/backend/sublet/migrations/0003_alter_sublet_baths.py b/backend/market/migrations/0003_alter_sublet_baths.py similarity index 100% rename from backend/sublet/migrations/0003_alter_sublet_baths.py rename to backend/market/migrations/0003_alter_sublet_baths.py diff --git a/backend/sublet/migrations/0004_alter_sublet_external_link.py b/backend/market/migrations/0004_alter_sublet_external_link.py similarity index 100% rename from backend/sublet/migrations/0004_alter_sublet_external_link.py rename to backend/market/migrations/0004_alter_sublet_external_link.py diff --git a/backend/sublet/migrations/__init__.py b/backend/market/migrations/__init__.py similarity index 100% rename from backend/sublet/migrations/__init__.py rename to backend/market/migrations/__init__.py diff --git a/backend/sublet/models.py b/backend/market/models.py similarity index 100% rename from backend/sublet/models.py rename to backend/market/models.py diff --git a/backend/sublet/permissions.py b/backend/market/permissions.py similarity index 100% rename from backend/sublet/permissions.py rename to backend/market/permissions.py diff --git a/backend/sublet/serializers.py b/backend/market/serializers.py similarity index 98% rename from backend/sublet/serializers.py rename to backend/market/serializers.py index 68a9ac6c..c8967cde 100644 --- a/backend/sublet/serializers.py +++ b/backend/market/serializers.py @@ -2,7 +2,7 @@ from profanity_check import predict from rest_framework import serializers -from sublet.models import Amenity, Offer, Sublet, SubletImage +from market.models import Amenity, Offer, Sublet, SubletImage class AmenitySerializer(serializers.ModelSerializer): diff --git a/backend/sublet/urls.py b/backend/market/urls.py similarity index 98% rename from backend/sublet/urls.py rename to backend/market/urls.py index edfde8bf..14efe102 100644 --- a/backend/sublet/urls.py +++ b/backend/market/urls.py @@ -1,7 +1,7 @@ from django.urls import path from rest_framework import routers -from sublet.views import ( +from market.views import ( Amenities, CreateImages, DeleteImage, diff --git a/backend/sublet/views.py b/backend/market/views.py similarity index 98% rename from backend/sublet/views.py rename to backend/market/views.py index cb37c2df..3ed13409 100644 --- a/backend/sublet/views.py +++ b/backend/market/views.py @@ -8,14 +8,14 @@ from rest_framework.response import Response from pennmobile.analytics import Metric, record_analytics -from sublet.models import Amenity, Offer, Sublet, SubletImage -from sublet.permissions import ( +from market.models import Amenity, Offer, Sublet, SubletImage +from market.permissions import ( IsSuperUser, OfferOwnerPermission, SubletImageOwnerPermission, SubletOwnerPermission, ) -from sublet.serializers import ( +from market.serializers import ( AmenitySerializer, OfferSerializer, SubletImageSerializer, diff --git a/backend/tests/sublet/test_permissions.py b/backend/tests/sublet/test_permissions.py index 39a26c5b..0cc5c530 100644 --- a/backend/tests/sublet/test_permissions.py +++ b/backend/tests/sublet/test_permissions.py @@ -4,7 +4,7 @@ from django.test import TestCase from rest_framework.test import APIClient -from sublet.models import Amenity, Sublet +from market.models import Amenity, Sublet User = get_user_model() diff --git a/backend/tests/sublet/test_sublets.py b/backend/tests/sublet/test_sublets.py index 793fc5f9..88ad7cf5 100644 --- a/backend/tests/sublet/test_sublets.py +++ b/backend/tests/sublet/test_sublets.py @@ -6,7 +6,7 @@ from django.test import TestCase from rest_framework.test import APIClient -from sublet.models import Amenity, Offer, Sublet, SubletImage +from market.models import Amenity, Offer, Sublet, SubletImage User = get_user_model()