Custom components stopped working after v13.0 upgrade

Dear club members,

After upgrading SugarCRM from v12.0.0 to v13.0.0, our custom components have stopped working.

For instance, we use custom-route.js to have a pop-up window on the Contact module, it's showing normally on our dev environment (it has v12.0.0) but is not working on SugarCRM v13 (prod one).  

I don't see anything on the browser console related to it.

The code is:

-> sugarcrm/custom/javascript/custom-routes.js

Fullscreen
1
2
3
4
5
6
7
8
9
10
(function(app) {
app.events.on('router:init', function() {
app.router.route('custom/contact/import', 'open', function() {
app.events.trigger('custom/contact/import:open');
});
app.router.route('custom/contact/import/prospected', 'open', function() {
app.events.trigger('custom/contact/import/prospected:open');
});
});
})(SUGAR.App);
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

-> sugarcrm/custom/Extension/modules/Contacts/Ext/clients/base/menus/header/addContactMenuOptions.php

Fullscreen
1
2
3
4
5
6
7
8
<?php
// Replace Sugar Import Link with Interchange Import App Link
$viewdefs['Contacts']['base']['menu']['header'][4] = array(
'route'=>'#custom/contact/import',
'label' =>'LNK_IMPORT_CONTACTS_INTERCHANGE',
'acl_module'=>'Contacts',
'icon' => 'fa-arrow-circle-o-up',
);
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

-> sugarcrm/custom/clients/base/views/contact-import/

- contact-import.hbs

The Div to display

- contact-import.js

Fullscreen
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
({
_classes: {
hideApp: 'contact-import--hidden',
optionSelected: 'contact-import__search-option--selected'
},
_constants: {
},
_selectors: {
connectionLoader: '.js-contact-import-connection-loading',
contactImportButton: '.js-contact-import-create-contact-btn',
indicator: '.js-contact-import-indicator',
searchOption: '.contact-import__search-option',
searchInput: '#contact-import-search-input',
searchResult: '.js-contact-import-search-result',
searchResults: '.js-contact-import-search-results',
searchLoader: '.js-contact-import-search-loading',
selected: '.contact-import__search-option--selected'
},
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

- contact-import.php

Fullscreen
1
2
3
4
5
<?php
$viewdefs['base']['view']['contact-import'] = array(
'template' => 'contact-import',
);
?>
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

Is there something different between v12 and v13 about Implementing custom components?

  • Hi  ,

    It seems like you're trying to use a component/layout that is no longer valid on v13 (header).

    It has been redesigned on v12.3, but don't worry, we have put together a lot of material to help you code in the new structure.

    Please read this and check the mapping here.

    SugarCRM | Principal Developer Advocate