- Anmeldeformular für Kinderfeuerwehr fertiggestellt - Fehlerbehebung wegen Umstellung auf https - Navigationsleiste wird in der Kategorie "Wir über uns" dynamisch erstellt
158 lines
5.6 KiB
JavaScript
Executable File
158 lines
5.6 KiB
JavaScript
Executable File
/******/ (function(modules) { // webpackBootstrap
|
|
/******/ // The module cache
|
|
/******/ var installedModules = {};
|
|
/******/
|
|
/******/ // The require function
|
|
/******/ function __webpack_require__(moduleId) {
|
|
/******/
|
|
/******/ // Check if module is in cache
|
|
/******/ if(installedModules[moduleId]) {
|
|
/******/ return installedModules[moduleId].exports;
|
|
/******/ }
|
|
/******/ // Create a new module (and put it into the cache)
|
|
/******/ var module = installedModules[moduleId] = {
|
|
/******/ i: moduleId,
|
|
/******/ l: false,
|
|
/******/ exports: {}
|
|
/******/ };
|
|
/******/
|
|
/******/ // Execute the module function
|
|
/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
|
|
/******/
|
|
/******/ // Flag the module as loaded
|
|
/******/ module.l = true;
|
|
/******/
|
|
/******/ // Return the exports of the module
|
|
/******/ return module.exports;
|
|
/******/ }
|
|
/******/
|
|
/******/
|
|
/******/ // expose the modules object (__webpack_modules__)
|
|
/******/ __webpack_require__.m = modules;
|
|
/******/
|
|
/******/ // expose the module cache
|
|
/******/ __webpack_require__.c = installedModules;
|
|
/******/
|
|
/******/ // define getter function for harmony exports
|
|
/******/ __webpack_require__.d = function(exports, name, getter) {
|
|
/******/ if(!__webpack_require__.o(exports, name)) {
|
|
/******/ Object.defineProperty(exports, name, {
|
|
/******/ configurable: false,
|
|
/******/ enumerable: true,
|
|
/******/ get: getter
|
|
/******/ });
|
|
/******/ }
|
|
/******/ };
|
|
/******/
|
|
/******/ // getDefaultExport function for compatibility with non-harmony modules
|
|
/******/ __webpack_require__.n = function(module) {
|
|
/******/ var getter = module && module.__esModule ?
|
|
/******/ function getDefault() { return module['default']; } :
|
|
/******/ function getModuleExports() { return module; };
|
|
/******/ __webpack_require__.d(getter, 'a', getter);
|
|
/******/ return getter;
|
|
/******/ };
|
|
/******/
|
|
/******/ // Object.prototype.hasOwnProperty.call
|
|
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
|
/******/
|
|
/******/ // __webpack_public_path__
|
|
/******/ __webpack_require__.p = "";
|
|
/******/
|
|
/******/ // Load entry module and return exports
|
|
/******/ return __webpack_require__(__webpack_require__.s = 45);
|
|
/******/ })
|
|
/************************************************************************/
|
|
/******/ ({
|
|
|
|
/***/ 45:
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
module.exports = __webpack_require__(46);
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 46:
|
|
/***/ (function(module, exports) {
|
|
|
|
var photo_counter = 0;
|
|
Dropzone.options.realDropzone = {
|
|
|
|
uploadMultiple: false,
|
|
parallelUploads: 100,
|
|
maxFilesize: 8,
|
|
url: 'test',
|
|
previewsContainer: '#dropzonePreview',
|
|
previewTemplate: document.querySelector('#preview-template').innerHTML,
|
|
addRemoveLinks: true,
|
|
dictDefaultMessage: "Dateien hier abgelegen zum Hochladen",
|
|
dictFallbackMessage: "Your browser does not support drag'n'drop file uploads.",
|
|
dictFallbackText: "Please use the fallback form below to upload your files like in the olden days.",
|
|
dictFileTooBig: "Die Datei ist zu groß ({{filesize}}MiB). Maximale Dateigröße: {{maxFilesize}}MiB.",
|
|
dictInvalidFileType: "Dieser Dateityp ist nicht erlaubt",
|
|
dictResponseError: "Server responded with {{statusCode}} code.",
|
|
dictCancelUpload: "Upload abbrechen",
|
|
dictCancelUploadConfirmation: "Are you sure you want to cancel this upload?",
|
|
dictRemoveFile: "löschen",
|
|
dictRemoveFileConfirmation: null,
|
|
dictMaxFilesExceeded: "You can not upload any more files.",
|
|
|
|
// The setting up of the dropzone
|
|
init: function init() {
|
|
$.get('/server-images', function (data) {
|
|
|
|
$.each(data.images, function (key, value) {
|
|
|
|
var file = { name: value.original, size: value.size };
|
|
myDropzone.options.addedfile.call(myDropzone, file);
|
|
myDropzone.options.thumbnail.call(myDropzone, file, 'images/icon_size/' + value.server);
|
|
myDropzone.emit("complete", file);
|
|
photo_counter++;
|
|
$("#photoCounter").text("(" + photo_counter + ")");
|
|
});
|
|
});
|
|
|
|
this.on("removedfile", function (file) {
|
|
|
|
$.ajax({
|
|
type: 'POST',
|
|
url: '/upload/delete',
|
|
data: { id: file.name, _token: $('#csrf-token').val() },
|
|
dataType: 'html',
|
|
success: function success(data) {
|
|
var rep = JSON.parse(data);
|
|
if (rep.code == 200) {
|
|
photo_counter--;
|
|
$("#photoCounter").text("(" + photo_counter + ")");
|
|
}
|
|
},
|
|
error: function error(jqXHR, textStatus, errorThrown) {
|
|
alert(jqXHR);
|
|
alert(textStatus);
|
|
alert(errorThrown);
|
|
}
|
|
});
|
|
});
|
|
},
|
|
error: function error(file, response) {
|
|
if ($.type(response) === "string") var message = response; //dropzone sends it's own error messages in string
|
|
else var message = response.message;
|
|
file.previewElement.classList.add("dz-error");
|
|
_ref = file.previewElement.querySelectorAll("[data-dz-errormessage]");
|
|
_results = [];
|
|
for (_i = 0, _len = _ref.length; _i < _len; _i++) {
|
|
node = _ref[_i];
|
|
_results.push(node.textContent = message);
|
|
}
|
|
return _results;
|
|
},
|
|
success: function success(file, done) {
|
|
photo_counter++;
|
|
$("#photoCounter").text("(" + photo_counter + ")");
|
|
}
|
|
};
|
|
|
|
/***/ })
|
|
|
|
/******/ }); |