56 lines
1.3 KiB
JavaScript
56 lines
1.3 KiB
JavaScript
|
|
import axios from 'axios'
|
|
|
|
export class Templates{
|
|
static template = {
|
|
header:"",
|
|
wochenbericht:"",
|
|
monatsbericht:"",
|
|
arbeitszeiten:"",
|
|
footer:""
|
|
};
|
|
static getTemplates(){
|
|
axios.get('/templates/header.ptt')
|
|
.then ((result) => {
|
|
Templates.template.header = result.data;
|
|
})
|
|
.catch ((error) => {
|
|
console.log(error);
|
|
})
|
|
axios.get('/templates/wochenbericht.ptt')
|
|
.then ((result) => {
|
|
|
|
Templates.template.wochenbericht = result.data;
|
|
})
|
|
.catch ((error) => {
|
|
console.log(error);
|
|
})
|
|
axios.get('/templates/monatsbericht.ptt')
|
|
.then ((result) => {
|
|
|
|
Templates.template.monatsbericht = result.data;
|
|
})
|
|
.catch ((error) => {
|
|
console.log(error);
|
|
})
|
|
axios.get('/templates/arbeitszeiten.ptt')
|
|
.then ((result) => {
|
|
|
|
Templates.template.arbeitszeiten = result.data;
|
|
})
|
|
.catch ((error) => {
|
|
console.log(error);
|
|
})
|
|
axios.get('/templates/footer.ptt')
|
|
.then ((result) => {
|
|
|
|
Templates.template.footer = result.data;
|
|
})
|
|
.catch ((error) => {
|
|
console.log(error);
|
|
})
|
|
}
|
|
printTimes(){
|
|
return ``
|
|
}
|
|
} |