mjda
Well-known member
This might not be the correct forum for this. If it's not, please move it.
Anyways, I'm wanting to add a new database row to a RM category. I know how to do most of it. I have the field in the form, and the row is added to the database, and it's added to the entity. However, I'm wondering what's the proper way to get that to save when I submit the form? I could just overwrite the
However, I'm thinking there has to be a better way to do it, right?
Anyways, I'm wanting to add a new database row to a RM category. I know how to do most of it. I have the field in the form, and the row is added to the database, and it's added to the entity. However, I'm wondering what's the proper way to get that to save when I submit the form? I could just overwrite the
categorySaveProcess
to add my row here:
PHP:
protected function categorySaveProcess(\XFRM\Entity\Category $category)
{
$entityInput = $this->filter([
'title' => 'str',
'description' => 'str',
'parent_category_id' => 'uint',
'display_order' => 'uint',
'allow_local' => 'bool',
'allow_external' => 'bool',
'allow_commercial_external' => 'bool',
'allow_fileless' => 'bool',
'enable_versioning' => 'bool',
'enable_support_url' => 'bool',
'always_moderate_create' => 'bool',
'always_moderate_update' => 'bool',
'min_tags' => 'uint',
'thread_node_id' => 'uint',
'thread_prefix_id' => 'uint',
'require_prefix' => 'bool',
'auto_feature' => 'bool',
]);
However, I'm thinking there has to be a better way to do it, right?