Merge pull request '#7867 - avoid deactivate user when is supplier' (!2860) from hotfix_nightTask_supplierDisable into master
gitea/salix/pipeline/head This commit looks good Details

Reviewed-on: #2860
Reviewed-by: Guillermo Bonet <guillermo@verdnatura.es>
This commit is contained in:
Javier Segarra 2024-08-14 05:52:13 +00:00
commit 0d931b2ab9
1 changed files with 1 additions and 0 deletions

View File

@ -21,6 +21,7 @@ BEGIN
AND a.id IS NULL
AND u.active
AND c.created < util.VN_CURDATE() - INTERVAL vMonths MONTH
AND NOT u.role = (SELECT id FROM `role` WHERE name = 'supplier')
AND u.id NOT IN (
SELECT DISTINCT c.id
FROM client c