mirror of
https://github.com/itflow-org/itflow
synced 2026-03-20 12:44:50 +00:00
Allow Overriding a ticket templates subject when creating a ticket from template
This commit is contained in:
@@ -31,7 +31,11 @@ if (isset($_POST['add_ticket'])) {
|
|||||||
if($ticket_template_id) {
|
if($ticket_template_id) {
|
||||||
$sql = mysqli_query($mysqli, "SELECT * FROM ticket_templates WHERE ticket_template_id = $ticket_template_id");
|
$sql = mysqli_query($mysqli, "SELECT * FROM ticket_templates WHERE ticket_template_id = $ticket_template_id");
|
||||||
$row = mysqli_fetch_array($sql);
|
$row = mysqli_fetch_array($sql);
|
||||||
$subject = sanitizeInput($row['ticket_template_subject']);
|
|
||||||
|
// Overide Template Subject
|
||||||
|
if(empty($subject)) {
|
||||||
|
$subject = sanitizeInput($row['ticket_template_subject']);
|
||||||
|
}
|
||||||
$details = mysqli_escape_string($mysqli, $row['ticket_template_details']);
|
$details = mysqli_escape_string($mysqli, $row['ticket_template_details']);
|
||||||
|
|
||||||
// Get Associated Tasks from the ticket template
|
// Get Associated Tasks from the ticket template
|
||||||
|
|||||||
@@ -64,6 +64,16 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<div class="form-group">
|
||||||
|
<label>Override Subject</label>
|
||||||
|
<div class="input-group">
|
||||||
|
<div class="input-group-prepend">
|
||||||
|
<span class="input-group-text"><i class="fa fa-fw fa-tag"></i></span>
|
||||||
|
</div>
|
||||||
|
<input type="text" class="form-control" name="subject" placeholder="Fill this in to override the templates subject">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
<?php if (empty($_GET['client_id'])) { ?>
|
<?php if (empty($_GET['client_id'])) { ?>
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user