Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix/one liners #1630

Merged
merged 2 commits into from
Oct 14, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# Generated by Django 3.1.5 on 2024-10-12 14:59

import datetime
from django.db import migrations, models


class Migration(migrations.Migration):

dependencies = [
('central_mess', '0001_initial'),
]

operations = [
migrations.AlterField(
model_name='payments',
name='payment_date',
field=models.DateField(default=datetime.date.today),
),
migrations.AlterUniqueTogether(
name='payments',
unique_together=set(),
),
]
2 changes: 1 addition & 1 deletion FusionIIIT/applications/central_mess/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ class Payments(models.Model):
amount_paid = models.IntegerField(default=0)
payment_month = models.CharField(max_length=20, default=current_month)
payment_year = models.IntegerField(default = current_year)
payment_date = models.DateField(default= datetime.date.today())
payment_date = models.DateField(default= datetime.date.today)

# class Meta:
# unique_together = (('student_id', 'payment_date'))
Expand Down
4 changes: 2 additions & 2 deletions FusionIIIT/applications/globals/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -65,10 +65,10 @@ class Constants:
('academic', 'Academic Designation'),
('administrative', 'Administrative Designation'),
)
USER_STATUS = {
USER_STATUS = (
("NEW", "NEW"),
("PRESENT", "PRESENT"),
}
)


class Designation(models.Model):
Expand Down
2 changes: 1 addition & 1 deletion FusionIIIT/applications/hostel_management/urls.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
path('admin/', admin.site.urls),
#Home
path('', views.hostel_view, name="hostel_view"),
path('/hello', views.hostel_view, name="hello"),
path('hello', views.hostel_view, name="hello"),

#Notice Board
path('notice_form/', views.notice_board, name="notice_board"),
Expand Down
64 changes: 64 additions & 0 deletions FusionIIIT/applications/hr2/migrations/0002_auto_20241012_1459.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
# Generated by Django 3.1.5 on 2024-10-12 14:59

import django.core.validators
from django.db import migrations, models


class Migration(migrations.Migration):

dependencies = [
('hr2', '0001_initial'),
]

