use wcf\data\user\avatar\UserAvatar;
use wcf\data\user\avatar\UserAvatarEditor;
use wcf\data\user\avatar\UserAvatarList;
+use wcf\data\user\User;
use wcf\data\user\UserEditor;
use wcf\data\user\UserList;
use wcf\data\user\UserProfileAction;
protected function initObjectList() {
parent::initObjectList();
+ $this->objectList->sqlSelects = 'user_option_value.userOption' . User::getUserOptionID('aboutMe') . ' AS aboutMe';
+ $this->objectList->sqlJoins = "LEFT JOIN wcf".WCF_N."_user_option_value user_option_value ON (user_option_value.userID = user_table.userID)";
$this->objectList->sqlOrderBy = 'user_table.userID';
}
$statement->execute($conditionBuilder->getParameters());
}
- // update signatures
+ // update signatures and about me
+ $sql = "UPDATE wcf".WCF_N."_user_option_value
+ SET userOption" . User::getUserOptionID('aboutMe') . " = ?
+ WHERE userID = ?";
+ $statement = WCF::getDB()->prepareStatement($sql);
+
$htmlInputProcessor = new HtmlInputProcessor();
WCF::getDB()->beginTransaction();
/** @var UserEditor $user */
'signature' => $htmlInputProcessor->getHtml(),
'signatureEnableHtml' => 1
]);
+
+ if ($user->aboutMe) {
+ $htmlInputProcessor->process($user->aboutMe, 'com.woltlab.wcf.user.aboutMe', $user->userID, true);
+ $statement->execute([
+ $htmlInputProcessor->getHtml(),
+ $user->userID
+ ]);
+ }
}
}
WCF::getDB()->commitTransaction();