hotfix_clientsDisable #2240

Merged
ivanm merged 1 commits from hotfix_clientsDisable into master 2024-04-03 08:46:47 +00:00
1 changed files with 1 additions and 2 deletions
Showing only changes of commit b9520b53ab - Show all commits

View File

@ -7,9 +7,8 @@ CREATE OR REPLACE DEFINER=`root`@`localhost` EVENT `vn`.`clientsDisable`
DO BEGIN
UPDATE account.user u
JOIN client c ON c.id = u.id
JOIN clientType ct ON ct.id = c.typeFk
SET u.active = FALSE
WHERE ct.code = 'normal'
WHERE c.typeFk = 'normal'
AND u.id NOT IN (
SELECT DISTINCT c.id
FROM client c