Add php files

This commit is contained in:
2025-05-12 15:44:39 +00:00
parent c951760058
commit 82d5804ac4
9534 changed files with 2638137 additions and 0 deletions

View File

@@ -0,0 +1,146 @@
<?php
/*********************************************************************************
* SugarCRM is a customer relationship management program developed by
* SugarCRM, Inc. Copyright (C) 2004-2010 SugarCRM Inc.
*
* This program is free software; you can redistribute it and/or modify it under
* the terms of the GNU Affero General Public License version 3 as published by the
* Free Software Foundation with the addition of the following permission added
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
*
* This program is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
* FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more
* details.
*
* You should have received a copy of the GNU Affero General Public License along with
* this program; if not, see http://www.gnu.org/licenses or write to the Free
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
* 02110-1301 USA.
*
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
*
* The interactive user interfaces in modified source and object code versions
* of this program must display Appropriate Legal Notices, as required under
* Section 5 of the GNU Affero General Public License version 3.
*
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
* these Appropriate Legal Notices must retain the display of the "Powered by
* SugarCRM" logo. If the display of the logo is not reasonably feasible for
* technical reasons, the Appropriate Legal Notices must display the words
* "Powered by SugarCRM".
********************************************************************************/
require_once('include/SugarObjects/templates/basic/Basic.php');
class Person extends Basic
{
var $picture;
function Person(){
parent::SugarBean();
$this->emailAddress = new SugarEmailAddress();
}
// need to override to have a name field created for this class
function retrieve($id = -1, $encode=true) {
$ret_val = parent::retrieve($id, $encode);
$this->_create_proper_name_field();
$this->emailAddress->handleLegacyRetrieve($this);
return $ret_val;
}
/**
* Generate the name field from the first_name and last_name fields.
*/
protected function _create_proper_name_field()
{
global $locale, $app_list_strings;
// Bug 38648 - If the given saluation doesn't exist in the dropdown, don't display it as part of the full name
$salutation = '';
if(isset($this->field_defs['salutation']['options'])
&& isset($app_list_strings[$this->field_defs['salutation']['options']])
&& isset($app_list_strings[$this->field_defs['salutation']['options']][$this->salutation]) ) {
$salutation = $app_list_strings[$this->field_defs['salutation']['options']][$this->salutation];
}
$full_name = $locale->getLocaleFormattedName($this->first_name, $this->last_name, $salutation, $this->title);
$this->name = $full_name;
$this->full_name = $full_name; //used by campaigns
}
function save($check_notify=false) {
$this->add_address_streets('primary_address_street');
$this->add_address_streets('alt_address_street');
$ori_in_workflow = empty($this->in_workflow) ? false : true;
$this->emailAddress->handleLegacySave($this, $this->module_dir);
parent::save($check_notify);
$override_email = array();
if(!empty($this->email1_set_in_workflow)) {
$override_email['emailAddress0'] = $this->email1_set_in_workflow;
}
if(!empty($this->email2_set_in_workflow)) {
$override_email['emailAddress1'] = $this->email2_set_in_workflow;
}
if(!isset($this->in_workflow)) {
$this->in_workflow = false;
}
if($ori_in_workflow === false || !empty($override_email)){
$this->emailAddress->save($this->id, $this->module_dir, $override_email,'','','','',$this->in_workflow);
}
return $this->id;
}
function get_summary_text() {
$this->_create_proper_name_field();
return $this->name;
}
function get_list_view_data() {
global $system_config;
global $current_user;
$this->_create_proper_name_field();
$temp_array = $this->get_list_view_array();
$temp_array['NAME'] = $this->name;
$temp_array['EMAIL1'] = $this->emailAddress->getPrimaryAddress($this);
$this->email1 = $temp_array['EMAIL1'];
$temp_array['EMAIL1_LINK'] = $current_user->getEmailLink('email1', $this, '', '', 'ListView');
return $temp_array;
}
/**
* @see SugarBean::populateRelatedBean()
*/
public function populateRelatedBean(
SugarBean $newbean
)
{
parent::populateRelatedBean($newbean);
if ( $newbean instanceOf Company ) {
$newbean->phone_fax = $this->phone_fax;
$newbean->phone_office = $this->phone_work;
$newbean->phone_alternate = $this->phone_other;
$newbean->email1 = $this->email1;
$this->add_address_streets('primary_address_street');
$newbean->billing_address_street = $this->primary_address_street;
$newbean->billing_address_city = $this->primary_address_city;
$newbean->billing_address_state = $this->primary_address_state;
$newbean->billing_address_postalcode = $this->primary_address_postalcode;
$newbean->billing_address_country = $this->primary_address_country;
$this->add_address_streets('alt_address_street');
$newbean->register_address_street = $this->alt_address_street;
$newbean->register_address_city = $this->alt_address_city;
$newbean->register_address_state = $this->alt_address_state;
$newbean->register_address_postalcode = $this->alt_address_postalcode;
$newbean->register_address_country = $this->alt_address_country;
}
}
}
?>

View File

@@ -0,0 +1,38 @@
<?php
/*********************************************************************************
* SugarCRM is a customer relationship management program developed by
* SugarCRM, Inc. Copyright (C) 2004-2010 SugarCRM Inc.
*
* This program is free software; you can redistribute it and/or modify it under
* the terms of the GNU Affero General Public License version 3 as published by the
* Free Software Foundation with the addition of the following permission added
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
*
* This program is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
* FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more
* details.
*
* You should have received a copy of the GNU Affero General Public License along with
* this program; if not, see http://www.gnu.org/licenses or write to the Free
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
* 02110-1301 USA.
*
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
*
* The interactive user interfaces in modified source and object code versions
* of this program must display Appropriate Legal Notices, as required under
* Section 5 of the GNU Affero General Public License version 3.
*
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
* these Appropriate Legal Notices must retain the display of the "Powered by
* SugarCRM" logo. If the display of the logo is not reasonably feasible for
* technical reasons, the Appropriate Legal Notices must display the words
* "Powered by SugarCRM".
********************************************************************************/
$config = array(
'image'=>'Contacts'
);

View File

@@ -0,0 +1,81 @@
<?php
/*********************************************************************************
* SugarCRM is a customer relationship management program developed by
* SugarCRM, Inc. Copyright (C) 2004-2010 SugarCRM Inc.
*
* This program is free software; you can redistribute it and/or modify it under
* the terms of the GNU Affero General Public License version 3 as published by the
* Free Software Foundation with the addition of the following permission added
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
*
* This program is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
* FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more
* details.
*
* You should have received a copy of the GNU Affero General Public License along with
* this program; if not, see http://www.gnu.org/licenses or write to the Free
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
* 02110-1301 USA.
*
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
*
* The interactive user interfaces in modified source and object code versions
* of this program must display Appropriate Legal Notices, as required under
* Section 5 of the GNU Affero General Public License version 3.
*
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
* these Appropriate Legal Notices must retain the display of the "Powered by
* SugarCRM" logo. If the display of the logo is not reasonably feasible for
* technical reasons, the Appropriate Legal Notices must display the words
* "Powered by SugarCRM".
********************************************************************************/
$mod_strings = array(
'LBL_SALUTATION'=>'Salutation',
'LBL_NAME'=>'Name',
'LBL_FIRST_NAME'=>'First Name',
'LBL_LAST_NAME'=>'Last Name',
'LBL_TITLE'=>'Title',
'LBL_DEPARTMENT'=>'Department',
'LBL_DO_NOT_CALL'=>'Do Not Call',
'LBL_HOME_PHONE'=>'Home Phone',
'LBL_MOBILE_PHONE'=>'Mobile Phone',
'LBL_OFFICE_PHONE'=>'Office Phone',
'LBL_OTHER_PHONE'=>'Other Phone',
'LBL_FAX_PHONE'=>'Fax',
'LBL_EMAIL_ADDRESS'=>'Email Address(es)',
'LBL_PRIMARY_ADDRESS'=>'Primary Address',
'LBL_PRIMARY_ADDRESS_STREET'=>'Primary Address',
'LBL_PRIMARY_ADDRESS_STREET_2' => 'Primary Address Street 2:',
'LBL_PRIMARY_ADDRESS_STREET_3' => 'Primary Address Street 3:',
'LBL_PRIMARY_ADDRESS_CITY'=>'Primary City',
'LBL_PRIMARY_ADDRESS_STATE'=>'Primary State',
'LBL_PRIMARY_ADDRESS_POSTALCODE'=>'Primary Postal Code',
'LBL_PRIMARY_ADDRESS_COUNTRY' => 'Primary Address Country:',
'LBL_ALT_ADDRESS_STREET'=>'Alternate Address',
'LBL_ALT_ADDRESS_STREET_2' => 'Alternate Address Street 2:',
'LBL_ALT_ADDRESS_STREET_3' => 'Alternate Address Street 3:',
'LBL_ALT_ADDRESS_CITY'=>'Alternate City',
'LBL_ALT_ADDRESS_STATE'=>'Alternate State',
'LBL_ALT_ADDRESS_POSTALCODE'=>'Alternate Postal Code',
'LBL_ALT_ADDRESS_COUNTRY'=>'Alternate Country',
'LBL_COUNTRY'=>'Country',
'LBL_STREET'=>'Other Address',
'LBL_CITY'=>'City',
'LBL_STATE'=>'State',
'LBL_POSTALCODE'=>'Postal Code',
'LBL_POSTAL_CODE'=>'Postal Code',
'LBL_COUNTRY'=>'Country',
'LBL_CONTACT_INFORMATION'=>'Contact Information',
'LBL_ADDRESS_INFORMATION'=>'Address(es)',
'LBL_CONTACT_INFORMATION'=>'Contact Information',
'LBL_ASSIGNED_TO_NAME'=>'User',
'LBL_OTHER_EMAIL_ADDRESS' => 'Other Email:',
'LBL_ASSISTANT'=>'Assistant',
'LBL_ASSISTANT_PHONE'=>'Assistant Phone',
'LBL_WORK_PHONE'=>'Work Phone',
'LNK_IMPORT_VCARD' => 'Create From vCard',
);

View File

@@ -0,0 +1,73 @@
<?php
/*********************************************************************************
* The contents of this file are subject to the SugarCRM Enterprise Subscription
* Agreement ("License") which can be viewed at
* http://www.sugarcrm.com/crm/products/sugar-enterprise-eula.html
* By installing or using this file, You have unconditionally agreed to the
* terms and conditions of the License, and You may not use this file except in
* compliance with the License. Under the terms of the license, You shall not,
* among other things: 1) sublicense, resell, rent, lease, redistribute, assign
* or otherwise transfer Your rights to the Software, and 2) use the Software
* for timesharing or service bureau purposes such as hosting the Software for
* commercial gain and/or for the benefit of a third party. Use of the Software
* may be subject to applicable fees and any use of the Software without first
* paying applicable fees is strictly prohibited. You do not have the right to
* remove SugarCRM copyrights from the source code or user interface.
*
* All copies of the Covered Code must include on each user interface screen:
* (i) the "Powered by SugarCRM" logo and
* (ii) the SugarCRM copyright notice
* in the same form as they appear in the distribution. See full license for
* requirements.
*
* Your Warranty, Limitations of liability and Indemnity are expressly stated
* in the License. Please refer to the License for the specific language
* governing these rights and limitations under the License. Portions created
* by SugarCRM are Copyright (C) 2004-2007 SugarCRM, Inc.; All Rights Reserved.
********************************************************************************/
$mod_strings = array(
'LBL_SALUTATION'=>'Pozdrowienie',
'LBL_NAME'=>'Nazwa',
'LBL_FIRST_NAME'=>'Imię',
'LBL_LAST_NAME'=>'Nazwisko',
'LBL_TITLE'=>'Tytuł',
'LBL_DEPARTMENT'=>'Departament',
'LBL_DO_NOT_CALL'=>'Nie dzownić',
'LBL_HOME_PHONE'=>'Telefon domowy',
'LBL_MOBILE_PHONE'=>'Tel. kom.',
'LBL_OFFICE_PHONE'=>'Tel. praca',
'LBL_OTHER_PHONE'=>'Inny tel.',
'LBL_FAX_PHONE'=>'Fax',
'LBL_EMAIL_ADDRESS'=>'Adresy poczty',
'LBL_PRIMARY_ADDRESS'=>'Podstawowy adres',
'LBL_PRIMARY_ADDRESS_STREET'=>'Podstawowy adres',
'LBL_PRIMARY_ADDRESS_STREET_2' => 'Podstawowy adres 2:',
'LBL_PRIMARY_ADDRESS_STREET_3' => 'Podstawowy adres 3:',
'LBL_PRIMARY_ADDRESS_CITY'=>'Miasto',
'LBL_PRIMARY_ADDRESS_STATE'=>'Wojewodztwo',
'LBL_PRIMARY_ADDRESS_POSTALCODE'=>'Kod pocztowy',
'LBL_PRIMARY_ADDRESS_COUNTRY' => 'Podstawowy adres kraj:',
'LBL_ALT_ADDRESS_COUNTRY'=>'Kraj',
'LBL_ALT_ADDRESS_STREET'=>'Ulica',
'LBL_ALT_ADDRESS_STREET_2' => 'Inny adre 2:',
'LBL_ALT_ADDRESS_STREET_3' => 'Inny adres 3:',
'LBL_ALT_ADDRESS_CITY'=>'Miasto',
'LBL_ALT_ADDRESS_STATE'=>'Woj.',
'LBL_ALT_ADDRESS_POSTALCODE'=>'Kod pocztowy',
'LBL_ALT_ADDRESS_COUNTRY'=>'Kraj',
'LBL_COUNTRY'=>'Kraj',
'LBL_STREET'=>'Ulica',
'LBL_CITY'=>'Miasto',
'LBL_STATE'=>'Woj.',
'LBL_POSTALCODE'=>'Kod pocztowy',
'LBL_POSTAL_CODE'=>'Kod pocztowy',
'LBL_COUNTRY'=>'Kraj',
'LBL_CONTACT_INFORMATION'=>'Informacje o kontakcie',
'LBL_ADDRESS_INFORMATION'=>'Adresy',
'LBL_CONTACT_INFORMATION'=>'Informacje o kontakcie',
'LBL_ASSIGNED_TO_NAME'=>'Przydzielony do',
'LBL_ASSISTANT'=>'Asystent',
'LBL_ASSISTANT_PHONE'=>'Tel. asystenta',
'LBL_WORK_PHONE'=>'Telefon do pracy',
'LNK_IMPORT_VCARD' => 'Utwórz z vCard',
);

View File

