SugarClub
SugarClub
  • User
  • Site
  • Search
  • User
SugarClub
SugarClub
  • User
  • Site
  • Search
  • User
DevClub
DevClub
Dev Tutorials How to identify customizations to Refactor
  • Dev Blog
  • Answers & Best Practices
  • Developer On-boarding
  • Dev Tutorials
  • Developer Events
  • Event Recaps
  • Members
  • Developer Suggestions
  • Sub-Groups
  • More
  • Cancel
  • New
Click here to join "DevClub" to engage in the conversation with this group and curate your SugarClub experience.
  • +On-Boarding Framework
  • +Customization Guides
  • -UI Redesign Technical Guide
    • +New Component Structure
    • +Component Mapping
    • +Codebase Refactor by Example
    • Expected Behavior
    • How to identify customizations to Refactor
    • Troubleshooting
  • Did you know? Copying related records is a breeze!
  • How to write code for SugarCloud webinar Q&A
  • HOW TO: enforce ACL on Tags
  • Programatically manage Dropdown List
  • Remove custom fields created via package installation
  • Sugar Developer Tools
  • Tutorial:  How to register custom platforms in Sugar instances via Platform extension
  • Adding a google reCAPTCHA in a Web-to-Lead form
  • Sugar Developer Blog Style Guide

How to identify customizations to Refactor

What are we looking for?

This guide will help you identify customizations that could possibly be impacted by the UI/UX Redesign in the overall header and footer contains and layouts.

Header Customizations

Overall header container files

custom/clients/base/layouts/header/header.php
custom/clients/base/layouts/header/header.js
custom/clients/base/layouts/header/*.hbs
Module list files

custom/clients/base/layouts/module-list/module-list.js
custom/clients/base/layouts/module-list/*.hbs
custom/clients/base/views/module-menu/module-menu.js
custom/clients/base/views/module-menu/*.hbs
custom/modules/*/clients/base/views/module-menu/module-menu.js
custom/modules/*/clients/base/views/module-menu/module-menu.php
custom/modules/*/clients/base/views/module-menu/*.hbs

Quicksearch files custom/clients/base/layouts/quicksearch/quicksearch.php
custom/clients/base/layouts/quicksearch/quicksearch.js
custom/clients/base/layouts/quicksearch/quicksearch.hbs
custom/clients/base/views/quicksearch-modulelist/quicksearch-modulelist.js
custom/clients/base/views/quicksearch-modulelist/*.hbs
custom/clients/base/views/quicksearch-taglist/quicksearch-taglist.js
custom/clients/base/views/quicksearch-taglist/*.hbs
custom/clients/base/views/quicksearch-bar/quicksearch-bar.js
custom/clients/base/views/quicksearch-bar/quicksearch-bar.hbs
custom/clients/base/views/quicksearch-tags/quicksearch-tags.js
custom/clients/base/views/quicksearch-tags/quicksearch-tags.hbs
custom/clients/base/views/quicksearch-results/quicksearch-results.js
custom/clients/base/views/quicksearch-results/*.hbs
custom/clients/base/views/quicksearch-button/quicksearch-button.js
custom/clients/base/views/quicksearch-button/quicksearch-button.hbs
Notifications files

custom/clients/base/views/notifications/notifications.php
custom/clients/base/views/notifications/notifications.js
custom/clients/base/views/notifications/*.hbs

Profile dropdown files

custom/clients/base/views/profileactions/profileactions.php
custom/clients/base/views/profileactions/profileactions.js
custom/clients/base/views/profileactions/profileactions.hbs

Quick create files

custom/clients/base/views/quickcreate/quickcreate.js
custom/clients/base/views/quickcreate/quickcreate.hbs

Footer Customizations

Overall footer container files custom/clients/base/layouts/footer/footer.php
custom/clients/base/layouts/footer/footer.hbs
Footer logo side files custom/clients/base/layouts/footer-logos/footer-logos.php
custom/clients/base/layouts/footer-logos/footer-logos.js
custom/clients/base/layouts/footer-logos/footer-logos.hbs
custom/clients/base/views/omnichannel-button/omnichannel-button.js
custom/clients/base/views/omnichannel-button/omnichannel-button.hbs
Footer button side files custom/clients/base/layouts/footer-buttons/footer-buttons.php
custom/clients/base/layouts/footer-buttons/footer-buttons.js
custom/clients/base/views/mobile-action/mobile-action.js
custom/clients/base/views/mobile-action/mobile-action.hbs
custom/clients/base/views/merge-widget-action/merge-widget-action.js
custom/clients/base/views/merge-widget-action/merge-widget-action.hbs
custom/clients/base/views/language-actions/language-actions.js
custom/clients/base/views/language-actions/language-actions.hbs
custom/clients/base/views/footer-actions/footer-actions.js
custom/clients/base/views/footer-actions/footer-actions.hbs
custom/clients/base/views/footer-actions/footer-actions.php

Scripts

Set of scripts to help you easily identify any customizations in your filesystem or any addon/MLP you may have created or installed in your instances.

Search on File System

You can execute the following script to search possible impacts through grep. Note that this script will search for terms in a wider range to make sure it catches most scenarios such as 

custom/Extension/application/Ext/clients/base/layouts/footer and not only custom/clients/base/layouts/footer

#search for folders in current directory
find . -type d | grep -i 'clients/.*/header\|clients/.*/footer\|clients/.*/module\|modules/.*/module\|clients/.*/quicksearch\|clients/.*/notifications\|clients/.*/profileactions\|clients/.*/quickcreate\|clients/.*/omnichannel\|clients/.*/mobile\|clients/.*/merge-widget\|clients/.*/language-actions'

