📄 acc_sc.php
字号:
<?php
////////////////////////////////////////////////////////
// Author by Shuweich
// Date : 2007.11.13
// 建站支持: http://www.shuweich.net
// 作者: Shuweich
// QQ: 1502384
// ICQ: 190492112
// MSN: shuweich@hotmail.com
// E-mail: root@shuweich.net
// E-mail: shuweich@163.com
////////////////////////////////////////////////////////
// 模块管理 by txdyz
// For 冲正(删除)流水帐
////////////////////////////////////////////////////////
include_once '../../mainfile.php';
## 扣积分 加入积分系数控制
if ( strlen($_REQUEST['user_card0']) == 13 ) {
$que = "select a.store_id,b.jfxs,a.user_card,b.bybz from ";
$que.= $xoopsDB->prefix("market_member")." a,".$xoopsDB->prefix("market_store")." b ";
$que.= " where a.store_id=b.store_id and a.user_card='".$_REQUEST['user_card0']."' limit 0,1";
$jfxs = $xoopsDB->fetchrow( $xoopsDB->query($que) );
## 扣积分 // 取整或四舍五入
if ( substr($jfxs[3],13,1) == '1' ) $kjf = round($_REQUEST['user_tach0'] * $jfxs[1],0); ## 四舍五入
elseif ( substr($jfxs[3],13,1) == '7' ) $kjf = floor($_REQUEST['user_tach0'] * $jfxs[1]); ## 取整
else $kjf = floor($_REQUEST['user_tach0']); ## 无系数 取整扣除
$upd = "update ".$xoopsDB->prefix("market_member");
$upd.= " set user_tach=user_tach-".$kjf.",user_ctach=user_ctach-".$kjf;
$upd.= " where store_id='".$_REQUEST['s_id0']."' and user_card='".$_REQUEST['user_card0']."'";
$upa = $upd;
$up0 = $xoopsDB->queryF($upd);
}
$upd = "update ".$xoopsDB->prefix("market_mdseri");
$upd.= " set shbz='2' ";
$upd.= " where store_id='".$_REQUEST['s_id0']."' and sdbh=".$_REQUEST['sdbh0'];
$up0 = $xoopsDB->queryF($upd);
if ($up0) {
echo "<script language='javascript'><!--\n";
echo " alert('冲正成功,流水号:".$_REQUEST['sdbh0']."');\n";
echo " window.close();\n";
echo "</script>\n";
} else {
echo "<script language='javascript'><!--\n";
echo " alert('冲正失败,流水号:".$_REQUEST['sdbh0']."');\n";
echo " window.close();\n";
echo "</script>\n";
}
include_once '../../footer.php';
?>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -