<?php
/**
 * 订单付款状态查询
 */
require_once("../../includes/fun.global.php");
if (empty((int)$_QET['order'])) dies(-1, '403');
$srow = $DB->get_row("SELECT * FROM sky_pay WHERE `order`='{$_QET['order']}' limit 1 for update");
if ($srow['state'] == 1) {
    query::OrderCookie($_QET['order']);
    dier(['code' => 1, 'msg' => '订单已付款', 'url' => is_https(false) . href() . '/?mod=query']);
} else dies(-1, '订单未付款');