[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Noalyss-commit] [noalyss] 43/86: Fix Create user , password not set
From: |
dwm |
Subject: |
[Noalyss-commit] [noalyss] 43/86: Fix Create user , password not set |
Date: |
Thu, 19 Sep 2024 02:41:53 -0400 (EDT) |
sparkyx pushed a commit to branch unstable
in repository noalyss.
commit c46b22623950fb52aa5d4446591456a786b43555
Author: sparkyx <danydb@noalyss.eu>
AuthorDate: Sat Sep 7 17:27:51 2024 +0200
Fix Create user , password not set
---
include/user.inc.php | 5 +++--
include/user_detail.inc.php | 4 ++--
2 files changed, 5 insertions(+), 4 deletions(-)
diff --git a/include/user.inc.php b/include/user.inc.php
index c9d7bfa07..0a452a1b6 100644
--- a/include/user.inc.php
+++ b/include/user.inc.php
@@ -63,12 +63,13 @@ if ( isset ($_POST["ADD"]) )
{
$exist_user=$cn->get_value("select count(*) from ac_users where
use_login=lower($1)",[$login]);
if ( $exist_user == 0 ) {
+ $new_user->setPassword($pass5);
$new_user->insert();
$new_user->load();
put_global(array(['key'=>'use_id',"value"=>$new_user->id]));
Noalyss_user::audit_admin(sprintf('ADD USER %s
%s',$new_user->id,$login));
} else {
- echo_warning(_("Utilisateur existant"));
+ echo_warning(_("Utilisateur existant"));
$uid=$cn->get_value("select use_id from ac_users where
use_login=lower($1)",[$login]);
$new_user->setId($uid);
put_global(array(['key'=>'use_id',"value"=>$new_user->id]));
@@ -147,7 +148,7 @@ else if ($sbaction == "delete")
echo "code [$code] code control [$ctl_code]";
}
if ( $code != $ctl_code) {
- echo _("Code invalide, effacement refusé");
+ echo_warning (_("Code invalide, effacement refusé"));
return;
}
$cn = new Database();
diff --git a/include/user_detail.inc.php b/include/user_detail.inc.php
index 9184a8e7e..232b1bce6 100644
--- a/include/user_detail.inc.php
+++ b/include/user_detail.inc.php
@@ -129,8 +129,8 @@ $it_pass->value="";
<div id="delete_user_div" class="inner_box" style="display: none">
<?=HtmlInput::title_box(_("Effacer"),'delete_user_div','hide')?>
<FORM id="user_detail_frm" METHOD="POST">
- <INPUT type="hidden" NAME="lname" value="<?=_("$UserChange->name")?>">
- <INPUT type="hidden" NAME="fname"
value="<?=_("$UserChange->first_name")?>">
+ <INPUT type="hidden" NAME="lname" value="<?="$UserChange->name"?>">
+ <INPUT type="hidden" NAME="fname" value="<?="$UserChange->first_name"?>">
<?php echo HtmlInput::hidden('UID',$uid)?>
<?php echo HtmlInput::hidden('use_id',$uid)?>
<input type="hidden" name="sbaction" value="delete">
- [Noalyss-commit] [noalyss] 66/86: Cosmetic , missing bcscale and code cleaning, (continued)
- [Noalyss-commit] [noalyss] 66/86: Cosmetic , missing bcscale and code cleaning, dwm, 2024/09/19
- [Noalyss-commit] [noalyss] 56/86: Merge branch 'stable' into pre-stable, dwm, 2024/09/19
- [Noalyss-commit] [noalyss] 75/86: CSS font h2, dwm, 2024/09/19
- [Noalyss-commit] [noalyss] 78/86: add detail, dwm, 2024/09/19
- [Noalyss-commit] [noalyss] 80/86: Cosmetic : animate bar menu, dwm, 2024/09/19
- [Noalyss-commit] [noalyss] 84/86: color, dwm, 2024/09/19
- [Noalyss-commit] [noalyss] 11/86: PHP8.2 compatility : strip_tags null, dwm, 2024/09/19
- [Noalyss-commit] [noalyss] 20/86: C0MENU : bug javascript Uniquement note de débit ou crédit ne fonctionne pas, dwm, 2024/09/19
- [Noalyss-commit] [noalyss] 76/86: Merge branch 'pre-stable' into stable, dwm, 2024/09/19
- [Noalyss-commit] [noalyss] 26/86: Cosmetic add inner_box2, dwm, 2024/09/19
- [Noalyss-commit] [noalyss] 43/86: Fix Create user , password not set,
dwm <=
- [Noalyss-commit] [noalyss] 02/86: Merge branch 'pre-stable' into stable, dwm, 2024/09/19
- [Noalyss-commit] [noalyss] 14/86: Cosmetic #0002375: Menu COMPTA/LET/LETCARD : le nom de la fiche n'apparaît pas., dwm, 2024/09/19
- [Noalyss-commit] [noalyss] 13/86: PHP8.2 compatility : strip_tags null, dwm, 2024/09/19
- [Noalyss-commit] [noalyss] 22/86: Cosmetic, dwm, 2024/09/19
- [Noalyss-commit] [noalyss] 24/86: Cosmetic add inner_box2, dwm, 2024/09/19
- [Noalyss-commit] [noalyss] 30/86: RECONCILE : remove direct access to, dwm, 2024/09/19
- [Noalyss-commit] [noalyss] 29/86: Cosmetic improve widget bookmark color for hover, dwm, 2024/09/19
- [Noalyss-commit] [noalyss] 33/86: RECONCILE : remove direct access to, dwm, 2024/09/19
- [Noalyss-commit] [noalyss] 37/86: RECONCILE : VAT ND not in account, dwm, 2024/09/19
- [Noalyss-commit] [noalyss] 40/86: Fix bug CSV for P1TVA , wrong header, dwm, 2024/09/19