mirror of
https://github.com/itflow-org/itflow
synced 2026-08-06 07:37:16 +00:00
Use Short echo tags across the code
This commit is contained in:
@@ -44,8 +44,8 @@ ob_start();
|
||||
|
||||
<form action="post.php" method="post" enctype="multipart/form-data" autocomplete="off">
|
||||
<div class="modal-body">
|
||||
<input type="hidden" name="csrf_token" value="<?php echo $_SESSION['csrf_token'] ?>">
|
||||
<input type="hidden" name="expense_id" value="<?php echo $expense_id; ?>">
|
||||
<input type="hidden" name="csrf_token" value="<?= $_SESSION['csrf_token'] ?>">
|
||||
<input type="hidden" name="expense_id" value="<?= $expense_id ?>">
|
||||
|
||||
<div class="form-row">
|
||||
|
||||
@@ -55,7 +55,7 @@ ob_start();
|
||||
<div class="input-group-prepend">
|
||||
<span class="input-group-text"><i class="fa fa-fw fa-calendar"></i></span>
|
||||
</div>
|
||||
<input type="date" class="form-control" name="date" max="2999-12-31" value="<?php echo $expense_date; ?>" required>
|
||||
<input type="date" class="form-control" name="date" max="2999-12-31" value="<?= $expense_date ?>" required>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -65,7 +65,7 @@ ob_start();
|
||||
<div class="input-group-prepend">
|
||||
<span class="input-group-text"><i class="fa fa-fw fa-dollar-sign"></i></span>
|
||||
</div>
|
||||
<input type="text" class="form-control" inputmode="decimal" pattern="-?[0-9]*\.?[0-9]{0,2}" name="amount" value="<?php echo number_format($expense_amount, 2, '.', ''); ?>" placeholder="0.00" required>
|
||||
<input type="text" class="form-control" inputmode="decimal" pattern="-?[0-9]*\.?[0-9]{0,2}" name="amount" value="<?= number_format($expense_amount, 2, '.', '') ?>" placeholder="0.00" required>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -108,7 +108,7 @@ ob_start();
|
||||
$balance = $opening_balance + $total_payments + $total_revenues - $total_expenses;
|
||||
|
||||
?>
|
||||
<option <?php if ($expense_account_id == $account_id_select) { ?> selected <?php } ?> value="<?php echo $account_id_select; ?>"><?php echo "$account_archived_display$account_name_select"; ?> [$<?php echo number_format($balance, 2); ?>]</option>
|
||||
<option <?php if ($expense_account_id == $account_id_select) { ?> selected <?php } ?> value="<?= $account_id_select ?>"><?= "$account_archived_display$account_name_select" ?> [$<?= number_format($balance, 2) ?>]</option>
|
||||
<?php
|
||||
}
|
||||
|
||||
@@ -131,7 +131,7 @@ ob_start();
|
||||
$vendor_id_select = intval($row['vendor_id']);
|
||||
$vendor_name_select = escapeHtml($row['vendor_name']);
|
||||
?>
|
||||
<option <?php if ($expense_vendor_id == $vendor_id_select) { ?> selected <?php } ?> value="<?php echo $vendor_id_select; ?>"><?php echo $vendor_name_select; ?></option>
|
||||
<option <?php if ($expense_vendor_id == $vendor_id_select) { ?> selected <?php } ?> value="<?= $vendor_id_select ?>"><?= $vendor_name_select ?></option>
|
||||
<?php
|
||||
}
|
||||
|
||||
@@ -147,7 +147,7 @@ ob_start();
|
||||
|
||||
<div class="form-group">
|
||||
<label>Description <strong class="text-danger">*</strong></label>
|
||||
<textarea class="form-control" rows="6" name="description" placeholder="Enter a description" required><?php echo $expense_description; ?></textarea>
|
||||
<textarea class="form-control" rows="6" name="description" placeholder="Enter a description" required><?= $expense_description ?></textarea>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
@@ -156,7 +156,7 @@ ob_start();
|
||||
<div class="input-group-prepend">
|
||||
<span class="input-group-text"><i class="fa fa-fw fa-file-alt"></i></span>
|
||||
</div>
|
||||
<input type="text" class="form-control" name="reference" placeholder="Enter a reference" maxlength="200" value="<?php echo $expense_reference; ?>">
|
||||
<input type="text" class="form-control" name="reference" placeholder="Enter a reference" maxlength="200" value="<?= $expense_reference ?>">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -176,7 +176,7 @@ ob_start();
|
||||
$category_id_select = intval($row['category_id']);
|
||||
$category_name_select = escapeHtml($row['category_name']);
|
||||
?>
|
||||
<option <?php if ($expense_category_id == $category_id_select) { ?> selected <?php } ?> value="<?php echo $category_id_select; ?>"><?php echo $category_name_select; ?></option>
|
||||
<option <?php if ($expense_category_id == $category_id_select) { ?> selected <?php } ?> value="<?= $category_id_select ?>"><?= $category_name_select ?></option>
|
||||
<?php
|
||||
}
|
||||
|
||||
@@ -192,7 +192,7 @@ ob_start();
|
||||
</div>
|
||||
|
||||
<?php if (isset($_GET['client_id'])) { ?>
|
||||
<input type="hidden" name="client_id" value="<?php echo $client_id; ?>">
|
||||
<input type="hidden" name="client_id" value="<?= $client_id ?>">
|
||||
<?php } else { ?>
|
||||
|
||||
<div class="form-group col-md">
|
||||
@@ -210,7 +210,7 @@ ob_start();
|
||||
$client_id_select = intval($row['client_id']);
|
||||
$client_name_select = escapeHtml($row['client_name']);
|
||||
?>
|
||||
<option <?php if ($client_id == $client_id_select) { echo "selected"; } ?> value="<?php echo $client_id_select; ?>"><?php echo $client_name_select; ?></option>
|
||||
<option <?php if ($client_id == $client_id_select) { echo "selected"; } ?> value="<?= $client_id_select ?>"><?= $client_name_select ?></option>
|
||||
|
||||
<?php
|
||||
}
|
||||
@@ -230,9 +230,9 @@ ob_start();
|
||||
|
||||
<?php if (!empty($expense_receipt)) { ?>
|
||||
<hr>
|
||||
<a class="text-secondary" href="<?php echo "../uploads/expenses/$expense_receipt"; ?>"
|
||||
download="<?php echo "$expense_date-$vendor_name-$category_name-$expense_id.pdf" ?>">
|
||||
<i class="fa fa-fw fa-2x fa-file-pdf text-secondary"></i> <?php echo "$expense_date-$vendor_name-$category_name-$expense_id.pdf" ?>
|
||||
<a class="text-secondary" href="<?= "../uploads/expenses/$expense_receipt" ?>"
|
||||
download="<?= "$expense_date-$vendor_name-$category_name-$expense_id.pdf" ?>">
|
||||
<i class="fa fa-fw fa-2x fa-file-pdf text-secondary"></i> <?= "$expense_date-$vendor_name-$category_name-$expense_id.pdf" ?>
|
||||
</a>
|
||||
<?php } ?>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user