feat(withdraw): 后台支持提现总开关与方式过滤并升级钱包与提现页面体验
这个提交包含在:
@@ -47,6 +47,9 @@ class Config extends Common
|
||||
}
|
||||
$config[self::getShortCode($row)] = $row->value;
|
||||
}
|
||||
if ($code === 'shop.recharge_withdraw.withdraw' && !isset($config['status'])) {
|
||||
$config['status'] = !empty($config['methods']) ? 1 : 0;
|
||||
}
|
||||
}
|
||||
// 设置配置缓存
|
||||
cache("config:{$code}", $config);
|
||||
@@ -124,6 +127,19 @@ class Config extends Common
|
||||
$config->value = $value;
|
||||
$config->save();
|
||||
}
|
||||
} else {
|
||||
// 自动补齐缺失的提现开关配置项,确保热更新无缝落地
|
||||
if ($code === 'shop.recharge_withdraw.withdraw.status') {
|
||||
self::create([
|
||||
'code' => $code,
|
||||
'parent_code' => 'shop.recharge_withdraw.withdraw',
|
||||
'name' => '开启提现',
|
||||
'type' => 'boolean',
|
||||
'value' => (string)intval($value),
|
||||
'rule' => 'required',
|
||||
'weigh' => 50
|
||||
]);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
在新工单中引用
屏蔽一个用户