Browse Source

#67 Wired up part of the UI. Still need to add section to view attachments

merge-requests/2/head
Mike Koch 7 years ago
parent
commit
65a80089c0
  1. 33
      admin/admin_ticket.php
  2. 8
      js/nuMods-javascript.js
  3. 1
      language/en/text.php

33
admin/admin_ticket.php

@ -866,7 +866,6 @@ require_once(HESK_PATH . 'inc/show_admin_nav.inc.php');
?>
<div class="row">
<div class="col-md-12">
<b><i><?php echo $hesklang['notes']; ?>: </i></b>
<?php
if ($can_reply)
{
@ -877,11 +876,33 @@ require_once(HESK_PATH . 'inc/show_admin_nav.inc.php');
?>
<div id="notesform" style="display:none">
<form method="post" action="admin_ticket.php" style="margin:0px; padding:0px;">
<textarea class="form-control" name="notemsg" rows="6" cols="60"></textarea><br />
<input class="btn btn-default" type="submit" value="<?php echo $hesklang['s']; ?>" /><input type="hidden" name="track" value="<?php echo $trackingID; ?>" />
<i><?php echo $hesklang['nhid']; ?></i>
<input type="hidden" name="token" value="<?php hesk_token_echo(); ?>" />
<form method="post" action="admin_ticket.php" style="margin:0px; padding:0px;" enctype="multipart/form-data">
<div class="row" style="margin-bottom: 10px;">
<div class="col-md-7">
<h5><?php echo $hesklang['message']; ?></h5>
<div class="footerWithBorder" style="margin-bottom: 10px;"></div>
<textarea class="form-control" name="notemsg" rows="6" cols="60"></textarea>
</div>
<div class="col-md-5">
<h5><?php echo $hesklang['attachments']; ?></h5>
<div class="footerWithBorder" style="margin-bottom: 10px;"></div>
<span style="display: none" id="number-of-file-dialogs">2</span>
<div id="files-for-notes">
<input type="file" name="file[0]" style="margin-bottom: 5px;">
<input type="file" name="file[1]" style="margin-bottom: 5px;">
</div>
<a href="javascript:void(0)" onclick="addFileDialog('number-of-file-dialogs', 'files-for-notes')">
<?php echo $hesklang['add_row']; ?>
</a>
</div>
</div>
<div class="row">
<div class="col-md-12">
<input class="btn btn-default" type="submit" value="<?php echo $hesklang['s']; ?>" /><input type="hidden" name="track" value="<?php echo $trackingID; ?>" />
<i><?php echo $hesklang['nhid']; ?></i>
<input type="hidden" name="token" value="<?php hesk_token_echo(); ?>" />
</div>
</div>
</form>
</div>
</div>

8
js/nuMods-javascript.js

@ -61,4 +61,12 @@ function toggleNote(noteId, showForm) {
}
}
function addFileDialog(id, divId) {
var nextId = +($('#'+id).text());
$('#'+divId).append('<input type="file" name="files[' + nextId + ']" style="margin-bottom: 5px">');
$('#'+id).text(nextId+1);
}
jQuery(document).ready(loadJquery);

1
language/en/text.php

@ -31,6 +31,7 @@ $hesklang['can_change_notification_settings'] = 'Can change notification setting
$hesklang['note_edit_successful'] = 'Note edited';
$hesklang['note_last_edit'] = 'Note last edited on: %s'; // %s: timestamp of last edit
$hesklang['total_number_of_edits'] = 'Total number of edits: %s'; // %s: total number of edits
$hesklang['add_row'] = 'Add row';
// ADDED OR MODIFIED IN NuMods 1.5.0
$hesklang['ticket_auto_refresh'] = 'Ticket Table Auto-Refresh:';

Loading…
Cancel
Save