私人领地

ecshop 订单-》订单状态 2

// 判断订单状态
    public function get_order_status($os,$ps,$ss){
        $arr = array('已取消','待付款','待发货','待收货','确认收货','无效');
        if($os==OS_CANCELED){ 
            $str = $arr[0];    
        }elseif($os ==OS_INVALID ){   // 无效
            $str = $arr[5];
        }elseif($ps ==PS_PAYED && $ss ==SS_RECEIVED){   // 确认收货
            $str = $arr[4];
        }elseif($ps ==PS_PAYED && $ss ==SS_SHIPPED){
            $str = $arr[3];    
        }elseif($ps == PS_PAYED && $ss==SS_UNSHIPPED){   // 待发货
            $str = $arr[2];
        }elseif($ps ==PS_UNPAYED){
            $str = $arr[1];
        }else{
            $str = '11111';    
        }
        return $str;    
        //return OS_INVALID;
    }

 

posted @ 2016-01-08 14:36  狂奔的蜗牛Snails  阅读(187)  评论(0编辑  收藏  举报