This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
require_once 'include/Sugarpdf/Sugarpdf.php'; | |
class CustomSugarpdf extends Sugarpdf | |
{ | |
function Footer() { | |
// just need to remove the unwanted hr | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
if(!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point'); | |
class CustomMODULE_NAMEApi extends SugarApi | |
{ | |
public function registerApiRest() { | |
return array( | |
'CasesLinkedTestsEndpoint' => array( | |
'reqType' => 'POST', |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// this file also goes in custom/SUBPANEL_MODULE_NAME/clients/base/views/subpanel-list/ | |
({ | |
extendsFrom: 'SubpanelListView', | |
initialize: function(options) { | |
this._super('initialize', [options]); | |
this.context.on('button:custom_action:click', this.customAction, this); | |
}, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
({ | |
extendsFrom: 'PanelTopView', | |
initialize: function(options) { | |
this._super('initialize', [options]); | |
var newEvents = { | |
'click a[name=custom_button]': 'customAction' | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
global $db; | |
if (($handle = fopen('/var/www/html/crm/custom/ninjacode/nvw-contacts.csv', 'r')) !== FALSE) { | |
while (($data = fgetcsv($handle, 1000, ",")) !== FALSE) { | |
$sql = "UPDATE contacts c | |
INNER JOIN contacts_cstm cc ON cc.id_c = c.id | |
SET c.first_name = '$data[1]', | |
cc.preferred_name_c = '$data[2]', |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// this is used in coremark custom/modules/Accounts/clients/base/views/nearby-stores/nearby-stores.js | |
({ | |
exportData: function() { | |
app.alert.show('massexport_loading', { | |
level: 'process', | |
title: app.lang.getAppString('LBL_LOADING') | |
}); | |
var fields = [ | |
'name', |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* SugarCRM 7 Intelligence Pane Pusher | |
* Make it possible to push dashboards out to users. | |
* | |
* Run this as an entryPoint. | |
* | |
* Here is a really long, ugly link (that probably won't work when | |
* you need it) that describes how to setup an entrypoint. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/* | |
* This example will hide the core notes subpanel on Opportunities detailview. | |
* In this case it is to allow a custom many-to-many relationship to notes | |
* to replace the core relationship. | |
* | |
* You just need to comment out the subpanel in question and the Quick Repair & Rebuild. | |
* | |
* this file is located at custom/modules/Opportunities/clients/base/layouts/subpanels/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
if(!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point'); | |
class ExampleNonAuthApi extends SugarApi | |
{ | |
public function registerApiRest() { | |
return array( | |
'SampleEndpoint' => array( | |
'reqType' => 'POST', |