From acd2b332b16c9f1d1298ff04d0ff6b0160b69fb4 Mon Sep 17 00:00:00 2001 From: LiamDes Date: Thu, 27 Apr 2023 13:34:26 -0700 Subject: [PATCH] lab05 pokedex! --- .../pokedex-main/pokedex-main/.gitignore | 129 ++ .../django/pokedex-main/pokedex-main/Pipfile | 12 + .../pokedex-main/pokedex-main/Pipfile.lock | 52 + .../pokedex-main/pokedex-main/README.md | 20 + .../pokedex-main/pokedex-main/api/__init__.py | 0 .../pokedex-main/pokedex-main/api/admin.py | 3 + .../pokedex-main/pokedex-main/api/apps.py | 6 + .../pokedex-main/api/migrations/__init__.py | 0 .../pokedex-main/pokedex-main/api/models.py | 3 + .../pokedex-main/api/serializers.py | 26 + .../pokedex-main/pokedex-main/api/tests.py | 3 + .../pokedex-main/pokedex-main/api/urls.py | 10 + .../pokedex-main/pokedex-main/api/views.py | 29 + .../pokedex-main/pokedex-main/manage.py | 22 + .../pokedex-main/pokedex_project/__init__.py | 0 .../pokedex-main/pokedex_project/asgi.py | 16 + .../pokedex-main/pokedex_project/settings.py | 138 ++ .../pokedex-main/pokedex_project/urls.py | 26 + .../pokedex-main/pokedex_project/wsgi.py | 16 + .../pokedex-main/pokedex-main/pokemon.json | 1883 +++++++++++++++++ .../pokedex-main/pokemon/__init__.py | 0 .../pokedex-main/pokemon/admin.py | 6 + .../pokedex-main/pokedex-main/pokemon/apps.py | 6 + .../management/commands/load_pokemon.py | 40 + .../pokemon/migrations/0001_initial.py | 37 + .../pokemon/migrations/__init__.py | 0 .../pokedex-main/pokemon/models.py | 23 + .../pokedex-main/pokemon/tests.py | 3 + .../pokedex-main/pokemon/views.py | 3 + .../pokedex-main/static/js/app.js | 69 + .../pokedex-main/pokedex-main/static/main.css | 238 +++ .../pokedex-main/static/media/caught.png | Bin 0 -> 35313 bytes .../pokedex-main/templates/home.html | 77 + .../templates/registration/login.html | 6 + .../templates/registration/signup.html | 6 + .../pokedex-main/users/__init__.py | 0 .../pokedex-main/pokedex-main/users/admin.py | 13 + .../pokedex-main/pokedex-main/users/apps.py | 6 + .../pokedex-main/pokedex-main/users/forms.py | 13 + .../users/migrations/0001_initial.py | 44 + .../pokedex-main/users/migrations/__init__.py | 0 .../pokedex-main/pokedex-main/users/models.py | 12 + .../pokedex-main/pokedex-main/users/tests.py | 3 + .../pokedex-main/pokedex-main/users/urls.py | 8 + .../pokedex-main/pokedex-main/users/views.py | 9 + .../liam/django/pokedex-main/requirements.txt | 4 + 46 files changed, 3020 insertions(+) create mode 100644 code/liam/django/pokedex-main/pokedex-main/.gitignore create mode 100644 code/liam/django/pokedex-main/pokedex-main/Pipfile create mode 100644 code/liam/django/pokedex-main/pokedex-main/Pipfile.lock create mode 100644 code/liam/django/pokedex-main/pokedex-main/README.md create mode 100644 code/liam/django/pokedex-main/pokedex-main/api/__init__.py create mode 100644 code/liam/django/pokedex-main/pokedex-main/api/admin.py create mode 100644 code/liam/django/pokedex-main/pokedex-main/api/apps.py create mode 100644 code/liam/django/pokedex-main/pokedex-main/api/migrations/__init__.py create mode 100644 code/liam/django/pokedex-main/pokedex-main/api/models.py create mode 100644 code/liam/django/pokedex-main/pokedex-main/api/serializers.py create mode 100644 code/liam/django/pokedex-main/pokedex-main/api/tests.py create mode 100644 code/liam/django/pokedex-main/pokedex-main/api/urls.py create mode 100644 code/liam/django/pokedex-main/pokedex-main/api/views.py create mode 100644 code/liam/django/pokedex-main/pokedex-main/manage.py create mode 100644 code/liam/django/pokedex-main/pokedex-main/pokedex_project/__init__.py create mode 100644 code/liam/django/pokedex-main/pokedex-main/pokedex_project/asgi.py create mode 100644 code/liam/django/pokedex-main/pokedex-main/pokedex_project/settings.py create mode 100644 code/liam/django/pokedex-main/pokedex-main/pokedex_project/urls.py create mode 100644 code/liam/django/pokedex-main/pokedex-main/pokedex_project/wsgi.py create mode 100644 code/liam/django/pokedex-main/pokedex-main/pokemon.json create mode 100644 code/liam/django/pokedex-main/pokedex-main/pokemon/__init__.py create mode 100644 code/liam/django/pokedex-main/pokedex-main/pokemon/admin.py create mode 100644 code/liam/django/pokedex-main/pokedex-main/pokemon/apps.py create mode 100644 code/liam/django/pokedex-main/pokedex-main/pokemon/management/commands/load_pokemon.py create mode 100644 code/liam/django/pokedex-main/pokedex-main/pokemon/migrations/0001_initial.py create mode 100644 code/liam/django/pokedex-main/pokedex-main/pokemon/migrations/__init__.py create mode 100644 code/liam/django/pokedex-main/pokedex-main/pokemon/models.py create mode 100644 code/liam/django/pokedex-main/pokedex-main/pokemon/tests.py create mode 100644 code/liam/django/pokedex-main/pokedex-main/pokemon/views.py create mode 100644 code/liam/django/pokedex-main/pokedex-main/static/js/app.js create mode 100644 code/liam/django/pokedex-main/pokedex-main/static/main.css create mode 100644 code/liam/django/pokedex-main/pokedex-main/static/media/caught.png create mode 100644 code/liam/django/pokedex-main/pokedex-main/templates/home.html create mode 100644 code/liam/django/pokedex-main/pokedex-main/templates/registration/login.html create mode 100644 code/liam/django/pokedex-main/pokedex-main/templates/registration/signup.html create mode 100644 code/liam/django/pokedex-main/pokedex-main/users/__init__.py create mode 100644 code/liam/django/pokedex-main/pokedex-main/users/admin.py create mode 100644 code/liam/django/pokedex-main/pokedex-main/users/apps.py create mode 100644 code/liam/django/pokedex-main/pokedex-main/users/forms.py create mode 100644 code/liam/django/pokedex-main/pokedex-main/users/migrations/0001_initial.py create mode 100644 code/liam/django/pokedex-main/pokedex-main/users/migrations/__init__.py create mode 100644 code/liam/django/pokedex-main/pokedex-main/users/models.py create mode 100644 code/liam/django/pokedex-main/pokedex-main/users/tests.py create mode 100644 code/liam/django/pokedex-main/pokedex-main/users/urls.py create mode 100644 code/liam/django/pokedex-main/pokedex-main/users/views.py create mode 100644 code/liam/django/pokedex-main/requirements.txt diff --git a/code/liam/django/pokedex-main/pokedex-main/.gitignore b/code/liam/django/pokedex-main/pokedex-main/.gitignore new file mode 100644 index 00000000..b6e47617 --- /dev/null +++ b/code/liam/django/pokedex-main/pokedex-main/.gitignore @@ -0,0 +1,129 @@ +# Byte-compiled / optimized / DLL files +__pycache__/ +*.py[cod] +*$py.class + +# C extensions +*.so + +# Distribution / packaging +.Python +build/ +develop-eggs/ +dist/ +downloads/ +eggs/ +.eggs/ +lib/ +lib64/ +parts/ +sdist/ +var/ +wheels/ +pip-wheel-metadata/ +share/python-wheels/ +*.egg-info/ +.installed.cfg +*.egg +MANIFEST + +# PyInstaller +# Usually these files are written by a python script from a template +# before PyInstaller builds the exe, so as to inject date/other infos into it. +*.manifest +*.spec + +# Installer logs +pip-log.txt +pip-delete-this-directory.txt + +# Unit test / coverage reports +htmlcov/ +.tox/ +.nox/ +.coverage +.coverage.* +.cache +nosetests.xml +coverage.xml +*.cover +*.py,cover +.hypothesis/ +.pytest_cache/ + +# Translations +*.mo +*.pot + +# Django stuff: +*.log +local_settings.py +db.sqlite3 +db.sqlite3-journal + +# Flask stuff: +instance/ +.webassets-cache + +# Scrapy stuff: +.scrapy + +# Sphinx documentation +docs/_build/ + +# PyBuilder +target/ + +# Jupyter Notebook +.ipynb_checkpoints + +# IPython +profile_default/ +ipython_config.py + +# pyenv +.python-version + +# pipenv +# According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control. +# However, in case of collaboration, if having platform-specific dependencies or dependencies +# having no cross-platform support, pipenv may install dependencies that don't work, or not +# install all needed dependencies. +#Pipfile.lock + +# PEP 582; used by e.g. github.com/David-OConnor/pyflow +__pypackages__/ + +# Celery stuff +celerybeat-schedule +celerybeat.pid + +# SageMath parsed files +*.sage.py + +# Environments +.env +.venv +env/ +venv/ +ENV/ +env.bak/ +venv.bak/ + +# Spyder project settings +.spyderproject +.spyproject + +# Rope project settings +.ropeproject + +# mkdocs documentation +/site + +# mypy +.mypy_cache/ +.dmypy.json +dmypy.json + +# Pyre type checker +.pyre/ diff --git a/code/liam/django/pokedex-main/pokedex-main/Pipfile b/code/liam/django/pokedex-main/pokedex-main/Pipfile new file mode 100644 index 00000000..70309f7a --- /dev/null +++ b/code/liam/django/pokedex-main/pokedex-main/Pipfile @@ -0,0 +1,12 @@ +[[source]] +name = "pypi" +url = "https://pypi.org/simple" +verify_ssl = true + +[dev-packages] + +[packages] +django = "==3.2" + +[requires] +python_version = "3.8" diff --git a/code/liam/django/pokedex-main/pokedex-main/Pipfile.lock b/code/liam/django/pokedex-main/pokedex-main/Pipfile.lock new file mode 100644 index 00000000..8e3522a5 --- /dev/null +++ b/code/liam/django/pokedex-main/pokedex-main/Pipfile.lock @@ -0,0 +1,52 @@ +{ + "_meta": { + "hash": { + "sha256": "19cfd5e42f57f56005b157dfa0339f9e877fea0cd51b016c55791df6db128462" + }, + "pipfile-spec": 6, + "requires": { + "python_version": "3.8" + }, + "sources": [ + { + "name": "pypi", + "url": "https://pypi.org/simple", + "verify_ssl": true + } + ] + }, + "default": { + "asgiref": { + "hashes": [ + "sha256:4ef1ab46b484e3c706329cedeff284a5d40824200638503f5768edb6de7d58e9", + "sha256:ffc141aa908e6f175673e7b1b3b7af4fdb0ecb738fc5c8b88f69f055c2415214" + ], + "markers": "python_version >= '3.6'", + "version": "==3.4.1" + }, + "django": { + "hashes": [ + "sha256:0604e84c4fb698a5e53e5857b5aea945b2f19a18f25f10b8748dbdf935788927", + "sha256:21f0f9643722675976004eb683c55d33c05486f94506672df3d6a141546f389d" + ], + "index": "pypi", + "version": "==3.2" + }, + "pytz": { + "hashes": [ + "sha256:83a4a90894bf38e243cf052c8b58f381bfe9a7a483f6a9cab140bc7f702ac4da", + "sha256:eb10ce3e7736052ed3623d49975ce333bcd712c7bb19a58b9e2089d4057d0798" + ], + "version": "==2021.1" + }, + "sqlparse": { + "hashes": [ + "sha256:017cde379adbd6a1f15a61873f43e8274179378e95ef3fede90b5aa64d304ed0", + "sha256:0f91fd2e829c44362cbcfab3e9ae12e22badaa8a29ad5ff599f9ec109f0454e8" + ], + "markers": "python_version >= '3.5'", + "version": "==0.4.1" + } + }, + "develop": {} +} diff --git a/code/liam/django/pokedex-main/pokedex-main/README.md b/code/liam/django/pokedex-main/pokedex-main/README.md new file mode 100644 index 00000000..3e5db93e --- /dev/null +++ b/code/liam/django/pokedex-main/pokedex-main/README.md @@ -0,0 +1,20 @@ +# Pokedex Starter + +## Installation + +Make sure you have Python and Pipenv installed on your computer. + +Download the repo and save it to your code folder in the class repo. *make sure you download it, don't clone it or it won't upload to the class repo correctly* + +If you are not running Python 3.8, edit the last line of the `Pipfile` to refer to your version instead. + +Navigate to the pokedex folder in the terminal and do the following: + +- `pipenv install` Create the virtual enviroment and install dependencies. +- `pipenv shell` Enter the new virtual enviroment. +- `python manage.py migrate users` Migrate the user model. *this django project uses a custom user model, you MUST migrate the users app before migrating the rest!* +- `python manage.py migrate` Migrate all other models. +- `python manage.py createsuperuser` Create yourself a super user. +- `python manage.py load_pokemon` Load Pokemon into the database. + +You're good to go! This Django project comes with a database full of Pokemon, login/logout/registration pages, and a `home.html` template for you to create your Vue app. diff --git a/code/liam/django/pokedex-main/pokedex-main/api/__init__.py b/code/liam/django/pokedex-main/pokedex-main/api/__init__.py new file mode 100644 index 00000000..e69de29b diff --git a/code/liam/django/pokedex-main/pokedex-main/api/admin.py b/code/liam/django/pokedex-main/pokedex-main/api/admin.py new file mode 100644 index 00000000..8c38f3f3 --- /dev/null +++ b/code/liam/django/pokedex-main/pokedex-main/api/admin.py @@ -0,0 +1,3 @@ +from django.contrib import admin + +# Register your models here. diff --git a/code/liam/django/pokedex-main/pokedex-main/api/apps.py b/code/liam/django/pokedex-main/pokedex-main/api/apps.py new file mode 100644 index 00000000..66656fd2 --- /dev/null +++ b/code/liam/django/pokedex-main/pokedex-main/api/apps.py @@ -0,0 +1,6 @@ +from django.apps import AppConfig + + +class ApiConfig(AppConfig): + default_auto_field = 'django.db.models.BigAutoField' + name = 'api' diff --git a/code/liam/django/pokedex-main/pokedex-main/api/migrations/__init__.py b/code/liam/django/pokedex-main/pokedex-main/api/migrations/__init__.py new file mode 100644 index 00000000..e69de29b diff --git a/code/liam/django/pokedex-main/pokedex-main/api/models.py b/code/liam/django/pokedex-main/pokedex-main/api/models.py new file mode 100644 index 00000000..71a83623 --- /dev/null +++ b/code/liam/django/pokedex-main/pokedex-main/api/models.py @@ -0,0 +1,3 @@ +from django.db import models + +# Create your models here. diff --git a/code/liam/django/pokedex-main/pokedex-main/api/serializers.py b/code/liam/django/pokedex-main/pokedex-main/api/serializers.py new file mode 100644 index 00000000..6dee6fad --- /dev/null +++ b/code/liam/django/pokedex-main/pokedex-main/api/serializers.py @@ -0,0 +1,26 @@ +from rest_framework import serializers +from pokemon.models import Pokemon, Type +from users.models import CustomUser + +class TypeSerializer(serializers.ModelSerializer): + class Meta: + model = Type + fields = ['id', 'type'] + +class PokemonSerializer(serializers.ModelSerializer): + + types = TypeSerializer( + many=True, + read_only=True, + ) + + class Meta: + model = Pokemon + fields = ['id', 'number', 'name', 'height', 'weight', + 'image_front', 'image_back', 'caught_by', + 'types'] + +class UserSerializer(serializers.ModelSerializer): + class Meta: + model = CustomUser + fields = ['username', 'id', 'caught'] \ No newline at end of file diff --git a/code/liam/django/pokedex-main/pokedex-main/api/tests.py b/code/liam/django/pokedex-main/pokedex-main/api/tests.py new file mode 100644 index 00000000..7ce503c2 --- /dev/null +++ b/code/liam/django/pokedex-main/pokedex-main/api/tests.py @@ -0,0 +1,3 @@ +from django.test import TestCase + +# Create your tests here. diff --git a/code/liam/django/pokedex-main/pokedex-main/api/urls.py b/code/liam/django/pokedex-main/pokedex-main/api/urls.py new file mode 100644 index 00000000..0aa7b8b5 --- /dev/null +++ b/code/liam/django/pokedex-main/pokedex-main/api/urls.py @@ -0,0 +1,10 @@ +from django.urls import path +from .views import * +from . import views + +urlpatterns = [ + path('', PokemonAPIView.as_view()), + path('users/', UserView.as_view()), + path('user//', UserDetail.as_view()), + path('current/', views.current_user, name='current_user'), +] \ No newline at end of file diff --git a/code/liam/django/pokedex-main/pokedex-main/api/views.py b/code/liam/django/pokedex-main/pokedex-main/api/views.py new file mode 100644 index 00000000..e4827c1e --- /dev/null +++ b/code/liam/django/pokedex-main/pokedex-main/api/views.py @@ -0,0 +1,29 @@ +from rest_framework import generics +from pokemon.models import Pokemon, Type +from users.models import CustomUser +from .serializers import PokemonSerializer, TypeSerializer, UserSerializer +from rest_framework import permissions +from rest_framework.decorators import api_view +from rest_framework.response import Response + +# Create your views here. + +class PokemonAPIView(generics.ListAPIView): + permission_class = permissions.IsAuthenticated + serializer_class = PokemonSerializer + queryset = Pokemon.objects.all() + +class UserView(generics.ListAPIView): + permission_class = permissions.IsAuthenticated + serializer_class = UserSerializer + queryset = CustomUser.objects.all() + +class UserDetail(generics.RetrieveUpdateDestroyAPIView): + permission_class = permissions.IsAuthenticated + queryset = CustomUser.objects.all() + serializer_class = UserSerializer + +@api_view(['GET']) +def current_user(request): + serializer = UserSerializer(request.user) + return Response(serializer.data) \ No newline at end of file diff --git a/code/liam/django/pokedex-main/pokedex-main/manage.py b/code/liam/django/pokedex-main/pokedex-main/manage.py new file mode 100644 index 00000000..ec23cc29 --- /dev/null +++ b/code/liam/django/pokedex-main/pokedex-main/manage.py @@ -0,0 +1,22 @@ +#!/usr/bin/env python +"""Django's command-line utility for administrative tasks.""" +import os +import sys + + +def main(): + """Run administrative tasks.""" + os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'pokedex_project.settings') + try: + from django.core.management import execute_from_command_line + except ImportError as exc: + raise ImportError( + "Couldn't import Django. Are you sure it's installed and " + "available on your PYTHONPATH environment variable? Did you " + "forget to activate a virtual environment?" + ) from exc + execute_from_command_line(sys.argv) + + +if __name__ == '__main__': + main() diff --git a/code/liam/django/pokedex-main/pokedex-main/pokedex_project/__init__.py b/code/liam/django/pokedex-main/pokedex-main/pokedex_project/__init__.py new file mode 100644 index 00000000..e69de29b diff --git a/code/liam/django/pokedex-main/pokedex-main/pokedex_project/asgi.py b/code/liam/django/pokedex-main/pokedex-main/pokedex_project/asgi.py new file mode 100644 index 00000000..f9a43b50 --- /dev/null +++ b/code/liam/django/pokedex-main/pokedex-main/pokedex_project/asgi.py @@ -0,0 +1,16 @@ +""" +ASGI config for pokedex_project project. + +It exposes the ASGI callable as a module-level variable named ``application``. + +For more information on this file, see +https://docs.djangoproject.com/en/3.2/howto/deployment/asgi/ +""" + +import os + +from django.core.asgi import get_asgi_application + +os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'pokedex_project.settings') + +application = get_asgi_application() diff --git a/code/liam/django/pokedex-main/pokedex-main/pokedex_project/settings.py b/code/liam/django/pokedex-main/pokedex-main/pokedex_project/settings.py new file mode 100644 index 00000000..d247b1ad --- /dev/null +++ b/code/liam/django/pokedex-main/pokedex-main/pokedex_project/settings.py @@ -0,0 +1,138 @@ +""" +Django settings for pokedex_project project. + +Generated by 'django-admin startproject' using Django 3.2. + +For more information on this file, see +https://docs.djangoproject.com/en/3.2/topics/settings/ + +For the full list of settings and their values, see +https://docs.djangoproject.com/en/3.2/ref/settings/ +""" + +from pathlib import Path + +# Build paths inside the project like this: BASE_DIR / 'subdir'. +BASE_DIR = Path(__file__).resolve().parent.parent + + +# Quick-start development settings - unsuitable for production +# See https://docs.djangoproject.com/en/3.2/howto/deployment/checklist/ + +# SECURITY WARNING: keep the secret key used in production secret! +SECRET_KEY = 'django-insecure-d^eg$3s_wy81)7qwig*8s#1u+zbi^7&h*id_qcfw@^4lra-@b2' + +# SECURITY WARNING: don't run with debug turned on in production! +DEBUG = True + +ALLOWED_HOSTS = [] + + +# Application definition + +INSTALLED_APPS = [ + 'django.contrib.admin', + 'django.contrib.auth', + 'django.contrib.contenttypes', + 'django.contrib.sessions', + 'django.contrib.messages', + 'django.contrib.staticfiles', + + 'pokemon.apps.PokemonConfig', + 'users.apps.UsersConfig', + 'api.apps.ApiConfig', + 'rest_framework' +] + +MIDDLEWARE = [ + 'django.middleware.security.SecurityMiddleware', + 'django.contrib.sessions.middleware.SessionMiddleware', + 'django.middleware.common.CommonMiddleware', + 'django.middleware.csrf.CsrfViewMiddleware', + 'django.contrib.auth.middleware.AuthenticationMiddleware', + 'django.contrib.messages.middleware.MessageMiddleware', + 'django.middleware.clickjacking.XFrameOptionsMiddleware', +] + +ROOT_URLCONF = 'pokedex_project.urls' + +TEMPLATES = [ + { + 'BACKEND': 'django.template.backends.django.DjangoTemplates', + 'DIRS': [BASE_DIR / 'templates'], + 'APP_DIRS': True, + 'OPTIONS': { + 'context_processors': [ + 'django.template.context_processors.debug', + 'django.template.context_processors.request', + 'django.contrib.auth.context_processors.auth', + 'django.contrib.messages.context_processors.messages', + ], + }, + }, +] + +WSGI_APPLICATION = 'pokedex_project.wsgi.application' + + +# Database +# https://docs.djangoproject.com/en/3.2/ref/settings/#databases + +DATABASES = { + 'default': { + 'ENGINE': 'django.db.backends.sqlite3', + 'NAME': BASE_DIR / 'db.sqlite3', + } +} + + +# Password validation +# https://docs.djangoproject.com/en/3.2/ref/settings/#auth-password-validators + +AUTH_PASSWORD_VALIDATORS = [ + { + 'NAME': 'django.contrib.auth.password_validation.UserAttributeSimilarityValidator', + }, + { + 'NAME': 'django.contrib.auth.password_validation.MinimumLengthValidator', + }, + { + 'NAME': 'django.contrib.auth.password_validation.CommonPasswordValidator', + }, + { + 'NAME': 'django.contrib.auth.password_validation.NumericPasswordValidator', + }, +] + + +# Internationalization +# https://docs.djangoproject.com/en/3.2/topics/i18n/ + +LANGUAGE_CODE = 'en-us' + +TIME_ZONE = 'UTC' + +USE_I18N = True + +USE_L10N = True + +USE_TZ = True + + +# Static files (CSS, JavaScript, Images) +# https://docs.djangoproject.com/en/3.2/howto/static-files/ + +STATIC_URL = '/static/' +STATICFILES_DIRS = [BASE_DIR / 'static'] + +# Default primary key field type +# https://docs.djangoproject.com/en/3.2/ref/settings/#default-auto-field + +DEFAULT_AUTO_FIELD = 'django.db.models.BigAutoField' + +AUTH_USER_MODEL = 'users.CustomUser' + +LOGIN_REDIRECT_URL = 'home' +LOGOUT_REDIRECT_URL = 'home' + +LOGIN_URL = 'login' diff --git a/code/liam/django/pokedex-main/pokedex-main/pokedex_project/urls.py b/code/liam/django/pokedex-main/pokedex-main/pokedex_project/urls.py new file mode 100644 index 00000000..829ec71d --- /dev/null +++ b/code/liam/django/pokedex-main/pokedex-main/pokedex_project/urls.py @@ -0,0 +1,26 @@ +"""pokedex_project URL Configuration + +The `urlpatterns` list routes URLs to views. For more information please see: + https://docs.djangoproject.com/en/3.2/topics/http/urls/ +Examples: +Function views + 1. Add an import: from my_app import views + 2. Add a URL to urlpatterns: path('', views.home, name='home') +Class-based views + 1. Add an import: from other_app.views import Home + 2. Add a URL to urlpatterns: path('', Home.as_view(), name='home') +Including another URLconf + 1. Import the include() function: from django.urls import include, path + 2. Add a URL to urlpatterns: path('blog/', include('blog.urls')) +""" +from django.contrib import admin +from django.urls import path, include +from django.views.generic import TemplateView + +urlpatterns = [ + path('admin/', admin.site.urls), + path('users/', include('django.contrib.auth.urls')), + path('users/', include('users.urls')), + path('', TemplateView.as_view(template_name='home.html'), name='home'), + path('api/', include('api.urls')) +] diff --git a/code/liam/django/pokedex-main/pokedex-main/pokedex_project/wsgi.py b/code/liam/django/pokedex-main/pokedex-main/pokedex_project/wsgi.py new file mode 100644 index 00000000..b482e56b --- /dev/null +++ b/code/liam/django/pokedex-main/pokedex-main/pokedex_project/wsgi.py @@ -0,0 +1,16 @@ +""" +WSGI config for pokedex_project project. + +It exposes the WSGI callable as a module-level variable named ``application``. + +For more information on this file, see +https://docs.djangoproject.com/en/3.2/howto/deployment/wsgi/ +""" + +import os + +from django.core.wsgi import get_wsgi_application + +os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'pokedex_project.settings') + +application = get_wsgi_application() diff --git a/code/liam/django/pokedex-main/pokedex-main/pokemon.json b/code/liam/django/pokedex-main/pokedex-main/pokemon.json new file mode 100644 index 00000000..0e383d62 --- /dev/null +++ b/code/liam/django/pokedex-main/pokedex-main/pokemon.json @@ -0,0 +1,1883 @@ +{ + "pokemon": [ + { + "number": 1, + "name": "bulbasaur", + "height": 7, + "weight": 69, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/1.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/1.png", + "types": [ + "poison", + "grass" + ], + "url": "https://pokemon.fandom.com/wiki/bulbasaur" + }, + { + "number": 2, + "name": "ivysaur", + "height": 10, + "weight": 130, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/2.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/2.png", + "types": [ + "poison", + "grass" + ], + "url": "https://pokemon.fandom.com/wiki/ivysaur" + }, + { + "number": 3, + "name": "venusaur", + "height": 20, + "weight": 1000, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/3.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/3.png", + "types": [ + "poison", + "grass" + ], + "url": "https://pokemon.fandom.com/wiki/venusaur" + }, + { + "number": 4, + "name": "charmander", + "height": 6, + "weight": 85, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/4.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/4.png", + "types": [ + "fire" + ], + "url": "https://pokemon.fandom.com/wiki/charmander" + }, + { + "number": 5, + "name": "charmeleon", + "height": 11, + "weight": 190, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/5.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/5.png", + "types": [ + "fire" + ], + "url": "https://pokemon.fandom.com/wiki/charmeleon" + }, + { + "number": 6, + "name": "charizard", + "height": 17, + "weight": 905, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/6.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/6.png", + "types": [ + "flying", + "fire" + ], + "url": "https://pokemon.fandom.com/wiki/charizard" + }, + { + "number": 7, + "name": "squirtle", + "height": 5, + "weight": 90, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/7.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/7.png", + "types": [ + "water" + ], + "url": "https://pokemon.fandom.com/wiki/squirtle" + }, + { + "number": 8, + "name": "wartortle", + "height": 10, + "weight": 225, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/8.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/8.png", + "types": [ + "water" + ], + "url": "https://pokemon.fandom.com/wiki/wartortle" + }, + { + "number": 9, + "name": "blastoise", + "height": 16, + "weight": 855, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/9.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/9.png", + "types": [ + "water" + ], + "url": "https://pokemon.fandom.com/wiki/blastoise" + }, + { + "number": 10, + "name": "caterpie", + "height": 3, + "weight": 29, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/10.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/10.png", + "types": [ + "bug" + ], + "url": "https://pokemon.fandom.com/wiki/caterpie" + }, + { + "number": 11, + "name": "metapod", + "height": 7, + "weight": 99, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/11.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/11.png", + "types": [ + "bug" + ], + "url": "https://pokemon.fandom.com/wiki/metapod" + }, + { + "number": 12, + "name": "butterfree", + "height": 11, + "weight": 320, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/12.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/12.png", + "types": [ + "flying", + "bug" + ], + "url": "https://pokemon.fandom.com/wiki/butterfree" + }, + { + "number": 13, + "name": "weedle", + "height": 3, + "weight": 32, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/13.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/13.png", + "types": [ + "poison", + "bug" + ], + "url": "https://pokemon.fandom.com/wiki/weedle" + }, + { + "number": 14, + "name": "kakuna", + "height": 6, + "weight": 100, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/14.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/14.png", + "types": [ + "poison", + "bug" + ], + "url": "https://pokemon.fandom.com/wiki/kakuna" + }, + { + "number": 15, + "name": "beedrill", + "height": 10, + "weight": 295, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/15.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/15.png", + "types": [ + "poison", + "bug" + ], + "url": "https://pokemon.fandom.com/wiki/beedrill" + }, + { + "number": 16, + "name": "pidgey", + "height": 3, + "weight": 18, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/16.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/16.png", + "types": [ + "flying", + "normal" + ], + "url": "https://pokemon.fandom.com/wiki/pidgey" + }, + { + "number": 17, + "name": "pidgeotto", + "height": 11, + "weight": 300, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/17.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/17.png", + "types": [ + "flying", + "normal" + ], + "url": "https://pokemon.fandom.com/wiki/pidgeotto" + }, + { + "number": 18, + "name": "pidgeot", + "height": 15, + "weight": 395, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/18.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/18.png", + "types": [ + "flying", + "normal" + ], + "url": "https://pokemon.fandom.com/wiki/pidgeot" + }, + { + "number": 19, + "name": "rattata", + "height": 3, + "weight": 35, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/19.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/19.png", + "types": [ + "normal" + ], + "url": "https://pokemon.fandom.com/wiki/rattata" + }, + { + "number": 20, + "name": "raticate", + "height": 7, + "weight": 185, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/20.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/20.png", + "types": [ + "normal" + ], + "url": "https://pokemon.fandom.com/wiki/raticate" + }, + { + "number": 21, + "name": "spearow", + "height": 3, + "weight": 20, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/21.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/21.png", + "types": [ + "flying", + "normal" + ], + "url": "https://pokemon.fandom.com/wiki/spearow" + }, + { + "number": 22, + "name": "fearow", + "height": 12, + "weight": 380, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/22.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/22.png", + "types": [ + "flying", + "normal" + ], + "url": "https://pokemon.fandom.com/wiki/fearow" + }, + { + "number": 23, + "name": "ekans", + "height": 20, + "weight": 69, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/23.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/23.png", + "types": [ + "poison" + ], + "url": "https://pokemon.fandom.com/wiki/ekans" + }, + { + "number": 24, + "name": "arbok", + "height": 35, + "weight": 650, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/24.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/24.png", + "types": [ + "poison" + ], + "url": "https://pokemon.fandom.com/wiki/arbok" + }, + { + "number": 25, + "name": "pikachu", + "height": 4, + "weight": 60, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/25.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/25.png", + "types": [ + "electric" + ], + "url": "https://pokemon.fandom.com/wiki/pikachu" + }, + { + "number": 26, + "name": "raichu", + "height": 8, + "weight": 300, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/26.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/26.png", + "types": [ + "electric" + ], + "url": "https://pokemon.fandom.com/wiki/raichu" + }, + { + "number": 27, + "name": "sandshrew", + "height": 6, + "weight": 120, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/27.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/27.png", + "types": [ + "ground" + ], + "url": "https://pokemon.fandom.com/wiki/sandshrew" + }, + { + "number": 28, + "name": "sandslash", + "height": 10, + "weight": 295, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/28.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/28.png", + "types": [ + "ground" + ], + "url": "https://pokemon.fandom.com/wiki/sandslash" + }, + { + "number": 29, + "name": "nidoran-f", + "height": 4, + "weight": 70, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/29.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/29.png", + "types": [ + "poison" + ], + "url": "https://pokemon.fandom.com/wiki/nidoran-f" + }, + { + "number": 30, + "name": "nidorina", + "height": 8, + "weight": 200, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/30.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/30.png", + "types": [ + "poison" + ], + "url": "https://pokemon.fandom.com/wiki/nidorina" + }, + { + "number": 31, + "name": "nidoqueen", + "height": 13, + "weight": 600, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/31.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/31.png", + "types": [ + "ground", + "poison" + ], + "url": "https://pokemon.fandom.com/wiki/nidoqueen" + }, + { + "number": 32, + "name": "nidoran-m", + "height": 5, + "weight": 90, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/32.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/32.png", + "types": [ + "poison" + ], + "url": "https://pokemon.fandom.com/wiki/nidoran-m" + }, + { + "number": 33, + "name": "nidorino", + "height": 9, + "weight": 195, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/33.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/33.png", + "types": [ + "poison" + ], + "url": "https://pokemon.fandom.com/wiki/nidorino" + }, + { + "number": 34, + "name": "nidoking", + "height": 14, + "weight": 620, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/34.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/34.png", + "types": [ + "ground", + "poison" + ], + "url": "https://pokemon.fandom.com/wiki/nidoking" + }, + { + "number": 35, + "name": "clefairy", + "height": 6, + "weight": 75, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/35.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/35.png", + "types": [ + "fairy" + ], + "url": "https://pokemon.fandom.com/wiki/clefairy" + }, + { + "number": 36, + "name": "clefable", + "height": 13, + "weight": 400, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/36.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/36.png", + "types": [ + "fairy" + ], + "url": "https://pokemon.fandom.com/wiki/clefable" + }, + { + "number": 37, + "name": "vulpix", + "height": 6, + "weight": 99, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/37.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/37.png", + "types": [ + "fire" + ], + "url": "https://pokemon.fandom.com/wiki/vulpix" + }, + { + "number": 38, + "name": "ninetales", + "height": 11, + "weight": 199, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/38.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/38.png", + "types": [ + "fire" + ], + "url": "https://pokemon.fandom.com/wiki/ninetales" + }, + { + "number": 39, + "name": "jigglypuff", + "height": 5, + "weight": 55, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/39.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/39.png", + "types": [ + "fairy", + "normal" + ], + "url": "https://pokemon.fandom.com/wiki/jigglypuff" + }, + { + "number": 40, + "name": "wigglytuff", + "height": 10, + "weight": 120, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/40.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/40.png", + "types": [ + "fairy", + "normal" + ], + "url": "https://pokemon.fandom.com/wiki/wigglytuff" + }, + { + "number": 41, + "name": "zubat", + "height": 8, + "weight": 75, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/41.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/41.png", + "types": [ + "flying", + "poison" + ], + "url": "https://pokemon.fandom.com/wiki/zubat" + }, + { + "number": 42, + "name": "golbat", + "height": 16, + "weight": 550, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/42.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/42.png", + "types": [ + "flying", + "poison" + ], + "url": "https://pokemon.fandom.com/wiki/golbat" + }, + { + "number": 43, + "name": "oddish", + "height": 5, + "weight": 54, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/43.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/43.png", + "types": [ + "poison", + "grass" + ], + "url": "https://pokemon.fandom.com/wiki/oddish" + }, + { + "number": 44, + "name": "gloom", + "height": 8, + "weight": 86, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/44.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/44.png", + "types": [ + "poison", + "grass" + ], + "url": "https://pokemon.fandom.com/wiki/gloom" + }, + { + "number": 45, + "name": "vileplume", + "height": 12, + "weight": 186, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/45.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/45.png", + "types": [ + "poison", + "grass" + ], + "url": "https://pokemon.fandom.com/wiki/vileplume" + }, + { + "number": 46, + "name": "paras", + "height": 3, + "weight": 54, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/46.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/46.png", + "types": [ + "grass", + "bug" + ], + "url": "https://pokemon.fandom.com/wiki/paras" + }, + { + "number": 47, + "name": "parasect", + "height": 10, + "weight": 295, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/47.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/47.png", + "types": [ + "grass", + "bug" + ], + "url": "https://pokemon.fandom.com/wiki/parasect" + }, + { + "number": 48, + "name": "venonat", + "height": 10, + "weight": 300, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/48.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/48.png", + "types": [ + "poison", + "bug" + ], + "url": "https://pokemon.fandom.com/wiki/venonat" + }, + { + "number": 49, + "name": "venomoth", + "height": 15, + "weight": 125, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/49.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/49.png", + "types": [ + "poison", + "bug" + ], + "url": "https://pokemon.fandom.com/wiki/venomoth" + }, + { + "number": 50, + "name": "diglett", + "height": 2, + "weight": 8, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/50.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/50.png", + "types": [ + "ground" + ], + "url": "https://pokemon.fandom.com/wiki/diglett" + }, + { + "number": 51, + "name": "dugtrio", + "height": 7, + "weight": 333, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/51.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/51.png", + "types": [ + "ground" + ], + "url": "https://pokemon.fandom.com/wiki/dugtrio" + }, + { + "number": 52, + "name": "meowth", + "height": 4, + "weight": 42, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/52.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/52.png", + "types": [ + "normal" + ], + "url": "https://pokemon.fandom.com/wiki/meowth" + }, + { + "number": 53, + "name": "persian", + "height": 10, + "weight": 320, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/53.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/53.png", + "types": [ + "normal" + ], + "url": "https://pokemon.fandom.com/wiki/persian" + }, + { + "number": 54, + "name": "psyduck", + "height": 8, + "weight": 196, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/54.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/54.png", + "types": [ + "water" + ], + "url": "https://pokemon.fandom.com/wiki/psyduck" + }, + { + "number": 55, + "name": "golduck", + "height": 17, + "weight": 766, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/55.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/55.png", + "types": [ + "water" + ], + "url": "https://pokemon.fandom.com/wiki/golduck" + }, + { + "number": 56, + "name": "mankey", + "height": 5, + "weight": 280, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/56.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/56.png", + "types": [ + "fighting" + ], + "url": "https://pokemon.fandom.com/wiki/mankey" + }, + { + "number": 57, + "name": "primeape", + "height": 10, + "weight": 320, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/57.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/57.png", + "types": [ + "fighting" + ], + "url": "https://pokemon.fandom.com/wiki/primeape" + }, + { + "number": 58, + "name": "growlithe", + "height": 7, + "weight": 190, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/58.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/58.png", + "types": [ + "fire" + ], + "url": "https://pokemon.fandom.com/wiki/growlithe" + }, + { + "number": 59, + "name": "arcanine", + "height": 19, + "weight": 1550, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/59.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/59.png", + "types": [ + "fire" + ], + "url": "https://pokemon.fandom.com/wiki/arcanine" + }, + { + "number": 60, + "name": "poliwag", + "height": 6, + "weight": 124, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/60.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/60.png", + "types": [ + "water" + ], + "url": "https://pokemon.fandom.com/wiki/poliwag" + }, + { + "number": 61, + "name": "poliwhirl", + "height": 10, + "weight": 200, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/61.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/61.png", + "types": [ + "water" + ], + "url": "https://pokemon.fandom.com/wiki/poliwhirl" + }, + { + "number": 62, + "name": "poliwrath", + "height": 13, + "weight": 540, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/62.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/62.png", + "types": [ + "fighting", + "water" + ], + "url": "https://pokemon.fandom.com/wiki/poliwrath" + }, + { + "number": 63, + "name": "abra", + "height": 9, + "weight": 195, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/63.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/63.png", + "types": [ + "psychic" + ], + "url": "https://pokemon.fandom.com/wiki/abra" + }, + { + "number": 64, + "name": "kadabra", + "height": 13, + "weight": 565, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/64.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/64.png", + "types": [ + "psychic" + ], + "url": "https://pokemon.fandom.com/wiki/kadabra" + }, + { + "number": 65, + "name": "alakazam", + "height": 15, + "weight": 480, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/65.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/65.png", + "types": [ + "psychic" + ], + "url": "https://pokemon.fandom.com/wiki/alakazam" + }, + { + "number": 66, + "name": "machop", + "height": 8, + "weight": 195, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/66.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/66.png", + "types": [ + "fighting" + ], + "url": "https://pokemon.fandom.com/wiki/machop" + }, + { + "number": 67, + "name": "machoke", + "height": 15, + "weight": 705, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/67.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/67.png", + "types": [ + "fighting" + ], + "url": "https://pokemon.fandom.com/wiki/machoke" + }, + { + "number": 68, + "name": "machamp", + "height": 16, + "weight": 1300, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/68.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/68.png", + "types": [ + "fighting" + ], + "url": "https://pokemon.fandom.com/wiki/machamp" + }, + { + "number": 69, + "name": "bellsprout", + "height": 7, + "weight": 40, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/69.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/69.png", + "types": [ + "poison", + "grass" + ], + "url": "https://pokemon.fandom.com/wiki/bellsprout" + }, + { + "number": 70, + "name": "weepinbell", + "height": 10, + "weight": 64, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/70.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/70.png", + "types": [ + "poison", + "grass" + ], + "url": "https://pokemon.fandom.com/wiki/weepinbell" + }, + { + "number": 71, + "name": "victreebel", + "height": 17, + "weight": 155, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/71.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/71.png", + "types": [ + "poison", + "grass" + ], + "url": "https://pokemon.fandom.com/wiki/victreebel" + }, + { + "number": 72, + "name": "tentacool", + "height": 9, + "weight": 455, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/72.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/72.png", + "types": [ + "poison", + "water" + ], + "url": "https://pokemon.fandom.com/wiki/tentacool" + }, + { + "number": 73, + "name": "tentacruel", + "height": 16, + "weight": 550, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/73.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/73.png", + "types": [ + "poison", + "water" + ], + "url": "https://pokemon.fandom.com/wiki/tentacruel" + }, + { + "number": 74, + "name": "geodude", + "height": 4, + "weight": 200, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/74.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/74.png", + "types": [ + "ground", + "rock" + ], + "url": "https://pokemon.fandom.com/wiki/geodude" + }, + { + "number": 75, + "name": "graveler", + "height": 10, + "weight": 1050, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/75.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/75.png", + "types": [ + "ground", + "rock" + ], + "url": "https://pokemon.fandom.com/wiki/graveler" + }, + { + "number": 76, + "name": "golem", + "height": 14, + "weight": 3000, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/76.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/76.png", + "types": [ + "ground", + "rock" + ], + "url": "https://pokemon.fandom.com/wiki/golem" + }, + { + "number": 77, + "name": "ponyta", + "height": 10, + "weight": 300, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/77.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/77.png", + "types": [ + "fire" + ], + "url": "https://pokemon.fandom.com/wiki/ponyta" + }, + { + "number": 78, + "name": "rapidash", + "height": 17, + "weight": 950, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/78.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/78.png", + "types": [ + "fire" + ], + "url": "https://pokemon.fandom.com/wiki/rapidash" + }, + { + "number": 79, + "name": "slowpoke", + "height": 12, + "weight": 360, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/79.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/79.png", + "types": [ + "psychic", + "water" + ], + "url": "https://pokemon.fandom.com/wiki/slowpoke" + }, + { + "number": 80, + "name": "slowbro", + "height": 16, + "weight": 785, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/80.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/80.png", + "types": [ + "psychic", + "water" + ], + "url": "https://pokemon.fandom.com/wiki/slowbro" + }, + { + "number": 81, + "name": "magnemite", + "height": 3, + "weight": 60, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/81.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/81.png", + "types": [ + "steel", + "electric" + ], + "url": "https://pokemon.fandom.com/wiki/magnemite" + }, + { + "number": 82, + "name": "magneton", + "height": 10, + "weight": 600, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/82.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/82.png", + "types": [ + "steel", + "electric" + ], + "url": "https://pokemon.fandom.com/wiki/magneton" + }, + { + "number": 83, + "name": "farfetchd", + "height": 8, + "weight": 150, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/83.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/83.png", + "types": [ + "flying", + "normal" + ], + "url": "https://pokemon.fandom.com/wiki/farfetchd" + }, + { + "number": 84, + "name": "doduo", + "height": 14, + "weight": 392, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/84.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/84.png", + "types": [ + "flying", + "normal" + ], + "url": "https://pokemon.fandom.com/wiki/doduo" + }, + { + "number": 85, + "name": "dodrio", + "height": 18, + "weight": 852, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/85.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/85.png", + "types": [ + "flying", + "normal" + ], + "url": "https://pokemon.fandom.com/wiki/dodrio" + }, + { + "number": 86, + "name": "seel", + "height": 11, + "weight": 900, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/86.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/86.png", + "types": [ + "water" + ], + "url": "https://pokemon.fandom.com/wiki/seel" + }, + { + "number": 87, + "name": "dewgong", + "height": 17, + "weight": 1200, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/87.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/87.png", + "types": [ + "ice", + "water" + ], + "url": "https://pokemon.fandom.com/wiki/dewgong" + }, + { + "number": 88, + "name": "grimer", + "height": 9, + "weight": 300, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/88.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/88.png", + "types": [ + "poison" + ], + "url": "https://pokemon.fandom.com/wiki/grimer" + }, + { + "number": 89, + "name": "muk", + "height": 12, + "weight": 300, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/89.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/89.png", + "types": [ + "poison" + ], + "url": "https://pokemon.fandom.com/wiki/muk" + }, + { + "number": 90, + "name": "shellder", + "height": 3, + "weight": 40, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/90.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/90.png", + "types": [ + "water" + ], + "url": "https://pokemon.fandom.com/wiki/shellder" + }, + { + "number": 91, + "name": "cloyster", + "height": 15, + "weight": 1325, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/91.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/91.png", + "types": [ + "ice", + "water" + ], + "url": "https://pokemon.fandom.com/wiki/cloyster" + }, + { + "number": 92, + "name": "gastly", + "height": 13, + "weight": 1, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/92.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/92.png", + "types": [ + "poison", + "ghost" + ], + "url": "https://pokemon.fandom.com/wiki/gastly" + }, + { + "number": 93, + "name": "haunter", + "height": 16, + "weight": 1, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/93.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/93.png", + "types": [ + "poison", + "ghost" + ], + "url": "https://pokemon.fandom.com/wiki/haunter" + }, + { + "number": 94, + "name": "gengar", + "height": 15, + "weight": 405, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/94.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/94.png", + "types": [ + "poison", + "ghost" + ], + "url": "https://pokemon.fandom.com/wiki/gengar" + }, + { + "number": 95, + "name": "onix", + "height": 88, + "weight": 2100, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/95.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/95.png", + "types": [ + "ground", + "rock" + ], + "url": "https://pokemon.fandom.com/wiki/onix" + }, + { + "number": 96, + "name": "drowzee", + "height": 10, + "weight": 324, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/96.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/96.png", + "types": [ + "psychic" + ], + "url": "https://pokemon.fandom.com/wiki/drowzee" + }, + { + "number": 97, + "name": "hypno", + "height": 16, + "weight": 756, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/97.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/97.png", + "types": [ + "psychic" + ], + "url": "https://pokemon.fandom.com/wiki/hypno" + }, + { + "number": 98, + "name": "krabby", + "height": 4, + "weight": 65, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/98.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/98.png", + "types": [ + "water" + ], + "url": "https://pokemon.fandom.com/wiki/krabby" + }, + { + "number": 99, + "name": "kingler", + "height": 13, + "weight": 600, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/99.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/99.png", + "types": [ + "water" + ], + "url": "https://pokemon.fandom.com/wiki/kingler" + }, + { + "number": 100, + "name": "voltorb", + "height": 5, + "weight": 104, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/100.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/100.png", + "types": [ + "electric" + ], + "url": "https://pokemon.fandom.com/wiki/voltorb" + }, + { + "number": 101, + "name": "electrode", + "height": 12, + "weight": 666, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/101.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/101.png", + "types": [ + "electric" + ], + "url": "https://pokemon.fandom.com/wiki/electrode" + }, + { + "number": 102, + "name": "exeggcute", + "height": 4, + "weight": 25, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/102.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/102.png", + "types": [ + "psychic", + "grass" + ], + "url": "https://pokemon.fandom.com/wiki/exeggcute" + }, + { + "number": 103, + "name": "exeggutor", + "height": 20, + "weight": 1200, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/103.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/103.png", + "types": [ + "psychic", + "grass" + ], + "url": "https://pokemon.fandom.com/wiki/exeggutor" + }, + { + "number": 104, + "name": "cubone", + "height": 4, + "weight": 65, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/104.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/104.png", + "types": [ + "ground" + ], + "url": "https://pokemon.fandom.com/wiki/cubone" + }, + { + "number": 105, + "name": "marowak", + "height": 10, + "weight": 450, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/105.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/105.png", + "types": [ + "ground" + ], + "url": "https://pokemon.fandom.com/wiki/marowak" + }, + { + "number": 106, + "name": "hitmonlee", + "height": 15, + "weight": 498, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/106.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/106.png", + "types": [ + "fighting" + ], + "url": "https://pokemon.fandom.com/wiki/hitmonlee" + }, + { + "number": 107, + "name": "hitmonchan", + "height": 14, + "weight": 502, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/107.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/107.png", + "types": [ + "fighting" + ], + "url": "https://pokemon.fandom.com/wiki/hitmonchan" + }, + { + "number": 108, + "name": "lickitung", + "height": 12, + "weight": 655, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/108.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/108.png", + "types": [ + "normal" + ], + "url": "https://pokemon.fandom.com/wiki/lickitung" + }, + { + "number": 109, + "name": "koffing", + "height": 6, + "weight": 10, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/109.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/109.png", + "types": [ + "poison" + ], + "url": "https://pokemon.fandom.com/wiki/koffing" + }, + { + "number": 110, + "name": "weezing", + "height": 12, + "weight": 95, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/110.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/110.png", + "types": [ + "poison" + ], + "url": "https://pokemon.fandom.com/wiki/weezing" + }, + { + "number": 111, + "name": "rhyhorn", + "height": 10, + "weight": 1150, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/111.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/111.png", + "types": [ + "rock", + "ground" + ], + "url": "https://pokemon.fandom.com/wiki/rhyhorn" + }, + { + "number": 112, + "name": "rhydon", + "height": 19, + "weight": 1200, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/112.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/112.png", + "types": [ + "rock", + "ground" + ], + "url": "https://pokemon.fandom.com/wiki/rhydon" + }, + { + "number": 113, + "name": "chansey", + "height": 11, + "weight": 346, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/113.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/113.png", + "types": [ + "normal" + ], + "url": "https://pokemon.fandom.com/wiki/chansey" + }, + { + "number": 114, + "name": "tangela", + "height": 10, + "weight": 350, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/114.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/114.png", + "types": [ + "grass" + ], + "url": "https://pokemon.fandom.com/wiki/tangela" + }, + { + "number": 115, + "name": "kangaskhan", + "height": 22, + "weight": 800, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/115.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/115.png", + "types": [ + "normal" + ], + "url": "https://pokemon.fandom.com/wiki/kangaskhan" + }, + { + "number": 116, + "name": "horsea", + "height": 4, + "weight": 80, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/116.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/116.png", + "types": [ + "water" + ], + "url": "https://pokemon.fandom.com/wiki/horsea" + }, + { + "number": 117, + "name": "seadra", + "height": 12, + "weight": 250, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/117.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/117.png", + "types": [ + "water" + ], + "url": "https://pokemon.fandom.com/wiki/seadra" + }, + { + "number": 118, + "name": "goldeen", + "height": 6, + "weight": 150, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/118.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/118.png", + "types": [ + "water" + ], + "url": "https://pokemon.fandom.com/wiki/goldeen" + }, + { + "number": 119, + "name": "seaking", + "height": 13, + "weight": 390, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/119.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/119.png", + "types": [ + "water" + ], + "url": "https://pokemon.fandom.com/wiki/seaking" + }, + { + "number": 120, + "name": "staryu", + "height": 8, + "weight": 345, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/120.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/120.png", + "types": [ + "water" + ], + "url": "https://pokemon.fandom.com/wiki/staryu" + }, + { + "number": 121, + "name": "starmie", + "height": 11, + "weight": 800, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/121.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/121.png", + "types": [ + "psychic", + "water" + ], + "url": "https://pokemon.fandom.com/wiki/starmie" + }, + { + "number": 122, + "name": "mr-mime", + "height": 13, + "weight": 545, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/122.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/122.png", + "types": [ + "fairy", + "psychic" + ], + "url": "https://pokemon.fandom.com/wiki/mr-mime" + }, + { + "number": 123, + "name": "scyther", + "height": 15, + "weight": 560, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/123.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/123.png", + "types": [ + "flying", + "bug" + ], + "url": "https://pokemon.fandom.com/wiki/scyther" + }, + { + "number": 124, + "name": "jynx", + "height": 14, + "weight": 406, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/124.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/124.png", + "types": [ + "psychic", + "ice" + ], + "url": "https://pokemon.fandom.com/wiki/jynx" + }, + { + "number": 125, + "name": "electabuzz", + "height": 11, + "weight": 300, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/125.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/125.png", + "types": [ + "electric" + ], + "url": "https://pokemon.fandom.com/wiki/electabuzz" + }, + { + "number": 126, + "name": "magmar", + "height": 13, + "weight": 445, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/126.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/126.png", + "types": [ + "fire" + ], + "url": "https://pokemon.fandom.com/wiki/magmar" + }, + { + "number": 127, + "name": "pinsir", + "height": 15, + "weight": 550, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/127.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/127.png", + "types": [ + "bug" + ], + "url": "https://pokemon.fandom.com/wiki/pinsir" + }, + { + "number": 128, + "name": "tauros", + "height": 14, + "weight": 884, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/128.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/128.png", + "types": [ + "normal" + ], + "url": "https://pokemon.fandom.com/wiki/tauros" + }, + { + "number": 129, + "name": "magikarp", + "height": 9, + "weight": 100, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/129.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/129.png", + "types": [ + "water" + ], + "url": "https://pokemon.fandom.com/wiki/magikarp" + }, + { + "number": 130, + "name": "gyarados", + "height": 65, + "weight": 2350, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/130.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/130.png", + "types": [ + "flying", + "water" + ], + "url": "https://pokemon.fandom.com/wiki/gyarados" + }, + { + "number": 131, + "name": "lapras", + "height": 25, + "weight": 2200, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/131.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/131.png", + "types": [ + "ice", + "water" + ], + "url": "https://pokemon.fandom.com/wiki/lapras" + }, + { + "number": 132, + "name": "ditto", + "height": 3, + "weight": 40, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/132.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/132.png", + "types": [ + "normal" + ], + "url": "https://pokemon.fandom.com/wiki/ditto" + }, + { + "number": 133, + "name": "eevee", + "height": 3, + "weight": 65, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/133.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/133.png", + "types": [ + "normal" + ], + "url": "https://pokemon.fandom.com/wiki/eevee" + }, + { + "number": 134, + "name": "vaporeon", + "height": 10, + "weight": 290, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/134.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/134.png", + "types": [ + "water" + ], + "url": "https://pokemon.fandom.com/wiki/vaporeon" + }, + { + "number": 135, + "name": "jolteon", + "height": 8, + "weight": 245, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/135.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/135.png", + "types": [ + "electric" + ], + "url": "https://pokemon.fandom.com/wiki/jolteon" + }, + { + "number": 136, + "name": "flareon", + "height": 9, + "weight": 250, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/136.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/136.png", + "types": [ + "fire" + ], + "url": "https://pokemon.fandom.com/wiki/flareon" + }, + { + "number": 137, + "name": "porygon", + "height": 8, + "weight": 365, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/137.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/137.png", + "types": [ + "normal" + ], + "url": "https://pokemon.fandom.com/wiki/porygon" + }, + { + "number": 138, + "name": "omanyte", + "height": 4, + "weight": 75, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/138.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/138.png", + "types": [ + "water", + "rock" + ], + "url": "https://pokemon.fandom.com/wiki/omanyte" + }, + { + "number": 139, + "name": "omastar", + "height": 10, + "weight": 350, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/139.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/139.png", + "types": [ + "water", + "rock" + ], + "url": "https://pokemon.fandom.com/wiki/omastar" + }, + { + "number": 140, + "name": "kabuto", + "height": 5, + "weight": 115, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/140.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/140.png", + "types": [ + "water", + "rock" + ], + "url": "https://pokemon.fandom.com/wiki/kabuto" + }, + { + "number": 141, + "name": "kabutops", + "height": 13, + "weight": 405, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/141.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/141.png", + "types": [ + "water", + "rock" + ], + "url": "https://pokemon.fandom.com/wiki/kabutops" + }, + { + "number": 142, + "name": "aerodactyl", + "height": 18, + "weight": 590, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/142.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/142.png", + "types": [ + "flying", + "rock" + ], + "url": "https://pokemon.fandom.com/wiki/aerodactyl" + }, + { + "number": 143, + "name": "snorlax", + "height": 21, + "weight": 4600, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/143.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/143.png", + "types": [ + "normal" + ], + "url": "https://pokemon.fandom.com/wiki/snorlax" + }, + { + "number": 144, + "name": "articuno", + "height": 17, + "weight": 554, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/144.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/144.png", + "types": [ + "flying", + "ice" + ], + "url": "https://pokemon.fandom.com/wiki/articuno" + }, + { + "number": 145, + "name": "zapdos", + "height": 16, + "weight": 526, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/145.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/145.png", + "types": [ + "flying", + "electric" + ], + "url": "https://pokemon.fandom.com/wiki/zapdos" + }, + { + "number": 146, + "name": "moltres", + "height": 20, + "weight": 600, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/146.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/146.png", + "types": [ + "flying", + "fire" + ], + "url": "https://pokemon.fandom.com/wiki/moltres" + }, + { + "number": 147, + "name": "dratini", + "height": 18, + "weight": 33, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/147.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/147.png", + "types": [ + "dragon" + ], + "url": "https://pokemon.fandom.com/wiki/dratini" + }, + { + "number": 148, + "name": "dragonair", + "height": 40, + "weight": 165, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/148.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/148.png", + "types": [ + "dragon" + ], + "url": "https://pokemon.fandom.com/wiki/dragonair" + }, + { + "number": 149, + "name": "dragonite", + "height": 22, + "weight": 2100, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/149.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/149.png", + "types": [ + "flying", + "dragon" + ], + "url": "https://pokemon.fandom.com/wiki/dragonite" + }, + { + "number": 150, + "name": "mewtwo", + "height": 20, + "weight": 1220, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/150.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/150.png", + "types": [ + "psychic" + ], + "url": "https://pokemon.fandom.com/wiki/mewtwo" + }, + { + "number": 151, + "name": "mew", + "height": 4, + "weight": 40, + "image_front": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/151.png", + "image_back": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/back/151.png", + "types": [ + "psychic" + ], + "url": "https://pokemon.fandom.com/wiki/mew" + } + ] +} \ No newline at end of file diff --git a/code/liam/django/pokedex-main/pokedex-main/pokemon/__init__.py b/code/liam/django/pokedex-main/pokedex-main/pokemon/__init__.py new file mode 100644 index 00000000..e69de29b diff --git a/code/liam/django/pokedex-main/pokedex-main/pokemon/admin.py b/code/liam/django/pokedex-main/pokedex-main/pokemon/admin.py new file mode 100644 index 00000000..cc700d6f --- /dev/null +++ b/code/liam/django/pokedex-main/pokedex-main/pokemon/admin.py @@ -0,0 +1,6 @@ +from django.contrib import admin + +from .models import Pokemon, Type + +admin.site.register(Pokemon) +admin.site.register(Type) diff --git a/code/liam/django/pokedex-main/pokedex-main/pokemon/apps.py b/code/liam/django/pokedex-main/pokedex-main/pokemon/apps.py new file mode 100644 index 00000000..0b4175f1 --- /dev/null +++ b/code/liam/django/pokedex-main/pokedex-main/pokemon/apps.py @@ -0,0 +1,6 @@ +from django.apps import AppConfig + + +class PokemonConfig(AppConfig): + default_auto_field = 'django.db.models.BigAutoField' + name = 'pokemon' diff --git a/code/liam/django/pokedex-main/pokedex-main/pokemon/management/commands/load_pokemon.py b/code/liam/django/pokedex-main/pokedex-main/pokemon/management/commands/load_pokemon.py new file mode 100644 index 00000000..0d863c8b --- /dev/null +++ b/code/liam/django/pokedex-main/pokedex-main/pokemon/management/commands/load_pokemon.py @@ -0,0 +1,40 @@ +import json + +from django.core.management.base import BaseCommand + +from ...models import Pokemon, Type + +class Command(BaseCommand): + + def handle(self, *args, **options): + + # Clear existing Pokemon and Types + Pokemon.objects.all().delete() + Type.objects.all().delete() + + # Open Pokemon JSON and load to list of dictionaries + with open('pokemon.json') as p: + pokemon_list = json.loads(p.read()) + + # Loop through Pokemon to add to DB + for pokemon in pokemon_list['pokemon']: + + # Convert units to m and kg + pokemon['height'] /= 10 + pokemon['weight'] /= 10 + + # Add Pokemon to DB + poke_obj = Pokemon.objects.create( + number=pokemon['number'], + name=pokemon['name'], + height=pokemon['height'], + weight=pokemon['weight'], + image_front=pokemon['image_front'], + image_back=pokemon['image_back'] + ) + + # Loop through types list + # For each type, create type if it doesn't exist yet, than add that type to current Pokemon + for type in pokemon['types']: + type_obj, created = Type.objects.get_or_create(type=type) + type_obj.pokemon.add(poke_obj) diff --git a/code/liam/django/pokedex-main/pokedex-main/pokemon/migrations/0001_initial.py b/code/liam/django/pokedex-main/pokedex-main/pokemon/migrations/0001_initial.py new file mode 100644 index 00000000..87cf535c --- /dev/null +++ b/code/liam/django/pokedex-main/pokedex-main/pokemon/migrations/0001_initial.py @@ -0,0 +1,37 @@ +# Generated by Django 3.2 on 2021-08-03 01:21 + +from django.conf import settings +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + migrations.swappable_dependency(settings.AUTH_USER_MODEL), + ] + + operations = [ + migrations.CreateModel( + name='Pokemon', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('number', models.IntegerField()), + ('name', models.CharField(max_length=200)), + ('height', models.FloatField()), + ('weight', models.FloatField()), + ('image_front', models.URLField()), + ('image_back', models.URLField()), + ('caught_by', models.ManyToManyField(related_name='caught', to=settings.AUTH_USER_MODEL)), + ], + ), + migrations.CreateModel( + name='Type', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('type', models.CharField(max_length=50)), + ('pokemon', models.ManyToManyField(related_name='types', to='pokemon.Pokemon')), + ], + ), + ] diff --git a/code/liam/django/pokedex-main/pokedex-main/pokemon/migrations/__init__.py b/code/liam/django/pokedex-main/pokedex-main/pokemon/migrations/__init__.py new file mode 100644 index 00000000..e69de29b diff --git a/code/liam/django/pokedex-main/pokedex-main/pokemon/models.py b/code/liam/django/pokedex-main/pokedex-main/pokemon/models.py new file mode 100644 index 00000000..92e1d5a4 --- /dev/null +++ b/code/liam/django/pokedex-main/pokedex-main/pokemon/models.py @@ -0,0 +1,23 @@ +from django.db import models +from django.contrib.auth import get_user_model + +class Pokemon(models.Model): + number = models.IntegerField() + name = models.CharField(max_length=200) + height = models.FloatField() + weight = models.FloatField() + image_front = models.URLField() + image_back = models.URLField() + caught_by = models.ManyToManyField(get_user_model(), related_name='caught') + # types = the set of Types associated with that Pokemon + + def __str__(self): + return self.name + +class Type(models.Model): + type = models.CharField(max_length=50) + pokemon = models.ManyToManyField(Pokemon, related_name='types') + + def __str__(self): + return self.type + diff --git a/code/liam/django/pokedex-main/pokedex-main/pokemon/tests.py b/code/liam/django/pokedex-main/pokedex-main/pokemon/tests.py new file mode 100644 index 00000000..7ce503c2 --- /dev/null +++ b/code/liam/django/pokedex-main/pokedex-main/pokemon/tests.py @@ -0,0 +1,3 @@ +from django.test import TestCase + +# Create your tests here. diff --git a/code/liam/django/pokedex-main/pokedex-main/pokemon/views.py b/code/liam/django/pokedex-main/pokedex-main/pokemon/views.py new file mode 100644 index 00000000..91ea44a2 --- /dev/null +++ b/code/liam/django/pokedex-main/pokedex-main/pokemon/views.py @@ -0,0 +1,3 @@ +from django.shortcuts import render + +# Create your views here. diff --git a/code/liam/django/pokedex-main/pokedex-main/static/js/app.js b/code/liam/django/pokedex-main/pokedex-main/static/js/app.js new file mode 100644 index 00000000..bab8b3e6 --- /dev/null +++ b/code/liam/django/pokedex-main/pokedex-main/static/js/app.js @@ -0,0 +1,69 @@ + +new Vue({ + el: '#app', + delimiters: ['[[', ']]'], + data: { + pokemon: [], + token: '', + currentUser: {}, + caughtPokemon: [], + type: 'normal', + }, + methods: { + getPokemon() { + axios.get('/api/') + .then(response => { + this.pokemon = response.data + }) + }, + getCurrentUser() { + axios.get('/api/current/') + .then(response => { + this.currentUser = response.data + }) + }, + catchPokemon(poke) { + let match = this.currentUser.caught.includes(poke.id) + if (!match) { + this.caughtPokemon.push(poke.name) + this.currentUser.caught.push(poke.id) + axios.patch(`/api/user/${this.currentUser.id}/`, { + 'caught': this.currentUser.caught + }, { + headers: { 'X-CSRFToken': this.token } + }) + } + }, + releasePokemon(poke) { + // find indexOf and splice out + const match = this.currentUser.caught.find(el => el === poke.id) + const index = this.currentUser.caught.indexOf(match) + if (index !== -1) { + this.currentUser.caught.splice(index, 1) + axios.patch(`/api/user/${this.currentUser.id}/`, { + 'caught': this.currentUser.caught + }, { + headers: { 'X-CSRFToken': this.token } + }).then(() => this.getCurrentUser()) + } + + }, + hasPokemon(poke) { + let match = this.currentUser.caught.includes(poke.id) + return match + } + }, + computed: { + hasCaughtPokemon() { + if (this.currentUser.caught.length > 0) { + return true + } + return false + }, + }, + mounted() { + this.getPokemon() + this.getCurrentUser() + this.token = document.querySelector('input[name=csrfmiddlewaretoken]').value + }, +}) \ No newline at end of file diff --git a/code/liam/django/pokedex-main/pokedex-main/static/main.css b/code/liam/django/pokedex-main/pokedex-main/static/main.css new file mode 100644 index 00000000..2034a471 --- /dev/null +++ b/code/liam/django/pokedex-main/pokedex-main/static/main.css @@ -0,0 +1,238 @@ +html { + background-color: #749cd1; + + font-family: sans-serif; + color: #001527; +} + +#app { + background: repeating-linear-gradient( + #14a04f, + #14a04f 5px, + #085528 5px, + #085528 10px); + margin: 1em; + padding: 1em; + border: 1px solid #313131; +} + +h1 { + color: #fff; +} + +#login { + background-color: #102c46; + padding: 1em; +} + +#login>p { + color: #fff; +} + +a { + border-radius: 2px; + background-image: linear-gradient(45deg, #80a3b9, #749cd1); + padding: 0.3em; + text-decoration: none; + font-weight: 500; + color: #102c46; +} + +a:visited { + color: #281a5a; +} + +#dex-entry { + display: flex; + flex-wrap: wrap; +} + +.outer-border { + background-color: #313131; + padding: 0.2em; + border-radius: 3px 3px 30px 3px; + margin: 0.5em; + width: fit-content; +} + +.inner-area { + background-color: #b8b8b8; + border: 3px solid #fff; + border-radius: 4px 4px 30px 4px; + padding: 1em; + width: 300px; + + display: grid; + grid-template-areas: + 'img stat caught' + 'img type type'; +} + +.image { + grid-area: img; +} + +.stats { + grid-area: stat; +} + +.caught { + grid-area: caught; + width: fit-content; + justify-self: end; +} + +.typelist { + grid-area: type; +} + +.catch { + text-align: center; +} + +.pokeball { + width: 0.8em; +} + +.information { + background-color: #fff; + border-left: 3px solid #b63b0e; + border-right: 3px solid #b63b0e; + padding: 1em; +} + +.fire { + color: #fff; + background-color: #d4784d; + margin: 0.2em; + padding: 0.3em; + border-radius: 2px; +} + +.water { + color: #fff; + background-color: #4f73b6; + margin: 0.2em; + padding: 0.3em; + border-radius: 2px; +} + +.grass { + color: #fff; + background-color: #55c464; + margin: 0.2em; + padding: 0.3em; + border-radius: 2px; +} + +.poison { + color: #fff; + background-color: #723162; + margin: 0.2em; + padding: 0.3em; + border-radius: 2px; +} + +.ghost { + color: #fff; + background-color: #503b55; + margin: 0.2em; + padding: 0.3em; + border-radius: 2px; +} + +.flying { + color: #fff; + background-color: #a284ad; + margin: 0.2em; + padding: 0.3em; + border-radius: 2px; +} + +.bug { + color: #fff; + background-color: #8eac5f; + margin: 0.2em; + padding: 0.3em; + border-radius: 2px; +} + +.dragon { + color: #fff; + background-color: #742ab9; + margin: 0.2em; + padding: 0.3em; + border-radius: 2px; +} + +.ground { + color: #fff; + background-color: #e2aa6a; + margin: 0.2em; + padding: 0.3em; + border-radius: 2px; +} + +.rock { + color: #fff; + background-color: #b48734; + margin: 0.2em; + padding: 0.3em; + border-radius: 2px; +} + +.normal { + color: #fff; + background-color: #a19575; + margin: 0.2em; + padding: 0.3em; + border-radius: 2px; +} + +.fairy { + color: #fff; + background-color: #da7191; + margin: 0.2em; + padding: 0.3em; + border-radius: 2px; +} + +.fighting { + color: #fff; + background-color: #a82e19; + margin: 0.2em; + padding: 0.3em; + border-radius: 2px; +} + +.electric { + color: #fff; + background-color: #dbc337; + margin: 0.2em; + padding: 0.3em; + border-radius: 2px; +} + +.psychic { + color: #fff; + background-color: #cf489b; + margin: 0.2em; + padding: 0.3em; + border-radius: 2px; +} + +.steel { + color: #fff; + background-color: #949494; + margin: 0.2em; + padding: 0.3em; + border-radius: 2px; +} + +.ice { + color: #fff; + background-color: #79e9df; + margin: 0.2em; + padding: 0.3em; + border-radius: 2px; +} \ No newline at end of file diff --git a/code/liam/django/pokedex-main/pokedex-main/static/media/caught.png b/code/liam/django/pokedex-main/pokedex-main/static/media/caught.png new file mode 100644 index 0000000000000000000000000000000000000000..62cf60e3fb46ca708459b9c8d3bb508d030d7cb5 GIT binary patch literal 35313 zcmaI7by!s27cYEFyMf77&nbkXAx^kd_W<1nCBm?(XhR>24(7!}s^x_p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_A6afa`XKB5uj$K4^(^+aDian^p3TP^=vp zl=fh}B{+fr1Of2TJ3k3>0VHI_#b!n9+pWZe9}XzW%xKR!cj?&>Cs78Da42l6YB6l4 zMm@yUQ2{`l#@@KN0E5*UWMHf%=d2|-4+29VfQAgH&w+XXfupORn>Y1puP&F0sEt8f$9U`+TFQ~)rJbj8212_KNSwV zfOBv#R06#8+W*8#z*rUIT;+`AGN`#$MafmH)?A~aU)Qkqc?-v z8(_CV*O?CIz<@#ygo7cRaemml0w?KwJ|X{)3IIZ!(1?)0CaRTn<3M``wF3w1#(+=& zir%^DfpMgB#?JuC84g4!z?E*Mq{w-+agUH2q5^;r7cnBFeod>zuOm~`PMo77yS8z% zC9eI`Ti@)YCm#yDbo$pOgb+dqA%qY@2qA + + + + + + + + + + + Pokedex + + + {% csrf_token %} +
+
+ {% if user.is_authenticated %} +

