From 0fa686af4245e54743a669d6216b316fdc7bf296 Mon Sep 17 00:00:00 2001 From: Marcin Misiak <2mmarcinmisiak@gmail.com> Date: Tue, 31 Aug 2021 11:07:27 +0200 Subject: [PATCH] Update yii2-dynamic-form.js I've use bootstrap4 + tabx from https://demos.krajee.com/tabs-x. Line 90 and 91 make bug: "Uncaught TypeError: yiiActiveFormData is undefined" , when add comment works ok --- src/assets/yii2-dynamic-form.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/assets/yii2-dynamic-form.js b/src/assets/yii2-dynamic-form.js index fbe3045..3b4f280 100644 --- a/src/assets/yii2-dynamic-form.js +++ b/src/assets/yii2-dynamic-form.js @@ -87,8 +87,8 @@ // remove "error/success" css class var yiiActiveFormData = $('#' + widgetOptions.formId).yiiActiveForm('data'); - $template.find('.' + yiiActiveFormData.settings.errorCssClass).removeClass(yiiActiveFormData.settings.errorCssClass); - $template.find('.' + yiiActiveFormData.settings.successCssClass).removeClass(yiiActiveFormData.settings.successCssClass); + // $template.find('.' + yiiActiveFormData.settings.errorCssClass).removeClass(yiiActiveFormData.settings.errorCssClass); + // $template.find('.' + yiiActiveFormData.settings.successCssClass).removeClass(yiiActiveFormData.settings.successCssClass); return $template; };