📄 send_mobile.php
字号:
<?
include_once("inc/auth.php");
?>
<html>
<head>
<title>手机工资条</title>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<script>
function func_find(select_obj,option_text)
{
pos=option_text.indexOf("] ")+1;
option_text=option_text.substr(0,pos);
for (j=0; j<select_obj.options.length; j++)
{
str=select_obj.options(j).text;
if(str.indexOf(option_text)>=0)
return j;
}//for
return j;
}
function func_insert()
{
for (i=select2.options.length-1; i>=0; i--)
{
if(select2.options(i).selected)
{
option_text=select2.options(i).text;
option_value=select2.options(i).value;
option_style_color=select2.options(i).style.color;
var my_option = document.createElement("OPTION");
my_option.text=option_text;
my_option.value=option_value;
my_option.style.color=option_style_color;
//pos=func_find(select1,option_text);
select1.add(my_option);
select2.remove(i);
}
}//for
}
function func_delete()
{
for (i=select1.options.length-1; i>=0; i--)
{
if(select1.options(i).selected)
{
option_text=select1.options(i).text;
option_value=select1.options(i).value;
var my_option = document.createElement("OPTION");
my_option.text=option_text;
my_option.value=option_value;
//pos=func_find(select2,option_text);
select2.add(my_option);
select1.remove(i);
}
}//for
}
function func_select_all1()
{
for (i=select1.options.length-1; i>=0; i--)
select1.options(i).selected=true;
}
function func_select_all2()
{
for (i=select2.options.length-1; i>=0; i--)
select2.options(i).selected=true;
}
function mysubmit()
{
fld_str="";
for (i=0; i< select1.options.length; i++)
{
options_value=select1.options(i).value;
fld_str+=options_value+",";
}
document.all("STYLE").value=fld_str;
}
function clear_user2()
{
document.form1.COPY_TO_NAME.value="";
document.form1.COPY_TO_ID.value="";
}
function LoadWindow2()
{
URL="/module/user_select?ID=2";
loc_x=document.body.scrollLeft+event.clientX-event.offsetX-100;
loc_y=document.body.scrollTop+event.clientY-event.offsetY+170;
//window.open(URL,"read_notify","height=400,width=550,status=1,toolbar=no,menubar=no,location=no,scrollbars=yes,top=150,left=150,resizable=yes");
window.showModalDialog(URL,self,"edge:raised;scroll:0;status:0;help:0;resizable:1;dialogWidth:350px;dialogHeight:350px;dialogTop:"+loc_y+"px;dialogLeft:"+loc_x+"px");
}
function exreport()
{
fld_str="";
for (i=0; i< select1.options.length; i++)
{
options_value=select1.options(i).value;
fld_str+=options_value+",";
}
URL="mobile_result.php?COPY_TO_ID="+document.all("COPY_TO_ID").value+"&fld_str="+fld_str+"&FLOW_ID="+document.all("FLOW_ID").value;
location=URL;
}
</script>
</head>
<body class="bodycolor" topmargin="5" >
<table border="0" width="100%" cellspacing="0" cellpadding="3" class="small">
<tr>
<td class="Big"><img src="/images/menu/mobile_sms.gif" WIDTH="22" HEIGHT="20" align="absmiddle"><span class="big3"> 手机工资条</span>
</td>
</tr>
</table>
<br>
<div align="center">
<table border="0" cellspacing="1" class="small" bgcolor="#000000" cellpadding="3" align="center" >
<tr>
<form name="form1">
<td nowrap class="TableContent"> 人员: </td>
<td nowrap class="TableData">
<input type="hidden" name="COPY_TO_ID" value="">
<textarea cols=40 name="COPY_TO_NAME" rows=3 class="BigStatic" wrap="yes" readonly></textarea>
<input value="选择" type="button" onClick="LoadWindow2()" class="SmallButton" title="选择人员" name="button">
<input type="button" value="清空" class="SmallButton" onClick="clear_user2()" title="清空人员" name="button">
</td>
</form>
</tr>
<tr>
<td nowrap class="TableContent"> 输出内容:</td>
<td nowrap class="TableData" align="left">
<table width="150" border="1" cellspacing="0" cellpadding="3" bordercolorlight="#000000" bordercolordark="#FFFFFF" class="small">
<tr bgcolor="#CCCCCC">
<td align="center"><b>显示字段</b></td>
<td align="center"> </td>
<td align="center" valign="top"><b>可选字段</b></td>
</tr>
<tr>
<td valign="top" align="center" bgcolor="#CCCCCC">
<select name="select1" ondblclick="func_delete();" MULTIPLE style="width:200;height:280">
<?
$query = "SELECT STYLE from SAL_FLOW where FLOW_ID=$FLOW_ID";
$cursor= exequery($connection,$query);
if($ROW=mysql_fetch_array($cursor))
{
$STYLE=$ROW["STYLE"];
}
if ($STYLE!="")
{
$STYLE_ARRAY=explode(",",$STYLE);
$ARRAY_COUNT=sizeof($STYLE_ARRAY);
$COUNT=0;
if($STYLE_ARRAY[$ARRAY_COUNT-1]=="")$ARRAY_COUNT--;
for($I=0;$I<$ARRAY_COUNT;$I++)
{
$query1 = "select ITEM_ID,ITEM_NAME from SAL_ITEM where ITEM_ID='$STYLE_ARRAY[$I]'";
$cursor1= exequery($connection,$query1);
if($ROW=mysql_fetch_array($cursor1))
{
$ITEM_NAME=$ROW["ITEM_NAME"];
$ITEM_ID=$ROW["ITEM_ID"];
}
?>
<option value="<?=$ITEM_ID?>"><?=$ITEM_NAME?></option>
<?
}
}
?>
</select>
<input type="button" value=" 全 选 " onclick="func_select_all1();" class="SmallInput">
</td>
<td align="center" bgcolor="#999999">
<input type="button" class="SmallInput" value=" ← " onclick="func_insert();">
<br><br>
<input type="button" class="SmallInput" value=" → " onclick="func_delete();">
</td>
<td align="center" valign="top" bgcolor="#CCCCCC">
<select name="select2" ondblclick="func_insert();" MULTIPLE style="width:200;height:280">
<?
$query = "SELECT ITEM_ID,ITEM_NAME from SAL_ITEM where ISPRINT='1' ORDER BY `ITEM_ID`";
$cursor=exequery($connection,$query);
while($ROW=mysql_fetch_array($cursor))
{
$ITEM_ID=$ROW["ITEM_ID"];
$ITEM_NAME=$ROW["ITEM_NAME"];
$sign=0;
for($I=0;$I<$ARRAY_COUNT;$I++)
{
if($STYLE_ARRAY[$I]==$ITEM_ID)$sign=1;
}
if($sign==0)
{
?>
<option value="<?=$ITEM_ID?>"><?=$ITEM_NAME?></option>
<?
}
}
?>
</select>
<input type="button" value=" 全 选 " onclick="func_select_all2();" class="SmallInput">
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td nowrap class="TableControl" colspan="4" align="center">
<input type="hidden" name="FLOW_ID" value="<?=$FLOW_ID?>">
<input type="hidden" name="STYLE" value="">
<input type="submit" value="确定" class="BigButton" name="button" onClick="exreport()">
<input type="submit" value="返回" class="BigButton" name="button" onclick="location='index.php'">
</td>
</tr>
</table>
</div>
</body>
</html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -