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

📄 sal_data.php

📁 极限网络智能办公系统 Office Automation V3.0官方100%源代码.
💻 PHP
字号:
<?
include_once("inc/auth.php");
include_once("inc/utility_all.php");
?>

<html>
<head>
<title>工资数据查阅</title>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
</head>

<body class="bodycolor" topmargin="5">

<?
 $query = "SELECT * from USER where USER_ID='$USER_ID'";
 $cursor= exequery($connection,$query);
 if($ROW=mysql_fetch_array($cursor))
 {
    $USER_NAME=$ROW["USER_NAME"];
 }
?>
<table border="0" width="100%" cellspacing="0" cellpadding="3" class="small">
  <tr>
    <td class="Big"><img src="/images/menu/salary.gif" WIDTH="22" HEIGHT="20" align="absmiddle"><span class="big3"> 工资数据查阅(<?=$USER_NAME?>)</span>
    </td>
  </tr>
</table>

<div align="center">

<?
 $connection=OpenConnection();

 //-- 首先查询是否已查阅过数据 --
 if($RECALL=="")
 {
   $query="select * from SAL_DATA where FLOW_ID=$FLOW_ID and USER_ID='$USER_ID'";
   $cursor= exequery($connection,$query);
   if($ROW=mysql_fetch_array($cursor))
   {
     for($I=1;$I<=50;$I++)
     {
       $STR="S".$I;
       $$STR=format_money($ROW["$STR"]);
     }

     $OPERATION=2; //-- 将执行数据更新 --
   }
   else
     $OPERATION=1; //-- 将执行数据插入 --
 }

 //-- 生成查阅项目 --
 $query="select * from SAL_ITEM";
 $cursor= exequery($connection,$query);
 $ITEM_COUNT=0;

 while($ROW=mysql_fetch_array($cursor))
 {
    $ITEM_COUNT++;

    $ITEM_ID=$ROW["ITEM_ID"];
    $ITEM_NAME=$ROW["ITEM_NAME"];

    $S_ID="S".$ITEM_ID;
    $S_NAME=$S_ID."_NAME";

    if($ITEM_COUNT==1)
    {
?>

    <table border="0" cellspacing="1" width="450" class="small" bgcolor="#000000" cellpadding="3">

<?
    }
?>
    <tr class="TableData">
      <td nowrap align="center" width="110"><?=$ITEM_NAME?></td>
      <td nowrap align="center"><?=$$S_ID?>
      </td>
    </tr>
<?
 }

 if($ITEM_COUNT>0)
 {
?>
    <thead class="TableHeader">
      <td nowrap align="center">工资项目</td>
      <td nowrap align="center">金额</td>
    </thead>
    </table>
<?
 }
 else
    message("","尚未定义工资项目,请与财务主管联系!");
?>

</div>

</body>
</html>

⌨️ 快捷键说明

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