Location: PHPKode > projects > CoreAsset > coreasset/templates/add_equip.tpl
{include file="head.tpl"}
{include file="left.tpl"}

<table width="100%" height="100%" border="0" cellspacing="0" cellpadding="0" align="center">
<tr>
<td height="21"><table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td><img src="images/corner9.gif" width="5" height="21"></td>
<td width="99%" class="header"><span class="whitetext">
 Add Equipment
</span></td>
<td><img src="images/corner10.gif" width="5" height="21"></td>
</tr>
</table></td>
</tr>
<tr>
<td class="border3side" valign="top" height="100%"><table width="100%" height="100%" border="0" cellspacing="8" cellpadding="0">
<tr>
<td  valign="top">

<!-- #######################   Paste the Table to Table from here ############## -->

<table cellSpacing="0" cellPadding="0" width="98%" align="center" border="0">
          
          <!--tr>
            <td><img title alt src="images/blank.gif" width="1" height="1"></td>
          </tr>
          <tr>
            <td style="border-left: 1px solid #bbbbbb; border-right: 1px solid #bbbbbb" bgColor="#bbbbbb">
            <img title height="3" alt src="images/blank.gif" width="1" valign="top"></td>
		<td>	
          </tr>-->
          
            <!--<td style="border-left: 1px solid #bbbbbb; border-right: 1px solid #bbbbbb; padding-left: 18px; padding-right: 23px; padding-top: 11px" vAlign="top" bgColor="#ededed" height="180">-->
			<tr>
			<td>

            {if $status < 4}
            <table borderColor="#ffffff" cellSpacing="1" cellPadding="0" width="100%" border="0">
              <form name="f1" action="?act=add" method="post" onSubmit="return validate();">
			  {if $count_cat  != 0 }
                <tr>
                  <td class="txtbox_bgcolor" width="20%">
                  &nbsp;Equipment Name</td>
                  <td class="txtbox_bgcolor" width="33%">
                  <input name="equipment_name"  type="text" size="20" class="text"></td>
                </tr>

                <tr>
                  <td class="txtbox_bgcolor" width="20%">
                  &nbsp;Model Number</td>
                  <td class="txtbox_bgcolor" width="33%">
                  <input name="equipment_model"  type="text" size="20" class="text"></td>
                </tr>
				{/if}
                <tr>
                  {if $count_cat  != 0 }<td class="alttxtbox_bgcolor">&nbsp;Select A Category</td> {/if}
                  <td class="alttxtbox_bgcolor">
				  {if $mm_cat == ""}
				  <select name="category" id="category" >
				  <option value="0"> -- Select Category -- </option>
				  {section name=index loop=$category_id}
                   {if $category_id[index] != $cat_id_book}<option value="{$category_id[index]}">{$category_name[index]}</option>{/if}
                   {/section}
				  </select>
				  {else}
				 
				   <td class="txt" align="center" ><font color="#FF0000">&nbsp;{$mm_cat}</font></td>
				  {/if}
				  </td>
                </tr>
				<!--{if $count_cat  != 0}-->
                <tr>
				  <td class="btn_bg" colSpan="1">
                  <td class="btn_bg" colSpan="1">
				  
                  <input type="image" src="images/add_eqp.gif" name="add" {if $mm_cat != ''} disabled{/if}></td>
                </tr>
				<!--{/if}-->
              </form>
            </table>

            {else}
            <table cellSpacing="1" cellPadding="0" width="100%" border="0">
                <tr>
                  <td class="txt" align="center" width="20%" height="23">
                  <font color="RED">{$mes}</font>
                  </td>
                </tr>
             </table>
            {/if}
            </td>
          </tr>
          <!--<tr>
            <td style="border-left: 1px solid #bbbbbb; border-right: 1px solid #bbbbbb" bgColor="#bbbbbb">
            <img title height="4" alt src="images/blank.gif" width="1"></td>
          </tr>-->
          </table>
        </td>
      </tr>
    </table>


<!-- ########################      End Here ##########################-->

{include file="foot.tpl"}
{include file="foot.tpl"}

{literal}
<script language="Javascript">
function validate()
{
 if(document.f1.equipment_name.value=="")
 {
  alert("Please Enter Equipment Name !");
  document.f1.equipment_name.focus();
  return false;
 }
 if(document.f1.equipment_model.value=="")
 {
  alert("Please Enter Equipment Model !");
  document.f1.equipment_model.focus();
  return false;
 }
 if(document.f1.category.value=='0')
  {
   alert("Please Select A Category");
   document.f1.category.focus();
   return false;
  }
  return confirm("Are you sure? The Equipment will be added!");
}
</script>
{/literal}
Return current item: CoreAsset