我自己扩展了后台的一些东西。
阿里云提示我有木马,又不告诉我木马到底是啥,郁闷。
- <?php
- /**
- * Created by PhpStorm.
- * User: vancy
- * Date: 15/12/30
- * Time: 下午5:06
- */
- if(!defined('IN_DISCUZ') || !defined('IN_ADMINCP') || !defined('IN_MAINPAGE')) {
- exit('Access Denied');
- }
- if ($id < 1) {
- cpmsg('错误!', array('action' => $action, 'operation' => $operation, 'do' => $do, 'id' => $id), 'error');
- }
- define('MODIFY_SHIPPING_FEE', 0);
- define('CONFIRM_ORDER', 1);
- define('CANCEL_ORDER', 2);
- define('SHIPPING', 3);
- define('RETURN_PAYMENT', 4);
- $dtl = C::t($table_name)->fetch_by_id($_GET['id']);
- if(!submitcheck('detailsubmit')) {
- $address = '';
- $address .= $area['all'][$dtl['province']]['areaName'];
- $address .= $area['all'][$dtl['city']]['areaName'];
- $address .= $area['all'][$dtl['district']]['areaName'];
- $address .= $dtl['address'];
- // step 1 确认订单
- if ($dtl['orderStatus'] == ORDER_STATUS_UNCONFIRMED) {
- $orderOperation = array(
- array(CONFIRM_ORDER, '确认订单'),
- array(CANCEL_ORDER, '取消订单'),
- );
- $defaultSelected = CONFIRM_ORDER;
- }
- // step 2 发货
- if ($dtl['orderStatus'] == ORDER_STATUS_CONFIRMED && $dtl['payStatus'] == PAYMENT_STATUS_ALREADY_PAID && $dtl['shippingStatus'] == SHIPPING_STATUS_NOT_SHIPPED) {
- $orderOperation = array(
- array(SHIPPING, '发货'),
- array(CANCEL_ORDER, '取消订单'),
- );
- $defaultSelected = SHIPPING;
- }
- // 退款
- if ($dtl['orderStatus'] > ORDER_STATUS_RETURN && $dtl['shippingStatus'] > SHIPPING_STATUS_NOT_SHIPPED && $dtl['payStatus'] == PAYMENT_STATUS_ALREADY_PAID) {
- $orderOperation = array(
- array(RETURN_PAYMENT, '退款'),
- );
- $defaultSelected = RETURN_PAYMENT;
- }
- showformheader("$action&operation=$operation&do=$do", 'enctype');
- showtableheader();
- if ($orderOperation) {
- // 注释留着扩展运费,需修改前台购买逻辑为先下单后付费
- // array_unshift($orderOperation, array(MODIFY_SHIPPING_FEE, '修改运费'));
- // showsetting('订单操作(除修改运费外,其它操作不可逆)', array('orderOperation', $orderOperation), MODIFY_SHIPPING_FEE, 'mradio');
- // showsetting('操作日志', 'operationLog', '', 'textarea', '', '', '');
- showsetting('订单操作', array('orderOperation', $orderOperation), $defaultSelected, 'mradio');
- showsetting('操作日志', 'operationLog', '', 'textarea', '', '', '仅提交订单操作时');
- }
- showsetting('订单ID', '', '', $dtl['orderId']);
- showsetting('订单编号', '', '', $dtl['orderSn']);
- showsetting('用户姓名', '', '', $dtl['consignee']);
- showsetting('用户手机', '', '', $dtl['phone']);
- showsetting('订单状态', '', '', $orderStatus[$dtl['orderStatus']]);
- showsetting('支付方式', '', '', $payType[$dtl['payType']]);
- showsetting('支付状态', '', '', $payStatus[$dtl['payStatus']]);
- showsetting('发货状态', '', '', $shippingStatus[$dtl['shippingStatus']]);
- showsetting('详细地址', '', '', $address);
- showsetting('商品价格', '', '', $dtl['goodsAmount']);
- showsetting('订单价格', '', '', $dtl['orderAmount']);
- if ($orderOperation) {
- // 注释留着扩展运费,需修改前台购买逻辑为先下单后付费
- // showsetting('运费', 'shippingFee', $dtl['shippingFee'], 'text');
- showsetting('', '', '', '');
- showreturn(array('noadd'), 2);
- showhiddenfields(array('id' => $_GET['id']));
- showhiddenfields(array('back_url' => $_GET['back_url']));
- showsubmit('detailsubmit', 'submit', '', '', '', false);
- }
- showtablefooter();
- showformfooter();
- } else {
- $orderOperation = intval($_GET['orderOperation']);
- $orderActionData = array(
- 'orderId' => $dtl['orderId'],
- 'uid' => $dtl['uid'],
- 'orderStatus' => $dtl['orderStatus'],
- 'shippingStatus' => $dtl['shippingStatus'],
- 'payStatus' => $dtl['payStatus'],
- 'actionNote' => dhtmlspecialchars(trim($_GET['operationLog'])),
- 'addTime' => TIMESTAMP,
- );
- // 确定/取消订单
- if (in_array($orderOperation, array(CONFIRM_ORDER, CANCEL_ORDER))) {
- $orderInfoData = array(
- 'orderStatus' => $orderOperation,
- );
- $orderActionData['orderStatus'] = $orderInfoData['orderStatus'];
- }
- // 发货
- if ($orderOperation == SHIPPING) {
- $orderInfoData = array(
- 'shippingStatus' => SHIPPING_STATUS_SHIPPED,
- );
- $orderActionData['shippingStatus'] = $orderInfoData['shippingStatus'];
- }
- // 退款
- if (in_array($orderOperation, array(RETURN_PAYMENT))) {
- $orderInfoData = array(
- 'shippingStatus' => SHIPPING_STATUS_RETURN,
- 'orderStatus' => ORDER_STATUS_RETURN,
- 'payStatus' => PAYMENT_STATUS_RETURNED_PAYMENT,
- );
- }
- // 修改运费
- if ($orderOperation == MODIFY_SHIPPING_FEE) {
- $orderInfoData = array(
- 'shippingFee' => doubleval($_GET['shippingFee']),
- );
- $orderActionData['actionNote'] = '修改运费';
- }
- $aid = C::t($orderActionTable)->insert($orderActionData, true);
- if ($aid > 0) {
- C::t($orderInfoTable)->update($id, $orderInfoData);
- // 退款
- if ($dtl['orderStatus'] > ORDER_STATUS_RETURN && $dtl['shippingStatus'] > SHIPPING_STATUS_NOT_SHIPPED && $dtl['payStatus'] == PAYMENT_STATUS_ALREADY_PAID) {
- // TODO
- }
- }
- cpmsg(($_GET['id'] > 0 ? $lang['edit'] : $lang['add']).'成功!', array('action' => $action, 'operation' => $operation, 'do' => $do, 'id' => $id), 'succeed');
- }
复制代码
我对比过服务器的文件和本地的文件,没有出入啊。是我哪里写的像木马? |