WIP Voicenumber Billing 2024-07-05

This commit is contained in:
Frank Schubert
2024-07-06 18:37:40 +02:00
parent 92edb9c812
commit 200af4802a
16 changed files with 417 additions and 220 deletions

View File

@@ -76,8 +76,23 @@
}
$inputid = "itemvalues_".$item->id;
$array_count = 0;
?>
<?php if($item->multiple): ?>
<?php // TODO: spezial configs besser machen ?>
<?php if($item->name == "voicenumberblock_voiceplan_id"): ?>
<tr id="tr-<?=$inputid?>_0">
<th style="max-width: 50vw;"><?=$item->displayname?>:</th>
<td style="width: 50vw;">
<select class="form-control" name="<?=$inputname?>" id="<?=$inputid?>" <?=($item->multiple) ? "data-item-multiple='true'" : ""?>>
<option value="0"></option>
<?php foreach(VoiceplanModel::getAll() as $voiceplan): ?>
<option value="<?=$voiceplan->id?>" <?=($item->getValue() == $voiceplan->id) ? "selected='selected'" : ""?>><?=$voiceplan->name?></option>
<?php endforeach; ?>
</select>
<small><?=$item->description?></small>
</td>
</tr>
<?php elseif($item->multiple): ?>
<?php foreach($item->getValue() as $item_value): ?>
<tr id="tr-<?=$inputid?>_<?=$array_count?>">
<th style="max-width: 50vw;"><?=$item->displayname?><span class="array_counter"> (<?=$array_count + 1?>)</span>:</th>