one($product_id); if ($product) { $order = Dever::db('service/order')->one(array('product_id' => $product_id, 'order_id' => $order_id, 'uid' => $uid)); if ($order) { Dever::db('service/order')->update(array('where_id' => $order['id'], 'status' => 2)); } } } } }