diff --git a/include/staff/header.inc.php b/include/staff/header.inc.php index b0a7c4efef46bfa5ce923ac251beb101c3125293..46722948c5aae7309c921623dfeaa57aa2c32a0b 100644 --- a/include/staff/header.inc.php +++ b/include/staff/header.inc.php @@ -14,19 +14,20 @@ </style> <![endif]--> <script type="text/javascript" src="../js/jquery-1.7.2.min.js"></script> - <script type="text/javascript" src="./js/calendar.js"></script> + <script type="text/javascript" src="../js/jquery-ui-1.8.18.custom.min.js"></script> <script type="text/javascript" src="./js/tips.js"></script> <script type="text/javascript" src="./js/nicEdit.js"></script> <script type="text/javascript" src="./js/bootstrap-typeahead.js"></script> <script type="text/javascript" src="./js/scp.js"></script> <link rel="stylesheet" href="./css/scp.css" media="screen"> <link rel="stylesheet" href="./css/typeahead.css" media="screen"> + <link type="text/css" href="../css/ui-lightness/jquery-ui-1.8.18.custom.css" rel="stylesheet" /> </head> <body> <div id="container"> <div id="header"> <a href="index.php" id="logo">osTicket - Customer Support System</a> - <p id="info">Welcome back, <strong><?php echo $thisstaff->getUserName(); ?></strong> + <p id="info">Howdy, <strong><?php echo $thisstaff->getUserName(); ?></strong> <?php if($thisstaff->isAdmin() && !defined('ADMINPAGE')) { ?> | <a href="admin.php">Admin Panel</a> diff --git a/include/staff/syslogs.inc.php b/include/staff/syslogs.inc.php index 5418518f71f498996aee68cd2a6f0b5a8f7b4034..e0f5d2098717dfd360b16fce6959b4a222fd241b 100644 --- a/include/staff/syslogs.inc.php +++ b/include/staff/syslogs.inc.php @@ -88,13 +88,9 @@ else <form action="syslogs.php" method="get"> <div style="padding-left:2px;"> <b>Date Span</b>: - From <input class="dp" id="sd" size=15 name="startDate" value="<?php echo Format::htmlchars($_REQUEST['startDate']); ?>" - onclick="event.cancelBubble=true;calendar(this);" autocomplete=OFF> - <a href="#" onclick="event.cancelBubble=true;calendar(getObj('sd')); return false;"><img src='images/cal.png'border=0 alt=""></a> + From <input class="dp" id="sd" size=15 name="startDate" value="<?php echo Format::htmlchars($_REQUEST['startDate']); ?>" autocomplete=OFF> to - <input class="dp" id="ed" size=15 name="endDate" value="<?php echo Format::htmlchars($_REQUEST['endDate']); ?>" - onclick="event.cancelBubble=true;calendar(this);" autocomplete=OFF > - <a href="#" onclick="event.cancelBubble=true;calendar(getObj('ed')); return false;"><img src='images/cal.png'border=0 alt=""></a> + <input class="dp" id="ed" size=15 name="endDate" value="<?php echo Format::htmlchars($_REQUEST['endDate']); ?>" autocomplete=OFF> Type: <select name='type'> diff --git a/include/staff/ticket-edit.inc.php b/include/staff/ticket-edit.inc.php index db80cf2f73fc53853905be23eaa6430e7eefd1de..7bbf0921e5ed97a076e0dc5df4aa61dde44e27fb 100644 --- a/include/staff/ticket-edit.inc.php +++ b/include/staff/ticket-edit.inc.php @@ -139,18 +139,17 @@ $info=Format::htmlchars(($errors && $_POST)?$_POST:$ticket->getUpdateInfo()); Due Date: </td> <td> - <input id="duedate" name="duedate" value="<?php echo Format::htmlchars($info['duedate']); ?>" size="10" - onclick="event.cancelBubble=true;calendar(this);" autocomplete=OFF> - <a href="#" onclick="event.cancelBubble=true;calendar(getObj('duedate')); return false;"><img src='images/cal.png'border=0 alt=""></a> + <input class="dp" id="duedate" name="duedate" value="<?php echo Format::htmlchars($info['duedate']); ?>" size="12" autocomplete=OFF> <?php $min=$hr=null; if($info['time']) - list($hr,$min)=explode(':',$info['time']); - echo Misc::timeDropdown($hr,$min,'time'); + list($hr, $min)=explode(':', $info['time']); + + echo Misc::timeDropdown($hr, $min, 'time'); ?> <font class="error"> <?=$errors['duedate']?> <?php echo $errors['time']; ?></font> - <em>Time is based on your time zone (GM <?php echo $thisstaff->getTZoffset(); ?>)</em> + <em>Time is based on your time zone (GMT <?php echo $thisstaff->getTZoffset(); ?>)</em> </td> </tr> <tr> diff --git a/include/staff/ticket-open.inc.php b/include/staff/ticket-open.inc.php index 4ec32b3423abb2c4fa424552ec4b6730a8418e9a..680fbad151ba038104410a3a778f3371841d4ed1 100644 --- a/include/staff/ticket-open.inc.php +++ b/include/staff/ticket-open.inc.php @@ -203,18 +203,17 @@ $info=Format::htmlchars(($errors && $_POST)?$_POST:$info); Due Date: </td> <td> - <input id="duedate" name="duedate" value="<?php echo Format::htmlchars($info['duedate']); ?>" size="10" - onclick="event.cancelBubble=true;calendar(this);" autocomplete=OFF> - <a href="#" onclick="event.cancelBubble=true;calendar(getObj('duedate')); return false;"><img src='images/cal.png'border=0 alt=""></a> + <input class="dp" id="duedate" name="duedate" value="<?php echo Format::htmlchars($info['duedate']); ?>" size="12" autocomplete=OFF> <?php $min=$hr=null; if($info['time']) - list($hr,$min)=explode(':',$info['time']); - echo Misc::timeDropdown($hr,$min,'time'); + list($hr, $min)=explode(':', $info['time']); + + echo Misc::timeDropdown($hr, $min, 'time'); ?> <font class="error"> <?=$errors['duedate']?> <?php echo $errors['time']; ?></font> - <em>Time is based on your time zone (GM <?php echo $thisstaff->getTZoffset(); ?>)</em> + <em>Time is based on your time zone (GMT <?php echo $thisstaff->getTZoffset(); ?>)</em> </td> </tr> <tr> diff --git a/include/staff/tickets.inc.php b/include/staff/tickets.inc.php index 9d6d5c7bcf0005e315f4e6e032943c97a237c01d..bd4801c445cadc40677b3dcdb3bf163b280abfc8 100644 --- a/include/staff/tickets.inc.php +++ b/include/staff/tickets.inc.php @@ -533,9 +533,9 @@ $negorder=$order=='DESC'?'ASC':'DESC'; //Negate the sorting.. </fieldset> <fieldset class="date_range"> <label>Date Range:</label> - <input class="dp" type="input" size="20" name="startDate"><i></i> + <input class="dp" type="input" size="20" name="startDate"> <span>TO</span> - <input class="dp" type="input" size="20" name="endDate"><i></i> + <input class="dp" type="input" size="20" name="endDate"> </fieldset> <p> <span class="buttons"> diff --git a/scp/css/scp.css b/scp/css/scp.css index adde43fafd105f9a5da9b778bb94f7103aebe2ed..aa6ca4782492783d221fef0c6b18fe412f3cbcd5 100644 --- a/scp/css/scp.css +++ b/scp/css/scp.css @@ -1290,3 +1290,16 @@ time { background:#ffd8d8; border:1px solid #a00; } + +/* Custom css for datepicker */ +.ui-datepicker-trigger { + display:inline-block; + border:0; + padding:0; + margin-left:2px; + position:relative; + top:5px; + width:16px; + height:16px; + background:inherit; +} diff --git a/scp/js/scp.js b/scp/js/scp.js index 071c63ff82cb339fdfc8517136672910efeb41f3..b31f673f0d9f7119768846bae078d11770ed18fc 100644 --- a/scp/js/scp.js +++ b/scp/js/scp.js @@ -185,6 +185,14 @@ $(document).ready(function(){ }, 'json') .error( function() {}); + /* Datepicker */ + + $('.dp').datepicker({ + numberOfMonths: 2, + showButtonPanel: true, + buttonImage: './images/cal.png', + showOn:'both' + }); /* NicEdit richtext init */ var rtes = $('.richtext');