From 3eed1ea53cb7641cfe65a730964cd42b3cada8dd Mon Sep 17 00:00:00 2001 From: Jason Irish Date: Mon, 30 Oct 2023 17:07:47 -0500 Subject: [PATCH] BUGFIX tests --- src/Extension/ProductFileCollectionDataExtension.php | 8 ++++---- src/Model/ProductFile.php | 4 ++-- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/Extension/ProductFileCollectionDataExtension.php b/src/Extension/ProductFileCollectionDataExtension.php index 1d692fd..e681730 100644 --- a/src/Extension/ProductFileCollectionDataExtension.php +++ b/src/Extension/ProductFileCollectionDataExtension.php @@ -28,15 +28,15 @@ public function updateCollectionForm(&$form) $fields = $form->Fields(); $fields->insertAfter( + 'Title', DropdownField::create('CategoryID', 'Category', ProductCategory::get()->map()) - ->setEmptyString('All categories'), - 'Title' + ->setEmptyString('All categories') ); $fields->insertAfter( + 'CategoryID', DropdownField::create('Products__ID', 'Product', Product::get()->map()) - ->setEmptyString('All products'), - 'CategoryID' + ->setEmptyString('All products') ); $fields->removeByName([ diff --git a/src/Model/ProductFile.php b/src/Model/ProductFile.php index 44753d1..3a2e9c3 100644 --- a/src/Model/ProductFile.php +++ b/src/Model/ProductFile.php @@ -85,12 +85,12 @@ public function getCMSFields() ); $fields->insertBefore( + 'Content', UploadField::create('Image') ->setAllowedMaxFileNumber(1) ->setFolderName('Uploads/ProductDocs/Images') ->setAllowedFileCategories('image') - ->setDescription('Optional preview image of file'), - 'Content' + ->setDescription('Optional preview image of file') ); return $fields;