File tree Expand file tree Collapse file tree 2 files changed +16
-1
lines changed
Components/ContentBuilder/Models Expand file tree Collapse file tree 2 files changed +16
-1
lines changed Original file line number Diff line number Diff line change @@ -13,7 +13,7 @@ class Registrar {
1313 /**
1414 * the laravel backend version
1515 */
16- const VERSION = '1.0.6 ' ;
16+ const VERSION = '1.0.7 ' ;
1717 const VERSION_NAME = 'Alpha ' ;
1818
1919 /**
Original file line number Diff line number Diff line change @@ -47,6 +47,13 @@ class Content extends BaseModel {
4747 'content_type_id ' => 'required|numeric ' ,
4848 );
4949
50+ /**
51+ * the custom fields of this content
52+ *
53+ * @var array
54+ */
55+ protected $ appends = ['custom_fields ' ];
56+
5057 /**
5158 * @param $req
5259 */
@@ -79,6 +86,14 @@ public function getMiscDataAttribute()
7986 return (Helpers::is_serialized ($ this ->attributes ['misc_data ' ])) ? unserialize ($ this ->attributes ['misc_data ' ]) : $ this ->attributes ['misc_data ' ];
8087 }
8188
89+ /**
90+ * @return array
91+ */
92+ public function getCustomFieldsAttribute ()
93+ {
94+ return self ::parseMetaData ($ this ->metaData ->toArray ());
95+ }
96+
8297 /**
8398 * parse meta data to associative array
8499 *
You can’t perform that action at this time.
0 commit comments