hotfix for images in editor uploads

This commit is contained in:
Are0h 2022-04-23 11:28:20 -07:00
parent 9baaed6d50
commit aa3301fb66
4 changed files with 8689 additions and 165 deletions

View file

@ -4,6 +4,7 @@ namespace brain\api\v1;
use brain\data\Member;
use brain\data\Settings;
use brain\utility\FileUploader;
class ImagesAPI
{

View file

@ -37,9 +37,9 @@
{% block stylesheets %}
<link rel="stylesheet" type="text/css" href="/assets/css/dash.css?=vbhj">
{% endblock %}
{% endblock %}
{% block mainContent %}
{% block mainContent %}
<div id="post-edit-index" data-index="{{ id }}" data-uuid="{{ uuid }}" data-slug="{{ slug }}" data-layout="{{ layout }}">
<div id="post-edit-index-wrapper">
<div id="post-feature">
@ -174,8 +174,8 @@
</div>
</div>
</div>
{% endblock %}
{% endblock %}
{% block javascripts %}
<script src="/assets/scripts/Start.js?=erty" type="text/javascript"></script>
{% endblock %}
{% block javascripts %}
<script src="/assets/scripts/Start.js?=dfdfvd" type="text/javascript"></script>
{% endblock %}

File diff suppressed because one or more lines are too long

View file

@ -19,7 +19,7 @@ export default class PostEditor {
//--------------------------
constructor() {
this.processing = false;
let self = "this";
let self = 'this';
this.admin = new FipamoAdminAPI(null, document.getElementById('notify-progress'));
this.mm = new Maintenance(null, null, document.getElementById('notify-progress'));
this.urlPieces = document.URL.split('/');
@ -69,7 +69,7 @@ export default class PostEditor {
document.getElementById('post-image-upload').addEventListener(
'change',
e => {
self.handleImageUpload(e.target.id, e.target.files);
this.handleImageUpload(e.target.id, e.target.files);
},
false
);
@ -194,7 +194,7 @@ export default class PostEditor {
notify.alert(err, false);
});
})
.catch(() => { });
.catch(() => {});
} else {
// Do nothing!
}