Version Notes
- 2.0.4: fix of "username exists" error message
- 2.0.3: fix bad Observer merge
- 2.0.1 / 2.0.2:
- Add composer, modman, MageTrashApp support to help installing and uninstalling this module
- Move template to design base package
- Fix several bugs like saving username from frontend, checkout process as guest, etc
- Follow best practices for module setup
- Version 1.5.0: update for Magento 1.7
- Version 1.4.0: fix a problem to enable and disable a customer account from Customer Management in backend
- Version 1.3.0: new features. Configurable options: display username in Manage Customer Grid, allow customer to edit or not username in frontend My Account, define maximum and minimum length of username for the forms, define what kind of validation desired (letters, digits, both or both " _-)
- Version 1.2.1: fix customer account layout
- Version 1.2.0: fix problem with case sensitive OS, limit the number of characters possible (now it's between 6 and 30 letters), allow only some characters, try to provide compatibility update for users who had the old Jfusion_Username module, generate a username for old customers who don't have it, based on email address and a random id, improve the german translation, tested on 1.6.2 and 1.5.1
- Version 1.1.0: change the module name from Jfusion_Customer to Diglin_Username, fix bugs with checkout frontend and backend and with old customers
- Version 1.0.2 - fix a bug with the installation
- Version 1.0.1 - fix bug in sql query during installation on prefixed tables, add german translation, do package for Magento version prior to 1.5 and version 1.5.x
- Version 1.0.0 - stable version
Release Info
Developer | Magento Core Team |
Extension | Diglin_Username |
Version | 2.0.4 |
Comparing to | |
See all releases |
Code changes from version 2.0.3 to 2.0.4
@@ -42,6 +42,8 @@ class Diglin_Username_Model_Form extends Mage_Customer_Model_Form
|
|
42 |
$customerId = Mage::app()->getFrontController()
|
43 |
->getRequest()
|
44 |
->getParam('id');
|
|
|
|
|
45 |
}
|
46 |
|
47 |
if (isset($data['website_id']) && $data['website_id'] !== false) {
|
@@ -75,7 +77,7 @@ class Diglin_Username_Model_Form extends Mage_Customer_Model_Form
|
|
75 |
|
76 |
$result = $model->customerUsernameExists($data['username'], $websiteId);
|
77 |
if ($result && $result->getId() != $customerId) {
|
78 |
-
$message = Mage::helper('username')->__('Username already exists');
|
79 |
$errors = array_merge($errors, array($message));
|
80 |
}
|
81 |
}
|
42 |
$customerId = Mage::app()->getFrontController()
|
43 |
->getRequest()
|
44 |
->getParam('id');
|
45 |
+
} else if (!$customerId && !Mage::app()->getStore()->isAdmin()) {
|
46 |
+
$customerId = Mage::getSingleton('customer/session')->getCustomer()->getId();
|
47 |
}
|
48 |
|
49 |
if (isset($data['website_id']) && $data['website_id'] !== false) {
|
77 |
|
78 |
$result = $model->customerUsernameExists($data['username'], $websiteId);
|
79 |
if ($result && $result->getId() != $customerId) {
|
80 |
+
$message = Mage::helper('username')->__('Username already exists customerId ' . $customerId . ' - Result ' . $result->getId());
|
81 |
$errors = array_merge($errors, array($message));
|
82 |
}
|
83 |
}
|
@@ -37,7 +37,8 @@ class Diglin_Username_Model_Observer extends Mage_Customer_Model_Observer
|
|
37 |
{
|
38 |
/* @var $collection Mage_Eav_Model_Entity_Collection_Abstract */
|
39 |
$collection = $observer->getEvent()->getCollection();
|
40 |
-
|
|
|
41 |
$collection->addAttributeToSelect('username');
|
42 |
}
|
43 |
|
37 |
{
|
38 |
/* @var $collection Mage_Eav_Model_Entity_Collection_Abstract */
|
39 |
$collection = $observer->getEvent()->getCollection();
|
40 |
+
$entity = $collection->getEntity();
|
41 |
+
if (!empty($entity) && $entity->getType() == 'customer') {
|
42 |
$collection->addAttributeToSelect('username');
|
43 |
}
|
44 |
|
@@ -2,7 +2,7 @@
|
|
2 |
<config>
|
3 |
<modules>
|
4 |
<Diglin_Username>
|
5 |
-
<version>2.0.
|
6 |
</Diglin_Username>
|
7 |
</modules>
|
8 |
<default>
|
2 |
<config>
|
3 |
<modules>
|
4 |
<Diglin_Username>
|
5 |
+
<version>2.0.3</version>
|
6 |
</Diglin_Username>
|
7 |
</modules>
|
8 |
<default>
|
@@ -1,7 +1,7 @@
|
|
1 |
<?xml version="1.0"?>
|
2 |
<package>
|
3 |
<name>Diglin_Username</name>
|
4 |
-
<version>2.0.
|
5 |
<stability>stable</stability>
|
6 |
<license uri="http://www.opensource.org/licenses/osl-3.0.php">OSL v3.0</license>
|
7 |
<channel>community</channel>
|
@@ -25,7 +25,8 @@ Allow to disable an account from backend. The user will be blocked if the option
|
|
25 |
- NEW - support username into the template of the persistent module
|
26 |

|
27 |
Use MageTrashApp to uninstall this module correctly: https://github.com/magento-hackathon/MageTrashApp</description>
|
28 |
-
<notes>- 2.0.
|
|
|
29 |
- 2.0.1 / 2.0.2:
|
30 |
- Add composer, modman, MageTrashApp support to help installing and uninstalling this module
|
31 |
- Move template to design base package
|
@@ -41,9 +42,9 @@ Use MageTrashApp to uninstall this module correctly: https://github.com/magento-
|
|
41 |
- Version 1.0.1 - fix bug in sql query during installation on prefixed tables, add german translation, do package for Magento version prior to 1.5 and version 1.5.x
|
42 |
- Version 1.0.0 - stable version</notes>
|
43 |
<authors><author><name>diglin</name><user>auto-converted</user><email>sly@diglin.com</email></author></authors>
|
44 |
-
<date>2013-06-
|
45 |
-
<time>
|
46 |
-
<contents><target name="mageetc"><dir name="modules"><file name="Diglin_Username.xml" hash="79603fae3def6dd098d4be51897e1ec6"/><file name="Hackathon_MageTrashApp.xml" hash="247c6b5278c3681efe24f504c5b48970"/></dir></target><target name="magecommunity"><dir name="Diglin"><dir name="Username"><dir name="Block"><dir name="Overwrite"><dir name="Adminhtml"><dir name="Config"><dir name="Source"><file name="Hint.php" hash="85edae9eec85d06b63a8c259cb787b23"/></dir></dir><file name="Grid.php" hash="fa13010ac51260cf515fd8710af9abea"/></dir></dir></dir><dir name="Helper"><file name="Data.php" hash="803f067b0eb5ff5629a113c6d723e54d"/></dir><dir name="Model"><dir name="Config"><dir name="Source"><file name="Inputvalidation.php" hash="cfe26f69418559c14f1b8b6ca3eabc93"/></dir><file name="Share.php" hash="8258ff3fd56df05dec26529e785cf1a5"/></dir><dir name="Entity"><file name="Customer.php" hash="2999c400148c03e5f11d075ef505211a"/><file name="Setup.php" hash="73fbe07ed6383c4bda8be73e9c43c923"/></dir><dir name="Import"><dir name="Entity"><file name="Customer.php" hash="1cfb9b92dfeff58dffe5329aefe5beb0"/></dir></dir><file name="Customer.php" hash="75c540a2fca3469c2318f4f649e1eb21"/><file name="Form.php" hash="
|
47 |
<compatible/>
|
48 |
<dependencies/>
|
49 |
</package>
|
1 |
<?xml version="1.0"?>
|
2 |
<package>
|
3 |
<name>Diglin_Username</name>
|
4 |
+
<version>2.0.4</version>
|
5 |
<stability>stable</stability>
|
6 |
<license uri="http://www.opensource.org/licenses/osl-3.0.php">OSL v3.0</license>
|
7 |
<channel>community</channel>
|
25 |
- NEW - support username into the template of the persistent module
|
26 |

|
27 |
Use MageTrashApp to uninstall this module correctly: https://github.com/magento-hackathon/MageTrashApp</description>
|
28 |
+
<notes>- 2.0.4: fix of "username exists" error message
|
29 |
+
- 2.0.3: fix bad Observer merge
|
30 |
- 2.0.1 / 2.0.2:
|
31 |
- Add composer, modman, MageTrashApp support to help installing and uninstalling this module
|
32 |
- Move template to design base package
|
42 |
- Version 1.0.1 - fix bug in sql query during installation on prefixed tables, add german translation, do package for Magento version prior to 1.5 and version 1.5.x
|
43 |
- Version 1.0.0 - stable version</notes>
|
44 |
<authors><author><name>diglin</name><user>auto-converted</user><email>sly@diglin.com</email></author></authors>
|
45 |
+
<date>2013-06-04</date>
|
46 |
+
<time>09:08:09</time>
|
47 |
+
<contents><target name="mageetc"><dir name="modules"><file name="Diglin_Username.xml" hash="79603fae3def6dd098d4be51897e1ec6"/><file name="Hackathon_MageTrashApp.xml" hash="247c6b5278c3681efe24f504c5b48970"/></dir></target><target name="magecommunity"><dir name="Diglin"><dir name="Username"><dir name="Block"><dir name="Overwrite"><dir name="Adminhtml"><dir name="Config"><dir name="Source"><file name="Hint.php" hash="85edae9eec85d06b63a8c259cb787b23"/></dir></dir><file name="Grid.php" hash="fa13010ac51260cf515fd8710af9abea"/></dir></dir></dir><dir name="Helper"><file name="Data.php" hash="803f067b0eb5ff5629a113c6d723e54d"/></dir><dir name="Model"><dir name="Config"><dir name="Source"><file name="Inputvalidation.php" hash="cfe26f69418559c14f1b8b6ca3eabc93"/></dir><file name="Share.php" hash="8258ff3fd56df05dec26529e785cf1a5"/></dir><dir name="Entity"><file name="Customer.php" hash="2999c400148c03e5f11d075ef505211a"/><file name="Setup.php" hash="73fbe07ed6383c4bda8be73e9c43c923"/></dir><dir name="Import"><dir name="Entity"><file name="Customer.php" hash="1cfb9b92dfeff58dffe5329aefe5beb0"/></dir></dir><file name="Customer.php" hash="75c540a2fca3469c2318f4f649e1eb21"/><file name="Form.php" hash="399225bb04bc98b6a844e86635da1950"/><file name="Observer.php" hash="30dff0af4237ff39444f6853498a2d51"/></dir><dir name="controllers"><file name="AccountController.php" hash="8edbee496580e7650495861e9a3b3710"/></dir><dir name="data"><dir name="username_setup"><file name="data-install-2.0.0.php" hash="cf95f627b016974215142ec72018ef94"/></dir></dir><dir name="etc"><file name="adminhtml.xml" hash="8eaa2843438b116e9d0425fcdd2ccabf"/><file name="config.xml" hash="0527e4c7fcd2a73cdfec11af318f6df5"/><file name="system.xml" hash="fadc30d87b96cf220854af18f8788f77"/><file name="uninstall.txt" hash="70ce51e6ea76f07394760ca567cd6294"/></dir><dir name="sql"><dir name="username_setup"><file name="install-2.0.0.php" hash="6c827f26e94876a82012a91f6b74370d"/><file name="mysql4-install-1.0.0.php" hash="deaa6e702bd0a6b83c41a10fbcc5cce9"/><file name="mysql4-upgrade-1.0.0-1.1.0.php" hash="fe759e361a65fc51eb6dc8a50b9605e8"/><file name="mysql4-upgrade-1.1.0-1.2.0.php" hash="21cdb85ec6ad08fac97252a604ca17ba"/><file name="mysql4-upgrade-1.3.0-1.4.0.php" hash="93f4d880243152b75ed2be2b26084e3d"/><file name="mysql4-upgrade-1.4.0-2.0.0.php" hash="cbe2c4027c846567eb45f757193f4edc"/><file name="uninstall.php" hash="379f87574ab4d0e95e3aace302bd572a"/></dir></dir></dir></dir><dir name="Hackathon"><dir name="MageTrashApp"><dir name="Adminhtml"><dir name="Block"><dir name="System"><dir name="Config"><dir name="Form"><dir name="Fieldset"><dir name="Modules"><file name="MageTrashApp.php" hash="8dc018926d9478d2ee12b505033e312a"/></dir></dir></dir></dir></dir></dir></dir><dir name="Block"><dir name="Adminhtml"><dir name="System"><dir name="Config"><dir name="Form"><dir name="Fieldset"><dir name="Modules"><file name="MageTrashApp.php" hash="190b72529aa16a61b6bc2490774304e3"/><file name="Rewind.php" hash="6a7d8004e79fd2f5226b2ca6f1a32d48"/></dir></dir></dir></dir></dir></dir></dir><dir name="Helper"><file name="Data.php" hash="6ea1f755b3470cd8254fec25977f08bd"/></dir><dir name="Model"><dir name="Adminhtml"><dir name="Config"><file name="Data.php" hash="666da6fe6343b0bf38ac6313242871bc"/></dir></dir><dir name="Resource"><file name="Resource.php" hash="ba46996c23e6c17db231fcfd7eeee1cd"/><file name="Setup.php" hash="01c3a067fb830edd7c2783b9a9b2d2bb"/></dir><file name="CoreResource.php" hash="48faa17486cbdb58b5b58e26a892bc8a"/><file name="Observer.php" hash="4edb98984908198865fd9a73fe15ccab"/><file name="PearWrapper.php" hash="5bfc49da1c0c4b8801217e1ece28b7e9"/><file name="Uninstall.php" hash="e8fe01333bae1d1c187b7eb95568e903"/></dir><dir name="Test"><dir name="Config"><file name="Config.php" hash="71d4e2715f295ac097316e02736fc986"/></dir><dir name="Helper"><file name="DataTest.php" hash="7bfebdb2953dc220457240fd01503ab7"/></dir><dir name="Model"><file name="Observer.php" hash="fbd80ba2d0eb8c6058f1a45d00e476f5"/></dir></dir><dir name="controllers"><dir name="Adminhtml"><file name="indexController.php" hash="b4ea9f1b928458c1af902416b91300d0"/></dir></dir><dir name="etc"><file name="adminhtml.xml" hash="29e4e7211061fb73eeceb1a6dc510dad"/><file name="config.xml" hash="767b2cd648240b07c858ef7282827571"/><file name="doc.uninstall.txt" hash="b2de80f292016c5392b0edbc21ac29f1"/><file name="system.xml" hash="ca750acb4682fc8edea2f5aa451278a5"/></dir></dir></dir></target><target name="magedesign"><dir name="frontend"><dir name="base"><dir name="default"><dir name="template"><dir name="username"><dir name="checkout"><dir name="onepage"><dir name="13"><file name="billing.phtml" hash="e7875ec85ee418539807266e0f8d7581"/></dir><dir name="17"><file name="billing.phtml" hash="35a3604ae93631f7a6522f923d2d364d"/></dir><file name="billing.phtml" hash="3e91cd48d06ba295d367b866986ad25a"/><file name="login.phtml" hash="5db44d2a09be5d33cdbacdab2a1fa978"/></dir></dir><dir name="customer"><dir name="account"><dir name="dashboard"><file name="info.phtml" hash="4fbd87ccca20ca1c28ef64c060a13cce"/></dir></dir><dir name="form"><dir name="13"><file name="register.phtml" hash="788e9c07648371ca7eec005091a6f743"/></dir><dir name="17"><file name="register.phtml" hash="236486d1b7e9d60f686c46d3e485d793"/></dir><file name="edit.phtml" hash="9169cd9135d7f0b74ae9f973f0fd6f36"/><file name="forgotpassword.phtml" hash="2764b7f1630adeda0bf058a148f2202e"/><file name="login.phtml" hash="aaad00540adca570d18dba9afc0f1858"/><file name="register.phtml" hash="2a74a300edcf780acb804b8cd25c393e"/></dir></dir><dir name="persistent"><dir name="checkout"><dir name="onepage"><file name="billing.phtml" hash="02653472f632833b8bc86245ff41d33c"/><file name="login.phtml" hash="27bd60ec63fc2911458df4191fc465be"/></dir></dir><dir name="customer"><dir name="form"><file name="login.phtml" hash="959d89c5e13704e289c861a1d8fcee13"/><file name="register.phtml" hash="1763f5b002dbadf20dd97875123e2aef"/></dir></dir></dir></dir></dir><dir name="layout"><file name="username.xml" hash="432ef8d9bd05bdfedfae879c981ba95c"/></dir></dir></dir></dir></target><target name="magelocale"><dir name="en_GB"><file name="Diglin_Username.csv" hash="2d18fb6bfc2c4c56f19cfe7ee6761f4b"/></dir><dir name="en_US"><file name="Diglin_Username.csv" hash="2d18fb6bfc2c4c56f19cfe7ee6761f4b"/></dir><dir name="fr_FR"><file name="Diglin_Username.csv" hash="d8d025c852649fc8e9edd2aed5ab377a"/></dir><dir name="de_DE"><file name="Diglin_Username.csv" hash="7a0aa81dbdafe2ef121a08cd03c64893"/></dir></target></contents>
|
48 |
<compatible/>
|
49 |
<dependencies/>
|
50 |
</package>
|