hr list add cancel + complain reply send email to notice

This commit is contained in:
xiaomlove
2022-08-02 01:58:08 +08:00
parent 22657622fa
commit d348422097
20 changed files with 81 additions and 26 deletions

View File

@@ -37,7 +37,7 @@ class BonusRepository extends BaseRepository
$hitAndRun->update([
'status' => HitAndRun::STATUS_PARDONED,
'comment' => NexusDB::raw("concat(comment, '\n$comment')"),
'comment' => NexusDB::raw("if(comment = '', '$comment', concat_ws('\n', '$comment', comment))"),
]);
});
@@ -106,7 +106,7 @@ class BonusRepository extends BaseRepository
$user = $this->getUser($user);
if ($user->seedbonus < $requireBonus) {
do_log("user: {$user->id}, bonus: {$user->seedbonus} < requireBonus: $requireBonus", 'error');
throw new \LogicException("User bonus point not enough.");
throw new \LogicException("User bonus not enough.");
}
NexusDB::transaction(function () use ($user, $requireBonus, $logBusinessType, $logComment, $userUpdates) {
$logComment = addslashes($logComment);