<!-- BEGIN options_select -->
    <option value="{optionvalue}" {optionselected}>{optionname}</option>
<!-- END options_select -->

<!-- BEGIN additional_notes_row -->
  <tr>
    <td colspan="4" class="bg_view" style="color:#000000">
      <hr />
      {lang_date}: &nbsp; {value_date}<br />
      {lang_user}: &nbsp; {value_user}<br /><br />
      {value_note}
      <p></p>
    </td>
  </tr>
<!-- END additional_notes_row -->

<!-- BEGIN additional_notes_row_empty -->
  <tr><td colspan="4"><b>{lang_no_additional_notes}</b></td></tr>
<!-- END additional_notes_row_empty -->

<!-- BEGIN row_history -->
  <tr>
    <td class="bg_color1">{value_date}</td>
    <td class="bg_color2">{value_user}</td>
    <td class="bg_color1">{value_action}</td>
    <td class="bg_color2">{value_old_value}</td>
    <td class="bg_color1">{value_new_value}</td>
  </tr>
<!-- END row_history -->

<!-- BEGIN row_history_empty -->
  <tr class="bg_color1"><td colspan="4" class="center"><b>{lang_no_history}</b></td></tr>
<!-- END row_history_empty -->

<!-- BEGIN form -->
<p><b>{lang_viewjobdetails}</b></p>
<table class="tabletab">
  <tr>
    <th id="tab1" class="activetab" valign="top" onclick="javascript:tab.display(1);">
      <table class="basic">
        <tr>
          <td id="starttab"></td>
          <td>
            <a href="#" tabindex="0" accesskey="1" onfocus="tab.display(1);" onclick="tab.display(1); return(false);">{lang_details}</a>
          </td>
          <td id="tweentab_r"></td>
        </tr>
      </table>
    </th>
    <th id="tab2" class="activetab" onclick="javascript:tab.display(2);">
      <table>
        <tr>
          <td id="tweentab_l"></td>
          <td>
            <a href="#" tabindex="0" accesskey="2" onfocus="tab.display(2);" onclick="tab.display(2); return(false);">{lang_update}</a>
          </td>
          <td id="tweentab_r"></td>
        </tr>
      </table>
    </th>
    <th id="tab3" class="activetab" onclick="javascript:tab.display(3);">
      <table>
        <tr>
          <td id="tweentab_l"></td>
          <td>
            <a href="#" tabindex="0" accesskey="3" onfocus="tab.display(3);" onclick="tab.display(3); return(false);">history</a>
          </td>
          <td id="tweentab_r"></td>
        </tr>
      </table>
    </th>
  </tr>
</table>

<form method="post" action="{viewticketdetails_link}">
  <input type="hidden" name="ticket_id" value="{ticket_id}" />
  <input type="hidden" name="lstAssignedfrom" value="{ticket_user}" />

  <div id="tabcontent1" class="activetab">

    <table class="basic" id="tab1" style="visibility: visible;">
      {messages}
