Index: branches/5.2.x/core/units/mailing_lists/mailing_lists_config.php
===================================================================
diff -u -N -r14585 -r14726
--- branches/5.2.x/core/units/mailing_lists/mailing_lists_config.php (.../mailing_lists_config.php) (revision 14585)
+++ branches/5.2.x/core/units/mailing_lists/mailing_lists_config.php (.../mailing_lists_config.php) (revision 14726)
@@ -1,6 +1,6 @@
'int',
'formatter' => 'kLEFTFormatter',
'options' => Array (USER_ROOT => 'root'),
- 'left_sql' => 'SELECT %s FROM ' . TABLE_PREFIX . 'PortalUser WHERE `%s` = \'%s\'', 'left_key_field' => 'PortalUserId', 'left_title_field' => 'Login',
+ 'left_sql' => 'SELECT %s FROM ' . TABLE_PREFIX . 'PortalUser WHERE `%s` = \'%s\'', 'left_key_field' => 'PortalUserId', 'left_title_field' => 'Username',
'required' => 1, 'not_null' => 1, 'default' => USER_ROOT,
),
Index: branches/5.2.x/core/units/visits/visits_config.php
===================================================================
diff -u -N -r14585 -r14726
--- branches/5.2.x/core/units/visits/visits_config.php (.../visits_config.php) (revision 14585)
+++ branches/5.2.x/core/units/visits/visits_config.php (.../visits_config.php) (revision 14726)
@@ -1,6 +1,6 @@
Array (
'' => Array (
- 'UserName' => 'IF( ISNULL(u.Login), IF (%1$s.PortalUserId = ' . USER_ROOT . ', \'root\', IF (%1$s.PortalUserId = ' . USER_GUEST . ', \'Guest\', \'n/a\')), u.Login)',
+ 'UserName' => 'IF( ISNULL(u.Username), IF (%1$s.PortalUserId = ' . USER_ROOT . ', \'root\', IF (%1$s.PortalUserId = ' . USER_GUEST . ', \'Guest\', \'n/a\')), u.Username)',
),
'incommerce' => Array (
- 'UserName' => 'IF( ISNULL(u.Login), IF (%1$s.PortalUserId = ' . USER_ROOT . ', \'root\', IF (%1$s.PortalUserId = ' . USER_GUEST . ', \'Guest\', \'n/a\')), u.Login)',
- 'AffiliateUser' => 'IF( LENGTH(au.Login),au.Login,\'!la_None!\')',
+ 'UserName' => 'IF( ISNULL(u.Username), IF (%1$s.PortalUserId = ' . USER_ROOT . ', \'root\', IF (%1$s.PortalUserId = ' . USER_GUEST . ', \'Guest\', \'n/a\')), u.Username)',
+ 'AffiliateUser' => 'IF( LENGTH(au.Username),au.Username,\'!la_None!\')',
'AffiliatePortalUserId' => 'af.PortalUserId',
'OrderTotalAmount' => 'IF(ord.Status = 4, ord.SubTotal+ord.ShippingCost+ord.VAT, 0)',
'OrderAffiliateCommission' => 'IF(ord.Status = 4, ord.AffiliateCommission, 0)',
@@ -133,7 +133,7 @@
'VisitDate' => Array ('type' => 'int', 'formatter' => 'kDateFormatter', 'custom_filter' => 'date_range', 'default' => NULL),
'Referer' => Array ('type' => 'string','not_null' => '1','default' => ''),
'IPAddress' => Array ('type' => 'string','not_null' => '1','default' => ''),
- 'AffiliateId' => Array ('type' => 'int','formatter' => 'kLEFTFormatter', 'error_msgs' => Array ('invalid_option' => '!la_error_UserNotFound!'), 'options' => Array (0 => 'lu_None'), 'left_sql' => 'SELECT %s FROM '.TABLE_PREFIX.'Affiliates af LEFT JOIN '.TABLE_PREFIX.'PortalUser pu ON pu.PortalUserId = af.PortalUserId WHERE `%s` = \'%s\'','left_key_field' => 'AffiliateId','left_title_field' => 'Login','not_null'=>1,'default'=>0),
+ 'AffiliateId' => Array ('type' => 'int','formatter' => 'kLEFTFormatter', 'error_msgs' => Array ('invalid_option' => '!la_error_UserNotFound!'), 'options' => Array (0 => 'lu_None'), 'left_sql' => 'SELECT %s FROM '.TABLE_PREFIX.'Affiliates af LEFT JOIN '.TABLE_PREFIX.'PortalUser pu ON pu.PortalUserId = af.PortalUserId WHERE `%s` = \'%s\'','left_key_field' => 'AffiliateId','left_title_field' => 'Username','not_null'=>1,'default'=>0),
'PortalUserId' => Array ('type' => 'int','not_null' => '1','default' => USER_GUEST),
),
Index: branches/5.2.x/core/units/categories/categories_config.php
===================================================================
diff -u -N -r14585 -r14726
--- branches/5.2.x/core/units/categories/categories_config.php (.../categories_config.php) (revision 14585)
+++ branches/5.2.x/core/units/categories/categories_config.php (.../categories_config.php) (revision 14726)
@@ -1,6 +1,6 @@
Array ('type' => 'string', 'formatter' => 'kFormatter', 'using_fck' => 1, 'default' => null),
'CachedDescendantCatsQty' => Array ('type' => 'int', 'not_null' => 1, 'default' => 0),
'CachedNavbar' => Array ('type' => 'string', 'formatter' => 'kMultiLanguage', 'default' => null),
- 'CreatedById' => Array ('type' => 'int', 'formatter' => 'kLEFTFormatter', 'error_msgs' => Array ('invalid_option' => '!la_error_UserNotFound!'), 'options' => Array (USER_ROOT => 'root', USER_GUEST => 'Guest'),'left_sql'=>'SELECT %s FROM '.TABLE_PREFIX.'PortalUser WHERE `%s` = \'%s\'', 'left_key_field' => 'PortalUserId', 'left_title_field' => 'Login', 'default' => NULL),
+ 'CreatedById' => Array ('type' => 'int', 'formatter' => 'kLEFTFormatter', 'error_msgs' => Array ('invalid_option' => '!la_error_UserNotFound!'), 'options' => Array (USER_ROOT => 'root', USER_GUEST => 'Guest'),'left_sql'=>'SELECT %s FROM '.TABLE_PREFIX.'PortalUser WHERE `%s` = \'%s\'', 'left_key_field' => 'PortalUserId', 'left_title_field' => 'Username', 'default' => NULL),
'ResourceId' => Array ('type' => 'int', 'default' => null),
'ParentPath' => Array ('type' => 'string', 'default' => null),
'TreeLeft' => Array ('type' => 'int', 'not_null' => 1, 'default' => 0),
@@ -337,7 +337,7 @@
'NewItem' => Array ('type' => 'int', 'formatter' => 'kOptionsFormatter', 'options' => Array (2 => 'la_Auto', 1 => 'la_Always', 0 => 'la_Never'), 'use_phrases' => 1, 'not_null' => 1, 'default' => 2),
'PopItem' => Array ('type' => 'int', 'formatter' => 'kOptionsFormatter', 'options' => Array (2 => 'la_Auto', 1 => 'la_Always', 0 => 'la_Never'), 'use_phrases' => 1, 'not_null' => 1, 'default' => 2),
'Modified' => Array ('type' => 'int', 'formatter' => 'kDateFormatter', 'default' => '#NOW#'),
- 'ModifiedById' => Array ('type' => 'int', 'formatter' => 'kLEFTFormatter', 'error_msgs' => Array ('invalid_option' => '!la_error_UserNotFound!'), 'options' => Array (USER_ROOT => 'root', USER_GUEST => 'Guest'),'left_sql'=>'SELECT %s FROM '.TABLE_PREFIX.'PortalUser WHERE `%s` = \'%s\'', 'left_key_field' => 'PortalUserId', 'left_title_field' => 'Login', 'default' => NULL),
+ 'ModifiedById' => Array ('type' => 'int', 'formatter' => 'kLEFTFormatter', 'error_msgs' => Array ('invalid_option' => '!la_error_UserNotFound!'), 'options' => Array (USER_ROOT => 'root', USER_GUEST => 'Guest'),'left_sql'=>'SELECT %s FROM '.TABLE_PREFIX.'PortalUser WHERE `%s` = \'%s\'', 'left_key_field' => 'PortalUserId', 'left_title_field' => 'Username', 'default' => NULL),
'CachedTemplate' => Array ('type' => 'string', 'not_null' => 1, 'default' => ''),
Index: branches/5.2.x/core/kernel/utility/temp_handler.php
===================================================================
diff -u -N -r14699 -r14726
--- branches/5.2.x/core/kernel/utility/temp_handler.php (.../temp_handler.php) (revision 14699)
+++ branches/5.2.x/core/kernel/utility/temp_handler.php (.../temp_handler.php) (revision 14726)
@@ -1,6 +1,6 @@
Conn->qstr($address);
+ WHERE Username = ' . $this->Conn->qstr($address);
$user_info = $this->Conn->GetRow($sql);
if ($user_info) {
@@ -416,7 +416,7 @@
case EmailEvent::ADDRESS_TYPE_USER:
$sql = 'SELECT FirstName, LastName, Email
FROM ' . TABLE_PREFIX . 'PortalUser
- WHERE Login = ' . $this->Conn->qstr($address);
+ WHERE Username = ' . $this->Conn->qstr($address);
$user_info = $this->Conn->GetRow($sql);
if ($user_info) {
@@ -506,7 +506,7 @@
// 2. replace tags if needed
$default_replacement_tags = Array (
'
' ' ' 'Conn->qstr($address);
if (!$this->Conn->GetOne($sql)) {
$object->SetError($field_prefix . 'Address', 'invalid_user');
}
@@ -1069,7 +1069,7 @@
break;
case EmailEvent::ADDRESS_TYPE_USER:
- $field = 'Login';
+ $field = 'Username';
$table_name = TABLE_PREFIX . 'PortalUser';
break;
Index: branches/5.2.x/core/install/step_templates/download_license.tpl
===================================================================
diff -u -N -r14244 -r14726
--- branches/5.2.x/core/install/step_templates/download_license.tpl (.../download_license.tpl) (revision 14244)
+++ branches/5.2.x/core/install/step_templates/download_license.tpl (.../download_license.tpl) (revision 14726)
@@ -1,5 +1,5 @@
- Login / E-mail: |
+ Username / E-mail: |
|
Index: branches/5.2.x/core/units/helpers/user_helper.php
===================================================================
diff -u -N -r14631 -r14726
--- branches/5.2.x/core/units/helpers/user_helper.php (.../user_helper.php) (revision 14631)
+++ branches/5.2.x/core/units/helpers/user_helper.php (.../user_helper.php) (revision 14726)
@@ -1,6 +1,6 @@
Clear($user_id);
- $object->SetDBField('Login', 'root');
+ $object->SetDBField('Username', 'root');
if (!$dry_run) {
$this->loginUserById($user_id, $remember_login_cookie);
@@ -146,7 +146,7 @@
}
/**
- * Login username by it's PortalUserId
+ * Login user by it's id
*
* @param int $user_id
* @param bool $remember_login_cookie
@@ -323,7 +323,7 @@
$sql = 'SELECT PortalUserId
FROM ' . TABLE_PREFIX . 'PortalUser
- WHERE (Email = %1$s OR Login = %1$s) AND (Password = %2$s)';
+ WHERE (Email = %1$s OR Username = %1$s) AND (Password = %2$s)';
return $this->Conn->GetOne( sprintf($sql, $this->Conn->qstr($username), $this->Conn->qstr($password) ) );
}
Index: branches/5.2.x/core/units/reviews/reviews_config.php
===================================================================
diff -u -N -r14652 -r14726
--- branches/5.2.x/core/units/reviews/reviews_config.php (.../reviews_config.php) (revision 14652)
+++ branches/5.2.x/core/units/reviews/reviews_config.php (.../reviews_config.php) (revision 14726)
@@ -1,6 +1,6 @@
Array (
'' => Array (
- 'ReviewedBy' => 'IF( ISNULL(pu.Login), IF (%1$s.CreatedById = ' . USER_ROOT . ', \'root\', IF (%1$s.CreatedById = ' . USER_GUEST . ', \'Guest\', \'n/a\')), pu.Login )',
+ 'ReviewedBy' => 'IF( ISNULL(pu.Username), IF (%1$s.CreatedById = ' . USER_ROOT . ', \'root\', IF (%1$s.CreatedById = ' . USER_GUEST . ', \'Guest\', \'n/a\')), pu.Username )',
),
'products' => Array (
- 'ReviewedBy' => 'IF( ISNULL(pu.Login), IF (%1$s.CreatedById = ' . USER_ROOT . ', \'root\', IF (%1$s.CreatedById = ' . USER_GUEST . ', \'Guest\', \'n/a\')), pu.Login )',
+ 'ReviewedBy' => 'IF( ISNULL(pu.Username), IF (%1$s.CreatedById = ' . USER_ROOT . ', \'root\', IF (%1$s.CreatedById = ' . USER_GUEST . ', \'Guest\', \'n/a\')), pu.Username )',
'ItemName' => 'pr.l1_Name',
'ProductId' => 'pr.ProductId',
),
'product' => Array (
- 'ReviewedBy' => 'IF( ISNULL(pu.Login), IF (%1$s.CreatedById = ' . USER_ROOT . ', \'root\', IF (%1$s.CreatedById = ' . USER_GUEST . ', \'Guest\', \'n/a\')), pu.Login )',
+ 'ReviewedBy' => 'IF( ISNULL(pu.Username), IF (%1$s.CreatedById = ' . USER_ROOT . ', \'root\', IF (%1$s.CreatedById = ' . USER_GUEST . ', \'Guest\', \'n/a\')), pu.Username )',
'ItemName' => 'pr.l1_Name',
'ProductId' => 'pr.ProductId',
),
@@ -139,7 +139,7 @@
'left_sql' => 'SELECT %s FROM ' . TABLE_PREFIX . 'PortalUser
WHERE `%s` = \'%s\' ',
'left_key_field' => 'PortalUserId',
- 'left_title_field' => 'Login',
+ 'left_title_field' => 'Username',
'required' => 1, 'default' => NULL,
'error_msgs' => Array ('invalid_option' => '!la_error_UserNotFound!'),
),
Index: branches/5.2.x/admin/system_presets/simple/users_u.php
===================================================================
diff -u -N -r14663 -r14726
--- branches/5.2.x/admin/system_presets/simple/users_u.php (.../users_u.php) (revision 14663)
+++ branches/5.2.x/admin/system_presets/simple/users_u.php (.../users_u.php) (revision 14726)
@@ -69,7 +69,7 @@
// fields to hide
$hidden_fields = Array (
- /* 'PortalUserId', 'Login', 'Password', 'FirstName','LastName', 'Company', 'Email', 'CreatedOn',
+ /* 'PortalUserId', 'Username', 'Password', 'FirstName','LastName', 'Company', 'Email', 'CreatedOn',
'Phone', 'Fax', 'Street', 'Street2', 'City', 'State' , 'Zip', 'Country', 'ResourceId', 'Status',
'Modified', 'dob', 'tz',*/ 'IPAddress', /*'IsBanned', 'PwResetConfirm', 'PwRequestTime',*/ 'IPRestrictions',
);
@@ -81,7 +81,7 @@
// fields to make required
$required_fields = Array (
- /*'PortalUserId',*/ 'Login', /*'Password', 'FirstName', 'LastName', 'Company', */'Email', /*'CreatedOn',
+ /*'PortalUserId',*/ 'Username', /*'Password', 'FirstName', 'LastName', 'Company', */'Email', /*'CreatedOn',
'Phone', 'Fax', 'Street', 'Street2', 'City', 'State' , 'Zip', 'Country', 'ResourceId', 'Status',
'Modified', 'dob', 'tz', 'IPAddress', 'IsBanned', 'PwResetConfirm', 'PwRequestTime',*/
);
@@ -106,14 +106,14 @@
// hide columns in grids
$hide_columns = Array (
// currently not in user
-// 'Default' => Array ('Login', 'LastName', 'FirstName', 'Email', 'PrimaryGroup', 'CreatedOn', 'Modified'),
+// 'Default' => Array ('Username', 'LastName', 'FirstName', 'Email', 'PrimaryGroup', 'CreatedOn', 'Modified'),
// user selector
-// 'UserSelector' => Array ('Login', 'LastName', 'FirstName', 'Email', 'PrimaryGroup', 'CreatedOn', 'Modified'),
+// 'UserSelector' => Array ('Username', 'LastName', 'FirstName', 'Email', 'PrimaryGroup', 'CreatedOn', 'Modified'),
// admins list; section: Users Management -> Administrators
-// 'Admins' => Array ('PortalUserId', 'Login', 'FirstName', 'LastName', 'Email'),
+// 'Admins' => Array ('PortalUserId', 'Username', 'FirstName', 'LastName', 'Email'),
// users list; section: Users Management -> Users
- 'RegularUsers' => Array (/*'PortalUserId', 'Login', 'FirstName', 'LastName', 'Email',*/ 'PrimaryGroup', 'CreatedOn', 'Modified', /* 'Status',*/ 'IPAddress'),
+ 'RegularUsers' => Array (/*'PortalUserId', 'Username', 'FirstName', 'LastName', 'Email',*/ 'PrimaryGroup', 'CreatedOn', 'Modified', /* 'Status',*/ 'IPAddress'),
);
Index: branches/5.2.x/core/kernel/db/cat_event_handler.php
===================================================================
diff -u -N -r14719 -r14726
--- branches/5.2.x/core/kernel/db/cat_event_handler.php (.../cat_event_handler.php) (revision 14719)
+++ branches/5.2.x/core/kernel/db/cat_event_handler.php (.../cat_event_handler.php) (revision 14726)
@@ -1,6 +1,6 @@
Application->getUnitOption('u', 'IDField');
$table_name = $this->Application->getUnitOption('u', 'TableName');
- $sql = 'SELECT Login
+ $sql = 'SELECT Username
FROM ' . $table_name . '
WHERE ' . $id_field . ' = ' . $user_id;
$object->SetDBField($cached_field, $this->Conn->GetOne($sql));
Index: branches/5.2.x/core/admin_templates/users/user_selector.tpl
===================================================================
diff -u -N -r14244 -r14726
--- branches/5.2.x/core/admin_templates/users/user_selector.tpl (.../user_selector.tpl) (revision 14244)
+++ branches/5.2.x/core/admin_templates/users/user_selector.tpl (.../user_selector.tpl) (revision 14726)
@@ -39,7 +39,7 @@
Index: branches/5.2.x/core/admin_templates/logs/change_logs/change_log_edit.tpl
===================================================================
diff -u -N -r14244 -r14726
--- branches/5.2.x/core/admin_templates/logs/change_logs/change_log_edit.tpl (.../change_log_edit.tpl) (revision 14244)
+++ branches/5.2.x/core/admin_templates/logs/change_logs/change_log_edit.tpl (.../change_log_edit.tpl) (revision 14726)
@@ -67,7 +67,7 @@
-
+
Index: branches/5.2.x/tools/run_event.php
===================================================================
diff -u -N -r14692 -r14726
--- branches/5.2.x/tools/run_event.php (.../run_event.php) (revision 14692)
+++ branches/5.2.x/tools/run_event.php (.../run_event.php) (revision 14726)
@@ -1,6 +1,6 @@
Done();
-$end = getmicrotime();
-
-function getmicrotime()
-{
- list($usec, $sec) = explode(" ", microtime());
- return ((float)$usec + (float)$sec);
-}
+$end = microtime(true);
\ No newline at end of file
Index: branches/5.2.x/core/kernel/db/db_event_handler.php
===================================================================
diff -u -N -r14714 -r14726
--- branches/5.2.x/core/kernel/db/db_event_handler.php (.../db_event_handler.php) (revision 14714)
+++ branches/5.2.x/core/kernel/db/db_event_handler.php (.../db_event_handler.php) (revision 14726)
@@ -1,6 +1,6 @@