-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'main' of github.com:2076-Collective/2077-CMS
- Loading branch information
Showing
11 changed files
with
186 additions
and
90 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
19 changes: 19 additions & 0 deletions
19
server/apps/research/migrations/0009_alter_article_thumb.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
# Generated by Django 5.0.8 on 2024-08-21 12:39 | ||
|
||
import apps.research.models.article | ||
from django.db import migrations, models | ||
|
||
|
||
class Migration(migrations.Migration): | ||
|
||
dependencies = [ | ||
('research', '0008_alter_article_content'), | ||
] | ||
|
||
operations = [ | ||
migrations.AlterField( | ||
model_name='article', | ||
name='thumb', | ||
field=models.ImageField(blank=True, default=apps.research.models.article.get_default_thumb, upload_to='images/'), | ||
), | ||
] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,6 @@ | ||
from .base import * | ||
|
||
MEDIA_URL = '/media/' | ||
|
||
CSRF_TRUSTED_ORIGINS = [ | ||
'http://127.0.0.1:8000', | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
document.addEventListener("DOMContentLoaded", function () { | ||
const editorElement = document.querySelector("#id_contents"); // Adjust to match your actual element ID | ||
if (editorElement) { | ||
ClassicEditor.create(editorElement, { | ||
link: { | ||
decorators: { | ||
addTargetToExternalLinks: false, | ||
}, | ||
}, | ||
removePlugins: ["Link"], | ||
toolbar: { | ||
items: [ | ||
"heading", | ||
"|", | ||
"bold", | ||
"italic", | ||
"link", | ||
"bulletedList", | ||
"numberedList", | ||
"blockQuote", | ||
], | ||
}, | ||
}) | ||
.then((editor) => { | ||
console.log("CKEditor5 initialized successfully"); | ||
}) | ||
.catch((error) => { | ||
console.error("Error initializing CKEditor:", error); | ||
}); | ||
} else { | ||
console.error("CKEditor5 element not found"); | ||
} | ||
}); |