diff --git a/components/UploadModal.tsx b/components/UploadModal.tsx index 0a1ecad3..83cb4394 100644 --- a/components/UploadModal.tsx +++ b/components/UploadModal.tsx @@ -46,6 +46,7 @@ import { import { buildFormData, uploadSingleFile, submitFormData } from '@/components/upload/file-upload-handlers' import { requiresCategoryAndScene, requiresProductCategoryName, requiresRenderer, shouldAutoFillGeneral } from '@/lib/material-validation' import { MATERIAL_TYPE_OPTIONS, type MaterialTypeOption } from '@/lib/material-type-options' +import { isXiaoyiDeliveryMaterial } from '@/lib/xiaoyi-delivery-material' import { isBatchVideoMaterialType, isVideoMaterialType, @@ -2058,9 +2059,10 @@ export default function UploadModal({ onClose, onSuccess, materialTypeCounts = { value={materialType} onChange={setMaterialType} disabled={interactionLocked} - options={accessScope === 'operations_g' ? [...MATERIAL_TYPE_OPTIONS] : availableMaterialTypes.length > 0 + options={(accessScope === 'operations_g' ? [...MATERIAL_TYPE_OPTIONS] : availableMaterialTypes.length > 0 ? availableMaterialTypes - : MATERIAL_TYPE_OPTIONS.filter((type) => !SPECIAL_UPLOAD_TYPES.includes(type as typeof SPECIAL_UPLOAD_TYPES[number]))} + : MATERIAL_TYPE_OPTIONS.filter((type) => !SPECIAL_UPLOAD_TYPES.includes(type as typeof SPECIAL_UPLOAD_TYPES[number]))) + .filter((type) => !isXiaoyiDeliveryMaterial(type))} counts={materialTypeCounts} />