<tr><td>
          <table class="padding">
            <thead class="center">
              <tr><td colspan="4">&nbsp;<b>[ #{ticket_id} ] - {value_subject}</b></td></tr>
            </thead>
            <tbody>
            <tr class="left">
              <td class="bg_color1">{lang_opendate}:</td>
              <td class="bg_color1"><b>{value_opendate}</b></td>
              <td class="bg_color2">{lang_billable_hours}:</td>
              <td class="bg_color2"><b>{currency} {value_billable_hours}</b></td>
            </tr>
            <tr class="left">
              <td class="bg_color2">{lang_assignedfrom}:</td>
              <td class="bg_color2"><b>{value_owner}</b></td>
              <td class="bg_color1">{lang_billable_hours_rate}:</td>
              <td class="bg_color1"><b>{currency} {value_billable_hours_rate}</b></td>
            </tr>
            <tr class="left">
              <td class="bg_color1">{lang_assignedto}:</td>
              <td class="bg_color1"><b>{value_assignedto}</b></td>
              <td class="bg_color2">{lang_billable_hours_total}:</td>
              <td class="bg_color2"><b>{currency} {value_billable_hours_total}</b></td>
            </tr>
            <tr class="left">
              <td class="bg_color2">{lang_priority}:</td>
              <td class="bg_color2"><b>{value_priority}</b></td>
              <td class="bg_color1">&nbsp;</td>
              <td class="bg_color1">&nbsp;</td>
            </tr>
            <tr class="left">
              <td class="bg_color1">{lang_category}:</td>
              <td class="bg_color1"><b>{value_category}</b></td>
              <td class="bg_color2">{lang_type}:</td>
              <td class="bg_color2"><b>{value_type}</b></td>
            </tr>
            <tr class="left">
              <td class="bg_color2">{lang_group}:</td>
              <td class="bg_color2"><b>{value_group}</b></td>
              <td class="bg_color1">{lang_attachment}</td>
              <td class="bg_color1">{value_attachment}</td>
            </tr>
            <tr><td colspan="4" class="center">&nbsp;</td></tr>

              <tr class="header"><td colspan="4" class="left"><b>{lang_details}:</b><br />{value_details}</td></tr>

            <tr><td class="tts_height" colspan="4"></td></tr>

              <tr class="header"><td colspan="4" class="left"><b>{lang_additional_notes}:</b></td></tr>

            {rows_notes}
            <tr><td colspan="4"><input name="done" type="button" value="{lang_done}" onClick="self.location.href='{done_url}'" /></td></tr>
            </tbody>
          </table>
        </td>
      </tr>
    </table>
  </div>
  <div id="tabcontent2" class="activetab">
    <table class="basic" id="tab2" style="visibility: visible;">
      <tr>
        <td>
          <table class="basic">
            <tr>
              <td>
                <table cellpadding="4">
                    <tr class="header"><td colspan="4" class="left">{lang_update}:&nbsp;</td></tr>
                  <tr class="left">
                    <td class="bg_color1">
                    	<b>{lang_priority}:&nbsp;</b>
                      <select name="ticket[priority]">
                        {options_priority}
                      </select>
                    </td>
                    <td class="bg_color1">
                      <b>{lang_category}:&nbsp;</b>
                      <select size="1" name="ticket[category]">
                        {options_category}
                      </select>
                    </td>
                    <td class="bg_color1">
                      <b>{lang_assignedto}:&nbsp;</b>
                      <select size="1" name="ticket[assignedto]">
                        {options_assignedto}
                      </select>
                    </td>
                  </tr>
                  <tr class="left">
                    <td class="bg_color2">
                      <b>{lang_status}:&nbsp;</b>
                      <select name="ticket[status]">
                        {options_status}
                      </select>
                    </td>
                    <td class="bg_color2">
                      <b>{lang_group}:&nbsp;</b>
                      <select name="ticket[group]">
                        {options_group}
                      </select>
                    </td>
                    <td class="bg_color2"><b>{lang_billable_hours_rate}:&nbsp;</b><input name="ticket[billable_rate]" value="{value_billable_hours_rate}" /></td>
                  </tr>
                  <tr class="left">
                    <td class="bg_color1"><b>{lang_platform}:</b>{option_platform}</td>
                    <td class="bg_color1"><b>{lang_attachment}</b><input type="file" name="attachment" /></td>
                    <td class="bg_color1"><b>{lang_billable_hours}: </b><input name="ticket[billable_hours]" value="{value_billable_hours}" /></td>
                  </tr>
                  <tr class="bg_color2"><td colspan="3" class="center">{additonal_details_rows}<textarea rows="12" name="ticket[note]" cols="70" wrap="physical"></textarea></td></tr>
                  <tr>
                    <td class="center" colspan="2"><input type="submit" value="{lang_ok}" name="submit" /></td>
                    <td class="left" colspan="2"><input name="done" type="button" value="{lang_done}" onClick="self.location.href='{done_url}'" /></td>
                  </tr>
                </table>
              </td>
            </tr>
          </table>
        </td>
      </tr>
    </table>
  </div>
  <div id="tabcontent3" class="activetab">
    <table id="tab3" class="basic" style="visibility: visible;">
      <tr class="left"><td colspan="4">{lang_history}</td></tr>
      <tr class="top">
        <td colspan="4">
        	<table class="basic">
							<tr class="bg_color2">
								<td><b>{lang_date}</b></td>
								<td><b>{lang_user}</b></td>
								<td><b>{lang_action}</b></td>
								<td><b>{lang_old_value}</b></td>
								<td><b>{lang_new_value}</b></td>
							</tr>
					{rows_history}
				</table>
        </td>
      </tr>
    </table>
  </div>
</form>

<script language="JavaScript1.1" type="text/javascript"><!--
  var tab = new Tabs(3,'activetab','inactivetab','tab','tabcontent','','','tabpage');
  tab.init();
  // -->
</script>
<!-- END form -->

