Password syncronization fixes

This commit is contained in:
Juan Ferrer 2019-06-04 14:14:48 +02:00
parent 55b5409624
commit 46f0420431
3 changed files with 12 additions and 4 deletions

2
debian/changelog vendored
View File

@ -1,4 +1,4 @@
hedera-web (1.406.50) stable; urgency=low hedera-web (1.406.51) stable; urgency=low
* Initial Release. * Initial Release.

View File

@ -1,6 +1,6 @@
{ {
"name": "hedera-web", "name": "hedera-web",
"version": "1.406.50", "version": "1.406.51",
"description": "Verdnatura web page", "description": "Verdnatura web page",
"license": "GPL-3.0", "license": "GPL-3.0",
"repository": { "repository": {

View File

@ -27,10 +27,18 @@ class Account {
self::sambaSync($db, $userName, $password); self::sambaSync($db, $userName, $password);
} }
$db->query( $userId = $db->getValue(
'UPDATE account.user SET sync = TRUE WHERE name = #', 'SELECT id FROM account.user WHERE `name` = #',
[$userName] [$userName]
); );
$db->query(
'CALL account.user_syncPassword(#, #)',
[$userId, $password]
);
$db->query(
'UPDATE account.user SET sync = TRUE WHERE id = #',
[$userId]
);
} }
/** /**