Initial Commit of AgileBill Open Source
This commit is contained in:
139
themes/default/blocks/ticket/add.tpl
Normal file
139
themes/default/blocks/ticket/add.tpl
Normal file
@@ -0,0 +1,139 @@
|
||||
|
||||
|
||||
<!-- Display the form validation -->
|
||||
{if $form_validation}
|
||||
{ $block->display("core:alert_fields") }
|
||||
{/if}
|
||||
|
||||
<!-- Display the form to collect the input values -->
|
||||
<form id="ticket_add" name="ticket_add" method="post" action="">
|
||||
|
||||
<table width=100% border="0" cellspacing="0" cellpadding="0" class="table_background">
|
||||
<tr>
|
||||
<td>
|
||||
<table width="100%" border="0" cellspacing="1" cellpadding="0">
|
||||
<tr valign="top">
|
||||
<td width="65%" class="table_heading">
|
||||
<div align="center">
|
||||
{translate module=ticket}
|
||||
title_add
|
||||
{/translate}
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<tr valign="top">
|
||||
<td width="65%" class="row1">
|
||||
<table width="100%" border="0" cellspacing="3" cellpadding="1" class="row1">
|
||||
<tr valign="top">
|
||||
<td width="35%">
|
||||
{translate module=ticket}
|
||||
field_priority
|
||||
{/translate}
|
||||
</td>
|
||||
<td width="65%">
|
||||
<select name="ticket_priority" >
|
||||
<option value="0" {if $VAR.ticket_priority == "0"}selected{/if}>
|
||||
{translate module=ticket}
|
||||
priority_standard
|
||||
{/translate}
|
||||
</option>
|
||||
<option value="1" {if $VAR.ticket_priority == "1"}selected{/if}>
|
||||
{translate module=ticket}
|
||||
priority_medium
|
||||
{/translate}
|
||||
</option>
|
||||
<option value="2" {if $VAR.ticket_priority == "2"}selected{/if}>
|
||||
{translate module=ticket}
|
||||
priority_high
|
||||
{/translate}
|
||||
</option>
|
||||
<option value="3" {if $VAR.ticket_priority == "3"}selected{/if}>
|
||||
{translate module=ticket}
|
||||
priority_emergency
|
||||
{/translate}
|
||||
</option>
|
||||
</select>
|
||||
</td>
|
||||
</tr>
|
||||
<tr valign="top">
|
||||
<td width="35%">
|
||||
{translate module=ticket}
|
||||
field_department_id
|
||||
{/translate}
|
||||
</td>
|
||||
<td width="65%">
|
||||
{ $list->menu("no", "ticket_department_id", "ticket_department", "name", $VAR.ticket_department_id, "form_menu") }
|
||||
</td>
|
||||
</tr>
|
||||
<tr valign="top">
|
||||
<td width="35%">
|
||||
{translate module=ticket}
|
||||
field_account_id
|
||||
{/translate}
|
||||
</td>
|
||||
<td width="65%">
|
||||
{html_select_account name="ticket_account_id" default=$VAR.ticket_account_id}
|
||||
</td>
|
||||
</tr>
|
||||
<tr valign="top">
|
||||
<td width="35%">
|
||||
{translate module=ticket}
|
||||
field_email
|
||||
{/translate}
|
||||
</td>
|
||||
<td width="65%">
|
||||
<input type="text" name="ticket_email" value="{$VAR.ticket_email}" {if $ticket_subject == true}class="form_field_error"{/if} size="32">
|
||||
</td>
|
||||
</tr>
|
||||
<tr valign="top">
|
||||
<td width="35%">
|
||||
{translate module=ticket}
|
||||
field_subject
|
||||
{/translate}
|
||||
</td>
|
||||
<td width="65%">
|
||||
<input type="text" name="ticket_subject" value="{$VAR.ticket_subject}" {if $ticket_subject == true}class="form_field_error"{/if} size="48">
|
||||
</td>
|
||||
</tr>
|
||||
<tr valign="top">
|
||||
<td width="35%">
|
||||
{translate module=ticket}
|
||||
field_body
|
||||
{/translate}
|
||||
</td>
|
||||
<td width="65%">
|
||||
<textarea name="ticket_body" cols="50" rows="10" {if $ticket_body == true}class="form_field_error"{/if}>{$VAR.ticket_body}</textarea>
|
||||
</td>
|
||||
</tr>
|
||||
{ $method->exe("ticket","static_var")}
|
||||
{ if ($method->result == FALSE) }
|
||||
{ $block->display("core:method_error") }
|
||||
{/if}
|
||||
{foreach from=$static_var item=record}
|
||||
<tr valign="top">
|
||||
<td width="29%">
|
||||
{$record.name}
|
||||
</td>
|
||||
<td width="71%">
|
||||
{$record.html}
|
||||
</td>
|
||||
</tr>
|
||||
{/foreach}
|
||||
<tr valign="top">
|
||||
<td width="35%"></td>
|
||||
<td width="65%">
|
||||
<input type="submit" name="Submit" value="{translate}submit{/translate}" class="form_button">
|
||||
<input type="hidden" name="_page" value="ticket:view">
|
||||
<input type="hidden" name="_page_current" value="ticket:add">
|
||||
<input type="hidden" name="do[]" value="ticket:add">
|
||||
<input type="hidden" name="ticket_status" value="0">
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</form>
|
112
themes/default/blocks/ticket/auth.tpl
Normal file
112
themes/default/blocks/ticket/auth.tpl
Normal file
@@ -0,0 +1,112 @@
|
||||
|
||||
<table width="100%" border="0" cellspacing="0" cellpadding="5" class="body">
|
||||
<tr>
|
||||
<td>
|
||||
<p><br>
|
||||
{translate module=ticket}
|
||||
user_ticket_auth
|
||||
{/translate}
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<table width="100%" border="0" cellspacing="0" cellpadding="5">
|
||||
<tr valign="top">
|
||||
<td width="50%">
|
||||
<form name="form2" method="get" action="">
|
||||
<table width="100%" border="0" cellspacing="5" cellpadding="1" class="body">
|
||||
<tr>
|
||||
<td width="25%">
|
||||
{translate module=ticket}
|
||||
field_email
|
||||
{/translate}
|
||||
</td>
|
||||
<td width="75%">
|
||||
<input type="text" name="email" value="{$VAR.email}" size="32">
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="25%">
|
||||
{translate module=ticket}
|
||||
key
|
||||
{/translate}
|
||||
</td>
|
||||
<td width="75%">
|
||||
<input type="text" name="key" value="{$VAR.key}" size="32">
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="25%">
|
||||
<input type="hidden" name="_page" value="{$VAR._page}">
|
||||
<input type="hidden" name="id" value="{$VAR.id}">
|
||||
</td>
|
||||
<td width="75%">
|
||||
<input type="submit" name="" value="{translate module=ticket}verify{/translate}" class="form_button">
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</form>
|
||||
</td>
|
||||
</tr>
|
||||
<tr valign="top">
|
||||
<td width="50%"> </td>
|
||||
</tr>
|
||||
<tr valign="top">
|
||||
<td width="50%">
|
||||
<form name="form1" method="post" action="">
|
||||
<table width="100%" border="0" cellspacing="1" cellpadding="0">
|
||||
<tr valign="top">
|
||||
<td width="65%" class="table_heading">
|
||||
<div align="center">
|
||||
{translate}
|
||||
account_login
|
||||
{/translate}
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<tr valign="top">
|
||||
<td width="65%" class="row1">
|
||||
<table width="100%" border="0" cellspacing="5" cellpadding="1" class="row1">
|
||||
<tr>
|
||||
<td width="25%">
|
||||
{translate}
|
||||
username
|
||||
{/translate}
|
||||
</td>
|
||||
<td width="75%">
|
||||
<input type="text" name="_username" value="{$VAR._username}" size="12">
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="25%">
|
||||
{translate}
|
||||
password
|
||||
{/translate}
|
||||
</td>
|
||||
<td width="75%">
|
||||
<input type="password" name="_password" size="12">
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="25%">
|
||||
<input type="hidden" name="_login" value="Y">
|
||||
<input type="hidden" name="_page2" value="{$VAR._page}">
|
||||
<input type="hidden" name="id2" value="{$VAR.id}">
|
||||
</td>
|
||||
<td width="75%">
|
||||
<input type="submit" name="_login2" value="{translate}login{/translate}" class="form_button">
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</form>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
2
themes/default/blocks/ticket/main.tpl
Normal file
2
themes/default/blocks/ticket/main.tpl
Normal file
@@ -0,0 +1,2 @@
|
||||
{$block->display("ticket:overview")}
|
||||
{$block->display("ticket:search_quick")}
|
104
themes/default/blocks/ticket/overview.tpl
Normal file
104
themes/default/blocks/ticket/overview.tpl
Normal file
@@ -0,0 +1,104 @@
|
||||
{$method->exe("ticket","overview")}
|
||||
{if ($method->result != FALSE)}
|
||||
|
||||
<table id="main1" width="100%" border="0" cellspacing="0" cellpadding="0" class="table_background">
|
||||
<form id="form1" name="form1" method="post" action="">
|
||||
<tr>
|
||||
<td>
|
||||
|
||||
<table id="main2" width="100%" border="0" cellspacing="1" cellpadding="1">
|
||||
<!-- DISPLAY THE SEARCH HEADING -->
|
||||
<tr valign="middle" align="center" class="table_heading">
|
||||
<td width="250" class="table_heading"> {translate module=ticket}field_department_id{/translate}</td>
|
||||
<td width="151" class="table_heading">{translate module=ticket}new{/translate}</td>
|
||||
<td width="175" class="table_heading"> {translate module=ticket}awaiting_reply{/translate}</td>
|
||||
<td width="152" class="table_heading">
|
||||
{translate module=ticket}
|
||||
awaiting_customer
|
||||
{/translate}
|
||||
</td>
|
||||
<td width="152" class="table_heading">
|
||||
{translate module=ticket}
|
||||
hold
|
||||
{/translate}
|
||||
</td>
|
||||
<td width="152" class="table_heading">
|
||||
{translate module=ticket}
|
||||
pending
|
||||
{/translate}
|
||||
</td>
|
||||
<td width="152" class="table_heading">
|
||||
{translate module=ticket}
|
||||
resolved
|
||||
{/translate}
|
||||
</td>
|
||||
<!-- LOOP THROUGH EACH RECORD -->
|
||||
{foreach from=$overview item=record}
|
||||
<tr id="row{$record.id}" class="{$record.class}">
|
||||
<td width="250">
|
||||
{$record.name}
|
||||
</td>
|
||||
<td width="151">
|
||||
{if $record.new > 0}
|
||||
<a href="javascript:searchTicketsStatus('{$record.id}', 'new')">
|
||||
{$record.new}
|
||||
</a>
|
||||
{else}
|
||||
{$record.new}
|
||||
{/if}
|
||||
</td>
|
||||
<td width="175">
|
||||
{if $record.waiting > 0}
|
||||
<a href="javascript:searchTicketsStatus('{$record.id}', 'staff')">
|
||||
{$record.waiting}
|
||||
</a>
|
||||
{else}
|
||||
{$record.waiting}
|
||||
{/if}
|
||||
</td>
|
||||
<td width="152">
|
||||
{if $record.customer > 0}
|
||||
<a href="javascript:searchTicketsStatus('{$record.id}', 'user')">
|
||||
{$record.customer}
|
||||
</a>
|
||||
{else}
|
||||
{$record.customer}
|
||||
{/if}
|
||||
</td>
|
||||
<td width="152">
|
||||
{if $record.hold > 0}
|
||||
<a href="javascript:searchTicketsStatus('{$record.id}', 'hold')">
|
||||
{$record.hold}
|
||||
</a>
|
||||
{else}
|
||||
{$record.hold}
|
||||
{/if}
|
||||
</td>
|
||||
<td width="152">
|
||||
{if $record.pending > 0}
|
||||
<a href="javascript:searchTicketsStatus('{$record.id}', 'pending')">
|
||||
{$record.pending}
|
||||
</a>
|
||||
{else}
|
||||
{$record.pending}
|
||||
{/if}
|
||||
</td>
|
||||
<td width="152">
|
||||
{if $record.resolved > 0}
|
||||
<a href="javascript:searchTicketsStatus('{$record.id}', 'closed')">
|
||||
{$record.resolved}
|
||||
</a>
|
||||
{else}
|
||||
{$record.resolved}
|
||||
{/if}
|
||||
</td>
|
||||
</tr>
|
||||
{/foreach}
|
||||
<!-- END OF RESULT LOOP -->
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</form>
|
||||
</table>
|
||||
<br>
|
||||
{/if}
|
222
themes/default/blocks/ticket/search_form.tpl
Normal file
222
themes/default/blocks/ticket/search_form.tpl
Normal file
@@ -0,0 +1,222 @@
|
||||
|
||||
{ $method->exe("ticket","search_form") }
|
||||
{ if ($method->result == FALSE) }
|
||||
{ $block->display("core:method_error") }
|
||||
{else}
|
||||
|
||||
<form name="ticket_search" method="post" action="">
|
||||
|
||||
<table width=100% border="0" cellspacing="0" cellpadding="0" class="table_background">
|
||||
<tr>
|
||||
<td>
|
||||
<table width="100%" border="0" cellspacing="1" cellpadding="0">
|
||||
<tr valign="top">
|
||||
<td width="65%" class="table_heading">
|
||||
<div align="center">
|
||||
{translate module=ticket}
|
||||
title_search
|
||||
{/translate}
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<tr valign="top">
|
||||
<td width="65%" class="row1">
|
||||
<table width="100%" border="0" cellspacing="3" cellpadding="1" class="row1">
|
||||
<tr valign="top">
|
||||
<td width="35%">
|
||||
{translate module=ticket}
|
||||
field_subject
|
||||
{/translate}
|
||||
</td>
|
||||
<td width="65%">
|
||||
<input type="text" name="ticket_subject" value="{$VAR.ticket_subject}" {if $ticket_subject == true}class="form_field_error"{/if}>
|
||||
{translate}
|
||||
search_partial
|
||||
{/translate}
|
||||
</td>
|
||||
</tr>
|
||||
<tr valign="top">
|
||||
<td width="35%">
|
||||
{translate module=ticket}
|
||||
field_body
|
||||
{/translate}
|
||||
</td>
|
||||
<td width="65%">
|
||||
<input type="text" name="ticket_body" value="{$VAR.ticket_body}" {if $ticket_body == true}class="form_field_error"{/if}>
|
||||
{translate}
|
||||
search_partial
|
||||
{/translate}
|
||||
</td>
|
||||
</tr>
|
||||
<tr valign="top">
|
||||
<td width="35%">
|
||||
{translate module=ticket}
|
||||
field_email
|
||||
{/translate}
|
||||
</td>
|
||||
<td width="65%">
|
||||
<input type="text" name="ticket_email" value="{$VAR.ticket_email}" {if $ticket_email == true}class="form_field_error"{/if}>
|
||||
{translate}
|
||||
search_partial
|
||||
{/translate}
|
||||
</td>
|
||||
</tr>
|
||||
<tr valign="top">
|
||||
<td width="35%">
|
||||
{translate module=ticket}
|
||||
field_status
|
||||
{/translate}
|
||||
</td>
|
||||
<td width="65%">
|
||||
<select name="ticket_status" >
|
||||
<option value=""></option>
|
||||
<option value="0" {if $VAR.ticket_priority == "0"}selected{/if}>
|
||||
{translate module=ticket}
|
||||
status_open
|
||||
{/translate}
|
||||
</option>
|
||||
<option value="1" {if $VAR.ticket_priority == "1"}selected{/if}>
|
||||
{translate module=ticket}
|
||||
status_hold
|
||||
{/translate}
|
||||
</option>
|
||||
<option value="2" {if $VAR.ticket_priority == "2"}selected{/if}>
|
||||
{translate module=ticket}
|
||||
status_close
|
||||
{/translate}
|
||||
</option>
|
||||
</select>
|
||||
</td>
|
||||
</tr>
|
||||
<tr valign="top">
|
||||
<td width="35%">
|
||||
{translate module=ticket}
|
||||
field_priority
|
||||
{/translate}
|
||||
</td>
|
||||
<td width="65%">
|
||||
<select name="ticket_priority" >
|
||||
<option value=""></option>
|
||||
<option value="0" {if $VAR.ticket_priority == "0"}selected{/if}>
|
||||
{translate module=ticket}
|
||||
priority_standard
|
||||
{/translate}
|
||||
</option>
|
||||
<option value="1" {if $VAR.ticket_priority == "1"}selected{/if}>
|
||||
{translate module=ticket}
|
||||
priority_medium
|
||||
{/translate}
|
||||
</option>
|
||||
<option value="2" {if $VAR.ticket_priority == "2"}selected{/if}>
|
||||
{translate module=ticket}
|
||||
priority_high
|
||||
{/translate}
|
||||
</option>
|
||||
<option value="3" {if $VAR.ticket_priority == "3"}selected{/if}>
|
||||
{translate module=ticket}
|
||||
priority_emergency
|
||||
{/translate}
|
||||
</option>
|
||||
</select>
|
||||
</td>
|
||||
</tr>
|
||||
<tr valign="top">
|
||||
<td width="35%">
|
||||
{translate module=ticket}
|
||||
field_department_id
|
||||
{/translate}
|
||||
</td>
|
||||
<td width="65%">
|
||||
{ $list->menu("", "ticket_department_id", "ticket_department", "name", "all", "form_menu") }
|
||||
</td>
|
||||
</tr>
|
||||
<tr valign="top">
|
||||
<td width="35%">
|
||||
{translate module=ticket}
|
||||
field_staff_id
|
||||
{/translate}
|
||||
</td>
|
||||
<td width="65%">
|
||||
{ $list->menu("", "ticket_staff_id", "staff", "nickname", "all", "form_menu") }
|
||||
</td>
|
||||
</tr>
|
||||
<tr valign="top">
|
||||
<td width="35%">
|
||||
{translate module=ticket}
|
||||
field_account_id
|
||||
{/translate}
|
||||
</td>
|
||||
<td width="65%">
|
||||
{html_select_account name="ticket_account_id" default=$VAR.ticket_account_id}
|
||||
</td>
|
||||
</tr>
|
||||
<tr valign="top">
|
||||
<td width="35%">
|
||||
{translate module=ticket}
|
||||
field_date_orig
|
||||
{/translate}
|
||||
</td>
|
||||
<td width="65%">
|
||||
{ $list->calender_search("ticket_date_orig", $VAR.ticket_date_orig, "form_field", "") }
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
{ $method->exe("ticket","static_var")}
|
||||
{foreach from=$static_var item=record}
|
||||
<tr valign="top">
|
||||
<td width="35%">
|
||||
{$record.name}
|
||||
</td>
|
||||
<td width="65%">
|
||||
{$record.html}
|
||||
</td>
|
||||
</tr>
|
||||
{/foreach}
|
||||
|
||||
<!-- Define the results per page -->
|
||||
<tr class="row1" valign="top">
|
||||
<td width="35%">
|
||||
{translate}
|
||||
search_results_per
|
||||
{/translate}
|
||||
</td>
|
||||
<td width="65%">
|
||||
<input type="text" name="limit" size="5" value="{$ticket_limit}">
|
||||
</td>
|
||||
</tr>
|
||||
<!-- Define the order by field per page -->
|
||||
<tr class="row1" valign="top">
|
||||
<td width="35%">
|
||||
{translate}
|
||||
search_order_by
|
||||
{/translate}
|
||||
</td>
|
||||
<td width="65%">
|
||||
<select name="order_by">
|
||||
{foreach from=$ticket item=record}
|
||||
<option value="{$record.field}"{if $record.field == $ticket_order_by} selected{/if}>
|
||||
{$record.translate}
|
||||
</option>
|
||||
{/foreach}
|
||||
</select>
|
||||
</td>
|
||||
</tr>
|
||||
<tr class="row1" valign="top">
|
||||
<td width="35%"></td>
|
||||
<td width="65%">
|
||||
<input type="submit" name="Submit" value="{translate}search{/translate}" class="form_button">
|
||||
<input type="hidden" name="_page" value="core:search">
|
||||
<input type="hidden" name="_next_page_one" value="view">
|
||||
<input type="hidden" name="_escape" value="1">
|
||||
<input type="hidden" name="module" value="ticket">
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</form>
|
||||
{/if}
|
169
themes/default/blocks/ticket/search_quick.tpl
Normal file
169
themes/default/blocks/ticket/search_quick.tpl
Normal file
@@ -0,0 +1,169 @@
|
||||
{literal}
|
||||
<style>
|
||||
div.results { padding:1px; border:1px solid #C5DEA1; border-bottom:0px;}
|
||||
div.results table { font-size:11px; }
|
||||
div.results table td { padding:2px; border-bottom:1px solid #C5DEA1; }
|
||||
</style>
|
||||
|
||||
<script language="javascript">
|
||||
|
||||
var http=getHTTPObject();
|
||||
var url=false;
|
||||
var popurl=false;
|
||||
|
||||
function viewTicket(id) {
|
||||
window.open('?_page=ticket:view_quick&_escape=1&id='+id, '_blank', 'toolbar=0,scrollbars=1,location=1,statusbar=1,menubar=1,resizable=0,width=700,height=800');
|
||||
}
|
||||
|
||||
function getCheckedValue(radioObj) {
|
||||
if(!radioObj)
|
||||
return "";
|
||||
var radioLength = radioObj.length;
|
||||
if(radioLength == undefined)
|
||||
if(radioObj.checked)
|
||||
return radioObj.value;
|
||||
else
|
||||
return "";
|
||||
for(var i = 0; i < radioLength; i++) {
|
||||
if(radioObj[i].checked) {
|
||||
return radioObj[i].value;
|
||||
}
|
||||
}
|
||||
return "";
|
||||
}
|
||||
|
||||
function refreshTicketSearch() {
|
||||
if(url!=false) {
|
||||
http.open("GET", url, true);
|
||||
http.onreadystatechange = function() {
|
||||
if (http.readyState == 4) {
|
||||
try { document.getElementById('results').innerHTML = http.responseText } catch(e) {}
|
||||
}
|
||||
}
|
||||
http.send(null);
|
||||
}
|
||||
}
|
||||
|
||||
function searchTicketsStatus(department,status) {
|
||||
url = 'index.php?do[]=ticket:search_status&_page=ticket:search_quick_show&_escape=1&department=' + department + '&status=' + status;
|
||||
http.open("GET", url, true);
|
||||
http.onreadystatechange = function() {
|
||||
if (http.readyState == 4) {
|
||||
try { document.getElementById('results').innerHTML = http.responseText } catch(e) {}
|
||||
}
|
||||
}
|
||||
http.send(null);
|
||||
}
|
||||
|
||||
function TicketRowDelete(id) {
|
||||
try { document.getElementById('ticket_id_'+id).style.display='none'; } catch(e) {}
|
||||
try { document.getElementById('ticket_id2_'+id).style.display='none'; } catch(e) {}
|
||||
}
|
||||
|
||||
function TicketDelete(id) {
|
||||
var urldel = 'index.php?_page=core:search&module=ticket&do[]=ticket:delete&_escape=1&delete_id=' + id;
|
||||
http.open("GET", urldel, true);
|
||||
http.onreadystatechange = function() {
|
||||
TicketRowDelete(id);
|
||||
}
|
||||
http.send(null);
|
||||
}
|
||||
|
||||
function searchTickets() {
|
||||
var query= document.getElementById('query').value;
|
||||
var query_type= getCheckedValue( document.forms['ticket_quick_search'].elements['query_type'] );
|
||||
var department= getCheckedValue( document.forms['ticket_quick_search'].elements['department'] );
|
||||
var status = getCheckedValue( document.forms['ticket_quick_search'].elements['status'] );
|
||||
searchTicketsVals(query,query_type,department,status);
|
||||
}
|
||||
|
||||
function searchTicketsVals(query,query_type,department,status) {
|
||||
url = 'index.php?do[]=ticket:search_quick&_page=ticket:search_quick_show&_escape=1';
|
||||
url += '&query=' + query;
|
||||
url += '&query_type=' + query_type;
|
||||
url += '&department=' + department;
|
||||
url += '&status=' + status;
|
||||
http.open("GET", url, true);
|
||||
http.onreadystatechange = function() {
|
||||
if (http.readyState == 4) {
|
||||
try { document.getElementById('results').innerHTML = http.responseText } catch(e) {}
|
||||
}
|
||||
}
|
||||
http.send(null);
|
||||
}
|
||||
</script>
|
||||
{/literal}
|
||||
|
||||
<form name="ticket_quick_search" method="post" action="javascript:void(0);" onSubmit="searchTickets()">
|
||||
<table width=100% border="0" cellspacing="0" cellpadding="0" class="table_background">
|
||||
<tr>
|
||||
<td>
|
||||
<table width="100%" border="0" cellspacing="1" cellpadding="0">
|
||||
<tr valign="top">
|
||||
<td width="65%" class="table_heading">
|
||||
<div align="center">
|
||||
{translate module=ticket}
|
||||
title_search
|
||||
{/translate}
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<tr valign="top">
|
||||
<td width="65%" class="row1">
|
||||
<table width="100%" border="0" cellspacing="3" cellpadding="1" class="row1">
|
||||
<tr valign="top">
|
||||
<td width="18%">
|
||||
Text/User Query </td>
|
||||
<td width="82%">
|
||||
<input id="query" name="query" type="text" value="{$VAR.query}" size="35" {if $ticket_subject == true}class="form_field_error"{/if}>
|
||||
<input name="query_type" type="radio" value="all" checked>
|
||||
All
|
||||
<input name="query_type" type="radio" value="sender">
|
||||
Sender Only
|
||||
<input name="query_type" type="radio" value="text">
|
||||
Text Only
|
||||
</td>
|
||||
</tr>
|
||||
<tr valign="top">
|
||||
<td width="18%">
|
||||
{translate module=ticket}field_department_id{/translate}</td>
|
||||
<td width="82%">
|
||||
<input name="department" type="radio" value="all" checked>
|
||||
All
|
||||
{foreach from=$overview item=record}
|
||||
<input name="department" type="radio" value="{$record.id}">
|
||||
{$record.name}
|
||||
{/foreach}
|
||||
</td>
|
||||
</tr>
|
||||
<tr class="row1" valign="top">
|
||||
<td width="18%">Status</td>
|
||||
<td width="82%">
|
||||
<input name="status" type="radio" value="all" checked> All
|
||||
<input name="status" type="radio" value="0"> {translate module=ticket} status_open {/translate}
|
||||
<input name="status" type="radio" value="2"> {translate module=ticket} status_close {/translate}
|
||||
<input name="status" type="radio" value="1"> {translate module=ticket} status_pending {/translate}
|
||||
<input name="status" type="radio" value="3"> {translate module=ticket} status_hold {/translate}
|
||||
</td>
|
||||
</tr>
|
||||
<tr class="row1" valign="top">
|
||||
<td><input type="button" name="Submit" value="{translate}search{/translate}" onClick="searchTickets()"></td>
|
||||
<td> <input type="hidden" name="_page" value="ticket:search_quick_show">
|
||||
<input type="hidden" name="do[]" value="ticket:search_quick"></td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</form>
|
||||
|
||||
<div id="results"></div>
|
||||
|
||||
{if $VAR.department && $VAR.status && $VAR.query==''}
|
||||
<script language="javascript">searchTicketsStatus('{$VAR.department}','{$VAR.status}');</script>
|
||||
{elseif $VAR.department && $VAR.status && $VAR.query}
|
||||
<script language="javascript">searchTicketsVals('{$VAR.query}','{$VAR.query_type}','{$VAR.department}','{$VAR.status}');</script>
|
||||
{/if}
|
32
themes/default/blocks/ticket/search_quick_show.tpl
Normal file
32
themes/default/blocks/ticket/search_quick_show.tpl
Normal file
@@ -0,0 +1,32 @@
|
||||
<form action="" method="get">
|
||||
<h3>Found {$count} Record(s)...</h3>
|
||||
{if $count > 0}
|
||||
<div class="results">
|
||||
<table width="100%" border="0" cellspacing="0">
|
||||
{foreach from=$results item=ticket}
|
||||
<tr id="ticket_id_{$ticket.id}">
|
||||
<td align="left" valign="top" width="150"><div style="overflow:hidden"><b>{$ticket.email}</b></div></td>
|
||||
<td align="left" valign="top" width="350">
|
||||
<div style="overflow:hidden">
|
||||
<font color="#{if $ticket.status==1}CC9900{elseif $ticket.status==2}666666{elseif $ticket.status==3}0099CC{else}990000{/if}">
|
||||
<b>{$ticket.subject}</b>
|
||||
</font>
|
||||
</div>
|
||||
</td>
|
||||
<td align="right" valign="top" width="200">{$ticket.department} | {$list->date($ticket.date_orig)}</td>
|
||||
</tr>
|
||||
<tr id="ticket_id2_{$ticket.id}">
|
||||
<td colspan="2" align="left" valign="top"><font color="#666666"> {$ticket.body|truncate:115:"..."}</font></span></td>
|
||||
<td align="right" valign="top">
|
||||
<a href="?_page=ticket:view_quick&_escape=1&id={$ticket.id}" target="_blank">View</a> |
|
||||
<a href="?_page=ticket:main&do[]=ticket:delete&delete_id={$ticket.id}&department={$VAR.department}&status={$VAR.status}&query={$VAR.query}&query_type={$VAR.query_type}">Delete</a>
|
||||
</td>
|
||||
</tr>
|
||||
{/foreach}
|
||||
</table>
|
||||
</div>
|
||||
{/if}
|
||||
<input type="hidden" name="_page" value="ticket:main">
|
||||
<input type="hidden" name="url" value="{$VAR.url}">
|
||||
<input type="hidden" name="do[]" value="ticket">
|
||||
</form>
|
140
themes/default/blocks/ticket/search_show.tpl
Normal file
140
themes/default/blocks/ticket/search_show.tpl
Normal file
@@ -0,0 +1,140 @@
|
||||
|
||||
{$method->exe("ticket","search_show")}
|
||||
{if ($method->result == FALSE)}
|
||||
{$block->display("core:method_error")}
|
||||
{else}
|
||||
{if $results == 1}
|
||||
{translate results=$results}search_result_count{/translate}
|
||||
{else}
|
||||
{translate results=$results}search_results_count{/translate}
|
||||
{/if}
|
||||
<BR>
|
||||
|
||||
|
||||
{literal}
|
||||
<script language="JavaScript">
|
||||
<!-- START
|
||||
var module = 'ticket';
|
||||
{/literal}
|
||||
{if $VAR._print == TRUE}
|
||||
var p = '&_escape=y&_print=y';
|
||||
{else}
|
||||
var p = '';
|
||||
{/if}{literal}
|
||||
var IMAGE = '{/literal}{$NONSSL_IMAGE}{literal}';
|
||||
var order = '{/literal}{$order}{literal}';
|
||||
var sort1 = '{/literal}{$sort}{literal}';
|
||||
var search_id = '{/literal}{$search_id}{literal}';
|
||||
var page = {/literal}{$page}{literal};
|
||||
var pages = '{/literal}{$pages}{literal}';
|
||||
var results = '{/literal}{$results}{literal}';
|
||||
var limit = '{/literal}{$limit}{literal}';
|
||||
record_arr = new Array ({/literal}{$limit}{literal});
|
||||
var i = 0;
|
||||
// END -->
|
||||
</script>
|
||||
<SCRIPT SRC="themes/{/literal}{$THEME_NAME}{literal}/search.js"></SCRIPT>
|
||||
{/literal}
|
||||
|
||||
<!-- SHOW THE SEARCH NAVIGATION MENU -->
|
||||
<center><script language="JavaScript">document.write(search_nav_top());</script></center>
|
||||
|
||||
<!-- BEGIN THE RESULTS CONTENT AREA -->
|
||||
<div id="search_results" onKeyPress="key_handler(event);">
|
||||
<table id="main1" width="100%" border="0" cellspacing="0" cellpadding="0" class="table_background">
|
||||
<form id="form1" name="form1" method="post" action="">
|
||||
<tr>
|
||||
<td>
|
||||
<table id="main2" width="100%" border="0" cellspacing="1" cellpadding="2">
|
||||
<!-- DISPLAY THE SEARCH HEADING -->
|
||||
<tr valign="middle" align="center" class="table_heading">
|
||||
<td width="40" class="table_heading"> </td>
|
||||
<td width="250" class="table_heading">
|
||||
{literal}
|
||||
<script language="JavaScript">
|
||||
document.write(search_heading('{/literal}{translate module=ticket}field_subject{/translate}{literal}','subject'));
|
||||
</script>
|
||||
{/literal}
|
||||
</td>
|
||||
<td width="151" class="table_heading">
|
||||
{literal}
|
||||
<script language="JavaScript">
|
||||
document.write(search_heading('{/literal}{translate module=ticket}field_account_id{/translate}{literal}','account_id'));
|
||||
</script>
|
||||
{/literal}
|
||||
</td>
|
||||
<td width="175" class="table_heading">
|
||||
{literal}
|
||||
<script language="JavaScript">
|
||||
document.write(search_heading('{/literal}{translate module=ticket}field_staff_id{/translate}{literal}','staff_id'));
|
||||
</script>
|
||||
{/literal}
|
||||
</td>
|
||||
<td width="152" class="table_heading">
|
||||
{literal}
|
||||
<script language="JavaScript">
|
||||
document.write(search_heading('{/literal}{translate module=ticket}field_department_id{/translate}{literal}','department_id'));
|
||||
</script>
|
||||
{/literal}
|
||||
</td>
|
||||
<td width="35" class="table_heading"> </td>
|
||||
<!-- LOOP THROUGH EACH RECORD -->
|
||||
{foreach from=$ticket item=record}
|
||||
<tr id="row{$record.id}" onClick="row_sel('{$record.id}',1);" onDblClick="window.location='?_page=ticket:view&id={$record.id},';" onMouseOver="row_mouseover('{$record.id}', 'row_mouse_over_select', 'row_mouse_over');" onMouseOut="row_mouseout('{$record.id}', '{$record._C}', 'row_select');" class="{$record._C}">
|
||||
<td align="center" width="40">
|
||||
<input type="checkbox" name="record{$record.id}" value="{$record.id}" onClick="row_sel('{$record.id}',1,'{$record._C}');">
|
||||
</td>
|
||||
<td width="250">
|
||||
{$record.subject|truncate:35}
|
||||
</td>
|
||||
<td width="151">
|
||||
{if $record.account_id == false}
|
||||
{$record.email}
|
||||
{else}
|
||||
{$record.account_id}
|
||||
{/if}
|
||||
</td>
|
||||
<td width="175">
|
||||
{if $record.staff_id != ""}
|
||||
{$record.staff_id}
|
||||
{else}
|
||||
---
|
||||
{/if}
|
||||
</td>
|
||||
<td width="152">
|
||||
{$record.department_id}
|
||||
</td>
|
||||
<td width="35">
|
||||
{ if $record.status == '0' }
|
||||
<img src="themes/{$THEME_NAME}/images/icons/go_16.gif" border="0">
|
||||
{ elseif $record.status == '1' }
|
||||
<img src="themes/{$THEME_NAME}/images/icons/timer_16.gif" border="0">
|
||||
{ elseif $record.status == '2' }
|
||||
<img src="themes/{$THEME_NAME}/images/icons/trash_16.gif" border="0">
|
||||
{ elseif $record.status == '3' }
|
||||
<img src="themes/{$THEME_NAME}/images/icons/stop_16.gif" border="0">
|
||||
{ /if }
|
||||
</td>
|
||||
</tr>
|
||||
{literal}
|
||||
<script language="JavaScript">row_sel('{/literal}{$record.id}{literal}', 0, '{/literal}{$record._C}{literal}'); record_arr[i] = '{/literal}{$record.id}{literal}'; i++; </script>
|
||||
{/literal}
|
||||
{/foreach}
|
||||
<!-- END OF RESULT LOOP -->
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</form>
|
||||
</table>
|
||||
{if $VAR._print != TRUE}<br>
|
||||
<center>
|
||||
<input type="submit" name="Submit" value="{translate}view_edit{/translate}" onClick="mass_do('', module+':view', limit, module);" class="form_button">
|
||||
<input type="submit" name="Submit" value="{translate}delete{/translate}" onClick="mass_do('delete', module+':search_show&search_id={$search_id}&page={$page}&order_by={$order}&{$sort}', limit, module);" class="form_button">
|
||||
<input type="submit" name="Submit" value="{translate}select_all{/translate}" onClick="all_select(record_arr);" class="form_button">
|
||||
<input type="submit" name="Submit" value="{translate}deselect_all{/translate}" onClick="all_deselect(record_arr);" class="form_button">
|
||||
<input type="submit" name="Submit" value="{translate}range_select{/translate}" onClick="all_range_select(record_arr,limit);" class="form_button">
|
||||
<br>
|
||||
</center>
|
||||
{/if}
|
||||
{/if}
|
||||
</div>
|
185
themes/default/blocks/ticket/ticket.tpl
Normal file
185
themes/default/blocks/ticket/ticket.tpl
Normal file
@@ -0,0 +1,185 @@
|
||||
|
||||
{ $method->exe("ticket","is_user_auth")} { if ($method->result == FALSE) } { $block->display("core:method_error") } {/if}
|
||||
{if $display == true}
|
||||
<form name="form1" method="post" action="">
|
||||
<table width=100% border="0" cellspacing="0" cellpadding="0" class="table_background">
|
||||
<tr>
|
||||
<td>
|
||||
<table width="100%" border="0" cellspacing="1" cellpadding="0">
|
||||
<tr valign="top">
|
||||
<td width="65%" class="table_heading">
|
||||
<div align="center">
|
||||
{translate module=ticket}
|
||||
menu_add
|
||||
{/translate}
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<tr valign="top">
|
||||
<td width="65%" class="row1">
|
||||
<table width="100%" border="0" cellspacing="1" cellpadding="0" align="center">
|
||||
<tr>
|
||||
<td class="row1">
|
||||
<table width="100%" border="0" cellpadding="3" class=row1>
|
||||
<tr>
|
||||
<td width="60%">
|
||||
{translate module=ticket}
|
||||
user_select_department
|
||||
{/translate}
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="60%">
|
||||
<p>
|
||||
{foreach from=$results item=record}
|
||||
<table width="100%" border="0" cellpadding="1" class="row1">
|
||||
<tr>
|
||||
<td width="8%"">
|
||||
<input type="radio" name="ticket_department_id" value="{$record.id}" checked>
|
||||
</td>
|
||||
<td width="92%"> <b>
|
||||
{$record.name}
|
||||
</b> </td>
|
||||
</tr>
|
||||
<tr class="row1">
|
||||
<td width="8%"> </td>
|
||||
<td width="92%">
|
||||
{$record.description}
|
||||
<br>
|
||||
</td>
|
||||
</tr>
|
||||
{/foreach}
|
||||
<tr class="row1">
|
||||
<td width="8%"></td>
|
||||
<td width="92%">
|
||||
<div align="right">
|
||||
<input type="submit" name="Submit" value="{translate}submit{/translate}" class="form_button">
|
||||
<input type="hidden" name="_page" value="ticket:user_add">
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</form>
|
||||
<p>{else}</p>
|
||||
<p>
|
||||
{translate module=ticket}
|
||||
user_not_auth_add
|
||||
{/translate}
|
||||
</p>
|
||||
<p>
|
||||
{/if}
|
||||
{ $method->exe("ticket","user_list")}
|
||||
{ if ($method->result == FALSE) }
|
||||
{ $block->display("core:method_error") }
|
||||
{/if}
|
||||
|
||||
{$method->exe("ticket","is_key_match")}
|
||||
{if $ticket_key == true}
|
||||
{if $ticket_results != false}
|
||||
<table width=100% border="0" cellspacing="0" cellpadding="0" class="table_background">
|
||||
<tr>
|
||||
<td>
|
||||
<table width="100%" border="0" cellspacing="1" cellpadding="0">
|
||||
<tr valign="top">
|
||||
<td width="65%" class="table_heading">
|
||||
<div align="center">
|
||||
{translate module=ticket}
|
||||
menu_view
|
||||
{/translate}
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<tr valign="top">
|
||||
<td width="65%" class="row1">
|
||||
<table width="100%" border="0" cellpadding="3" class=row1>
|
||||
<tr>
|
||||
<td width="60%">
|
||||
{translate module=ticket}
|
||||
user_ticket_list
|
||||
{/translate}
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="60%">
|
||||
<p>
|
||||
<table width="100%" border="0" cellpadding="1" class="row2">
|
||||
<tr>
|
||||
<td width="61%"> <u> <b>
|
||||
{translate}
|
||||
field_subject
|
||||
{/translate}
|
||||
</b></u></td>
|
||||
<td width="29%"> <u> <b>
|
||||
{translate}
|
||||
field_date_last
|
||||
{/translate}
|
||||
</b></u></td>
|
||||
<td width="10%"> <u> </u><u><b>
|
||||
{translate}
|
||||
field_status
|
||||
{/translate}
|
||||
</b></u></td>
|
||||
</tr>
|
||||
{foreach from=$ticket_results item=record}
|
||||
</table>
|
||||
<table width="100%" border="0" cellpadding="1" class="row2">
|
||||
<tr>
|
||||
<td width="61%"> <a href="?_page=ticket:user_view&id={$record.id}{if $VAR.key != "" && $VAR.email != ""}&email={$VAR.email}&key={$VAR.key}{/if}"><font color="#000000">
|
||||
<b>
|
||||
{$record.subject|truncate:40}
|
||||
</b></font></a> </td>
|
||||
<td width="29%">
|
||||
{ $list->date_time($record.date_orig)}
|
||||
</td>
|
||||
<td width="10%">
|
||||
{ if $record.status == '0' }
|
||||
{translate module=ticket}
|
||||
status_open
|
||||
{/translate}
|
||||
{ elseif $record.status == '1' }
|
||||
{translate module=ticket}
|
||||
status_hold
|
||||
{/translate}
|
||||
{ elseif $record.status == '2' }
|
||||
{translate module=ticket}
|
||||
status_close
|
||||
{/translate}
|
||||
{ elseif $record.status == '3' }
|
||||
{translate module=ticket}
|
||||
status_hold
|
||||
{/translate}
|
||||
{ /if }
|
||||
</td>
|
||||
</tr>
|
||||
{/foreach}
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
{else}
|
||||
{translate module=ticket}
|
||||
user_no_existing_ticket
|
||||
{/translate}
|
||||
{/if}
|
||||
|
||||
{else}
|
||||
{ $block->display("ticket:auth")}
|
||||
{/if}
|
51
themes/default/blocks/ticket/user.tpl
Normal file
51
themes/default/blocks/ticket/user.tpl
Normal file
@@ -0,0 +1,51 @@
|
||||
<table width="200" border="0" cellspacing="0" cellpadding="0" class="body">
|
||||
<tr>
|
||||
<td valign="top" align="center" width="35%">
|
||||
<table width="100%" border="0" cellspacing="0" cellpadding="0">
|
||||
<tr>
|
||||
<td>
|
||||
<table width="100%" border="0" cellspacing="0" cellpadding="0" class="table_background">
|
||||
<tr>
|
||||
<td>
|
||||
<table width="100%" border="0" cellspacing="1" cellpadding="0">
|
||||
<tr valign="top">
|
||||
<td width="65%" class="table_heading">
|
||||
<div align="center">
|
||||
{translate module=ticket}
|
||||
menu
|
||||
{/translate}
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<tr valign="top">
|
||||
<td width="65%" class="row1">
|
||||
<table width="100%" border="0" cellspacing="5" cellpadding="1" class="row1">
|
||||
<tr>
|
||||
<td width="74%"> Create New Ticket</td>
|
||||
<td width="26%" align="right"> <a href="{$SSL_URL}?_page=ticket:ticket">
|
||||
{translate module=ticket}
|
||||
menu_add
|
||||
{/translate}
|
||||
</a> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="74%"> Manage Tickets </td>
|
||||
<td width="26%" align="right"> <a href="{$SSL_URL}?_page=ticket:ticket">
|
||||
{translate module=ticket}
|
||||
menu_view
|
||||
{/translate}
|
||||
</a></td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
142
themes/default/blocks/ticket/user_add.tpl
Normal file
142
themes/default/blocks/ticket/user_add.tpl
Normal file
@@ -0,0 +1,142 @@
|
||||
<!-- Display the form validation -->
|
||||
{if $form_validation}
|
||||
{ $block->display("core:alert_fields") }
|
||||
{/if}
|
||||
|
||||
{ $method->exe("ticket","is_user_auth")}
|
||||
{ if ($method->result == FALSE) } { $block->display("core:method_error") } {/if}
|
||||
|
||||
{if $display == true}
|
||||
{if $VAR.ticket_department_id == ''}
|
||||
{translate module=ticket}
|
||||
user_department_required
|
||||
{/translate}
|
||||
{else}
|
||||
<form name="form1" method="post" action="">
|
||||
<table width=100% border="0" cellspacing="0" cellpadding="0" class="table_background">
|
||||
<tr>
|
||||
<td>
|
||||
<table width="100%" border="0" cellspacing="1" cellpadding="0">
|
||||
<tr valign="top">
|
||||
<td width="65%" class="table_heading">
|
||||
<div align="center">
|
||||
{translate module=ticket}
|
||||
title_add
|
||||
{/translate}
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<tr valign="top">
|
||||
<td width="65%" class="row1">
|
||||
<table width="100%" border="0" cellspacing="3" cellpadding="1" class="row1">
|
||||
<tr valign="top">
|
||||
<td width="29%">
|
||||
{translate module=ticket}
|
||||
field_priority
|
||||
{/translate}
|
||||
</td>
|
||||
<td width="71%">
|
||||
<select name="ticket_priority">
|
||||
<option value="0">
|
||||
{translate module=ticket}
|
||||
priority_standard
|
||||
{/translate}
|
||||
</option>
|
||||
<option value="1">
|
||||
{translate module=ticket}
|
||||
priority_medium
|
||||
{/translate}
|
||||
</option>
|
||||
<option value="2">
|
||||
{translate module=ticket}
|
||||
priority_high
|
||||
{/translate}
|
||||
</option>
|
||||
<option value="3">
|
||||
{translate module=ticket}
|
||||
priority_emergency
|
||||
{/translate}
|
||||
</option>
|
||||
</select>
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
{if $smarty.const.SESS_LOGGED == false}
|
||||
<tr valign="top">
|
||||
<td width="29%">
|
||||
{translate module=ticket}
|
||||
field_email
|
||||
{/translate}
|
||||
</td>
|
||||
<td width="71%">
|
||||
<input type="text" name="ticket_email" value="{$VAR.ticket_email}" {if $ticket_email == true}class="form_field_error"{/if} size="43" maxlength="255">
|
||||
</td>
|
||||
</tr>
|
||||
{/if}
|
||||
|
||||
|
||||
<tr valign="top">
|
||||
<td width="29%">
|
||||
{translate module=ticket}
|
||||
field_subject
|
||||
{/translate}
|
||||
</td>
|
||||
<td width="71%">
|
||||
<input type="text" name="ticket_subject" value="{$VAR.ticket_subject}" {if $ticket_subject == true}class="form_field_error"{/if} size="43" maxlength="255">
|
||||
</td>
|
||||
</tr>
|
||||
<tr valign="top">
|
||||
<td width="29%">
|
||||
{translate module=ticket}
|
||||
field_body
|
||||
{/translate}
|
||||
</td>
|
||||
<td width="71%">
|
||||
<textarea name="ticket_body" cols="50" rows="10" {if $ticket_body == true}class="form_field_error"{/if}>{$VAR.ticket_body}</textarea>
|
||||
</td>
|
||||
</tr>
|
||||
{ $method->exe("ticket","static_var")}
|
||||
{ if ($method->result == FALSE) }
|
||||
{ $block->display("core:method_error") }
|
||||
{/if}
|
||||
{foreach from=$static_var item=record}
|
||||
<tr valign="top">
|
||||
<td width="29%">
|
||||
{$record.name}
|
||||
</td>
|
||||
<td width="71%">
|
||||
{$record.html}
|
||||
</td>
|
||||
</tr>
|
||||
{/foreach}
|
||||
<tr valign="top">
|
||||
<td width="29%"></td>
|
||||
<td width="71%">
|
||||
<input type="submit" name="Submit" value="{translate}submit{/translate}" class="form_button">
|
||||
<input type="hidden" name="_page" value="ticket:ticket">
|
||||
<input type="hidden" name="_page_current" value="ticket:user_add">
|
||||
<input type="hidden" name="do[]" value="ticket:user_add">
|
||||
<input type="hidden" name="ticket_department_id" value="{$VAR.ticket_department_id}">
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</form>
|
||||
|
||||
|
||||
|
||||
{/if}
|
||||
{else}
|
||||
<p>
|
||||
{translate module=ticket}
|
||||
user_not_auth_add
|
||||
{/translate}
|
||||
<p>
|
||||
{ $block->display("ticket:auth")}
|
||||
{/if}
|
||||
|
330
themes/default/blocks/ticket/user_view.tpl
Normal file
330
themes/default/blocks/ticket/user_view.tpl
Normal file
@@ -0,0 +1,330 @@
|
||||
{ $method->exe("ticket","user_view") }
|
||||
{ if ($method->result == FALSE) } { $block->display("core:method_error") } {/if}
|
||||
|
||||
<!-- Display the field validation -->
|
||||
{if $ticket != false}
|
||||
|
||||
{ if $ticket.status == '3' && $smarty.const.SESS_LOGGED == false }
|
||||
<form name="form1" method="post" action="">
|
||||
{translate module=ticket}
|
||||
user_pending_verify
|
||||
{/translate}
|
||||
<br>
|
||||
<br>
|
||||
<table width="100%" border="0" cellspacing="1" cellpadding="0">
|
||||
<tr valign="top">
|
||||
<td width="65%" class="table_heading">
|
||||
<div align="center">
|
||||
{translate}
|
||||
account_login
|
||||
{/translate}
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<tr valign="top">
|
||||
<td width="65%" class="row1">
|
||||
<table width="100%" border="0" cellspacing="5" cellpadding="1" class="row1">
|
||||
<tr>
|
||||
<td width="25%">
|
||||
{translate}
|
||||
username
|
||||
{/translate}
|
||||
</td>
|
||||
<td width="75%">
|
||||
<input type="text" name="_username" value="{$VAR._username}" size="12">
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="25%">
|
||||
{translate}
|
||||
password
|
||||
{/translate}
|
||||
</td>
|
||||
<td width="75%">
|
||||
<input type="password" name="_password" size="12">
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="25%">
|
||||
<input type="hidden" name="_login" value="Y">
|
||||
<input type="hidden" name="_page" value="{$VAR._page}">
|
||||
<input type="hidden" name="id" value="{$VAR.id}">
|
||||
</td>
|
||||
<td width="75%">
|
||||
<input type="submit" name="submit" value="{translate}login{/translate}" class="form_button">
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</form>
|
||||
{elseif $ticket.status == '3' && $smarty.const.SESS_LOGGED == true}
|
||||
{ $method->exe("ticket","pending_verify") }
|
||||
{$pending_status}
|
||||
{else}
|
||||
<!-- Display each record -->
|
||||
<form name="form1" method="post" action="">
|
||||
<table width=100% border="0" cellspacing="0" cellpadding="0" class="table_background">
|
||||
<tr>
|
||||
<td>
|
||||
<table width="100%" border="0" cellspacing="1" cellpadding="0">
|
||||
<tr valign="top">
|
||||
<td width="65%" class="table_heading">
|
||||
<div align="center">
|
||||
{translate module=ticket}
|
||||
title_view
|
||||
{/translate}
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<tr valign="top">
|
||||
<td width="65%" class="row1">
|
||||
<table width="100%" border="0" cellspacing="4" cellpadding="1" class="row1">
|
||||
<tr valign="top" class="row1">
|
||||
<td width="20%">
|
||||
{translate module=ticket}
|
||||
field_date_last
|
||||
{/translate}
|
||||
</td>
|
||||
<td width="80%">
|
||||
{$list->date_time($ticket.date_last)}
|
||||
</td>
|
||||
</tr>
|
||||
<tr valign="top" class="row1">
|
||||
<td width="20%">
|
||||
{translate module=ticket}
|
||||
field_status
|
||||
{/translate}
|
||||
</td>
|
||||
<td width="80%" class="row1">
|
||||
{ if $ticket.status == '0' }
|
||||
{translate module=ticket}
|
||||
status_open
|
||||
{/translate}
|
||||
{ elseif $ticket.status == '1' }
|
||||
{translate module=ticket}
|
||||
status_hold
|
||||
{/translate}
|
||||
{ elseif $ticket.status == '2' }
|
||||
{translate module=ticket}
|
||||
status_close
|
||||
{/translate}
|
||||
{ elseif $ticket.status == '3' }
|
||||
<b> <font color="#990000">
|
||||
{translate module=ticket}
|
||||
status_pending
|
||||
{/translate}
|
||||
</font></b>
|
||||
{ /if }
|
||||
</td>
|
||||
</tr>
|
||||
<tr valign="top" class="row1">
|
||||
<td width="20%">
|
||||
{translate module=ticket}
|
||||
field_priority
|
||||
{/translate}
|
||||
</td>
|
||||
<td width="80%">
|
||||
{ if $ticket.priority == '0' }
|
||||
{translate module=ticket}
|
||||
priority_standard
|
||||
{/translate}
|
||||
{ elseif $ticket.priority == '1' }
|
||||
{translate module=ticket}
|
||||
priority_medium
|
||||
{/translate}
|
||||
{ elseif $ticket.priority == '2' }
|
||||
{translate module=ticket}
|
||||
priority_high
|
||||
{/translate}
|
||||
{ elseif $ticket.priority == '3' }
|
||||
{translate module=ticket}
|
||||
priority_emergency
|
||||
{/translate}
|
||||
{ /if }
|
||||
</td>
|
||||
</tr>
|
||||
{if $show_static_var != false}
|
||||
{foreach from=$static_var item=record}
|
||||
<tr valign="top" class="row1">
|
||||
<td width="20%">
|
||||
{$record.name}
|
||||
</td>
|
||||
<td width="80%">
|
||||
{$record.html}
|
||||
</td>
|
||||
</tr>
|
||||
{/foreach}
|
||||
{/if}
|
||||
{ if $ticket.status != "2" }
|
||||
<tr valign="top" class="row1">
|
||||
<td width="20%"> </td>
|
||||
<td width="80%">
|
||||
<div align="right">
|
||||
<input type="hidden" name="email" value="{$VAR.email}">
|
||||
<input type="hidden" name="key" value="{$VAR.key}">
|
||||
<input type="hidden" name="ticket_status" value="2">
|
||||
<input type="hidden" name="_page" value="ticket:user_view">
|
||||
<input type="hidden" name="id" value="{$ticket.id}">
|
||||
<input type="hidden" name="do[]" value="ticket:user_update">
|
||||
<input type="submit" name="Submit" value="{translate module=ticket}close_ticket{/translate}" class="form_button">
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
{/if}
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</form>
|
||||
<table width=100% border="0" cellspacing="0" cellpadding="1" class="table_background">
|
||||
<tr>
|
||||
<td>
|
||||
<table width="100%" border="0" cellspacing="4" cellpadding="1" class="row1">
|
||||
<tr valign="top">
|
||||
<td width="20%"> </td>
|
||||
<td width="80%" valign="top" align="right">
|
||||
{$list->date_time($ticket.date_orig)}
|
||||
</td>
|
||||
</tr>
|
||||
<tr valign="top" class="row1">
|
||||
<td width="20%">
|
||||
{translate module=ticket}
|
||||
field_subject
|
||||
{/translate}
|
||||
</td>
|
||||
<td width="80%">
|
||||
{$ticket.subject}
|
||||
</td>
|
||||
</tr>
|
||||
<tr valign="top" class="row1">
|
||||
<td width="20%">
|
||||
{translate module=ticket}
|
||||
field_body
|
||||
{/translate}
|
||||
</td>
|
||||
<td width="80%">
|
||||
{$ticket.body|linkalize|replace:"
|
||||
":"<br>"}
|
||||
</td>
|
||||
</tr>
|
||||
{if $show_static_var != false}
|
||||
{foreach from=$static_var item=record}
|
||||
{/foreach}
|
||||
{/if}
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
<br>
|
||||
{if $ticket_reply != false}
|
||||
{foreach from=$ticket_reply item=reply}
|
||||
<table width=100% border="0" cellspacing="0" cellpadding="1" class="table_background">
|
||||
<tr>
|
||||
<td>
|
||||
<table width="100%" border="0" cellspacing="4" cellpadding="1" class="row1">
|
||||
<tr valign="top">
|
||||
<td width="20%"> </td>
|
||||
<td width="80%" valign="top" align="right">
|
||||
{if $reply.staff_id > 1 }
|
||||
<b>
|
||||
{$list->date_time($reply.date_orig)}
|
||||
</b>
|
||||
{else}
|
||||
{$list->date_time($reply.date_orig)}
|
||||
{/if}
|
||||
</td>
|
||||
</tr>
|
||||
<tr valign="top" class="row1">
|
||||
<td width="20%">
|
||||
{if $reply.staff_id < 1 }
|
||||
{translate module=ticket}
|
||||
user_wrote
|
||||
{/translate}
|
||||
{else}
|
||||
<b>
|
||||
{translate module=ticket}
|
||||
staff_wrote
|
||||
{/translate}
|
||||
</b>
|
||||
{/if}
|
||||
</td>
|
||||
<td width="80%">
|
||||
{if $reply.staff_id > 1 }
|
||||
<b>
|
||||
{$reply.message|linkalize|replace:"\r\n":"<br>"}</b>
|
||||
{else}
|
||||
{$reply.message|linkalize|replace:"\r\n":"<br>"}
|
||||
{/if}
|
||||
</td>
|
||||
</tr>
|
||||
{if $show_static_var != false}
|
||||
{foreach from=$static_var item=record}
|
||||
{/foreach}
|
||||
{/if}
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<br>
|
||||
{/foreach}
|
||||
{/if}
|
||||
<form name="ticket_view" method="post" action="">
|
||||
<table width=100% border="0" cellspacing="0" cellpadding="1" class="table_background">
|
||||
<tr>
|
||||
<td>
|
||||
<table width="100%" border="0" cellspacing="4" cellpadding="1" class="row1">
|
||||
<tr valign="top" class="row1">
|
||||
<td width="80%">
|
||||
<div align="center">
|
||||
{ if $ticket.status != "2" }
|
||||
{translate module=ticket}
|
||||
user_add_response
|
||||
{/translate}
|
||||
{else}
|
||||
{translate module=ticket}
|
||||
user_reopen_response
|
||||
{/translate}
|
||||
{/if}
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<tr valign="top" class="row1">
|
||||
<td width="80%">
|
||||
<div align="center">
|
||||
<textarea name="ticket_reply" cols="70" rows="10"></textarea>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<tr valign="top" class="row1">
|
||||
<td width="80%">
|
||||
<div align="center">
|
||||
{html_button}
|
||||
<input type="hidden" name="_page" value="ticket:user_view">
|
||||
<input type="hidden" name="id" value="{$ticket.id}">
|
||||
<input type="hidden" name="do[]" value="ticket:user_update">
|
||||
<input type="hidden" name="email" value="{$VAR.email}">
|
||||
<input type="hidden" name="key" value="{$VAR.key}">
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
{if $show_static_var != false}
|
||||
{foreach from=$static_var item=record}
|
||||
{/foreach}
|
||||
{/if}
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<br>
|
||||
</form>
|
||||
{/if}
|
||||
|
||||
{else}
|
||||
{$block->display("ticket:auth")}
|
||||
{/if}
|
580
themes/default/blocks/ticket/view.tpl
Normal file
580
themes/default/blocks/ticket/view.tpl
Normal file
@@ -0,0 +1,580 @@
|
||||
{ $method->exe("ticket","view") } { if ($method->result == FALSE) } { $block->display("core:method_error") } {else}
|
||||
{literal}
|
||||
<script src="themes/{/literal}{$THEME_NAME}{literal}/view.js"></script>
|
||||
<script language="JavaScript">
|
||||
var module = 'ticket';
|
||||
var locations = '{/literal}{$VAR.module_id}{literal}';
|
||||
var id = '{/literal}{$VAR.id}{literal}';
|
||||
var ids = '{/literal}{$VAR.ids}{literal}';
|
||||
var array_id = id.split(",");
|
||||
var array_ids = ids.split(",");
|
||||
var num=0;
|
||||
if(array_id.length > 2) {
|
||||
document.location = '?_page='+module+':view&id='+array_id[0]+'&ids='+id;
|
||||
}else if (array_ids.length > 2) {
|
||||
document.write(view_nav_top(array_ids,id,ids));
|
||||
}
|
||||
|
||||
function refreshOpener() {
|
||||
try{ window.opener.refreshTicketSearch()} catch(e) {}
|
||||
}
|
||||
|
||||
function delete_record(id,ids)
|
||||
{
|
||||
temp = window.confirm("{/literal}{translate}alert_delete{/translate}{literal}");
|
||||
if(temp == false) return;
|
||||
|
||||
var replace_id = id + ",";
|
||||
ids = ids.replace(replace_id, '');
|
||||
if(ids == '') {
|
||||
var url = '?_page=core:search&module=' + module + '&do[]=' + module + ':delete&delete_id=' + id;
|
||||
window.location = url;
|
||||
return;
|
||||
} else {
|
||||
var page = 'view&id=' +ids;
|
||||
}
|
||||
|
||||
var doit = 'delete';
|
||||
var url = '?_page='+ module +':'+ page +'&do[]=' + module + ':' + doit + '&delete_id=' + id;
|
||||
window.location = url;
|
||||
}
|
||||
|
||||
function delete_quick(id) {
|
||||
try{window.opener.TicketDelete(id); }catch(e){}
|
||||
try{window.close(); }catch(e){}
|
||||
}
|
||||
|
||||
function delete_message(id,ids)
|
||||
{
|
||||
temp = window.confirm("{/literal}{translate}alert_delete{/translate}{literal}");
|
||||
if(temp == false) return;
|
||||
var url = '?_page=ticket:view&id=' + ids + '&do[]=ticket_message:delete&delete_id=' + id;
|
||||
document.location = url;
|
||||
return;
|
||||
}
|
||||
|
||||
function swapMsgStatus(i) {
|
||||
// get current state:
|
||||
if($('msgbody_'+i).style.display=='block') {
|
||||
$('msgtitleOn_'+i).style.display='block';
|
||||
$('msgtitleOff_'+i).style.display='none';
|
||||
$('msgoptionsOn_'+i).style.display='block';
|
||||
$('msgoptionsOff_'+i).style.display='none';
|
||||
$('msgbody_'+i).style.display='none';
|
||||
} else {
|
||||
$('msgtitleOn_'+i).style.display='none';
|
||||
$('msgtitleOff_'+i).style.display='block';
|
||||
$('msgoptionsOn_'+i).style.display='none';
|
||||
$('msgoptionsOff_'+i).style.display='block';
|
||||
$('msgbody_'+i).style.display='block';
|
||||
}
|
||||
}
|
||||
|
||||
function addFaq() {
|
||||
// set page & faq value
|
||||
if( $('add_faq').checked == true ) {
|
||||
$('page2').value = 'faq:add';
|
||||
$('faq_answer').value = $('ticket_reply').value;
|
||||
} else {
|
||||
$('page2').value = '{/literal}{$VAR._page}{literal}';
|
||||
$('faq_answer').value = $('ticket_reply').value;
|
||||
}
|
||||
}
|
||||
|
||||
// END -->
|
||||
</script>
|
||||
|
||||
<style>
|
||||
div.DialogBody table { font-family:Verdana, Arial, Helvetica, sans-serif; font-size:10px; cellpadding:0; cellspacing:0; width:100%; }
|
||||
|
||||
div.details {
|
||||
background-color:white;
|
||||
padding:5px;
|
||||
border:2px solid #C5DEA1;
|
||||
}
|
||||
|
||||
div.msgtitleStaff {
|
||||
padding:3px;
|
||||
background-color: #ECF3E1;
|
||||
border:1px solid #C5DEA1;
|
||||
border-bottom: 0px solid #FFF;
|
||||
width:100%;
|
||||
}
|
||||
|
||||
div.msgbodyStaff {
|
||||
padding:3px;
|
||||
background-color: #ECF3E1;
|
||||
border:1px solid #C5DEA1;
|
||||
border-bottom: 0px solid #FFF;
|
||||
border-top: 0px solid #FFF;
|
||||
width:100%;
|
||||
}
|
||||
|
||||
div.msgtitleUser {
|
||||
padding:3px;
|
||||
border:1px solid #C5DEA1;
|
||||
border-bottom: 0px solid #FFF;
|
||||
width:100%;
|
||||
}
|
||||
|
||||
div.msgbodyUser {
|
||||
padding:3px;
|
||||
border:1px solid #C5DEA1;
|
||||
border-bottom: 0px solid #FFF;
|
||||
border-top: 0px solid #FFF;
|
||||
width:100%;
|
||||
}
|
||||
|
||||
div.msgtitleStaff table { font-family:Verdana, Arial, Helvetica, sans-serif; font-size:11px; cellpadding:0; cellspacing:0; width:100%; }
|
||||
div.msgtitleUser table { font-family:Verdana, Arial, Helvetica, sans-serif; font-size:11px; cellpadding:0; cellspacing:0; width:100%; }
|
||||
|
||||
|
||||
div.msgoptions { position:float;
|
||||
text-align:right;
|
||||
}
|
||||
|
||||
div.DialogHeader {
|
||||
color: #fff;
|
||||
text-align:center;
|
||||
background-color: #333333;
|
||||
border: 1px solid #666666;
|
||||
padding:3px;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
div.DialogBody {
|
||||
color: #333;
|
||||
padding:3px;
|
||||
background-color:#fcfcfc;
|
||||
border: 1px solid #666666;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
div.DialogAction {
|
||||
border-top: 1px dotted #666666;
|
||||
padding-top: 5px;
|
||||
margin-top: 10px;
|
||||
}
|
||||
|
||||
</style>
|
||||
{/literal}
|
||||
|
||||
<!-- Loop through each record -->
|
||||
{foreach from=$ticket item=ticket}
|
||||
|
||||
<!-- Display the field validation -->
|
||||
{if $form_validation}
|
||||
{ $block->display("core:alert_fields") }
|
||||
{/if}
|
||||
|
||||
<form id="ticket_view" name="ticket_view" method="post" action="">
|
||||
<div>
|
||||
<table width="100%" border="0" cellspacing="0">
|
||||
<tr>
|
||||
<td align="left" valign="top">
|
||||
<h3>
|
||||
{if $ticket.status == "2"}<font color="#999999">{/if}
|
||||
{$ticket.subject} -
|
||||
{if $ticket.status == "0"}
|
||||
<font color="#990000">
|
||||
{translate module=ticket}
|
||||
status_open
|
||||
{/translate}
|
||||
</font> {/if}
|
||||
|
||||
{if $ticket.status == "1"}
|
||||
<font color="#CC9900">
|
||||
{translate module=ticket}
|
||||
status_hold
|
||||
{/translate}
|
||||
</font> {/if}
|
||||
|
||||
{if $ticket.status == "2"}
|
||||
{translate module=ticket}
|
||||
status_close
|
||||
{/translate}
|
||||
{/if}
|
||||
|
||||
{if $ticket.status == "3"}
|
||||
<font color="#0099CC">
|
||||
{translate module=ticket}
|
||||
status_pending
|
||||
{/translate}
|
||||
</font>{/if}
|
||||
</font></h3>
|
||||
</td>
|
||||
<td align="right" valign="bottom">
|
||||
<div id=showoptions {if $VAR.view_options}{style_hide}{/if}>{html_link name="More Options" hide=showoptions show=main_full,hideoptions action="document.getElementById('view_options').value=1;"}</div>
|
||||
<div id=hideoptions {if !$VAR.view_options}{style_hide}{/if}>{html_link name="Hide Options" show=showoptions hide=main_full,hideoptions action="document.getElementById('view_options').value=0;"}</div>
|
||||
{if $ticket.account_id > 0}
|
||||
<div id=showoptionsauth>{html_link name="Show User Authentication" hide=showoptionsauth show=optionsauth,hideoptionsauth}</div>
|
||||
<div id=hideoptionsauth {style_hide}>{html_link name="Hide User Authentication" show=showoptionsauth hide=optionsauth,hideoptionsauth}</div>
|
||||
{/if}
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<br>
|
||||
</div>
|
||||
|
||||
{if $ticket.account_id > 0}
|
||||
<div id="optionsauth" {style_hide}>
|
||||
<div class="DialogHeader">
|
||||
User's Services, Products, and Groups
|
||||
</div>
|
||||
<div class="DialogBody">
|
||||
<table width="100%" border="0" cellspacing="0" >
|
||||
<tr>
|
||||
<th width="33%" style="border-right:1px #ccc solid; border-bottom:1px #ccc solid" scope="col">Services</th>
|
||||
<th width="33%" style="border-right:1px #ccc solid; border-bottom:1px #ccc solid" scope="col">Groups</th>
|
||||
<th width="33%" style="border-bottom:1px #ccc solid" scope="col">Products</th>
|
||||
</tr>
|
||||
<tr valign="top">
|
||||
<td width="33%" style="border-right:1px #ccc solid">
|
||||
{if !$ticket.authsrvc} {/if}
|
||||
{foreach from=$ticket.authsrvc item=service}
|
||||
<p> <a href="?_page=service:view&id={$service.id}">{$service.date_orig}</a>
|
||||
<font color="#{if $service.active}006600{else}CC0000{/if}">{$service.sku}</font>
|
||||
</p>
|
||||
{/foreach}
|
||||
</td>
|
||||
<td width="33%" style="border-right:1px #ccc solid">
|
||||
{if !$ticket.authgrp} {/if}
|
||||
{foreach from=$ticket.authgrp item=group}
|
||||
<p> {$group.date_orig}
|
||||
<font color="#{if $group.active}006600{else}CC0000{/if}">{$group.name}</font>
|
||||
</p>
|
||||
{/foreach}
|
||||
</td>
|
||||
<td width="33%">
|
||||
{if !$ticket.authsku} {/if}
|
||||
{foreach from=$ticket.authsku item=sku}
|
||||
<p> <a href="?_page=invoice:view&id={$sku.id}">{$sku.dateorg}</a>
|
||||
{$sku.sku} ({$sku.qty}) </p>
|
||||
{/foreach}
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
<br>
|
||||
{/if}
|
||||
|
||||
<div id="main_full" {if !$VAR.view_options}{style_hide}{/if}>
|
||||
<div class="DialogHeader">
|
||||
{translate module=ticket}title_view{/translate} {$ticket.id}
|
||||
</div>
|
||||
<div class="DialogBody">
|
||||
<input type="hidden" name="_page" value="{$VAR._page}">
|
||||
{if $VAR._escape}
|
||||
<input type="hidden" name="_escape" value="1">
|
||||
{/if}
|
||||
<input type="hidden" name="ticket_id" value="{$ticket.id}">
|
||||
<input type="hidden" name="do[]" value="ticket:update">
|
||||
<input type="hidden" name="id" value="{$VAR.id}">
|
||||
<input type="hidden" name="ticket_date_last" value="">
|
||||
<input type="hidden" name="view_options" id="view_options" value="1">
|
||||
<table width=100%>
|
||||
<tr>
|
||||
<td>
|
||||
<table width="100%" bgcolor="#FFFFFF">
|
||||
<tr valign="top">
|
||||
<td width="25%"> <b>
|
||||
{translate module=ticket}
|
||||
field_date_orig
|
||||
{/translate}
|
||||
</b> </td>
|
||||
<td width="50%" align="center"> <b>
|
||||
{translate module=ticket}
|
||||
field_date_last
|
||||
{/translate}
|
||||
</b> </td>
|
||||
<td width="25%" align="right"> <b>
|
||||
{translate module=ticket}
|
||||
field_status
|
||||
{/translate}
|
||||
</b> </td>
|
||||
</tr>
|
||||
<tr valign="top">
|
||||
<td width="25%">
|
||||
{$list->date_time($ticket.date_orig)}
|
||||
</td>
|
||||
<td width="50%" align="center">
|
||||
{$list->date_time($ticket.date_last)}
|
||||
</td>
|
||||
<td width="25%" align="right">
|
||||
<select id="ticket_status" name="ticket_status" onChange="document.getElementById('ticket_view').submit()">
|
||||
<option value="0" {if $ticket.status == "0"}selected{/if}>
|
||||
{translate module=ticket}
|
||||
status_open
|
||||
{/translate}
|
||||
</option>
|
||||
<option value="1" {if $ticket.status == "1"}selected{/if}>
|
||||
{translate module=ticket}
|
||||
status_hold
|
||||
{/translate}
|
||||
</option>
|
||||
<option value="2" {if $ticket.status == "2"}selected{/if}>
|
||||
{translate module=ticket}
|
||||
status_close
|
||||
{/translate}
|
||||
</option>
|
||||
<option value="3" {if $ticket.status == "3"}selected{/if}>
|
||||
{translate module=ticket}
|
||||
status_pending
|
||||
{/translate}
|
||||
</option>
|
||||
</select>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<table width="100%">
|
||||
<tr valign="top">
|
||||
<td width="25%"> <b>
|
||||
{translate module=ticket}
|
||||
field_staff_id
|
||||
{/translate}
|
||||
</b> </td>
|
||||
<td width="50%" align="center"> <b>
|
||||
{translate module=ticket}
|
||||
field_department_id
|
||||
{/translate}
|
||||
</b> </td>
|
||||
<td width="25%" align="right"> <b>
|
||||
{translate module=ticket}
|
||||
field_priority
|
||||
{/translate}
|
||||
</b> </td>
|
||||
</tr>
|
||||
<tr valign="top">
|
||||
<td width="25%">
|
||||
{ $list->menu("no", "ticket_staff_id", "staff", "nickname", $ticket.staff_id, "form_menu\" onChange=\"document.getElementById('ticket_view').submit()") }
|
||||
</td>
|
||||
<td width="50%" align="center">
|
||||
{ $list->menu("no", "ticket_department_id", "ticket_department", "name", $ticket.department_id, "form_menu\" onChange=\"document.getElementById('ticket_view').submit()") }
|
||||
</td>
|
||||
<td width="25%" align="right">
|
||||
<select name="ticket_priority" onChange="document.getElementById('ticket_view').submit()">
|
||||
<option value="0" {if $ticket.priority == "0"}selected{/if}>
|
||||
{translate module=ticket}
|
||||
priority_standard
|
||||
{/translate}
|
||||
</option>
|
||||
<option value="1" {if $ticket.priority == "1"}selected{/if}>
|
||||
{translate module=ticket}
|
||||
priority_medium
|
||||
{/translate}
|
||||
</option>
|
||||
<option value="2" {if $ticket.priority == "2"}selected{/if}>
|
||||
{translate module=ticket}
|
||||
priority_high
|
||||
{/translate}
|
||||
</option>
|
||||
<option value="3" {if $ticket.priority == "3"}selected{/if}>
|
||||
{translate module=ticket}
|
||||
priority_emergency
|
||||
{/translate}
|
||||
</option>
|
||||
</select>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<table width="100%">
|
||||
<tr valign="top">
|
||||
<td width="25%"> <b>
|
||||
{translate module=ticket}
|
||||
field_email
|
||||
{/translate}
|
||||
</b> </td>
|
||||
<td width="50%" align="center"> <b>
|
||||
{translate module=ticket}
|
||||
field_account_id
|
||||
{/translate}
|
||||
</b> </td>
|
||||
<td width="25%" align="right"><b>
|
||||
{translate module=ticket}
|
||||
field_last_reply
|
||||
{/translate}
|
||||
</b></td>
|
||||
</tr>
|
||||
<tr valign="top">
|
||||
<td width="25%">
|
||||
<input type="text" name="ticket_email" value="{$ticket.email}" size="22" >
|
||||
</td>
|
||||
<td width="50%" align="center">
|
||||
{html_select_account name="ticket_account_id" default=$ticket.account_id}
|
||||
</td>
|
||||
<td width="25%" align="right">
|
||||
<select name="ticket_last_reply" onChange="submit()">
|
||||
<option value="0" {if $ticket.last_reply == ""}selected{/if}></option>
|
||||
<option value="1" {if $ticket.last_reply == "1"}selected{/if}>
|
||||
{translate module=ticket}last_reply_user{/translate}
|
||||
</option>
|
||||
<option value="2" {if $ticket.last_reply == "2"}selected{/if}>
|
||||
{translate module=ticket}last_reply_staff{/translate}
|
||||
</option>
|
||||
</select>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
{if $ticket.static_var != false}
|
||||
<tr>
|
||||
<td>
|
||||
<table width="100%">
|
||||
{foreach from=$ticket.static_var item=record}
|
||||
<tr valign="top" class="row1">
|
||||
<td width="25%"> <b>
|
||||
{$record.name}
|
||||
</b> </td>
|
||||
<td width="65%">
|
||||
{$record.html}
|
||||
</td>
|
||||
</tr>
|
||||
{/foreach}
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
{/if}
|
||||
</table>
|
||||
<div class="DialogAction">
|
||||
<table width="95%">
|
||||
<tr valign="middle">
|
||||
<td width="1%">
|
||||
<input type="submit" name="Submit32" value="{translate}submit{/translate}" class="form_button">
|
||||
</td>
|
||||
<td width="98%" align="center">
|
||||
{ $method->exe_noauth("ticket","merge_list") }
|
||||
</td>
|
||||
<td width="1%" align="right">
|
||||
<input type="button" name="delete32" value="{translate}delete{/translate}" class="form_button" onClick="{if $VAR._page=='ticket:view_quick'}delete_quick('{$ticket.id}'){else}delete_record('{$ticket.id}','{$VAR.id}'){/if}">
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
<br>
|
||||
</div>
|
||||
|
||||
|
||||
<div id="showmsg">
|
||||
<div class="msgtitleUser" onclick="swapMsgStatus(0);">
|
||||
<table width="100%" border="0" cellspacing="0">
|
||||
<tr>
|
||||
<td align="left" valign="top">
|
||||
<div id="msgtitleOn_0" {if !$ticket.reply}{style_hide}{/if}>{$ticket.body|replace:"\r\n":" "|truncate:95}</div>
|
||||
<div id="msgtitleOff_0" {if $ticket.reply}{style_hide}{/if}><b>{$ticket.subject}</b></div>
|
||||
</td>
|
||||
<td align="right" valign="top">
|
||||
<div id="msgoptionsOn_0" class="msgoptions" {if !$ticket.reply}{style_hide}{/if}>{$list->date_time($ticket.date_orig)}</div>
|
||||
<div id="msgoptionsOff_0" class="msgoptions" {if $ticket.reply}{style_hide}{/if}>{html_link name=edit hide=showmsg show=editmsg} | {$list->date_time($ticket.date_orig)}</div>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
<div class="msgbodyUser" id="msgbody_0" {if $ticket.reply}{style_hide}{/if}>
|
||||
<p>{$ticket.body|linkalize|replace:"\r\n":"<br>"}</p>
|
||||
|
||||
{if $ticket.attachments}
|
||||
<hr style="width:300px;" align="left">
|
||||
{foreach from=$ticket.attachments item=attach}
|
||||
<p><b>{$attach.name}</b><br>{$attach.size} <a href="{$URL}?_page=core:blank&_escape=1&do[]=ticket_attachment:download&id={$attach.id}">Download</a></p>
|
||||
{/foreach}
|
||||
{/if}
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="editmsg" {style_hide}>
|
||||
<div class="msgtitleUser">
|
||||
<div class="msgoptions"> {html_link name=save action="getElementById('ticket_view').submit();"} {html_link name=cancel hide=editmsg show=showmsg} </div>
|
||||
<div><input type="text" size="60" name="ticket_subject" value="{$ticket.subject|escape:"htmlall"}"></div>
|
||||
</div>
|
||||
<div class="msgbodyUser">
|
||||
<textarea name="ticket_body" id="ticket_body" cols="70" rows="3" onClick="{literal}$('ticket_body').rows='14'; {/literal}">{$ticket.body|escape:"htmlall"}</textarea>
|
||||
</div></form>
|
||||
</div>
|
||||
|
||||
{if $ticket.reply != false}
|
||||
{foreach from=$ticket.reply item=reply}
|
||||
<div class="msgtitle{if $reply.staff_id}Staff{else}User{/if}" {if !$reply.last}onclick="swapMsgStatus('{$reply.id}');"{/if}>
|
||||
<table width="100%" border="0" cellspacing="0">
|
||||
<tr>
|
||||
<td align="left" valign="top">
|
||||
<div id="msgtitleOn_{$reply.id}" {if $reply.last}{style_hide}{/if}>
|
||||
<b>{if $reply.staff_id}{$reply.staff_nickname}{else}{$reply.user_name}{/if}</b>
|
||||
{$reply.message|replace:"\r\n":" "|truncate:70}
|
||||
</div>
|
||||
<div id="msgtitleOff_{$reply.id}" {if !$reply.last}{style_hide}{/if}>
|
||||
<b>{if $reply.staff_id}{$reply.staff_nickname}{else}{$reply.user_name}{/if}</b>
|
||||
</div>
|
||||
</td>
|
||||
<td align="right" valign="top">
|
||||
<div id="msgoptionsOff_{$reply.id}" class="msgoptions" {if !$reply.last}{style_hide}{/if}>{html_link name=delete action="delete_message('`$reply.id`','`$VAR.id`');"} | {$list->date_time($reply.date_orig)}</div>
|
||||
<div id="msgoptionsOn_{$reply.id}" class="msgoptions" {if $reply.last}{style_hide}{/if}>{$list->date_time($reply.date_orig)}</div>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
|
||||
<div class="msgbody{if $reply.staff_id}Staff{else}User{/if}" id="msgbody_{$reply.id}" {if !$reply.last}{style_hide}{/if}>
|
||||
<p>{$reply.message|linkalize|replace:"\r\n":"<br>"} </p>
|
||||
</div>
|
||||
{/foreach}
|
||||
{/if}
|
||||
|
||||
|
||||
<div class="msgtitleStaff" id="replymsg">
|
||||
<div>
|
||||
<p><center>{translate module=ticket}user_add_response {/translate}</center></p>
|
||||
|
||||
<form name="ticket_update" method="get" action="">
|
||||
<center>
|
||||
|
||||
{if $list->is_installed('faq')}
|
||||
<p>
|
||||
<input type="hidden" id="faq_autofill_hidden" name="faq_translate_id" value="" />
|
||||
<input type="text" autocomplete="off" id="faq_autofill" name="faq_autofill" size="65" value="" onBlur="{literal}if($('faq_autofill_hidden').value!='' && $('faq_autofill_hidden').value!='null') { $('ticket_reply').value = $('faq_autofill_hidden').value + $('signature').innerHTML; $('ticket_reply').rows='14'; }{/literal}" onClick="this.value=''; $('faq_autofill_hidden').value=''; $('faq_autofill').focus();" style="font-size: 14px; border:2px solid #999; padding:2px;" />
|
||||
<div class="auto_complete" id="faq_autofiller"></div>
|
||||
<script type="text/javascript">new Ajax.Autocompleter("faq_autofill", "faq_autofiller", "ajax.php?do[]=faq:autofill" )</script>
|
||||
</p>
|
||||
{/if}
|
||||
|
||||
<div id="signature" {style_hide}>{$signature}</div>
|
||||
<p><textarea id="ticket_reply" name="ticket_reply" cols="65" rows="2" onfocus="{literal}$('ticket_reply').rows='14';{/literal}" onblur="addFaq()" style="font-size: 13px; border:2px solid #999; padding:2px; ">{$signature}</textarea></p>
|
||||
|
||||
<p>
|
||||
<input type="checkbox" name="enable_user_notice" value="1" checked> {translate module=ticket} enable_user_notice {/translate}
|
||||
<input type="checkbox" name="add_faq" id="add_faq" value="1" onClick="addFaq()"> Add Q&A to FAQ Module
|
||||
|
||||
<p>{html_button}</p
|
||||
>
|
||||
</p>
|
||||
|
||||
|
||||
</center>
|
||||
<input type="hidden" name="_page" id="page2" value="{$VAR._page}">
|
||||
{if $VAR._escape}
|
||||
<input type="hidden" name="_escape" value="1">
|
||||
{/if}
|
||||
<input type="hidden" name="ticket_id" value="{$ticket.id}">
|
||||
<input type="hidden" name="do[]" value="ticket:reply">
|
||||
<input type="hidden" name="id" value="{$VAR.id}">
|
||||
|
||||
<input type="hidden" name="faq_name" value="{$ticket.subject}">
|
||||
<input type="hidden" name="faq_question" value="{$ticket.body|escape:"htmlall"}">
|
||||
<input type="hidden" name="faq_answer" id="faq_answer" value="">
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
<script language="javascript">{if $VAR.do}refreshOpener(){/if}</script>
|
||||
{/foreach}
|
||||
{/if}
|
20
themes/default/blocks/ticket/view_quick.tpl
Normal file
20
themes/default/blocks/ticket/view_quick.tpl
Normal file
@@ -0,0 +1,20 @@
|
||||
{ $block->display("core:top_clean") }
|
||||
|
||||
{literal}
|
||||
<style type="text/css">
|
||||
body {
|
||||
margin: 20px;
|
||||
margin-right: 30px;
|
||||
}
|
||||
</style>
|
||||
{/literal}
|
||||
|
||||
<script src="includes/javascript/prototype.js" type="text/javascript"></script>
|
||||
<script src="includes/javascript/effects.js" type="text/javascript"></script>
|
||||
<script src="includes/javascript/dragdrop.js" type="text/javascript"></script>
|
||||
<script src="includes/javascript/controls.js" type="text/javascript"></script>
|
||||
|
||||
{ $block->display("ticket:view") }
|
||||
|
||||
</body>
|
||||
</html>
|
Reference in New Issue
Block a user