Skip to content

Instantly share code, notes, and snippets.

@esimonetti
Created August 22, 2019 16:22
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save esimonetti/4690a0220895dc3f8eb2da809bcd817a to your computer and use it in GitHub Desktop.
Save esimonetti/4690a0220895dc3f8eb2da809bcd817a to your computer and use it in GitHub Desktop.
Add newly built module sugar_PortalAnnouncements on portal. Test with: patch -p1 --dry-run < ../add_portal_announcements_to_portal.diff Install with: patch -p1 < ../add_portal_announcements_to_portal.diff
diff -auNr -x cache -x upload -x config.php -x config_override.php -x 'uk_UA*' -x 'tr_TR*' -x 'sv_SE*' -x 'sr_RS*' -x 'sq_AL*' -x 'sk_SK*' -x 'ru_RU*' -x 'ro_RO*' -x 'pt_PT*' -x 'pt_BR*' -x 'pl_PL*' -x 'nl_NL*' -x 'nb_NO*' -x 'lv_LV*' -x 'ko_KR*' -x 'ja_JP*' -x 'it_it*' -x 'hu_HU*' -x 'he_IL*' -x 'fr_FR*' -x 'fi_FI*' -x 'et_EE*' -x 'es_LA*' -x 'es_ES*' -x 'en_UK*' -x 'el_EL*' -x 'de_DE*' -x 'da_DK*' -x 'cs_CZ*' -x 'ca_ES*' -x 'bg_BG*' -x 'ar_SA*' -x 'lt_LT*' -x 'zh_TW*' -x 'zh_CN*' -x 'th_TH*' -x 'hr_HR*' '--ignore-matching-lines=// created: ' '--ignore-matching-lines=//created: ' -x '*.php_1*' -x '*.ext.php' -x '*blowfish*' -x .gitignore -x .gitattributes -x .htaccess -x '*.DS_Store' -x '*.git*' -x vendor -x '*.log' -x '*.zip' -x '*.sql' -x '*.tgz' -x '*.md' -x '*.filepart' -x config.js -x working -x modulebuilder sugarMango/custom/Extension/modules/sugar_PortalAnnouncements/Ext/Vardefs/portal_visibility.php sugar/custom/Extension/modules/sugar_PortalAnnouncements/Ext/Vardefs/portal_visibility.php
--- sugarMango/custom/Extension/modules/sugar_PortalAnnouncements/Ext/Vardefs/portal_visibility.php 1970-01-01 10:00:00.000000000 +1000
+++ sugar/custom/Extension/modules/sugar_PortalAnnouncements/Ext/Vardefs/portal_visibility.php 2019-08-22 12:15:55.409134769 +1000
@@ -0,0 +1,4 @@
+<?php
+$dictionary['sugar_PortalAnnouncements']['portal_visibility'] = [
+ 'class' => 'Visible',
+];
diff -auNr -x cache -x upload -x config.php -x config_override.php -x 'uk_UA*' -x 'tr_TR*' -x 'sv_SE*' -x 'sr_RS*' -x 'sq_AL*' -x 'sk_SK*' -x 'ru_RU*' -x 'ro_RO*' -x 'pt_PT*' -x 'pt_BR*' -x 'pl_PL*' -x 'nl_NL*' -x 'nb_NO*' -x 'lv_LV*' -x 'ko_KR*' -x 'ja_JP*' -x 'it_it*' -x 'hu_HU*' -x 'he_IL*' -x 'fr_FR*' -x 'fi_FI*' -x 'et_EE*' -x 'es_LA*' -x 'es_ES*' -x 'en_UK*' -x 'el_EL*' -x 'de_DE*' -x 'da_DK*' -x 'cs_CZ*' -x 'ca_ES*' -x 'bg_BG*' -x 'ar_SA*' -x 'lt_LT*' -x 'zh_TW*' -x 'zh_CN*' -x 'th_TH*' -x 'hr_HR*' '--ignore-matching-lines=// created: ' '--ignore-matching-lines=//created: ' -x '*.php_1*' -x '*.ext.php' -x '*blowfish*' -x .gitignore -x .gitattributes -x .htaccess -x '*.DS_Store' -x '*.git*' -x vendor -x '*.log' -x '*.zip' -x '*.sql' -x '*.tgz' -x '*.md' -x '*.filepart' -x config.js -x working -x modulebuilder sugarMango/custom/modules/sugar_PortalAnnouncements/clients/portal/views/list/list.php sugar/custom/modules/sugar_PortalAnnouncements/clients/portal/views/list/list.php
--- sugarMango/custom/modules/sugar_PortalAnnouncements/clients/portal/views/list/list.php 1970-01-01 10:00:00.000000000 +1000
+++ sugar/custom/modules/sugar_PortalAnnouncements/clients/portal/views/list/list.php 2019-08-22 12:13:34.930925728 +1000
@@ -0,0 +1,49 @@
+<?php
+/*
+ * Your installation or use of this SugarCRM file is subject to the applicable
+ * terms available at
+ * http://support.sugarcrm.com/Resources/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.
+ *
+ * Copyright (C) SugarCRM Inc. All rights reserved.
+ */
+
+$viewdefs['sugar_PortalAnnouncements']['portal']['view']['list'] = array(
+ 'panels' =>
+ array(
+ 0 =>
+ array(
+ 'label' => 'LBL_PANEL_DEFAULT',
+ 'fields' =>
+ array(
+ array(
+ 'name' => 'name',
+ 'link' => true,
+ 'label' => 'LBL_NAME',
+ 'enabled' => true,
+ 'default' => true
+ ),
+ array (
+ 'name' => 'date_entered',
+ 'label' => 'LBL_DATE_ENTERED',
+ 'enabled' => true,
+ 'default' => true,
+ 'readonly' => true,
+ ),
+ array (
+ 'name' => 'date_modified',
+ 'label' => 'LBL_DATE_MODIFIED',
+ 'enabled' => true,
+ 'default' => true,
+ 'readonly' => true,
+ ),
+ ),
+ ),
+ ),
+ 'last_state' => array(
+ 'id' => 'list',
+ ),
+);
+
diff -auNr -x cache -x upload -x config.php -x config_override.php -x 'uk_UA*' -x 'tr_TR*' -x 'sv_SE*' -x 'sr_RS*' -x 'sq_AL*' -x 'sk_SK*' -x 'ru_RU*' -x 'ro_RO*' -x 'pt_PT*' -x 'pt_BR*' -x 'pl_PL*' -x 'nl_NL*' -x 'nb_NO*' -x 'lv_LV*' -x 'ko_KR*' -x 'ja_JP*' -x 'it_it*' -x 'hu_HU*' -x 'he_IL*' -x 'fr_FR*' -x 'fi_FI*' -x 'et_EE*' -x 'es_LA*' -x 'es_ES*' -x 'en_UK*' -x 'el_EL*' -x 'de_DE*' -x 'da_DK*' -x 'cs_CZ*' -x 'ca_ES*' -x 'bg_BG*' -x 'ar_SA*' -x 'lt_LT*' -x 'zh_TW*' -x 'zh_CN*' -x 'th_TH*' -x 'hr_HR*' '--ignore-matching-lines=// created: ' '--ignore-matching-lines=//created: ' -x '*.php_1*' -x '*.ext.php' -x '*blowfish*' -x .gitignore -x .gitattributes -x .htaccess -x '*.DS_Store' -x '*.git*' -x vendor -x '*.log' -x '*.zip' -x '*.sql' -x '*.tgz' -x '*.md' -x '*.filepart' -x config.js -x working -x modulebuilder sugarMango/custom/modules/sugar_PortalAnnouncements/clients/portal/views/record/record.php sugar/custom/modules/sugar_PortalAnnouncements/clients/portal/views/record/record.php
--- sugarMango/custom/modules/sugar_PortalAnnouncements/clients/portal/views/record/record.php 1970-01-01 10:00:00.000000000 +1000
+++ sugar/custom/modules/sugar_PortalAnnouncements/clients/portal/views/record/record.php 2019-08-22 12:13:15.317123027 +1000
@@ -0,0 +1,73 @@
+<?php
+
+/*
+ * Your installation or use of this SugarCRM file is subject to the applicable
+ * terms available at
+ * http://support.sugarcrm.com/Resources/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.
+ *
+ * Copyright (C) SugarCRM Inc. All rights reserved.
+ */
+
+$viewdefs['sugar_PortalAnnouncements']['portal']['view']['record'] = array(
+ 'buttons' => array(
+ array(
+ 'name' => 'sidebar_toggle',
+ 'type' => 'sidebartoggle',
+ ),
+ ),
+ 'panels' => array(
+ array(
+ 'name' => 'panel_header',
+ 'header' => true,
+ 'fields' => array(
+ array(
+ 'name' => 'picture',
+ 'type' => 'avatar',
+ 'size' => 'large',
+ 'dismiss_label' => true,
+ 'readonly' => true,
+ ),
+ 'name',
+ ),
+ ),
+ array(
+ 'name' => 'panel_body',
+ 'label' => 'LBL_RECORD_BODY',
+ 'columns' => 2,
+ 'labelsOnTop' => true,
+ 'placeholders' => true,
+ 'fields' =>
+ array(
+ array(
+ 'name' => 'description',
+ 'span' => 12,
+ ),
+ array(
+ 'name' => 'date_entered_by',
+ 'readonly' => true,
+ 'type' => 'fieldset',
+ 'label' => 'LBL_DATE_ENTERED',
+ 'fields' => array(
+ array(
+ 'name' => 'date_entered',
+ ),
+ ),
+ ),
+ array(
+ 'name' => 'date_modified_by',
+ 'readonly' => true,
+ 'type' => 'fieldset',
+ 'label' => 'LBL_DATE_MODIFIED',
+ 'fields' => array(
+ array(
+ 'name' => 'date_modified',
+ ),
+ ),
+ ),
+ ),
+ ),
+ ),
+);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment