{if $page == 0} {**}
{*
*} {else}
{/if} {foreach $weekdays as $weekday} {$lastarbtermend = 0} {if $i == 1 && $page == 0}
{$weekday.weekday}
{else if {$weekday.weekday|substr:0:7} != "Samstag" && {$weekday.weekday|substr:0:7} != "Sonntag"}
{$weekday.weekday}
{**}
{*
*} {else}
{$weekday.weekday}
{**}
{*
*} {/if}
{$shift = 0} {$prevtermin= ""} {$absmaxshift.{$weekday.weekday} = 1} {$absmaxshiftone.{$weekday.weekday} = 0} {$shiftone = 0} {foreach $weekday.termine as $key=>$termin} {if {$termin.termdauer} == "24:00:00"} {$termin.termdauer = "23:59:59"} {/if} {if {$prevtermin.termtime|date_format:"%H%M"} <= {$termin.termtime|date_format:"%H%M"} && {{$prevtermin.termtime|date_format:"%H%M"}+{$prevtermin.termdauer|date_format:"%H%M"}} > {$termin.termtime|date_format:"%H%M"}} {*starttime of next term is within the prev term*} {if {$prevtermin.termdauer} == "23:59:59"} {$shiftone = $shiftone+1} {else} {$shift = $shift+1} {/if} {/if} {if $termin.termdauer == "23:59:59"} {if $termin.user2 > 0} {$shiftone = $shiftone+1} {/if} {if $termin.user3 > 0} {$shiftone = $shiftone+1} {/if} {if $termin.user4 > 0} {$shiftone = $shiftone+1} {/if} {else} {if $termin.user2 > 0} {$shift = $shift+1} {/if} {if $termin.user3 > 0} {$shift = $shift+1} {/if} {if $termin.user4 > 0} {$shift = $shift+1} {/if} {/if} {$weekday.termine.{$key}.shift = $shift} {$weekday.termine.{$key}.shiftone = $shiftone} {if $shift+1 > $absmaxshift.{$weekday.weekday}} {$absmaxshift.{$weekday.weekday} = $shift+1} {/if} {if $shiftone > $absmaxshiftone.{$weekday.weekday}} {$absmaxshiftone.{$weekday.weekday} = $shiftone} {/if} {$prevtermin = $termin} {/foreach} {$width = ((18 / $absmaxshift.{$weekday.weekday})-$absmaxshiftone.{$weekday.weekday})} {foreach $weekday.termine as $key=>$termin} {$shift = 10*$i + 3.9 + ($width/2)*$termin.shift + $termin.shiftone} {if {$termin.termdauer} == '24:00:00'} {$terminlength = 960} {$terminstart = 390} {$height = ($terminlength/15)} {$start = 4 + ($terminstart - 420)/15}
{$termin.typ|substr:0:3}.
{else} {$terminlength = ({$termin.termdauer|date_format:"%H"}*60 + {$termin.termdauer|date_format:"%M"})} {$terminstart = ({$termin.termtime|date_format:"%H"}*60 + {$termin.termtime|date_format:"%M"})} {if {$terminstart} == 0}
{$terminlength = {$termin.termdauer}*60} {$terminstart = 450+$lastarbtermend} {$lastarbtermend = $terminstart-450 + $termin.termdauer * 60} {$termin.typ = 'Arbeitsleistung'} {else} {/if} {$height = ($terminlength/15)} {$start = 4 + ($terminstart - 420)/15} {if {$termin.typ} != 'Arbeitsleistung'}
Dauer {if {$termin.termdauer|date_format:'%k'} > 0} {$termin.termdauer|date_format:'%k'}h{/if} {if {$termin.termdauer|date_format:'%M'} > 0}{$termin.termdauer|date_format:'%M'}min{/if}
In {$termin.ort}{if $termin.ortsteil}-{$termin.ortsteil}{/if}
Bei {$termin.vname} {$termin.nname} {$termin.firma}'> {else}
{$termin.typ|substr:0:3}.
{/if}
{if $termin.user2} {$shift = 10*$i + 3.9 + ($width)*($termin.shift-1) + $termin.shiftone} {if {$termin.termdauer} == '24:00:00'} {$terminlength = 960} {$terminstart = 390} {$height = ($terminlength/15)} {$start = 4 + ($terminstart - 420)/15}
{$termin.typ|substr:0:3}.
{else} {$terminlength = ({$termin.termdauer|date_format:"%H"}*60 + {$termin.termdauer|date_format:"%M"})} {$terminstart = ({$termin.termtime|date_format:"%H"}*60 + {$termin.termtime|date_format:"%M"})} {$height = ($terminlength/15)} {$start = 4 + ($terminstart - 420)/15}
Dauer {if {$termin.termdauer|date_format:'%k'} > 0} {$termin.termdauer|date_format:'%k'}h{/if} {if {$termin.termdauer|date_format:'%M'} > 0}{$termin.termdauer|date_format:'%M'}min{/if}
In {$termin.ort}{if $termin.ortsteil}-{$termin.ortsteil}{/if}
Bei {$termin.vname} {$termin.nname} {$termin.firma}'> {$termin.typ|substr:0:3}.
{/if}
{/if} {if $termin.user3} {$shift = 10*$i + 3.9 + ($width)*($termin.shift-2) + $termin.shiftone} {if {$termin.termdauer} == '24:00:00'} {$terminlength = 960} {$terminstart = 390} {$height = ($terminlength/15)} {$start = 4 + ($terminstart - 420)/15}
{$termin.typ|substr:0:3}.
{else} {$terminlength = ({$termin.termdauer|date_format:"%H"}*60 + {$termin.termdauer|date_format:"%M"})} {$terminstart = ({$termin.termtime|date_format:"%H"}*60 + {$termin.termtime|date_format:"%M"})} {$height = ($terminlength/15)} {$start = 4 + ($terminstart - 420)/15}
Dauer {if {$termin.termdauer|date_format:'%k'} > 0} {$termin.termdauer|date_format:'%k'}h{/if} {if {$termin.termdauer|date_format:'%M'} > 0}{$termin.termdauer|date_format:'%M'}min{/if}
In {$termin.ort}{if $termin.ortsteil}-{$termin.ortsteil}{/if}
Bei {$termin.vname} {$termin.nname} {$termin.firma}'> {$termin.typ|substr:0:3}.
{/if}
{/if} {if $termin.user4} {$shift = 10*$i + 3.9 + ($width)*($termin.shift-3) + $termin.shiftone} {if {$termin.termdauer} == '24:00:00'} {$terminlength = 960} {$terminstart = 390} {$height = ($terminlength/15)} {$start = 4 + ($terminstart - 420)/15}
{$termin.typ|substr:0:3}.
{else} {$terminlength = ({$termin.termdauer|date_format:"%H"}*60 + {$termin.termdauer|date_format:"%M"})} {$terminstart = ({$termin.termtime|date_format:"%H"}*60 + {$termin.termtime|date_format:"%M"})} {$height = ($terminlength/15)} {$start = 4 + ($terminstart - 420)/15}
Dauer {if {$termin.termdauer|date_format:'%k'} > 0} {$termin.termdauer|date_format:'%k'}h{/if} {if {$termin.termdauer|date_format:'%M'} > 0}{$termin.termdauer|date_format:'%M'}min{/if}
In {$termin.ort}{if $termin.ortsteil}-{$termin.ortsteil}{/if}
Bei {$termin.vname} {$termin.nname} {$termin.firma}'> {$termin.typ|substr:0:3}.
{/if}
{/if} {/foreach} {$i=$i+1} {/foreach} {$i = 0} {while $i < 16} {$i = $i+1}
{{$i+6}|str_pad:2:'0':0}:00
{/while} {$time = {$smarty.now|date_format:"%H"}*60 + {$smarty.now|date_format:"%M"}}
{if $page == 0} {for $i = 1 to 7}
{$weather.{$i}.low}°C - {$weather.{$i}.high}°C
{/for} {/if}

{foreach $users as $user} {$user.vname} {$user.nname} {/foreach}