operations = [
migrations.AlterField(
model_name='appraisalform',
name='employeeId',
field=models.IntegerField(null=True),
),
migrations.AlterField(
model_name='cpdaadvanceform',
name='amountRequired',
field=models.IntegerField(null=True),
),
migrations.AlterField(
model_name='cpdaadvanceform',
name='employeeId',
field=models.IntegerField(null=True),
),
migrations.AlterField(
model_name='cpdaadvanceform',
name='pfNo',
field=models.IntegerField(null=True),
),
migrations.AlterField(
model_name='cpdareimbursementform',
name='employeeId',
field=models.IntegerField(null=True),
),
migrations.AlterField(
model_name='cpdareimbursementform',
name='pfNo',
field=models.IntegerField(),
),
migrations.AlterField(
model_name='empconfidentialdetails',
name='aadhar_no',
field=models.BigIntegerField(default=0, validators=[django.core.validators.MaxValueValidator(999999999999), django.core.validators.MinValueValidator(99999999999)]),
),
migrations.AlterField(
model_name='leaveform',
name='employeeId',
field=models.IntegerField(null=True),
),
migrations.AlterField(
model_name='leaveform',
name='pfNo',
field=models.IntegerField(null=True),
),
migrations.AlterField(
model_name='ltcform',
name='pfNo',
field=models.IntegerField(),
),
]
20 changes: 10 additions & 10 deletions FusionIIIT/applications/hr2/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ class EmpConfidentialDetails(models.Model):
table for employee confidential details
"""
extra_info = models.OneToOneField(ExtraInfo, on_delete=models.CASCADE)
aadhar_no = models.BigIntegerField(default=0, max_length=12,
aadhar_no = models.BigIntegerField(default=0,
validators=[MaxValueValidator(999999999999),MinValueValidator(99999999999)])

maritial_status = models.CharField(
Expand Down Expand Up @@ -149,7 +149,7 @@ class LTCform(models.Model):
employeeId = models.IntegerField()
name = models.CharField(max_length=100, null=True)
blockYear = models.TextField() #
pfNo = models.IntegerField(max_length=50)
pfNo = models.IntegerField()
basicPaySalary = models.IntegerField(null=True)
designation = models.CharField(max_length=50)
departmentInfo = models.CharField(max_length=50)
Expand Down Expand Up @@ -181,12 +181,12 @@ class LTCform(models.Model):

class CPDAAdvanceform(models.Model):
id = models.AutoField(primary_key=True)
employeeId = models.IntegerField(max_length=22, null=True)
employeeId = models.IntegerField(null=True)
name = models.CharField(max_length=40,null=True)
designation = models.CharField(max_length=40,null=True)
pfNo = models.IntegerField(max_length=30,null=True)
pfNo = models.IntegerField(null=True)
purpose = models.TextField(max_length=40, null=True)
amountRequired = models.IntegerField(max_length=30,null=True)
amountRequired = models.IntegerField(null=True)
advanceDueAdjustment = models.DecimalField(max_digits=10, decimal_places=2, null=True,blank=True)

submissionDate = models.DateField(blank=True, null=True)
Expand All @@ -202,11 +202,11 @@ class CPDAAdvanceform(models.Model):

class LeaveForm(models.Model):
id = models.AutoField(primary_key=True)
employeeId = models.IntegerField(max_length=22,null=True)
employeeId = models.IntegerField(null=True)
name = models.CharField(max_length=40,null=True)
designation = models.CharField(max_length=40,null=True)
submissionDate = models.DateField(blank=True, null=True)
pfNo = models.IntegerField(max_length=30,null=True)
pfNo = models.IntegerField(null=True)
departmentInfo = models.CharField(max_length=40,null=True)
natureOfLeave = models.TextField(max_length=40,null=True)
leaveStartDate = models.DateField(blank=True, null=True)
Expand Down Expand Up @@ -237,7 +237,7 @@ class LeaveBalance(models.Model):

class Appraisalform(models.Model):
id = models.AutoField(primary_key=True)
employeeId = models.IntegerField(max_length=22,null=True)
employeeId = models.IntegerField(null=True)
name = models.CharField(max_length=22)
designation = models.CharField(max_length=50)
disciplineInfo = models.CharField(max_length=22, null=True)
Expand Down Expand Up @@ -273,10 +273,10 @@ class Appraisalform(models.Model):

class CPDAReimbursementform(models.Model):
id = models.AutoField(primary_key=True)
employeeId = models.IntegerField(max_length=22,null=True)
employeeId = models.IntegerField(null=True)
name = models.CharField(max_length=50)
designation = models.CharField(max_length=50)
pfNo = models.IntegerField(max_length=20)
pfNo = models.IntegerField()
advanceTaken = models.IntegerField()
purpose = models.TextField()
adjustmentSubmitted = models.DecimalField(max_digits=10, decimal_places=2, null=True, blank=True)
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,89 @@
# Generated by Django 3.1.5 on 2024-10-12 14:59

from django.db import migrations, models
import django.db.models.deletion


class Migration(migrations.Migration):

dependencies = [
('iwdModuleV2', '0001_initial'),
]

operations = [
migrations.AddField(
model_name='pageonedetails',
name='page_id',
field=models.OneToOneField(null=True, on_delete=django.db.models.deletion.CASCADE, to='iwdModuleV2.projects'),
),
migrations.AddField(
model_name='pagethreedetails',
name='page_id',
field=models.OneToOneField(null=True, on_delete=django.db.models.deletion.CASCADE, to='iwdModuleV2.projects'),
),
migrations.AddField(
model_name='pagetwodetails',
name='page_id',
field=models.OneToOneField(null=True, on_delete=django.db.models.deletion.CASCADE, to='iwdModuleV2.projects'),
),
migrations.AlterField(
model_name='addendum',
name='key',
field=models.OneToOneField(on_delete=django.db.models.deletion.CASCADE, to='iwdModuleV2.projects'),
),
migrations.AlterField(
model_name='agreement',
name='key',
field=models.OneToOneField(on_delete=django.db.models.deletion.CASCADE, to='iwdModuleV2.projects'),
),
migrations.AlterField(
model_name='corrigendumtable',
name='key',
field=models.OneToOneField(on_delete=django.db.models.deletion.CASCADE, to='iwdModuleV2.projects'),
),
migrations.AlterField(
model_name='financialbiddetails',
name='key',
field=models.OneToOneField(on_delete=django.db.models.deletion.CASCADE, to='iwdModuleV2.projects'),
),
migrations.AlterField(
model_name='letterofintentdetails',
name='key',
field=models.OneToOneField(on_delete=django.db.models.deletion.CASCADE, to='iwdModuleV2.projects'),
),
migrations.AlterField(
model_name='nooftechnicalbidtimes',
name='key',
field=models.OneToOneField(on_delete=django.db.models.deletion.CASCADE, to='iwdModuleV2.projects'),
),
migrations.AlterField(
model_name='pageonedetails',
name='id',
field=models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'),
),
migrations.AlterField(
model_name='pagethreedetails',
name='id',
field=models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'),
),
migrations.AlterField(
model_name='pagetwodetails',
name='id',
field=models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'),
),
migrations.AlterField(
model_name='prebiddetails',
name='key',
field=models.OneToOneField(on_delete=django.db.models.deletion.CASCADE, to='iwdModuleV2.projects'),
),
migrations.AlterField(
model_name='technicalbiddetails',
name='key',
field=models.OneToOneField(on_delete=django.db.models.deletion.CASCADE, to='iwdModuleV2.projects'),
),
migrations.AlterField(
model_name='workorderform',
name='key',
field=models.OneToOneField(on_delete=django.db.models.deletion.CASCADE, to='iwdModuleV2.projects'),
),
]
24 changes: 12 additions & 12 deletions FusionIIIT/applications/iwdModuleV2/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ class Projects(models.Model):


class PageOneDetails(models.Model):
id = models.ForeignKey(Projects, on_delete=models.CASCADE, primary_key=True)
page_id = models.OneToOneField(Projects, on_delete=models.CASCADE, null=True)
aESFile = models.FileField(null=True)
dASA = models.DateField(null=True)
nitNiqNo = models.IntegerField(null=True)
Expand All @@ -31,7 +31,7 @@ class AESDetails(models.Model):


class PageTwoDetails(models.Model):
id = models.ForeignKey(Projects, on_delete=models.CASCADE, primary_key=True)
page_id = models.OneToOneField(Projects, on_delete=models.CASCADE, null=True)
corrigendum = models.FileField(null=True)
addendum = models.FileField(null=True)
preBidMeetingDetails = models.FileField(null=True)
Expand All @@ -46,7 +46,7 @@ class PageTwoDetails(models.Model):


class CorrigendumTable(models.Model):
key = models.ForeignKey(Projects, on_delete=models.CASCADE, unique=True)
key = models.OneToOneField(Projects, on_delete=models.CASCADE)
issueDate = models.DateField()
nitNo = models.IntegerField()
name = models.CharField(max_length=200)
Expand All @@ -59,7 +59,7 @@ class CorrigendumTable(models.Model):


class Addendum(models.Model):
key = models.ForeignKey(Projects, on_delete=models.CASCADE, unique=True)
key = models.OneToOneField(Projects, on_delete=models.CASCADE)
issueDate = models.DateField()
nitNiqNo = models.IntegerField()
name = models.CharField(max_length=200)
Expand All @@ -68,15 +68,15 @@ class Addendum(models.Model):


class PreBidDetails(models.Model):
key = models.ForeignKey(Projects, on_delete=models.CASCADE, unique=True)
key = models.OneToOneField(Projects, on_delete=models.CASCADE)
sNo = models.CharField(max_length=200)
nameOfParticipants = models.CharField(max_length=200)
issuesRaised = models.CharField(max_length=200)
responseDecision = models.CharField(max_length=200)


class TechnicalBidDetails(models.Model):
key = models.ForeignKey(Projects, on_delete=models.CASCADE, unique=True)
key = models.OneToOneField(Projects, on_delete=models.CASCADE)
sNo = models.CharField(max_length=200)
requirements = models.CharField(max_length=200)

Expand All @@ -88,7 +88,7 @@ class TechnicalBidContractorDetails(models.Model):


class FinancialBidDetails(models.Model):
key = models.ForeignKey(Projects, on_delete=models.CASCADE, unique=True)
key = models.OneToOneField(Projects, on_delete=models.CASCADE)
sNo = models.CharField(max_length=200)
description = models.CharField(max_length=200)

Expand All @@ -103,7 +103,7 @@ class FinancialContractorDetails(models.Model):


class LetterOfIntentDetails(models.Model):
key = models.ForeignKey(Projects, on_delete=models.CASCADE, unique=True)
key = models.OneToOneField(Projects, on_delete=models.CASCADE)
nitNiqNo = models.IntegerField()
dateOfOpening = models.DateField()
agency = models.CharField(max_length=200)
Expand All @@ -112,7 +112,7 @@ class LetterOfIntentDetails(models.Model):


class WorkOrderForm(models.Model):
key = models.ForeignKey(Projects, on_delete=models.CASCADE, unique=True)
key = models.OneToOneField(Projects, on_delete=models.CASCADE)
issueDate = models.DateField()
nitNiqNo = models.IntegerField()
agency = models.CharField(max_length=200)
Expand All @@ -127,7 +127,7 @@ class WorkOrderForm(models.Model):


class Agreement(models.Model):
key = models.ForeignKey(Projects, on_delete=models.CASCADE, unique=True)
key = models.OneToOneField(Projects, on_delete=models.CASCADE)
date = models.DateField()
agencyName = models.CharField(max_length=200)
workName = models.CharField(max_length=200)
Expand All @@ -143,7 +143,7 @@ class Milestones(models.Model):


class PageThreeDetails(models.Model):
id = models.ForeignKey(Projects, on_delete=models.CASCADE, primary_key=True)
page_id = models.OneToOneField(Projects, on_delete=models.CASCADE, null=True)
extensionOfTime = models.FileField()
actualCostOfBuilding = models.IntegerField()

Expand All @@ -157,7 +157,7 @@ class ExtensionOfTimeDetails(models.Model):


class NoOfTechnicalBidTimes(models.Model):
key = models.ForeignKey(Projects, on_delete=models.CASCADE, unique=True)
key = models.OneToOneField(Projects, on_delete=models.CASCADE)
number = models.IntegerField()

class Requests(models.Model):
Expand Down
Loading
Loading