Dialog Neuer Nutzer begonnen
3 files modified
1 files added
| | |
| | | { |
| | | "menue": { |
| | | "menuetitel": "Untermenü 1", |
| | | "menuetitel": "Nutzer", |
| | | "wurzel": false, |
| | | "vorgaenger": { |
| | | "vtitel": "Hauptmenü", |
| | |
| | | }, |
| | | "inhalt": [ |
| | | { |
| | | "titel": "Benachrichtigung 1", |
| | | "titel": "Neu", |
| | | "umenue": false, |
| | | "funktion": "app.message_1" |
| | | "funktion": "app.nutzer_neu_dialog_zeigen" |
| | | }, |
| | | { |
| | | "titel": "noch mehr", |
New file |
| | |
| | | <div class="dlg-nutzer-neu"> |
| | | <span class="close-btn pointer-cursor">✖</span> |
| | | <div class="dlg-behaelter"> |
| | | <div class="dlg-nutzer-titel">Neuer Nutzer</div> |
| | | <form> |
| | | <input id="nutzer-id" placeholder="Anmelde-ID" type="text" class="nutzer-eingabe"></br> |
| | | <!--<label class="inline-label">Name:</label>--> |
| | | <input id="nutzer-vorname" placeholder="Vorname" type="text" class="nutzer-eingabe"></br> |
| | | <!--<label class="inline-label">URL:</label>--> |
| | | <input id="nutzer-name" placeholder="Name" type="text" class="nutzer-eingabe"></br> |
| | | <!--<label class="inline-label">Bild:</label>--> |
| | | <input id="nutzer-email" placeholder="E-Mail-Adresse" type="text" class="nutzer-eingabe"></br> |
| | | <input id="nutzer-kw" placeholder="Kennwort" type="text" class="nutzer-eingabe"></br> |
| | | <input id="nutzer-wkw" placeholder="Wiederholung Kennwort" type="text" class="nutzer-eingabe"></br> |
| | | <div class="form-button-footer"> |
| | | <button type="button" id="nutzer-speichern">Speichern</button> |
| | | </div> |
| | | </form> |
| | | </div> |
| | | </div> |
| | |
| | | <script> |
| | | var app; |
| | | document.addEventListener('DOMContentLoaded', function () { |
| | | app = new AppVorlage(); |
| | | app = new NutzerApp(); |
| | | app.init(); |
| | | }); |
| | | </script> |
| | |
| | | function AppVorlage() { |
| | | function NutzerApp() { |
| | | var self = this; |
| | | var appMenu; |
| | | var vorlagen; |
| | |
| | | |
| | | this.info_dialog_zeigen = function () { |
| | | self.dialog_laden_und_zeigen('data/tpl/dlg-info.tpl', ''); |
| | | self.menue_umschalten(); |
| | | }; |
| | | |
| | | this.nutzer_neu_dialog_zeigen = function () { |
| | | self.dialog_laden_und_zeigen('data/tpl/dlg-nutzer-neu.tpl', ''); |
| | | self.menue_umschalten(); |
| | | }; |
| | | |
| | |
| | | vurl, |
| | | inhalt, |
| | | function (html) { |
| | | dlg.style.flexBasis = '6em'; |
| | | dlg.style.flexBasis = '14em'; |
| | | setTimeout(function () { |
| | | dlg.innerHTML = html; |
| | | document.querySelector('.close-btn').addEventListener('click', self.dialog_schliessen); |
| | |
| | | xmlhttp.open("GET", url, true); |
| | | xmlhttp.send(); |
| | | }; |
| | | |
| | | /* ----- Hilfsfunktionen ----- */ |
| | | |
| | | this.serialisieren = function(obj) { |
| | | return '{"' + obj.constructor.name + '":' + JSON.stringify(obj) + '}'; |
| | | }; |
| | | |
| | | } |
| | | |
| | | |
| | | /* ----- Objekte ----- */ |
| | | |
| | | function User(i, p, fn, ln, em) { |
| | | this.id = i; |
| | | this.pw = p; |
| | | this.firstName = fn; |
| | | this.lastName = ln; |
| | | this.email = em; |
| | | } |
| | | |