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
RewriteEngine on | |
# BEGIN SUGARCRM RESTRICTIONS | |
RedirectMatch 403 (?i).*\.log$ | |
RedirectMatch 403 (?i)/+not_imported_.*\.txt | |
RedirectMatch 403 (?i)/+(soap|cache|xtemplate|data|examples|include|log4php|metadata|modules)/+.*\.(php|tpl) | |
RedirectMatch 403 (?i)/+emailmandelivery\.php | |
RedirectMatch 403 (?i)/+upload/ | |
RedirectMatch 403 (?i)/+custom/+blowfish | |
RedirectMatch 403 (?i)/+cache/+diagnostic |
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
/** | |
File Location | |
/custom/modules/<YourModule>/clients/base/layouts/subpanels/subpanels.js | |
*/ | |
({ | |
extendsFrom: 'SubpanelsLayout', | |
events: { |
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
############################################### | |
# | |
# Install ORO CRM | |
# | |
############################################### | |
cd /var/www/html/OroCrm # go to your install OroCrm folder |
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
TRUNCATE TABLE `activities`; | |
TRUNCATE TABLE `calls`; | |
TRUNCATE TABLE `calls_contacts`; | |
TRUNCATE TABLE `meetings`; | |
TRUNCATE TABLE `meetings_contacts`; | |
TRUNCATE TABLE `tasks`; | |
TRUNCATE TABLE `notes`; |
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
// MySQL | |
update users set user_hash = md5('jim') where user_name = 'jim'; | |
// MSSQL | |
update users set user_hash = '5e027396789a18c37aeda616e3d7991b' where user_name = 'jim'; |
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
Example usage common function defined in sidecar: | |
------------------- | |
// "custom-record": {"controller": | |
({ | |
// Record View (base) | |
extendsFrom: 'RecordView', | |
initialize: function (options) { | |
//this.plugins = _.union(this.plugins, ['MyAmazingFunctionFour']); // Call function through plugins | |
//app.MyAmazingFunction() // Call function through app | |
//SUGAR.util.MyAmazingFunctionTwo(); // Call function through SUGAR.util |
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
<style> | |
/* svg fix for leaflet on sugar 7 against styles from styleguide/assets/css/nvd3.css */ | |
svg { | |
width: auto; | |
height: auto; | |
max-height: 1900px; | |
max-width: 1900px; | |
} | |
</style> |
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
if($.isEmptyObject(google)) { | |
$.getScript('https://www.google.com/jsapi', function () { | |
google.load("maps", "3", {'other_params' : 'sensor=true' }); | |
}); | |
} |
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
require_once('include/utils.php'); | |
$newID = create_guid(); |
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
global $db; | |
$db = DBManagerFactory::getInstance(); | |
$sql = "SELECT your_qurey_here"; | |
$res = $db->query($sql); | |
$row = $db->fetchByAssoc($res); | |
$cnt = $db->getRowCount($res); |