text
stringlengths
0
1.05M
meta
dict
from django.views.generic import ListView from django.shortcuts import render, render_to_response, RequestContext from django.contrib.auth.decorators import login_required from django.http import HttpResponseRedirect, HttpResponse from django.contrib import auth from django.core.context_processors import csrf from djan...
{ "repo_name": "KBratland/django_final", "path": "person/views.py", "copies": "1", "size": "1451", "license": "apache-2.0", "hash": 1796261958804621800, "line_mean": 33.5476190476, "line_max": 239, "alpha_frac": 0.7263955892, "autogenerated": false, "ratio": 4.19364161849711, "config_test": fals...
from django.views.generic import ListView from django.template import RequestContext from django.template.loader import get_template from ..utils import JsonView from ..cms.models import Page from .models import Artwork, ArtworkType, Tag, TagArtwork class PaintingsView(ListView): context_object_name = 'artwork_l...
{ "repo_name": "rogerhil/flaviabernardes", "path": "flaviabernardes/flaviabernardes/artwork/views.py", "copies": "1", "size": "1826", "license": "apache-2.0", "hash": 2163653810262024200, "line_mean": 36.2653061224, "line_max": 73, "alpha_frac": 0.6084337349, "autogenerated": false, "ratio": 3.844...
from django.views.generic import ListView from django.views.generic.base import TemplateView from rest_framework.response import Response from rest_framework import generics, permissions from braces.views import (LoginRequiredMixin, PermissionRequiredMixin, GroupRequiredMixin, SetHeadlineMixin, AnonymousRequiredM...
{ "repo_name": "aronysidoro/django-payasyougo", "path": "payg/account/views.py", "copies": "1", "size": "3266", "license": "mit", "hash": -4377725865512077000, "line_mean": 30.4134615385, "line_max": 90, "alpha_frac": 0.6013472137, "autogenerated": false, "ratio": 4.2973684210526315, "config_tes...
from django.views.generic import ListView from django.views.generic.detail import DetailView from django.conf import settings from django.http import Http404 from .models import Interview, Product from .managers import published class InterviewDetailView(DetailView): def get_queryset(self): queryset = Int...
{ "repo_name": "jibaku/interviews", "path": "interviews/views.py", "copies": "1", "size": "3806", "license": "bsd-3-clause", "hash": 5745571867830001000, "line_mean": 36.6831683168, "line_max": 113, "alpha_frac": 0.6208617972, "autogenerated": false, "ratio": 4.132464712269273, "config_test": fa...
from django.views.generic import ListView from django.views.generic.detail import DetailView from django.views.generic.edit import CreateView from django.views.generic.edit import UpdateView from django.views.generic.edit import DeleteView from .mixins import LoginRequiredMixin from django.core.urlresolvers import reve...
{ "repo_name": "Jhonbeltran/information-layer8", "path": "events/views.py", "copies": "1", "size": "1127", "license": "mit", "hash": -858377877990100500, "line_mean": 33.1515151515, "line_max": 52, "alpha_frac": 0.7169476486, "autogenerated": false, "ratio": 4.068592057761733, "config_test": fal...
from django.views.generic import ListView from django.views.generic.detail import DetailView from taggit.models import Tag from .models import BaseEntryTranslation class ContentListView(ListView): context_object_name = 'contents' class ContentDetailView(DetailView): context_object_name = 'content' tem...
{ "repo_name": "esistgut/django-content-toolkit", "path": "content/views.py", "copies": "1", "size": "1303", "license": "mit", "hash": -1769026117263147000, "line_mean": 27.3260869565, "line_max": 80, "alpha_frac": 0.6462010744, "autogenerated": false, "ratio": 3.9604863221884496, "config_test":...
from django.views.generic import ListView from django.views.generic.edit import CreateView from django import forms from .models import Message, Room from django.shortcuts import get_object_or_404 from django.http.response import HttpResponse, HttpResponseRedirect from django.core import serializers from django.core.se...
{ "repo_name": "georgedorn/demo_chat", "path": "chat/views.py", "copies": "1", "size": "4025", "license": "mit", "hash": -1302352067700605200, "line_mean": 34.6283185841, "line_max": 103, "alpha_frac": 0.6310559006, "autogenerated": false, "ratio": 4.05337361530715, "config_test": false, "has_...
from django.views.generic import ListView from django.views.generic.edit import CreateView from django.views.generic.detail import DetailView from django.views.generic.dates import YearArchiveView, MonthArchiveView, DayArchiveView from django.contrib.contenttypes.models import ContentType from django.shortcuts import g...
{ "repo_name": "ateoto/django-words", "path": "words/views.py", "copies": "1", "size": "2087", "license": "mit", "hash": -1712216691060713200, "line_mean": 31.625, "line_max": 88, "alpha_frac": 0.7618591279, "autogenerated": false, "ratio": 3.235658914728682, "config_test": false, "has_no_keyw...
from django.views.generic import ListView from django.views.generic.edit import CreateView, UpdateView, DeleteView from django.core.urlresolvers import reverse_lazy from django.contrib.auth.decorators import permission_required, user_passes_test from django.utils.decorators import method_decorator from website.models i...
{ "repo_name": "solarpermit/solarpermit", "path": "website/views/news.py", "copies": "1", "size": "3626", "license": "bsd-3-clause", "hash": 5438347374263419000, "line_mean": 43.2195121951, "line_max": 84, "alpha_frac": 0.7071152785, "autogenerated": false, "ratio": 3.932754880694143, "config_te...
from django.views.generic import ListView from django.views.generic.edit import CreateView, UpdateView, DeleteView from django.views.generic.base import TemplateView from django.contrib.auth.mixins import (LoginRequiredMixin) from django.core.urlresolvers import reverse_lazy from django.http import Http404 import datet...
{ "repo_name": "ahmedetefy/AccountTracker", "path": "projects/AccountTracker/main/views.py", "copies": "1", "size": "3531", "license": "bsd-3-clause", "hash": 4863397118288791000, "line_mean": 30.8108108108, "line_max": 72, "alpha_frac": 0.6593033135, "autogenerated": false, "ratio": 4.25421686746...
from django.views.generic import ListView from django.views.generic.edit import CreateView, UpdateView from .models import Organisation class OrganisationMixin(object): model = Organisation context_object_name = 'organisation' class Index(OrganisationMixin, ListView): context_object_name = 'organisatio...
{ "repo_name": "UKTradeInvestment/crm-poc", "path": "crm-poc/apps/organisation/views.py", "copies": "1", "size": "1288", "license": "bsd-3-clause", "hash": 3343476341514994700, "line_mean": 25.2857142857, "line_max": 68, "alpha_frac": 0.6203416149, "autogenerated": false, "ratio": 3.65909090909090...
from django.views.generic import ListView from django.views.generic.edit import FormMixin from django.shortcuts import render from django.core.paginator import Paginator from .forms import UrlSearchForm from .models import LoggedUrl class UrlSearchView(FormMixin, ListView): model = LoggedUrl template_name = '...
{ "repo_name": "tykling/tykurllog", "path": "src/tykurllog/views.py", "copies": "1", "size": "2917", "license": "bsd-3-clause", "hash": -2285142356220946000, "line_mean": 42.5373134328, "line_max": 115, "alpha_frac": 0.5961604388, "autogenerated": false, "ratio": 4.366766467065868, "config_test"...
from django.views.generic import ListView from django.views.generic.edit import FormView, UpdateView, DeleteView from django.shortcuts import HttpResponseRedirect, get_object_or_404 from django.core.urlresolvers import reverse from guardian.mixins import LoginRequiredMixin from django.contrib.auth.decorators import log...
{ "repo_name": "DArtagan/thoth", "path": "accounts/views.py", "copies": "1", "size": "3487", "license": "mit", "hash": -5941014220947389000, "line_mean": 35.7052631579, "line_max": 82, "alpha_frac": 0.7011757958, "autogenerated": false, "ratio": 3.953514739229025, "config_test": false, "has_no...
from django.views.generic import ListView from django.views.generic.edit import FormView, UpdateView from django.shortcuts import HttpResponseRedirect, get_object_or_404 from django.core.urlresolvers import reverse from guardian.mixins import LoginRequiredMixin from django.contrib.auth.decorators import login_required ...
{ "repo_name": "DArtagan/teetimer", "path": "accounts/views.py", "copies": "1", "size": "1609", "license": "mit", "hash": 3349522389773108700, "line_mean": 30.5490196078, "line_max": 68, "alpha_frac": 0.734617775, "autogenerated": false, "ratio": 3.7331786542923435, "config_test": false, "has_...
from django.views.generic import ListView from haystack.query import SearchQuerySet from haystack.utils.geo import Point, D from ..models import Store from ..utils import caching_geo_lookup class DistanceSearchView(ListView): template_name = 'stores/store_search.html' distance = 25 def get_location(self...
{ "repo_name": "nikdoof/vapemap", "path": "app/stores/views/search.py", "copies": "1", "size": "1472", "license": "bsd-3-clause", "hash": 746737637923427300, "line_mean": 31.0217391304, "line_max": 72, "alpha_frac": 0.6195652174, "autogenerated": false, "ratio": 4.0550964187327825, "config_test"...
from django.views.generic import ListView from .models import Gallery class GalleryView(ListView): model = Gallery context_object_name = 'gallery' paginate_by = 8 template_name = 'gallery/gallery.html' class GalleryImageView(ListView): model = Gallery paginate_by = 16 template_name = 'ga...
{ "repo_name": "petquimica/sitepet", "path": "gallery/views.py", "copies": "2", "size": "1108", "license": "mpl-2.0", "hash": 6773015093099643000, "line_mean": 29.7777777778, "line_max": 71, "alpha_frac": 0.6353790614, "autogenerated": false, "ratio": 4.058608058608058, "config_test": false, "...
from django.views.generic import ListView from multigtfs.models import ( Block, Fare, FareRule, Feed, Frequency, Route, Service, ServiceDate, Shape, ShapePoint, Stop, StopTime, Trip) class ByFeedListView(ListView): by_col = 'feed_id' by_kwarg = 'feed_id' by_class = Feed by_classname = 'feed' ...
{ "repo_name": "CodeforHawaii/allb.us", "path": "allbus/exploreapp/views.py", "copies": "2", "size": "5714", "license": "bsd-3-clause", "hash": -2152639865885742300, "line_mean": 32.2209302326, "line_max": 79, "alpha_frac": 0.6498074904, "autogenerated": false, "ratio": 3.609602021478206, "confi...
from django.views.generic import ListView from opconsole.models import Timesheets, Device, Employes from django.db.models import Count, F, Q from django.db.models.functions import ExtractYear, ExtractDay, ExtractMonth from django.conf import settings from django.shortcuts import get_object_or_404 class AnomaliesView(L...
{ "repo_name": "baalkor/timetracking", "path": "opconsole/views/anonamliesView.py", "copies": "1", "size": "1379", "license": "apache-2.0", "hash": 2006093255883805000, "line_mean": 29.6444444444, "line_max": 92, "alpha_frac": 0.6359680928, "autogenerated": false, "ratio": 3.7371273712737128, "c...
from django.views.generic import ListView from oscar.core.loading import get_model from django import http from django.shortcuts import get_object_or_404 from oscar.apps.offer.models import ConditionalOffer, Range Product = get_model('catalogue', 'Product') class OfferListView(ListView): model = ConditionalOffe...
{ "repo_name": "MrReN/django-oscar", "path": "oscar/apps/offer/views.py", "copies": "1", "size": "1965", "license": "bsd-3-clause", "hash": -6242891857247192000, "line_mean": 30.6935483871, "line_max": 73, "alpha_frac": 0.6580152672, "autogenerated": false, "ratio": 3.914342629482072, "config_te...
from django.views.generic import ListView from simple_cms.contrib.utils import digg_paginator class DataGridView(ListView): sort_column = None sort_direction = 'asc' sort = None querystring = None headers = [] digg = True def get(self, request, *args, **kwargs): self.querystrin...
{ "repo_name": "3atmospheres/django-simple-cms", "path": "simple_cms/contrib/views.py", "copies": "2", "size": "3060", "license": "mit", "hash": 9099432722408448000, "line_mean": 38.7402597403, "line_max": 104, "alpha_frac": 0.5264705882, "autogenerated": false, "ratio": 4.4412191582002905, "con...
from django.views.generic import ListView from django.contrib.auth import get_user_model class UsersListView(ListView): model = get_user_model() template_name = "sample/users.html" # class ProfilePage(Page): # user_details = UserInfo() # tabs = TabCollection() # tabs2 = TabCollection() # # ...
{ "repo_name": "nanuxbe/toga_web", "path": "sample/views.py", "copies": "1", "size": "2143", "license": "mit", "hash": 2624224396167366000, "line_mean": 22.2934782609, "line_max": 70, "alpha_frac": 0.5254316379, "autogenerated": false, "ratio": 3.251896813353566, "config_test": false, "has_no_...
from django.views.generic import ListView from django.http import HttpResponse from .models import Job from geoq.maps.models import FeatureType from django.shortcuts import get_object_or_404 from datetime import datetime from pytz import timezone from webcolors import name_to_hex, normalize_hex from xml.sax.saxutils i...
{ "repo_name": "ngageoint/geoq", "path": "geoq/core/atom2_view.py", "copies": "1", "size": "17002", "license": "mit", "hash": -6148009798897243000, "line_mean": 43.3916449086, "line_max": 189, "alpha_frac": 0.5040583461, "autogenerated": false, "ratio": 3.334379290056874, "config_test": false, ...
from django.views.generic import ListView from django.http import HttpResponse from models import Job from geoq.maps.models import FeatureType from django.shortcuts import get_object_or_404 from datetime import datetime from pytz import timezone from webcolors import name_to_hex, normalize_hex from xml.sax.saxutils im...
{ "repo_name": "khazhyk/geoq", "path": "geoq/core/kml_view.py", "copies": "3", "size": "12539", "license": "mit", "hash": 5926779716379146000, "line_mean": 42.6898954704, "line_max": 187, "alpha_frac": 0.5151128479, "autogenerated": false, "ratio": 3.52615298087739, "config_test": false, "has_...
from django.views.generic import ListView from django.views.generic import CreateView from django.views.generic import UpdateView from django.views.generic import DetailView from django.views.generic import DeleteView from django.core.urlresolvers import reverse from contacts.models import Contact class ListContac...
{ "repo_name": "russomi/effective_django_tutorial", "path": "contacts/views.py", "copies": "1", "size": "1520", "license": "mit", "hash": 4897219120133387000, "line_mean": 25.6666666667, "line_max": 89, "alpha_frac": 0.6953947368, "autogenerated": false, "ratio": 4.086021505376344, "config_test"...
from django.views.generic import ListView from djofx import models from djofx.forms import CategoriseTransactionForm from djofx.views.base import PageTitleMixin, UserRequiredMixin class AccountTransactionsView(PageTitleMixin, UserRequiredMixin, ListView): model = models.Transaction paginate_by = 50 def ...
{ "repo_name": "dominicrodger/djofx", "path": "djofx/views/account.py", "copies": "1", "size": "1355", "license": "mit", "hash": -4750254321202615000, "line_mean": 27.829787234, "line_max": 77, "alpha_frac": 0.615498155, "autogenerated": false, "ratio": 3.9504373177842567, "config_test": false, ...
from django.views.generic import ListView from haystack.views import SearchView from source.articles.models import Article from source.articles.views import ArticleList from source.code.models import Code from source.people.models import Organization, Person class HomepageView(ArticleList): ''' Gets standard...
{ "repo_name": "ryanpitts/source", "path": "source/base/views.py", "copies": "1", "size": "2435", "license": "bsd-3-clause", "hash": 6449460592530749000, "line_mean": 30.2307692308, "line_max": 102, "alpha_frac": 0.5983572895, "autogenerated": false, "ratio": 4.6826923076923075, "config_test": f...
from django.views.generic import ListView import pymongo from nosqladmin.mixins import NosqlAdminViewMixin # TODO Move this to settings or something... # TODO Move this to settings or something... # TODO Move this to settings or something... from pymongo import Connection from pymongo.errors import CollectionInvalid...
{ "repo_name": "pydanny/django-nosqladmin", "path": "nosqladmin/views.py", "copies": "1", "size": "1180", "license": "mit", "hash": 7197400089001232000, "line_mean": 29.2820512821, "line_max": 88, "alpha_frac": 0.6923728814, "autogenerated": false, "ratio": 4.068965517241379, "config_test": fals...
from django.views.generic import ListView, RedirectView from django.views.generic.edit import FormView, UpdateView, DeletionMixin, CreateView from django.http import HttpResponseRedirect from django.shortcuts import render from django.template.loader import render_to_string from django.core.urlresolvers import reverse_...
{ "repo_name": "LucasCore/lucas", "path": "account/views.py", "copies": "2", "size": "7838", "license": "mit", "hash": 1203651136364529400, "line_mean": 30.9665271967, "line_max": 118, "alpha_frac": 0.6827225131, "autogenerated": false, "ratio": 3.6208530805687205, "config_test": false, "has_n...
from django.views.generic import ListView from django.shortcuts import render_to_response from django.template import RequestContext from cyndiloza.apps.news.models import Article, Publication, FavoriteList from cyndiloza.apps.about.models import About class HomeView(ListView): queryset = Article.object...
{ "repo_name": "richardcornish/cyndiloza", "path": "cyndiloza/views.py", "copies": "1", "size": "1390", "license": "bsd-3-clause", "hash": 6239676297065850000, "line_mean": 38.8823529412, "line_max": 97, "alpha_frac": 0.7028776978, "autogenerated": false, "ratio": 3.808219178082192, "config_test...
from django.views.generic import ListView from django.views.generic.detail import SingleObjectMixin from django.views.generic.base import View from django.shortcuts import render_to_response from django.template import RequestContext from braces.views import JSONResponseMixin, LoginRequiredMixin from ftp_deploy...
{ "repo_name": "lpakula/django-ftp-deploy", "path": "ftp_deploy/server/views/log.py", "copies": "1", "size": "1679", "license": "mit", "hash": -1535788233416921000, "line_mean": 32.9791666667, "line_max": 75, "alpha_frac": 0.6164383562, "autogenerated": false, "ratio": 4.261421319796955, "config...
from django.views.generic import ListView, TemplateView from .models import Host, Port, PortLog class IndexView(TemplateView): template_name = 'monitor/index.html' class HostListView(ListView): template_name = 'monitor/host_list.html' context_object_name = 'host_list' def get_queryset(self): ...
{ "repo_name": "diegogslomp/django-monitor", "path": "monitor/views.py", "copies": "2", "size": "1234", "license": "mit", "hash": 2277015696545407000, "line_mean": 23.68, "line_max": 76, "alpha_frac": 0.6401944895, "autogenerated": false, "ratio": 3.7737003058103977, "config_test": false, "has...
from django.views.generic import ListView, TemplateView, View from django.contrib.auth.models import Permission, ContentType from django.shortcuts import redirect from django.contrib.auth.mixins import LoginRequiredMixin from django.db.models import Q from permissions.forms import CreatePermissionForm from permissions....
{ "repo_name": "mingziV5/opsweb_test", "path": "permissions/views.py", "copies": "1", "size": "7358", "license": "apache-2.0", "hash": 7680837390503695000, "line_mean": 39.5875706215, "line_max": 140, "alpha_frac": 0.6152561247, "autogenerated": false, "ratio": 4.100456621004566, "config_test": ...
from django.views.generic import ListView, TemplateView, View from django.http import JsonResponse, QueryDict from .models import SqlWorkflow, MasterConfig, SqlWorkflowStatus from django.contrib.auth.models import Group from .form import AddSqlWorkflow, CheckWorkflow from opsweb.utils import GetLogger from inception im...
{ "repo_name": "mingziV5/opsweb_test", "path": "inception/views.py", "copies": "1", "size": "13128", "license": "apache-2.0", "hash": -6947271450198818000, "line_mean": 41.7128027682, "line_max": 176, "alpha_frac": 0.5803629294, "autogenerated": false, "ratio": 3.5624819624819626, "config_test":...
from django.views.generic import ListView, UpdateView, DeleteView, CreateView from django.core.urlresolvers import reverse_lazy from django.contrib import messages from braces.views import LoginRequiredMixin from ftp_deploy.models import Notification from ftp_deploy.server.forms import NotificationForm cl...
{ "repo_name": "lpakula/django-ftp-deploy", "path": "ftp_deploy/server/views/notification.py", "copies": "1", "size": "2332", "license": "mit", "hash": -3000779656425956400, "line_mean": 33.3333333333, "line_max": 78, "alpha_frac": 0.6689536878, "autogenerated": false, "ratio": 4.608695652173913, ...
from django.views.generic import ListView, View, FormView from django.template import RequestContext from django.template.loader import get_template from django import http class JsonView(View): """ By using this class, the methods json_get and json_post needs to be implemented. """ def get(self, req...
{ "repo_name": "rogerhil/oauau", "path": "src/oauau/utils.py", "copies": "1", "size": "1687", "license": "apache-2.0", "hash": -2472921916337799000, "line_mean": 32.0784313725, "line_max": 77, "alpha_frac": 0.6271487848, "autogenerated": false, "ratio": 4.055288461538462, "config_test": false, ...
from django.views.generic import ListView, View from django.shortcuts import render, redirect from django.contrib.auth.decorators import login_required from django.utils.decorators import method_decorator from discussion.functions import get_all_tags from schedule.models import Schedule from schedule import functions...
{ "repo_name": "BuildmLearn/University-Campus-Portal-UCP", "path": "UCP/schedule/views.py", "copies": "1", "size": "2752", "license": "bsd-3-clause", "hash": 1766839111019942700, "line_mean": 32.5731707317, "line_max": 89, "alpha_frac": 0.6231831395, "autogenerated": false, "ratio": 4.077037037037...
from django.views.generic import ListView,View,TemplateView from django.contrib.auth.models import Group, User, Permission, ContentType from django.http import JsonResponse from django.db import IntegrityError from django.http import QueryDict from django.shortcuts import redirect from opsweb.utils import GetLogg...
{ "repo_name": "mingziV5/opsweb_test", "path": "accounts/group/views.py", "copies": "1", "size": "8456", "license": "apache-2.0", "hash": 1507936046583210500, "line_mean": 37.8823529412, "line_max": 104, "alpha_frac": 0.543633235, "autogenerated": false, "ratio": 4.2375, "config_test": false, ...
from django.views.generic import ( DeleteView as DjangoDeleteView, TemplateView as DjangoTemplateView, ListView as DjangoListView, DetailView as DjangoDetailView, View as DjangoView, CreateView as DjangoCreateView, UpdateView as DjangoUpdateView, FormView as DjangoFormView, ) from djutil...
{ "repo_name": "telminov/ansible-manager", "path": "core/generic/views.py", "copies": "1", "size": "1605", "license": "mit", "hash": -5090511515036406000, "line_mean": 24.078125, "line_max": 94, "alpha_frac": 0.723364486, "autogenerated": false, "ratio": 3.8214285714285716, "config_test": false,...
from django.views.generic import ( DetailView, ListView, UpdateView, CreateView, TemplateView ) from django.core.urlresolvers import reverse from django.contrib.auth.decorators import login_required from django.utils import timezone from django.http import JsonResponse from djaxelrod import tasks fr...
{ "repo_name": "Axelrod-Python/DjAxelrod", "path": "core/views.py", "copies": "1", "size": "2024", "license": "mit", "hash": -2230163176794087400, "line_mean": 27.5070422535, "line_max": 73, "alpha_frac": 0.6936758893, "autogenerated": false, "ratio": 4.1138211382113825, "config_test": false, ...
from django.views.generic import ( FormView, CreateView, RedirectView, ) from django.contrib.auth import ( login, logout, ) from django.contrib.auth.mixins import LoginRequiredMixin from django.core.urlresolvers import reverse_lazy from django.http import HttpResponseRedirect from .models import ...
{ "repo_name": "citiufpe/citi-webplate", "path": "accounts/views.py", "copies": "1", "size": "1280", "license": "mit", "hash": -5414413712838924000, "line_mean": 26.8260869565, "line_max": 68, "alpha_frac": 0.6921875, "autogenerated": false, "ratio": 3.775811209439528, "config_test": false, "h...
from django.views.generic import * from django.contrib import messages from baseapp.forms import Pool_databaseform from schemes.forms import Student_schemesform from django.shortcuts import render from schemes.models import Student_schemes from students.models import School_child_count, Child_detail from django.db.mode...
{ "repo_name": "mravikumar281/staging-server", "path": "schemes/views.py", "copies": "2", "size": "11036", "license": "mit", "hash": -5171252376451615000, "line_mean": 55.306122449, "line_max": 341, "alpha_frac": 0.5870786517, "autogenerated": false, "ratio": 3.5889430894308942, "config_test": f...
from django.views.generic import * from django.core.urlresolvers import reverse from django.views.generic import ListView, DetailView from django.shortcuts import render from django.contrib.auth.decorators import login_required from social_auth import backends # from django.db.models import Q class FilteredListView(L...
{ "repo_name": "tnajdek/appengine-playground", "path": "blog/views.py", "copies": "1", "size": "2311", "license": "mit", "hash": 2567060487773735000, "line_mean": 31.0972222222, "line_max": 106, "alpha_frac": 0.7351795759, "autogenerated": false, "ratio": 3.359011627906977, "config_test": false,...
from django.views.generic import * from teachers.models import * from teachers.forms import * from django.shortcuts import * from baseapp.models import * from django.contrib import messages from django.db import * from datetime import datetime from django.views.generic import * from django.contrib.auth import authentic...
{ "repo_name": "tnemis/staging-server", "path": "teachers/views/teacher_leave_surrender_views.py", "copies": "2", "size": "9684", "license": "mit", "hash": 6343430090145764000, "line_mean": 46.9405940594, "line_max": 300, "alpha_frac": 0.5408921933, "autogenerated": false, "ratio": 4.0809102402022...
from django.views.generic import ( TemplateView, CreateView, DeleteView, RedirectView, UpdateView ) from django.core.urlresolvers import reverse from django.http.response import HttpResponseRedirect from django.db.models import Sum from django.shortcuts import get_object_or_404 from django.core.paginator import Pag...
{ "repo_name": "polarkac/TaskTracker", "path": "tasks/views.py", "copies": "1", "size": "8134", "license": "mit", "hash": 2772534189577334300, "line_mean": 30.6498054475, "line_max": 82, "alpha_frac": 0.6260142611, "autogenerated": false, "ratio": 3.8080524344569286, "config_test": false, "has...
from django.views.generic import RedirectView, CreateView from django.contrib.auth.mixins import LoginRequiredMixin from django.views.generic.list import ListView from django.urls import reverse_lazy from django.utils import timezone from .forms import NewPostForm from . import models class CreatePostView(LoginRequir...
{ "repo_name": "rodriguesrl/reddit-clone-udemy", "path": "posts/views.py", "copies": "1", "size": "1956", "license": "mit", "hash": -2795237594342766000, "line_mean": 31.6, "line_max": 93, "alpha_frac": 0.6513292434, "autogenerated": false, "ratio": 3.6088560885608856, "config_test": false, "h...
from django.views.generic import RedirectView from django.contrib.auth import authenticate, login from django.conf import settings from django.http import Http404 from .models import State from urllib import urlencode class LoginStageOneView(RedirectView): permanent = False def get_redirect_url(self, **kwa...
{ "repo_name": "siggame/siggame-vote", "path": "vote/accounts/views.py", "copies": "1", "size": "2014", "license": "bsd-3-clause", "hash": 4469679845866863000, "line_mean": 36.2962962963, "line_max": 78, "alpha_frac": 0.631082423, "autogenerated": false, "ratio": 4.378260869565217, "config_test"...
from django.views.generic import RedirectView from django.core.urlresolvers import reverse from django.views.static import serve from django.conf import settings from django.contrib.auth.decorators import login_required from functools import wraps from django.contrib.admin.forms import AdminAuthenticationForm from djan...
{ "repo_name": "svfat/django-docs", "path": "docs/views.py", "copies": "1", "size": "3031", "license": "bsd-3-clause", "hash": 5732771591417926000, "line_mean": 32.3076923077, "line_max": 210, "alpha_frac": 0.6819531508, "autogenerated": false, "ratio": 4.0092592592592595, "config_test": false, ...
from django.views.generic import RedirectView from ..main.views import DefaultCreate, TableView, DefaultUpdate from .tables_ajax import DutyTableJson, DocumentTableJson, DutyHistoryTableJson from ..team_mgt.models import Duty, Document, DutyHistory from .forms import DutyModelForm # TEAM MGT VIEW # ------------------...
{ "repo_name": "mpdevilleres/tbpc_app", "path": "tbpc/team_mgt/views.py", "copies": "1", "size": "1976", "license": "mit", "hash": 4328437199329068500, "line_mean": 24.3333333333, "line_max": 80, "alpha_frac": 0.588562753, "autogenerated": false, "ratio": 3.8, "config_test": false, "has_no_key...
from django.views.generic import RedirectView, View from django.core.urlresolvers import reverse from django.http import HttpResponseRedirect from django.contrib import messages from oscar_gocardless import facade from oscar.apps.payment.exceptions import PaymentError from oscar.apps.checkout.views import OrderPlaceme...
{ "repo_name": "django-oscar/django-oscar-gocardless", "path": "oscar_gocardless/views.py", "copies": "1", "size": "1811", "license": "bsd-3-clause", "hash": -4453595947023185000, "line_mean": 35.22, "line_max": 85, "alpha_frac": 0.6311430149, "autogenerated": false, "ratio": 4.460591133004926, ...
from django.views.generic import simple, list_detail from django.http import HttpResponse from garfield.models import ComicStrip def home(request): return simple.direct_to_template(request, 'home.html') def about_us(request): return simple.direct_to_template(request, 'about_us.html') def landing(request)...
{ "repo_name": "trapeze/transurlvania", "path": "tests/garfield/views.py", "copies": "1", "size": "1084", "license": "bsd-3-clause", "hash": 5034714502554745000, "line_mean": 25.4390243902, "line_max": 79, "alpha_frac": 0.6881918819, "autogenerated": false, "ratio": 3.601328903654485, "config_te...
from django.views.generic import TemplateView, CreateView, ListView, UpdateView from django.urls import reverse_lazy from django import forms from django.forms.models import modelform_factory from django.shortcuts import render from django.contrib.auth import login, authenticate from django.contrib.auth.mixins import ...
{ "repo_name": "dvcolgan/tomatoestogether", "path": "core/views.py", "copies": "1", "size": "3945", "license": "mit", "hash": 319583534761833860, "line_mean": 23.3518518519, "line_max": 92, "alpha_frac": 0.5944233207, "autogenerated": false, "ratio": 3.8905325443786984, "config_test": false, "...
from django.views.generic import TemplateView, CreateView from django.views.decorators.http import require_http_methods from django.shortcuts import redirect from django.utils import timezone from django.contrib.auth.models import AnonymousUser from django.db.models import Q from django.http import HttpResponseForbidde...
{ "repo_name": "Flowneee/django-e-referendum", "path": "project/referendums/views.py", "copies": "1", "size": "7525", "license": "mit", "hash": -838019756951877100, "line_mean": 32.1769911504, "line_max": 78, "alpha_frac": 0.6224326487, "autogenerated": false, "ratio": 3.572177227251072, "config...
from django.views.generic import TemplateView, CreateView from django.contrib.auth.models import User from django.contrib.auth.forms import UserCreationForm from django.http import HttpResponseRedirect from django.contrib.auth import authenticate, login, logout from django.shortcuts import redirect class Inde...
{ "repo_name": "apy2017/Anaconda", "path": "techbot_web/techbot_web/views.py", "copies": "1", "size": "1133", "license": "mit", "hash": 6455894109028641000, "line_mean": 26.325, "line_max": 65, "alpha_frac": 0.6866725508, "autogenerated": false, "ratio": 4.275471698113208, "config_test": false, ...
from django.views.generic import TemplateView, CreateView, UpdateView from .models import Doctor from django.http import HttpResponseRedirect from .forms import RegistrationForm from django.contrib.auth.models import User from django.shortcuts import render_to_response from django.template import RequestContext from ...
{ "repo_name": "razzius/outpatient", "path": "outpatient/app/views.py", "copies": "1", "size": "1250", "license": "mit", "hash": -8425777956524845000, "line_mean": 30.25, "line_max": 82, "alpha_frac": 0.7608, "autogenerated": false, "ratio": 3.3692722371967654, "config_test": false, "has_no_ke...
from django.views.generic import TemplateView, DeleteView, CreateView from django.http import HttpResponse, HttpResponseRedirect from django.utils import simplejson as json from django.core.urlresolvers import reverse from django.contrib import messages from django.contrib.auth.models import User from django.contrib.a...
{ "repo_name": "nikdoof/test-auth", "path": "app/reddit/views.py", "copies": "1", "size": "3355", "license": "bsd-3-clause", "hash": 4766803734369269000, "line_mean": 32.8888888889, "line_max": 121, "alpha_frac": 0.6602086438, "autogenerated": false, "ratio": 4.188514357053683, "config_test": fa...
from django.views.generic import TemplateView, DeleteView, FormView, View from django.shortcuts import render from .models import Question, AnswerInstance, AnswerOption,\ ClosedEndedQuestion, Answer from core.models import Lecture from django.shortcuts import get_object_or_404 from braces.views import LoginRequiredMix...
{ "repo_name": "thebenwaters/openclickio", "path": "qa/views.py", "copies": "1", "size": "7112", "license": "mit", "hash": 4972938766584744000, "line_mean": 38.0824175824, "line_max": 150, "alpha_frac": 0.7452193476, "autogenerated": false, "ratio": 3.467576791808874, "config_test": false, "ha...
from django.views.generic import TemplateView, DetailView, FormView from django.http import HttpResponse from django.utils.translation import ugettext as _ from openbudget.apps.pages.models import Page from openbudget.apps.pages.forms import ContactForm from openbudget.commons.mixins.views import JSONResponseMixin cl...
{ "repo_name": "zbyufei/open-budgets", "path": "openbudget/apps/pages/views.py", "copies": "2", "size": "2068", "license": "bsd-3-clause", "hash": -5689047005620657000, "line_mean": 25.5128205128, "line_max": 78, "alpha_frac": 0.6097678917, "autogenerated": false, "ratio": 4.127744510978044, "co...
from django.views.generic import TemplateView, DetailView, FormView from django.http import HttpResponse from django.utils.translation import ugettext as _ from openbudgets.apps.pages.models import Page from openbudgets.apps.pages.forms import ContactForm from openbudgets.commons.mixins.views import JSONResponseMixin ...
{ "repo_name": "shaib/openbudgets", "path": "openbudgets/apps/pages/views.py", "copies": "3", "size": "2025", "license": "bsd-3-clause", "hash": -1977749914339278300, "line_mean": 26, "line_max": 78, "alpha_frac": 0.6241975309, "autogenerated": false, "ratio": 4.05811623246493, "config_test": fa...
from django.views.generic import TemplateView, DetailView, FormView from django.http import HttpResponse from django.utils.translation import ugettext_lazy as _ from openbudgets.apps.pages.models import Page from openbudgets.apps.pages.forms import ContactForm from openbudgets.commons.mixins.views import JSONResponseMi...
{ "repo_name": "openbudgets/openbudgets", "path": "openbudgets/apps/pages/views.py", "copies": "2", "size": "2030", "license": "bsd-3-clause", "hash": -3873488535161334000, "line_mean": 26.0666666667, "line_max": 78, "alpha_frac": 0.6246305419, "autogenerated": false, "ratio": 4.05189620758483, ...
from django.views.generic import TemplateView, DetailView, ListView from django.conf import settings from django.http import HttpResponse from django_remote_submission.models import Interpreter, Server, Job, Log from django_remote_submission.tasks import submit_job_to_server from django.contrib.auth.mixins import Logi...
{ "repo_name": "ornl-ndav/django-remote-submission", "path": "example/server/views.py", "copies": "1", "size": "2987", "license": "isc", "hash": 3633712017437782000, "line_mean": 29.793814433, "line_max": 90, "alpha_frac": 0.6427854034, "autogenerated": false, "ratio": 4.0861833105335155, "confi...
from django.views.generic import TemplateView, DetailView, ListView from django.views.generic.edit import (FormView, CreateView, UpdateView) from django.contrib.auth.mixins import LoginRequiredMixin from django.core.urlresolvers import reverse_lazy from django.db import transaction from django.utils.translation import ...
{ "repo_name": "art-solopov/mdwiki", "path": "wiki/views.py", "copies": "1", "size": "4254", "license": "mit", "hash": 9160487973184374000, "line_mean": 33.3064516129, "line_max": 92, "alpha_frac": 0.6090738129, "autogenerated": false, "ratio": 4.166503428011753, "config_test": false, "has_no_...
from django.views.generic import TemplateView, DetailView from django.views.generic.edit import CreateView, UpdateView from django.urls import reverse from imager_images.forms import (PhotoUploadForm, PhotoEditForm, NewAlbumForm ...
{ "repo_name": "ilikesounds/django-imager", "path": "imager_images/views.py", "copies": "1", "size": "3469", "license": "mit", "hash": 1770493816083185200, "line_mean": 32.0380952381, "line_max": 73, "alpha_frac": 0.6388008071, "autogenerated": false, "ratio": 4.115065243179123, "config_test": f...
from django.views.generic import TemplateView, DetailView from skd_tools.mixins import ActiveTabMixin from cathedra.models import Lector, Aspirant, Technician class LectorsListView(ActiveTabMixin, TemplateView): template_name = 'cathedra/lector_list.html' active_tab = 'academics' def get_context_data(s...
{ "repo_name": "Axik/eapu", "path": "apps/cathedra/views.py", "copies": "1", "size": "1106", "license": "mit", "hash": -892398147045594100, "line_mean": 25.9756097561, "line_max": 73, "alpha_frac": 0.7350813743, "autogenerated": false, "ratio": 3.311377245508982, "config_test": false, "has_no_...
from django.views.generic import TemplateView, FormView from django.contrib.messages import add_message from django.contrib.auth import login from django.contrib.auth.forms import AuthenticationForm from django.http import HttpResponse from stored_messages import broadcast_message import stored_messages class Index...
{ "repo_name": "masci/notification_example", "path": "notification/views.py", "copies": "1", "size": "1268", "license": "unlicense", "hash": -4241196864308640300, "line_mean": 32.3684210526, "line_max": 117, "alpha_frac": 0.7097791798, "autogenerated": false, "ratio": 3.9874213836477987, "config...
from django.views.generic import TemplateView, FormView from django.http import Http404 from .forms import preference_form_builder """Todo : remove these views and use only context processors""" class RegularTemplateView(TemplateView): """Used for testing context""" template_name = "dynamic_preferences/testco...
{ "repo_name": "haroon-sheikh/django-dynamic-preferences", "path": "dynamic_preferences/views.py", "copies": "2", "size": "1860", "license": "bsd-3-clause", "hash": 3507023548419825700, "line_mean": 30.5254237288, "line_max": 79, "alpha_frac": 0.6505376344, "autogenerated": false, "ratio": 4.22727...
from django.views.generic import TemplateView, FormView from .forms import preference_form_builder, user_preference_form_builder from . import user_preferences_registry """Todo : remove these views and use only context processors""" class RegularTemplateView(TemplateView): """Used for testing context""" templ...
{ "repo_name": "willseward/django-dynamic-preferences", "path": "dynamic_preferences/views.py", "copies": "2", "size": "1794", "license": "bsd-3-clause", "hash": -9048152320320684000, "line_mean": 31.6181818182, "line_max": 94, "alpha_frac": 0.6973244147, "autogenerated": false, "ratio": 4.0772727...
from django.views.generic import TemplateView, FormView from .readopensecrets import read_contributions, read_contibutors from .readpolitifact import read_recent_statements from .fivethirtyeight import getPollNum from django.http.response import HttpResponseRedirect from django.shortcuts import reverse from .forms impo...
{ "repo_name": "mac-chaffee/candidata", "path": "candidata/candidata/views.py", "copies": "1", "size": "1915", "license": "mit", "hash": -1112917564338833200, "line_mean": 38.0816326531, "line_max": 75, "alpha_frac": 0.6496083551, "autogenerated": false, "ratio": 3.5996240601503757, "config_test...
from django.views.generic import TemplateView, FormView from .readopensecrets import read_contributions, read_contributors from .readpolitifact import read_recent_statements, read_recent_statements_front from .fivethirtyeight import getPollNum from django.http.response import HttpResponseRedirect from django.shortcuts ...
{ "repo_name": "mac-chaffee/candidata", "path": "candidata/views.py", "copies": "1", "size": "2249", "license": "mit", "hash": -692389095507069600, "line_mean": 40.6481481481, "line_max": 82, "alpha_frac": 0.6500666963, "autogenerated": false, "ratio": 3.6215780998389695, "config_test": false, ...
from django.views.generic import TemplateView, FormView, RedirectView from django.urls import reverse_lazy from django.contrib.auth.models import User from django.contrib.sites.shortcuts import get_current_site from django.utils import timezone from django.utils.crypto import get_random_string from datetime import time...
{ "repo_name": "Nuurek/HomeLibrary", "path": "accounts/views.py", "copies": "1", "size": "2065", "license": "mit", "hash": 505879557926619500, "line_mean": 35.2280701754, "line_max": 97, "alpha_frac": 0.6556900726, "autogenerated": false, "ratio": 4.27536231884058, "config_test": false, "has_n...
from django.views.generic import TemplateView, ListView, CreateView, DetailView from django.views.generic.detail import BaseDetailView from models import Company, Venue, Booking, Location, Event, Menu, Product, Category, OpeningTime from forms import VenueForm from simple_rest.auth.decorators import login_required, ad...
{ "repo_name": "Strangemother/coffee", "path": "reserved/views.py", "copies": "1", "size": "5989", "license": "mit", "hash": -3664463568504325000, "line_mean": 26.3470319635, "line_max": 98, "alpha_frac": 0.6431791618, "autogenerated": false, "ratio": 3.8001269035532994, "config_test": false, ...
from django.views.generic import TemplateView, ListView, CreateView, DetailView from models import Company, Venue, Booking, Location, Event from forms import VenueForm from simple_rest.auth.decorators import login_required, admin_required from django.http import HttpResponse from django.core import serializers #from j...
{ "repo_name": "hellsgate1001/bookit", "path": "reserved/views.py", "copies": "1", "size": "2539", "license": "mit", "hash": 2995580453545894000, "line_mean": 26.597826087, "line_max": 98, "alpha_frac": 0.6675856636, "autogenerated": false, "ratio": 3.795216741405082, "config_test": false, "ha...
from django.views.generic import TemplateView, ListView, CreateView from django.conf import settings from django.db.models import Max from django.shortcuts import get_object_or_404 from braces.views import LoginRequiredMixin import requests import pprint import re import datetime from dateutil import parser from .mod...
{ "repo_name": "cod3monk/django-ciscoprime", "path": "ciscoprime/main/views.py", "copies": "1", "size": "9115", "license": "bsd-3-clause", "hash": 2019410825263692500, "line_mean": 43.9014778325, "line_max": 227, "alpha_frac": 0.5729018102, "autogenerated": false, "ratio": 3.780588967233513, "co...
from django.views.generic import TemplateView, ListView, DetailView, CreateView from .forms import ThreadCreateUpdateForm, ThreadReplyForm from .mixins import DetailWithListMixin, RequestForFormMixIn from .models import ForumPost, ForumThread, ForumCategory class ForumHome(ListView): model = ForumCategory d...
{ "repo_name": "hellsgate1001/thatforum_django", "path": "thatforum/views.py", "copies": "1", "size": "3749", "license": "mit", "hash": 2632794237722753000, "line_mean": 33.712962963, "line_max": 88, "alpha_frac": 0.6577754068, "autogenerated": false, "ratio": 3.779233870967742, "config_test": f...
from django.views.generic import TemplateView, ListView, DetailView, FormView from imager_images.models import Photos, Album, Face from .models import ImagerProfile from .forms import ProfileSettingsForm from django.http import HttpResponse def get_faces(photo): import Algorithmia import base64 Algorithmi...
{ "repo_name": "MigrantJ/django-imager", "path": "imagersite/imager_profile/views.py", "copies": "2", "size": "4638", "license": "mit", "hash": 1160762822395068400, "line_mean": 26.7724550898, "line_max": 77, "alpha_frac": 0.5968089694, "autogenerated": false, "ratio": 3.770731707317073, "config...
from django.views.generic import TemplateView, ListView, DetailView from braces.views import UserPassesTestMixin from token_auth.views import BaseAuthView from .models import Organisation from questions.forms import QuestionForm class OrganisationAuthenticateView(BaseAuthView): def get_redirect_url(self, *args, **...
{ "repo_name": "DemocracyClub/candidate_questions", "path": "q_and_a/apps/organisations/views.py", "copies": "1", "size": "1072", "license": "bsd-3-clause", "hash": 2428605470520029000, "line_mean": 35.9655172414, "line_max": 80, "alpha_frac": 0.7350746269, "autogenerated": false, "ratio": 4.1875,...
from django.views.generic import TemplateView, ListView, DetailView from django.core.mail import send_mail, BadHeaderError from django.http import HttpResponse, HttpResponseRedirect from eventex.core.models import Speaker, Talk, Course home = ListView.as_view(template_name='index.html', model=Speaker) speaker_detail...
{ "repo_name": "rg3915/wttd2", "path": "eventex/core/views.py", "copies": "1", "size": "2942", "license": "mit", "hash": 3428340941877281000, "line_mean": 47.0163934426, "line_max": 135, "alpha_frac": 0.5988391943, "autogenerated": false, "ratio": 3.6385093167701865, "config_test": false, "has...
from django.views.generic import TemplateView, ListView, DetailView from django.http import Http404 from sys import stderr from wquests import common_functions from wqengine.models import WebQuest, WebQuestVersion, WebQuestVersionSection class IndexView(TemplateView): template_name = 'public/index.html' def g...
{ "repo_name": "priakni/wquests", "path": "wquests/public/views.py", "copies": "1", "size": "4603", "license": "mit", "hash": -6542629028388612000, "line_mean": 53.8095238095, "line_max": 149, "alpha_frac": 0.6791223115, "autogenerated": false, "ratio": 3.627265563435776, "config_test": false, ...
from django.views.generic import (TemplateView, ListView, DetailView, View, CreateView, UpdateView, DeleteView) from django.core.exceptions import PermissionDenied class HelpDeskView(View): """ An abstraction of the basic view """ class HelpDeskTemplateView(TemplateView): """ As defined by ht...
{ "repo_name": "vladyslav2/django-helpdesk", "path": "helpdesk/views/base.py", "copies": "1", "size": "2397", "license": "bsd-3-clause", "hash": 3583196219010365000, "line_mean": 28.9625, "line_max": 136, "alpha_frac": 0.6800166875, "autogenerated": false, "ratio": 4.118556701030927, "config_tes...
from django.views.generic import TemplateView, ListView, FormView from django.core.urlresolvers import reverse_lazy from django.contrib import messages from content.models import Genres, Galleries from content.forms import FeedBackForm class IndexView(TemplateView): """ simple template for index page """ t...
{ "repo_name": "Samael500/helena", "path": "helena/content/views.py", "copies": "1", "size": "1029", "license": "unlicense", "hash": 7062552855713598000, "line_mean": 21.7045454545, "line_max": 96, "alpha_frac": 0.6986986987, "autogenerated": false, "ratio": 3.5551601423487544, "config_test": fa...
from django.views.generic import TemplateView, ListView #from django.views.generic.base import TemplateView from django.shortcuts import get_object_or_404 from django.http import HttpResponseRedirect from django.core.urlresolvers import reverse, reverse_lazy from django.core.mail import send_mail from django.core.excep...
{ "repo_name": "kevincwebb/conceptum", "path": "conceptum/custom_auth/views.py", "copies": "1", "size": "4206", "license": "bsd-3-clause", "hash": 8011674245087202000, "line_mean": 34.3445378151, "line_max": 88, "alpha_frac": 0.6752258678, "autogenerated": false, "ratio": 4.099415204678363, "con...
from django.views.generic import TemplateView,ListView from .models import Libro from apps.autores.models import Autor from django.shortcuts import render class BuscarView(TemplateView): def post(self, request, *args, **kwargs): buscar = request.POST['buscalo'] libros = Libro.objects.filter(nombre__contains=busca...
{ "repo_name": "richpolis/siveinpy", "path": "SiveinPy/apps/libros/views.py", "copies": "1", "size": "1172", "license": "mit", "hash": 6444593917034416000, "line_mean": 29.0769230769, "line_max": 58, "alpha_frac": 0.7252559727, "autogenerated": false, "ratio": 3.0923482849604222, "config_test": ...
from django.views.generic import TemplateView, ListView, View from django.shortcuts import redirect, reverse from django.http import JsonResponse from resources.idc.models import Idc from django.http import QueryDict from django.contrib.auth.mixins import LoginRequiredMixin from permissions.mixins import MyPermis...
{ "repo_name": "mingziV5/opsweb_test", "path": "resources/idc/views.py", "copies": "1", "size": "9713", "license": "apache-2.0", "hash": 8247357679257317000, "line_mean": 35.988, "line_max": 124, "alpha_frac": 0.5257449721, "autogenerated": false, "ratio": 3.9341342170671085, "config_test": fals...
from django.views.generic import TemplateView from allauth.account.decorators import verified_email_required from django.utils.decorators import method_decorator from django.contrib import messages from django.http import HttpResponseRedirect, HttpResponse from django.core.urlresolvers import reverse_lazy from django_d...
{ "repo_name": "marcin-pwr/isrp", "path": "isrp_app/views.py", "copies": "1", "size": "18506", "license": "mit", "hash": -4977925788370045000, "line_mean": 46.3666666667, "line_max": 197, "alpha_frac": 0.5429004493, "autogenerated": false, "ratio": 3.7777096114519426, "config_test": false, "ha...
from django.views.generic import TemplateView #from apiclient.discovery import build from googleapiclient.discovery import build from .utils import SearchResults from . import * class SearchView(TemplateView): template_name = "googlesearch/search_results.html" def get_context_data(self, **kwargs): c...
{ "repo_name": "hzdg/django-google-search", "path": "googlesearch/views.py", "copies": "1", "size": "2809", "license": "mit", "hash": 5372204719419525000, "line_mean": 30.9204545455, "line_max": 104, "alpha_frac": 0.5514417942, "autogenerated": false, "ratio": 4.230421686746988, "config_test": f...
from django.views.generic import TemplateView from challenge_framework.mixins import ChallengeAdmin, CustomAdminSideBar from challenge_framework.configs.urls import admin_configs, challenge_admin, group_under from .models import ChallengeScore class BaseViewMixin(CustomAdminSideBar): @property def side_bar_li...
{ "repo_name": "jonatanSh/challenge-framework", "path": "challenge_framework/challenge_admin/views.py", "copies": "1", "size": "2353", "license": "apache-2.0", "hash": -571831449415551040, "line_mean": 34.6515151515, "line_max": 105, "alpha_frac": 0.5788355291, "autogenerated": false, "ratio": 4.0...
from django.views.generic import TemplateView from crm.contract.models import Contract from crm.contract.models import Addendum class AddendumPrintView(TemplateView): template_name = "contract/agreement_2013-2014.html" def get_context_data(self, user_id, **kwargs): return { "contract": Ad...
{ "repo_name": "MattAgile/django-spa-crm", "path": "crm/contract/views.py", "copies": "1", "size": "1085", "license": "apache-2.0", "hash": 6753642997689432000, "line_mean": 30, "line_max": 73, "alpha_frac": 0.664516129, "autogenerated": false, "ratio": 3.6904761904761907, "config_test": false, ...
from django.views.generic import TemplateView from datawarehouse.mixins import JSONMixin from django.http import Http404, HttpResponse from data_services.adapters import EMOD_Adapter from data_services.models import DimLocation, DimRun import json class GeoJsonView(JSONMixin, TemplateView): """ This class is ...
{ "repo_name": "tph-thuering/vnetsource", "path": "data_services/views/geojson.py", "copies": "2", "size": "1554", "license": "mpl-2.0", "hash": 8548177333990384000, "line_mean": 42.1944444444, "line_max": 117, "alpha_frac": 0.6698841699, "autogenerated": false, "ratio": 4.046875, "config_test":...
from django.views.generic import TemplateView from django.conf import settings from .forms import DemoForm class Index(TemplateView): template_name = 'demo/index.html' class DemoBase(TemplateView): form_class = DemoForm form_1 = None form_2 = None form_3 = None def get(self, request, *args,...
{ "repo_name": "djk2/django-popup-view-field", "path": "demo/demo/views.py", "copies": "1", "size": "2271", "license": "mit", "hash": -4397171008244415500, "line_mean": 35.0476190476, "line_max": 73, "alpha_frac": 0.6468516072, "autogenerated": false, "ratio": 3.384500745156483, "config_test": f...
from django.views.generic import TemplateView from django.conf import settings from molo.profiles.views import RegistrationView, ProfilePasswordChangeView from forms import FBRegistrationForm, ProfilePasswordChangeForm class HomeView(TemplateView): template_name = 'home.html' def get_context_data(self, *ar...
{ "repo_name": "praekelt/molo-freebasics", "path": "freebasics/views.py", "copies": "1", "size": "1346", "license": "bsd-2-clause", "hash": 6368285240527208000, "line_mean": 36.3888888889, "line_max": 75, "alpha_frac": 0.6849925706, "autogenerated": false, "ratio": 4.005952380952381, "config_tes...
from django.views.generic import TemplateView from django.conf.urls import url from .views import RegisterView, VerifyEmailView from django.contrib.sites.shortcuts import get_current_site from django.views.generic.base import RedirectView class ConfirmEmailRedirectView(RedirectView): permanent = False def ge...
{ "repo_name": "kdzch/django-rest-auth", "path": "rest_auth/registration/urls.py", "copies": "1", "size": "1479", "license": "mit", "hash": 7190525810550885000, "line_mean": 45.21875, "line_max": 119, "alpha_frac": 0.7153482082, "autogenerated": false, "ratio": 3.7443037974683544, "config_test":...
from django.views.generic import TemplateView from django.contrib.auth import logout, get_user_model from django.utils.decorators import method_decorator from django.views.decorators.csrf import ensure_csrf_cookie from rest_framework import generics, status from rest_framework.permissions import IsAuthenticated from re...
{ "repo_name": "st4lk/django-rest-social-auth", "path": "example_project/users/views.py", "copies": "1", "size": "1809", "license": "mit", "hash": 8903604464322246000, "line_mean": 27.7142857143, "line_max": 84, "alpha_frac": 0.7777777778, "autogenerated": false, "ratio": 3.984581497797357, "con...
from django.views.generic import TemplateView from django.contrib.auth.mixins import LoginRequiredMixin from django.urls import reverse_lazy from django.db.models import Sum from accounts.models import UserProfile from libraries.models import BookCopy, Reading class HomeView(TemplateView): template_name = 'home....
{ "repo_name": "Nuurek/HomeLibrary", "path": "home_library/views.py", "copies": "1", "size": "1591", "license": "mit", "hash": 608738368276652500, "line_mean": 37.8048780488, "line_max": 101, "alpha_frac": 0.6882463859, "autogenerated": false, "ratio": 3.7971360381861574, "config_test": false, ...
from django.views.generic import TemplateView from django.contrib.auth.models import User, Group from rest_framework import viewsets, generics from rest_framework_json_api.renderers import JsonApiRenderer from rest_framework.decorators import api_view from rest_framework.response import Response from rest_framework imp...
{ "repo_name": "christabor/MoAL", "path": "MOAL/systems_engineering/architecture/restful/restclient/quickstart/views.py", "copies": "1", "size": "1672", "license": "apache-2.0", "hash": -7385609600474136000, "line_mean": 32.44, "line_max": 66, "alpha_frac": 0.7589712919, "autogenerated": false, "r...
from django.views.generic import TemplateView from django.contrib.sites.shortcuts import get_current_site from django.contrib import messages from braces.views import LoginRequiredMixin from rest_framework.views import APIView from rest_framework.response import Response from rest_framework.permissions import BasePer...
{ "repo_name": "nagyistoce/geokey", "path": "geokey/superusertools/views.py", "copies": "1", "size": "6367", "license": "apache-2.0", "hash": 1642987894091186700, "line_mean": 25.9788135593, "line_max": 79, "alpha_frac": 0.5534788755, "autogenerated": false, "ratio": 4.989811912225705, "config_t...
from django.views.generic import TemplateView from django.core.exceptions import ObjectDoesNotExist, PermissionDenied from data_services.models import DimUser from ts_emod2.models import Scenario import json class DetailsView(TemplateView): template_name = 'ts_emod2/details/details.html' def get_context_da...
{ "repo_name": "vecnet/vnetsource", "path": "ts_emod2/views/DetailsView.py", "copies": "2", "size": "6650", "license": "mpl-2.0", "hash": -8329639117139857000, "line_mean": 45.838028169, "line_max": 118, "alpha_frac": 0.5351879699, "autogenerated": false, "ratio": 4.169278996865204, "config_test...
from django.views.generic import TemplateView from django.core.paginator import InvalidPage from django.contrib import messages from django.conf import settings from django.utils.translation import ugettext_lazy as _ from django.shortcuts import get_object_or_404, redirect from oscar.core.loading import get_class, get...
{ "repo_name": "byte-up/custom-filter-django-oscar", "path": "shop/catalogue/views.py", "copies": "1", "size": "1698", "license": "mit", "hash": -3275400830567332400, "line_mean": 37.6136363636, "line_max": 78, "alpha_frac": 0.6607773852, "autogenerated": false, "ratio": 3.807174887892377, "conf...
from django.views.generic import TemplateView from django.core.paginator import Paginator, EmptyPage, PageNotAnInteger from django import http from django.conf import settings from core import ContentBrowser, cbregistry class BrowserItemsView(TemplateView): template_name = 'contentbrowser/browser_items.html' ...
{ "repo_name": "andrewebdev/django-contentbrowser", "path": "src/contentbrowser/views.py", "copies": "1", "size": "1944", "license": "mit", "hash": 2512651833394466000, "line_mean": 29.8571428571, "line_max": 77, "alpha_frac": 0.5961934156, "autogenerated": false, "ratio": 4.092631578947368, "co...
from django.views.generic import TemplateView from django.core.paginator import Paginator, EmptyPage, PageNotAnInteger from data_services.models import DimUser from ts_repr.models import RepresentativeScenario class BrowseScenarioView(TemplateView): template_name = 'ts_repr/browse_scenario.html' def get_co...
{ "repo_name": "vecnet/vnetsource", "path": "ts_repr/views/BrowseScenarioView.py", "copies": "2", "size": "2883", "license": "mpl-2.0", "hash": 6303498303892470000, "line_mean": 40.7971014493, "line_max": 109, "alpha_frac": 0.6298994103, "autogenerated": false, "ratio": 4.124463519313305, "confi...
from django.views.generic import TemplateView from django.core.urlresolvers import reverse from django.shortcuts import render, redirect from django.views.generic import View from django.contrib import messages from django.contrib.auth import get_user_model from django.contrib import messages class SignupView(Templat...
{ "repo_name": "manducku/awesomepose", "path": "awesomepose/users/views/signup.py", "copies": "1", "size": "1185", "license": "mit", "hash": -6533559262182051000, "line_mean": 33.78125, "line_max": 82, "alpha_frac": 0.6109613657, "autogenerated": false, "ratio": 3.4565217391304346, "config_test"...
from django.views.generic import TemplateView from django.db.models.query import QuerySet from django.conf import settings from models import Publication, Project, Code, CodeSnippet, Article, Category from mysite.blog.models import ProjectImage, ProjectVideo class PublicationsView(TemplateView): template_name...
{ "repo_name": "sariyanidi/academics-webpage", "path": "mysite/blog/views.py", "copies": "1", "size": "5100", "license": "mit", "hash": 483279722042022850, "line_mean": 27.4916201117, "line_max": 134, "alpha_frac": 0.5874509804, "autogenerated": false, "ratio": 4.163265306122449, "config_test": ...