arms
Well-known member
All seems to work fine. Extra fields are filled in etc. But now finding I'm getting empty recent activity entries.
I'm extending actionCreateThread and actionAddThread.
Could it be to do with the extra save in:
Any help would be appreciated.
I'm extending actionCreateThread and actionAddThread.
Could it be to do with the extra save in:
PHP:
function actionAddThread()
{
$suffixId = $this->_input->filterSingle('suffix_id', XenForo_Input::UINT);
$forumId = $this->_input->filterSingle('node_id', XenForo_Input::UINT);
$ftpHelper = $this->getHelper('ForumThreadPost');
$forum = $ftpHelper->assertForumValidAndViewable($forumId ? $forumId : $forumName);
$parent = parent::actionAddThread();
$threadId = $parent->params['thread']['thread_id'];
if (!$this->_getSuffixModel()->verifySuffixIsUsable($suffixId, $forumId))
{
$suffixId = 0; // not usable, just blank it out
}
$dw = XenForo_DataWriter::create('XenForo_DataWriter_Discussion_Thread');
$dw->setExistingData($threadId);
$dw->getFirstMessageDw();
$dw->set('suffix_id', $suffixId);
$dw->preSave();
if ($forum['require_suffix'] && !$dw->get('suffix_id'))
{
$dw->error(new XenForo_Phrase('please_select_a_suffix'), 'suffix_id');
}
$dw->save();
return $parent;
}
Any help would be appreciated.
Last edited: