From e83a27a31b011412febd389a1084ff8843a83e4f Mon Sep 17 00:00:00 2001 From: jitendra Date: Fri, 5 Apr 2019 11:42:52 +0530 Subject: [PATCH] Issue #803 fixed --- packages/Webkul/Attribute/src/Models/Attribute.php | 2 +- packages/Webkul/Attribute/src/Models/AttributeOption.php | 2 ++ packages/Webkul/Category/src/Models/Category.php | 2 ++ 3 files changed, 5 insertions(+), 1 deletion(-) diff --git a/packages/Webkul/Attribute/src/Models/Attribute.php b/packages/Webkul/Attribute/src/Models/Attribute.php index 8aace2e9f..8fd43e016 100755 --- a/packages/Webkul/Attribute/src/Models/Attribute.php +++ b/packages/Webkul/Attribute/src/Models/Attribute.php @@ -11,7 +11,7 @@ class Attribute extends TranslatableModel implements AttributeContract protected $fillable = ['code', 'admin_name', 'type', 'position', 'is_required', 'is_unique', 'validation', 'value_per_locale', 'value_per_channel', 'is_filterable', 'is_configurable', 'is_visible_on_front', 'is_user_defined', 'swatch_type']; - protected $with = ['options']; + protected $with = ['options', 'translations']; /** * Get the options. diff --git a/packages/Webkul/Attribute/src/Models/AttributeOption.php b/packages/Webkul/Attribute/src/Models/AttributeOption.php index ad81ea63a..d92b8e6d0 100755 --- a/packages/Webkul/Attribute/src/Models/AttributeOption.php +++ b/packages/Webkul/Attribute/src/Models/AttributeOption.php @@ -14,6 +14,8 @@ class AttributeOption extends TranslatableModel implements AttributeOptionContra protected $fillable = ['admin_name', 'swatch_value', 'sort_order', 'attribute_id']; + protected $with = ['translations']; + /** * Get the attribute that owns the attribute option. */ diff --git a/packages/Webkul/Category/src/Models/Category.php b/packages/Webkul/Category/src/Models/Category.php index 273430dad..48b8e3046 100755 --- a/packages/Webkul/Category/src/Models/Category.php +++ b/packages/Webkul/Category/src/Models/Category.php @@ -15,6 +15,8 @@ class Category extends TranslatableModel implements CategoryContract protected $fillable = ['position', 'status', 'display_mode', 'parent_id']; + protected $with = ['translations']; + /** * Get image url for the category image. */