⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 index.php

📁 通达OA2007SE源代码 非常好的
💻 PHP
字号:
<?
  include_once 'inc/auth.php';
  include_once 'inc/utility_all.php';
  echo '
<html>
<head>
<title>固定资产查询</title>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
';
  echo '<s';
  echo 'cript Language="JavaScript">
function td_calendar(fieldname)
{
  myleft=document.body.scrollLeft+event.clientX-event.offsetX-80;
  mytop=document.body.scrollTop+event.clientY-event.offsetY+140;
  window.showModalDialog("/inc/calendar.php?FIELDNAME="+fieldname,self,"edge:raised;scroll:0;status:0;help:0;resizable:1;dialogWidth:280px;dialogHeight:215px;dialogTop:"+mytop+"px;dialogLeft:"+myleft';
  echo '+"px");
}
//verify for netscape/mozilla
var isNS4 = (navigator.appName=="Netscape")?1:0;
function check_input()
{
  if(!isNS4)
  {
  	 if(event.keyCode < 45 || event.keyCode > 57)
  	    event.returnValue = false;
  }
  else
  {
  	 if(event.which < 45 || event.which > 57)
  	    return false;
  }  
}
function  ForDight(Dight,How)  
{  
           Dight  =  Math.round  (Di';
  echo 'ght*Math.pow(10,How))/Math.pow(10,How);  
           return  Dight;  
} 
function check_value(obj)
{
   if(obj.value=="")
      return;
   val=parseFloat(obj.value);
   if(isNaN(val))
   {
      alert("非法的数字");
      obj.focus();
      return;
   }
   if(val<0)
   {
      alert("数值不能小于0");
      obj.focus();
      return;
   }
   obj.value=ForDight(val,2);';
  echo '
   value_array=obj.value.split(".");
   if(value_array.length==1)
   {
   	  obj.value=value_array[0]+".00";
   	  return;
   }
   else if(value_array.length==2)
   {
   	  if(value_array[1].length==0)
   	    obj.value=value_array[0]+".00";
   	  else if(value_array[1].length==1)
   	    obj.value=value_array[0]+"."+value_array[1]+"0";
   	  else if(value_array[1].length>=2)
   	';
  echo '    obj.value=value_array[0]+"."+value_array[1].substr(0,2);
   }
}
</script>
</head>
';
  $query = 'SELECT * from CP_ASSETCFG';
  $cursor = exequery ($connection, $query);
  if ($ROW = mysql_fetch_array ($cursor))
  {
    $BAL_SORT = $ROW['BAL_SORT'];
  }
  echo '<body class="bodycolor" topmargin="5" onload="form1.CPTL_NO.focus();">
<table border="0" width="90%" cellspacing="0" cellpadding="3" class="small">
  <tr>
    <td class="Big"><img src="/images/menu/asset.gif"  width="24" height="24">';
  echo '<s';
  echo 'pan class="big3"> 固定资产查询</span>
    </td>
  </tr>
</table>
<table border="0" width="500" cellpadding="2" cellspacing="1" align="center" bgcolor="#000000" class="small">
  <form enctype="multipart/form-data" action="query.php"  method="post" name="form1">
    <tr>
      <td nowrap class="TableData" width="100"> 资产编号:</td>
      <td class="TableData"> 
        <input type="text" name="C';
  echo 'PTL_NO" size="20" maxlength="100" class="BigInput" value="">
      </td>
    </tr>
    <tr>
      <td nowrap class="TableData" width="100"> 资产名称:</td>
      <td class="TableData"> 
        <input type="text" name="CPTL_NAME" size="30" maxlength="200" class="BigInput" value="">
      </td>
    </tr>
    <tr>
      <td nowrap class="TableData" width="100"> 资产类别:</td>
      <td class="TableDa';
  echo 'ta"> 
      ';
  echo '<s';
  echo 'elect name="TYPE_ID" class="BigSelect">
        <option value="">所有类别</option>
        <option value="0">未指定类别</option>
';
  $query = 'SELECT * from CP_ASSET_TYPE order by TYPE_NO';
  $cursor = exequery ($connection, $query);
  while ($ROW = mysql_fetch_array ($cursor))
  {
    $TYPE_ID = $ROW['TYPE_ID'];
    $TYPE_NAME = $ROW['TYPE_NAME'];
    echo '        <option value="';
    echo $TYPE_ID;
    echo '">';
    echo $TYPE_NAME;
    echo '</option>
';
  }
  echo '      </select>
      </td>
    </tr>
    <tr>
      <td nowrap class="TableData" width="100"> 所属部门:</td>
      <td class="TableData">
      ';
  echo '<s';
  echo 'elect name="DEPT_ID" class="BigSelect">
        <option value="">所有部门</option>
        <option value="0">未指定部门</option>
';
  echo my_dept_tree (0, $DEPT_ID, 0);
  echo '      </select>
      </td>
    </tr>
    <tr>
      <td nowrap class="TableData" width="100"> 资产性质:</td>
      <td class="TableData"> 
      ';
  echo '<s';
  echo 'elect name="CPTL_KIND" class="BigSelect">
        <option value="" selected></option>
        <option value="01">资产</option>
        <option value="02">费用</option>
      </select>
      </td>
    </tr>
    <tr>
      <td nowrap class="TableData" width="100"> 增加类型:</td>
      <td class="TableData"> 
      ';
  echo '<s';
  echo 'elect name="PRCS_ID" class="BigSelect">
        <option value=""></option>
';
  $query = 'SELECT * from CP_PRCS_PROP where left(PRCS_CLASS,1)=\'A\' order by PRCS_CLASS';
  $cursor = exequery ($connection, $query);
  while ($ROW = mysql_fetch_array ($cursor))
  {
    $PRCS_ID = $ROW['PRCS_ID'];
    $PRCS_LONG_DESC = $ROW['PRCS_LONG_DESC'];
    echo '        <option value="';
    echo $PRCS_ID;
    echo '">';
    echo $PRCS_LONG_DESC;
    echo '</option>
';
  }
  echo '      </select>
      </td>
    </tr>
    <tr>
      <td nowrap class="TableData" width="100"> 减少类型:</td>
      <td class="TableData"> 
      ';
  echo '<s';
  echo 'elect name="DCR_PRCS_ID" class="BigSelect">
        <option value=""></option>
';
  $query = 'SELECT * from CP_PRCS_PROP where left(PRCS_CLASS,1)=\'D\' order by PRCS_CLASS';
  $cursor = exequery ($connection, $query);
  while ($ROW = mysql_fetch_array ($cursor))
  {
    $PRCS_ID = $ROW['PRCS_ID'];
    $PRCS_LONG_DESC = $ROW['PRCS_LONG_DESC'];
    echo '        <option value="';
    echo $PRCS_ID;
    echo '">';
    echo $PRCS_LONG_DESC;
    echo '</option>
';
  }
  echo '      </select>
      </td>
    </tr>
    <tr>
      <td nowrap class="TableData" width="100"> 折旧:</td>
      <td class="TableData"> 
        ';
  echo '<s';
  echo 'elect name="FINISH_FLAG" class="BigSelect">
          <option value="" selected></option>
          <option value="1">提足</option>
          <option value="0">未提足</option>
      </select>
      </td>
    </tr>
    <tr>
      <td nowrap class="TableData" width="100"> 资产原值:</td>
      <td class="TableData"> 
        大于等于 <input type="text" name="CPTL_VAL_MIN" size="10" maxlength="23" class=';
  echo '"BigInput" value="" onkeypress="check_input()" onblur="check_value(this)" style="text-align:right;"> ';
  if (($BAL_SORT == '02'))
  {
    echo '%';
  }
  echo '&nbsp;&nbsp;&nbsp;&nbsp;
        小于等于 <input type="text" name="CPTL_VAL_MAX" size="10" maxlength="23" class="BigInput" value="" onkeypress="check_input()" onblur="check_value(this)" style="text-align:right;"> ';
  if (($BAL_SORT == '02'))
  {
    echo '%';
  }
  echo '      </td>
    </tr>
    <tr>
      <td nowrap class="TableData" width="100"> ';
  if (($BAL_SORT == '01'))
  {
    echo '残值:';
  }
  else
  {
    echo '残值率:';
  }
  echo '</td>
      <td class="TableData"> 
        大于等于 <input type="text" name="CPTL_BAL_MIN" size="10" maxlength="23" class="BigInput" value="" onkeypress="check_input()" onblur="check_value(this)" style="text-align:right;"> ';
  if (($BAL_SORT == '02'))
  {
    echo '%';
  }
  echo '&nbsp;&nbsp;&nbsp;&nbsp;
        小于等于 <input type="text" name="CPTL_BAL_MAX" size="10" maxlength="23" class="BigInput" value="" onkeypress="check_input()" onblur="check_value(this)" style="text-align:right;"> ';
  if (($BAL_SORT == '02'))
  {
    echo '%';
  }
  echo '      </td>
    </tr>
    <tr>
      <td nowrap class="TableData" width="100"> 增加日期:</td>
      <td class="TableData"> 
        开始日期:<input type="text" name="CREATE_DATE_MIN" size="12" maxlength="10" class="BigInput" value="">
        <img src="/images/menu/calendar.gif" border="0" style="cursor:hand" onclick="td_calendar(\'form1.CREATE_DATE_MIN\');"> <br>
        结束日期:<input type="text"';
  echo ' name="CREATE_DATE_MAX" size="12" maxlength="10" class="BigInput" value="">
        <img src="/images/menu/calendar.gif" border="0" style="cursor:hand" onclick="td_calendar(\'form1.CREATE_DATE_MAX\');"> 
      </td>
    </tr>
    <tr>
      <td nowrap class="TableData" width="100"> 减少日期:</td>
      <td class="TableData"> 
        开始日期:<input type="text" name="DCR_DATE_MIN" size="12" maxleng';
  echo 'th="10" class="BigInput" value="">
        <img src="/images/menu/calendar.gif" border="0" style="cursor:hand" onclick="td_calendar(\'form1.DCR_DATE_MIN\');"> <br>
        结束日期:<input type="text" name="DCR_DATE_MAX" size="12" maxlength="10" class="BigInput" value="">
        <img src="/images/menu/calendar.gif" border="0" style="cursor:hand" onclick="td_calendar(\'form1.DCR_DATE_MAX\');"> 
      ';
  echo '</td>
    </tr>
    <tr>
      <td nowrap class="TableData" width="100"> 启用日期:</td>
      <td class="TableData"> 
        开始日期:<input type="text" name="FROM_YYMM_MIN" size="12" maxlength="10" class="BigInput" value="">
        <img src="/images/menu/calendar.gif" border="0" style="cursor:hand" onclick="td_calendar(\'form1.FROM_YYMM_MIN\');"> <br>
        结束日期:<input type="text" name="FRO';
  echo 'M_YYMM_MAX" size="12" maxlength="10" class="BigInput" value="">
        <img src="/images/menu/calendar.gif" border="0" style="cursor:hand" onclick="td_calendar(\'form1.FROM_YYMM_MAX\');"> 
      </td>
    </tr>
    <tr>
      <td nowrap class="TableData" width="100"> 保管人:</td>
      <td class="TableData"> 
        <input type="text" name="KEEPER" size="15" maxlength="20" class="BigInput" value="';
  echo '">
      </td>
    </tr>
    <tr>
      <td nowrap class="TableData" width="100"> 备注:</td>
      <td class="TableData"> 
        <textarea cols="35" name="REMARK" rows="2" class="BigInput" wrap="yes"></textarea>
      </td>
    </tr>
    <tr align="center" class="TableControl">
      <td colspan="2" nowrap>
        <input type="submit" value="查询" class="BigButton">&nbsp;&nbsp;
        <input ty';
  echo 'pe="button" value="重填" class="BigButton" onclick="location=\'index.php\'">&nbsp;&nbsp;
      </td>
    </tr>
  </table>
</form>
</body>
</html>';
?>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -