= $giveCouponMinPrice) WechatUser::userTakeOrderGiveCoupon($uid); if(!($res1 && $res2)) exception('收货失败!'); } /** * 修改状态 为已收货 admin模块 * @param $order * @throws \Exception */ public static function storeProductOrderTakeDeliveryAdmin($order) { $res1 = AdminStoreOrder::gainUserIntegral($order); $res2 = User::backOrderBrokerage($order); AdminStoreOrder::orderTakeAfter($order); if(!($res1 && $res2)) exception('收货失败!'); } /** * 修改状态为 已退款 admin模块 * @param $data * @param $oid * @return bool|mixed * @throws \think\db\exception\DataNotFoundException * @throws \think\db\exception\ModelNotFoundException * @throws \think\exception\DbException */ public static function storeProductOrderRefundY($data,$oid){ $order = AdminStoreOrder::where('id', $oid)->find(); if($order['is_channel']) return AdminStoreOrder::refundRoutineTemplate($oid); //TODO 小程序余额退款模板消息 else return AdminStoreOrder::refundTemplate($data,$oid);//TODO 公众号余额退款模板消息 } /** * TODO 后台余额退款 * @param $product * @param $refund_data * @throws \Exception */ public static function storeOrderYueRefund($product,$refund_data) { $res = AdminStoreOrder::integralBack($product['id']); if(!$res) exception('退积分失败!'); } /** * 订单退积分 * @param $product $product 商品信息 * @param $back_integral $back_integral 退多少积分 */ public static function storeOrderIntegralBack($product,$back_integral){ } public static function computedOrder() { } }