init views and add season attribute to internship

This commit is contained in:
karthikmurakonda 2023-07-13 00:03:48 +05:30
parent 2d18135a4a
commit 4e85772557
6 changed files with 25 additions and 5 deletions

View File

@ -3,5 +3,6 @@ from django.urls import path, include
urlpatterns = [ urlpatterns = [
path('admin/', admin.site.urls), path('admin/', admin.site.urls),
path('api/', include('APIs.urls')) path('api/', include('APIs.urls')),
path('internapi/', include('internAPIs.urls'))
] ]

View File

@ -0,0 +1,7 @@
from django.urls import path
from . import companyViews
urlpatterns = [
path('addInternship/', companyViews.addInternship, name="Add Internship"),
]

View File

@ -0,0 +1,4 @@
def addInternship(request):
pass

View File

@ -47,10 +47,10 @@ TIERS = [
] ]
SEASON_CHOICES = ( SEASON_CHOICES = (
('summer', 'Summer'), ['summer', 'Summer'],
('winter', 'Winter'), ['winter', 'Winter'],
('monsoon', 'Monsoon'), ['autumn', 'Autumn'],
('spring', 'Spring'), ['spring', 'Spring'],
) )
DEGREE_CHOICES = [ DEGREE_CHOICES = [

View File

@ -48,6 +48,7 @@ class Internship(models.Model):
description = models.CharField(blank=False, max_length=INF_TEXTAREA_MAX_CHARACTER_COUNT, default=None, null=True) description = models.CharField(blank=False, max_length=INF_TEXTAREA_MAX_CHARACTER_COUNT, default=None, null=True)
interning_period_from = models.DateField(blank=False, default=None, null=True) interning_period_from = models.DateField(blank=False, default=None, null=True)
interning_period_to = models.DateField(blank=False, default=None, null=True) interning_period_to = models.DateField(blank=False, default=None, null=True)
season = models.CharField(blank=False, max_length=10, choices=SEASON_CHOICES, default=None)
is_work_from_home = models.BooleanField(blank=False, default=False) is_work_from_home = models.BooleanField(blank=False, default=False)
sophomore_eligible = models.BooleanField(blank=False, default=False) sophomore_eligible = models.BooleanField(blank=False, default=False)
tentative_no_of_offers = models.IntegerField(blank=False, default=None, null=True) tentative_no_of_offers = models.IntegerField(blank=False, default=None, null=True)

View File

@ -0,0 +1,7 @@
from django.urls import path, include
from . import companyUrls
urlpatterns = [
path('company/', include(companyUrls)),
]