Initializes the admin contact's phone number, in case it is a mandatory field in the data model...

SVN:1.2[1623]
This commit is contained in:
Denis Flaven
2011-09-30 08:03:45 +00:00
parent 398e294604
commit eb8f49ebfe

View File

@@ -557,6 +557,10 @@ class UserRightsProfile extends UserRightsAddOnAPI
{
$oContact->Set('org_id', $iOrgId);
}
if (MetaModel::IsValidAttCode('Person', 'phone'))
{
$oContact->Set('phone', '+00 000 000 000');
}
$oContact->Set('email', 'my.email@foo.org');
$iContactId = $oContact->DBInsertTrackedNoReload($oChange, true /* skip security */);
}