Welcome, {{ user.username }}!

+

Logout

+ {% else %} +

Welcome, visitor!

+

You are not logged in. Login Sign Up

+ {% endif %} +
+
+ {% if user.is_authenticated %} +
+
+
+
+ +
+
+ ● + O +
+
+
+ #[[ p.number]]: [[ p.name ]] +
+
+
Height:
+
[[p.height]]m
+
Weight:
+
[[p.weight]]kg
+
+
+
+ [[ t.type ]] +
+
+
+ + +
+
+
+ +
+ Catch some new pokemon! +

Pokemon caught this session:

+
    +
  • [[ p ]]
  • +
+
+ + {% else %} +
+ Log in or Sign Up to see! +
+ {% endif %} +
+
+ + \ No newline at end of file diff --git a/code/liam/django/pokedex-main/pokedex-main/templates/registration/login.html b/code/liam/django/pokedex-main/pokedex-main/templates/registration/login.html new file mode 100644 index 00000000..797d9e4c --- /dev/null +++ b/code/liam/django/pokedex-main/pokedex-main/templates/registration/login.html @@ -0,0 +1,6 @@ +

Login

+
+ {% csrf_token %} + {{ form.as_p }} + +
\ No newline at end of file diff --git a/code/liam/django/pokedex-main/pokedex-main/templates/registration/signup.html b/code/liam/django/pokedex-main/pokedex-main/templates/registration/signup.html new file mode 100644 index 00000000..7c681dbc --- /dev/null +++ b/code/liam/django/pokedex-main/pokedex-main/templates/registration/signup.html @@ -0,0 +1,6 @@ +

