From d7b91d88d6aec4482fe35f8084219f98d7364771 Mon Sep 17 00:00:00 2001 From: Brady Wetherington Date: Tue, 5 Jan 2016 13:53:09 -0800 Subject: [PATCH] Allow setting 'no custom fields' from having a customfieldset enabled in a model. --- app/controllers/admin/ModelsController.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/app/controllers/admin/ModelsController.php b/app/controllers/admin/ModelsController.php index c1803ecb63..9d58ffe39c 100755 --- a/app/controllers/admin/ModelsController.php +++ b/app/controllers/admin/ModelsController.php @@ -243,7 +243,9 @@ class ModelsController extends AdminController $model->modelno = e(Input::get('modelno')); $model->manufacturer_id = e(Input::get('manufacturer_id')); $model->category_id = e(Input::get('category_id')); - if (Input::get('custom_fieldset')!='') { + if (Input::get('custom_fieldset')=='') { + $model->fieldset_id = null; + } else { $model->fieldset_id = e(Input::get('custom_fieldset')); }