#look for any occurence (most likely in manifest.php) in files
grep -i 'clients/.*/header\|clients/.*/footer\|clients/.*/module\|modules/.*/module\|clients/.*/quicksearch\|clients/.*/notifications\|clients/.*/profileactions\|clients/.*/quickcreate\|clients/.*/omnichannel\|clients/.*/mobile\|clients/.*/merge-widget\|clients/.*/language-actions' -R *

#easier to read version (will not execute)
#find . -type d | 
#    grep -i '
#        clients/.*/header\|
#        clients/.*/footer\|
#        clients/.*/module\|
#        modules/.*/module\|
#        clients/.*/quicksearch\|
#        clients/.*/notifications\|
#        clients/.*/profileactions\|
#        clients/.*/quickcreate\|
#        clients/.*/omnichannel\|
#        clients/.*/mobile\|
#        clients/.*/merge-widget\|
#        clients/.*/language-actions
#        '

Search on MLP Zip files

Copy all of your addons/MLPs into a directory in their zip format and execute the following script. It unzips the files in place, scans for possible customizations (using the same script as the previous section), and if found, returns its name (zip filename).

#!/bin/sh
find . -name *.zip |
while read filename
do
    path=$(echo $filename | sed 's/ /\\ /g')
    if ( unzip -c "$filename" | grep -i -q "clients/.*/header\|clients/.*/footer\|clients/.*/module\|modules/.*/module\|clients/.*/quicksearch\|clients/.*/notifications\|clients/.*/profileactions\|clients/.*/quickcreate\|clients/.*/omnichannel\|clients/.*/mobile\|clients/.*/merge-widget\|clients/.*/language-actions"); then
            o1=`ls -l "$filename" | awk '{print $6,$7,$8}' | column -t`
            o2=`echo "$filename" | sed 's|^[^/]*\(/[^/]*/\).*$|\1|' | sed 's|/||g'`
            echo "$filename" | column -t
    fi
done

Note: we're targeting manifest files on their copy commands for MLPs.

  • Share
  • History
  • More
  • Cancel
Anonymous
Related
Recommended