Sign up

+
+ {% csrf_token %} + {{ form.as_p }} + +
\ No newline at end of file diff --git a/code/liam/django/pokedex-main/pokedex-main/users/__init__.py b/code/liam/django/pokedex-main/pokedex-main/users/__init__.py new file mode 100644 index 00000000..e69de29b diff --git a/code/liam/django/pokedex-main/pokedex-main/users/admin.py b/code/liam/django/pokedex-main/pokedex-main/users/admin.py new file mode 100644 index 00000000..60590641 --- /dev/null +++ b/code/liam/django/pokedex-main/pokedex-main/users/admin.py @@ -0,0 +1,13 @@ +from django.contrib import admin +from django.contrib.auth.admin import UserAdmin + +from .forms import CustomUserCreationForm, CustomUserChangeForm +from .models import CustomUser + +class CustomUserAdmin(UserAdmin): + add_form = CustomUserCreationForm + form = CustomUserChangeForm + model = CustomUser + list_display = ['email', 'username',] + +admin.site.register(CustomUser, CustomUserAdmin) \ No newline at end of file diff --git a/code/liam/django/pokedex-main/pokedex-main/users/apps.py b/code/liam/django/pokedex-main/pokedex-main/users/apps.py new file mode 100644 index 00000000..72b14010 --- /dev/null +++ b/code/liam/django/pokedex-main/pokedex-main/users/apps.py @@ -0,0 +1,6 @@ +from django.apps import AppConfig + + +class UsersConfig(AppConfig): + default_auto_field = 'django.db.models.BigAutoField' + name = 'users' diff --git a/code/liam/django/pokedex-main/pokedex-main/users/forms.py b/code/liam/django/pokedex-main/pokedex-main/users/forms.py new file mode 100644 index 00000000..b0f8bfca --- /dev/null +++ b/code/liam/django/pokedex-main/pokedex-main/users/forms.py @@ -0,0 +1,13 @@ +from django import forms +from django.contrib.auth.forms import UserCreationForm, UserChangeForm +from .models import CustomUser + +class CustomUserCreationForm(UserCreationForm): + class Meta: + model = CustomUser + fields = ('username', 'email') + +class CustomUserChangeForm(UserChangeForm): + class Meta: + model = CustomUser + fields = ('username', 'email') \ No newline at end of file diff --git a/code/liam/django/pokedex-main/pokedex-main/users/migrations/0001_initial.py b/code/liam/django/pokedex-main/pokedex-main/users/migrations/0001_initial.py new file mode 100644 index 00000000..72f498d2 --- /dev/null +++ b/code/liam/django/pokedex-main/pokedex-main/users/migrations/0001_initial.py @@ -0,0 +1,44 @@ +# Generated by Django 3.2 on 2021-08-03 01:11 + +import django.contrib.auth.models +import django.contrib.auth.validators +from django.db import migrations, models +import django.utils.timezone + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ('auth', '0012_alter_user_first_name_max_length'), + ] + + operations = [ + migrations.CreateModel( + name='CustomUser', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('password', models.CharField(max_length=128, verbose_name='password')), + ('last_login', models.DateTimeField(blank=True, null=True, verbose_name='last login')), + ('is_superuser', models.BooleanField(default=False, help_text='Designates that this user has all permissions without explicitly assigning them.', verbose_name='superuser status')), + ('username', models.CharField(error_messages={'unique': 'A user with that username already exists.'}, help_text='Required. 150 characters or fewer. Letters, digits and @/./+/-/_ only.', max_length=150, unique=True, validators=[django.contrib.auth.validators.UnicodeUsernameValidator()], verbose_name='username')), + ('first_name', models.CharField(blank=True, max_length=150, verbose_name='first name')), + ('last_name', models.CharField(blank=True, max_length=150, verbose_name='last name')), + ('email', models.EmailField(blank=True, max_length=254, verbose_name='email address')), + ('is_staff', models.BooleanField(default=False, help_text='Designates whether the user can log into this admin site.', verbose_name='staff status')), + ('is_active', models.BooleanField(default=True, help_text='Designates whether this user should be treated as active. Unselect this instead of deleting accounts.', verbose_name='active')), + ('date_joined', models.DateTimeField(default=django.utils.timezone.now, verbose_name='date joined')), + ('groups', models.ManyToManyField(blank=True, help_text='The groups this user belongs to. A user will get all permissions granted to each of their groups.', related_name='user_set', related_query_name='user', to='auth.Group', verbose_name='groups')), + ('user_permissions', models.ManyToManyField(blank=True, help_text='Specific permissions for this user.', related_name='user_set', related_query_name='user', to='auth.Permission', verbose_name='user permissions')), + ], + options={ + 'verbose_name': 'user', + 'verbose_name_plural': 'users', + 'abstract': False, + }, + managers=[ + ('objects', django.contrib.auth.models.UserManager()), + ], + ), + ] diff --git a/code/liam/django/pokedex-main/pokedex-main/users/migrations/__init__.py b/code/liam/django/pokedex-main/pokedex-main/users/migrations/__init__.py new file mode 100644 index 00000000..e69de29b diff --git a/code/liam/django/pokedex-main/pokedex-main/users/models.py b/code/liam/django/pokedex-main/pokedex-main/users/models.py new file mode 100644 index 00000000..a598ab63 --- /dev/null +++ b/code/liam/django/pokedex-main/pokedex-main/users/models.py @@ -0,0 +1,12 @@ +from django.db import models +from django.contrib.auth.models import AbstractUser + +class CustomUser(AbstractUser): + # caught = the set of Pokemon associated with that user + caught = [] + + # This is where you would add additional fields. + # These will be in the DB alongside username, email, etc + + def __str__(self): + return self.username diff --git a/code/liam/django/pokedex-main/pokedex-main/users/tests.py b/code/liam/django/pokedex-main/pokedex-main/users/tests.py new file mode 100644 index 00000000..7ce503c2 --- /dev/null +++ b/code/liam/django/pokedex-main/pokedex-main/users/tests.py @@ -0,0 +1,3 @@ +from django.test import TestCase + +# Create your tests here. diff --git a/code/liam/django/pokedex-main/pokedex-main/users/urls.py b/code/liam/django/pokedex-main/pokedex-main/users/urls.py new file mode 100644 index 00000000..b33a796e --- /dev/null +++ b/code/liam/django/pokedex-main/pokedex-main/users/urls.py @@ -0,0 +1,8 @@ +from django.urls import path +from .views import SignUpView + +app_name = 'users' + +urlpatterns = [ + path('signup/', SignUpView.as_view(), name='signup'), +] \ No newline at end of file diff --git a/code/liam/django/pokedex-main/pokedex-main/users/views.py b/code/liam/django/pokedex-main/pokedex-main/users/views.py new file mode 100644 index 00000000..d0ac3eb9 --- /dev/null +++ b/code/liam/django/pokedex-main/pokedex-main/users/views.py @@ -0,0 +1,9 @@ +from django.urls import reverse_lazy +from django.views.generic.edit import CreateView + +from .forms import CustomUserCreationForm + +class SignUpView(CreateView): + form_class = CustomUserCreationForm + success_url = reverse_lazy('login') + template_name = 'registration/signup.html' \ No newline at end of file diff --git a/code/liam/django/pokedex-main/requirements.txt b/code/liam/django/pokedex-main/requirements.txt new file mode 100644 index 00000000..22e3cd4f --- /dev/null +++ b/code/liam/django/pokedex-main/requirements.txt @@ -0,0 +1,4 @@ +asgiref==3.4.1 +django==3.2 +pytz==2021.1 +sqlparse==0.4.1 \ No newline at end of file