<!-- $Id: gift_type_info.htm 7323 2007-03-19 05:28:24Z scottye $ -->
{include file="pageheader.htm"}
<div class="main-div">
  <form enctype="multipart/form-data" action="" method="post" name="theForm" onsubmit="return validate();">
    <table cellspacing="1" cellpadding="3">
      <tr>
        <td class="label">{$lang.lab_gift_type_name}:</td>
        <td><input type="text" name="gift_type_name" value="{$gift_type.gift_type_name|escape}" size="40" />
        {$lang.require_field}</td>
      </tr>
      <tr>
        <td class="label">{$lang.lab_min_amount}:</td>
        <td><input type="text" name="min_amount" value="{$gift_type.min_amount}" size="20" />{$lang.require_field}</td>
      </tr>
      <tr>
        <td class="label">{$lang.lab_max_amount}:</td>
        <td><input type="text" name="max_amount" value="{$gift_type.max_amount}" size="20" />{$lang.require_field}</td>
      </tr>
      <tr>
        <td class="label">{$lang.lab_max_count}:</td>
        <td><input type="text" name="max_count" value="{$gift_type.max_count}" />{$lang.require_field}</td>
      </tr>
      <tr>
        <td class="label">{$lang.lab_start_date}:</td>
        <td>{html_select_date field_order="YMD" prefix="start" time=$gift_type.start_date start_year="-1" end_year="+2" display_days=true month_format="%m"}</td>
      </tr>
      <tr>
        <td class="label">{$lang.lab_end_date}:</td>
        <td>{html_select_date field_order="YMD" prefix="end" time=$gift_type.end_date start_year="-1" end_year="+2" display_days=true month_format="%m"}</td>
      </tr>

      <tr align="center">
        <td colspan="2">
          <input type="hidden" name="gift_type_id" value="{$gift_type.gift_type_id}" />
          <input type="submit" value="{$lang.button_submit}" class="button" />
          <input type="reset" value="{$lang.button_reset}" class="button" />
          <input type="hidden" name="act" value="{$form_act}" />
        </td>
      </tr>
    </table>
  </form>
</div>
{insert_scripts files="../js/utils.js,validator.js"}
{literal}
<script language="JavaScript">
  onload = function()
  {
    startCheckOrder();
  }
  function validate()
  {
    var validator = new Validator('theForm');
    validator.required('gift_type_name', gift_type_name_null);
    validator.isNumber('min_amount', min_amount_not_number, true);
    validator.isNumber('max_amount', max_amount_not_number, true);
    validator.isNumber('max_count',  max_count_not_number, true);
    return validator.passed();
  }
</script>
{/literal}
{include file="pagefooter.htm"}