Zitat Zitat von Whiz-zarD Beitrag anzeigen
Du sollst ja auch in den Zellen die Divisions verwenden.
(Allerdings weiß ich gar nicht, ob das überhaupt in Tabellen funktioniert)
Aber was ist, wenn 2 Aufträge gleichzeitig starten, aber unterschiedlich lang sind? Dann würde diese Methode ja nicht funktionieren :/
Ich hab hier mal mein PHP Ding.
Code:
<table style="border-collapse: collapse;width: 100%;border-width:1px ;table-layout:fixed;">
    <thead>
        <tr>
            <td>
                Uhrzeit <?php ?>
            </td>
            <?php foreach ($weekPeriod as $date): ?>
                <td>
                    <b><?php echo $weekNames[$date->format('w')];?></b><br/>
                    <?php echo $date->format('d.m.Y'); ?>
                </td>
            <?php endforeach; ?>
        </tr>
    </thead>
    <tbody>
        <?php foreach ($hoursPeriod as $time): ?>
            <tr >
                <td><?php echo $time->format($dayformat); ?></td>
                <?php
                foreach ($weekPeriod as $date):
                    $hours = $time->format('H');
                    $minutes = $time->format('i');
                    $date->setTime($hours, $minutes);
                    $task = getTask($date, $tasks);
                    ?>
                    <?php
                    if ($task):
                        if (!isset($displayedInvervals[$task->id])):
                            $displayedInvervals[$task->id] = true;
                            ?>
                            <td class="task" rowspan="<?= $task->intervals ?>">
                            <div class="task<?php if($task->deleted ==1)echo 'deleted';?>"
                                <b><u> <?php echo $task->id . ':' . $task->name; ?></u></b> 
                                <br><b><?php echo $task->billnumb; ?></b>
                                <br><?php echo $task->customnumb;echo ': '; echo $task->customname; ?>
                                <br><?php echo $task->description; ?>
                                <br><?php echo $task->workernumb;echo ': '; echo $task->workername; ?>
                                <br><?php echo $task->comment; ?><br>
                                <?php if($task->deleted == 0): ?>
                                <a href="Planung/auftragbearbeit.php?action=edit&id=<?php echo $task->id; ?>"target="_blank">Bearbeiten</a>
                                <a href="Planung/auftragloeschen.php?id=<?php echo $task->id; ?>"target="_blank">L��en</a>
                                <?php else:?>
                                <a href="Planung/auftragloeschen.php?id=<?php echo $task->id; ?>"target="_blank">Freigeben</a>
                                <?php endif;?>
                                </div>
                            </td>
                        <?php endif; ?>
                    <?php else: ?>
                        <td class="empty"><a target="_blank" href="Planung/auftragbearbeit.php?action=new&time=<?php echo $date->getTimestamp(); ?>" style="display:block;width:100%;height:100%;"></a></td>
                    <?php endif; ?>


                <?php endforeach; ?>
            </tr>
        <?php endforeach; ?>
    </tbody>
</table>