|
|
@@ -152,6 +152,9 @@ class PurchaseController extends BaseController
|
|
|
if ($info->status != 1) {
|
|
|
util::fail('订单不是待付款状态');
|
|
|
}
|
|
|
+ if ($info->book == 1) {
|
|
|
+ util::fail('预售不能记欠款');
|
|
|
+ }
|
|
|
|
|
|
$ghsId = $info->ghsId;
|
|
|
$ghs = GhsClass::getGhsInfo($ghsId);
|
|
|
@@ -264,6 +267,11 @@ class PurchaseController extends BaseController
|
|
|
$customId = $info['customId'] ?? 0;
|
|
|
$custom = CustomClass::getById($customId);
|
|
|
$hasDebtPay = $custom['debt'] ?? 0;
|
|
|
+ $book = $info['book'] ?? 0;
|
|
|
+ //预售不能记欠款
|
|
|
+ if ($book == 1) {
|
|
|
+ $hasDebtPay = 0;
|
|
|
+ }
|
|
|
$info['hasDebtPay'] = $hasDebtPay;
|
|
|
$info['balance'] = $this->shop->balance ?? 0;
|
|
|
|