feat(edit): 定价试算开发、SKU 样式功能修改

This commit is contained in:
R524809
2026-09-29 17:50:19 +08:00
parent 84b230e69a
commit 0a303414d8
52 changed files with 4278 additions and 1393 deletions
+2 -6
View File
@@ -101,11 +101,7 @@ export function draftPricingEnabled(
nodeEnvironment: Environment['NODE_ENV'],
setting: Environment['PRICING_ALLOW_DRAFT_RATES'],
): boolean {
return (
nodeEnvironment !== 'production' &&
(setting === 'true' ||
(nodeEnvironment === 'development' && setting === 'auto'))
);
return setting === 'true' || (setting === 'auto' && nodeEnvironment !== 'test');
}
export type AppConfig = Omit<
Environment,
@@ -152,7 +148,7 @@ function createAppConfig(environment: Environment): AppConfig {
objectStorageSecretKey,
objectStorageForcePathStyle:
environment.OBJECT_STORAGE_FORCE_PATH_STYLE === 'true',
// 草稿费率仅用于本地商品编辑联调,生产配置无法开启。
// 草稿费率默认可参与报价;仍可通过环境配置限制新试算。
pricingAllowDraftRates: draftPricingEnabled(
environment.NODE_ENV,
environment.PRICING_ALLOW_DRAFT_RATES,