123456789101112131415161718192021222324252627282930 |
- <?php
- namespace Product\Lib;
- use Dever;
- class Pay
- {
- /**
- * 支付成功后,调取的接口
- *
- * @return mixed
- */
- public function act($param)
- {
- $product_id = $param['pay_product_id'];
- $uid = $param['pay_uid'];
- $cash = $param['pay_cash'];
- $order_id = $param['pay_order_id'];
- $status = $param['pay_status'];
- $msg = $param['pay_msg'];
- $order = Dever::db('product/order')->one(array('order_id' => $order_id, 'uid' => $uid));
- if ($status == 2 && $order) {
- Dever::db('product/order')->update(array('where_id' => $order['id'], 'status' => 2));
- } else {
- Dever::db('product/order')->update(array('where_id' => $order['id'], 'status' => 3));
- }
- }
- }
|