diff --git a/src/Controller/PartController.php b/src/Controller/PartController.php index d6acb36b..b11a5c90 100644 --- a/src/Controller/PartController.php +++ b/src/Controller/PartController.php @@ -229,6 +229,10 @@ class PartController extends AbstractController $dto = $infoRetriever->getDetails($providerKey, $providerId); $new_part = $infoRetriever->dtoToPart($dto); + if ($new_part->getCategory() === null || $new_part->getCategory()->getID() === null) { + $this->addFlash('warning', t("part.create_from_info_provider.no_category_yet")); + } + return $this->renderPartForm('new', $request, $new_part, [ 'info_provider_dto' => $dto, ]); diff --git a/translations/messages.en.xlf b/translations/messages.en.xlf index b63c1377..9c45b4be 100644 --- a/translations/messages.en.xlf +++ b/translations/messages.en.xlf @@ -12257,5 +12257,11 @@ Please note, that you can not impersonate a disabled user. If you try you will g Update existing part from info provider + + + part.create_from_info_provider.no_category_yet + Category could not be automatically determined by the info provider. Review the data and select the category manually. + +