diff --git a/public/main.css b/public/main.css
index df04e60..e74d884 100644
--- a/public/main.css
+++ b/public/main.css
@@ -3,6 +3,24 @@ select {
height: 34px;
box-sizing: border-box;
}
+#notify-center {
+ position: fixed;
+ bottom: 0;
+ right: 0;
+ width: 0;
+ height: 0;
+ background-color: #FFF;
+}
+#notify-center .notification {
+ width: 200px;
+ position: absolute;
+ bottom: 0;
+ right: 0;
+ margin: 5px;
+ padding: 5px;
+ border: 1px solid #454545;
+ box-shadow: 1px 2px 3px rgba(69, 69, 69, 0.34901961);
+}
@font-face {
font-family: 'Exo';
font-style: normal;
diff --git a/public/templates/wochenbericht_2_wo_time.ptt b/public/templates/wochenbericht_2_wo_time.ptt
new file mode 100644
index 0000000..df62052
--- /dev/null
+++ b/public/templates/wochenbericht_2_wo_time.ptt
@@ -0,0 +1,1086 @@
+
+{% for id, week in weeks %}
+
+
+
Berichtsheft für die kaufmännische Berufsausbildung
+
+
+
+
+
+
+ Name und Vorname
+ |
+
+ {{name}}
+ |
+
+
+
+ Ausbildungsabteilung
+ |
+
+ Fachdienst IT-Service
+ |
+
+
+
+
+
+
+
+
+ Ausbildungsnachweis Nr.
+ |
+
+ {{week.num}}
+ |
+
+
+ |
+
+
+ |
+
+
+ |
+
+
+ |
+
+
+
+
+
+
+
+
+ Art der ausgeführten Ausbildungsarbeit
+ |
+
+
+
+ Vom
+ |
+
+ 26/02/2018
+ |
+
+ bis
+ |
+
+ 02/03/2018
+ |
+
+
+
+
+ {% for day in week.data %}
+
+
+
+ {{day[1]}}
+ |
+
+
+ |
+
+ {% for task in day[5] %}
+ {{task}}
+ {% endfor %}
+
+ |
+
+
+
+ {% endfor %}
+
+ |
+
+
+
+
Bemerkungen des Ausbilders
+
+
+
+
+ Bemerkungen über ausgeführte Ausbildungsarbeiten,
+ Zwischenprüfungen, Ausbildungslehrgänge, Ausbildungsnachweis usw.
+
+ |
+
+
+
+
Unterschriften
+
+
+
+
+
+ Für die Richtigkeit aller
+ Angaben:
+
+
+
+ _______________________
+ Auszubildender
+ Unterschrift und Datum
+ |
+
+
+ Für die Richtigkeit aller
+ Angaben über die betriebliche Ausbildung:
+
+
+ _______________________
+ Ausbilder
+ Unterschrift und Datum
+ |
+
+
+ Gesehen:
+
+
+
+
+ __________________________________________________
+ Betriebsrat Gesetzlicher
+ Vertreter
+ Sichtvermerk und
+ Datum Sichtvermerk und Datum
+ |
+
+
+
+
+
+{% endfor %}
\ No newline at end of file
diff --git a/src/jsx/static/debug.jsx b/src/jsx/static/debug.jsx
index 8c32012..27464ec 100644
--- a/src/jsx/static/debug.jsx
+++ b/src/jsx/static/debug.jsx
@@ -1,6 +1,6 @@
export class Log{
static debug(txt){
- console.debug('%cDEBUG: '+txt, 'background: #222; color: #bada55');
+ //console.debug('%cDEBUG: '+txt, 'background: #222; color: #bada55');
}
}
\ No newline at end of file
diff --git a/src/jsx/static/notify.jsx b/src/jsx/static/notify.jsx
new file mode 100644
index 0000000..c566da1
--- /dev/null
+++ b/src/jsx/static/notify.jsx
@@ -0,0 +1,19 @@
+import { Log } from "./debug";
+
+export class Notify{
+ static onEventsArray = [];
+ static on(func){
+ Notify.onEventsArray.push(func);
+ }
+ /**
+ *
+ * @param {*} data {title:"",body:"",type:""}
+ */
+ static emit(data){
+ Log.debug('Notify emit');
+ for(var f in Notify.onEventsArray){
+ Log.debug(Notify.onEventsArray[f]);
+ Notify.onEventsArray[f](data);
+ }
+ }
+}
\ No newline at end of file
diff --git a/src/jsx/ui/calender.jsx b/src/jsx/ui/calender.jsx
index 9306c89..239d53b 100644
--- a/src/jsx/ui/calender.jsx
+++ b/src/jsx/ui/calender.jsx
@@ -2,6 +2,8 @@ import React from 'react';
import InfiniteCalendar from 'react-infinite-calendar';
import {DB} from '../static/storage'
import { Log } from '../static/debug';
+
+import {Notify} from '../static/notify';
//import 'react-infinite-calendar/styles.css'; // only needs to be imported once
//const { ipcRenderer} = require('electron');
@@ -139,6 +141,7 @@ export class Calender extends React.Component {
taskList:this.state.taskList
}
);
+ Notify.emit({title:"",body:"Eintrag gespeichert.",type:"success"});
//ipcRenderer.send('saveDate',s)
}
render() {
diff --git a/src/jsx/ui/components/templates.jsx b/src/jsx/ui/components/templates.jsx
index c02c97d..5145861 100644
--- a/src/jsx/ui/components/templates.jsx
+++ b/src/jsx/ui/components/templates.jsx
@@ -6,6 +6,7 @@ export class Templates{
header:"",
wochenbericht:"",
wochenbericht_2:"",
+ wochenbericht_2_wo_time:"",
monatsbericht:"",
arbeitszeiten:"",
footer:""
@@ -37,6 +38,14 @@ export class Templates{
.catch ((error) => {
console.log(error);
})
+ axios.get('/templates/wochenbericht_2_wo_time.ptt')
+ .then ((result) => {
+
+ Templates.template.wochenbericht_2_wo_time = result.data;
+ })
+ .catch ((error) => {
+ console.log(error);
+ })
axios.get('/templates/monatsbericht.ptt')
.then ((result) => {
diff --git a/src/jsx/ui/generator.jsx b/src/jsx/ui/generator.jsx
index c7eca86..351a5bb 100644
--- a/src/jsx/ui/generator.jsx
+++ b/src/jsx/ui/generator.jsx
@@ -1,5 +1,6 @@
import React from 'react';
import {DB} from '../static/storage';
+import { Notify } from '../static/notify';
//import 'react-infinite-calendar/styles.css'; // only needs to be imported once
const moment = require('moment');
@@ -245,6 +246,7 @@ export class Generator extends React.Component {
}
}
}
+ Notify.emit({title:"",body:"Einträge generiert.",type:"success"});
}
handleMo(e) {
//console.log(e.target.id);
diff --git a/src/jsx/ui/nav.jsx b/src/jsx/ui/nav.jsx
index 8eee923..3a97df5 100644
--- a/src/jsx/ui/nav.jsx
+++ b/src/jsx/ui/nav.jsx
@@ -7,14 +7,23 @@ import {Print} from './print';
import {Settings} from './settings';
import {DB} from './../static/storage'
+import { Notify } from '../static/notify';
export class Nav extends React.Component {
constructor(props) {
super(props);
this.state = {
- tab:(