mirror of
https://github.com/itflow-org/itflow
synced 2026-09-22 06:31:15 +00:00
Initial migration from AdminLTE 3 to 4, bootstrap 4 to 5
This commit is contained in:
@@ -40,10 +40,8 @@ ob_start();
|
||||
?>
|
||||
|
||||
<div class="modal-header bg-dark">
|
||||
<h5 class="modal-title"><i class="fa fa-fw fa-calendar-check mr-2" style="color:<?= $calendar_color ?>"></i>Editing: <strong><?= $event_title ?></strong></h5>
|
||||
<button type="button" class="close text-white" data-dismiss="modal">
|
||||
<span>×</span>
|
||||
</button>
|
||||
<h5 class="modal-title"><i class="fa fa-fw fa-calendar-check me-2" style="color:<?= $calendar_color ?>"></i>Editing: <strong><?= $event_title ?></strong></h5>
|
||||
<button type="button" class="btn-close btn-close-white" data-bs-dismiss="modal"></button>
|
||||
</div>
|
||||
|
||||
<form action="post.php" method="post" autocomplete="off">
|
||||
@@ -54,13 +52,13 @@ ob_start();
|
||||
|
||||
<ul class="nav nav-pills nav-justified mb-3">
|
||||
<li class="nav-item">
|
||||
<a class="nav-link active" data-toggle="pill" href="#pills-event<?= $event_id ?>"><i class="fa fa-fw fa-calendar-check mr-2"></i>Event</a>
|
||||
<a class="nav-link active" data-bs-toggle="pill" href="#pills-event<?= $event_id ?>"><i class="fa fa-fw fa-calendar-check me-2"></i>Event</a>
|
||||
</li>
|
||||
<li class="nav-item">
|
||||
<a class="nav-link" data-toggle="pill" href="#pills-details<?= $event_id ?>"><i class="fa fa-fw fa-info-circle mr-2"></i>Details</a>
|
||||
<a class="nav-link" data-bs-toggle="pill" href="#pills-details<?= $event_id ?>"><i class="fa fa-fw fa-info-circle me-2"></i>Details</a>
|
||||
</li>
|
||||
<li class="nav-item">
|
||||
<a class="nav-link" data-toggle="pill" href="#pills-attendees<?= $event_id ?>"><i class="fa fa-fw fa-users mr-2"></i>Attendees</a>
|
||||
<a class="nav-link" data-bs-toggle="pill" href="#pills-attendees<?= $event_id ?>"><i class="fa fa-fw fa-users me-2"></i>Attendees</a>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
@@ -70,12 +68,10 @@ ob_start();
|
||||
|
||||
<div class="tab-pane fade show active" id="pills-event<?= $event_id ?>">
|
||||
|
||||
<div class="form-group">
|
||||
<div class="mb-3">
|
||||
<label>Calendar <strong class="text-danger">*</strong></label>
|
||||
<div class="input-group">
|
||||
<div class="input-group-prepend">
|
||||
<span class="input-group-text"><i class="fa fa-calendar"></i></span>
|
||||
</div>
|
||||
<select class="form-control select2" name="calendar" required>
|
||||
<?php
|
||||
|
||||
@@ -85,87 +81,75 @@ ob_start();
|
||||
$calendar_name_select = escapeHtml($row['calendar_name']);
|
||||
$calendar_color_select = escapeHtml($row['calendar_color']);
|
||||
?>
|
||||
<option data-content="<i class='fa fa-circle mr-2' style='color:<?= $calendar_color_select ?>;'></i> <?= $calendar_name_select ?>"<?php if ($calendar_id == $calendar_id_select) { echo "selected"; } ?> value="<?= $calendar_id_select ?>"><?= $calendar_name_select ?></option>
|
||||
<option data-bs-content="<i class='fa fa-circle me-2' style='color:<?= $calendar_color_select ?>;'></i> <?= $calendar_name_select ?>"<?php if ($calendar_id == $calendar_id_select) { echo "selected"; } ?> value="<?= $calendar_id_select ?>"><?= $calendar_name_select ?></option>
|
||||
|
||||
<?php } ?>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<div class="mb-3">
|
||||
<label>Title <strong class="text-danger">*</strong></label>
|
||||
<div class="input-group">
|
||||
<div class="input-group-prepend">
|
||||
<span class="input-group-text"><i class="fa fa-fw fa-calendar-day"></i></span>
|
||||
</div>
|
||||
<input type="text" class="form-control" name="title" maxlength="200" value="<?= $event_title ?>" placeholder="Title of the event" required>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<?php if (!empty($event_repeat)) { ?>
|
||||
<div class="alert alert-info">
|
||||
<i class="fas fa-fw fa-redo mr-2"></i>
|
||||
<i class="fas fa-fw fa-redo me-2"></i>
|
||||
This event repeats <strong>every <?= strtolower($event_repeat) ?></strong>.
|
||||
Saving or deleting affects <strong>every occurrence</strong> — a single
|
||||
occurrence cannot be moved or cancelled on its own.
|
||||
</div>
|
||||
<?php } ?>
|
||||
|
||||
<div class="form-group">
|
||||
<div class="custom-control custom-switch">
|
||||
<input type="checkbox" class="custom-control-input event-all-day-toggle" id="event_edit_all_day" name="all_day" value="1" <?php if ($event_all_day) { echo "checked"; } ?>>
|
||||
<label class="custom-control-label" for="event_edit_all_day">All day</label>
|
||||
<div class="mb-3">
|
||||
<div class="form-check form-switch">
|
||||
<input type="checkbox" class="form-check-input event-all-day-toggle" id="event_edit_all_day" name="all_day" value="1" <?php if ($event_all_day) { echo "checked"; } ?>>
|
||||
<label class="form-check-label" for="event_edit_all_day">All day</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-row">
|
||||
<div class="form-group col-md-6">
|
||||
<div class="row g-2">
|
||||
<div class="mb-3 col-md-6">
|
||||
<label>Date from <strong class="text-danger">*</strong></label>
|
||||
<div class="input-group">
|
||||
<div class="input-group-prepend">
|
||||
<span class="input-group-text"><i class="fa fa-fw fa-calendar-check"></i></span>
|
||||
</div>
|
||||
<input type="date" class="form-control event-start-date" id="event_edit_start_date" name="start_date" value="<?= $event_start_date ?>" required>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group col-md-6">
|
||||
<div class="mb-3 col-md-6">
|
||||
<label>Date to <strong class="text-danger">*</strong></label>
|
||||
<div class="input-group">
|
||||
<div class="input-group-prepend">
|
||||
<span class="input-group-text"><i class="fa fa-fw fa-calendar-day"></i></span>
|
||||
</div>
|
||||
<input type="date" class="form-control" id="event_edit_end_date" name="end_date" value="<?= $event_end_date ?>" required>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-row<?= $event_all_day ? ' d-none' : '' ?>" id="event_edit_time_fields">
|
||||
<div class="form-group col-md-6">
|
||||
<div class="row g-2<?= $event_all_day ? ' d-none' : '' ?>" id="event_edit_time_fields">
|
||||
<div class="mb-3 col-md-6">
|
||||
<label>Time from <strong class="text-danger">*</strong></label>
|
||||
<div class="input-group">
|
||||
<div class="input-group-prepend">
|
||||
<span class="input-group-text"><i class="fa fa-fw fa-clock"></i></span>
|
||||
</div>
|
||||
<input type="time" class="form-control event-start-time" id="event_edit_start_time" name="start_time" value="<?= $event_start_time ?>"<?= $event_all_day ? '' : ' required' ?>>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group col-md-6">
|
||||
<div class="mb-3 col-md-6">
|
||||
<label>Time to <strong class="text-danger">*</strong></label>
|
||||
<div class="input-group">
|
||||
<div class="input-group-prepend">
|
||||
<span class="input-group-text"><i class="fa fa-fw fa-clock"></i></span>
|
||||
</div>
|
||||
<input type="time" class="form-control" id="event_edit_end_time" name="end_time" value="<?= $event_end_time ?>"<?= $event_all_day ? '' : ' required' ?>>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<div class="mb-3">
|
||||
<label>Repeat</label>
|
||||
<div class="input-group">
|
||||
<div class="input-group-prepend">
|
||||
<span class="input-group-text"><i class="fa fa-fw fa-recycle"></i></span>
|
||||
</div>
|
||||
<select class="form-control select2" name="repeat">
|
||||
<option <?php if (empty($event_repeat)) { echo "selected"; } ?> value="">Never</option>
|
||||
<option <?php if ($event_repeat == "Day") { echo "selected"; } ?>>Day</option>
|
||||
@@ -179,17 +163,15 @@ ob_start();
|
||||
</div>
|
||||
|
||||
<div class="tab-pane fade" id="pills-details<?= $event_id ?>">
|
||||
<div class="form-group">
|
||||
<div class="mb-3">
|
||||
<label>Location</label>
|
||||
<div class="input-group">
|
||||
<div class="input-group-prepend">
|
||||
<span class="input-group-text"><i class="fa fa-fw fa-map-marker-alt"></i></span>
|
||||
</div>
|
||||
<input type="text" class="form-control" name="location" value="<?= $event_location ?>" placeholder="Location of the event">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<div class="mb-3">
|
||||
<label>Description</label>
|
||||
<textarea class="form-control" rows="8" name="description" placeholder="Enter a description"><?= $event_description ?></textarea>
|
||||
</div>
|
||||
@@ -203,12 +185,10 @@ ob_start();
|
||||
<input type="hidden" name="client_id" value="<?= $client_id ?>">
|
||||
<?php } else { ?>
|
||||
|
||||
<div class="form-group">
|
||||
<div class="mb-3">
|
||||
<label>Client</label>
|
||||
<div class="input-group">
|
||||
<div class="input-group-prepend">
|
||||
<span class="input-group-text"><i class="fa fa-fw fa-user"></i></span>
|
||||
</div>
|
||||
<select class="form-control select2" name="client">
|
||||
<option value="">- Client -</option>
|
||||
<?php
|
||||
@@ -230,9 +210,9 @@ ob_start();
|
||||
<?php } ?>
|
||||
|
||||
<?php if (!empty($config_smtp_host)) { ?>
|
||||
<div class="custom-control custom-checkbox">
|
||||
<input type="checkbox" class="custom-control-input" id="customControlAutosizing<?= $event_id ?>" name="email_event" value="1" >
|
||||
<label class="custom-control-label" for="customControlAutosizing<?= $event_id ?>">Email Event</label>
|
||||
<div class="form-check">
|
||||
<input type="checkbox" class="form-check-input" id="customControlAutosizing<?= $event_id ?>" name="email_event" value="1" >
|
||||
<label class="form-check-label" for="customControlAutosizing<?= $event_id ?>">Email Event</label>
|
||||
</div>
|
||||
<?php } ?>
|
||||
|
||||
@@ -242,9 +222,9 @@ ob_start();
|
||||
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<a class="btn btn-default text-danger mr-auto" href="post.php?delete_event=<?= $event_id ?>&csrf_token=<?= $_SESSION['csrf_token'] ?>"><i class="fa fa-calendar-times mr-2"></i><?= empty($event_repeat) ? 'Delete' : 'Delete series' ?></a>
|
||||
<button type="submit" name="edit_event" class="btn btn-primary text-bold"><i class="fa fa-check mr-2"></i>Save</button>
|
||||
<button type="button" class="btn btn-light" data-dismiss="modal"><i class="fa fa-times mr-2"></i>Cancel</button>
|
||||
<a class="btn btn-default text-danger me-auto" href="post.php?delete_event=<?= $event_id ?>&csrf_token=<?= $_SESSION['csrf_token'] ?>"><i class="fa fa-calendar-times me-2"></i><?= empty($event_repeat) ? 'Delete' : 'Delete series' ?></a>
|
||||
<button type="submit" name="edit_event" class="btn btn-primary text-bold"><i class="fa fa-check me-2"></i>Save</button>
|
||||
<button type="button" class="btn btn-light" data-bs-dismiss="modal"><i class="fa fa-times me-2"></i>Cancel</button>
|
||||
</div>
|
||||
</form>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user