├── .gitattributes ├── .gitignore ├── .vscode └── settings.json ├── Dockerfile ├── README.md ├── djfans ├── __pycache__ │ └── keys.cpython-38.pyc ├── authy │ ├── __init__.py │ ├── __pycache__ │ │ ├── __init__.cpython-38.pyc │ │ ├── admin.cpython-38.pyc │ │ ├── forms.cpython-38.pyc │ │ ├── models.cpython-38.pyc │ │ ├── urls.cpython-38.pyc │ │ └── views.cpython-38.pyc │ ├── admin.py │ ├── apps.py │ ├── forms.py │ ├── migrations │ │ ├── 0001_initial.py │ │ ├── __init__.py │ │ └── __pycache__ │ │ │ ├── 0001_initial.cpython-38.pyc │ │ │ └── __init__.cpython-38.pyc │ ├── models.py │ ├── tests.py │ ├── urls.py │ └── views.py ├── comment │ ├── __init__.py │ ├── __pycache__ │ │ ├── __init__.cpython-38.pyc │ │ ├── admin.cpython-38.pyc │ │ ├── forms.cpython-38.pyc │ │ └── models.cpython-38.pyc │ ├── admin.py │ ├── apps.py │ ├── forms.py │ ├── migrations │ │ ├── 0001_initial.py │ │ ├── __init__.py │ │ └── __pycache__ │ │ │ ├── 0001_initial.cpython-38.pyc │ │ │ └── __init__.cpython-38.pyc │ ├── models.py │ ├── tests.py │ └── views.py ├── db.sqlite3 ├── direct │ ├── __init__.py │ ├── __pycache__ │ │ ├── __init__.cpython-38.pyc │ │ ├── admin.cpython-38.pyc │ │ ├── models.cpython-38.pyc │ │ ├── urls.cpython-38.pyc │ │ └── views.cpython-38.pyc │ ├── admin.py │ ├── apps.py │ ├── migrations │ │ ├── 0001_initial.py │ │ ├── __init__.py │ │ └── __pycache__ │ │ │ ├── 0001_initial.cpython-38.pyc │ │ │ └── __init__.cpython-38.pyc │ ├── models.py │ ├── tests.py │ ├── urls.py │ └── views.py ├── djfans │ ├── __init__.py │ ├── __pycache__ │ │ ├── __init__.cpython-38.pyc │ │ ├── dev.cpython-38.pyc │ │ ├── settings.cpython-38.pyc │ │ ├── urls.cpython-38.pyc │ │ └── wsgi.cpython-38.pyc │ ├── asgi.py │ ├── local.py │ ├── settings.py │ ├── static │ │ ├── css │ │ │ ├── materialize.css │ │ │ ├── materialize.min.css │ │ │ └── style.css │ │ ├── img │ │ │ ├── favicon.png │ │ │ ├── no_avatar.jpg │ │ │ ├── no_banner.jpg │ │ │ ├── sample-1.jpg │ │ │ ├── sample-2.jpg │ │ │ ├── sample-3.jpg │ │ │ ├── sample-4.jpg │ │ │ ├── sample-5.jpg │ │ │ ├── sample-6.jpg │ │ │ ├── sample-7.jpg │ │ │ └── sample-8.jpg │ │ └── js │ │ │ ├── init.js │ │ │ ├── loadmore.js │ │ │ ├── materialize.js │ │ │ └── materialize.min.js │ ├── templates │ │ ├── base.html │ │ ├── bookmark_list.html │ │ ├── direct │ │ │ ├── can_message_list.html │ │ │ ├── direct.html │ │ │ ├── inbox.html │ │ │ └── search_user.html │ │ ├── fans_list.html │ │ ├── following_list.html │ │ ├── index.html │ │ ├── new_list_modal.html │ │ ├── newpost.html │ │ ├── newtier.html │ │ ├── notifications.html │ │ ├── people_list.html │ │ ├── post_detail.html │ │ ├── profile.html │ │ ├── registration │ │ │ ├── change_password.html │ │ │ ├── change_password_done.html │ │ │ ├── edit_profile.html │ │ │ ├── login.html │ │ │ ├── password_reset_complete.html │ │ │ ├── password_reset_confirm.html │ │ │ ├── password_reset_done.html │ │ │ ├── password_reset_email.html │ │ │ ├── password_reset_form.html │ │ │ ├── password_reset_subject.txt │ │ │ └── signup.html │ │ └── user_lists.html │ ├── urls.py │ └── wsgi.py ├── manage.py ├── media │ ├── user_2 │ │ ├── banner.jpg │ │ ├── paul-volkmer-FGeycwoYGT4-unsplash.jpg │ │ ├── paul-volkmer-FGeycwoYGT4-unsplash_S68W7ca.jpg │ │ ├── paul-volkmer-FGeycwoYGT4-unsplash_Seqa4yi.jpg │ │ ├── paul-volkmer-FGeycwoYGT4-unsplash_UavYjyZ.jpg │ │ ├── paul-volkmer-FGeycwoYGT4-unsplash_npUSKX7.jpg │ │ ├── paul-volkmer-FGeycwoYGT4-unsplash_rIDdsps.jpg │ │ └── profile.jpg │ ├── user_3 │ │ ├── banner.jpg │ │ ├── big-dodzy-adFlSmVeDb4-unsplash.jpg │ │ ├── martin-zdrazil-egsyjg7xmxI-unsplash.jpg │ │ ├── profile.jpg │ │ └── reynier-carl-D9wUdokXcd8-unsplash.jpg │ ├── user_4 │ │ ├── banner.jpg │ │ └── profile.jpg │ └── user_6 │ │ └── spacecharacter.jpg ├── notifications │ ├── __init__.py │ ├── __pycache__ │ │ ├── __init__.cpython-38.pyc │ │ ├── admin.cpython-38.pyc │ │ ├── models.cpython-38.pyc │ │ ├── urls.cpython-38.pyc │ │ └── views.cpython-38.pyc │ ├── admin.py │ ├── apps.py │ ├── migrations │ │ ├── 0001_initial.py │ │ ├── __init__.py │ │ └── __pycache__ │ │ │ ├── 0001_initial.cpython-38.pyc │ │ │ └── __init__.cpython-38.pyc │ ├── models.py │ ├── tests.py │ ├── urls.py │ └── views.py ├── post │ ├── __init__.py │ ├── __pycache__ │ │ ├── __init__.cpython-38.pyc │ │ ├── admin.cpython-38.pyc │ │ ├── forms.cpython-38.pyc │ │ ├── models.cpython-38.pyc │ │ ├── urls.cpython-38.pyc │ │ └── views.cpython-38.pyc │ ├── admin.py │ ├── apps.py │ ├── forms.py │ ├── migrations │ │ ├── 0001_initial.py │ │ ├── 0002_bookmark.py │ │ ├── 0003_post_date.py │ │ ├── 0004_remove_post_date.py │ │ ├── __init__.py │ │ └── __pycache__ │ │ │ ├── 0001_initial.cpython-38.pyc │ │ │ ├── 0002_bookmark.cpython-38.pyc │ │ │ ├── 0003_post_date.cpython-38.pyc │ │ │ ├── 0004_remove_post_date.cpython-38.pyc │ │ │ └── __init__.cpython-38.pyc │ ├── models.py │ ├── signals.py │ ├── tests.py │ ├── urls.py │ └── views.py ├── requirements.txt └── tier │ ├── __init__.py │ ├── __pycache__ │ ├── __init__.cpython-38.pyc │ ├── admin.cpython-38.pyc │ ├── forms.cpython-38.pyc │ ├── models.cpython-38.pyc │ ├── urls.cpython-38.pyc │ └── views.cpython-38.pyc │ ├── admin.py │ ├── apps.py │ ├── forms.py │ ├── migrations │ ├── 0001_initial.py │ ├── __init__.py │ └── __pycache__ │ │ ├── 0001_initial.cpython-38.pyc │ │ └── __init__.cpython-38.pyc │ ├── models.py │ ├── tests.py │ ├── urls.py │ └── views.py ├── docker-compose.yml ├── entrypoint.sh ├── images ├── chat.png ├── diagram.png ├── fanlist.png ├── followinglist.png ├── index.png ├── notification.png ├── profile.png ├── skills.png └── subscription.png ├── nginx ├── Dockerfile └── default.conf ├── static ├── admin │ ├── css │ │ ├── autocomplete.css │ │ ├── base.css │ │ ├── changelists.css │ │ ├── dashboard.css │ │ ├── fonts.css │ │ ├── forms.css │ │ ├── login.css │ │ ├── nav_sidebar.css │ │ ├── responsive.css │ │ ├── responsive_rtl.css │ │ ├── rtl.css │ │ ├── vendor │ │ │ └── select2 │ │ │ │ ├── LICENSE-SELECT2.md │ │ │ │ ├── select2.css │ │ │ │ └── select2.min.css │ │ └── widgets.css │ ├── fonts │ │ ├── LICENSE.txt │ │ ├── README.txt │ │ ├── Roboto-Bold-webfont.woff │ │ ├── Roboto-Light-webfont.woff │ │ └── Roboto-Regular-webfont.woff │ ├── img │ │ ├── LICENSE │ │ ├── README.txt │ │ ├── calendar-icons.svg │ │ ├── gis │ │ │ ├── move_vertex_off.svg │ │ │ └── move_vertex_on.svg │ │ ├── icon-addlink.svg │ │ ├── icon-alert.svg │ │ ├── icon-calendar.svg │ │ ├── icon-changelink.svg │ │ ├── icon-clock.svg │ │ ├── icon-deletelink.svg │ │ ├── icon-no.svg │ │ ├── icon-unknown-alt.svg │ │ ├── icon-unknown.svg │ │ ├── icon-viewlink.svg │ │ ├── icon-yes.svg │ │ ├── inline-delete.svg │ │ ├── search.svg │ │ ├── selector-icons.svg │ │ ├── sorting-icons.svg │ │ ├── tooltag-add.svg │ │ └── tooltag-arrowright.svg │ └── js │ │ ├── SelectBox.js │ │ ├── SelectFilter2.js │ │ ├── actions.js │ │ ├── actions.min.js │ │ ├── admin │ │ ├── DateTimeShortcuts.js │ │ └── RelatedObjectLookups.js │ │ ├── autocomplete.js │ │ ├── calendar.js │ │ ├── cancel.js │ │ ├── change_form.js │ │ ├── collapse.js │ │ ├── collapse.min.js │ │ ├── core.js │ │ ├── inlines.js │ │ ├── inlines.min.js │ │ ├── jquery.init.js │ │ ├── nav_sidebar.js │ │ ├── popup_response.js │ │ ├── prepopulate.js │ │ ├── prepopulate.min.js │ │ ├── prepopulate_init.js │ │ ├── urlify.js │ │ └── vendor │ │ ├── jquery │ │ ├── LICENSE.txt │ │ ├── jquery.js │ │ └── jquery.min.js │ │ ├── select2 │ │ ├── LICENSE.md │ │ ├── i18n │ │ │ ├── af.js │ │ │ ├── ar.js │ │ │ ├── az.js │ │ │ ├── bg.js │ │ │ ├── bn.js │ │ │ ├── bs.js │ │ │ ├── ca.js │ │ │ ├── cs.js │ │ │ ├── da.js │ │ │ ├── de.js │ │ │ ├── dsb.js │ │ │ ├── el.js │ │ │ ├── en.js │ │ │ ├── es.js │ │ │ ├── et.js │ │ │ ├── eu.js │ │ │ ├── fa.js │ │ │ ├── fi.js │ │ │ ├── fr.js │ │ │ ├── gl.js │ │ │ ├── he.js │ │ │ ├── hi.js │ │ │ ├── hr.js │ │ │ ├── hsb.js │ │ │ ├── hu.js │ │ │ ├── hy.js │ │ │ ├── id.js │ │ │ ├── is.js │ │ │ ├── it.js │ │ │ ├── ja.js │ │ │ ├── ka.js │ │ │ ├── km.js │ │ │ ├── ko.js │ │ │ ├── lt.js │ │ │ ├── lv.js │ │ │ ├── mk.js │ │ │ ├── ms.js │ │ │ ├── nb.js │ │ │ ├── ne.js │ │ │ ├── nl.js │ │ │ ├── pl.js │ │ │ ├── ps.js │ │ │ ├── pt-BR.js │ │ │ ├── pt.js │ │ │ ├── ro.js │ │ │ ├── ru.js │ │ │ ├── sk.js │ │ │ ├── sl.js │ │ │ ├── sq.js │ │ │ ├── sr-Cyrl.js │ │ │ ├── sr.js │ │ │ ├── sv.js │ │ │ ├── th.js │ │ │ ├── tk.js │ │ │ ├── tr.js │ │ │ ├── uk.js │ │ │ ├── vi.js │ │ │ ├── zh-CN.js │ │ │ └── zh-TW.js │ │ ├── select2.full.js │ │ └── select2.full.min.js │ │ └── xregexp │ │ ├── LICENSE.txt │ │ ├── xregexp.js │ │ └── xregexp.min.js ├── css │ ├── materialize.css │ ├── materialize.min.css │ └── style.css ├── img │ ├── no_avatar.jpg │ ├── no_banner.jpg │ ├── sample-1.jpg │ ├── sample-2.jpg │ ├── sample-3.jpg │ ├── sample-4.jpg │ ├── sample-5.jpg │ ├── sample-6.jpg │ ├── sample-7.jpg │ └── sample-8.jpg └── js │ ├── init.js │ ├── loadmore.js │ ├── materialize.js │ └── materialize.min.js └── temp └── settings.py /.gitattributes: -------------------------------------------------------------------------------- 1 | # Auto detect text files and perform LF normalization 2 | * text=auto 3 | /docker/* text eol=lf 4 | /ci/* text eol=lf 5 | /sbt text eol=lf 6 | /docker-*.sh text eol=lf 7 | /sbt-dist/bin/*.bash text eol=lf 8 | /sbt-dist/bin/sbt text eol=lf -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | .vscode 2 | keys.py 3 | .env 4 | .env 5 | .env 6 | -------------------------------------------------------------------------------- /.vscode/settings.json: -------------------------------------------------------------------------------- 1 | { 2 | "python.pythonPath": "C:\\Users\\49173\\envs\\djfans\\Scripts\\python.exe" 3 | } -------------------------------------------------------------------------------- /Dockerfile: -------------------------------------------------------------------------------- 1 | FROM python:3.8.6 2 | 3 | RUN pip install --upgrade pip 4 | 5 | 6 | COPY ./djfans/requirements.txt . 7 | RUN pip install -r requirements.txt 8 | 9 | 10 | COPY ./djfans /djfans 11 | 12 | WORKDIR /djfans 13 | 14 | COPY ./entrypoint.sh / 15 | 16 | 17 | 18 | ENTRYPOINT ["sh", "/entrypoint.sh"] 19 | 20 | 21 | -------------------------------------------------------------------------------- /djfans/__pycache__/keys.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/__pycache__/keys.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/authy/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/authy/__init__.py -------------------------------------------------------------------------------- /djfans/authy/__pycache__/__init__.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/authy/__pycache__/__init__.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/authy/__pycache__/admin.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/authy/__pycache__/admin.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/authy/__pycache__/forms.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/authy/__pycache__/forms.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/authy/__pycache__/models.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/authy/__pycache__/models.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/authy/__pycache__/urls.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/authy/__pycache__/urls.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/authy/__pycache__/views.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/authy/__pycache__/views.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/authy/admin.py: -------------------------------------------------------------------------------- 1 | from django.contrib import admin 2 | from authy.models import Profile 3 | 4 | # Register your models here. 5 | admin.site.register(Profile) 6 | -------------------------------------------------------------------------------- /djfans/authy/apps.py: -------------------------------------------------------------------------------- 1 | from django.apps import AppConfig 2 | 3 | 4 | class AuthyConfig(AppConfig): 5 | name = 'authy' 6 | -------------------------------------------------------------------------------- /djfans/authy/migrations/0001_initial.py: -------------------------------------------------------------------------------- 1 | # Generated by Django 3.1.7 on 2021-03-04 20:41 2 | 3 | import authy.models 4 | from django.conf import settings 5 | from django.db import migrations, models 6 | import django.db.models.deletion 7 | 8 | 9 | class Migration(migrations.Migration): 10 | 11 | initial = True 12 | 13 | dependencies = [ 14 | migrations.swappable_dependency(settings.AUTH_USER_MODEL), 15 | ] 16 | 17 | operations = [ 18 | migrations.CreateModel( 19 | name='Profile', 20 | fields=[ 21 | ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), 22 | ('location', models.CharField(blank=True, max_length=50, null=True)), 23 | ('url', models.CharField(blank=True, max_length=80, null=True)), 24 | ('profile_info', models.TextField(blank=True, max_length=150, null=True)), 25 | ('created', models.DateField(auto_now_add=True)), 26 | ('picture', models.ImageField(blank=True, null=True, upload_to=authy.models.user_directory_path_profile, verbose_name='Picture')), 27 | ('banner', models.ImageField(blank=True, null=True, upload_to=authy.models.user_directory_path_banner, verbose_name='Banner')), 28 | ('user', models.OneToOneField(on_delete=django.db.models.deletion.CASCADE, related_name='profile', to=settings.AUTH_USER_MODEL)), 29 | ], 30 | ), 31 | migrations.CreateModel( 32 | name='PeopleList', 33 | fields=[ 34 | ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), 35 | ('title', models.CharField(max_length=150)), 36 | ('people', models.ManyToManyField(related_name='people_user', to=settings.AUTH_USER_MODEL)), 37 | ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='list_user', to=settings.AUTH_USER_MODEL)), 38 | ], 39 | ), 40 | ] 41 | -------------------------------------------------------------------------------- /djfans/authy/migrations/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/authy/migrations/__init__.py -------------------------------------------------------------------------------- /djfans/authy/migrations/__pycache__/0001_initial.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/authy/migrations/__pycache__/0001_initial.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/authy/migrations/__pycache__/__init__.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/authy/migrations/__pycache__/__init__.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/authy/models.py: -------------------------------------------------------------------------------- 1 | from django.db import models 2 | from django.contrib.auth.models import User 3 | from django.core.files.storage import default_storage as storage 4 | from django.db.models.signals import post_save 5 | 6 | from PIL import Image 7 | from django.conf import settings 8 | import os 9 | 10 | 11 | def user_directory_path_profile(instance, filename): 12 | # file will be uploaded to MEDIA_ROOT/user_/ 13 | profile_pic_name = 'user_{0}/profile.jpg'.format(instance.user.id) 14 | full_path = os.path.join(settings.MEDIA_ROOT, profile_pic_name) 15 | 16 | if os.path.exists(full_path): 17 | os.remove(full_path) 18 | 19 | return profile_pic_name 20 | 21 | 22 | def user_directory_path_banner(instance, filename): 23 | # file will be uploaded to MEDIA_ROOT/user_/ 24 | banner_pic_name = 'user_{0}/banner.jpg'.format(instance.user.id) 25 | full_path = os.path.join(settings.MEDIA_ROOT, banner_pic_name) 26 | 27 | if os.path.exists(full_path): 28 | os.remove(full_path) 29 | 30 | return banner_pic_name 31 | 32 | # Create your models here. 33 | 34 | 35 | class Profile(models.Model): 36 | user = models.OneToOneField( 37 | User, on_delete=models.CASCADE, related_name='profile') 38 | location = models.CharField(max_length=50, null=True, blank=True) 39 | url = models.CharField(max_length=80, null=True, blank=True) 40 | profile_info = models.TextField(max_length=150, null=True, blank=True) 41 | created = models.DateField(auto_now_add=True) 42 | picture = models.ImageField( 43 | upload_to=user_directory_path_profile, blank=True, null=True, verbose_name='Picture') 44 | banner = models.ImageField( 45 | upload_to=user_directory_path_banner, blank=True, null=True, verbose_name='Banner') 46 | 47 | def save(self, *args, **kwargs): 48 | super().save(*args, **kwargs) 49 | SIZE = 250, 250 50 | 51 | if self.picture: 52 | pic = Image.open(self.picture) 53 | pic.thumbnail(SIZE, Image.LANCZOS) 54 | storage_path = storage.open(self.picture.name, "wb") 55 | pic.save(storage_path) 56 | storage_path.close() 57 | 58 | return self 59 | 60 | def __str__(self): 61 | return self.user.username 62 | 63 | 64 | def create_user_profile(sender, instance, created, **kwargs): 65 | if created: 66 | Profile.objects.create(user=instance) 67 | 68 | 69 | def save_user_profile(sender, instance, **kwargs): 70 | instance.profile.save() 71 | 72 | 73 | class PeopleList(models.Model): 74 | title = models.CharField(max_length=150) 75 | user = models.ForeignKey( 76 | User, on_delete=models.CASCADE, related_name='list_user') 77 | people = models.ManyToManyField(User, related_name='people_user') 78 | 79 | 80 | post_save.connect(create_user_profile, sender=User) 81 | post_save.connect(save_user_profile, sender=User) 82 | -------------------------------------------------------------------------------- /djfans/authy/tests.py: -------------------------------------------------------------------------------- 1 | from django.test import TestCase 2 | 3 | # Create your tests here. 4 | -------------------------------------------------------------------------------- /djfans/authy/urls.py: -------------------------------------------------------------------------------- 1 | from django.urls import path, include 2 | from authy.views import UserProfile, Signup, PasswordChange, PasswordChangeDone, EditProfile, addToList, ShowList, listpeople, listpeopledelete 3 | from django.contrib.auth import views as authViews 4 | 5 | 6 | urlpatterns = [ 7 | 8 | path('profile/edit', EditProfile, name='edit-profile'), 9 | path('signup/', Signup, name='signup'), 10 | path('login/', authViews.LoginView.as_view(template_name='registration/login.html'), name='login'), 11 | path('githubin/', include('allauth.urls')), 12 | path('logout/', authViews.LogoutView.as_view(), 13 | {'next_page': 'index'}, name='logout'), 14 | path('changepassword/', PasswordChange, name='change_password'), 15 | path('changepassword/done', PasswordChangeDone, name='change_password_done'), 16 | path('passwordreset/', authViews.PasswordResetView.as_view(), 17 | name='password_reset'), 18 | path('passwordreset/done', authViews.PasswordResetDoneView.as_view(), 19 | name='password_reset_done'), 20 | path('passwordreset///', 21 | authViews.PasswordResetConfirmView.as_view(), name='password_reset_confirm'), 22 | path('passwordreset/complete/', authViews.PasswordResetCompleteView.as_view(), 23 | name='password_reset_complete'), 24 | path('profile/addtolist', addToList, name='add-to-list'), 25 | path('mylists', ShowList, name='show-my-lists'), 26 | path('mylists/', listpeople, name='list-people'), 27 | path('mylists//delete', listpeopledelete, name='list-people-delete'), 28 | 29 | ] 30 | -------------------------------------------------------------------------------- /djfans/comment/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/comment/__init__.py -------------------------------------------------------------------------------- /djfans/comment/__pycache__/__init__.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/comment/__pycache__/__init__.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/comment/__pycache__/admin.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/comment/__pycache__/admin.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/comment/__pycache__/forms.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/comment/__pycache__/forms.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/comment/__pycache__/models.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/comment/__pycache__/models.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/comment/admin.py: -------------------------------------------------------------------------------- 1 | from django.contrib import admin 2 | 3 | # Register your models here. 4 | -------------------------------------------------------------------------------- /djfans/comment/apps.py: -------------------------------------------------------------------------------- 1 | from django.apps import AppConfig 2 | 3 | 4 | class CommentConfig(AppConfig): 5 | name = 'comment' 6 | -------------------------------------------------------------------------------- /djfans/comment/forms.py: -------------------------------------------------------------------------------- 1 | from django import forms 2 | from comment.models import Comment 3 | 4 | 5 | class CommentForm(forms.ModelForm): 6 | body = forms.CharField(widget=forms.Textarea( 7 | attrs={'class': 'validate'}), required=True) 8 | 9 | class Meta: 10 | model = Comment 11 | fields = ('body',) 12 | -------------------------------------------------------------------------------- /djfans/comment/migrations/0001_initial.py: -------------------------------------------------------------------------------- 1 | # Generated by Django 3.1.7 on 2021-03-15 20:13 2 | 3 | from django.conf import settings 4 | from django.db import migrations, models 5 | import django.db.models.deletion 6 | 7 | 8 | class Migration(migrations.Migration): 9 | 10 | initial = True 11 | 12 | dependencies = [ 13 | ('post', '0002_bookmark'), 14 | migrations.swappable_dependency(settings.AUTH_USER_MODEL), 15 | ] 16 | 17 | operations = [ 18 | migrations.CreateModel( 19 | name='Comment', 20 | fields=[ 21 | ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), 22 | ('body', models.TextField()), 23 | ('date', models.DateTimeField(auto_now_add=True)), 24 | ('post', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='post_comments', to='post.post')), 25 | ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)), 26 | ], 27 | ), 28 | ] 29 | -------------------------------------------------------------------------------- /djfans/comment/migrations/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/comment/migrations/__init__.py -------------------------------------------------------------------------------- /djfans/comment/migrations/__pycache__/0001_initial.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/comment/migrations/__pycache__/0001_initial.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/comment/migrations/__pycache__/__init__.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/comment/migrations/__pycache__/__init__.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/comment/models.py: -------------------------------------------------------------------------------- 1 | from django.db import models 2 | 3 | from post.models import Post 4 | from notifications.models import Notification 5 | from django.contrib.auth.models import User 6 | 7 | from django.db.models.signals import post_save, post_delete 8 | 9 | # Create your models here. 10 | 11 | 12 | class Comment(models.Model): 13 | post = models.ForeignKey( 14 | Post, on_delete=models.CASCADE, related_name='post_comments') 15 | user = models.ForeignKey(User, on_delete=models.CASCADE) 16 | body = models.TextField() 17 | date = models.DateTimeField(auto_now_add=True) 18 | 19 | def user_comment_post(sender, instance, *args, **kwargs): 20 | comment = instance 21 | post = comment.post 22 | sender = comment.user 23 | text_preview = comment.body[:50] 24 | 25 | notify = Notification(post=post, sender=sender, user=post.user, 26 | text_preview=text_preview, notification_type=2) 27 | notify.save() 28 | 29 | def user_del_comment_post(sender, instance, *args, **kwargs): 30 | comment = instance 31 | post = comment.post 32 | sender = comment.user 33 | notify = Notification.objects.filter( 34 | post=post, sender=sender, notification_type=2) 35 | notify.delete() 36 | 37 | 38 | # Comments signals stuff: 39 | post_save.connect(Comment.user_comment_post, sender=Comment) 40 | post_delete.connect(Comment.user_del_comment_post, sender=Comment) 41 | -------------------------------------------------------------------------------- /djfans/comment/tests.py: -------------------------------------------------------------------------------- 1 | from django.test import TestCase 2 | 3 | # Create your tests here. 4 | -------------------------------------------------------------------------------- /djfans/comment/views.py: -------------------------------------------------------------------------------- 1 | from django.shortcuts import render 2 | 3 | # Create your views here. 4 | -------------------------------------------------------------------------------- /djfans/db.sqlite3: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/db.sqlite3 -------------------------------------------------------------------------------- /djfans/direct/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/direct/__init__.py -------------------------------------------------------------------------------- /djfans/direct/__pycache__/__init__.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/direct/__pycache__/__init__.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/direct/__pycache__/admin.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/direct/__pycache__/admin.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/direct/__pycache__/models.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/direct/__pycache__/models.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/direct/__pycache__/urls.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/direct/__pycache__/urls.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/direct/__pycache__/views.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/direct/__pycache__/views.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/direct/admin.py: -------------------------------------------------------------------------------- 1 | from django.contrib import admin 2 | 3 | # Register your models here. 4 | -------------------------------------------------------------------------------- /djfans/direct/apps.py: -------------------------------------------------------------------------------- 1 | from django.apps import AppConfig 2 | 3 | 4 | class DirectConfig(AppConfig): 5 | name = 'direct' 6 | -------------------------------------------------------------------------------- /djfans/direct/migrations/0001_initial.py: -------------------------------------------------------------------------------- 1 | # Generated by Django 3.1.7 on 2021-03-15 20:30 2 | 3 | from django.conf import settings 4 | from django.db import migrations, models 5 | import django.db.models.deletion 6 | 7 | 8 | class Migration(migrations.Migration): 9 | 10 | initial = True 11 | 12 | dependencies = [ 13 | migrations.swappable_dependency(settings.AUTH_USER_MODEL), 14 | ] 15 | 16 | operations = [ 17 | migrations.CreateModel( 18 | name='Message', 19 | fields=[ 20 | ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), 21 | ('body', models.TextField(blank=True, max_length=1000, null=True)), 22 | ('date', models.DateTimeField(auto_now_add=True)), 23 | ('is_read', models.BooleanField(default=False)), 24 | ('recipient', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='to_user', to=settings.AUTH_USER_MODEL)), 25 | ('sender', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='from_user', to=settings.AUTH_USER_MODEL)), 26 | ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='msg_user', to=settings.AUTH_USER_MODEL)), 27 | ], 28 | ), 29 | ] 30 | -------------------------------------------------------------------------------- /djfans/direct/migrations/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/direct/migrations/__init__.py -------------------------------------------------------------------------------- /djfans/direct/migrations/__pycache__/0001_initial.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/direct/migrations/__pycache__/0001_initial.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/direct/migrations/__pycache__/__init__.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/direct/migrations/__pycache__/__init__.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/direct/models.py: -------------------------------------------------------------------------------- 1 | from django.db import models 2 | from django.db.models import Max 3 | 4 | from django.contrib.auth.models import User 5 | # Create your models here. 6 | 7 | 8 | class Message(models.Model): 9 | user = models.ForeignKey( 10 | User, on_delete=models.CASCADE, related_name='msg_user') 11 | sender = models.ForeignKey( 12 | User, on_delete=models.CASCADE, related_name='from_user') 13 | recipient = models.ForeignKey( 14 | User, on_delete=models.CASCADE, related_name='to_user') 15 | body = models.TextField(max_length=1000, blank=True, null=True) 16 | date = models.DateTimeField(auto_now_add=True) 17 | is_read = models.BooleanField(default=False) 18 | 19 | def send_message(from_user, to_user, body): 20 | sender_message = Message( 21 | user=from_user, 22 | sender=from_user, 23 | recipient=to_user, 24 | body=body, 25 | is_read=True) 26 | sender_message.save() 27 | 28 | recipient_message = Message( 29 | user=to_user, 30 | sender=from_user, 31 | body=body, 32 | recipient=from_user,) 33 | recipient_message.save() 34 | return sender_message 35 | 36 | def get_messages(user): 37 | messages = Message.objects.filter(user=user).values( 38 | 'recipient').annotate(last=Max('date')).order_by('-last') 39 | users = [] 40 | for message in messages: 41 | users.append({ 42 | 'user': User.objects.get(pk=message['recipient']), 43 | 'last': message['last'], 44 | 'unread': Message.objects.filter(user=user, recipient__pk=message['recipient'], is_read=False).count() 45 | }) 46 | return users 47 | -------------------------------------------------------------------------------- /djfans/direct/tests.py: -------------------------------------------------------------------------------- 1 | from django.test import TestCase 2 | 3 | # Create your tests here. 4 | -------------------------------------------------------------------------------- /djfans/direct/urls.py: -------------------------------------------------------------------------------- 1 | from django.urls import path 2 | from direct.views import inbox, PeopleWeCanMessage, NewConversation, Directs, SendDirect, LoadMore, UserSearch 3 | 4 | urlpatterns = [ 5 | path('', inbox, name='inbox'), 6 | path('start/', PeopleWeCanMessage, name='people-we-can-message'), 7 | path('new/', NewConversation, name='new-conversation'), 8 | path('directs/', Directs, name='directs'), 9 | path('send/', SendDirect, name='send-direct'), 10 | path('loadmore/', LoadMore, name='loadmore'), 11 | path('search/', UserSearch, name='user-search'), 12 | 13 | ] 14 | -------------------------------------------------------------------------------- /djfans/djfans/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/djfans/__init__.py -------------------------------------------------------------------------------- /djfans/djfans/__pycache__/__init__.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/djfans/__pycache__/__init__.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/djfans/__pycache__/dev.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/djfans/__pycache__/dev.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/djfans/__pycache__/settings.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/djfans/__pycache__/settings.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/djfans/__pycache__/urls.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/djfans/__pycache__/urls.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/djfans/__pycache__/wsgi.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/djfans/__pycache__/wsgi.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/djfans/asgi.py: -------------------------------------------------------------------------------- 1 | """ 2 | ASGI config for djfans project. 3 | 4 | It exposes the ASGI callable as a module-level variable named ``application``. 5 | 6 | For more information on this file, see 7 | https://docs.djangoproject.com/en/3.1/howto/deployment/asgi/ 8 | """ 9 | 10 | import os 11 | 12 | from django.core.asgi import get_asgi_application 13 | 14 | os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'djfans.settings') 15 | 16 | application = get_asgi_application() 17 | -------------------------------------------------------------------------------- /djfans/djfans/local.py: -------------------------------------------------------------------------------- 1 | from .settings import * 2 | 3 | 4 | # Running env - Local 5 | 6 | SECRET_KEY = '-nro!j**h$!c=d(*r30+u46g$^(oge1!*9ymb4v8ks9%mwyim%' 7 | DEBUG = True 8 | ALLOWED_HOSTS = [] 9 | 10 | 11 | # Database - Sqlite3 12 | 13 | DATABASES = { 14 | 'default': { 15 | 'ENGINE': 'django.db.backends.sqlite3', 16 | 'NAME': BASE_DIR / 'db.sqlite3', 17 | } 18 | } 19 | 20 | 21 | # static setting 22 | 23 | STATIC_URL = '/static/' 24 | STATIC_ROOT = os.path.join(ROOT_DIR, 'static') 25 | STATICFILES_DIRS = [ 26 | os.path.join(BASE_DIR, 'djfans/static'), 27 | ] 28 | 29 | 30 | # media setting 31 | 32 | MEDIA_URL = '/media/' 33 | MEDIA_ROOT = os.path.join(BASE_DIR, 'media') 34 | -------------------------------------------------------------------------------- /djfans/djfans/static/css/style.css: -------------------------------------------------------------------------------- 1 | /* Custom Stylesheet */ 2 | /** 3 | * Use this file to override Materialize files so you can update 4 | * the core Materialize files in the future 5 | * 6 | * Made By MaterializeCSS.com 7 | */ 8 | 9 | 10 | .icon-block { 11 | padding: 0 15px; 12 | } 13 | .icon-block .material-icons { 14 | font-size: inherit; 15 | } 16 | 17 | 18 | 19 | /* Blackwhite img hover */ 20 | /* 21 | .image-wrapper { 22 | background: white !important; 23 | } 24 | .image-wrapper img { 25 | mix-blend-mode: luminosity !important; 26 | } 27 | .image-wrapper img:hover { 28 | mix-blend-mode: normal !important; 29 | } */ 30 | 31 | 32 | /* scrollbar visible */ 33 | /* .scroll-item::-webkit-scrollbar { 34 | width: 10px; 35 | } 36 | .scroll-item::-webkit-scrollbar-thumb { 37 | background-color: #2f3542; 38 | border-radius: 10px; 39 | } 40 | .scroll-item::-webkit-scrollbar-track { 41 | background-color: grey; 42 | border-radius: 10px; 43 | box-shadow: inset 0px 0px 5px white; 44 | } */ 45 | 46 | /* invisivle scroll*/ 47 | .scroll-item{ 48 | -ms-overflow-style: none; 49 | } 50 | .scroll-item::-webkit-scrollbar{ 51 | display:none; 52 | } 53 | 54 | 55 | -------------------------------------------------------------------------------- /djfans/djfans/static/img/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/djfans/static/img/favicon.png -------------------------------------------------------------------------------- /djfans/djfans/static/img/no_avatar.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/djfans/static/img/no_avatar.jpg -------------------------------------------------------------------------------- /djfans/djfans/static/img/no_banner.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/djfans/static/img/no_banner.jpg -------------------------------------------------------------------------------- /djfans/djfans/static/img/sample-1.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/djfans/static/img/sample-1.jpg -------------------------------------------------------------------------------- /djfans/djfans/static/img/sample-2.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/djfans/static/img/sample-2.jpg -------------------------------------------------------------------------------- /djfans/djfans/static/img/sample-3.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/djfans/static/img/sample-3.jpg -------------------------------------------------------------------------------- /djfans/djfans/static/img/sample-4.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/djfans/static/img/sample-4.jpg -------------------------------------------------------------------------------- /djfans/djfans/static/img/sample-5.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/djfans/static/img/sample-5.jpg -------------------------------------------------------------------------------- /djfans/djfans/static/img/sample-6.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/djfans/static/img/sample-6.jpg -------------------------------------------------------------------------------- /djfans/djfans/static/img/sample-7.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/djfans/static/img/sample-7.jpg -------------------------------------------------------------------------------- /djfans/djfans/static/img/sample-8.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/djfans/static/img/sample-8.jpg -------------------------------------------------------------------------------- /djfans/djfans/static/js/init.js: -------------------------------------------------------------------------------- 1 | (function ($) { 2 | $(function () { 3 | 4 | $('.sidenav').sidenav(); 5 | $('.tabs').tabs(); 6 | $('.materialboxed').materialbox(); 7 | $('select').formSelect(); 8 | $('.slider').slider(); 9 | $('.tooltipped').tooltip(); 10 | $('.modal').modal(); 11 | 12 | $("addtolistform").submit(function () { 13 | $.ajax({ 14 | url: '/profile/addtolist', 15 | data: $("#addtolistform").serialize(), 16 | cache: false, 17 | type: "post", 18 | success: function (data) { 19 | console.log("Person added succesfully") 20 | } 21 | }); 22 | return false; 23 | }); 24 | 25 | }); // end of document ready 26 | })(jQuery); // end of jQuery name space 27 | -------------------------------------------------------------------------------- /djfans/djfans/static/js/loadmore.js: -------------------------------------------------------------------------------- 1 | (function ($) { 2 | 3 | $("#loadmorebtn").click(function () { 4 | var username = document.getElementsByName("to_user")[0].value; 5 | var directspage = document.getElementById('page_number'); 6 | var page_number = parseInt(directspage.value); 7 | 8 | $.ajax({ 9 | url: '/messages/loadmore/', 10 | data: { 11 | 'directspage': page_number, 12 | 'username': username, 13 | 'csrfmiddlewaretoken': window.CSRF_TOKEN 14 | }, 15 | cache: false, 16 | type: 'post', 17 | success: function (data) { 18 | if (data.empty == true) { 19 | $("#loadmorebtn").hide(); 20 | } else { 21 | $.each(data, function (i, v) { 22 | var ol_collection_html = '
  • ' + v.sender__first_name + ' ' + v.sender__last_name + '

    ' + v.body + '

    ' + v.date + '

  • '; 23 | $('#oldirects').append(ol_collection_html); 24 | }); 25 | } 26 | page_number = page_number + 1; 27 | $("#page_number").attr('value', page_number); 28 | 29 | } 30 | }); 31 | return false; 32 | }); 33 | // end of document ready 34 | }(jQuery)); // end of jQuery name space -------------------------------------------------------------------------------- /djfans/djfans/templates/bookmark_list.html: -------------------------------------------------------------------------------- 1 | {% extends 'base.html' %} 2 | {% load static %} 3 | 4 | {% block content %} 5 |
    6 |
    7 |
    My favorite posts
    8 |

    Posts saved

    9 |
    10 |
    11 | 12 | {% for post in bookmark_data %} 13 |
    14 |
    15 | 16 |
    17 | {% if post.content.first.file.name|slice:"-3:" == 'jpg' %} 18 | 19 | {{ post.title }} 20 | favorite 21 | {% else %} 22 |
    23 | 26 |
    27 | {% endif %} 28 |
    29 | 30 |
    31 | {{ post.caption }} 32 |

    Click to see Full post

    33 |
    34 | 35 |
    36 |
    37 |
    38 | {% if post.user.profile.picture %} 39 | 40 | {% else %} 41 | 42 | {% endif %} 43 |
    44 |
    45 |
    {{ post.user.first_name }} {{ post.user.last_name }}
    46 | Published on: {{ post.posted }} 47 |
    48 |
    49 |
    50 | 51 | 56 | 57 |
    58 |
    59 | {% endfor %} 60 | 61 |
    62 | {% if bookmark_data.has_previous %} 63 | arrow_backBack 64 | {% endif %} 65 | 66 | {% if bookmark_data.has_next %} 67 | addLoad more 68 | {% endif %} 69 |
    70 | 71 | {% endblock %} -------------------------------------------------------------------------------- /djfans/djfans/templates/direct/can_message_list.html: -------------------------------------------------------------------------------- 1 | {% extends 'base.html' %} 2 | {% load static %} 3 | 4 | {% block content %} 5 |
    6 |
    People that you are following
    7 |

    These people are the ones that you can message:

    8 |
    9 |
    10 | 11 | {% for person in people %} 12 |
    13 |
    14 |
    15 | {% if person.subscribed.profile.banner %} 16 | 17 | {% else %} 18 | 19 | {% endif %} 20 |
    21 |
    22 |
    23 |
    24 | {% if person.subscribed.profile.picture %} 25 | 26 | {% else %} 27 | 28 | {% endif %} 29 |
    30 |
    31 | 32 | {{ person.subscribed.first_name }} {{ person.subscribed.last_name }} 33 | 34 |
    35 | @{{ person.subscribed.username }} 36 |

    {{ person.subscribed.profile.profile_info }}

    37 | sendmessage 38 |
    39 |
    40 |
    41 |
    42 |
    43 | {% endfor %} 44 | 45 | 46 | {% endblock %} -------------------------------------------------------------------------------- /djfans/djfans/templates/direct/inbox.html: -------------------------------------------------------------------------------- 1 | {% extends 'base.html' %} 2 | {% load static %} 3 | 4 | {% block content %} 5 | 6 | 37 |
    38 | searchSearch 39 | personFollowing 40 |
    41 | {% endblock %} -------------------------------------------------------------------------------- /djfans/djfans/templates/direct/search_user.html: -------------------------------------------------------------------------------- 1 | {% extends 'base.html' %} 2 | {% load static %} 3 | 4 | {% block content %} 5 | 6 |
    7 |

    Search users

    8 | Find users that you can messsage 9 |
    10 |
    11 | 12 | 13 |
    14 | 17 |
    18 |
    19 | 20 | {% for person in users %} 21 |
    22 |
    23 |
    24 | {% if person.subscribed.profile.banner %} 25 | 26 | {% else %} 27 | 28 | {% endif %} 29 |
    30 |
    31 |
    32 |
    33 | {% if person.subscribed.profile.picture %} 34 | 35 | {% else %} 36 | 37 | {% endif %} 38 |
    39 |
    40 | 41 | {{ person.subscribed.first_name }} {{ person.subscribed.last_name }} 42 | 43 |
    44 | @{{ person.subscribed.username }} 45 |

    {{ person.subscribed.profile.profile_info }}

    46 | sendSend a message! 47 |
    48 |
    49 |
    50 |
    51 |
    52 | {% endfor %} 53 | 54 | {% endblock %} -------------------------------------------------------------------------------- /djfans/djfans/templates/fans_list.html: -------------------------------------------------------------------------------- 1 | {% extends 'base.html' %} 2 | {% load static %} 3 | 4 | {% block content %} 5 | 6 |
    7 |
    People subscribed to me:
    8 |
    9 |
    10 | 11 | {% for person in my_fans %} 12 |
    13 |
    14 |
    15 | {% if person.subscriber.profile.banner %} 16 | 17 | {% else %} 18 | 19 | {% endif %} 20 |
    21 |
    22 |
    23 |
    24 | {% if person.subscriber.profile.picture %} 25 | 26 | {% else %} 27 | 28 | {% endif %} 29 |
    30 |
    31 | 32 | {{ person.subscriber.first_name }} {{ person.subscriber.last_name }} 33 | 34 |
    35 | @{{ person.subscriber.username }} 36 |

    {{ person.subscriber.profile.profile_info }}

    37 |
    38 |
    39 |
    40 |
    41 |
    42 | {% endfor %} 43 | 44 | 45 | {% endblock %} -------------------------------------------------------------------------------- /djfans/djfans/templates/following_list.html: -------------------------------------------------------------------------------- 1 | {% extends 'base.html' %} 2 | {% load static %} 3 | 4 | {% block content %} 5 |
    6 |
    My subscriptions:
    7 |

    People I am following

    8 |
    9 |
    10 | 11 | {% for person in my_follows %} 12 |
    13 |
    14 |
    15 | {% if person.subscribed.profile.banner %} 16 | 17 | {% else %} 18 | 19 | {% endif %} 20 |
    21 |
    22 |
    23 |
    24 | {% if person.subscribed.profile.picture %} 25 | 26 | {% else %} 27 | 28 | {% endif %} 29 | 30 | {% if person.expired == True %} 31 | Expired 32 | {% else %} 33 | {{ person.date }} days left 34 | {% endif %} 35 | 36 |
    37 |
    38 | 39 | {{ person.subscribed.first_name }} {{ person.subscribed.last_name }} 40 | 41 |
    42 | @{{ person.subscribed.username }} 43 |

    {{ person.subscribed.profile.profile_info }}

    44 | {% if person.expired == True %} 45 | autorenewRenew subscription 46 | {% else %} 47 | cancelCancel subscription 48 | {% endif %} 49 |
    50 |
    51 |
    52 |
    53 |
    54 | {% endfor %} 55 | 56 | 57 | {% endblock %} -------------------------------------------------------------------------------- /djfans/djfans/templates/new_list_modal.html: -------------------------------------------------------------------------------- 1 | 2 | 21 | -------------------------------------------------------------------------------- /djfans/djfans/templates/newpost.html: -------------------------------------------------------------------------------- 1 | {% extends 'base.html' %} 2 | {% load static %} 3 | 4 | {% block content %} 5 | 6 |
    7 |
    8 |
    9 |
    10 |

    New Post

    11 | {% csrf_token %} 12 |
    13 |
    14 | Media Files 15 | {{ form.content }} 16 |
    17 |
    18 | 19 |
    20 |
    21 |
    22 | description 23 | {{ form.title }} 24 | 25 |
    26 |
    27 | description 28 | {{ form.caption }} 29 | 30 |
    31 |
    32 | star_rate 33 | {{ form.tier }} 34 | 35 |
    36 |
    37 | 40 |
    41 |
    42 |
    43 |
    44 |
    45 | 46 | {% endblock %} -------------------------------------------------------------------------------- /djfans/djfans/templates/newtier.html: -------------------------------------------------------------------------------- 1 | {% extends 'base.html' %} 2 | 3 | {% block content %} 4 | 5 |
    6 |
    7 |
    8 |
    9 |

    New Tier

    10 | {% csrf_token %} 11 |
    12 | attach_money 13 | {{ form.price }} 14 | 15 |
    16 |
    17 | description 18 | {{ form.description }} 19 | 20 |
    21 |
    22 | 26 |
    27 |
    28 |
    29 | 32 |
    33 | 34 |
    35 |
    36 | 37 | 38 | {% endblock %} -------------------------------------------------------------------------------- /djfans/djfans/templates/people_list.html: -------------------------------------------------------------------------------- 1 | {% extends 'base.html' %} 2 | {% load static %} 3 | 4 | {% block content %} 5 |
    6 |
    {{ user_list.title }}
    7 | 10 |

    People in the list

    11 |
    12 |
    13 | 14 | {% for person in user_list.people.all %} 15 |
    16 |
    17 |
    18 | {% if person.profile.banner %} 19 | 20 | {% else %} 21 | 22 | {% endif %} 23 |
    24 |
    25 |
    26 |
    27 | {% if person.profile.picture %} 28 | 29 | {% else %} 30 | 31 | {% endif %} 32 |
    33 |
    34 | 35 | {{ person.first_name }} {{ person.last_name }} 36 | 37 |
    38 | @{{ person.username }} 39 |

    {{ person.profile.profile_info }}

    40 |
    41 |
    42 |
    43 |
    44 |
    45 | {% endfor %} 46 | 47 | 48 | {% endblock %} -------------------------------------------------------------------------------- /djfans/djfans/templates/registration/change_password.html: -------------------------------------------------------------------------------- 1 | {% extends 'base.html' %} 2 | {% load static %} 3 | 4 | 5 | {% block content %} 6 | 7 |
    8 |
    9 | 10 |
    11 | {% csrf_token %} 12 | {{ form.id }} 13 |

    Change password

    14 |
    15 | {{ form.old_password }} 16 | 17 |
    18 |
    19 |
    20 |
    21 | {{ form.new_password }} 22 | 23 |
    24 |
    25 |
    26 |
    27 | {{ form.confirm_password }} 28 | 29 |
    30 |
    31 |
    32 |
    33 | {{ form.errors }} 34 |
    35 |
    36 | 37 | loopReset Password 38 |
    39 |
    40 | 41 | {% endblock %} -------------------------------------------------------------------------------- /djfans/djfans/templates/registration/change_password_done.html: -------------------------------------------------------------------------------- 1 | {% extends 'base.html' %} 2 | 3 | {% block content %} 4 | 5 |
    6 |
    7 |
    8 |
    9 |
    10 |
    11 | check_circle 12 |
    13 |
    14 |

    Your password has been succesfully changed

    15 |
    16 | 17 | 18 |
    19 | 20 |
    21 |
    22 | {% endblock %} -------------------------------------------------------------------------------- /djfans/djfans/templates/registration/edit_profile.html: -------------------------------------------------------------------------------- 1 | {% extends 'base.html' %} {% load static %} {% block content %} 2 | 3 |
    4 |
    5 |
    6 |
    7 | {% csrf_token %} 8 |

    Edit Profile

    9 | 10 |
    11 |
    12 | Picture 13 | {{ form.picture }} 14 |
    15 |
    16 | 17 |
    18 |
    19 | 20 |
    21 |
    22 | Banner 23 | {{ form.banner }} 24 |
    25 |
    26 | 27 |
    28 |
    29 | 30 |
    31 | {{ form.first_name }} 32 | 33 |
    34 | 35 |
    36 | {{ form.last_name }} 37 | 38 |
    39 | 40 |
    41 | {{ form.location }} 42 | 43 |
    44 | 45 |
    46 | {{ form.url }} 47 | 48 |
    49 | 50 |
    51 | {{ form.profile_info }} 52 | 53 |
    54 | 55 |
    56 |
    57 | {{ form.errors }} 58 |
    59 |
    60 | 61 |
    62 |

    63 | 70 |

    71 |
    72 |
    73 |
    74 |
    75 |
    76 | 77 | {% endblock %} 78 | -------------------------------------------------------------------------------- /djfans/djfans/templates/registration/password_reset_complete.html: -------------------------------------------------------------------------------- 1 | {% extends 'base.html' %} 2 | 3 | {% block content %} 4 | 5 |
    6 |
    7 |
    8 |
    9 |
    10 |
    11 | check_circle 12 |
    13 |
    14 |

    Your password has been set. Please Sign in< now. Thank you!/h4> 15 |

    16 | 17 | 18 |
    19 | 20 |
    21 |
    22 | {% endblock %} -------------------------------------------------------------------------------- /djfans/djfans/templates/registration/password_reset_confirm.html: -------------------------------------------------------------------------------- 1 | {% extends 'base.html' %} 2 | {% load static %} 3 | 4 | 5 | {% block content %} 6 | 7 |
    8 |
    9 | 10 |
    11 | {% csrf_token %} 12 | {{ form.id }} 13 |

    Set a new password

    14 |
    15 | {% if validlink %} 16 |
    17 |
    18 | {{ form.new_password1 }} 19 | 20 |
    21 |
    22 |
    23 |
    24 | {{ form.new_password2 }} 25 | 26 |
    27 |
    28 | {% else %} 29 |
    30 |
    31 | The password reset link was invalid, it has alredy been used. Please request a new one. 32 |
    33 |
    34 | {% endif %} 35 | 36 |
    37 |
    38 | 39 | {% endblock %} -------------------------------------------------------------------------------- /djfans/djfans/templates/registration/password_reset_done.html: -------------------------------------------------------------------------------- 1 | {% extends 'base.html' %} 2 | 3 | {% block content %} 4 | 5 |
    6 |
    7 |
    8 |
    9 |
    10 |
    11 | check_circle 12 |
    13 |
    14 |

    We have emailed you instructions to reset your password

    15 |

    If an account exists with the email you entered. You will receive the token.

    16 |

    If you don't receive an email. Check your spam folder or make sure you entered the correct email.

    17 |
    18 | 19 | 20 |
    21 | 22 |
    23 |
    24 | {% endblock %} -------------------------------------------------------------------------------- /djfans/djfans/templates/registration/password_reset_email.html: -------------------------------------------------------------------------------- 1 | {% autoescape off %} 2 | 3 | Your initiate a password reset proccess your account: {{ user.get_username }} in --yourwebsite-- 4 | 5 | Click the link below continue: 6 | 7 | {{ protocol }}://{{ domain }}{% url 'password_reset_confirm' uidb64=uid token=token %} 8 | 9 | If the link doesn't work, Please copy and paste the url in a new tab. 10 | 11 | Sincerely, 12 | -Yourwebsite 13 | 14 | {% endautoescape %} -------------------------------------------------------------------------------- /djfans/djfans/templates/registration/password_reset_form.html: -------------------------------------------------------------------------------- 1 | {% extends 'base.html' %} 2 | {% load static %} 3 | 4 | 5 | {% block content %} 6 | 7 |
    8 |
    9 | {% csrf_token %} 10 | {{ form.id }} 11 |

    Forgot password

    12 |
    13 |
    14 | {{ form.email }} 15 | 16 |
    17 |
    18 |
    19 |
    20 | {{ form.errors }} 21 |
    22 |
    23 | 24 |
    25 |
    26 | 27 | {% endblock %} -------------------------------------------------------------------------------- /djfans/djfans/templates/registration/password_reset_subject.txt: -------------------------------------------------------------------------------- 1 | Password reset for yourwebsite -------------------------------------------------------------------------------- /djfans/djfans/templates/registration/signup.html: -------------------------------------------------------------------------------- 1 | {% load static %} 2 | 3 | 4 | 5 | 6 | 7 | 8 | Djfans- Onlyfans clone project 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 |
    18 |
    19 |
    20 | 21 |
    22 | {% csrf_token %} 23 |

    Create an account

    24 | 25 |
    26 | {{ form.username }} 27 | 28 |
    29 | 30 |
    31 | {{ form.email }} 32 | 33 |
    34 | 35 |
    36 | {{ form.password }} 37 | 38 |
    39 | 40 |
    41 | {{ form.confirm_password }} 42 | 43 |
    44 | 45 |
    46 |
    47 | {{ form.errors }} 48 |
    49 |
    50 | 51 |
    52 |

    53 | 56 |

    57 |
    58 | 59 | 60 |
    61 |
    62 | 63 | 64 |
    65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | 79 | 80 | -------------------------------------------------------------------------------- /djfans/djfans/templates/user_lists.html: -------------------------------------------------------------------------------- 1 | {% extends 'base.html' %} 2 | 3 | {% block content %} 4 | 5 | 18 | 19 | {% include "new_list_modal.html" %} 20 | 21 | {% endblock %} -------------------------------------------------------------------------------- /djfans/djfans/urls.py: -------------------------------------------------------------------------------- 1 | """djfans URL Configuration 2 | 3 | The `urlpatterns` list routes URLs to views. For more information please see: 4 | https://docs.djangoproject.com/en/3.1/topics/http/urls/ 5 | Examples: 6 | Function views 7 | 1. Add an import: from my_app import views 8 | 2. Add a URL to urlpatterns: path('', views.home, name='home') 9 | Class-based views 10 | 1. Add an import: from other_app.views import Home 11 | 2. Add a URL to urlpatterns: path('', Home.as_view(), name='home') 12 | Including another URLconf 13 | 1. Import the include() function: from django.urls import include, path 14 | 2. Add a URL to urlpatterns: path('blog/', include('blog.urls')) 15 | """ 16 | from django.contrib import admin 17 | from django.urls import path, include 18 | 19 | from django.conf import settings 20 | from django.conf.urls.static import static 21 | 22 | 23 | from authy.views import UserProfile, RemoveFromList 24 | from tier.views import Subscribe 25 | from post.views import index 26 | 27 | 28 | urlpatterns = [ 29 | path('admin/', admin.site.urls), 30 | path('user/', include('authy.urls')), 31 | path('sub/', include('tier.urls')), 32 | path('post/', include('post.urls')), 33 | path('notifications/', include('notifications.urls')), 34 | path('messages/', include('direct.urls')), 35 | path('', index, name='index'), 36 | path('/', UserProfile, name='profile'), 37 | path('/photos', UserProfile, name='profilephotos'), 38 | path('/videos', UserProfile, name='profilevideos'), 39 | path('//subscribe', Subscribe, name='subscribe'), 40 | path('/remove/fromlist', RemoveFromList, name='remove-from-list'), 41 | 42 | ] 43 | 44 | # + static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT) 45 | -------------------------------------------------------------------------------- /djfans/djfans/wsgi.py: -------------------------------------------------------------------------------- 1 | """ 2 | WSGI config for djfans project. 3 | 4 | It exposes the WSGI callable as a module-level variable named ``application``. 5 | 6 | For more information on this file, see 7 | https://docs.djangoproject.com/en/3.1/howto/deployment/wsgi/ 8 | """ 9 | 10 | import os 11 | 12 | from django.core.wsgi import get_wsgi_application 13 | 14 | os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'djfans.settings') 15 | 16 | application = get_wsgi_application() 17 | -------------------------------------------------------------------------------- /djfans/manage.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python 2 | 3 | """Django's command-line utility for administrative tasks.""" 4 | import os 5 | import sys 6 | 7 | 8 | def main(): 9 | """Run administrative tasks.""" 10 | os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'djfans.settings') 11 | try: 12 | from django.core.management import execute_from_command_line 13 | except ImportError as exc: 14 | raise ImportError( 15 | "Couldn't import Django. Are you sure it's installed and " 16 | "available on your PYTHONPATH environment variable? Did you " 17 | "forget to activate a virtual environment?" 18 | ) from exc 19 | execute_from_command_line(sys.argv) 20 | 21 | 22 | if __name__ == '__main__': 23 | main() 24 | -------------------------------------------------------------------------------- /djfans/media/user_2/banner.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/media/user_2/banner.jpg -------------------------------------------------------------------------------- /djfans/media/user_2/paul-volkmer-FGeycwoYGT4-unsplash.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/media/user_2/paul-volkmer-FGeycwoYGT4-unsplash.jpg -------------------------------------------------------------------------------- /djfans/media/user_2/paul-volkmer-FGeycwoYGT4-unsplash_S68W7ca.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/media/user_2/paul-volkmer-FGeycwoYGT4-unsplash_S68W7ca.jpg -------------------------------------------------------------------------------- /djfans/media/user_2/paul-volkmer-FGeycwoYGT4-unsplash_Seqa4yi.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/media/user_2/paul-volkmer-FGeycwoYGT4-unsplash_Seqa4yi.jpg -------------------------------------------------------------------------------- /djfans/media/user_2/paul-volkmer-FGeycwoYGT4-unsplash_UavYjyZ.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/media/user_2/paul-volkmer-FGeycwoYGT4-unsplash_UavYjyZ.jpg -------------------------------------------------------------------------------- /djfans/media/user_2/paul-volkmer-FGeycwoYGT4-unsplash_npUSKX7.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/media/user_2/paul-volkmer-FGeycwoYGT4-unsplash_npUSKX7.jpg -------------------------------------------------------------------------------- /djfans/media/user_2/paul-volkmer-FGeycwoYGT4-unsplash_rIDdsps.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/media/user_2/paul-volkmer-FGeycwoYGT4-unsplash_rIDdsps.jpg -------------------------------------------------------------------------------- /djfans/media/user_2/profile.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/media/user_2/profile.jpg -------------------------------------------------------------------------------- /djfans/media/user_3/banner.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/media/user_3/banner.jpg -------------------------------------------------------------------------------- /djfans/media/user_3/big-dodzy-adFlSmVeDb4-unsplash.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/media/user_3/big-dodzy-adFlSmVeDb4-unsplash.jpg -------------------------------------------------------------------------------- /djfans/media/user_3/martin-zdrazil-egsyjg7xmxI-unsplash.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/media/user_3/martin-zdrazil-egsyjg7xmxI-unsplash.jpg -------------------------------------------------------------------------------- /djfans/media/user_3/profile.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/media/user_3/profile.jpg -------------------------------------------------------------------------------- /djfans/media/user_3/reynier-carl-D9wUdokXcd8-unsplash.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/media/user_3/reynier-carl-D9wUdokXcd8-unsplash.jpg -------------------------------------------------------------------------------- /djfans/media/user_4/banner.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/media/user_4/banner.jpg -------------------------------------------------------------------------------- /djfans/media/user_4/profile.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/media/user_4/profile.jpg -------------------------------------------------------------------------------- /djfans/media/user_6/spacecharacter.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/media/user_6/spacecharacter.jpg -------------------------------------------------------------------------------- /djfans/notifications/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/notifications/__init__.py -------------------------------------------------------------------------------- /djfans/notifications/__pycache__/__init__.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/notifications/__pycache__/__init__.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/notifications/__pycache__/admin.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/notifications/__pycache__/admin.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/notifications/__pycache__/models.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/notifications/__pycache__/models.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/notifications/__pycache__/urls.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/notifications/__pycache__/urls.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/notifications/__pycache__/views.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/notifications/__pycache__/views.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/notifications/admin.py: -------------------------------------------------------------------------------- 1 | from django.contrib import admin 2 | from notifications.models import Notification 3 | # Register your models here. 4 | admin.site.register(Notification) 5 | -------------------------------------------------------------------------------- /djfans/notifications/apps.py: -------------------------------------------------------------------------------- 1 | from django.apps import AppConfig 2 | 3 | 4 | class NotificationsConfig(AppConfig): 5 | name = 'notifications' 6 | -------------------------------------------------------------------------------- /djfans/notifications/migrations/0001_initial.py: -------------------------------------------------------------------------------- 1 | # Generated by Django 3.1.7 on 2021-03-15 20:13 2 | 3 | from django.conf import settings 4 | from django.db import migrations, models 5 | import django.db.models.deletion 6 | 7 | 8 | class Migration(migrations.Migration): 9 | 10 | initial = True 11 | 12 | dependencies = [ 13 | ('post', '0002_bookmark'), 14 | migrations.swappable_dependency(settings.AUTH_USER_MODEL), 15 | ] 16 | 17 | operations = [ 18 | migrations.CreateModel( 19 | name='Notification', 20 | fields=[ 21 | ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), 22 | ('notification_type', models.IntegerField(choices=[(1, 'Like'), (2, 'Comment'), (3, 'Subscribed')])), 23 | ('text_preview', models.CharField(blank=True, max_length=50)), 24 | ('date', models.DateTimeField(auto_now_add=True)), 25 | ('is_seen', models.BooleanField(default=False)), 26 | ('post', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='noti_post', to='post.post')), 27 | ('sender', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='noti_from_user', to=settings.AUTH_USER_MODEL)), 28 | ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='noti_to_user', to=settings.AUTH_USER_MODEL)), 29 | ], 30 | ), 31 | ] 32 | -------------------------------------------------------------------------------- /djfans/notifications/migrations/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/notifications/migrations/__init__.py -------------------------------------------------------------------------------- /djfans/notifications/migrations/__pycache__/0001_initial.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/notifications/migrations/__pycache__/0001_initial.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/notifications/migrations/__pycache__/__init__.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/notifications/migrations/__pycache__/__init__.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/notifications/models.py: -------------------------------------------------------------------------------- 1 | from django.db import models 2 | from django.contrib.auth.models import User 3 | 4 | # Create your models here. 5 | 6 | 7 | class Notification(models.Model): 8 | NOTIFICATION_TYPES = ((1, 'Like'), (2, 'Comment'), (3, 'Subscribed')) 9 | 10 | post = models.ForeignKey('post.Post', on_delete=models.CASCADE, 11 | related_name='noti_post', blank=True, null=True) 12 | sender = models.ForeignKey( 13 | User, on_delete=models.CASCADE, related_name='noti_from_user') 14 | user = models.ForeignKey( 15 | User, on_delete=models.CASCADE, related_name='noti_to_user') 16 | notification_type = models.IntegerField(choices=NOTIFICATION_TYPES) 17 | text_preview = models.CharField(max_length=50, blank=True) 18 | date = models.DateTimeField(auto_now_add=True) 19 | is_seen = models.BooleanField(default=False) 20 | -------------------------------------------------------------------------------- /djfans/notifications/tests.py: -------------------------------------------------------------------------------- 1 | from django.test import TestCase 2 | 3 | # Create your tests here. 4 | -------------------------------------------------------------------------------- /djfans/notifications/urls.py: -------------------------------------------------------------------------------- 1 | from django.urls import path 2 | from notifications.views import ShowNotifications, DeleteNotification 3 | 4 | urlpatterns = [ 5 | path('', ShowNotifications, name='show-notifications'), 6 | path('/delete', DeleteNotification, name='delete-notification') 7 | ] 8 | -------------------------------------------------------------------------------- /djfans/notifications/views.py: -------------------------------------------------------------------------------- 1 | from django.shortcuts import render, redirect 2 | 3 | from notifications.models import Notification 4 | 5 | # Create your views here. 6 | 7 | 8 | def ShowNotifications(request): 9 | user = request.user 10 | notifications = Notification.objects.filter(user=user).order_by('-date') 11 | Notification.objects.filter(user=user, is_seen=False).update(is_seen=True) 12 | 13 | context = { 14 | 'notifications': notifications 15 | } 16 | 17 | return render(request, 'notifications.html', context) 18 | 19 | 20 | def DeleteNotification(request, noti_id): 21 | user = request.user 22 | Notification.objects.filter(id=noti_id, user=user).delete() 23 | return redirect('show-notifications') 24 | 25 | 26 | def CountNotifications(request): 27 | count_notifications = None 28 | if request.user.is_authenticated: 29 | count_notifications = Notification.objects.filter( 30 | user=request.user, is_seen=False).count() 31 | return {'count_notifications': count_notifications} 32 | -------------------------------------------------------------------------------- /djfans/post/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/post/__init__.py -------------------------------------------------------------------------------- /djfans/post/__pycache__/__init__.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/post/__pycache__/__init__.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/post/__pycache__/admin.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/post/__pycache__/admin.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/post/__pycache__/forms.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/post/__pycache__/forms.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/post/__pycache__/models.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/post/__pycache__/models.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/post/__pycache__/urls.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/post/__pycache__/urls.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/post/__pycache__/views.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/post/__pycache__/views.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/post/admin.py: -------------------------------------------------------------------------------- 1 | from django.contrib import admin 2 | from post.models import Post, PostFileContent, Stream, Likes, Bookmark 3 | # Register your models here. 4 | admin.site.register(Post) 5 | admin.site.register(Bookmark) 6 | admin.site.register(Likes) 7 | admin.site.register(Stream) 8 | admin.site.register(PostFileContent) 9 | -------------------------------------------------------------------------------- /djfans/post/apps.py: -------------------------------------------------------------------------------- 1 | from django.apps import AppConfig 2 | 3 | 4 | class PostConfig(AppConfig): 5 | name = 'post' 6 | -------------------------------------------------------------------------------- /djfans/post/forms.py: -------------------------------------------------------------------------------- 1 | from django import forms 2 | from post.models import Post 3 | from tier.models import Tier 4 | 5 | 6 | class NewPostForm(forms.ModelForm): 7 | title = forms.CharField(widget=forms.TextInput( 8 | attrs={'class': 'validate'}), required=True) 9 | content = forms.FileField(widget=forms.ClearableFileInput( 10 | attrs={'multiple': False}), required=True) 11 | caption = forms.CharField(widget=forms.Textarea( 12 | attrs={'class': 'materialize-textarea'}), required=True) 13 | tier = forms.ModelChoiceField(queryset=Tier.objects.all()) 14 | 15 | class Meta: 16 | model = Post 17 | fields = ('content', 'title', 'caption', 'tier') 18 | -------------------------------------------------------------------------------- /djfans/post/migrations/0002_bookmark.py: -------------------------------------------------------------------------------- 1 | # Generated by Django 3.1.7 on 2021-03-15 19:02 2 | 3 | from django.conf import settings 4 | from django.db import migrations, models 5 | import django.db.models.deletion 6 | 7 | 8 | class Migration(migrations.Migration): 9 | 10 | dependencies = [ 11 | migrations.swappable_dependency(settings.AUTH_USER_MODEL), 12 | ('post', '0001_initial'), 13 | ] 14 | 15 | operations = [ 16 | migrations.CreateModel( 17 | name='Bookmark', 18 | fields=[ 19 | ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), 20 | ('posts', models.ManyToManyField(to='post.Post')), 21 | ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='bookmark_user', to=settings.AUTH_USER_MODEL)), 22 | ], 23 | ), 24 | ] 25 | -------------------------------------------------------------------------------- /djfans/post/migrations/0003_post_date.py: -------------------------------------------------------------------------------- 1 | # Generated by Django 3.1.7 on 2021-03-30 17:01 2 | 3 | from django.db import migrations, models 4 | import django.utils.timezone 5 | 6 | 7 | class Migration(migrations.Migration): 8 | 9 | dependencies = [ 10 | ('post', '0002_bookmark'), 11 | ] 12 | 13 | operations = [ 14 | migrations.AddField( 15 | model_name='post', 16 | name='date', 17 | field=models.DateTimeField(auto_now_add=True, default=django.utils.timezone.now), 18 | preserve_default=False, 19 | ), 20 | ] 21 | -------------------------------------------------------------------------------- /djfans/post/migrations/0004_remove_post_date.py: -------------------------------------------------------------------------------- 1 | # Generated by Django 3.1.7 on 2021-03-30 21:29 2 | 3 | from django.db import migrations 4 | 5 | 6 | class Migration(migrations.Migration): 7 | 8 | dependencies = [ 9 | ('post', '0003_post_date'), 10 | ] 11 | 12 | operations = [ 13 | migrations.RemoveField( 14 | model_name='post', 15 | name='date', 16 | ), 17 | ] 18 | -------------------------------------------------------------------------------- /djfans/post/migrations/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/post/migrations/__init__.py -------------------------------------------------------------------------------- /djfans/post/migrations/__pycache__/0001_initial.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/post/migrations/__pycache__/0001_initial.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/post/migrations/__pycache__/0002_bookmark.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/post/migrations/__pycache__/0002_bookmark.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/post/migrations/__pycache__/0003_post_date.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/post/migrations/__pycache__/0003_post_date.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/post/migrations/__pycache__/0004_remove_post_date.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/post/migrations/__pycache__/0004_remove_post_date.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/post/migrations/__pycache__/__init__.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/post/migrations/__pycache__/__init__.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/post/signals.py: -------------------------------------------------------------------------------- 1 | from django.db.models.signals import post_save 2 | from django.dispatch import receiver 3 | from post.models import Post, Stream 4 | 5 | 6 | @receiver(post_save, sender=Post) 7 | def new_post_save(sender, **kwargs): 8 | post = kwargs['instance'].post 9 | post.save() 10 | -------------------------------------------------------------------------------- /djfans/post/tests.py: -------------------------------------------------------------------------------- 1 | from django.test import TestCase 2 | 3 | # Create your tests here. 4 | -------------------------------------------------------------------------------- /djfans/post/urls.py: -------------------------------------------------------------------------------- 1 | from django.urls import path 2 | from post.views import NewPost, PostDetails, like, bookmark, BookmarkList 3 | 4 | urlpatterns = [ 5 | path('newpost/', NewPost, name='newpost'), 6 | path('bookmarks/', BookmarkList, name='bookmarks'), 7 | path('', PostDetails, name='postdetails'), 8 | path('/like', like, name='postlike'), 9 | path('/bookmark', bookmark, name='postbookmark'), 10 | ] 11 | -------------------------------------------------------------------------------- /djfans/requirements.txt: -------------------------------------------------------------------------------- 1 | asgiref==3.3.1 2 | autopep8==1.5.5 3 | boto3==1.17.57 4 | botocore==1.20.57 5 | certifi==2020.12.5 6 | cffi==1.14.5 7 | chardet==4.0.0 8 | cryptography==3.4.7 9 | defusedxml==0.7.1 10 | Django==3.1.7 11 | django-allauth==0.44.0 12 | django-storages==1.11.1 13 | gunicorn==20.1.0 14 | idna==2.10 15 | jmespath==0.10.0 16 | oauthlib==3.1.0 17 | Pillow==8.1.1 18 | psycopg2-binary==2.8.6 19 | pycodestyle==2.6.0 20 | pycparser==2.20 21 | PyJWT==2.0.1 22 | python-dateutil==2.8.1 23 | python3-openid==3.2.0 24 | pytz==2021.1 25 | requests==2.25.1 26 | requests-oauthlib==1.3.0 27 | s3transfer==0.4.2 28 | six==1.15.0 29 | sqlparse==0.4.1 30 | toml==0.10.2 31 | urllib3==1.26.4 32 | -------------------------------------------------------------------------------- /djfans/tier/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/tier/__init__.py -------------------------------------------------------------------------------- /djfans/tier/__pycache__/__init__.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/tier/__pycache__/__init__.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/tier/__pycache__/admin.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/tier/__pycache__/admin.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/tier/__pycache__/forms.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/tier/__pycache__/forms.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/tier/__pycache__/models.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/tier/__pycache__/models.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/tier/__pycache__/urls.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/tier/__pycache__/urls.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/tier/__pycache__/views.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/tier/__pycache__/views.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/tier/admin.py: -------------------------------------------------------------------------------- 1 | from django.contrib import admin 2 | from tier.models import Tier, Subscription 3 | 4 | # Register your models here. 5 | admin.site.register(Tier) 6 | admin.site.register(Subscription) 7 | -------------------------------------------------------------------------------- /djfans/tier/apps.py: -------------------------------------------------------------------------------- 1 | from django.apps import AppConfig 2 | 3 | 4 | class TierConfig(AppConfig): 5 | name = 'tier' 6 | -------------------------------------------------------------------------------- /djfans/tier/forms.py: -------------------------------------------------------------------------------- 1 | from django import forms 2 | from tier.models import Tier 3 | 4 | 5 | class NewTierForm(forms.ModelForm): 6 | description = forms.CharField(widget=forms.TextInput( 7 | attrs={'class': 'materialize-textarea'}), required=True) 8 | price = forms.CharField(required=True) 9 | can_message = forms.BooleanField(required=False) 10 | 11 | class Meta: 12 | model = Tier 13 | fields = ('description', 'price', 'can_message') 14 | -------------------------------------------------------------------------------- /djfans/tier/migrations/0001_initial.py: -------------------------------------------------------------------------------- 1 | # Generated by Django 3.1.7 on 2021-03-05 17:21 2 | 3 | from django.conf import settings 4 | from django.db import migrations, models 5 | import django.db.models.deletion 6 | 7 | 8 | class Migration(migrations.Migration): 9 | 10 | initial = True 11 | 12 | dependencies = [ 13 | migrations.swappable_dependency(settings.AUTH_USER_MODEL), 14 | ] 15 | 16 | operations = [ 17 | migrations.CreateModel( 18 | name='Tier', 19 | fields=[ 20 | ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), 21 | ('number', models.PositiveSmallIntegerField(default=0)), 22 | ('description', models.TextField(max_length=800, verbose_name='Description')), 23 | ('price', models.IntegerField(verbose_name='Price')), 24 | ('can_message', models.BooleanField(default=False)), 25 | ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='tier_user', to=settings.AUTH_USER_MODEL)), 26 | ], 27 | ), 28 | migrations.CreateModel( 29 | name='Subscription', 30 | fields=[ 31 | ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), 32 | ('date', models.DateTimeField(auto_now_add=True)), 33 | ('expired', models.BooleanField(default=False)), 34 | ('subscribed', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='subscribed', to=settings.AUTH_USER_MODEL)), 35 | ('subscriber', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='subscriber', to=settings.AUTH_USER_MODEL)), 36 | ('tier', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='tier', to='tier.tier')), 37 | ], 38 | ), 39 | ] 40 | -------------------------------------------------------------------------------- /djfans/tier/migrations/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/tier/migrations/__init__.py -------------------------------------------------------------------------------- /djfans/tier/migrations/__pycache__/0001_initial.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/tier/migrations/__pycache__/0001_initial.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/tier/migrations/__pycache__/__init__.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/djfans/tier/migrations/__pycache__/__init__.cpython-38.pyc -------------------------------------------------------------------------------- /djfans/tier/models.py: -------------------------------------------------------------------------------- 1 | from django.db import models 2 | 3 | from notifications.models import Notification 4 | from django.contrib.auth.models import User 5 | from django.db.models.signals import post_save, post_delete 6 | 7 | # Create your models here. 8 | 9 | 10 | class Tier(models.Model): 11 | number = models.PositiveSmallIntegerField(default=0) 12 | description = models.TextField(max_length=800, verbose_name='Description') 13 | price = models.IntegerField(verbose_name='Price') 14 | can_message = models.BooleanField(default=False) 15 | user = models.ForeignKey( 16 | User, on_delete=models.CASCADE, related_name='tier_user') 17 | 18 | def __str__(self): 19 | return str(self.user) + '-' + str(self.description) 20 | 21 | def save(self, *args, **kwargs): 22 | amount = Tier.objects.filter(user=self.user).count() 23 | self.number = amount + 1 24 | return super().save(*args, **kwargs) 25 | 26 | 27 | class Subscription(models.Model): 28 | subscriber = models.ForeignKey( 29 | User, on_delete=models.CASCADE, related_name='subscriber') 30 | subscribed = models.ForeignKey( 31 | User, on_delete=models.CASCADE, related_name='subscribed') 32 | tier = models.ForeignKey( 33 | Tier, on_delete=models.CASCADE, related_name='tier') 34 | date = models.DateTimeField(auto_now_add=True) 35 | expired = models.BooleanField(default=False) 36 | 37 | def __str__(self): 38 | return self.subscriber.username + '==' + self.subscribed.username + '== Tier: ' + str(self.tier.number) 39 | 40 | def user_subscribed(sender, instance, *args, **kwargs): 41 | subscription = instance 42 | sender = subscription.subscriber 43 | subscribing = subscription.subscribed 44 | 45 | notify = Notification( 46 | sender=sender, user=subscribing, notification_type=3) 47 | notify.save() 48 | 49 | def user_unsubscribed(sender, instance, *args, **kwargs): 50 | subscription = instance 51 | sender = subscription.subscriber 52 | subscribing = subscription.subscribed 53 | 54 | notify = Notification.objects.filter( 55 | sender=sender, user=subscribing, notification_type=3) 56 | notify.delete() 57 | 58 | 59 | # Subscription signals stuff: 60 | post_save.connect(Subscription.user_subscribed, sender=Subscription) 61 | post_delete.connect(Subscription.user_unsubscribed, sender=Subscription) 62 | -------------------------------------------------------------------------------- /djfans/tier/tests.py: -------------------------------------------------------------------------------- 1 | from django.test import TestCase 2 | 3 | # Create your tests here. 4 | -------------------------------------------------------------------------------- /djfans/tier/urls.py: -------------------------------------------------------------------------------- 1 | from django.urls import path 2 | from tier.views import NewTier, FansList, FollowingList, CheckExpiration 3 | 4 | urlpatterns = [ 5 | path('newtier/', NewTier, name='newtier'), 6 | path('myfans/', FansList, name='myfans'), 7 | path('myfollows/', FollowingList, name='myfollows'), 8 | path('checkexp/', CheckExpiration, name='check-expiration'), 9 | ] 10 | -------------------------------------------------------------------------------- /djfans/tier/views.py: -------------------------------------------------------------------------------- 1 | from django.shortcuts import render, redirect, get_object_or_404 2 | from tier.forms import NewTierForm 3 | 4 | from tier.models import Tier, Subscription 5 | from django.contrib.auth.models import User 6 | from datetime import datetime, timedelta 7 | # Create your views here. 8 | 9 | 10 | def NewTier(request): 11 | user = request.user 12 | 13 | if request.method == "POST": 14 | form = NewTierForm(request.POST) 15 | 16 | if form.is_valid(): 17 | description = form.cleaned_data.get('description') 18 | price = form.cleaned_data.get('price') 19 | can_message = form.cleaned_data.get('can_message') 20 | 21 | Tier.objects.create(description=description, 22 | price=price, user=user, can_message=can_message) 23 | return redirect('index') 24 | else: 25 | form = NewTierForm() 26 | 27 | context = { 28 | 'form': form, 29 | } 30 | 31 | return render(request, 'newtier.html', context) 32 | 33 | 34 | def Subscribe(request, username, tier_id): 35 | user = request.user 36 | subscribing = get_object_or_404(User, username=username) 37 | tier = Tier.objects.get(id=tier_id) 38 | 39 | try: 40 | Subscription.objects.get_or_create( 41 | subscriber=user, subscribed=subscribing, tier=tier) 42 | return redirect('index') 43 | except User.DoesNotExist: 44 | return redirect('index') 45 | 46 | 47 | def FansList(request): 48 | my_fans = Subscription.objects.filter(subscribed=request.user) 49 | 50 | context = { 51 | 'my_fans': my_fans 52 | } 53 | 54 | return render(request, 'fans_list.html', context) 55 | 56 | 57 | def FollowingList(request): 58 | my_follows = Subscription.objects.filter(subscriber=request.user) 59 | # tier_num = Tier.number 60 | for follows in my_follows: 61 | if follows.expired != True: 62 | end_date = datetime.now() - timedelta(days=30) 63 | remaining = follows.date.replace( 64 | tzinfo=None) - end_date.replace(tzinfo=None) 65 | days_left = remaining.days 66 | follows.date = days_left 67 | 68 | context = { 69 | 'my_follows': my_follows 70 | } 71 | 72 | return render(request, 'following_list.html', context) 73 | 74 | 75 | def CheckExpiration(request): 76 | exp_date = datetime.now() - timedelta(days=30) 77 | subs = Subscription.objects.filter( 78 | subscriber=request.user, date__lt=exp_date) 79 | subs.update(expired=True) 80 | fans = Subscription.objects.filter( 81 | subscribed=request.user, date__lt=exp_date) 82 | fans.update(expired=True) 83 | return redirect('index') 84 | -------------------------------------------------------------------------------- /docker-compose.yml: -------------------------------------------------------------------------------- 1 | version: '3.8' 2 | 3 | services: 4 | django_gunicorn: 5 | volumes: 6 | - static:/static 7 | - media:/media 8 | environment: 9 | - SECRET_KEY=${SECRET_KEY} 10 | - S3_ACCESS_KEY=${S3_ACCESS_KEY} 11 | - AWS_REGION=${AWS_REGION} 12 | - AWS_ACCESS_KEY=${AWS_ACCESS_KEY} 13 | - AWS_SECRET_KEY=${AWS_SECRET_KEY} 14 | - DEBUG=${DEBUG} 15 | - DB_PASSWORD=${DB_PASSWORD} 16 | - DB_HOST=${DB_HOST} 17 | - DB_USER=${DB_USER} 18 | - DB_NAME=${DB_NAME} 19 | - DJANGO_SUPERUSER_PASSWORD=${DJANGO_SUPERUSER_PASSWORD} 20 | - DJANGO_SUPERUSER_USERNAME=${DJANGO_SUPERUSER_USERNAME} 21 | - DJANGO_SUPERUSER_EMAIL=${DJANGO_SUPERUSER_EMAIL} 22 | build: 23 | context: . 24 | ports: 25 | - "8000:8000" 26 | nginx: 27 | build: ./nginx 28 | volumes: 29 | - static:/static 30 | - media:/media 31 | ports: 32 | - "80:80" 33 | depends_on: 34 | - django_gunicorn 35 | 36 | volumes: 37 | static: 38 | media: -------------------------------------------------------------------------------- /entrypoint.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | 4 | 5 | python manage.py makemigrations 6 | python manage.py migrate --noinput 7 | python manage.py collectstatic --noinput 8 | 9 | gunicorn djfans.wsgi:application --bind 0.0.0.0:8000 10 | 11 | -------------------------------------------------------------------------------- /images/chat.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/images/chat.png -------------------------------------------------------------------------------- /images/diagram.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/images/diagram.png -------------------------------------------------------------------------------- /images/fanlist.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/images/fanlist.png -------------------------------------------------------------------------------- /images/followinglist.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/images/followinglist.png -------------------------------------------------------------------------------- /images/index.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/images/index.png -------------------------------------------------------------------------------- /images/notification.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/images/notification.png -------------------------------------------------------------------------------- /images/profile.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/images/profile.png -------------------------------------------------------------------------------- /images/skills.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/images/skills.png -------------------------------------------------------------------------------- /images/subscription.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/images/subscription.png -------------------------------------------------------------------------------- /nginx/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM nginx:1.19.0 2 | 3 | COPY ./default.conf /etc/nginx/conf.d/default.conf 4 | 5 | -------------------------------------------------------------------------------- /nginx/default.conf: -------------------------------------------------------------------------------- 1 | upstream django { 2 | server django_gunicorn:8000; 3 | } 4 | 5 | server { 6 | listen 80; 7 | client_max_body_size 128M; 8 | charset UTF-8; 9 | 10 | location / { 11 | proxy_pass http://django; 12 | } 13 | 14 | location /static/ { 15 | alias https://djfans-static.s3.eu-central-1.amazonaws.com/static/; 16 | } 17 | 18 | location /media/ { 19 | alias https://djfans-static.s3.eu-central.amazonaws.com/media/; 20 | } 21 | } -------------------------------------------------------------------------------- /static/admin/css/dashboard.css: -------------------------------------------------------------------------------- 1 | /* DASHBOARD */ 2 | 3 | .dashboard .module table th { 4 | width: 100%; 5 | } 6 | 7 | .dashboard .module table td { 8 | white-space: nowrap; 9 | } 10 | 11 | .dashboard .module table td a { 12 | display: block; 13 | padding-right: .6em; 14 | } 15 | 16 | /* RECENT ACTIONS MODULE */ 17 | 18 | .module ul.actionlist { 19 | margin-left: 0; 20 | } 21 | 22 | ul.actionlist li { 23 | list-style-type: none; 24 | overflow: hidden; 25 | text-overflow: ellipsis; 26 | } 27 | -------------------------------------------------------------------------------- /static/admin/css/fonts.css: -------------------------------------------------------------------------------- 1 | @font-face { 2 | font-family: 'Roboto'; 3 | src: url('../fonts/Roboto-Bold-webfont.woff'); 4 | font-weight: 700; 5 | font-style: normal; 6 | } 7 | 8 | @font-face { 9 | font-family: 'Roboto'; 10 | src: url('../fonts/Roboto-Regular-webfont.woff'); 11 | font-weight: 400; 12 | font-style: normal; 13 | } 14 | 15 | @font-face { 16 | font-family: 'Roboto'; 17 | src: url('../fonts/Roboto-Light-webfont.woff'); 18 | font-weight: 300; 19 | font-style: normal; 20 | } 21 | -------------------------------------------------------------------------------- /static/admin/css/login.css: -------------------------------------------------------------------------------- 1 | /* LOGIN FORM */ 2 | 3 | .login { 4 | background: #f8f8f8; 5 | height: auto; 6 | } 7 | 8 | .login #header { 9 | height: auto; 10 | padding: 15px 16px; 11 | justify-content: center; 12 | } 13 | 14 | .login #header h1 { 15 | font-size: 18px; 16 | } 17 | 18 | .login #header h1 a { 19 | color: #fff; 20 | } 21 | 22 | .login #content { 23 | padding: 20px 20px 0; 24 | } 25 | 26 | .login #container { 27 | background: #fff; 28 | border: 1px solid #eaeaea; 29 | border-radius: 4px; 30 | overflow: hidden; 31 | width: 28em; 32 | min-width: 300px; 33 | margin: 100px auto; 34 | height: auto; 35 | } 36 | 37 | .login #content-main { 38 | width: 100%; 39 | } 40 | 41 | .login .form-row { 42 | padding: 4px 0; 43 | float: left; 44 | width: 100%; 45 | border-bottom: none; 46 | } 47 | 48 | .login .form-row label { 49 | padding-right: 0.5em; 50 | line-height: 2em; 51 | font-size: 1em; 52 | clear: both; 53 | color: #333; 54 | } 55 | 56 | .login .form-row #id_username, .login .form-row #id_password { 57 | clear: both; 58 | padding: 8px; 59 | width: 100%; 60 | box-sizing: border-box; 61 | } 62 | 63 | .login span.help { 64 | font-size: 10px; 65 | display: block; 66 | } 67 | 68 | .login .submit-row { 69 | clear: both; 70 | padding: 1em 0 0 9.4em; 71 | margin: 0; 72 | border: none; 73 | background: none; 74 | text-align: left; 75 | } 76 | 77 | .login .password-reset-link { 78 | text-align: center; 79 | } 80 | -------------------------------------------------------------------------------- /static/admin/css/nav_sidebar.css: -------------------------------------------------------------------------------- 1 | .sticky { 2 | position: sticky; 3 | top: 0; 4 | max-height: 100vh; 5 | } 6 | 7 | .toggle-nav-sidebar { 8 | z-index: 20; 9 | left: 0; 10 | display: flex; 11 | align-items: center; 12 | justify-content: center; 13 | flex: 0 0 23px; 14 | width: 23px; 15 | border-right: 1px solid #eaeaea; 16 | background-color: #ffffff; 17 | cursor: pointer; 18 | font-size: 20px; 19 | color: #447e9b; 20 | padding: 0; 21 | } 22 | 23 | [dir="rtl"] .toggle-nav-sidebar { 24 | border-left: 1px solid #eaeaea; 25 | border-right: 0; 26 | } 27 | 28 | .toggle-nav-sidebar:hover, 29 | .toggle-nav-sidebar:focus { 30 | background-color: #f6f6f6; 31 | } 32 | 33 | #nav-sidebar { 34 | z-index: 15; 35 | flex: 0 0 275px; 36 | left: -276px; 37 | margin-left: -276px; 38 | border-top: 1px solid transparent; 39 | border-right: 1px solid #eaeaea; 40 | background-color: #ffffff; 41 | overflow: auto; 42 | } 43 | 44 | [dir="rtl"] #nav-sidebar { 45 | border-left: 1px solid #eaeaea; 46 | border-right: 0; 47 | left: 0; 48 | margin-left: 0; 49 | right: -276px; 50 | margin-right: -276px; 51 | } 52 | 53 | .toggle-nav-sidebar::before { 54 | content: '\00BB'; 55 | } 56 | 57 | .main.shifted .toggle-nav-sidebar::before { 58 | content: '\00AB'; 59 | } 60 | 61 | .main.shifted > #nav-sidebar { 62 | left: 24px; 63 | margin-left: 0; 64 | } 65 | 66 | [dir="rtl"] .main.shifted > #nav-sidebar { 67 | left: 0; 68 | right: 24px; 69 | margin-right: 0; 70 | } 71 | 72 | #nav-sidebar .module th { 73 | width: 100%; 74 | overflow-wrap: anywhere; 75 | } 76 | 77 | #nav-sidebar .module th, 78 | #nav-sidebar .module caption { 79 | padding-left: 16px; 80 | } 81 | 82 | #nav-sidebar .module td { 83 | white-space: nowrap; 84 | } 85 | 86 | [dir="rtl"] #nav-sidebar .module th, 87 | [dir="rtl"] #nav-sidebar .module caption { 88 | padding-left: 8px; 89 | padding-right: 16px; 90 | } 91 | 92 | #nav-sidebar .current-app .section:link, 93 | #nav-sidebar .current-app .section:visited { 94 | color: #ffc; 95 | font-weight: bold; 96 | } 97 | 98 | #nav-sidebar .current-model { 99 | background: #ffc; 100 | } 101 | 102 | .main > #nav-sidebar + .content { 103 | max-width: calc(100% - 23px); 104 | } 105 | 106 | .main.shifted > #nav-sidebar + .content { 107 | max-width: calc(100% - 299px); 108 | } 109 | 110 | @media (max-width: 767px) { 111 | #nav-sidebar, #toggle-nav-sidebar { 112 | display: none; 113 | } 114 | 115 | .main > #nav-sidebar + .content, 116 | .main.shifted > #nav-sidebar + .content { 117 | max-width: 100%; 118 | } 119 | } 120 | -------------------------------------------------------------------------------- /static/admin/css/responsive_rtl.css: -------------------------------------------------------------------------------- 1 | /* TABLETS */ 2 | 3 | @media (max-width: 1024px) { 4 | [dir="rtl"] .colMS { 5 | margin-right: 0; 6 | } 7 | 8 | [dir="rtl"] #user-tools { 9 | text-align: right; 10 | } 11 | 12 | [dir="rtl"] #changelist .actions label { 13 | padding-left: 10px; 14 | padding-right: 0; 15 | } 16 | 17 | [dir="rtl"] #changelist .actions select { 18 | margin-left: 0; 19 | margin-right: 15px; 20 | } 21 | 22 | [dir="rtl"] .change-list .filtered .results, 23 | [dir="rtl"] .change-list .filtered .paginator, 24 | [dir="rtl"] .filtered #toolbar, 25 | [dir="rtl"] .filtered div.xfull, 26 | [dir="rtl"] .filtered .actions, 27 | [dir="rtl"] #changelist-filter { 28 | margin-left: 0; 29 | } 30 | 31 | [dir="rtl"] .inline-group ul.tools a.add, 32 | [dir="rtl"] .inline-group div.add-row a, 33 | [dir="rtl"] .inline-group .tabular tr.add-row td a { 34 | padding: 8px 26px 8px 10px; 35 | background-position: calc(100% - 8px) 9px; 36 | } 37 | 38 | [dir="rtl"] .related-widget-wrapper-link + .selector { 39 | margin-right: 0; 40 | margin-left: 15px; 41 | } 42 | 43 | [dir="rtl"] .selector .selector-filter label { 44 | margin-right: 0; 45 | margin-left: 8px; 46 | } 47 | 48 | [dir="rtl"] .object-tools li { 49 | float: right; 50 | } 51 | 52 | [dir="rtl"] .object-tools li + li { 53 | margin-left: 0; 54 | margin-right: 15px; 55 | } 56 | 57 | [dir="rtl"] .dashboard .module table td a { 58 | padding-left: 0; 59 | padding-right: 16px; 60 | } 61 | } 62 | 63 | /* MOBILE */ 64 | 65 | @media (max-width: 767px) { 66 | [dir="rtl"] .aligned .related-lookup, 67 | [dir="rtl"] .aligned .datetimeshortcuts { 68 | margin-left: 0; 69 | margin-right: 15px; 70 | } 71 | 72 | [dir="rtl"] .aligned ul { 73 | margin-right: 0; 74 | } 75 | 76 | [dir="rtl"] #changelist-filter { 77 | margin-left: 0; 78 | margin-right: 0; 79 | } 80 | } 81 | -------------------------------------------------------------------------------- /static/admin/css/vendor/select2/LICENSE-SELECT2.md: -------------------------------------------------------------------------------- 1 | The MIT License (MIT) 2 | 3 | Copyright (c) 2012-2017 Kevin Brown, Igor Vaynberg, and Select2 contributors 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in 13 | all copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 21 | THE SOFTWARE. 22 | -------------------------------------------------------------------------------- /static/admin/fonts/README.txt: -------------------------------------------------------------------------------- 1 | Roboto webfont source: https://www.google.com/fonts/specimen/Roboto 2 | WOFF files extracted using https://github.com/majodev/google-webfonts-helper 3 | Weights used in this project: Light (300), Regular (400), Bold (700) 4 | -------------------------------------------------------------------------------- /static/admin/fonts/Roboto-Bold-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/static/admin/fonts/Roboto-Bold-webfont.woff -------------------------------------------------------------------------------- /static/admin/fonts/Roboto-Light-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/static/admin/fonts/Roboto-Light-webfont.woff -------------------------------------------------------------------------------- /static/admin/fonts/Roboto-Regular-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/static/admin/fonts/Roboto-Regular-webfont.woff -------------------------------------------------------------------------------- /static/admin/img/LICENSE: -------------------------------------------------------------------------------- 1 | The MIT License (MIT) 2 | 3 | Copyright (c) 2014 Code Charm Ltd 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy of 6 | this software and associated documentation files (the "Software"), to deal in 7 | the Software without restriction, including without limitation the rights to 8 | use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of 9 | the Software, and to permit persons to whom the Software is furnished to do so, 10 | subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 17 | FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 18 | COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 19 | IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 20 | CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 21 | -------------------------------------------------------------------------------- /static/admin/img/README.txt: -------------------------------------------------------------------------------- 1 | All icons are taken from Font Awesome (http://fontawesome.io/) project. 2 | The Font Awesome font is licensed under the SIL OFL 1.1: 3 | - https://scripts.sil.org/OFL 4 | 5 | SVG icons source: https://github.com/encharm/Font-Awesome-SVG-PNG 6 | Font-Awesome-SVG-PNG is licensed under the MIT license (see file license 7 | in current folder). 8 | -------------------------------------------------------------------------------- /static/admin/img/calendar-icons.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /static/admin/img/gis/move_vertex_off.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /static/admin/img/gis/move_vertex_on.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /static/admin/img/icon-addlink.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /static/admin/img/icon-alert.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /static/admin/img/icon-calendar.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /static/admin/img/icon-changelink.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /static/admin/img/icon-clock.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /static/admin/img/icon-deletelink.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /static/admin/img/icon-no.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /static/admin/img/icon-unknown-alt.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /static/admin/img/icon-unknown.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /static/admin/img/icon-viewlink.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /static/admin/img/icon-yes.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /static/admin/img/inline-delete.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /static/admin/img/search.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /static/admin/img/sorting-icons.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | -------------------------------------------------------------------------------- /static/admin/img/tooltag-add.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /static/admin/img/tooltag-arrowright.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /static/admin/js/autocomplete.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | { 3 | const $ = django.jQuery; 4 | const init = function($element, options) { 5 | const settings = $.extend({ 6 | ajax: { 7 | data: function(params) { 8 | return { 9 | term: params.term, 10 | page: params.page 11 | }; 12 | } 13 | } 14 | }, options); 15 | $element.select2(settings); 16 | }; 17 | 18 | $.fn.djangoAdminSelect2 = function(options) { 19 | const settings = $.extend({}, options); 20 | $.each(this, function(i, element) { 21 | const $element = $(element); 22 | init($element, settings); 23 | }); 24 | return this; 25 | }; 26 | 27 | $(function() { 28 | // Initialize all autocomplete widgets except the one in the template 29 | // form used when a new formset is added. 30 | $('.admin-autocomplete').not('[name*=__prefix__]').djangoAdminSelect2(); 31 | }); 32 | 33 | $(document).on('formset:added', (function() { 34 | return function(event, $newFormset) { 35 | return $newFormset.find('.admin-autocomplete').djangoAdminSelect2(); 36 | }; 37 | })(this)); 38 | } 39 | -------------------------------------------------------------------------------- /static/admin/js/cancel.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | { 3 | // Call function fn when the DOM is loaded and ready. If it is already 4 | // loaded, call the function now. 5 | // http://youmightnotneedjquery.com/#ready 6 | function ready(fn) { 7 | if (document.readyState !== 'loading') { 8 | fn(); 9 | } else { 10 | document.addEventListener('DOMContentLoaded', fn); 11 | } 12 | } 13 | 14 | ready(function() { 15 | function handleClick(event) { 16 | event.preventDefault(); 17 | if (window.location.search.indexOf('&_popup=1') === -1) { 18 | window.history.back(); // Go back if not a popup. 19 | } else { 20 | window.close(); // Otherwise, close the popup. 21 | } 22 | } 23 | 24 | document.querySelectorAll('.cancel-link').forEach(function(el) { 25 | el.addEventListener('click', handleClick); 26 | }); 27 | }); 28 | } 29 | -------------------------------------------------------------------------------- /static/admin/js/change_form.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | { 3 | const inputTags = ['BUTTON', 'INPUT', 'SELECT', 'TEXTAREA']; 4 | const modelName = document.getElementById('django-admin-form-add-constants').dataset.modelName; 5 | if (modelName) { 6 | const form = document.getElementById(modelName + '_form'); 7 | for (const element of form.elements) { 8 | // HTMLElement.offsetParent returns null when the element is not 9 | // rendered. 10 | if (inputTags.includes(element.tagName) && !element.disabled && element.offsetParent) { 11 | element.focus(); 12 | break; 13 | } 14 | } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /static/admin/js/collapse.js: -------------------------------------------------------------------------------- 1 | /*global gettext*/ 2 | 'use strict'; 3 | { 4 | window.addEventListener('load', function() { 5 | // Add anchor tag for Show/Hide link 6 | const fieldsets = document.querySelectorAll('fieldset.collapse'); 7 | for (const [i, elem] of fieldsets.entries()) { 8 | // Don't hide if fields in this fieldset have errors 9 | if (elem.querySelectorAll('div.errors, ul.errorlist').length === 0) { 10 | elem.classList.add('collapsed'); 11 | const h2 = elem.querySelector('h2'); 12 | const link = document.createElement('a'); 13 | link.id = 'fieldsetcollapser' + i; 14 | link.className = 'collapse-toggle'; 15 | link.href = '#'; 16 | link.textContent = gettext('Show'); 17 | h2.appendChild(document.createTextNode(' (')); 18 | h2.appendChild(link); 19 | h2.appendChild(document.createTextNode(')')); 20 | } 21 | } 22 | // Add toggle to hide/show anchor tag 23 | const toggleFunc = function(ev) { 24 | if (ev.target.matches('.collapse-toggle')) { 25 | ev.preventDefault(); 26 | ev.stopPropagation(); 27 | const fieldset = ev.target.closest('fieldset'); 28 | if (fieldset.classList.contains('collapsed')) { 29 | // Show 30 | ev.target.textContent = gettext('Hide'); 31 | fieldset.classList.remove('collapsed'); 32 | } else { 33 | // Hide 34 | ev.target.textContent = gettext('Show'); 35 | fieldset.classList.add('collapsed'); 36 | } 37 | } 38 | }; 39 | document.querySelectorAll('fieldset.module').forEach(function(el) { 40 | el.addEventListener('click', toggleFunc); 41 | }); 42 | }); 43 | } 44 | -------------------------------------------------------------------------------- /static/admin/js/collapse.min.js: -------------------------------------------------------------------------------- 1 | 'use strict';window.addEventListener("load",function(){var c=document.querySelectorAll("fieldset.collapse");for(const [a,b]of c.entries())if(0===b.querySelectorAll("div.errors, ul.errorlist").length){b.classList.add("collapsed");c=b.querySelector("h2");const d=document.createElement("a");d.id="fieldsetcollapser"+a;d.className="collapse-toggle";d.href="#";d.textContent=gettext("Show");c.appendChild(document.createTextNode(" ("));c.appendChild(d);c.appendChild(document.createTextNode(")"))}const e= 2 | function(a){if(a.target.matches(".collapse-toggle")){a.preventDefault();a.stopPropagation();const b=a.target.closest("fieldset");b.classList.contains("collapsed")?(a.target.textContent=gettext("Hide"),b.classList.remove("collapsed")):(a.target.textContent=gettext("Show"),b.classList.add("collapsed"))}};document.querySelectorAll("fieldset.module").forEach(function(a){a.addEventListener("click",e)})}); 3 | -------------------------------------------------------------------------------- /static/admin/js/jquery.init.js: -------------------------------------------------------------------------------- 1 | /*global jQuery:false*/ 2 | 'use strict'; 3 | /* Puts the included jQuery into our own namespace using noConflict and passing 4 | * it 'true'. This ensures that the included jQuery doesn't pollute the global 5 | * namespace (i.e. this preserves pre-existing values for both window.$ and 6 | * window.jQuery). 7 | */ 8 | window.django = {jQuery: jQuery.noConflict(true)}; 9 | -------------------------------------------------------------------------------- /static/admin/js/nav_sidebar.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | { 3 | const toggleNavSidebar = document.getElementById('toggle-nav-sidebar'); 4 | if (toggleNavSidebar !== null) { 5 | const navLinks = document.querySelectorAll('#nav-sidebar a'); 6 | function disableNavLinkTabbing() { 7 | for (const navLink of navLinks) { 8 | navLink.tabIndex = -1; 9 | } 10 | } 11 | function enableNavLinkTabbing() { 12 | for (const navLink of navLinks) { 13 | navLink.tabIndex = 0; 14 | } 15 | } 16 | 17 | const main = document.getElementById('main'); 18 | let navSidebarIsOpen = localStorage.getItem('django.admin.navSidebarIsOpen'); 19 | if (navSidebarIsOpen === null) { 20 | navSidebarIsOpen = 'true'; 21 | } 22 | if (navSidebarIsOpen === 'false') { 23 | disableNavLinkTabbing(); 24 | } 25 | main.classList.toggle('shifted', navSidebarIsOpen === 'true'); 26 | 27 | toggleNavSidebar.addEventListener('click', function() { 28 | if (navSidebarIsOpen === 'true') { 29 | navSidebarIsOpen = 'false'; 30 | disableNavLinkTabbing(); 31 | } else { 32 | navSidebarIsOpen = 'true'; 33 | enableNavLinkTabbing(); 34 | } 35 | localStorage.setItem('django.admin.navSidebarIsOpen', navSidebarIsOpen); 36 | main.classList.toggle('shifted'); 37 | }); 38 | } 39 | } 40 | -------------------------------------------------------------------------------- /static/admin/js/popup_response.js: -------------------------------------------------------------------------------- 1 | /*global opener */ 2 | 'use strict'; 3 | { 4 | const initData = JSON.parse(document.getElementById('django-admin-popup-response-constants').dataset.popupResponse); 5 | switch(initData.action) { 6 | case 'change': 7 | opener.dismissChangeRelatedObjectPopup(window, initData.value, initData.obj, initData.new_value); 8 | break; 9 | case 'delete': 10 | opener.dismissDeleteRelatedObjectPopup(window, initData.value); 11 | break; 12 | default: 13 | opener.dismissAddRelatedObjectPopup(window, initData.value, initData.obj); 14 | break; 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /static/admin/js/prepopulate.js: -------------------------------------------------------------------------------- 1 | /*global URLify*/ 2 | 'use strict'; 3 | { 4 | const $ = django.jQuery; 5 | $.fn.prepopulate = function(dependencies, maxLength, allowUnicode) { 6 | /* 7 | Depends on urlify.js 8 | Populates a selected field with the values of the dependent fields, 9 | URLifies and shortens the string. 10 | dependencies - array of dependent fields ids 11 | maxLength - maximum length of the URLify'd string 12 | allowUnicode - Unicode support of the URLify'd string 13 | */ 14 | return this.each(function() { 15 | const prepopulatedField = $(this); 16 | 17 | const populate = function() { 18 | // Bail if the field's value has been changed by the user 19 | if (prepopulatedField.data('_changed')) { 20 | return; 21 | } 22 | 23 | const values = []; 24 | $.each(dependencies, function(i, field) { 25 | field = $(field); 26 | if (field.val().length > 0) { 27 | values.push(field.val()); 28 | } 29 | }); 30 | prepopulatedField.val(URLify(values.join(' '), maxLength, allowUnicode)); 31 | }; 32 | 33 | prepopulatedField.data('_changed', false); 34 | prepopulatedField.on('change', function() { 35 | prepopulatedField.data('_changed', true); 36 | }); 37 | 38 | if (!prepopulatedField.val()) { 39 | $(dependencies.join(',')).on('keyup change focus', populate); 40 | } 41 | }); 42 | }; 43 | } 44 | -------------------------------------------------------------------------------- /static/admin/js/prepopulate.min.js: -------------------------------------------------------------------------------- 1 | 'use strict';{const b=django.jQuery;b.fn.prepopulate=function(d,f,g){return this.each(function(){const a=b(this),h=function(){if(!a.data("_changed")){var e=[];b.each(d,function(a,c){c=b(c);01&&(u+="a"),u},inputTooShort:function(n){var e=n.minimum-n.input.length,u="Моля въведете още "+e+" символ";return e>1&&(u+="a"),u},loadingMore:function(){return"Зареждат се още…"},maximumSelected:function(n){var e="Можете да направите до "+n.maximum+" ";return n.maximum>1?e+="избора":e+="избор",e},noResults:function(){return"Няма намерени съвпадения"},searching:function(){return"Търсене…"},removeAllItems:function(){return"Премахнете всички елементи"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/bn.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/bn",[],function(){return{errorLoading:function(){return"ফলাফলগুলি লোড করা যায়নি।"},inputTooLong:function(n){var e=n.input.length-n.maximum,u="অনুগ্রহ করে "+e+" টি অক্ষর মুছে দিন।";return 1!=e&&(u="অনুগ্রহ করে "+e+" টি অক্ষর মুছে দিন।"),u},inputTooShort:function(n){return n.minimum-n.input.length+" টি অক্ষর অথবা অধিক অক্ষর লিখুন।"},loadingMore:function(){return"আরো ফলাফল লোড হচ্ছে ..."},maximumSelected:function(n){var e=n.maximum+" টি আইটেম নির্বাচন করতে পারবেন।";return 1!=n.maximum&&(e=n.maximum+" টি আইটেম নির্বাচন করতে পারবেন।"),e},noResults:function(){return"কোন ফলাফল পাওয়া যায়নি।"},searching:function(){return"অনুসন্ধান করা হচ্ছে ..."}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/bs.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/bs",[],function(){function e(e,n,r,t){return e%10==1&&e%100!=11?n:e%10>=2&&e%10<=4&&(e%100<12||e%100>14)?r:t}return{errorLoading:function(){return"Preuzimanje nije uspijelo."},inputTooLong:function(n){var r=n.input.length-n.maximum,t="Obrišite "+r+" simbol";return t+=e(r,"","a","a")},inputTooShort:function(n){var r=n.minimum-n.input.length,t="Ukucajte bar još "+r+" simbol";return t+=e(r,"","a","a")},loadingMore:function(){return"Preuzimanje još rezultata…"},maximumSelected:function(n){var r="Možete izabrati samo "+n.maximum+" stavk";return r+=e(n.maximum,"u","e","i")},noResults:function(){return"Ništa nije pronađeno"},searching:function(){return"Pretraga…"},removeAllItems:function(){return"Uklonite sve stavke"}}}),e.define,e.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/ca.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/ca",[],function(){return{errorLoading:function(){return"La càrrega ha fallat"},inputTooLong:function(e){var n=e.input.length-e.maximum,r="Si us plau, elimina "+n+" car";return r+=1==n?"àcter":"àcters"},inputTooShort:function(e){var n=e.minimum-e.input.length,r="Si us plau, introdueix "+n+" car";return r+=1==n?"àcter":"àcters"},loadingMore:function(){return"Carregant més resultats…"},maximumSelected:function(e){var n="Només es pot seleccionar "+e.maximum+" element";return 1!=e.maximum&&(n+="s"),n},noResults:function(){return"No s'han trobat resultats"},searching:function(){return"Cercant…"},removeAllItems:function(){return"Treu tots els elements"}}}),e.define,e.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/cs.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/cs",[],function(){function e(e,n){switch(e){case 2:return n?"dva":"dvě";case 3:return"tři";case 4:return"čtyři"}return""}return{errorLoading:function(){return"Výsledky nemohly být načteny."},inputTooLong:function(n){var t=n.input.length-n.maximum;return 1==t?"Prosím, zadejte o jeden znak méně.":t<=4?"Prosím, zadejte o "+e(t,!0)+" znaky méně.":"Prosím, zadejte o "+t+" znaků méně."},inputTooShort:function(n){var t=n.minimum-n.input.length;return 1==t?"Prosím, zadejte ještě jeden znak.":t<=4?"Prosím, zadejte ještě další "+e(t,!0)+" znaky.":"Prosím, zadejte ještě dalších "+t+" znaků."},loadingMore:function(){return"Načítají se další výsledky…"},maximumSelected:function(n){var t=n.maximum;return 1==t?"Můžete zvolit jen jednu položku.":t<=4?"Můžete zvolit maximálně "+e(t,!1)+" položky.":"Můžete zvolit maximálně "+t+" položek."},noResults:function(){return"Nenalezeny žádné položky."},searching:function(){return"Vyhledávání…"},removeAllItems:function(){return"Odstraňte všechny položky"}}}),e.define,e.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/da.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/da",[],function(){return{errorLoading:function(){return"Resultaterne kunne ikke indlæses."},inputTooLong:function(e){return"Angiv venligst "+(e.input.length-e.maximum)+" tegn mindre"},inputTooShort:function(e){return"Angiv venligst "+(e.minimum-e.input.length)+" tegn mere"},loadingMore:function(){return"Indlæser flere resultater…"},maximumSelected:function(e){var n="Du kan kun vælge "+e.maximum+" emne";return 1!=e.maximum&&(n+="r"),n},noResults:function(){return"Ingen resultater fundet"},searching:function(){return"Søger…"},removeAllItems:function(){return"Fjern alle elementer"}}}),e.define,e.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/de.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/de",[],function(){return{errorLoading:function(){return"Die Ergebnisse konnten nicht geladen werden."},inputTooLong:function(e){return"Bitte "+(e.input.length-e.maximum)+" Zeichen weniger eingeben"},inputTooShort:function(e){return"Bitte "+(e.minimum-e.input.length)+" Zeichen mehr eingeben"},loadingMore:function(){return"Lade mehr Ergebnisse…"},maximumSelected:function(e){var n="Sie können nur "+e.maximum+" Element";return 1!=e.maximum&&(n+="e"),n+=" auswählen"},noResults:function(){return"Keine Übereinstimmungen gefunden"},searching:function(){return"Suche…"},removeAllItems:function(){return"Entferne alle Elemente"}}}),e.define,e.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/dsb.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/dsb",[],function(){var n=["znamuško","znamušce","znamuška","znamuškow"],e=["zapisk","zapiska","zapiski","zapiskow"],u=function(n,e){return 1===n?e[0]:2===n?e[1]:n>2&&n<=4?e[2]:n>=5?e[3]:void 0};return{errorLoading:function(){return"Wuslědki njejsu se dali zacytaś."},inputTooLong:function(e){var a=e.input.length-e.maximum;return"Pšosym lašuj "+a+" "+u(a,n)},inputTooShort:function(e){var a=e.minimum-e.input.length;return"Pšosym zapódaj nanejmjenjej "+a+" "+u(a,n)},loadingMore:function(){return"Dalšne wuslědki se zacytaju…"},maximumSelected:function(n){return"Móžoš jano "+n.maximum+" "+u(n.maximum,e)+"wubraś."},noResults:function(){return"Žedne wuslědki namakane"},searching:function(){return"Pyta se…"},removeAllItems:function(){return"Remove all items"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/el.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/el",[],function(){return{errorLoading:function(){return"Τα αποτελέσματα δεν μπόρεσαν να φορτώσουν."},inputTooLong:function(n){var e=n.input.length-n.maximum,u="Παρακαλώ διαγράψτε "+e+" χαρακτήρ";return 1==e&&(u+="α"),1!=e&&(u+="ες"),u},inputTooShort:function(n){return"Παρακαλώ συμπληρώστε "+(n.minimum-n.input.length)+" ή περισσότερους χαρακτήρες"},loadingMore:function(){return"Φόρτωση περισσότερων αποτελεσμάτων…"},maximumSelected:function(n){var e="Μπορείτε να επιλέξετε μόνο "+n.maximum+" επιλογ";return 1==n.maximum&&(e+="ή"),1!=n.maximum&&(e+="ές"),e},noResults:function(){return"Δεν βρέθηκαν αποτελέσματα"},searching:function(){return"Αναζήτηση…"},removeAllItems:function(){return"Καταργήστε όλα τα στοιχεία"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/en.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/en",[],function(){return{errorLoading:function(){return"The results could not be loaded."},inputTooLong:function(e){var n=e.input.length-e.maximum,r="Please delete "+n+" character";return 1!=n&&(r+="s"),r},inputTooShort:function(e){return"Please enter "+(e.minimum-e.input.length)+" or more characters"},loadingMore:function(){return"Loading more results…"},maximumSelected:function(e){var n="You can only select "+e.maximum+" item";return 1!=e.maximum&&(n+="s"),n},noResults:function(){return"No results found"},searching:function(){return"Searching…"},removeAllItems:function(){return"Remove all items"}}}),e.define,e.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/es.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/es",[],function(){return{errorLoading:function(){return"No se pudieron cargar los resultados"},inputTooLong:function(e){var n=e.input.length-e.maximum,r="Por favor, elimine "+n+" car";return r+=1==n?"ácter":"acteres"},inputTooShort:function(e){var n=e.minimum-e.input.length,r="Por favor, introduzca "+n+" car";return r+=1==n?"ácter":"acteres"},loadingMore:function(){return"Cargando más resultados…"},maximumSelected:function(e){var n="Sólo puede seleccionar "+e.maximum+" elemento";return 1!=e.maximum&&(n+="s"),n},noResults:function(){return"No se encontraron resultados"},searching:function(){return"Buscando…"},removeAllItems:function(){return"Eliminar todos los elementos"}}}),e.define,e.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/et.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/et",[],function(){return{inputTooLong:function(e){var n=e.input.length-e.maximum,t="Sisesta "+n+" täht";return 1!=n&&(t+="e"),t+=" vähem"},inputTooShort:function(e){var n=e.minimum-e.input.length,t="Sisesta "+n+" täht";return 1!=n&&(t+="e"),t+=" rohkem"},loadingMore:function(){return"Laen tulemusi…"},maximumSelected:function(e){var n="Saad vaid "+e.maximum+" tulemus";return 1==e.maximum?n+="e":n+="t",n+=" valida"},noResults:function(){return"Tulemused puuduvad"},searching:function(){return"Otsin…"},removeAllItems:function(){return"Eemalda kõik esemed"}}}),e.define,e.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/eu.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/eu",[],function(){return{inputTooLong:function(e){var t=e.input.length-e.maximum,n="Idatzi ";return n+=1==t?"karaktere bat":t+" karaktere",n+=" gutxiago"},inputTooShort:function(e){var t=e.minimum-e.input.length,n="Idatzi ";return n+=1==t?"karaktere bat":t+" karaktere",n+=" gehiago"},loadingMore:function(){return"Emaitza gehiago kargatzen…"},maximumSelected:function(e){return 1===e.maximum?"Elementu bakarra hauta dezakezu":e.maximum+" elementu hauta ditzakezu soilik"},noResults:function(){return"Ez da bat datorrenik aurkitu"},searching:function(){return"Bilatzen…"},removeAllItems:function(){return"Kendu elementu guztiak"}}}),e.define,e.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/fa.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/fa",[],function(){return{errorLoading:function(){return"امکان بارگذاری نتایج وجود ندارد."},inputTooLong:function(n){return"لطفاً "+(n.input.length-n.maximum)+" کاراکتر را حذف نمایید"},inputTooShort:function(n){return"لطفاً تعداد "+(n.minimum-n.input.length)+" کاراکتر یا بیشتر وارد نمایید"},loadingMore:function(){return"در حال بارگذاری نتایج بیشتر..."},maximumSelected:function(n){return"شما تنها می‌توانید "+n.maximum+" آیتم را انتخاب نمایید"},noResults:function(){return"هیچ نتیجه‌ای یافت نشد"},searching:function(){return"در حال جستجو..."},removeAllItems:function(){return"همه موارد را حذف کنید"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/fi.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/fi",[],function(){return{errorLoading:function(){return"Tuloksia ei saatu ladattua."},inputTooLong:function(n){return"Ole hyvä ja anna "+(n.input.length-n.maximum)+" merkkiä vähemmän"},inputTooShort:function(n){return"Ole hyvä ja anna "+(n.minimum-n.input.length)+" merkkiä lisää"},loadingMore:function(){return"Ladataan lisää tuloksia…"},maximumSelected:function(n){return"Voit valita ainoastaan "+n.maximum+" kpl"},noResults:function(){return"Ei tuloksia"},searching:function(){return"Haetaan…"},removeAllItems:function(){return"Poista kaikki kohteet"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/fr.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/fr",[],function(){return{errorLoading:function(){return"Les résultats ne peuvent pas être chargés."},inputTooLong:function(e){var n=e.input.length-e.maximum;return"Supprimez "+n+" caractère"+(n>1?"s":"")},inputTooShort:function(e){var n=e.minimum-e.input.length;return"Saisissez au moins "+n+" caractère"+(n>1?"s":"")},loadingMore:function(){return"Chargement de résultats supplémentaires…"},maximumSelected:function(e){return"Vous pouvez seulement sélectionner "+e.maximum+" élément"+(e.maximum>1?"s":"")},noResults:function(){return"Aucun résultat trouvé"},searching:function(){return"Recherche en cours…"},removeAllItems:function(){return"Supprimer tous les éléments"}}}),e.define,e.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/gl.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/gl",[],function(){return{errorLoading:function(){return"Non foi posíbel cargar os resultados."},inputTooLong:function(e){var n=e.input.length-e.maximum;return 1===n?"Elimine un carácter":"Elimine "+n+" caracteres"},inputTooShort:function(e){var n=e.minimum-e.input.length;return 1===n?"Engada un carácter":"Engada "+n+" caracteres"},loadingMore:function(){return"Cargando máis resultados…"},maximumSelected:function(e){return 1===e.maximum?"Só pode seleccionar un elemento":"Só pode seleccionar "+e.maximum+" elementos"},noResults:function(){return"Non se atoparon resultados"},searching:function(){return"Buscando…"},removeAllItems:function(){return"Elimina todos os elementos"}}}),e.define,e.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/he.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/he",[],function(){return{errorLoading:function(){return"שגיאה בטעינת התוצאות"},inputTooLong:function(n){var e=n.input.length-n.maximum,r="נא למחוק ";return r+=1===e?"תו אחד":e+" תווים"},inputTooShort:function(n){var e=n.minimum-n.input.length,r="נא להכניס ";return r+=1===e?"תו אחד":e+" תווים",r+=" או יותר"},loadingMore:function(){return"טוען תוצאות נוספות…"},maximumSelected:function(n){var e="באפשרותך לבחור עד ";return 1===n.maximum?e+="פריט אחד":e+=n.maximum+" פריטים",e},noResults:function(){return"לא נמצאו תוצאות"},searching:function(){return"מחפש…"},removeAllItems:function(){return"הסר את כל הפריטים"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/hi.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/hi",[],function(){return{errorLoading:function(){return"परिणामों को लोड नहीं किया जा सका।"},inputTooLong:function(n){var e=n.input.length-n.maximum,r=e+" अक्षर को हटा दें";return e>1&&(r=e+" अक्षरों को हटा दें "),r},inputTooShort:function(n){return"कृपया "+(n.minimum-n.input.length)+" या अधिक अक्षर दर्ज करें"},loadingMore:function(){return"अधिक परिणाम लोड हो रहे है..."},maximumSelected:function(n){return"आप केवल "+n.maximum+" आइटम का चयन कर सकते हैं"},noResults:function(){return"कोई परिणाम नहीं मिला"},searching:function(){return"खोज रहा है..."},removeAllItems:function(){return"सभी वस्तुओं को हटा दें"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/hr.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/hr",[],function(){function n(n){var e=" "+n+" znak";return n%10<5&&n%10>0&&(n%100<5||n%100>19)?n%10>1&&(e+="a"):e+="ova",e}return{errorLoading:function(){return"Preuzimanje nije uspjelo."},inputTooLong:function(e){return"Unesite "+n(e.input.length-e.maximum)},inputTooShort:function(e){return"Unesite još "+n(e.minimum-e.input.length)},loadingMore:function(){return"Učitavanje rezultata…"},maximumSelected:function(n){return"Maksimalan broj odabranih stavki je "+n.maximum},noResults:function(){return"Nema rezultata"},searching:function(){return"Pretraga…"},removeAllItems:function(){return"Ukloni sve stavke"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/hsb.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/hsb",[],function(){var n=["znamješko","znamješce","znamješka","znamješkow"],e=["zapisk","zapiskaj","zapiski","zapiskow"],u=function(n,e){return 1===n?e[0]:2===n?e[1]:n>2&&n<=4?e[2]:n>=5?e[3]:void 0};return{errorLoading:function(){return"Wuslědki njedachu so začitać."},inputTooLong:function(e){var a=e.input.length-e.maximum;return"Prošu zhašej "+a+" "+u(a,n)},inputTooShort:function(e){var a=e.minimum-e.input.length;return"Prošu zapodaj znajmjeńša "+a+" "+u(a,n)},loadingMore:function(){return"Dalše wuslědki so začitaja…"},maximumSelected:function(n){return"Móžeš jenož "+n.maximum+" "+u(n.maximum,e)+"wubrać"},noResults:function(){return"Žane wuslědki namakane"},searching:function(){return"Pyta so…"},removeAllItems:function(){return"Remove all items"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/hu.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/hu",[],function(){return{errorLoading:function(){return"Az eredmények betöltése nem sikerült."},inputTooLong:function(e){return"Túl hosszú. "+(e.input.length-e.maximum)+" karakterrel több, mint kellene."},inputTooShort:function(e){return"Túl rövid. Még "+(e.minimum-e.input.length)+" karakter hiányzik."},loadingMore:function(){return"Töltés…"},maximumSelected:function(e){return"Csak "+e.maximum+" elemet lehet kiválasztani."},noResults:function(){return"Nincs találat."},searching:function(){return"Keresés…"},removeAllItems:function(){return"Távolítson el minden elemet"}}}),e.define,e.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/hy.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/hy",[],function(){return{errorLoading:function(){return"Արդյունքները հնարավոր չէ բեռնել։"},inputTooLong:function(n){return"Խնդրում ենք հեռացնել "+(n.input.length-n.maximum)+" նշան"},inputTooShort:function(n){return"Խնդրում ենք մուտքագրել "+(n.minimum-n.input.length)+" կամ ավել նշաններ"},loadingMore:function(){return"Բեռնվում են նոր արդյունքներ․․․"},maximumSelected:function(n){return"Դուք կարող եք ընտրել առավելագույնը "+n.maximum+" կետ"},noResults:function(){return"Արդյունքներ չեն գտնվել"},searching:function(){return"Որոնում․․․"},removeAllItems:function(){return"Հեռացնել բոլոր տարրերը"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/id.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/id",[],function(){return{errorLoading:function(){return"Data tidak boleh diambil."},inputTooLong:function(n){return"Hapuskan "+(n.input.length-n.maximum)+" huruf"},inputTooShort:function(n){return"Masukkan "+(n.minimum-n.input.length)+" huruf lagi"},loadingMore:function(){return"Mengambil data…"},maximumSelected:function(n){return"Anda hanya dapat memilih "+n.maximum+" pilihan"},noResults:function(){return"Tidak ada data yang sesuai"},searching:function(){return"Mencari…"},removeAllItems:function(){return"Hapus semua item"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/is.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/is",[],function(){return{inputTooLong:function(n){var t=n.input.length-n.maximum,e="Vinsamlegast styttið texta um "+t+" staf";return t<=1?e:e+"i"},inputTooShort:function(n){var t=n.minimum-n.input.length,e="Vinsamlegast skrifið "+t+" staf";return t>1&&(e+="i"),e+=" í viðbót"},loadingMore:function(){return"Sæki fleiri niðurstöður…"},maximumSelected:function(n){return"Þú getur aðeins valið "+n.maximum+" atriði"},noResults:function(){return"Ekkert fannst"},searching:function(){return"Leita…"},removeAllItems:function(){return"Fjarlægðu öll atriði"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/it.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/it",[],function(){return{errorLoading:function(){return"I risultati non possono essere caricati."},inputTooLong:function(e){var n=e.input.length-e.maximum,t="Per favore cancella "+n+" caratter";return t+=1!==n?"i":"e"},inputTooShort:function(e){return"Per favore inserisci "+(e.minimum-e.input.length)+" o più caratteri"},loadingMore:function(){return"Caricando più risultati…"},maximumSelected:function(e){var n="Puoi selezionare solo "+e.maximum+" element";return 1!==e.maximum?n+="i":n+="o",n},noResults:function(){return"Nessun risultato trovato"},searching:function(){return"Sto cercando…"},removeAllItems:function(){return"Rimuovi tutti gli oggetti"}}}),e.define,e.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/ja.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/ja",[],function(){return{errorLoading:function(){return"結果が読み込まれませんでした"},inputTooLong:function(n){return n.input.length-n.maximum+" 文字を削除してください"},inputTooShort:function(n){return"少なくとも "+(n.minimum-n.input.length)+" 文字を入力してください"},loadingMore:function(){return"読み込み中…"},maximumSelected:function(n){return n.maximum+" 件しか選択できません"},noResults:function(){return"対象が見つかりません"},searching:function(){return"検索しています…"},removeAllItems:function(){return"すべてのアイテムを削除"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/ka.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/ka",[],function(){return{errorLoading:function(){return"მონაცემების ჩატვირთვა შეუძლებელია."},inputTooLong:function(n){return"გთხოვთ აკრიფეთ "+(n.input.length-n.maximum)+" სიმბოლოთი ნაკლები"},inputTooShort:function(n){return"გთხოვთ აკრიფეთ "+(n.minimum-n.input.length)+" სიმბოლო ან მეტი"},loadingMore:function(){return"მონაცემების ჩატვირთვა…"},maximumSelected:function(n){return"თქვენ შეგიძლიათ აირჩიოთ არაუმეტეს "+n.maximum+" ელემენტი"},noResults:function(){return"რეზულტატი არ მოიძებნა"},searching:function(){return"ძიება…"},removeAllItems:function(){return"ამოიღე ყველა ელემენტი"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/km.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/km",[],function(){return{errorLoading:function(){return"មិនអាចទាញយកទិន្នន័យ"},inputTooLong:function(n){return"សូមលុបចេញ "+(n.input.length-n.maximum)+" អក្សរ"},inputTooShort:function(n){return"សូមបញ្ចូល"+(n.minimum-n.input.length)+" អក្សរ រឺ ច្រើនជាងនេះ"},loadingMore:function(){return"កំពុងទាញយកទិន្នន័យបន្ថែម..."},maximumSelected:function(n){return"អ្នកអាចជ្រើសរើសបានតែ "+n.maximum+" ជម្រើសប៉ុណ្ណោះ"},noResults:function(){return"មិនមានលទ្ធផល"},searching:function(){return"កំពុងស្វែងរក..."},removeAllItems:function(){return"លុបធាតុទាំងអស់"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/ko.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/ko",[],function(){return{errorLoading:function(){return"결과를 불러올 수 없습니다."},inputTooLong:function(n){return"너무 깁니다. "+(n.input.length-n.maximum)+" 글자 지워주세요."},inputTooShort:function(n){return"너무 짧습니다. "+(n.minimum-n.input.length)+" 글자 더 입력해주세요."},loadingMore:function(){return"불러오는 중…"},maximumSelected:function(n){return"최대 "+n.maximum+"개까지만 선택 가능합니다."},noResults:function(){return"결과가 없습니다."},searching:function(){return"검색 중…"},removeAllItems:function(){return"모든 항목 삭제"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/lt.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/lt",[],function(){function n(n,e,i,t){return n%10==1&&(n%100<11||n%100>19)?e:n%10>=2&&n%10<=9&&(n%100<11||n%100>19)?i:t}return{inputTooLong:function(e){var i=e.input.length-e.maximum,t="Pašalinkite "+i+" simbol";return t+=n(i,"į","ius","ių")},inputTooShort:function(e){var i=e.minimum-e.input.length,t="Įrašykite dar "+i+" simbol";return t+=n(i,"į","ius","ių")},loadingMore:function(){return"Kraunama daugiau rezultatų…"},maximumSelected:function(e){var i="Jūs galite pasirinkti tik "+e.maximum+" element";return i+=n(e.maximum,"ą","us","ų")},noResults:function(){return"Atitikmenų nerasta"},searching:function(){return"Ieškoma…"},removeAllItems:function(){return"Pašalinti visus elementus"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/lv.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/lv",[],function(){function e(e,n,u,i){return 11===e?n:e%10==1?u:i}return{inputTooLong:function(n){var u=n.input.length-n.maximum,i="Lūdzu ievadiet par "+u;return(i+=" simbol"+e(u,"iem","u","iem"))+" mazāk"},inputTooShort:function(n){var u=n.minimum-n.input.length,i="Lūdzu ievadiet vēl "+u;return i+=" simbol"+e(u,"us","u","us")},loadingMore:function(){return"Datu ielāde…"},maximumSelected:function(n){var u="Jūs varat izvēlēties ne vairāk kā "+n.maximum;return u+=" element"+e(n.maximum,"us","u","us")},noResults:function(){return"Sakritību nav"},searching:function(){return"Meklēšana…"},removeAllItems:function(){return"Noņemt visus vienumus"}}}),e.define,e.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/mk.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/mk",[],function(){return{inputTooLong:function(n){var e=(n.input.length,n.maximum,"Ве молиме внесете "+n.maximum+" помалку карактер");return 1!==n.maximum&&(e+="и"),e},inputTooShort:function(n){var e=(n.minimum,n.input.length,"Ве молиме внесете уште "+n.maximum+" карактер");return 1!==n.maximum&&(e+="и"),e},loadingMore:function(){return"Вчитување резултати…"},maximumSelected:function(n){var e="Можете да изберете само "+n.maximum+" ставк";return 1===n.maximum?e+="а":e+="и",e},noResults:function(){return"Нема пронајдено совпаѓања"},searching:function(){return"Пребарување…"},removeAllItems:function(){return"Отстрани ги сите предмети"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/ms.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/ms",[],function(){return{errorLoading:function(){return"Keputusan tidak berjaya dimuatkan."},inputTooLong:function(n){return"Sila hapuskan "+(n.input.length-n.maximum)+" aksara"},inputTooShort:function(n){return"Sila masukkan "+(n.minimum-n.input.length)+" atau lebih aksara"},loadingMore:function(){return"Sedang memuatkan keputusan…"},maximumSelected:function(n){return"Anda hanya boleh memilih "+n.maximum+" pilihan"},noResults:function(){return"Tiada padanan yang ditemui"},searching:function(){return"Mencari…"},removeAllItems:function(){return"Keluarkan semua item"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/nb.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/nb",[],function(){return{errorLoading:function(){return"Kunne ikke hente resultater."},inputTooLong:function(e){return"Vennligst fjern "+(e.input.length-e.maximum)+" tegn"},inputTooShort:function(e){return"Vennligst skriv inn "+(e.minimum-e.input.length)+" tegn til"},loadingMore:function(){return"Laster flere resultater…"},maximumSelected:function(e){return"Du kan velge maks "+e.maximum+" elementer"},noResults:function(){return"Ingen treff"},searching:function(){return"Søker…"},removeAllItems:function(){return"Fjern alle elementer"}}}),e.define,e.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/ne.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/ne",[],function(){return{errorLoading:function(){return"नतिजाहरु देखाउन सकिएन।"},inputTooLong:function(n){var e=n.input.length-n.maximum,u="कृपया "+e+" अक्षर मेटाउनुहोस्।";return 1!=e&&(u+="कृपया "+e+" अक्षरहरु मेटाउनुहोस्।"),u},inputTooShort:function(n){return"कृपया बाँकी रहेका "+(n.minimum-n.input.length)+" वा अरु धेरै अक्षरहरु भर्नुहोस्।"},loadingMore:function(){return"अरु नतिजाहरु भरिँदैछन् …"},maximumSelected:function(n){var e="तँपाई "+n.maximum+" वस्तु मात्र छान्न पाउँनुहुन्छ।";return 1!=n.maximum&&(e="तँपाई "+n.maximum+" वस्तुहरु मात्र छान्न पाउँनुहुन्छ।"),e},noResults:function(){return"कुनै पनि नतिजा भेटिएन।"},searching:function(){return"खोजि हुँदैछ…"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/nl.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/nl",[],function(){return{errorLoading:function(){return"De resultaten konden niet worden geladen."},inputTooLong:function(e){return"Gelieve "+(e.input.length-e.maximum)+" karakters te verwijderen"},inputTooShort:function(e){return"Gelieve "+(e.minimum-e.input.length)+" of meer karakters in te voeren"},loadingMore:function(){return"Meer resultaten laden…"},maximumSelected:function(e){var n=1==e.maximum?"kan":"kunnen",r="Er "+n+" maar "+e.maximum+" item";return 1!=e.maximum&&(r+="s"),r+=" worden geselecteerd"},noResults:function(){return"Geen resultaten gevonden…"},searching:function(){return"Zoeken…"},removeAllItems:function(){return"Verwijder alle items"}}}),e.define,e.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/pl.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/pl",[],function(){var n=["znak","znaki","znaków"],e=["element","elementy","elementów"],r=function(n,e){return 1===n?e[0]:n>1&&n<=4?e[1]:n>=5?e[2]:void 0};return{errorLoading:function(){return"Nie można załadować wyników."},inputTooLong:function(e){var t=e.input.length-e.maximum;return"Usuń "+t+" "+r(t,n)},inputTooShort:function(e){var t=e.minimum-e.input.length;return"Podaj przynajmniej "+t+" "+r(t,n)},loadingMore:function(){return"Trwa ładowanie…"},maximumSelected:function(n){return"Możesz zaznaczyć tylko "+n.maximum+" "+r(n.maximum,e)},noResults:function(){return"Brak wyników"},searching:function(){return"Trwa wyszukiwanie…"},removeAllItems:function(){return"Usuń wszystkie przedmioty"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/ps.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/ps",[],function(){return{errorLoading:function(){return"پايلي نه سي ترلاسه کېدای"},inputTooLong:function(n){var e=n.input.length-n.maximum,r="د مهربانۍ لمخي "+e+" توری ړنګ کړئ";return 1!=e&&(r=r.replace("توری","توري")),r},inputTooShort:function(n){return"لږ تر لږه "+(n.minimum-n.input.length)+" يا ډېر توري وليکئ"},loadingMore:function(){return"نوري پايلي ترلاسه کيږي..."},maximumSelected:function(n){var e="تاسو يوازي "+n.maximum+" قلم په نښه کولای سی";return 1!=n.maximum&&(e=e.replace("قلم","قلمونه")),e},noResults:function(){return"پايلي و نه موندل سوې"},searching:function(){return"لټول کيږي..."},removeAllItems:function(){return"ټول توکي لرې کړئ"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/pt-BR.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/pt-BR",[],function(){return{errorLoading:function(){return"Os resultados não puderam ser carregados."},inputTooLong:function(e){var n=e.input.length-e.maximum,r="Apague "+n+" caracter";return 1!=n&&(r+="es"),r},inputTooShort:function(e){return"Digite "+(e.minimum-e.input.length)+" ou mais caracteres"},loadingMore:function(){return"Carregando mais resultados…"},maximumSelected:function(e){var n="Você só pode selecionar "+e.maximum+" ite";return 1==e.maximum?n+="m":n+="ns",n},noResults:function(){return"Nenhum resultado encontrado"},searching:function(){return"Buscando…"},removeAllItems:function(){return"Remover todos os itens"}}}),e.define,e.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/pt.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/pt",[],function(){return{errorLoading:function(){return"Os resultados não puderam ser carregados."},inputTooLong:function(e){var r=e.input.length-e.maximum,n="Por favor apague "+r+" ";return n+=1!=r?"caracteres":"caractere"},inputTooShort:function(e){return"Introduza "+(e.minimum-e.input.length)+" ou mais caracteres"},loadingMore:function(){return"A carregar mais resultados…"},maximumSelected:function(e){var r="Apenas pode seleccionar "+e.maximum+" ";return r+=1!=e.maximum?"itens":"item"},noResults:function(){return"Sem resultados"},searching:function(){return"A procurar…"},removeAllItems:function(){return"Remover todos os itens"}}}),e.define,e.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/ro.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/ro",[],function(){return{errorLoading:function(){return"Rezultatele nu au putut fi incărcate."},inputTooLong:function(e){var t=e.input.length-e.maximum,n="Vă rugăm să ștergeți"+t+" caracter";return 1!==t&&(n+="e"),n},inputTooShort:function(e){return"Vă rugăm să introduceți "+(e.minimum-e.input.length)+" sau mai multe caractere"},loadingMore:function(){return"Se încarcă mai multe rezultate…"},maximumSelected:function(e){var t="Aveți voie să selectați cel mult "+e.maximum;return t+=" element",1!==e.maximum&&(t+="e"),t},noResults:function(){return"Nu au fost găsite rezultate"},searching:function(){return"Căutare…"},removeAllItems:function(){return"Eliminați toate elementele"}}}),e.define,e.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/ru.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/ru",[],function(){function n(n,e,r,u){return n%10<5&&n%10>0&&n%100<5||n%100>20?n%10>1?r:e:u}return{errorLoading:function(){return"Невозможно загрузить результаты"},inputTooLong:function(e){var r=e.input.length-e.maximum,u="Пожалуйста, введите на "+r+" символ";return u+=n(r,"","a","ов"),u+=" меньше"},inputTooShort:function(e){var r=e.minimum-e.input.length,u="Пожалуйста, введите ещё хотя бы "+r+" символ";return u+=n(r,"","a","ов")},loadingMore:function(){return"Загрузка данных…"},maximumSelected:function(e){var r="Вы можете выбрать не более "+e.maximum+" элемент";return r+=n(e.maximum,"","a","ов")},noResults:function(){return"Совпадений не найдено"},searching:function(){return"Поиск…"},removeAllItems:function(){return"Удалить все элементы"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/sk.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/sk",[],function(){var e={2:function(e){return e?"dva":"dve"},3:function(){return"tri"},4:function(){return"štyri"}};return{errorLoading:function(){return"Výsledky sa nepodarilo načítať."},inputTooLong:function(n){var t=n.input.length-n.maximum;return 1==t?"Prosím, zadajte o jeden znak menej":t>=2&&t<=4?"Prosím, zadajte o "+e[t](!0)+" znaky menej":"Prosím, zadajte o "+t+" znakov menej"},inputTooShort:function(n){var t=n.minimum-n.input.length;return 1==t?"Prosím, zadajte ešte jeden znak":t<=4?"Prosím, zadajte ešte ďalšie "+e[t](!0)+" znaky":"Prosím, zadajte ešte ďalších "+t+" znakov"},loadingMore:function(){return"Načítanie ďalších výsledkov…"},maximumSelected:function(n){return 1==n.maximum?"Môžete zvoliť len jednu položku":n.maximum>=2&&n.maximum<=4?"Môžete zvoliť najviac "+e[n.maximum](!1)+" položky":"Môžete zvoliť najviac "+n.maximum+" položiek"},noResults:function(){return"Nenašli sa žiadne položky"},searching:function(){return"Vyhľadávanie…"},removeAllItems:function(){return"Odstráňte všetky položky"}}}),e.define,e.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/sl.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/sl",[],function(){return{errorLoading:function(){return"Zadetkov iskanja ni bilo mogoče naložiti."},inputTooLong:function(e){var n=e.input.length-e.maximum,t="Prosim zbrišite "+n+" znak";return 2==n?t+="a":1!=n&&(t+="e"),t},inputTooShort:function(e){var n=e.minimum-e.input.length,t="Prosim vpišite še "+n+" znak";return 2==n?t+="a":1!=n&&(t+="e"),t},loadingMore:function(){return"Nalagam več zadetkov…"},maximumSelected:function(e){var n="Označite lahko največ "+e.maximum+" predmet";return 2==e.maximum?n+="a":1!=e.maximum&&(n+="e"),n},noResults:function(){return"Ni zadetkov."},searching:function(){return"Iščem…"},removeAllItems:function(){return"Odstranite vse elemente"}}}),e.define,e.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/sq.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/sq",[],function(){return{errorLoading:function(){return"Rezultatet nuk mund të ngarkoheshin."},inputTooLong:function(e){var n=e.input.length-e.maximum,t="Të lutem fshi "+n+" karakter";return 1!=n&&(t+="e"),t},inputTooShort:function(e){return"Të lutem shkruaj "+(e.minimum-e.input.length)+" ose më shumë karaktere"},loadingMore:function(){return"Duke ngarkuar më shumë rezultate…"},maximumSelected:function(e){var n="Mund të zgjedhësh vetëm "+e.maximum+" element";return 1!=e.maximum&&(n+="e"),n},noResults:function(){return"Nuk u gjet asnjë rezultat"},searching:function(){return"Duke kërkuar…"},removeAllItems:function(){return"Hiq të gjitha sendet"}}}),e.define,e.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/sr-Cyrl.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/sr-Cyrl",[],function(){function n(n,e,r,u){return n%10==1&&n%100!=11?e:n%10>=2&&n%10<=4&&(n%100<12||n%100>14)?r:u}return{errorLoading:function(){return"Преузимање није успело."},inputTooLong:function(e){var r=e.input.length-e.maximum,u="Обришите "+r+" симбол";return u+=n(r,"","а","а")},inputTooShort:function(e){var r=e.minimum-e.input.length,u="Укуцајте бар још "+r+" симбол";return u+=n(r,"","а","а")},loadingMore:function(){return"Преузимање још резултата…"},maximumSelected:function(e){var r="Можете изабрати само "+e.maximum+" ставк";return r+=n(e.maximum,"у","е","и")},noResults:function(){return"Ништа није пронађено"},searching:function(){return"Претрага…"},removeAllItems:function(){return"Уклоните све ставке"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/sr.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/sr",[],function(){function n(n,e,r,t){return n%10==1&&n%100!=11?e:n%10>=2&&n%10<=4&&(n%100<12||n%100>14)?r:t}return{errorLoading:function(){return"Preuzimanje nije uspelo."},inputTooLong:function(e){var r=e.input.length-e.maximum,t="Obrišite "+r+" simbol";return t+=n(r,"","a","a")},inputTooShort:function(e){var r=e.minimum-e.input.length,t="Ukucajte bar još "+r+" simbol";return t+=n(r,"","a","a")},loadingMore:function(){return"Preuzimanje još rezultata…"},maximumSelected:function(e){var r="Možete izabrati samo "+e.maximum+" stavk";return r+=n(e.maximum,"u","e","i")},noResults:function(){return"Ništa nije pronađeno"},searching:function(){return"Pretraga…"},removeAllItems:function(){return"Уклоните све ставке"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/sv.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/sv",[],function(){return{errorLoading:function(){return"Resultat kunde inte laddas."},inputTooLong:function(n){return"Vänligen sudda ut "+(n.input.length-n.maximum)+" tecken"},inputTooShort:function(n){return"Vänligen skriv in "+(n.minimum-n.input.length)+" eller fler tecken"},loadingMore:function(){return"Laddar fler resultat…"},maximumSelected:function(n){return"Du kan max välja "+n.maximum+" element"},noResults:function(){return"Inga träffar"},searching:function(){return"Söker…"},removeAllItems:function(){return"Ta bort alla objekt"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/th.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/th",[],function(){return{errorLoading:function(){return"ไม่สามารถค้นข้อมูลได้"},inputTooLong:function(n){return"โปรดลบออก "+(n.input.length-n.maximum)+" ตัวอักษร"},inputTooShort:function(n){return"โปรดพิมพ์เพิ่มอีก "+(n.minimum-n.input.length)+" ตัวอักษร"},loadingMore:function(){return"กำลังค้นข้อมูลเพิ่ม…"},maximumSelected:function(n){return"คุณสามารถเลือกได้ไม่เกิน "+n.maximum+" รายการ"},noResults:function(){return"ไม่พบข้อมูล"},searching:function(){return"กำลังค้นข้อมูล…"},removeAllItems:function(){return"ลบรายการทั้งหมด"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/tk.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/tk",[],function(){return{errorLoading:function(){return"Netije ýüklenmedi."},inputTooLong:function(e){return e.input.length-e.maximum+" harp bozuň."},inputTooShort:function(e){return"Ýene-de iň az "+(e.minimum-e.input.length)+" harp ýazyň."},loadingMore:function(){return"Köpräk netije görkezilýär…"},maximumSelected:function(e){return"Diňe "+e.maximum+" sanysyny saýlaň."},noResults:function(){return"Netije tapylmady."},searching:function(){return"Gözlenýär…"},removeAllItems:function(){return"Remove all items"}}}),e.define,e.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/tr.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/tr",[],function(){return{errorLoading:function(){return"Sonuç yüklenemedi"},inputTooLong:function(n){return n.input.length-n.maximum+" karakter daha girmelisiniz"},inputTooShort:function(n){return"En az "+(n.minimum-n.input.length)+" karakter daha girmelisiniz"},loadingMore:function(){return"Daha fazla…"},maximumSelected:function(n){return"Sadece "+n.maximum+" seçim yapabilirsiniz"},noResults:function(){return"Sonuç bulunamadı"},searching:function(){return"Aranıyor…"},removeAllItems:function(){return"Tüm öğeleri kaldır"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/uk.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/uk",[],function(){function n(n,e,u,r){return n%100>10&&n%100<15?r:n%10==1?e:n%10>1&&n%10<5?u:r}return{errorLoading:function(){return"Неможливо завантажити результати"},inputTooLong:function(e){return"Будь ласка, видаліть "+(e.input.length-e.maximum)+" "+n(e.maximum,"літеру","літери","літер")},inputTooShort:function(n){return"Будь ласка, введіть "+(n.minimum-n.input.length)+" або більше літер"},loadingMore:function(){return"Завантаження інших результатів…"},maximumSelected:function(e){return"Ви можете вибрати лише "+e.maximum+" "+n(e.maximum,"пункт","пункти","пунктів")},noResults:function(){return"Нічого не знайдено"},searching:function(){return"Пошук…"},removeAllItems:function(){return"Видалити всі елементи"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/vi.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/vi",[],function(){return{inputTooLong:function(n){return"Vui lòng xóa bớt "+(n.input.length-n.maximum)+" ký tự"},inputTooShort:function(n){return"Vui lòng nhập thêm từ "+(n.minimum-n.input.length)+" ký tự trở lên"},loadingMore:function(){return"Đang lấy thêm kết quả…"},maximumSelected:function(n){return"Chỉ có thể chọn được "+n.maximum+" lựa chọn"},noResults:function(){return"Không tìm thấy kết quả"},searching:function(){return"Đang tìm…"},removeAllItems:function(){return"Xóa tất cả các mục"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/zh-CN.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/zh-CN",[],function(){return{errorLoading:function(){return"无法载入结果。"},inputTooLong:function(n){return"请删除"+(n.input.length-n.maximum)+"个字符"},inputTooShort:function(n){return"请再输入至少"+(n.minimum-n.input.length)+"个字符"},loadingMore:function(){return"载入更多结果…"},maximumSelected:function(n){return"最多只能选择"+n.maximum+"个项目"},noResults:function(){return"未找到结果"},searching:function(){return"搜索中…"},removeAllItems:function(){return"删除所有项目"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/select2/i18n/zh-TW.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/zh-TW",[],function(){return{inputTooLong:function(n){return"請刪掉"+(n.input.length-n.maximum)+"個字元"},inputTooShort:function(n){return"請再輸入"+(n.minimum-n.input.length)+"個字元"},loadingMore:function(){return"載入中…"},maximumSelected:function(n){return"你只能選擇最多"+n.maximum+"項"},noResults:function(){return"沒有找到相符的項目"},searching:function(){return"搜尋中…"},removeAllItems:function(){return"刪除所有項目"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /static/admin/js/vendor/xregexp/LICENSE.txt: -------------------------------------------------------------------------------- 1 | The MIT License 2 | 3 | Copyright (c) 2007-2017 Steven Levithan 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in 13 | all copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 21 | THE SOFTWARE. 22 | -------------------------------------------------------------------------------- /static/css/style.css: -------------------------------------------------------------------------------- 1 | /* Custom Stylesheet */ 2 | /** 3 | * Use this file to override Materialize files so you can update 4 | * the core Materialize files in the future 5 | * 6 | * Made By MaterializeCSS.com 7 | */ 8 | 9 | 10 | .icon-block { 11 | padding: 0 15px; 12 | } 13 | .icon-block .material-icons { 14 | font-size: inherit; 15 | } 16 | 17 | 18 | 19 | /* Blackwhite img hover */ 20 | /* 21 | .image-wrapper { 22 | background: white !important; 23 | } 24 | .image-wrapper img { 25 | mix-blend-mode: luminosity !important; 26 | } 27 | .image-wrapper img:hover { 28 | mix-blend-mode: normal !important; 29 | } */ 30 | 31 | 32 | /* scrollbar visible */ 33 | /* .scroll-item::-webkit-scrollbar { 34 | width: 10px; 35 | } 36 | .scroll-item::-webkit-scrollbar-thumb { 37 | background-color: #2f3542; 38 | border-radius: 10px; 39 | } 40 | .scroll-item::-webkit-scrollbar-track { 41 | background-color: grey; 42 | border-radius: 10px; 43 | box-shadow: inset 0px 0px 5px white; 44 | } */ 45 | 46 | /* invisivle scroll*/ 47 | .scroll-item{ 48 | -ms-overflow-style: none; 49 | } 50 | .scroll-item::-webkit-scrollbar{ 51 | display:none; 52 | } 53 | 54 | 55 | -------------------------------------------------------------------------------- /static/img/no_avatar.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/static/img/no_avatar.jpg -------------------------------------------------------------------------------- /static/img/no_banner.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/static/img/no_banner.jpg -------------------------------------------------------------------------------- /static/img/sample-1.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/static/img/sample-1.jpg -------------------------------------------------------------------------------- /static/img/sample-2.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/static/img/sample-2.jpg -------------------------------------------------------------------------------- /static/img/sample-3.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/static/img/sample-3.jpg -------------------------------------------------------------------------------- /static/img/sample-4.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/static/img/sample-4.jpg -------------------------------------------------------------------------------- /static/img/sample-5.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/static/img/sample-5.jpg -------------------------------------------------------------------------------- /static/img/sample-6.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/static/img/sample-6.jpg -------------------------------------------------------------------------------- /static/img/sample-7.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/static/img/sample-7.jpg -------------------------------------------------------------------------------- /static/img/sample-8.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jojo-tey/Django_fans/0fad58304cc56d33a0b41029b7c97fb0bebb92eb/static/img/sample-8.jpg -------------------------------------------------------------------------------- /static/js/init.js: -------------------------------------------------------------------------------- 1 | (function ($) { 2 | $(function () { 3 | 4 | $('.sidenav').sidenav(); 5 | $('.tabs').tabs(); 6 | $('.materialboxed').materialbox(); 7 | $('select').formSelect(); 8 | $('.slider').slider(); 9 | $('.tooltipped').tooltip(); 10 | $('.modal').modal(); 11 | 12 | $("addtolistform").submit(function () { 13 | $.ajax({ 14 | url: '/profile/addtolist', 15 | data: $("#addtolistform").serialize(), 16 | cache: false, 17 | type: "post", 18 | success: function (data) { 19 | console.log("Person added succesfully") 20 | } 21 | }); 22 | return false; 23 | }); 24 | 25 | }); // end of document ready 26 | })(jQuery); // end of jQuery name space 27 | -------------------------------------------------------------------------------- /static/js/loadmore.js: -------------------------------------------------------------------------------- 1 | (function ($) { 2 | 3 | $("#loadmorebtn").click(function () { 4 | var username = document.getElementsByName("to_user")[0].value; 5 | var directspage = document.getElementById('page_number'); 6 | var page_number = parseInt(directspage.value); 7 | 8 | $.ajax({ 9 | url: '/messages/loadmore/', 10 | data: { 11 | 'directspage': page_number, 12 | 'username': username, 13 | 'csrfmiddlewaretoken': window.CSRF_TOKEN 14 | }, 15 | cache: false, 16 | type: 'post', 17 | success: function (data) { 18 | if (data.empty == true) { 19 | $("#loadmorebtn").hide(); 20 | } else { 21 | $.each(data, function (i, v) { 22 | var ol_collection_html = '
  • ' + v.sender__first_name + ' ' + v.sender__last_name + '

    ' + v.body + '

    ' + v.date + '

  • '; 23 | $('#oldirects').append(ol_collection_html); 24 | }); 25 | } 26 | page_number = page_number + 1; 27 | $("#page_number").attr('value', page_number); 28 | 29 | } 30 | }); 31 | return false; 32 | }); 33 | // end of document ready 34 | }(jQuery)); // end of jQuery name space --------------------------------------------------------------------------------