News:

Please note these forums are mostly a testing ground for my SMF work and I don't really use them otherwise.

Main Menu

Paste-1269205203:v:use_geshi-1:v:type-php

Started by SleePy, Mar 21, 2010, 09:00 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

SleePy

The-SleePy-Laptop:simpledesk jeremy$ diff -u /home/svn/simpledesk/trunk/scripts/helpdesk.js /home/smf/public_html/helpdesk/Themes/default/scripts/helpdesk.js
--- /home/svn/simpledesk/trunk/scripts/helpdesk.js   2010-02-28 08:27:39.000000000 -0800
+++ /home/smf/public_html/helpdesk/Themes/default/scripts/helpdesk.js   2010-03-21 13:57:44.000000000 -0700
@@ -206,4 +206,11 @@
    document.getElementById(this.opt.sHeaderId).setAttribute('class', (this.bCollapsed ? 'titlebg grid_header' : 'titlebg'));
 
    this.bCollapsed = !this.bCollapsed;
+}
+
+// The quick jump function
+function shd_quickTicketJump(id_ticket)
+{
+   window.location.href = smf_prepareScriptUrl(smf_scripturl) + '?action=helpdesk;sa=ticket;ticket=' + id_ticket;
+   return false;
 }
\ No newline at end of file
The-SleePy-Laptop:simpledesk jeremy$ diff -u /home/svn/simpledesk/trunk/template/SimpleDesk.template.php /home/smf/public_html/helpdesk/Themes/default/SimpleDesk.template.php
--- /home/svn/simpledesk/trunk/template/SimpleDesk.template.php   2010-03-20 13:28:57.000000000 -0700
+++ /home/smf/public_html/helpdesk/Themes/default/SimpleDesk.template.php   2010-03-21 13:57:41.000000000 -0700
@@ -37,11 +37,12 @@
                <span class="upperframe"><span></span></span>
                <div class="roundframe">
                   <div class="shd_gototicket smalltext">
-                     <form action="', $scripturl, '?action=helpdesk" method="post">
+                     <form action="', $scripturl, '?action=helpdesk;sa=ticket" method="get">
                         ', $txt['shd_go_to_ticket'], ':
-                        <input type="text" name="ticket" size="4" />
-                        <input type="submit" value="', $txt['shd_go'], '" />
+                        <input type="hidden" name="action" value="helpdesk" />
                         <input type="hidden" name="sa" value="ticket" />
+                        <input type="text" id="ticketJump" name="ticket" size="4" />
+                        <input type="submit" value="', $txt['shd_go'], '" onclick="shd_quickTicketJump(this.parentNode.ticketJump.value);" />
                      </form>
                   </div>
                   <div id="welcome">
No siggy! :D