Skip to content

Instantly share code, notes, and snippets.

Avatar

Betobaz betobaz

  • Betobaz
  • Veracruz, Mexico
View GitHub Profile
View custom__clients__base__layouts__filter__filter.js
({
extendsFrom: "FilterLayout",
/**
* Applies filter on current contexts
* @param {String} query search string
* @param {Object} dynamicFilterDef(optional)
*/
applyFilter: function(query, dynamicFilterDef) {
// TODO: getRelevantContextList needs to be refactored to handle filterpanels in drawer layouts,
@betobaz
betobaz / manifest.php
Created Jan 26, 2017
SugarCRM: Create relate field by manifest
View manifest.php
<?php
/*********************************************************************************
* By installing or using this file, you are confirming on behalf of the entity
* subscribed to the SugarCRM Inc. product ("Company") that Company is bound by
* the SugarCRM Inc. Master Subscription Agreement (“MSA”), which is viewable at:
* http://www.sugarcrm.com/master-subscription-agreement
*
* If Company is not bound by the MSA, then by installing or using this file
* you are agreeing unconditionally that Company will be bound by the MSA and
* certifying that you have authority to bind Company accordingly.
View custom__Extension__modules__Meetings__Ext__Dependencies__readonly_fields_logic.php
<?php
// Documentation.- http://support.sugarcrm.com/Documentation/Sugar_Developer/Sugar_Developer_Guide_7.7/Architecture/Sugar_Logic/Dependency_Actions/
$dependencies['Meetings']['readonly_fields'] = array(
'hooks' => array("edit"), // values : "edit", "view", "save" and "all"
'trigger' => 'equal($status,"Held")', //Optional, the trigger for the dependency. Defaults to 'true'.
'triggerFields' => array('status'), // The list of fields to watch for change events. When changed, the trigger expressions will be recalculated.
'onload' => true, // Whether or not to trigger the dependencies when the page is loaded.
//Actions is a list of actions to fire when the trigger is true
// You could list multiple fields here each in their own array under 'actions'
'actions' => array(
@betobaz
betobaz / repair.php
Last active Oct 1, 2016
SugarCRM: 7.7.X: Quick Repair CLI
View repair.php
<?php
if(!defined('sugarEntry'))define('sugarEntry', true);
/*
* Your installation or use of this SugarCRM file is subject to the applicable
* terms available at
* http://support.sugarcrm.com/06_Customer_Center/10_Master_Subscription_Agreements/.
* If you do not agree to all of the applicable terms or do not have the
* authority to bind the entity as an authorized representative, then do not
* install or use this SugarCRM file.
*
@betobaz
betobaz / dashlet-test.js
Last active Aug 2, 2016
SugarCRM:: Sidecar unit test
View dashlet-test.js
ddescribe("Dashlet dashlet", function () {
var viewName = 'dashlet',
view,
layout,
context,
layoutName = 'record',
moduleName = 'Opportunities',
model;
beforeEach(function () {
View custom__modules__Quotes__sugarpdf__sugarpdf.pdfmanager.php
<?php
if(!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point');
/*
* Your installation or use of this SugarCRM file is subject to the applicable
* terms available at
* http://support.sugarcrm.com/06_Customer_Center/10_Master_Subscription_Agreements/.
* If you do not agree to all of the applicable terms or do not have the
* authority to bind the entity as an authorized representative, then do not
* install or use this SugarCRM file.
*
@betobaz
betobaz / custom__clients__base__views__supanel-list__subpanel-list.js
Created Oct 15, 2015
SugarCRM:Sidecar: Change Edit list max per page in subpanel any module
View custom__clients__base__views__supanel-list__subpanel-list.js
({
extendsFrom: 'SubpanelListView',
initialize: function(options) {
// `dataViewName` corresponds to the list of fields the API should retrieve.
this.dataViewName = options.name || 'subpanel-list';
this._super("initialize", [options]);
var limit = this.context.get('limit') || app.config.maxSubpanelResult;
// Setup max limit on collection's fetch options for this subpanel's context
@betobaz
betobaz / custom__modules__Contacts__clients__base__fields__link-action__link-action.js
Created Oct 12, 2015
SugarCRM:Sidecar:Modify list selection for "Link Existing Record"
View custom__modules__Contacts__clients__base__fields__link-action__link-action.js
@betobaz
betobaz / custom__include__language__es_LA.lang.php
Last active Aug 4, 2016
SugarCRM: Sidecar: Multi select dependent from another multi select dependent fields
View custom__include__language__es_LA.lang.php
<?php
$app_list_strings['promocion_region_list']=array (
'Michoacana' => 'Michoacana',
'Jaliciense' => 'Jaliciense',
'Sinaloense' => 'Sinaloense',
'Sonorense' => 'Sonorense',
);
$app_list_strings['seg_geo_com_Michoacana_list']=array (