-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpost_ticket.php
More file actions
executable file
·90 lines (82 loc) · 3.34 KB
/
Copy pathpost_ticket.php
File metadata and controls
executable file
·90 lines (82 loc) · 3.34 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
<?php /* TICKETSMITH $Id: post_ticket.php,v 1.17 2006/05/20 09:35:47 cyberhorse Exp $ */
##
## Ticketsmith Post Ticket
##
if (!$canEdit) {
$AppUI->redirect( "m=public&a=access_denied" );
}
// setup the title block
$titleBlock = new CTitleBlock( 'Submit Trouble Ticket', 'gconf-app-icon.png', $m, "$m.$a" );
$titleBlock->addCrumb( "?m=ticketsmith", "tickets list" );
$titleBlock->show();
?>
<SCRIPT language="javascript">
function submitIt() {
var f = document.ticketform;
var msg = '';
if (f.name.value.length < 3) {
msg += "\n- <?php echo $AppUI->_('a valid name'); ?>"
}
if (f.email.value.length < 3) {
msg += "\n- <?php echo $AppUI->_('a valid email'); ?>";
}
if (f.subject.value.length < 3) {
msg += "\n- <?php echo $AppUI->_('a valid subject'); ?>";
}
if (f.description.value.length < 3) {
msg += "\n- <?php echo $AppUI->_('a valid description'); ?>";
}
if (msg.length < 1) {
f.submit();
} else {
alert( "<?php echo $AppUI->_('ticketsmithValidDetail', UI_OUTPUT_JS); ?>:" + msg );
}
}
</script>
<TABLE width="100%" border=0 cellpadding="0" cellspacing=1 class="std">
<form name="ticketform" action="?m=ticketsmith" method="post">
<input type="hidden" name="dosql" value="do_ticket_aed">
<TR height="20">
<Th colspan=2>
<font face="verdana,helveitica,arial,sans-serif" color=#ffffff><strong><?php echo $AppUI->_('Trouble Details'); ?></strong></font>
</th>
</tr>
<tr>
<TD align="right"><?php echo $AppUI->_('Name'); ?>:</td>
<TD><input type="text" class="text" name="name" value="<?php echo $AppUI->user_first_name . ' ' . $AppUI->user_last_name; ?>" size=50 maxlength="255"> <span class="smallNorm">(<?php echo $AppUI->_('required'); ?>)</span></td>
</tr>
<tr>
<TD align="right"><?php echo $AppUI->_('E-Mail'); ?>:</td>
<TD><input type="text" class="text" name="email" value="<?php echo $AppUI->user_email; ?>" size=50 maxlength="50"> <span class="smallNorm">(<?php echo $AppUI->_('required'); ?>)</span></td>
</tr>
<tr>
<TD align="right"><?php echo $AppUI->_('Subject'); ?>:</td>
<TD><input type="text" class="text" name="subject" value="" size=50 maxlength="50"> <span class="smallNorm">(<?php echo $AppUI->_('required'); ?>)</span></td>
</tr>
<tr>
<TD align="right"><?php echo $AppUI->_('Priority'); ?>:</td>
<td><?php echo arraySelect(dPgetSysVal('TicketsPriority'), 'priority', ' class="text"', '0'); ?></td>
<!-- <select name="priority" class="text">
<option value="0"><?php echo $AppUI->_('Low'); ?>
<option value="1" selected><?php echo $AppUI->_('Normal'); ?>
<option value="2"><?php echo $AppUI->_('High'); ?>
<option value="3"><?php echo $AppUI->_('Highest'); ?>
<option value="4"><strong><?php echo $AppUI->_('911'); ?> (<?php echo $AppUI->_('Showstopper'); ?>)</strong>
</select> -->
</tr>
<TR>
<TD align="right"><?php echo $AppUI->_('Description of Problem'); ?>: </td>
<td><span class="smallNorm">(<?php echo $AppUI->_('required'); ?>)</span></td>
</tr>
<TR>
<TD colspan=2 align="center">
<textarea cols="70" rows="10" class="textarea" name="description"><?php echo @$crow["description"];?></textarea>
</td>
</tr>
<TR>
<TD><input type="button" value="<?php echo $AppUI->_('back'); ?>" class="button" onclick="javascript:history.back(-1);"></td>
<TD align="right"><input type="button" value="<?php echo $AppUI->_('submit'); ?>" class="button" onclick="submitIt()"></td>
</tr>
</form>
</TABLE>
<br /> <br />