Do not return password form Enterprise Service Methods

This commit is contained in:
alexY2004 2015-05-14 12:18:53 +03:00
parent e93d354058
commit db16c927cb
15 changed files with 129 additions and 61 deletions

View file

@ -210,10 +210,10 @@ namespace WebsitePanel.Portal
return dsUsers;
}
public static int AddUser(List<string> log, int portalId, UserInfo user, bool sendLetter)
public static int AddUser(List<string> log, int portalId, UserInfo user, bool sendLetter, string password)
{
// add user to WebsitePanel server
return ES.Services.Users.AddUser(user, sendLetter);
return ES.Services.Users.AddUser(user, sendLetter, password);
}
public static void AddUserVLan(int userId, UserVlan vLan)

View file

@ -195,7 +195,7 @@ namespace WebsitePanel.Portal
user.SecondaryEmail = txtSecondaryEmail.Text;
user.HtmlMail = ddlMailFormat.SelectedIndex == 1;
user.Username = txtUsername.Text;
user.Password = userPassword.Password;
// user.Password = userPassword.Password;
user.IsDemo = chkDemo.Checked;
user.LoginStatusId = loginStatus.SelectedIndex;
@ -220,7 +220,7 @@ namespace WebsitePanel.Portal
try
{
//int userId = UsersHelper.AddUser(log, PortalId, user);
int userId = PortalUtils.AddUserAccount(log, user, false);
int userId = PortalUtils.AddUserAccount(log, user, false, userPassword.Password);
if (userId < 0)
{

View file

@ -103,7 +103,7 @@ namespace WebsitePanel.Portal
user.SecondaryEmail = txtSecondaryEmail.Text;
user.HtmlMail = ddlMailFormat.SelectedIndex == 1;
user.Username = txtUsername.Text.Trim();
user.Password = userPassword.Password;
// user.Password = userPassword.Password;
// contact info
user.CompanyName = contact.CompanyName;
@ -123,7 +123,7 @@ namespace WebsitePanel.Portal
try
{
//int userId = UsersHelper.AddUser(log, PortalId, user);
int userId = PortalUtils.AddUserAccount(log, user, chkAccountLetter.Checked);
int userId = PortalUtils.AddUserAccount(log, user, chkAccountLetter.Checked, userPassword.Password);
if (userId == BusinessErrorCodes.ERROR_INVALID_USER_NAME)
{