Skip to content
Snippets Groups Projects
Commit ef1217ce authored by Satish's avatar Satish
Browse files

Fixes #721 - Creating event from Contact with No organization linked

parent 3819e131
No related branches found
No related tags found
No related merge requests found
......@@ -82,7 +82,10 @@ Class Calendar_Edit_View extends Vtiger_Edit_View {
$relContactId = $request->get('contact_id');
if ($relContactId) {
$contactRecordModel = Vtiger_Record_Model::getInstanceById($relContactId);
$requestFieldList['parent_id'] = $contactRecordModel->get('account_id');
$accountId = $contactRecordModel->get('account_id');
if ($accountId) {
$requestFieldList['parent_id'] = $accountId;
}
}
foreach($requestFieldList as $fieldName=>$fieldValue){
$fieldModel = $fieldList[$fieldName];
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment