]> CyberLeo.Net >> Repos - Github/sugarcrm.git/blob - include/Smarty/plugins/function.sugar_connector_display.php
Release 6.5.0
[Github/sugarcrm.git] / include / Smarty / plugins / function.sugar_connector_display.php
1 <?php
2
3 /*
4
5 Modification information for LGPL compliance
6
7 r56990 - 2010-06-16 13:05:36 -0700 (Wed, 16 Jun 2010) - kjing - snapshot "Mango" svn branch to a new one for GitHub sync
8
9 r56989 - 2010-06-16 13:01:33 -0700 (Wed, 16 Jun 2010) - kjing - defunt "Mango" svn dev branch before github cutover
10
11 r55980 - 2010-04-19 13:31:28 -0700 (Mon, 19 Apr 2010) - kjing - create Mango (6.1) based on windex
12
13 r51719 - 2009-10-22 10:18:00 -0700 (Thu, 22 Oct 2009) - mitani - Converted to Build 3  tags and updated the build system 
14
15 r51634 - 2009-10-19 13:32:22 -0700 (Mon, 19 Oct 2009) - mitani - Windex is the branch for Sugar Sales 1.0 development
16
17 r50375 - 2009-08-24 18:07:43 -0700 (Mon, 24 Aug 2009) - dwong - branch kobe2 from tokyo r50372
18
19 r44079 - 2009-02-12 22:27:15 -0800 (Thu, 12 Feb 2009) - clee - Merged Code from Solana to Tokyo and Trunk branches
20 Modified:
21 include/connectors/component.php
22 include/Smarty/plugins/function.sugar_connector_display.php
23 modules/Connectors/Connector.js
24 modules/Connectors/connectors/filters/ext/rest/zoominfocompany/zoominfocompany.php
25 modules/Connectors/connectors/filters/ext/rest/zoominfoperson/zoominfoperson.php
26 modules/Connectors/connectors/filters/ext/soap/hoovers/hoovers.php
27 modules/Connectors/connectors/filters/ext/jigsaw/jigsaw.php
28 modules/Connectors/connectors/sources/ext/rest/zoominfoperson/vardefs.php
29 modules/Connectors/connectors/sources/ext/rest/zoominfoperson/zoominfoperson.php
30 modules/Connectors/connectors/sources/ext/soap/hoovers/vardefs.php
31 modules/Connectors/controller.php
32 modules/Connectors/language/en_us.lang.php
33 modules/Connectors/views/view.mappingproperties.php
34 modules/Connectors/views/view.retrievesource.php
35 Added:
36 include/Connectors/connectors/filters/ext/rest/zoominfocompany/zoominfocompany.php
37 include/Connectors/connectors/filters/ext/rest/zoominfoperson/zoominfoperson.php
38 include/Connectors/connectors/filters/ext/soap/hoovers/hoovers.php
39 include/Connectors/connectors/filters/ext/soap/jigsaw/jigsaw.php
40 modules/Connectors/connectors/filters/ext/rest/zoominfocompany/listviewdefs.php
41 modules/Connectors/connectors/filters/ext/rest/zoominfoperson/listviewdefs.php
42 modules/Connectors/connectors/filters/ext/soap/hoovers/listviewdefs.php
43 modules/Connectors/connectors/filters/ext/soap/jigsaw/listviewdefs.php
44
45 r42807 - 2008-12-29 11:16:59 -0800 (Mon, 29 Dec 2008) - dwong - Branch from trunk/sugarcrm r42806 to branches/tokyo/sugarcrm
46
47 r42645 - 2008-12-18 13:41:08 -0800 (Thu, 18 Dec 2008) - awu - merging maint_5_2_0 rev41336:HEAD to trunk
48
49 r42562 - 2008-12-15 17:54:57 -0800 (Mon, 15 Dec 2008) - dwong - create branches/maint_5_2_0 from branches/milan r42559
50
51 r42508 - 2008-12-11 14:59:33 -0800 (Thu, 11 Dec 2008) - Collin Lee - Updated license information  and emoved Wrapper components (we decided to not have these components awhile back).
52
53 r41724 - 2008-11-13 08:55:42 -0800 (Thu, 13 Nov 2008) - Collin Lee - Made changes to rename DataSource module and components to Connectors.
54
55
56 */
57
58
59 if(!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point');
60 /*********************************************************************************
61  * SugarCRM Community Edition is a customer relationship management program developed by
62  * SugarCRM, Inc. Copyright (C) 2004-2012 SugarCRM Inc.
63  * 
64  * This program is free software; you can redistribute it and/or modify it under
65  * the terms of the GNU Affero General Public License version 3 as published by the
66  * Free Software Foundation with the addition of the following permission added
67  * to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
68  * IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
69  * OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
70  * 
71  * This program is distributed in the hope that it will be useful, but WITHOUT
72  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
73  * FOR A PARTICULAR PURPOSE.  See the GNU Affero General Public License for more
74  * details.
75  * 
76  * You should have received a copy of the GNU Affero General Public License along with
77  * this program; if not, see http://www.gnu.org/licenses or write to the Free
78  * Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
79  * 02110-1301 USA.
80  * 
81  * You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
82  * SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
83  * 
84  * The interactive user interfaces in modified source and object code versions
85  * of this program must display Appropriate Legal Notices, as required under
86  * Section 5 of the GNU Affero General Public License version 3.
87  * 
88  * In accordance with Section 7(b) of the GNU Affero General Public License version 3,
89  * these Appropriate Legal Notices must retain the display of the "Powered by
90  * SugarCRM" logo. If the display of the logo is not reasonably feasible for
91  * technical reasons, the Appropriate Legal Notices must display the words
92  * "Powered by SugarCRM".
93  ********************************************************************************/
94
95
96 function smarty_function_sugar_connector_display($params, &$smarty)
97 {
98     $bean = $params['bean'];
99     $field = $params['field'];
100     $type = $bean->field_name_map[$field]['type'];
101     if($type == 'text') {
102        echo strlen($bean->$field) > 50 ? substr($bean->$field, 0, 47) . '...' : $bean->field;
103     } else if($type == 'link') {
104        echo "<a href='{$bean->$field}' target='_blank'>{$bean->$field}</a>"; 
105     } else {
106        echo $bean->$field;
107     }
108 }
109
110 /* vim: set expandtab: */
111
112 ?>