diff --git a/.gitignore b/.gitignore index 488280b..74f846b 100644 --- a/.gitignore +++ b/.gitignore @@ -1,4 +1,4 @@ -<<<<<<< HEAD + # Byte-compiled / optimized / DLL files __pycache__/ *.pyc @@ -110,4 +110,3 @@ local_settings.py # If a rule in .gitignore ends with a directory separator (i.e. `/` # character), then remove the file in the remaining pattern string and all # files with the same name in subdirectories. ->>>>>>> 29790ab (add external integration) diff --git a/NorahUniversity/__pycache__/settings.cpython-313.pyc b/NorahUniversity/__pycache__/settings.cpython-313.pyc index 48f3c69..23e0028 100644 Binary files a/NorahUniversity/__pycache__/settings.cpython-313.pyc and b/NorahUniversity/__pycache__/settings.cpython-313.pyc differ diff --git a/NorahUniversity/__pycache__/urls.cpython-313.pyc b/NorahUniversity/__pycache__/urls.cpython-313.pyc index 56ff2be..e7abc55 100644 Binary files a/NorahUniversity/__pycache__/urls.cpython-313.pyc and b/NorahUniversity/__pycache__/urls.cpython-313.pyc differ diff --git a/NorahUniversity/settings.py b/NorahUniversity/settings.py index 05cb7fd..e0fbf71 100644 --- a/NorahUniversity/settings.py +++ b/NorahUniversity/settings.py @@ -57,7 +57,6 @@ INSTALLED_APPS = [ 'django_countries', 'django_celery_results', 'django_q', - ] SITE_ID = 1 @@ -252,4 +251,104 @@ Q_CLUSTER = { 'max_attempts': 1, }, } -} \ No newline at end of file +} + + +customColorPalette = [ + { + 'color': 'hsl(4, 90%, 58%)', + 'label': 'Red' + }, + { + 'color': 'hsl(340, 82%, 52%)', + 'label': 'Pink' + }, + { + 'color': 'hsl(291, 64%, 42%)', + 'label': 'Purple' + }, + { + 'color': 'hsl(262, 52%, 47%)', + 'label': 'Deep Purple' + }, + { + 'color': 'hsl(231, 48%, 48%)', + 'label': 'Indigo' + }, + { + 'color': 'hsl(207, 90%, 54%)', + 'label': 'Blue' + }, + ] + +CKEDITOR_5_CUSTOM_CSS = 'path_to.css' # optional +CKEDITOR_5_FILE_STORAGE = "path_to_storage.CustomStorage" # optional +CKEDITOR_5_CONFIGS = { + 'default': { + 'toolbar': { + 'items': ['heading', '|', 'bold', 'italic', 'link', + 'bulletedList', 'numberedList', 'blockQuote', 'imageUpload', ], + } + + }, + 'extends': { + 'blockToolbar': [ + 'paragraph', 'heading1', 'heading2', 'heading3', + '|', + 'bulletedList', 'numberedList', + '|', + 'blockQuote', + ], + 'toolbar': { + 'items': ['heading', '|', 'outdent', 'indent', '|', 'bold', 'italic', 'link', 'underline', 'strikethrough', + 'code','subscript', 'superscript', 'highlight', '|', 'codeBlock', 'sourceEditing', 'insertImage', + 'bulletedList', 'numberedList', 'todoList', '|', 'blockQuote', 'imageUpload', '|', + 'fontSize', 'fontFamily', 'fontColor', 'fontBackgroundColor', 'mediaEmbed', 'removeFormat', + 'insertTable', + ], + 'shouldNotGroupWhenFull': 'true' + }, + 'image': { + 'toolbar': ['imageTextAlternative', '|', 'imageStyle:alignLeft', + 'imageStyle:alignRight', 'imageStyle:alignCenter', 'imageStyle:side', '|'], + 'styles': [ + 'full', + 'side', + 'alignLeft', + 'alignRight', + 'alignCenter', + ] + + }, + 'table': { + 'contentToolbar': [ 'tableColumn', 'tableRow', 'mergeTableCells', + 'tableProperties', 'tableCellProperties' ], + 'tableProperties': { + 'borderColors': customColorPalette, + 'backgroundColors': customColorPalette + }, + 'tableCellProperties': { + 'borderColors': customColorPalette, + 'backgroundColors': customColorPalette + } + }, + 'heading' : { + 'options': [ + { 'model': 'paragraph', 'title': 'Paragraph', 'class': 'ck-heading_paragraph' }, + { 'model': 'heading1', 'view': 'h1', 'title': 'Heading 1', 'class': 'ck-heading_heading1' }, + { 'model': 'heading2', 'view': 'h2', 'title': 'Heading 2', 'class': 'ck-heading_heading2' }, + { 'model': 'heading3', 'view': 'h3', 'title': 'Heading 3', 'class': 'ck-heading_heading3' } + ] + } + }, + 'list': { + 'properties': { + 'styles': 'true', + 'startIndex': 'true', + 'reversed': 'true', + } + } +} + +# Define a constant in settings.py to specify file upload permissions +CKEDITOR_5_FILE_UPLOAD_PERMISSION = "staff" # Possible values: "staff", "authenticated", "any" \ No newline at end of file diff --git a/db.sqlite3 b/db.sqlite3 index 94afcef..68bc01e 100644 Binary files a/db.sqlite3 and b/db.sqlite3 differ diff --git a/recruitment/__pycache__/admin.cpython-313.pyc b/recruitment/__pycache__/admin.cpython-313.pyc index ea1b2f9..c67547f 100644 Binary files a/recruitment/__pycache__/admin.cpython-313.pyc and b/recruitment/__pycache__/admin.cpython-313.pyc differ diff --git a/recruitment/__pycache__/forms.cpython-313.pyc b/recruitment/__pycache__/forms.cpython-313.pyc index ffffc9f..6768e08 100644 Binary files a/recruitment/__pycache__/forms.cpython-313.pyc and b/recruitment/__pycache__/forms.cpython-313.pyc differ diff --git a/recruitment/__pycache__/models.cpython-313.pyc b/recruitment/__pycache__/models.cpython-313.pyc index 1236c5d..3c54891 100644 Binary files a/recruitment/__pycache__/models.cpython-313.pyc and b/recruitment/__pycache__/models.cpython-313.pyc differ diff --git a/recruitment/__pycache__/signals.cpython-313.pyc b/recruitment/__pycache__/signals.cpython-313.pyc index 3a9c25c..3a25d0c 100644 Binary files a/recruitment/__pycache__/signals.cpython-313.pyc and b/recruitment/__pycache__/signals.cpython-313.pyc differ diff --git a/recruitment/__pycache__/urls.cpython-313.pyc b/recruitment/__pycache__/urls.cpython-313.pyc index f3436fb..08329cb 100644 Binary files a/recruitment/__pycache__/urls.cpython-313.pyc and b/recruitment/__pycache__/urls.cpython-313.pyc differ diff --git a/recruitment/__pycache__/views.cpython-313.pyc b/recruitment/__pycache__/views.cpython-313.pyc index eb48134..2f50f81 100644 Binary files a/recruitment/__pycache__/views.cpython-313.pyc and b/recruitment/__pycache__/views.cpython-313.pyc differ diff --git a/recruitment/__pycache__/views_frontend.cpython-313.pyc b/recruitment/__pycache__/views_frontend.cpython-313.pyc index e72323e..2208e5a 100644 Binary files a/recruitment/__pycache__/views_frontend.cpython-313.pyc and b/recruitment/__pycache__/views_frontend.cpython-313.pyc differ diff --git a/recruitment/migrations/0001_initial.py b/recruitment/migrations/0001_initial.py index 0e32b64..3a3b33a 100644 --- a/recruitment/migrations/0001_initial.py +++ b/recruitment/migrations/0001_initial.py @@ -1,4 +1,4 @@ -# Generated by Django 5.2.7 on 2025-10-11 11:04 +# Generated by Django 5.2.6 on 2025-10-12 10:34 import django.core.validators import django.db.models.deletion @@ -220,6 +220,7 @@ class Migration(migrations.Migration): ('parsed_summary', models.TextField(blank=True, verbose_name='Parsed Summary')), ('applied', models.BooleanField(default=False, verbose_name='Applied')), ('stage', models.CharField(choices=[('Applied', 'Applied'), ('Exam', 'Exam'), ('Interview', 'Interview'), ('Offer', 'Offer')], default='Applied', max_length=100, verbose_name='Stage')), + ('applicant_status', models.CharField(blank=True, choices=[('Applicant', 'Applicant'), ('Candidate', 'Candidate')], default='Applicant', max_length=100, null=True, verbose_name='Applicant Status')), ('exam_date', models.DateField(blank=True, null=True, verbose_name='Exam Date')), ('exam_status', models.CharField(blank=True, choices=[('Passed', 'Passed'), ('Failed', 'Failed')], max_length=100, null=True, verbose_name='Exam Status')), ('interview_date', models.DateField(blank=True, null=True, verbose_name='Interview Date')), @@ -321,9 +322,7 @@ class Migration(migrations.Migration): name='JobPostingImage', fields=[ ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), - ('post_image', models.ImageField(height_field='photo_height', upload_to='post/', width_field='photo_width')), - ('post_image_height', models.PositiveIntegerField(blank=True, null=True)), - ('post_image_width', models.PositiveIntegerField(blank=True, null=True)), + ('post_image', models.ImageField(upload_to='post/')), ('job', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='post_images', to='recruitment.jobposting')), ], ), diff --git a/recruitment/migrations/0002_remove_jobpostingimage_post_image_height_and_more.py b/recruitment/migrations/0002_remove_jobpostingimage_post_image_height_and_more.py deleted file mode 100644 index 385c411..0000000 --- a/recruitment/migrations/0002_remove_jobpostingimage_post_image_height_and_more.py +++ /dev/null @@ -1,26 +0,0 @@ -# Generated by Django 5.2.7 on 2025-10-11 12:38 - -from django.db import migrations, models - - -class Migration(migrations.Migration): - - dependencies = [ - ('recruitment', '0001_initial'), - ] - - operations = [ - migrations.RemoveField( - model_name='jobpostingimage', - name='post_image_height', - ), - migrations.RemoveField( - model_name='jobpostingimage', - name='post_image_width', - ), - migrations.AlterField( - model_name='jobpostingimage', - name='post_image', - field=models.ImageField(upload_to='post/'), - ), - ] diff --git a/recruitment/migrations/0004_candidate_applicant_status.py b/recruitment/migrations/0004_candidate_applicant_status.py deleted file mode 100644 index 866ba2e..0000000 --- a/recruitment/migrations/0004_candidate_applicant_status.py +++ /dev/null @@ -1,18 +0,0 @@ -# Generated by Django 5.2.6 on 2025-10-11 14:47 - -from django.db import migrations, models - - -class Migration(migrations.Migration): - - dependencies = [ - ('recruitment', '0003_candidate_is_resume_parsed_and_more'), - ] - - operations = [ - migrations.AddField( - model_name='candidate', - name='applicant_status', - field=models.CharField(blank=True, choices=[('Applicant', 'Applicant'), ('Candidate', 'Candidate')], default='Applicant', max_length=100, null=True, verbose_name='Applicant Status'), - ), - ] diff --git a/recruitment/migrations/__pycache__/0001_initial.cpython-313.pyc b/recruitment/migrations/__pycache__/0001_initial.cpython-313.pyc index dfcea98..f5e9725 100644 Binary files a/recruitment/migrations/__pycache__/0001_initial.cpython-313.pyc and b/recruitment/migrations/__pycache__/0001_initial.cpython-313.pyc differ diff --git a/recruitment/migrations/__pycache__/__init__.cpython-313.pyc b/recruitment/migrations/__pycache__/__init__.cpython-313.pyc index b67d53b..6b9887c 100644 Binary files a/recruitment/migrations/__pycache__/__init__.cpython-313.pyc and b/recruitment/migrations/__pycache__/__init__.cpython-313.pyc differ diff --git a/recruitment/models.py b/recruitment/models.py index a6df23c..a038f86 100644 --- a/recruitment/models.py +++ b/recruitment/models.py @@ -79,7 +79,7 @@ class JobPosting(Base): # Job Details description = CKEditor5Field( - 'Description', + 'Description', config_name='extends' # Matches the config name you defined in settings.py ) @@ -118,7 +118,7 @@ class JobPosting(Base): ("ARCHIVED", "Archived"), ] status = models.CharField( - max_length=20, choices=STATUS_CHOICES, default="DRAFT", null=True, blank=True + max_length=20, choices=STATUS_CHOICES, default="DRAFT" ) # hashtags for social media @@ -250,7 +250,7 @@ class JobPosting(Base): class JobPostingImage(models.Model): job=models.ForeignKey('JobPosting',on_delete=models.CASCADE,related_name='post_images') post_image = models.ImageField(upload_to='post/') - + class Candidate(Base): class Stage(models.TextChoices): diff --git a/recruitment/templatetags/__pycache__/form_filters.cpython-313.pyc b/recruitment/templatetags/__pycache__/form_filters.cpython-313.pyc index c7fbf5f..9436ae7 100644 Binary files a/recruitment/templatetags/__pycache__/form_filters.cpython-313.pyc and b/recruitment/templatetags/__pycache__/form_filters.cpython-313.pyc differ