@@ -0,0 +1,52 @@
<?php
if(!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point');
/*********************************************************************************
* SugarCRM is a customer relationship management program developed by
* SugarCRM, Inc. Copyright (C) 2004-2010 SugarCRM Inc.
*
* This program is free software; you can redistribute it and/or modify it under
* the terms of the GNU Affero General Public License version 3 as published by the
* Free Software Foundation with the addition of the following permission added
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
*
* This program is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
* FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more
* details.
*
* You should have received a copy of the GNU Affero General Public License along with
* this program; if not, see http://www.gnu.org/licenses or write to the Free
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
* 02110-1301 USA.
*
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
*
* The interactive user interfaces in modified source and object code versions
* of this program must display Appropriate Legal Notices, as required under
* Section 5 of the GNU Affero General Public License version 3.
*
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
* these Appropriate Legal Notices must retain the display of the "Powered by
* SugarCRM" logo. If the display of the logo is not reasonably feasible for
* technical reasons, the Appropriate Legal Notices must display the words
* "Powered by SugarCRM".
********************************************************************************/
$module_name = '<module_name>';
$searchFields[$module_name] =
array (
'first_name' => array( 'query_type'=>'default'),
'last_name'=> array('query_type'=>'default'),
'search_name'=> array('query_type'=>'default','db_field'=>array('first_name','last_name'),'force_unifiedsearch'=>true),
'do_not_call'=> array('query_type'=>'default', 'input_type' => 'checkbox', 'operator'=>'='),
'phone'=> array('query_type'=>'default','db_field'=>array('phone_mobile','phone_work','phone_other','phone_fax','assistant_phone')),
'address_street'=> array('query_type'=>'default','db_field'=>array('primary_address_street','alt_address_street')),
'address_city'=> array('query_type'=>'default','db_field'=>array('primary_address_city','alt_address_city')),
'address_state'=> array('query_type'=>'default','db_field'=>array('primary_address_state','alt_address_state')),
'address_postalcode'=> array('query_type'=>'default','db_field'=>array('primary_address_postalcode','alt_address_postalcode')),
'address_country'=> array('query_type'=>'default','db_field'=>array('primary_address_country','alt_address_country')),
'current_user_only'=> array('query_type'=>'default','db_field'=>array('assigned_user_id'),'my_items'=>true, 'vname' => 'LBL_CURRENT_USER_FILTER', 'type' => 'bool'),
);
?>

View File

@@ -0,0 +1,58 @@
<?php
if(!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point');
/*********************************************************************************
* SugarCRM is a customer relationship management program developed by
* SugarCRM, Inc. Copyright (C) 2004-2010 SugarCRM Inc.
*
* This program is free software; you can redistribute it and/or modify it under
* the terms of the GNU Affero General Public License version 3 as published by the
* Free Software Foundation with the addition of the following permission added
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
*
* This program is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
* FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more
* details.
*
* You should have received a copy of the GNU Affero General Public License along with
* this program; if not, see http://www.gnu.org/licenses or write to the Free
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
* 02110-1301 USA.
*
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
*
* The interactive user interfaces in modified source and object code versions
* of this program must display Appropriate Legal Notices, as required under
* Section 5 of the GNU Affero General Public License version 3.
*
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
* these Appropriate Legal Notices must retain the display of the "Powered by
* SugarCRM" logo. If the display of the logo is not reasonably feasible for
* technical reasons, the Appropriate Legal Notices must display the words
* "Powered by SugarCRM".
********************************************************************************/
global $current_user;
$dashletData['<module_name>Dashlet']['searchFields'] = array('date_entered' => array('default' => ''),
'date_modified' => array('default' => ''),
'assigned_user_id' => array('type' => 'assigned_user_name',
'default' => $current_user->name));
$dashletData['<module_name>Dashlet']['columns'] = array( 'name' => array('width' => '40',
'label' => 'LBL_LIST_NAME',
'link' => true,
'default' => true),
'date_entered' => array('width' => '15',
'label' => 'LBL_DATE_ENTERED',
'default' => true),
'date_modified' => array('width' => '15',
'label' => 'LBL_DATE_MODIFIED'),
'created_by' => array('width' => '8',
'label' => 'LBL_CREATED'),
'assigned_user_name' => array('width' => '8',
'label' => 'LBL_LIST_ASSIGNED_USER'),
);

View File

@@ -0,0 +1,134 @@
<?php
/*********************************************************************************
* SugarCRM is a customer relationship management program developed by
* SugarCRM, Inc. Copyright (C) 2004-2010 SugarCRM Inc.
*
* This program is free software; you can redistribute it and/or modify it under
* the terms of the GNU Affero General Public License version 3 as published by the
* Free Software Foundation with the addition of the following permission added
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
*
* This program is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
* FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more
* details.
*
* You should have received a copy of the GNU Affero General Public License along with
* this program; if not, see http://www.gnu.org/licenses or write to the Free
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
* 02110-1301 USA.
*
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
*
* The interactive user interfaces in modified source and object code versions
* of this program must display Appropriate Legal Notices, as required under
* Section 5 of the GNU Affero General Public License version 3.
*
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
* these Appropriate Legal Notices must retain the display of the "Powered by
* SugarCRM" logo. If the display of the logo is not reasonably feasible for
* technical reasons, the Appropriate Legal Notices must display the words
* "Powered by SugarCRM".
********************************************************************************/
$module_name = '<module_name>';
$viewdefs[$module_name]['DetailView'] = array(
'templateMeta' => array('form' => array('buttons'=>array('EDIT', 'DUPLICATE', 'DELETE', 'FIND_DUPLICATES',
),
),
'maxColumns' => '2',
'widths' => array(
array('label' => '10', 'field' => '30'),
array('label' => '10', 'field' => '30')
),
),
'panels' =>array (
array (
array (
'name' => 'full_name',
'label' => 'LBL_NAME',
),
//'full_name',
array (
'name' => 'phone_work',
),
),
array (
'title',
array (
'name' => 'phone_mobile',
),
),
array (
'department',
array (
'name' => 'phone_home',
'label' => 'LBL_HOME_PHONE',
),
),
array (
NULL,
array (
'name' => 'phone_other',
'label' => 'LBL_OTHER_PHONE',
),
),
array (
array (
'name' => 'date_entered',
'customCode' => '{$fields.date_entered.value} {$APP.LBL_BY} {$fields.created_by_name.value}',
'label' => 'LBL_DATE_ENTERED',
),
array (
'name' => 'phone_fax',
'label' => 'LBL_FAX_PHONE',
),
),
array (
array (
'name' => 'date_modified',
'customCode' => '{$fields.date_modified.value} {$APP.LBL_BY} {$fields.modified_by_name.value}',
'label' => 'LBL_DATE_MODIFIED',
),
'do_not_call',
),
array('assigned_user_name', ''),
array(
'email1'),
array (
array (
'name' => 'primary_address_street',
'label'=> 'LBL_PRIMARY_ADDRESS',
'type' => 'address',
'displayParams'=>array('key'=>'primary'),
),
array (
'name' => 'alt_address_street',
'label'=> 'LBL_ALT_ADDRESS',
'type' => 'address',
'displayParams'=>array('key'=>'alt'),
),
),
array (
'description',
),
)
);
?>

View File

@@ -0,0 +1,112 @@
<?php
/*********************************************************************************
* SugarCRM is a customer relationship management program developed by
* SugarCRM, Inc. Copyright (C) 2004-2010 SugarCRM Inc.
*
* This program is free software; you can redistribute it and/or modify it under
* the terms of the GNU Affero General Public License version 3 as published by the
* Free Software Foundation with the addition of the following permission added
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
*
* This program is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
* FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more
* details.
*
* You should have received a copy of the GNU Affero General Public License along with
* this program; if not, see http://www.gnu.org/licenses or write to the Free
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
* 02110-1301 USA.
*
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
*
* The interactive user interfaces in modified source and object code versions
* of this program must display Appropriate Legal Notices, as required under
* Section 5 of the GNU Affero General Public License version 3.
*
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
* these Appropriate Legal Notices must retain the display of the "Powered by
* SugarCRM" logo. If the display of the logo is not reasonably feasible for
* technical reasons, the Appropriate Legal Notices must display the words
* "Powered by SugarCRM".
********************************************************************************/
$module_name = '<module_name>';
$viewdefs[$module_name]['EditView'] = array(
'templateMeta' => array('maxColumns' => '2',
'widths' => array(
array('label' => '10', 'field' => '30'),
array('label' => '10', 'field' => '30'),
),
),
'panels' =>array (
'lbl_contact_information' =>
array (
array (
array (
'name' => 'first_name',
'customCode' => '{html_options name="salutation" options=$fields.salutation.options selected=$fields.salutation.value}&nbsp;<input name="first_name" size="25" maxlength="25" type="text" value="{$fields.first_name.value}">',
),
'phone_work',
),
array (
'last_name',
'phone_mobile',
),
array (
'title',
'phone_home',
),
array (
'department',
'phone_other',
),
array (
'',
'phone_fax',
),
array (
'assigned_user_name',
'do_not_call',
),
array (
'description',
),
),
'lbl_email_addresses'=>array(
array('email1')
),
'lbl_address_information' =>
array (
array (
array (
'name' => 'primary_address_street',
'hideLabel' => true,
'type' => 'address',
'displayParams'=>array('key'=>'primary', 'rows'=>2, 'cols'=>30, 'maxlength'=>150),
),
array (
'name' => 'alt_address_street',
'hideLabel'=>true,
'type' => 'address',
'displayParams'=>array('key'=>'alt', 'copy'=>'primary', 'rows'=>2, 'cols'=>30, 'maxlength'=>150),
),
),
),
)
);
?>

View File

@@ -0,0 +1,99 @@
<?php
if(!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point');
/*********************************************************************************
* SugarCRM is a customer relationship management program developed by
* SugarCRM, Inc. Copyright (C) 2004-2010 SugarCRM Inc.
*
* This program is free software; you can redistribute it and/or modify it under
* the terms of the GNU Affero General Public License version 3 as published by the
* Free Software Foundation with the addition of the following permission added
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
*
* This program is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
* FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more
* details.
*
* You should have received a copy of the GNU Affero General Public License along with
* this program; if not, see http://www.gnu.org/licenses or write to the Free
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
* 02110-1301 USA.
*
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
*
* The interactive user interfaces in modified source and object code versions
* of this program must display Appropriate Legal Notices, as required under
* Section 5 of the GNU Affero General Public License version 3.
*
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
* these Appropriate Legal Notices must retain the display of the "Powered by
* SugarCRM" logo. If the display of the logo is not reasonably feasible for
* technical reasons, the Appropriate Legal Notices must display the words
* "Powered by SugarCRM".
********************************************************************************/
$module_name = '<module_name>';
$listViewDefs[$module_name] = array(
'NAME' => array(
'width' => '20%',
'label' => 'LBL_NAME',
'link' => true,
'orderBy' => 'last_name',
'default' => true,
'related_fields' => array('first_name', 'last_name', 'salutation'),
),
'TITLE' => array(
'width' => '15%',
'label' => 'LBL_TITLE',
'default' => true),
'PHONE_WORK' => array(
'width' => '15%',
'label' => 'LBL_OFFICE_PHONE',
'default' => true),
'EMAIL1' => array(
'width' => '15%',
'label' => 'LBL_EMAIL_ADDRESS',
'sortable' => false,
'link' => true,
'customCode' => '{$EMAIL1_LINK}{$EMAIL1}</a>',
'default' => true
),
'DO_NOT_CALL' => array(
'width' => '10',
'label' => 'LBL_DO_NOT_CALL'),
'PHONE_HOME' => array(
'width' => '10',
'label' => 'LBL_HOME_PHONE'),
'PHONE_MOBILE' => array(
'width' => '10',
'label' => 'LBL_MOBILE_PHONE'),
'PHONE_OTHER' => array(
'width' => '10',
'label' => 'LBL_WORK_PHONE'),
'PHONE_FAX' => array(
'width' => '10',
'label' => 'LBL_FAX_PHONE'),
'ADDRESS_STREET' => array(
'width' => '10',
'label' => 'LBL_PRIMARY_ADDRESS_STREET'),
'ADDRESS_CITY' => array(
'width' => '10',
'label' => 'LBL_PRIMARY_ADDRESS_CITY'),
'ADDRESS_STATE' => array(
'width' => '10',
'label' => 'LBL_PRIMARY_ADDRESS_STATE'),
'ADDRESS_POSTALCODE' => array(
'width' => '10',
'label' => 'LBL_PRIMARY_ADDRESS_POSTALCODE'),
'DATE_ENTERED' => array(
'width' => '10',
'label' => 'LBL_DATE_ENTERED'),
'CREATED_BY_NAME' => array(
'width' => '10',
'label' => 'LBL_CREATED'),
);
?>

View File

@@ -0,0 +1,51 @@
<?php
/*********************************************************************************
* SugarCRM is a customer relationship management program developed by
* SugarCRM, Inc. Copyright (C) 2004-2010 SugarCRM Inc.
*
* This program is free software; you can redistribute it and/or modify it under
* the terms of the GNU Affero General Public License version 3 as published by the
* Free Software Foundation with the addition of the following permission added
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
*
* This program is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
* FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more
* details.
*
* You should have received a copy of the GNU Affero General Public License along with
* this program; if not, see http://www.gnu.org/licenses or write to the Free
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
* 02110-1301 USA.
*
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
*
* The interactive user interfaces in modified source and object code versions
* of this program must display Appropriate Legal Notices, as required under
* Section 5 of the GNU Affero General Public License version 3.
*
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
* these Appropriate Legal Notices must retain the display of the "Powered by
* SugarCRM" logo. If the display of the logo is not reasonably feasible for
* technical reasons, the Appropriate Legal Notices must display the words
* "Powered by SugarCRM".
********************************************************************************/
/*
* Created on July 12, 2007
*
* To change the template for this generated file go to
* Window - Preferences - PHPeclipse - PHP - Code Templates
*/
$module_name = '<module_name>';
$metafiles[$module_name] = array(
'detailviewdefs' => 'modules/'.$module_name.'/metadata/detailviewdefs.php',
'editviewdefs' => 'modules/'. $module_name. '/metadata/editviewdefs.php',
'listviewdefs' => 'modules/'. $module_name. '/metadata/listviewdefs.php',
'searchdefs' => 'modules/'. $module_name. '/metadata/searchdefs.php',
'popupdefs' => 'modules/'. $module_name. '/metadata/popupdefs.php',
'searchfields' => 'modules/'. $module_name. '/metadata/SearchFields.php',
);
?>

View File

@@ -0,0 +1,50 @@
<?php
if(!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point');
/*********************************************************************************
* SugarCRM is a customer relationship management program developed by
* SugarCRM, Inc. Copyright (C) 2004-2010 SugarCRM Inc.
*
* This program is free software; you can redistribute it and/or modify it under
* the terms of the GNU Affero General Public License version 3 as published by the
* Free Software Foundation with the addition of the following permission added
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
*
* This program is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
* FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more
* details.
*
* You should have received a copy of the GNU Affero General Public License along with
* this program; if not, see http://www.gnu.org/licenses or write to the Free
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
* 02110-1301 USA.
*
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
*
* The interactive user interfaces in modified source and object code versions
* of this program must display Appropriate Legal Notices, as required under
* Section 5 of the GNU Affero General Public License version 3.
*
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
* these Appropriate Legal Notices must retain the display of the "Powered by
* SugarCRM" logo. If the display of the logo is not reasonably feasible for
* technical reasons, the Appropriate Legal Notices must display the words
* "Powered by SugarCRM".
********************************************************************************/
$module_name = '<module_name>';
$object_name = '<object_name>';
$_module_name = '<_module_name>';
$popupMeta = array('moduleMain' => $module_name,
'varName' => $object_name,
'orderBy' => $_module_name . '.first_name, '. $_module_name . '.last_name',
'whereClauses' =>
array('first_name' => $_module_name . '.first_name',
'last_name' => $_module_name . '.last_name',
),
'searchInputs' =>
array('first_name', 'last_name'),
);
?>

View File

@@ -0,0 +1,83 @@
<?php
/*********************************************************************************
* SugarCRM is a customer relationship management program developed by
* SugarCRM, Inc. Copyright (C) 2004-2010 SugarCRM Inc.
*
* This program is free software; you can redistribute it and/or modify it under
* the terms of the GNU Affero General Public License version 3 as published by the
* Free Software Foundation with the addition of the following permission added
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
*
* This program is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
* FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more
* details.
*
* You should have received a copy of the GNU Affero General Public License along with
* this program; if not, see http://www.gnu.org/licenses or write to the Free
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
* 02110-1301 USA.
*
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
*
* The interactive user interfaces in modified source and object code versions
* of this program must display Appropriate Legal Notices, as required under
* Section 5 of the GNU Affero General Public License version 3.
*
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
* these Appropriate Legal Notices must retain the display of the "Powered by
* SugarCRM" logo. If the display of the logo is not reasonably feasible for
* technical reasons, the Appropriate Legal Notices must display the words
* "Powered by SugarCRM".
********************************************************************************/
$module_name = '<module_name>';
$viewdefs[$module_name]['QuickCreate'] = array(
'templateMeta' => array('maxColumns' => '2',
'widths' => array(
array('label' => '10', 'field' => '30'),
array('label' => '10', 'field' => '30'),
),
),
'panels' =>array (
'lbl_contact_information' =>
array (
array (
array (
'name' => 'first_name',
'customCode' => '{html_options name="salutation" options=$fields.salutation.options selected=$fields.salutation.value}&nbsp;<input name="first_name" size="25" maxlength="25" type="text" value="{$fields.first_name.value}">',
),
'assigned_user_name',
),
array (
array('name'=>'last_name', 'displayParams'=>array('required'=>true)),
),
array (
'title',
'phone_work',
),
array (
'department',
'phone_mobile',
),
array (
'phone_fax',
'',
),
),
'lbl_email_addresses'=>array(
array('email1')
),
)
);
?>

View File

@@ -0,0 +1,62 @@
<?php
/*********************************************************************************
* SugarCRM is a customer relationship management program developed by
* SugarCRM, Inc. Copyright (C) 2004-2010 SugarCRM Inc.
*
* This program is free software; you can redistribute it and/or modify it under
* the terms of the GNU Affero General Public License version 3 as published by the
* Free Software Foundation with the addition of the following permission added
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
*
* This program is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
* FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more
* details.
*
* You should have received a copy of the GNU Affero General Public License along with
* this program; if not, see http://www.gnu.org/licenses or write to the Free
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
* 02110-1301 USA.
*
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
*
* The interactive user interfaces in modified source and object code versions
* of this program must display Appropriate Legal Notices, as required under
* Section 5 of the GNU Affero General Public License version 3.
*
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
* these Appropriate Legal Notices must retain the display of the "Powered by
* SugarCRM" logo. If the display of the logo is not reasonably feasible for
* technical reasons, the Appropriate Legal Notices must display the words
* "Powered by SugarCRM".
********************************************************************************/
/*
* Created on May 29, 2007
*
* To change the template for this generated file go to
* Window - Preferences - PHPeclipse - PHP - Code Templates
*/
$module_name = '<module_name>';
$searchdefs[$module_name] = array(
'templateMeta' => array('maxColumns' => '3',
'widths' => array('label' => '10', 'field' => '30'),
),
'layout' => array(
'basic_search' => array(
array('name'=>'search_name','label' =>'LBL_NAME', 'type' => 'name'),
array('name'=>'current_user_only', 'label'=>'LBL_CURRENT_USER_FILTER', 'type'=>'bool'),
),
'advanced_search' => array(
'first_name',
'last_name',
'address_city',
'created_by_name',
'do_not_call',
),
),
);
?>

View File

@@ -0,0 +1,90 @@
<?php
if(!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point');
/*********************************************************************************
* SugarCRM is a customer relationship management program developed by
* SugarCRM, Inc. Copyright (C) 2004-2010 SugarCRM Inc.
*
* This program is free software; you can redistribute it and/or modify it under
* the terms of the GNU Affero General Public License version 3 as published by the
* Free Software Foundation with the addition of the following permission added
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
*
* This program is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
* FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more
* details.
*
* You should have received a copy of the GNU Affero General Public License along with
* this program; if not, see http://www.gnu.org/licenses or write to the Free
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
* 02110-1301 USA.
*
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
*
* The interactive user interfaces in modified source and object code versions
* of this program must display Appropriate Legal Notices, as required under
* Section 5 of the GNU Affero General Public License version 3.
*
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
* these Appropriate Legal Notices must retain the display of the "Powered by
* SugarCRM" logo. If the display of the logo is not reasonably feasible for
* technical reasons, the Appropriate Legal Notices must display the words
* "Powered by SugarCRM".
********************************************************************************/
$subpanel_layout = array(
'top_buttons' => array(
array('widget_class' => 'SubPanelTopCreateButton'),
array('widget_class' => 'SubPanelTopSelectButton', 'popup_module' => 'People'),
),
'where' => '',
'list_fields' => array(
'first_name'=>array(
'name'=>'first_name',
'usage' => 'query_only',
),
'last_name'=>array(
'name'=>'last_name',
'usage' => 'query_only',
),
'name'=>array(
'name'=>'name',
'vname' => 'LBL_LIST_NAME',
'sort_by' => 'last_name',
'sort_order' => 'asc',
'widget_class' => 'SubPanelDetailViewLink',
'module' => 'Contacts',
'width' => '40%',
),
'email1'=>array(
'name'=>'email1',
'vname' => 'LBL_LIST_EMAIL',
'widget_class' => 'SubPanelEmailLink',
'width' => '35%',
),
'phone_work'=>array (
'name'=>'phone_work',
'vname' => 'LBL_LIST_PHONE',
'width' => '15%',
),
'edit_button'=>array(
'widget_class' => 'SubPanelEditButton',
'module' => 'Contacts',
'width' => '5%',
),
'remove_button'=>array(
'widget_class' => 'SubPanelRemoveButton',
'module' => 'Contacts',
'width' => '5%',
),
),
);
?>

View File

@@ -0,0 +1,418 @@
<?php
/*********************************************************************************
* SugarCRM is a customer relationship management program developed by
* SugarCRM, Inc. Copyright (C) 2004-2010 SugarCRM Inc.
*
* This program is free software; you can redistribute it and/or modify it under
* the terms of the GNU Affero General Public License version 3 as published by the
* Free Software Foundation with the addition of the following permission added
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
*
* This program is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
* FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more
* details.
*
* You should have received a copy of the GNU Affero General Public License along with
* this program; if not, see http://www.gnu.org/licenses or write to the Free
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
* 02110-1301 USA.
*
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
*
* The interactive user interfaces in modified source and object code versions
* of this program must display Appropriate Legal Notices, as required under
* Section 5 of the GNU Affero General Public License version 3.
*
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
* these Appropriate Legal Notices must retain the display of the "Powered by
* SugarCRM" logo. If the display of the logo is not reasonably feasible for
* technical reasons, the Appropriate Legal Notices must display the words
* "Powered by SugarCRM".
********************************************************************************/
$vardefs =array(
'fields'=> array(
'salutation' =>
array (
'name' => 'salutation',
'vname' => 'LBL_SALUTATION',
'type' => 'enum',
'options' => 'salutation_dom',
'massupdate' => false,
'len' => '5',
'comment' => 'Contact salutation (e.g., Mr, Ms)'
),
'first_name' =>
array (
'name' => 'first_name',
'vname' => 'LBL_FIRST_NAME',
'type' => 'varchar',
'len' => '100',
'unified_search' => true,
'comment' => 'First name of the contact',
'merge_filter' => 'selected',
),
'last_name' =>
array (
'name' => 'last_name',
'vname' => 'LBL_LAST_NAME',
'type' => 'varchar',
'len' => '100',
'unified_search' => true,
'comment' => 'Last name of the contact',
'merge_filter' => 'selected',
'required'=>true,
'importable' => 'required',
),
'name' =>
array (
'name' => 'name',
'rname' => 'name',
'vname' => 'LBL_NAME',
'type' => 'name',
'fields' => array('first_name', 'last_name'),
'sort_on' => 'last_name',
'source' => 'non-db',
'group'=>'last_name',
'len' => '255',
'db_concat_fields'=> array(0=>'first_name', 1=>'last_name'),
'importable' => 'false',
),
'full_name' =>
array (
'name' => 'full_name',
'rname' => 'full_name',
'vname' => 'LBL_NAME',
'type' => 'fullname',
'fields' => array('first_name', 'last_name'),
'sort_on' => 'last_name',
'source' => 'non-db',
'group'=>'last_name',
'len' => '510',
'db_concat_fields'=> array(0=>'first_name', 1=>'last_name'),
),
'title' =>
array (
'name' => 'title',
'vname' => 'LBL_TITLE',
'type' => 'varchar',
'len' => '100',
'comment' => 'The title of the contact'
),
'department' =>
array (
'name' => 'department',
'vname' => 'LBL_DEPARTMENT',
'type' => 'varchar',
'len' => '255',
'comment' => 'The department of the contact',
'merge_filter' => 'enabled',
),
'do_not_call' =>
array (
'name' => 'do_not_call',
'vname' => 'LBL_DO_NOT_CALL',
'type' => 'bool',
'default' => '0',
'audited'=>true,
'comment' => 'An indicator of whether contact can be called'
),
'phone_home' =>
array (
'name' => 'phone_home',
'vname' => 'LBL_HOME_PHONE',
'type' => 'phone',
'dbType' => 'varchar',
'len' => '25',
'unified_search' => true,
'comment' => 'Home phone number of the contact',
'merge_filter' => 'enabled',
),
'phone_mobile' =>
array (
'name' => 'phone_mobile',
'vname' => 'LBL_MOBILE_PHONE',
'type' => 'phone',
'dbType' => 'varchar',
'len' => '25',
'unified_search' => true,
'comment' => 'Mobile phone number of the contact',
'merge_filter' => 'enabled',
),
'phone_work' =>
array (
'name' => 'phone_work',
'vname' => 'LBL_OFFICE_PHONE',
'type' => 'phone',
'dbType' => 'varchar',
'len' => '25',
'audited'=>true,
'unified_search' => true,
'comment' => 'Work phone number of the contact',
'merge_filter' => 'enabled',
),
'phone_other' =>
array (
'name' => 'phone_other',
'vname' => 'LBL_OTHER_PHONE',
'type' => 'phone',
'dbType' => 'varchar',
'len' => '25',
'unified_search' => true,
'comment' => 'Other phone number for the contact',
'merge_filter' => 'enabled',
),
'phone_fax' =>
array (
'name' => 'phone_fax',
'vname' => 'LBL_FAX_PHONE',
'type' => 'phone',
'dbType' => 'varchar',
'len' => '25',
'unified_search' => true,
'comment' => 'Contact fax number',
'merge_filter' => 'enabled',
),
'email1' =>
array(
'name' => 'email1',
'vname' => 'LBL_EMAIL_ADDRESS',
'type' => 'varchar',
'function' => array(
'name' => 'getEmailAddressWidget',
'returns' => 'html'),
'source' => 'non-db',
'group'=>'email1',
'merge_filter' => 'enabled',
'studio' => array('editField' => true),
),
'email2' =>
array(
'name' => 'email2',
'vname' => 'LBL_OTHER_EMAIL_ADDRESS',
'type' => 'varchar',
'function' => array(
'name' => 'getEmailAddressWidget',
'returns' => 'html'),
'source' => 'non-db',
'group'=>'email2',
'merge_filter' => 'enabled',
'studio' => 'false',
),
'invalid_email' =>
array(
'name' => 'invalid_email',
'vname' => 'LBL_INVALID_EMAIL',
'source' => 'non-db',
'type' => 'bool',
'massupdate' => false,
'studio' => 'false',
),
'email_opt_out' =>
array(
'name' => 'email_opt_out',
'vname' => 'LBL_EMAIL_OPT_OUT',
'source' => 'non-db',
'type' => 'bool',
'massupdate' => false,
'studio'=>'false',
),
'primary_address_street' =>
array (
'name' => 'primary_address_street',
'vname' => 'LBL_PRIMARY_ADDRESS_STREET',
'type' => 'varchar',
'len' => '150',
'group'=>'primary_address',
'comment' => 'Street address for primary address',
'merge_filter' => 'enabled',
),
'primary_address_street_2' =>
array (
'name' => 'primary_address_street_2',
'vname' => 'LBL_PRIMARY_ADDRESS_STREET_2',
'type' => 'varchar',
'len' => '150',
'source' => 'non-db',
),
'primary_address_street_3' =>
array (
'name' => 'primary_address_street_3',
'vname' => 'LBL_PRIMARY_ADDRESS_STREET_3',
'type' => 'varchar',
'len' => '150',
'source' => 'non-db',
),
'primary_address_city' =>
array (
'name' => 'primary_address_city',
'vname' => 'LBL_PRIMARY_ADDRESS_CITY',
'type' => 'varchar',
'len' => '100',
'group'=>'primary_address',
'comment' => 'City for primary address',
'merge_filter' => 'enabled',
),
'primary_address_state' =>
array (
'name' => 'primary_address_state',
'vname' => 'LBL_PRIMARY_ADDRESS_STATE',
'type' => 'varchar',
'len' => '100',
'group'=>'primary_address',
'comment' => 'State for primary address',
'merge_filter' => 'enabled',
),
'primary_address_postalcode' =>
array (
'name' => 'primary_address_postalcode',
'vname' => 'LBL_PRIMARY_ADDRESS_POSTALCODE',
'type' => 'varchar',
'len' => '20',
'group'=>'primary_address',
'comment' => 'Postal code for primary address',
'merge_filter' => 'enabled',
),
'primary_address_country' =>
array (
'name' => 'primary_address_country',
'vname' => 'LBL_PRIMARY_ADDRESS_COUNTRY',
'type' => 'varchar',
'group'=>'primary_address',
'comment' => 'Country for primary address',
'merge_filter' => 'enabled',
),
'alt_address_street' =>
array (
'name' => 'alt_address_street',
'vname' => 'LBL_ALT_ADDRESS_STREET',
'type' => 'varchar',
'len' => '150',
'group'=>'alt_address',
'comment' => 'Street address for alternate address',
'merge_filter' => 'enabled',
),
'alt_address_street_2' =>
array (
'name' => 'alt_address_street_2',
'vname' => 'LBL_ALT_ADDRESS_STREET_2',
'type' => 'varchar',
'len' => '150',
'source' => 'non-db',
),
'alt_address_street_3' =>
array (
'name' => 'alt_address_street_3',
'vname' => 'LBL_ALT_ADDRESS_STREET_3',
'type' => 'varchar',
'len' => '150',
'source' => 'non-db',
),
'alt_address_city' =>
array (
'name' => 'alt_address_city',
'vname' => 'LBL_ALT_ADDRESS_CITY',
'type' => 'varchar',
'len' => '100',
'group'=>'alt_address',
'comment' => 'City for alternate address',
'merge_filter' => 'enabled',
),
'alt_address_state' =>
array (
'name' => 'alt_address_state',
'vname' => 'LBL_ALT_ADDRESS_STATE',
'type' => 'varchar',
'len' => '100',
'group'=>'alt_address',
'comment' => 'State for alternate address',
'merge_filter' => 'enabled',
),
'alt_address_postalcode' =>
array (
'name' => 'alt_address_postalcode',
'vname' => 'LBL_ALT_ADDRESS_POSTALCODE',
'type' => 'varchar',
'len' => '20',
'group'=>'alt_address',
'comment' => 'Postal code for alternate address',
'merge_filter' => 'enabled',
),
'alt_address_country' =>
array (
'name' => 'alt_address_country',
'vname' => 'LBL_ALT_ADDRESS_COUNTRY',
'type' => 'varchar',
'group'=>'alt_address',
'comment' => 'Country for alternate address',
'merge_filter' => 'enabled',
),
'assistant' =>
array (
'name' => 'assistant',
'vname' => 'LBL_ASSISTANT',
'type' => 'varchar',
'len' => '75',
'unified_search' => true,
'comment' => 'Name of the assistant of the contact',
'merge_filter' => 'enabled',
),
'assistant_phone' =>
array (
'name' => 'assistant_phone',
'vname' => 'LBL_ASSISTANT_PHONE',
'type' => 'phone',
'dbType' => 'varchar',
'len' => '25',
'group'=>'assistant',
'unified_search' => true,
'comment' => 'Phone number of the assistant of the contact',
'merge_filter' => 'enabled',
),
'email_addresses_primary' =>
array (
'name' => 'email_addresses_primary',
'type' => 'link',
'relationship' => strtolower($object_name).'_email_addresses_primary',
'source' => 'non-db',
'vname' => 'LBL_EMAIL_ADDRESS_PRIMARY',
'duplicate_merge' => 'disabled',
),
'email_addresses' =>
array (
'name' => 'email_addresses',
'type' => 'link',
'relationship' => strtolower($object_name).'_email_addresses',
'source' => 'non-db',
'vname' => 'LBL_EMAIL_ADDRESSES',
'reportable'=>false,
'unified_search' => true,
'rel_fields' => array('primary_address' => array('type'=>'bool')),
),
),
'relationships'=>array(
strtolower($module).'_email_addresses' =>
array(
'lhs_module'=> $module, 'lhs_table'=> strtolower($module), 'lhs_key' => 'id',
'rhs_module'=> 'EmailAddresses', 'rhs_table'=> 'email_addresses', 'rhs_key' => 'id',
'relationship_type'=>'many-to-many',
'join_table'=> 'email_addr_bean_rel', 'join_key_lhs'=>'bean_id', 'join_key_rhs'=>'email_address_id',
'relationship_role_column'=>'bean_module',
'relationship_role_column_value'=>$module
),
strtolower($module).'_email_addresses_primary' =>
array('lhs_module'=> $module, 'lhs_table'=> strtolower($module), 'lhs_key' => 'id',
'rhs_module'=> 'EmailAddresses', 'rhs_table'=> 'email_addresses', 'rhs_key' => 'id',
'relationship_type'=>'many-to-many',
'join_table'=> 'email_addr_bean_rel', 'join_key_lhs'=>'bean_id', 'join_key_rhs'=>'email_address_id',
'relationship_role_column'=>'primary_address',
'relationship_role_column_value'=>'1'
),
)
);
?>