Not specifically, but virtually everything captures input, passes it around, and persists it to the database. As a rough outline:
You'd extend the thread entity with a new column, then extend
\XF\Service\Thread\Creator with a new setter for it:
PHP:
public function setSomeId(int $someId)
{
$this->thread->some_id = $someId;
}
Then extend
\XF\Pub\Controller\Forum::actionPostThread to capture it and pass it to the template:
PHP:
public function actionPostThread(ParameterBag $params)
{
$reply = parent::actionPostThread($params);
if ($reply instanceof \XF\Mvc\Reply\View)
{
$someId = $this->filter('some_id', 'int');
if ($someId)
{
$reply->setParam('someId', $someId);
}
}
return $reply;
}
Then you'd persist it with the form data using a template modification for
forum_post_thread:
HTML:
<xf:if is="$someId">
<xf:hiddenval name="some_id" value="$someId" />
</xf:if>
Then capture it and pass it to the setter you created in
\XF\Pub\Controller\Forum::setupThreadCreate:
PHP:
public function setupThreadCreate(\XF\Entity\Forum $forum)
{
$creator = parent::setupThreadCreate($forum);
$someId = $this->filter('some_id', 'int');
if ($someId)
{
$creator->setSomeId($someId);
}
return $creator;
}