CRM-14383 - Update cj closures
authorColeman Watts <coleman@civicrm.org>
Fri, 28 Mar 2014 15:08:53 +0000 (11:08 -0400)
committerColeman Watts <coleman@civicrm.org>
Fri, 28 Mar 2014 18:49:39 +0000 (14:49 -0400)
182 files changed:
CRM/Core/Region.php
js/AutoComplete.js
templates/CRM/Activity/Form/Activity.tpl
templates/CRM/Activity/Form/ActivityLinks.tpl
templates/CRM/Activity/Form/Search.tpl
templates/CRM/Activity/Form/Search/Common.tpl
templates/CRM/Activity/Form/Task/FileOnCase.tpl
templates/CRM/Activity/Selector/Selector.tpl
templates/CRM/Admin/Form/MessageTemplates.tpl
templates/CRM/Admin/Form/Preferences/Display.tpl
templates/CRM/Admin/Form/ScheduleReminders.tpl
templates/CRM/Admin/Form/Setting/Mapping.tpl
templates/CRM/Admin/Form/Setting/Smtp.tpl
templates/CRM/Admin/Form/WordReplacements.tpl
templates/CRM/Admin/Page/Extensions.tpl
templates/CRM/Admin/Page/MessageTemplates.tpl
templates/CRM/Admin/Page/Navigation.tpl
templates/CRM/Admin/Page/Tag.tpl
templates/CRM/Badge/Form/Layout.js
templates/CRM/Batch/Form/Entry.js
templates/CRM/Batch/Form/Entry.tpl
templates/CRM/Batch/Form/Search.tpl
templates/CRM/Block/RecentlyViewed.tpl
templates/CRM/Campaign/Form/Gotv.tpl
templates/CRM/Campaign/Form/Petition.tpl
templates/CRM/Campaign/Form/Search/Campaign.tpl
templates/CRM/Campaign/Form/Search/Common.tpl
templates/CRM/Campaign/Form/Search/Petition.tpl
templates/CRM/Campaign/Form/Search/Survey.tpl
templates/CRM/Campaign/Form/Survey/Main.tpl
templates/CRM/Campaign/Form/Task/Interview.tpl
templates/CRM/Campaign/Form/Task/Reserve.tpl
templates/CRM/Campaign/Page/Vote.tpl
templates/CRM/Case/Form/Activity.tpl
templates/CRM/Case/Form/Activity/LinkCases.tpl
templates/CRM/Case/Form/ActivityChangeStatusJs.tpl
templates/CRM/Case/Form/ActivityTab.tpl
templates/CRM/Case/Form/ActivityToCase.tpl
templates/CRM/Case/Form/CaseView.tpl
templates/CRM/Case/Form/Search.tpl
templates/CRM/Case/Page/CustomDataView.tpl
templates/CRM/Contact/Form/Contact.tpl
templates/CRM/Contact/Form/CustomData.tpl
templates/CRM/Contact/Form/Edit/Address.tpl
templates/CRM/Contact/Form/Edit/CommunicationPreferences.tpl
templates/CRM/Contact/Form/Edit/Individual.tpl
templates/CRM/Contact/Form/Edit/Lock.tpl
templates/CRM/Contact/Form/Inline/CommunicationPreferences.tpl
templates/CRM/Contact/Form/Inline/Demographics.tpl
templates/CRM/Contact/Form/Inline/Email.tpl
templates/CRM/Contact/Form/Inline/IM.tpl
templates/CRM/Contact/Form/Inline/OpenID.tpl
templates/CRM/Contact/Form/Inline/Phone.tpl
templates/CRM/Contact/Form/Inline/Website.tpl
templates/CRM/Contact/Form/OnBehalfOf.tpl
templates/CRM/Contact/Form/Relationship.tpl
templates/CRM/Contact/Form/Search/AdvancedCriteria.tpl
templates/CRM/Contact/Form/Search/BasicCriteria.tpl
templates/CRM/Contact/Form/Search/Criteria/Basic.tpl
templates/CRM/Contact/Form/Search/Criteria/ChangeLog.tpl
templates/CRM/Contact/Form/Search/Criteria/Location.tpl
templates/CRM/Contact/Form/Search/Custom.tpl
templates/CRM/Contact/Form/Search/Custom/ActivitySearch.tpl
templates/CRM/Contact/Form/Search/Custom/ContribSYBNT.tpl
templates/CRM/Contact/Form/Search/Custom/ContributionAggregate.tpl
templates/CRM/Contact/Form/Search/Custom/MultipleValuesCriteria.tpl
templates/CRM/Contact/Form/Search/Custom/Proximity.tpl
templates/CRM/Contact/Form/Search/ResultTasks.tpl
templates/CRM/Contact/Form/Selector.tpl
templates/CRM/Contact/Form/ShareAddress.tpl
templates/CRM/Contact/Form/Task.tpl
templates/CRM/Contact/Form/Task/EmailCommon.js
templates/CRM/Contact/Form/Task/PDFLetterCommon.tpl
templates/CRM/Contact/Form/Task/SMSCommon.tpl
templates/CRM/Contact/Import/Form/MapTable.tpl
templates/CRM/Contact/Import/Form/Preview.tpl
templates/CRM/Contact/Page/DashBoardDashlet.tpl
templates/CRM/Contact/Page/Dashlet.tpl
templates/CRM/Contact/Page/View/GroupContact.tpl
templates/CRM/Contact/Page/View/Log.tpl
templates/CRM/Contact/Page/View/RelationshipSelector.tpl
templates/CRM/Contact/Page/View/Summary.tpl
templates/CRM/Contribute/Form/AdditionalInfo/CreditCard.tpl
templates/CRM/Contribute/Form/AdditionalPayment.tpl
templates/CRM/Contribute/Form/Contribution.tpl
templates/CRM/Contribute/Form/Contribution/Main.tpl
templates/CRM/Contribute/Form/Contribution/MembershipBlock.tpl
templates/CRM/Contribute/Form/Contribution/OnBehalfOf.tpl
templates/CRM/Contribute/Form/Contribution/PremiumBlock.tpl
templates/CRM/Contribute/Form/ContributionCharts.tpl
templates/CRM/Contribute/Form/ContributionPage/Amount.tpl
templates/CRM/Contribute/Form/ContributionPage/Premium.tpl
templates/CRM/Contribute/Form/ContributionPage/Widget.tpl
templates/CRM/Contribute/Form/Search.tpl
templates/CRM/Contribute/Form/SoftCredit.tpl
templates/CRM/Contribute/Page/DashBoard.js
templates/CRM/Contribute/Page/PaymentInfo.tpl
templates/CRM/Core/APIDoc.tpl
templates/CRM/Core/AjaxDoc.tpl
templates/CRM/Core/BillingBlock.js
templates/CRM/Core/BillingBlock.tpl
templates/CRM/Custom/Form/ContactReference.tpl
templates/CRM/Custom/Form/CustomData.tpl
templates/CRM/Custom/Form/Group.tpl
templates/CRM/Custom/Page/CustomDataView.tpl
templates/CRM/Event/Form/EventFees.tpl
templates/CRM/Event/Form/ManageEvent/EventInfo.tpl
templates/CRM/Event/Form/ManageEvent/Fee.tpl
templates/CRM/Event/Form/ManageEvent/Registration.tpl
templates/CRM/Event/Form/ManageEvent/ScheduleReminders.tpl
templates/CRM/Event/Form/ManageEvent/Tab.tpl
templates/CRM/Event/Form/Participant.tpl
templates/CRM/Event/Form/ParticipantFeeSelection.tpl
templates/CRM/Event/Form/Registration/Register.tpl
templates/CRM/Event/Form/Search.tpl
templates/CRM/Event/Form/Search/Common.tpl
templates/CRM/Event/Form/Task/Batch.tpl
templates/CRM/Financial/Form/BatchTransaction.tpl
templates/CRM/Financial/Form/Export.tpl
templates/CRM/Financial/Form/FinancialBatch.tpl
templates/CRM/Financial/Form/Search.tpl
templates/CRM/Financial/Page/BatchTransaction.tpl
templates/CRM/Form/attachment.tpl
templates/CRM/Form/attachmentjs.tpl
templates/CRM/Form/validate.tpl
templates/CRM/Grant/Form/Grant.tpl
templates/CRM/Grant/Form/Search.tpl
templates/CRM/Group/Form/Search.tpl
templates/CRM/Mailing/Form/Approve.tpl
templates/CRM/Mailing/Form/Count.tpl
templates/CRM/Mailing/Form/Group.tpl
templates/CRM/Mailing/Form/InsertTokens.tpl
templates/CRM/Mailing/Form/Schedule.tpl
templates/CRM/Mailing/Form/Settings.tpl
templates/CRM/Mailing/Form/Test.tpl
templates/CRM/Mailing/Page/Event.tpl
templates/CRM/Mailing/Page/Tab.tpl
templates/CRM/Member/Form/Membership.js
templates/CRM/Member/Form/Membership.tpl
templates/CRM/Member/Form/MembershipBlock.tpl
templates/CRM/Member/Form/MembershipRenewal.tpl
templates/CRM/Member/Form/MembershipStandalone.js
templates/CRM/Member/Form/MembershipType.tpl
templates/CRM/Member/Form/Search.tpl
templates/CRM/Member/Form/Task/Label.js
templates/CRM/Pledge/Form/Pledge.tpl
templates/CRM/Pledge/Form/Search.tpl
templates/CRM/Profile/Form/Search.tpl
templates/CRM/Profile/Page/MultipleRecordFieldsListing.tpl
templates/CRM/Queue/Page/Runner.tpl
templates/CRM/Report/Form/Case/Detail.tpl
templates/CRM/Report/Form/Fields.tpl
templates/CRM/Report/Form/Instance.tpl
templates/CRM/Report/Form/Layout/Graph.tpl
templates/CRM/Report/Page/InstanceList.tpl
templates/CRM/Report/Page/TemplateList.tpl
templates/CRM/SMS/Form/Group.tpl
templates/CRM/SMS/Form/Schedule.tpl
templates/CRM/Tag/Form/Tag.tpl
templates/CRM/UF/Form/AdvanceSetting.tpl
templates/CRM/UF/Form/Block.tpl
templates/CRM/UF/Form/Field.tpl
templates/CRM/UF/Page/Group.tpl
templates/CRM/Widget/Page/Inline/Example.tpl
templates/CRM/common/Navigation.tpl
templates/CRM/common/TabHeader.js
templates/CRM/common/TrackingFields.tpl
templates/CRM/common/additionalBlocks.tpl
templates/CRM/common/batchCopy.tpl
templates/CRM/common/crmeditable.tpl
templates/CRM/common/dashboard.tpl
templates/CRM/common/enableDisableApi.tpl
templates/CRM/common/formNavigate.tpl
templates/CRM/common/highLightImport.tpl
templates/CRM/common/jcalendar.tpl
templates/CRM/common/jsortable.tpl
templates/CRM/common/pager.tpl
templates/CRM/common/paymentBlock.tpl
templates/CRM/common/searchResultTasks.tpl
templates/CRM/common/stateCountry.tpl
tests/phpunit/CRM/Core/RegionTest.php
tools/extensions/org.civicrm.search.activity/templates/ActivitySearch.tpl

index bc125a42817a20171cafdd14e14ca75970fd1a82..c3b25ec0e54702ea2cd8b3a768d9acde14bdf8f7 100644 (file)
@@ -175,7 +175,7 @@ class CRM_Core_Region {
           }
           break;
         case 'jquery':
-          $snippet['script'] = sprintf("cj(function(\$){\n%s\n});", $snippet['jquery']);
+          $snippet['script'] = sprintf("CRM.\$(function(\$) {\n%s\n});", $snippet['jquery']);
           // no break - continue processing as script
         case 'script':
           if (!$allowCmsOverride || !$cms->addScript($snippet['script'], $this->_name)) {
index 8304d0e047cdb2055781dfeb834b93d1459c4cb3..ee38992cf7197e90f48b46b30bd1b6e72300c42b 100644 (file)
@@ -1,4 +1,4 @@
-cj(function ($) {
+CRM.$(function($) {
   'use strict';
 
   // Behind the scenes method deals with browser for setting cursor position
index 6b6c969e65f1d3efd8f91e1c0f20c2e0a1eb848f..ace20497037d901c6c8407fe725aa5d198088222 100644 (file)
       </div><!-- /.crm-accordion-wrapper -->
       {literal}
         <script type="text/javascript">
-          cj(function($) {
+          CRM.$(function($) {
             cj().crmAccordions();
             cj('.crm-accordion-body').each( function() {
               //open tab if form rule throws error
   {include file="CRM/common/customData.tpl"}
     {literal}
     <script type="text/javascript">
-    cj(function() {
+    CRM.$(function($) {
     {/literal}
     {if $customDataSubType}
       CRM.buildCustomData( '{$customDataType}', {$customDataSubType} );
index 94ae229c2f179c31591b94c45191468eb51fd4d4..eda8494f5bbead239cb214e218e26dfd823f53dd 100644 (file)
@@ -38,7 +38,7 @@
 </select>
 {literal}
 <script type="text/javascript">
-  cj(function($) {
+  CRM.$(function($) {
     $('[name=other_activity].crm-action-menu').change(function() {
       var
         $el = $(this),
index 8cae98554fddbe0d9a859f00a772f850fa1bd02e..1bcabfd1e566d518e3f4ef52863d3c914e7fccfa 100644 (file)
@@ -87,7 +87,7 @@
 {/if}
 {literal}
   <script type="text/javascript">
-    cj(function () {
+    CRM.$(function($) {
       cj().crmAccordions();
 
       var roleId = cj('input[name=activity_role]:checked', '#Search').val();
index ad1bd5ea85444396c759b9365250d37fbdd33406..484459981722ea76971829f28a105f23aa71f397 100644 (file)
@@ -127,7 +127,7 @@ campaignContext="componentSearch" campaignTrClass='' campaignTdClass=''}
 
 {literal}
 <script type="text/javascript">
-  cj(function() {
+  CRM.$(function($) {
     //Searchable activity custom fields which extend ALL activity types are always displayed in the form
     //hence hide remaining activity custom data
     cj('#activityCustom').children( ).each( function( ) {
index 145bab90fe6a1b143de37c70d31171c2daf9ef24..1c81d51d3801165e9d2f032e36f4b85afd317a9a 100644 (file)
@@ -45,7 +45,7 @@
 </div>
 {literal}
 <script type="text/javascript">
-cj(function($) {
+CRM.$(function($) {
   var $form = $("#{/literal}{$form.formName}{literal}");
   $('input[name=unclosed_case_id]', $form).select2({
     placeholder: {/literal}'{ts escape="js"}- select case -{/ts}'{literal},
index e770ff625950681e03eebb18f92ea36e12366ec5..9eaea866927c3e310a815baf56da0f96ca7ebacd 100644 (file)
@@ -61,7 +61,7 @@
 <script type="text/javascript">
   var {/literal}{$context}{literal}oTable;
 
-  cj(function ( ) {
+  CRM.$(function($) {
     cj().crmAccordions();
     var context = {/literal}"{$context}"{literal};
     var filterSearchOnLoad = false;
index 7ae58700a67c0e818155b108708ff476f9e7497d..9b393555dd5bdfe64d71831eaede50b65cd4a943 100644 (file)
 {include file="CRM/Mailing/Form/InsertTokens.tpl"}
 {literal}
 <script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
    cj().crmAccordions();
 });
 </script>
index 03ec78cb46808c07b08853b7f9346f41fc47e00a..faf3b1c3834a63915ac1375a0dd42fe3b1d92eb6 100644 (file)
 {if $form.contact_edit_options.html}
   {literal}
     <script type="text/javascript">
-      cj(function () {
+      CRM.$(function($) {
         cj("#contactEditBlocks").sortable({
           placeholder: 'ui-state-highlight',
           update: getSorting
index e81dd4888d40b5c6c156dc914049e4e1ae9a0828..f92f6cd91a439f4c757c7e9e8bc104cfc8d9d8c3 100644 (file)
 
 {literal}
 <script type='text/javascript'>
-  cj(function($) {
+  CRM.$(function($) {
     $().crmAccordions();
   });
     var entityMapping = eval({/literal}{$entityMapping}{literal});
         }
     });
 
-    cj(function() {
+    CRM.$(function($) {
         if (cj('#absolute_date_display').val()) {
             cj('#relativeDate').hide();
             cj('#relativeDateRepeat').hide();
          });
      });
 
-  cj(function () {
+  CRM.$(function($) {
     loadMsgBox();
     cj('#mode').change(function () {
       loadMsgBox();
     }
   }
 
-  cj(function () {
+  CRM.$(function($) {
     if (cj('#is_recipient_listing').val()) {
       cj('#recipientList').show();
     }
index 847e543a619ea4958febd99e1a95ccc1bd468764..bdb6e786c1e76abbe5d113a38eb27ac3c4be675c 100644 (file)
@@ -54,7 +54,7 @@
 </div>
 {literal}
 <script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
   showHideMapAPIkey( cj('#mapProvider').val( ) );
 });
 function showHideMapAPIkey( mapProvider ) {
index a01a15ea1d6f33a6cff2faeb2939e68e1dc82187..758f5502289a9d8c1c82dbb215def5ae96618b8e 100644 (file)
 
 {literal}
 <script type="text/javascript">
-    cj( function( ) {
+    CRM.$(function($) {
       var mailSetting = cj("input[name='outBound_option']:checked").val( );
 
       var archiveWarning = "{/literal}{ts escape='js'}WARNING: You are switching from a testing mode (Redirect to Database) to a live mode. Check Mailings > Archived Mailings, and delete any test mailings that are not in Completed status prior to running the mailing cron job for the first time. This will ensure that test mailings are not actually sent out.{/ts}{literal}"
index f6a4118ef129cdc1977fb88517c0e6536a6c6ab5..013dbb5502dbbaae026ca6c6c4b5662e7c36c85d 100644 (file)
@@ -100,7 +100,7 @@ function buildStringOverrideRow( curInstance )
    });
 }
 
-cj( function( ) {
+CRM.$(function($) {
   {/literal}
   {if $stringOverrideInstances}
      {foreach from=$stringOverrideInstances key="index" item="instance"}
index 5de7a7cd4c8c4565237016c9147054de332da78f..bf7021136a40edf6388956f471466a1ed6e0b054 100644 (file)
@@ -84,7 +84,7 @@
     {* Expand/Collapse *}
     {literal}
     <script type="text/javascript">
-      cj( function( ) {
+      CRM.$(function($) {
           cj('.collapsed').click( function( ) {
               var currentObj = cj( this );
               if ( currentObj.hasClass( 'expanded') ) {
 
     {literal}
 
-    cj( function() {
+    CRM.$(function($) {
       var tabIndex = cj('#tab_' + selectedTab).prevAll().length;
       cj("#mainTabContainer").tabs({active: tabIndex});
       cj(".crm-tab-button").addClass("ui-corner-bottom");
     {* Refresh buttons *}
     {literal}
     <script type="text/javascript">
-    cj(function() {
+    CRM.$(function($) {
       cj('.crm-extensions-refresh').click(function(event){
         event.stopPropagation();
         CRM.alert('', '{/literal}{ts escape="js"}Refreshing...{/ts}{literal}', 'crm-msg-loading', {expires: 0});
index a33b67042b5e60d9cbad42e7c178db1ae6edb725..23ea5bde5de0df86af08c2207b49980b5c253a4a 100644 (file)
     var selectedTab = 'user';
     {if $selectedChild}selectedTab = '{$selectedChild}';{/if}
     {literal}
-      cj( function() {
+      CRM.$(function($) {
         var tabIndex = cj('#tab_' + selectedTab).prevAll().length
         cj("#mainTabContainer").tabs( {active: tabIndex} );
       });
index d38672c0fc2f3dc107e2aef4cb0be966ccaacd33..a058ff84b25fb2b586d2718c6d2a0a34b7727d6f 100644 (file)
@@ -52,7 +52,7 @@
     }
   </style>
   <script type="text/javascript">
-  cj(function($) {
+  CRM.$(function($) {
     cj("#navigation-tree").jstree({
     plugins : [ "themes", "json_data", "dnd","ui", "crrm","contextmenu" ],
     json_data  : {
index 4ec3b2338dc9767d5546806ced7197d7986b2b45..f700e3253f11a1caea1b9604e9e7b5611a8d2b0b 100644 (file)
 
 {literal}
 <script type="text/javascript">
-cj(function($) {
+CRM.$(function($) {
   var tag;
   $('.merge_tag').click(function(e) {
     tag = $(this).crmEditableEntity();
index 3398ba757d5e97ac39ea8c4900517800e0432b3c..5586588947cb291ccf10403d2f9a1092c779a6f4 100644 (file)
@@ -1,5 +1,5 @@
 // http://civicrm.org/licensing
-cj(function ($) {
+CRM.$(function($) {
   function openKCFinder(field) {
     var field = $(this);
     window.KCFinder = {
index 6b81bd19621a544cf7b1f50b09feb34ad4b4aee2..3fe3693d5ee8b7ca14d8d3e8ee3fd3d99f9f4669 100644 (file)
@@ -1,6 +1,6 @@
 //@todo functions partially moved from tpl but still need an enclosure / cleanup
 // jslinting etc
-cj(function () {
+CRM.$(function($) {
   cj('.selector-rows').change(function () {
     var options = {
       'url': CRM.url('civicrm/ajax/batch')
index 9acd70bd75415ec196da93e6a1f29880a278a5b0..90c43bd65f1db87918d15e5989da8a20b90cd343 100644 (file)
 </div>
 {literal}
 <script type="text/javascript">
-cj(function () {
+CRM.$(function($) {
   cj('.selector-rows').change(function () {
     var options = {
       'url': {/literal}"{crmURL p='civicrm/ajax/batch' h=0}"{literal}
index 3d92c3561359aa08abe2667d9bae8e55e7dd0dfd..3d1e08b11d23b782db5df4a2b55132addf4fa4fa 100644 (file)
@@ -56,7 +56,7 @@
 
 {literal}
 <script type="text/javascript">
-cj( function() {
+CRM.$(function($) {
   buildBatchSelector( false );
   cj('#_qf_Search_refresh').click( function() {
     buildBatchSelector(true);
index 986d9dadbcf3e0eb6a66c9793062d3b5d788cdbc..2c65ec024a528a4c79103dc32649ac440115a4d0 100644 (file)
@@ -45,7 +45,7 @@
 </div>
 {literal}
 <script type="text/javascript">
-    cj( function( ) {
+    CRM.$(function($) {
       if (cj('#crm-recently-viewed').offset().left > 150) {
         cj('#crm-recently-viewed').removeClass('left').addClass('right');
           }
index 853c85d2ac1a3787043e4db93002cacc93512ce6..173f58a57e661d03a66c7b8b68787d5afb36f8b5 100755 (executable)
@@ -41,7 +41,7 @@
 
        {literal}
        <script type="text/javascript">
-       cj( function( ){
+       CRM.$(function($) {
            loadVoterList( );
        });
        </script>
@@ -84,7 +84,7 @@
  {* load selector when force *}
  {if $force and !$buildSelector}
  {literal}
cj( function( ) {
CRM.$(function($) {
     searchVoters( {/literal}'{$qfKey}'{literal} );
  });
 
index 6865964bb73f7d5e8bd0cb56396dd8fa01a5d16f..cca8e77cb939d5b08284d0fb7cf57c7eb8ca18d8 100644 (file)
 {literal}
   <script type="text/javascript">
     //show edit profile field links
-    cj(function () {
+    CRM.$(function($) {
       // show edit for both contact and activity profile
       cj('select[id$="profile_id"]').change(function () {
         buildLinks(cj(this), cj(this).val());
index 6bb051a526fc7bdd2a77ade0ab2a4f71735f99f8..8c3ffb0e9e0bc7e53fec45df6c777ba11ab5ebac 100755 (executable)
@@ -43,7 +43,7 @@
 
   {literal}
     <script type="text/javascript">
-      cj(function () {
+      CRM.$(function($) {
         loadCampaignList();
       });
     </script>
 {literal}
 <script type="text/javascript">
 
-  cj(function () {
+  CRM.$(function($) {
     cj().crmAccordions();
   });
 
   {* load selector when force *}
   {if $force and !$buildSelector}
   {literal}
-  cj(function () {
+  CRM.$(function($) {
     searchCampaigns({/literal}'{$qfKey}'{literal});
   });
 
index 0dc3e50bf91cc55506a8788812db82071b4b24a0..4618a0a5df07af6d6024ea3ea6f47c3989093bfb 100755 (executable)
 {literal}
 <script type="text/javascript">
 
-  cj(function() {
+  CRM.$(function($) {
     cj().crmAccordions();
 
     {/literal}
index e39d2dbcfb9f66f580fcd8677d39c52f9d43c28e..37819a5d5177bf6072e80a0dd820d3304eb369c7 100755 (executable)
@@ -46,7 +46,7 @@
 
        {literal}
        <script type="text/javascript">
-       cj( function( ){
+       CRM.$(function($) {
            loadPetitionList( );
        });
        </script>
 {literal}
 <script type="text/javascript">
 
cj(function() {
CRM.$(function($) {
     cj().crmAccordions();
  });
 
  {* load selector when force *}
  {if $force and !$buildSelector}
  {literal}
cj( function( ) {
CRM.$(function($) {
     searchPetitions( {/literal}'{$qfKey}'{literal} );
  });
 
index c2dc85607f55da02e67fadec6d2d6a7841108456..b9286a2e3e479ee565e92791c94b8a7b01b381e5 100755 (executable)
@@ -45,7 +45,7 @@
 
   {literal}
   <script type="text/javascript">
-    cj( function( ){
+    CRM.$(function($) {
       loadSurveyList( );
     });
   </script>
 {literal}
 <script type="text/javascript">
 
cj(function() {
CRM.$(function($) {
     cj().crmAccordions();
  });
 
  {* load selector when force *}
  {if $force and !$buildSelector}
  {literal}
cj( function( ) {
CRM.$(function($) {
     searchSurveys( {/literal}'{$qfKey}'{literal} );
  });
 
index 6291ccbef53655f10df661c6e86dfd98a5030694..17a08d406941febc0738e87ee1853e23f9016632 100644 (file)
@@ -95,7 +95,7 @@
 {literal}
 <script type="text/javascript">
     //show edit profile field links
-    cj(function() {
+    CRM.$(function($) {
         // show edit for profile
         cj('select[id="profile_id"]').change( function( ) {
             buildLinks( cj(this), cj(this).val());
index 1fb6fcecaa648fd253aaf1fc73b555ae37fcbf51..bd6e3b53cb2453670091b332a94bcd4a84d838d2 100644 (file)
 <script type="text/javascript">
 var updateVote = "{/literal}{ts escape='js'}Update Response{/ts}{literal}";
 var updateVoteforall = "{/literal}{ts escape='js'}Update Responses for All{/ts}{literal}";
-cj( function( ) {
+CRM.$(function($) {
   var count = 0; var columns='';
 
   cj('#voterRecords th').each( function( ) {
index 3edbd79ad14cff9aa9a899a299de88bc77c1fdd5..bfb8db8b47328f5aa85d66c95c01c8b4383689cd 100755 (executable)
@@ -81,7 +81,7 @@
 {literal}
 <script type="text/javascript">
 
cj(function() {
CRM.$(function($) {
    cj().crmAccordions();
    setDefaultGroup( );
  });
index b1282617138e8af7e05d10589cc8617890ccb14e..93b60ed0ace3ea9d011a4c7c946bd298b50f6991 100644 (file)
@@ -35,7 +35,7 @@
   <script type="text/javascript">
     {* very crude refresh of tabs - fixme: use datatable native refresh method *}
     {literal}
-    cj(function($) {
+    CRM.$(function($) {
       $('#mainTabContainer').on('tabsbeforeactivate', function(e, ui) {
         // fixme - can't search more than once! Uncomment this code, switching tabs gives qfkey error.
         //if (ui.newTab.is('#tab_reserve')) {
index 2ca7d88c3c1f0bca06bd9e03da5cf6f183ba8310..f5c044f6c8cb0e94f96615d7dea211d170223a57 100644 (file)
   {include file="CRM/common/customData.tpl"}
     {literal}
     <script type="text/javascript">
-    cj(function() {
+    CRM.$(function($) {
     {/literal}
     {if $customDataSubType}
       CRM.buildCustomData( '{$customDataType}', {$customDataSubType} );
   {if $action eq 2 or $action eq 1}
     {literal}
     <script type="text/javascript">
-      cj(function( ) {
+      CRM.$(function($) {
         cj('.crm-with-contact').click(function(){
           cj('#with-contacts-widget').toggle();
           cj('#with-clients').toggle();
index 5bf08748f51c9dbcfe00c3e1d867504ab6f7a8f0..7f15ada6913311713f912924390cf215f641c801 100644 (file)
@@ -32,7 +32,7 @@
 
 {literal}
 <script type="text/javascript">
-  cj(function($) {
+  CRM.$(function($) {
     var $form = $("#{/literal}{$form.formName}{literal}");
     $('input[name=link_to_case_id]', $form).select2({
       placeholder: {/literal}'{ts escape="js"}- select case -{/ts}'{literal},
index 6583095d1ed3600079f640a6f2a03c20e4b643b2..a801e4c396be4806e5a5a6fb85c7a728ff99fc57 100644 (file)
@@ -26,7 +26,7 @@
 {* CiviCase - change activity status inline *}
 {literal}
   <script type="text/javascript">
-    cj(function($) {
+    CRM.$(function($) {
       // Elements are sometimes in a jQuery dialog box which is outside crm-container,
       // So gotta attach this handler to the whole body - sorry.
       $('body').off('click.changeActivityStatus');
index bd4214918cb7b54b7807841856b6c6e1b687a62d..9276acbdcdbba469237fd4e13e1cd80870f06eb9 100644 (file)
@@ -89,7 +89,7 @@
 
 {literal}
 <script type="text/javascript">
-cj(function( ) {
+CRM.$(function($) {
   buildCaseActivities(false);
 });
 
@@ -162,4 +162,4 @@ function setSelectorClass( ) {
   });
 }
 </script>
-{/literal}
\ No newline at end of file
+{/literal}
index 74051eeeb9788fa6a30fd8a607b7c86105d20cb6..8a2d232286eb379fcd83c1554635f85f150240aa 100644 (file)
@@ -49,7 +49,7 @@
     var target_contact_id = '';
     var selectedCaseId = '';
     var contactId = '';
-    cj(function($) {
+    CRM.$(function($) {
       $('input[name=unclosed_case_id]', '#fileOnCaseDialog').select2({
         placeholder: {/literal}'{ts escape="js"}- select case -{/ts}'{literal},
         minimumInputLength: 1,
index ca2ce8b39f06b89fdf45c868236361620d9ae265..97be9a32556596ab5092b4c2b69bd76aff982e83 100644 (file)
   <script type="text/javascript">
   var oTable;
 
-  cj(function() {
+  CRM.$(function($) {
     buildCaseRoles(false);
   });
 
       {/if}
  {literal}
  <script type="text/javascript">
-   cj(function( ) {
+   CRM.$(function($) {
       buildCaseClientRelationships(false);
    });
 
  {literal}
  <script type="text/javascript">
 
cj(function() {
CRM.$(function($) {
     buildCaseGlobalRelationships(false);
  });
 
index 261022e05b00ef5e6b961ee61ce2b60700676e78..39e99989b97fed1f2c79f3f56ec98fca205329f6 100644 (file)
@@ -81,7 +81,7 @@
 {/if}
 {literal}
 <script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
    cj().crmAccordions();
 });
 </script>
index 672c30140a5d21176f8c3085119e5b730624fd65..8811ad8bfd92cf1b557fa0f18378befb0c2b44c9 100644 (file)
@@ -85,7 +85,7 @@
 
 {literal}
 <script type="text/javascript">
-  cj(function() {
+  CRM.$(function($) {
     cj().crmAccordions();
   });
 </script>
index e657a514ac4aae07d04d30d97f2ee24c6e80b6bd..5748c2c2c24ea90c234408250ae2c7d222b75912 100644 (file)
   {literal}
 
   <script type="text/javascript" >
-  cj(function($) {
+  CRM.$(function($) {
     var action = "{/literal}{$action}{literal}";
     $().crmAccordions();
 
index aa2edffc769a83ade33c2fae39cda3f7858ee7eb..807f00a37afb579a950e18a1e94e23606befb165 100644 (file)
@@ -52,4 +52,4 @@
   {/if}
 {/if}
 
-{include file="CRM/Form/attachmentjs.tpl"}
\ No newline at end of file
+{include file="CRM/Form/attachmentjs.tpl"}
index 54262146efbd350953034a09fa3ad829e40ff317..f996ac2becfe0ffdf4e6819d9fba4aac9cab0bb1 100644 (file)
@@ -111,7 +111,7 @@ function checkLocation( object, noAlert ) {
 {/literal}
 {literal}
 <script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
    cj().crmAccordions();
 });
 </script>
index 343404c40c64c250c0bcbc29ebf34c6743aa1ca9..8c9152bc0df6da856f77d3ad9f5bf1a4983f258a 100644 (file)
 
 {literal}
 <script type="text/javascript">
-cj( function( ) {
+CRM.$(function($) {
     var fields = new Array( 'postal_greeting', 'addressee', 'email_greeting');
     for ( var i = 0; i < 3; i++ ) {
         cj( "#" + fields[i] + "_id").change( function( ) {
index 5d23ac1d9b5e31aa2677f2cc4cb781a0328f659b..5998aaedc02b16c9eaa98eb84f35ac2158f7edba 100644 (file)
@@ -26,7 +26,7 @@
 {* tpl for building Individual related fields *}
 <script type="text/javascript">
 {literal}
-cj(function($) {
+CRM.$(function($) {
 {/literal}
   var cid=parseFloat("{$contactId}");//parseInt is octal by default
   var contactIndividual = "{crmURL p='civicrm/ajax/rest' q='entity=contact&action=get&json=1&contact_type=Individual&return=display_name,sort_name,email&rowCount=50' h=0}";
index a8807e50faf5ee4194e394f2226e20bf106d72d6..0c4c43af100122eebe33be3f130fd9bde9976935 100644 (file)
@@ -1,6 +1,6 @@
 {literal}
 <script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
   if (cj('#update_modified_date').length == 0) {
     return;
   }
index dc40f63d2f743c873ceda252693569c29f7b6e00..0e7e3ae67cfe1a2a2371320c1dd153b8b38616ce 100644 (file)
 
 {literal}
 <script type="text/javascript">
-cj( function( ) {
+CRM.$(function($) {
     var fields = new Array( 'postal_greeting', 'addressee', 'email_greeting');
     for ( var i = 0; i < 3; i++ ) {
       cj( "#" + fields[i] + "_id").change( function( ) {
index 1987e0706e5e2a3ee89d2c04b73e7d85d71d7132..7ad19d97d34ba490eb5177064f4a2c8c6a1f9b31 100644 (file)
@@ -67,7 +67,7 @@ function showDeceasedDate( ) {
   }
 }
 
-cj( function() {
+CRM.$(function($) {
   showDeceasedDate( );
 });
 </script>
index f8746ebba014f9954ae6ed82775a0879a780b665..73fea94c0041ce15c771da6ad2e5c4e0c9bb52e7 100644 (file)
@@ -67,7 +67,7 @@
 
 {literal}
 <script type="text/javascript">
-    cj(function($) {
+    CRM.$(function($) {
       // check first primary radio
       $('#Email_1_IsPrimary').prop('checked', true );
     });
index efe4e20ae52e65ae0c4ad6df5de8bcfbe51fb352..152d2e89c93d7773e87f04489ec1a074a5f085f5 100644 (file)
@@ -62,7 +62,7 @@
 
 {literal}
 <script type="text/javascript">
-    cj(function($) {
+    CRM.$(function($) {
       // check first primary radio
       $('#IM_1_IsPrimary').prop('checked', true );
     });
index 412b41ca294ca101428f317369d6d05f1c2d6f08..c915f9cedaf5ecc43b37f71db036cd8f6b479b90 100644 (file)
@@ -62,7 +62,7 @@
 
 {literal}
 <script type="text/javascript">
-    cj(function($) {
+    CRM.$(function($) {
       // check first primary radio
       $('#OpenID_1_IsPrimary').prop('checked', true );
     });
index 0d67519df196092ce0fb995c83e712b02dd815bd..327b02dce00a59d0f2d312886a9218d364a16039 100644 (file)
@@ -62,7 +62,7 @@
 
 {literal}
 <script type="text/javascript">
-  cj(function($) {
+  CRM.$(function($) {
     // check first primary radio
     $('#Phone_1_IsPrimary').prop('checked', true );
   });
index a431c34957d1270d995fd456c0dcf7c9a7bd6af9..327473a0c98a15acde7c8d3cb5e652c02fbf2992 100644 (file)
@@ -61,7 +61,7 @@
 
 {literal}
 <script type="text/javascript">
-    cj(function($) {
+    CRM.$(function($) {
       // error handling / show hideen elements duing form validation
       $('tr[id^="Website_Block_"]' ).each( function() {
           if( $(this).find('td:first span').length > 0 ) {
index 2989bd271efadba59141db024a412ddd9af2de52..75c69d1a5144cfe8fc1246456254ae55d91918ec 100644 (file)
 {* If mid present in the url, take the required action (poping up related existing contact ..etc) *}
 {if $membershipContactID}
     {literal}
-    cj( function( ) {
+    CRM.$(function($) {
         cj( '#organization_id' ).val("{/literal}{$membershipContactName}{literal}");
         cj( '#organization_name' ).val("{/literal}{$membershipContactName}{literal}");
         cj( '#onbehalfof_id' ).val("{/literal}{$membershipContactID}{literal}");
index e6eed44c2e0ba09a49a299824c361a058623e67d..9a234f6f0bd176d8cee44d86d4d612e576ab9787 100644 (file)
     {include file="CRM/common/customData.tpl" includeWysiwygEditor=TRUE}
     <script type="text/javascript">
       {literal}
-      cj(function($) {
+      CRM.$(function($) {
         var
           $form = $("form#{/literal}{$form.formName}{literal}"),
           relationshipData = {/literal}{$relationshipData|@json_encode}{literal};
index e45933d25545114034a481361e3d301c839bab9d..21212d400daa654be7a696c492a93b34f524d19e 100644 (file)
@@ -26,7 +26,7 @@
 {* Advanced Search Criteria Fieldset *}
 {literal}
 <script type="text/javascript">
-cj(function($) {
+CRM.$(function($) {
   $().crmAccordions();
   // Bind first click of accordion header to load crm-accordion-body with snippet
   // everything else is taken care of by crmAccordions()
index 258bdfd075f911ee155da66af7fdc707f8cde4dd..a1db6135c708d6dd67312b7733c0c41bd5386b86 100644 (file)
 {/strip}
 {literal}
 <script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
    cj().crmAccordions();
 });
 </script>
index 2e68782354ec6c230d0f0810deb391999012bc22..6b32376c00d6fb75f3764d2d472b21aac002f980 100644 (file)
@@ -74,7 +74,7 @@
       {$form.group_type.html}
         {literal}
         <script type="text/javascript">
-        cj(function(){
+        CRM.$(function($) {
           function showGroupSearch(){
             cj('#grouptypeselect').hide();
             cj('#groupselect').show();
index 378443abcd27815739a9384f8bb0f48547982322..6b4b5d9924c71c9da5e8777daf1270ab6c88517f 100644 (file)
@@ -51,7 +51,7 @@
 
 {literal}
   <script type="text/javascript">
-    cj(function () {
+    CRM.$(function($) {
       updateChangeLogLabels();
     });
 
index 54955b1d3ad6779bb67135c7183a87ab592080e9..4f3c67434f368503c1454117e4d03b42b156c9b2 100644 (file)
@@ -141,7 +141,7 @@ function processAddressFields( name, loadData ) {
 
 }
 
-cj(function( ) {
+CRM.$(function($) {
   if (  cj('#street_name').val( ).length > 0 ||
         cj('#street_unit').val( ).length > 0 ||
         cj('#street_number').val( ).length > 0 ) {
index 7c9094cd0694e361a97fafcc005025999f9df52e..e4dee4517e0233a34ecf6f1adedd30edf5534136 100644 (file)
 {/if}
 {literal}
 <script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
    cj().crmAccordions();
 });
 
index e20a4ef76f6e5f7b46921193609637f2ebd5aa31..09e63bbcb6809d6b32d67adf2b869e50c7f5cecf 100644 (file)
 {/if}
 {literal}
 <script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
    cj().crmAccordions();
 });
 </script>
index b2f145ddbc243015d6ee5ba031368205a723c841..7d368b48ddad8ee8d9d3e099eed6d547a53dae95 100644 (file)
 {/if}
 {literal}
 <script type="text/javascript">
cj(function() {
CRM.$(function($) {
     cj().crmAccordions();
  });
 </script>
index 66d7968a0dcc393e84be5c8af3fcef4e2f2e9707..72f710ca40d48e59eeaf751a5804569f8c91105a 100644 (file)
 {/if}
 {literal}
 <script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
    cj().crmAccordions();
 });
 </script>
index 264098614f3870a5000b3179ce71eac74127ef4c..bb2c561830e32603caf212cafdf016f31736a078 100644 (file)
 {/strip}
 {literal}
 <script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
    cj().crmAccordions();
 });
 </script>
index 9cd5204ff0c33fc17f5274fdb51a5690e5b6d6b6..70eb60ae7cbdd284486c85f514206170b84e37e3 100644 (file)
 {/if}
 {literal}
 <script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
    cj().crmAccordions();
 });
 </script>
index e071650e1f0633bbe4f47e9b789bce44b444b34d..c6f98118680ea72fdb4a1d3033989fe16524c52f 100644 (file)
@@ -94,7 +94,7 @@
 
 {literal}
 <script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
   toggleTaskAction( );
 });
 </script>
index 814b205d1901b569cca2a28380f4ba299dec3f82..a628a5c9cbea8baffcb6413446ce885cc605f168 100644 (file)
 
 <script type="text/javascript">
   {literal}
-  cj(function($) {
+  CRM.$(function($) {
     cj("#toggleSelect, input[id^=mark_x_]").prop('checked', false);
     var cids = [];
     var i = 0;
index a0f87e4c6680c651ac90a0fb598964e724669bd3..19358ad2c823adc17bf76127c247d8e5f5c933c3 100644 (file)
@@ -72,7 +72,7 @@
     }
   }
 
-cj( function( ) {
+CRM.$(function($) {
     var blockNo = {/literal}{$blockId}{literal};
 
     // call this when form loads
index e385fca50b3553b74885cd2e6bb5d845ac247641..6a105d20fa1f9b4d1aa3c22947409ffd976561fb 100644 (file)
@@ -50,7 +50,7 @@
 {if $searchtype eq 'ts_sel'}
 {literal}
 <script type="text/javascript">
-  cj(function($) {
+  CRM.$(function($) {
     $("#popupContainer").css({
       "background-color":"#E0E0E0",
       'display':'none',
index d58d7e990f62f150cf637711f2efdeca834673fd..b2ae29ba461aac7b19da6409118640da8998871c 100644 (file)
@@ -1,4 +1,4 @@
-cj(function ($) {
+CRM.$(function($) {
   //do not copy & paste this - find a way to generalise it
   'use strict';
    $().crmAccordions();
index 0ae4cc2c8ecbc83981266c808db01c2228b53f0b..7cf5bcde4133bdbd3327b745244934b3df524a82 100644 (file)
 
 {literal}
 <script type="text/javascript">
-cj(function($) {
+CRM.$(function($) {
   var $form = $('form#{/literal}{$form.formName}{literal}');
   $('#format_id', $form).on('change', function() {
     selectFormat($(this).val());
index 1bb19e0267f7599c86b01c339e07cb41c92b476e..6114e7b152a35e8dd07d4c4760476a709a9fbeb7 100644 (file)
@@ -57,7 +57,7 @@
 {include file="CRM/Mailing/Form/InsertTokens.tpl"}
 {literal}
 <script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
    cj().crmAccordions();
 });
 
index 43f1a1b94480ce7c887a45f92ac088427e4e0c56..799b5742a8bd6d440b95d96d66de30c9fd2ef105 100644 (file)
 
       {* // Set default location type *}
       {literal}
-      cj(function() {
+      CRM.$(function($) {
         var defaultLocationType = "{/literal}{$defaultLocationType}{literal}";
         if (defaultLocationType.length) {
           cj('#map-field').on('change', 'select[id^="mapper"][id$="_0"]', function() {
index 894d0390139484e0320a98926a2d72e8d163b9f8..f515df4004e6c9a8a640086410088e3fc32e3647 100644 (file)
@@ -228,7 +228,7 @@ function verify( ) {
 
 {literal}
 <script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
    cj().crmAccordions();
 });
 
index d1acaebc61d2dc1ceac4445e581328514a447aeb..a7d7cbf8b2c085595e06f3f8ba12f748c818ab7b 100644 (file)
@@ -92,7 +92,7 @@
 <div class="clear"></div>
 {literal}
 <script type="text/javascript">
-  cj(function($) {
+  CRM.$(function($) {
     $('#crm-dashboard-configure').click(function() {
       $.ajax({
          url: CRM.url('civicrm/dashlet', 'reset=1&snippet=1'),
index f08b9aedb758b241cb2c1ae343db05acbf472fa4..216edee77bd45b08ae9015db58670fd8a6ab19c6 100644 (file)
@@ -59,7 +59,7 @@
 
 {literal}
 <script type="text/javascript">
-  cj(function() {
+  CRM.$(function($) {
       var currentReSortEvent;
     cj(".dash-column").sortable({
       connectWith: '.dash-column',
index d43f042b629f3ae9b1b0760a7ead1a7ac4c9cb82..9cc96d3f9c6a3cc1d9a4da4969bb2e417c3ddcfe 100644 (file)
 
 {literal}
 <script type="text/javascript">
-  cj(function($) {
+  CRM.$(function($) {
     // load panes function calls for snippet based on id of crm-accordion-header
     function loadPanes() {
       var id = $(this).attr('id');
index 58c74b9fbf8800f82975e9be50b7313532c7e362..e3656ce66aa4080a8f8242372ab18219fe55497a 100644 (file)
@@ -55,7 +55,7 @@
 {if $useLogging}
 {literal}
   <script type="text/javascript">
-  cj(function ($) {
+  CRM.$(function($) {
     $('#changeLog .instance_data').on('crmLoad', function(e, data) {
       CRM.tabHeader.updateCount('#tab_log', data.totalRows);
     });
index 1f21d5f2f21358d6b68bc6cfd3fe99ec44d0a384..40b31ff166b725a20f927a474a8af3fd3ecf3af5 100644 (file)
@@ -47,7 +47,7 @@
 <script type="text/javascript">
   var {/literal}{$context}{literal}oTable;
 
-  cj(function () {
+  CRM.$(function($) {
     buildContactRelationships{/literal}{$context}{literal}();
   });
 
index a74171b0c0fce9dcef8e9659e3f26cf004c5c747..09732b141d8500ee20dcf5432b5d14de64c23857 100644 (file)
 {* CRM-10560 *}
 {literal}
 <script type="text/javascript">
-cj(function($) {
+CRM.$(function($) {
   $('.crm-inline-edit-container').crmFormContactLock({
     ignoreLabel: "{/literal}{ts escape='js'}Ignore{/ts}{literal}",
     saveAnywayLabel: "{/literal}{ts escape='js'}Save Anyway{/ts}{literal}",
index 0a22ee6abae99a8776f5f28c024ae7840f19c896..ba345d52b9fcf637649ec7c73400be4cca532002 100644 (file)
@@ -74,7 +74,7 @@
        eval( 'cj( "#recurringPaymentBlock" ).' + funName + "( )" );
    }
 
-   cj( function() {
+   CRM.$(function($) {
        buildRecurBlock( null );
        enablePeriod( );
    });
index 76aea8417c16ced792520099b1669d4340b6cb25..1004450c26620e25e5fe464243346275926c2e54 100644 (file)
 
     var url = "{/literal}{$dataUrl}{literal}";
 
-      cj( function( ) {
+      CRM.$(function($) {
         showHideByValue( 'is_email_receipt', '', 'notice', 'table-row', 'radio', false );
         showHideByValue( 'is_email_receipt', '', 'fromEmail', 'table-row', 'radio', false );
       });
 
     {literal}
     <script type="text/javascript">
-      cj( function( ) {
+      CRM.$(function($) {
         checkEmailDependancies( );
         cj('#is_email_receipt').click( function( ) {
           checkEmailDependancies( );
 
     // bind first click of accordion header to load crm-accordion-body with snippet
     // everything else taken care of by cj().crm-accordions()
-    cj(function() {
+    CRM.$(function($) {
       cj('#adjust-option-type').hide();
       cj('.crm-ajax-accordion .crm-accordion-header').one('click', function() {
         loadPanes(cj(this).attr('id'));
@@ -290,7 +290,7 @@ cj('#fee_amount').change( function() {
 {/if}
 {literal}
 <script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
   cj().crmAccordions();
 });
 </script>
index a1be20b8a48756839827c52a54dd1be08bcb3fcc..79f05effbfe6881349539d0e771ddd0d4ae6a3e9 100644 (file)
 
     {literal}
     <script type="text/javascript">
-      cj( function( ) {
+      CRM.$(function($) {
     {/literal}
     CRM.buildCustomData( '{$customDataType}' );
     {if $customDataSubType}
 
     // bind first click of accordion header to load crm-accordion-body with snippet
     // everything else taken care of by cj().crm-accordions()
-    cj(function() {
+    CRM.$(function($) {
       cj('#adjust-option-type').hide();
       cj('.crm-ajax-accordion .crm-accordion-header').one('click', function() {
         loadPanes(cj(this).attr('id'));
   {/literal}
     {if $context eq 'standalone' and $outBound_option != 2 }
       {literal}
-      cj( function( ) {
+      CRM.$(function($) {
         cj("#contact_1").blur( function( ) {
           checkEmail( );
         });
   {if $action neq 8}
     {literal}
     <script type="text/javascript">
-      cj( function( ) {
+      CRM.$(function($) {
         checkEmailDependancies( );
         cj('#is_email_receipt').click( function( ) {
           checkEmailDependancies( );
       }
 
     {/literal}{if !$contributionMode}{literal}
-     cj( function( ) {
+     CRM.$(function($) {
       showHideCancelInfo(cj('#contribution_status_id'));
 
       cj('#contribution_status_id').change(function() {
 
 {literal}
 <script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
   cj().crmAccordions();
 });
 
index 11d9cd5608a5a9932d778918b65a0bb8e721453d..f7a4add18fe19b399309aa3a0d2fc5596b1ca1d7 100644 (file)
     toggleConfirmButton();
   });
 
-  cj(function() {
+  CRM.$(function($) {
     toggleConfirmButton();
   });
 
     }
   }
 
-  cj(function(){
+  CRM.$(function($) {
     // highlight price sets
     function updatePriceSetHighlight() {
       cj('#priceset .price-set-row').removeClass('highlight');
index d9aa6988c64b3d46273017aa517022b48000ff24..feb71e9af2346311dc467139361ed9ec07b0339a 100644 (file)
@@ -91,7 +91,7 @@
 </div>
 {literal}
 <script type="text/javascript">
-cj(function(){
+CRM.$(function($) {
     //if price set is set we use below below code to show for showing auto renew
     var autoRenewOption =  {/literal}'{$autoRenewOption}'{literal};
     cj('#allow_auto_renew').hide();
@@ -240,7 +240,7 @@ cj(function(){
 {if $membershipBlock AND $quickConfig}
 {literal}
 <script type="text/javascript">
-cj(function(){
+CRM.$(function($) {
     showHideAutoRenew( null );
 });
 function showHideAutoRenew( memTypeId )
@@ -291,7 +291,7 @@ function showHideAutoRenew( memTypeId )
 }
 
 {/literal}{if $allowAutoRenewMembership}{literal}
-  cj( function( ) {
+  CRM.$(function($) {
      //keep read only always checked.
      cj( "#auto_renew" ).click(function( ) {
         if ( cj(this).attr( 'readonly' ) ) {
index f24ef79088914859f03b50ab88ff80fc76374630..233ecdd5416241170e4226380dd2eb768c8c4bf2 100644 (file)
@@ -297,7 +297,7 @@ function selectCreateOrg( orgOption, reset ) {
 {* If mid present in the url, take the required action (poping up related existing contact ..etc) *}
 {if $membershipContactID}
 {literal}
-  cj( function( ) {
+  CRM.$(function($) {
     cj('#organization_id').val("{/literal}{$membershipContactName}{literal}");
     cj('#organization_name').val("{/literal}{$membershipContactName}{literal}");
     cj('#onbehalfof_id').val("{/literal}{$membershipContactID}{literal}");
index 7913197c7b1bc229768cf20d327d2b6a850fe187..96f5c6bcac1de08f33ef0814692bc7ea00ce1929 100644 (file)
   {if $context EQ "makeContribution"}
     {literal}
     <script>
-      cj(function($){
+      CRM.$(function($) {
         var is_separate_payment = {/literal}{if $membershipBlock.is_separate_payment}{$membershipBlock.is_separate_payment}{else}0{/if}{literal};
 
         // select a new premium
   {else}
     {literal}
     <script>
-      cj(function(){
+      CRM.$(function($) {
         cj('.premium-short').hide();
         cj('.premium-full').show();
       });
index c69965a7be44883925fd7b7fddd38427d00a5ce2..e6a721df35673f015897d470f2bc403ace5adac2 100644 (file)
@@ -60,7 +60,7 @@
 {literal}
 <script type="text/javascript">
 
-  cj( function( ) {
+  CRM.$(function($) {
       buildChart( );
   });
 
index 9335f9a58123e7822f623a02ac15c9b31aef5aa2..917e3fde1ecdb02dc72d25b7bfa6f029d770a9c1 100644 (file)
      cj('#amountFields').hide();
   }
 
-  cj(function() {
+  CRM.$(function($) {
     payLater('is_pay_later');
   });
 
index a1fab0de7cc20446a9e4b85dfacbc0485c4d80fb..f386064e915a5928e36a07d6b0655a64fcc78030 100644 (file)
 
 <script type="text/javascript">
   {literal}
-  cj(function () {
+  CRM.$(function($) {
     cj().crmAccordions();
 
     // bind click event to premiums_active checkbox
index 584023a8fa25362b40094172daf3b3ef2f0a2455..26a8d45030b423c682073b47fe059cfe1bf8ba2b 100644 (file)
 
 {literal}
 <script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
    cj().crmAccordions();
 });
 </script>
index 983f993d193bb48ba2f078ec433e8d0438ac006f..5f10bdcd68112f899d4e329f260a6e37d127510f 100644 (file)
@@ -92,7 +92,7 @@
 {/if}
 {literal}
 <script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
    cj().crmAccordions();
 });
 </script>
index b46baafc56a4ef7a661bf409861d3be69856b8dc..43ba52e2ca1b7b6f7cfd22b2b8d9855d5cb35685 100644 (file)
@@ -66,7 +66,7 @@
 {/if}
 {literal}
 <script type="text/javascript">
-  cj(function($) {
+  CRM.$(function($) {
     var $form = $("#{/literal}{$form.formName}{literal}");
     $('#showPCP, #showSoftCredit').click(function(){
       return showHideSoftCreditAndPCP();
index 120c700c69bd17648d82bf3407f26fa9f972d5ad..b56013ecdf43faa54619e143f0f789dd2ba8185f 100644 (file)
@@ -1,7 +1,7 @@
 // http://civicrm.org/licensing
 /*jslint indent: 2 */
 /*global CRM, cj */
-cj(function ($) {
+CRM.$(function($) {
   'use strict';
 
   var load = {
index 27e172a92c42671abc1490c5ae5b4166d074a168..64bb4ec418851cbc7a44481fdad62514a3782598 100644 (file)
@@ -26,7 +26,7 @@
 {if $show eq 'event-payment'}
 {literal}
 <script type='text/javascript'>
-cj(function($){
+CRM.$(function($) {
   if (cj("#payment-info").length) {
     var dataUrl = {/literal}'{crmURL p="civicrm/payment/view" h=0 q="action=browse&id=$participantId&cid=`$contactId`&component=event&context=payment_info&snippet=4"}'{literal};
     cj.ajax({
index ac08b2bb356033635696e6676b946b962a9b25d5..191908f4e5f2be7647c6335d517ca8caed9cf93c 100644 (file)
@@ -63,7 +63,7 @@ function APIDoc(entity){
 }
 
 
-cj(function ($) {
+CRM.$(function($) {
     $('h2.entity').click ( function(){APIDoc($(this).attr('id'))} ); 
     entity=window.location.hash;
     if (entity.substring(0, 1) === '#') {
index a072075065d4c8a2b95f4364c0b642469a04aceb..1110e5ece5c3d2e7214758d852a86a948b5aa62e 100644 (file)
@@ -13,7 +13,7 @@ code {line-height:1em;}
 <script>
 {literal}
 
-cj(function($) {
+CRM.$(function($) {
   var restURL = CRM.url("civicrm/ajax/rest");
 
   function toggleField (name, label, type) {
index c78932b1a30b7d8b937f76d716c05bb185b02074..abe4376dfd79d2366cd63862c87ebb484cc20a57 100644 (file)
@@ -79,4 +79,4 @@
   $(function() {
     $('#billing-payment-block').on('crmFormLoad', civicrm_billingblock_creditcard_helper);
   });
-})(cj);
+})(CRM.$);
index d6b48e1ae052f587281a04fca7f32b87f4d94950..85a4efe456234221f0262fe4d7b9c11caf711bc3 100644 (file)
      <script type="text/javascript">
      {literal}
 
-cj( function( ) {
+CRM.$(function($) {
   // build list of ids to track changes on
   var address_fields = {/literal}{$profileAddressFields|@json_encode}{literal};
   var input_ids = {};
index c85e8a1459b2079a0c7abdb3138bda44b57ce91b..4a25f4e984efa9595fd772c7e525f809ad22211a 100644 (file)
@@ -25,7 +25,7 @@
 *}
 {literal}
 <script type="text/javascript">
-cj( function( ) {
+CRM.$(function($) {
     var url       = "{/literal}{$customUrls.$element_name}{literal}";
     var custom    = "{/literal}#{$element_name|replace:']':''|replace:'[':'_'}{literal}";
     var custom_id = "{/literal}input[name=\"{$element_name|cat:'_id'|regex_replace:'/\]_id$/':'_id]'}\"]{literal}";
index 55bb4b1b402378b3ffdf6c1512215a07a1a242f9..a9fd459b5bd5e3724b7674f7d4905737e89bdb90 100644 (file)
@@ -94,7 +94,7 @@
   {/foreach}
   <script type="text/javascript">
     {literal}
-      cj(function() {
+      CRM.$(function($) {
         cj().crmAccordions();
       });
     {/literal}
index e83c6a8215521ebe8c04601653b40ab71970f5ec..4697876fe2d26de645ef403bdfae579473bcdf78 100644 (file)
@@ -85,7 +85,7 @@
 {$initHideBlocks}
 {literal}
 <script type="text/Javascript">
-cj(function($) {
+CRM.$(function($) {
 
   showHideStyle();
   cj('#extends_0').change(function() {
index d74ce3a3cce6c2a6c88d4d0c4fc80e99ed55109b..db3e48e375a3724b2e398b06bc1104fe2c5445c1 100644 (file)
 {/foreach}
 {literal}
   <script type="text/javascript">
-    cj(function () {
+    CRM.$(function($) {
       cj().crmAccordions();
     });
   </script>
index ea5b05a5e87d4ec09c40f9a654daea71950cf1b0..24dc555c03790b4fde0c6149c538778e76edf055 100644 (file)
 {if $context eq 'standalone' and $outBound_option != 2 }
 <script type="text/javascript">
 {literal}
-cj( function( ) {
+CRM.$(function($) {
     cj("#contact_1").blur( function( ) {
         checkEmail( );
     } );
index 482eaa4eaa635bb526ce8b28e9cb320bf7aaad65..1e5dae1226439becc65987a8d8dc851fc10a9034 100644 (file)
 </div>
 {literal}
 <script type="text/javascript">
-  cj(function($) {
+  CRM.$(function($) {
     $('#template_id', '#EventInfo').change(function() {
       $('#crm-main-content-wrapper')
         .crmSnippet({url: CRM.url('civicrm/event/add', {action: 'add', reset: 1, template_id: $(this).val()})})
index 0c09689973380a2dd810f185b5236079c86f3edc..4578f064db754fb87a5441de334c29c9e9aecd2b 100644 (file)
             {if $discountSection eq 2}
                 <script type="text/javascript">
                 {literal}
-                    cj( function() {
+                    CRM.$(function($) {
                         cj('#discounted_label_1').focus( );
                     });
                 {/literal}
index 5aacdf529b3cd3a8e85e2d006cecd2275c6abb37..ed4d80c2d8019f7d7f283df6079305672d24b5c7 100644 (file)
@@ -425,7 +425,7 @@ invert              = 0
     }
 
     //show edit profile field links
-    cj(function() {
+    CRM.$(function($) {
         // show edit for main profile
         cj(document).on('change', 'select[id^="custom_p"]', function( event ) {
             buildLinks( cj(this), cj(this).val());
index e9b6fef3fe8d7653adfd0c7b3a7eda903110296c..bb366944f6ea355e5cb6f311e8c7ed2f673e6407 100755 (executable)
 
   {literal}
     <script type='text/javascript'>
-      cj(function() {
+      CRM.$(function($) {
         populateRecipient();
         cj('#recipient').click( function( ) {
           populateRecipient();
index 5f9232e5e32cfe714450bb4f60825d6197175aa9..b148863b4f447df562ad1e2f9e08883f628cdcb3 100644 (file)
@@ -75,7 +75,7 @@
 
 {literal}
 <script>
-cj(function($) {
+CRM.$(function($) {
   $('body').click(function() {
     $('#crm-event-links-list, #crm-participant-list').hide();
   });
index def9258e3e17e08d458c15025d28d0caeda0dd21..4e085d14b5a29c93956f5f733e6dd56864cdb1a3 100644 (file)
@@ -49,7 +49,7 @@
     {literal}
 
     if ( fieldOptionsFull.length > 0 ) {
-      cj(function() {
+      CRM.$(function($) {
         cj("input,#priceset select,#priceset").each(function () {
           if ( cj(this).attr('price') ) {
             switch( cj(this).attr('type') ) {
 
     <script type="text/javascript">
       {literal}
-      cj(function($) {
+      CRM.$(function($) {
 
         var $form = $('form#{/literal}{$form.formName}{literal}');
 
     {/literal}
   {/if}
   {literal}
-  cj(function() {
+  CRM.$(function($) {
     cj().crmAccordions();
   });
   {/literal}
index 498b077d2e04438e5af2d5713b2672d202ef5228..59b7e09447effdaecf51840c2ed36f82f3788400 100644 (file)
@@ -67,7 +67,7 @@ function populatebalanceFee(updatedAmt) {
   cj('#balance-fee').text(symbol+" "+balanceAmt);
 }
 
-cj(function(){
+CRM.$(function($) {
   // assign statuses
   var partiallyPaid = {/literal}{$partiallyPaid}{literal};
   var pendingRefund = {/literal}{$pendingRefund}{literal};
@@ -193,7 +193,7 @@ cj(function(){
 {/if}
 {literal}
 <script type='text/javascript'>
-cj(function($){
+CRM.$(function($) {
   cj('.total_amount-section').remove(); 
 
   cj('#ParticipantFeeSelection').submit(function(e) {
index bbf5440dabf48e28dd7ec9aef099c83ea1f64ba9..8cefbaaa47eb0f59fcc54938b812552ddcd0ebfd 100644 (file)
       toggleConfirmButton();
     });
 
-    cj(function () {
+    CRM.$(function($) {
       toggleConfirmButton();
       skipPaymentMethod();
     });
index f15da6ef920bb464ecba21c24ff33889b74168e8..8b5c0f54fd38edc92f57024dff6b7e3183d89b42 100644 (file)
@@ -79,7 +79,7 @@
 {/if}
 {literal}
 <script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
    cj().crmAccordions();
 });
 </script>
index 5e8aa5563c04f77d696b063e2c69e18bd6a3e036..ca93d528f50aa73b3442581fad566282fdbfb56d 100644 (file)
@@ -89,7 +89,7 @@ campaignTrClass='' campaignTdClass='crm-event-form-block-participant_campaign_id
 
 {literal}
 <script type="text/javascript">
-cj(function($) {
+CRM.$(function($) {
   // FIXME: This could be much simpler as an entityRef field but the priceFieldValue api doesn't currently support the filters we need
   $('#participant_fee_id').select2({
     placeholder: {/literal}'{ts escape="js"}- any -{/ts}'{literal},
index 925c934298a1987c4b8e5fb98a0e1557d5353d57..daa9633093e7e0738a4a41d2666068af31bba714 100644 (file)
@@ -92,7 +92,7 @@
 /**
  * Function to update participant status
  */
-cj( function(){
+CRM.$(function($) {
    cj('#status_change').change( function() {
       if ( cj(this).val() ) {
         cj('.crm-copy-fields [name^="field["][name*="[participant_status]"]').val( cj(this).val() );
index 78864887497ce30cdabcf7fea6c1afc81b17dffa..293e15f53158e72b24e8661f1c03b471bf1b55ee 100644 (file)
@@ -89,7 +89,7 @@
 
 {literal}
 <script type="text/javascript">
-cj( function() {
+CRM.$(function($) {
   cj().crmAccordions();
   cj('#_qf_BatchTransaction_submit-top, #_qf_BatchTransaction_submit-botttom').click(function() {
     cj('.crm-batch_transaction_search-accordion:not(.collapsed)').crmAccordionToggle();
index 0cec90182cbe5e5f150ad6a8f05b6b239c606c69..1368a541ad3479e17c8acea4116ca90b4500982d 100644 (file)
@@ -52,7 +52,7 @@
 </div>
 {literal}
 <script type="text/javascript">
-  cj(function(){
+  CRM.$(function($) {
     cj('input[name="export_format"]').filter('[value=IIF]').prop('checked', true);
     cj('#_qf_Export_next').click(function(){
       cj(this).hide();
index 3c7db2ad87ad9db0bbbd1bc9cbdd710018f0c713..8aa74cd7c8c020bc30293a1b86f4c52ed0e3bb21 100644 (file)
@@ -94,7 +94,7 @@
 {include file="CRM/Form/validate.tpl"}
 {literal}
 <script type="text/javascript">
-cj(function($){
+CRM.$(function($) {
   $().crmAccordions();
 });
 </script>
index 002c6863f90d4a825c7a80afbea656994087d714..5b6ff9a0d7c70a9542eccc262c4a9badbf652112 100644 (file)
@@ -67,7 +67,7 @@
 {include file="CRM/Form/validate.tpl"}
 {literal}
 <script type="text/javascript">
-cj(function($) {
+CRM.$(function($) {
   var batchSelector;
   buildBatchSelector();
   $("#batch_update").prop('disabled', false);
index 9022e8f55928d6168551c0541dedb64ef4d1a7ac..92d1db1f970752a60f141f5a64d224bb1a02cae3 100644 (file)
@@ -76,7 +76,7 @@
 
 {literal}
 <script type="text/javascript">
-cj( function() {
+CRM.$(function($) {
   var entityID = {/literal}{$entityID}{literal};
   batchSummary(entityID);
   cj('#close_batch').click( function() {
index c0f5becce855118439e37a7f4fda4c3858c96798..ecd119c93be4aa7a4eafcdddbdf0612d8dd7e78e 100644 (file)
   {if !$noexpand}
     {literal}
     <script type="text/javascript">
-    cj(function() {
+    CRM.$(function($) {
        cj().crmAccordions();
     });
     </script>
index 75345c5813f456bf1774b7ba36673d0e04a9158e..f626b779cecdd97cd385c178b49ec328b5482095 100644 (file)
@@ -1,6 +1,6 @@
 <script type="text/javascript">
 {literal}
-  cj(function($) {
+  CRM.$(function($) {
     $('a.delete-attachment').click(function() {
       var $el = $(this),
         $row = $el.closest('.crm-attachment-wrapper'),
index 808d209f011e374e6919141546cebd3310f678ca..502482b875a61c66779b4f930eed395e80ad0fcf 100644 (file)
@@ -32,7 +32,7 @@
 
 {literal}
 <script type="text/javascript" >
-cj(function($) {
+CRM.$(function($) {
   var messages = {{/literal}
         required: "{ts escape='js'}This field is required.{/ts}",
         remote: "{ts escape='js'}Please fix this field.{/ts}",
index d0162068d4aee478b16c6a77c220c1a2afcd191e..8dab641e1ced49d005f738ba1c0d7c650dc278d1 100644 (file)
 
 {literal}
 <script type="text/javascript">
-    cj( function( ) {
+    CRM.$(function($) {
         {/literal}
         CRM.buildCustomData( '{$customDataType}' );
         {if $customDataSubType}
         {literal}
     });
 
-    cj(function() {
+    CRM.$(function($) {
        cj().crmAccordions();
     });
 </script>
index 511f316b100eef7e2b481cb4146529db7d3f46c5..b2436d142b83827bfb3a451061060fa82e03ed08 100644 (file)
@@ -72,7 +72,7 @@
 </div><!-- /.crm-content-block -->
 {literal}
 <script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
    cj().crmAccordions();
 });
 </script>
index 312cc231dac3c0fa691d6052951717054aab685f..1fe66e4672c43c13dd1f14f355be909305cce8ba 100644 (file)
@@ -91,7 +91,7 @@
 
 {literal}
 <script type="text/javascript">
-cj(function($) {
+CRM.$(function($) {
   // for CRM-11310 and CRM-10635 : processing just parent groups on initial display
   // passing '1' for parentsOnlyArg to show parent child heirarchy structure display
   // on initial load of manage group page and
index c6459e7b40429d2bc38b741a2ccea60edd68aa21..0a554f0cf88005e70d392a0e97bd50f22545b1d8 100644 (file)
@@ -61,7 +61,7 @@
 
 {literal}
 <script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
    cj().crmAccordions();
 });
 </script>
index d19a35fa5618f6f362bd3bbf7dd23d1e3bcdc217..4be3523f5fdab6f983c249f781f8604076850263 100644 (file)
@@ -63,7 +63,7 @@ cj("#button").click(function(){
      });
   });
 
-    cj( function( ) {
+    CRM.$(function($) {
         var count = 0; var columns=''; var sortColumn = '';
 
         cj('#selectedRecords th').each( function( ) {
index b1b9e751fce6a9d7433f7a9b8d13f01bad7d227e..6b19195da3e4bbdfc63eb68597082a603fe843f0 100644 (file)
@@ -79,7 +79,7 @@
 
 {literal}
 <script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
    cj().crmAccordions();
 });
 </script>
index 7cdb1ef592135ef3753887a6195eb90e70c4a348..2e860121789842f534957751f4b860927f141b4d 100644 (file)
@@ -242,7 +242,7 @@ if ( isMailing ) {
   {/literal}
   {if $editor eq "ckeditor"}
   {literal}
-    cj( function() {
+    CRM.$(function($) {
       oEditor = CKEDITOR.instances['html_message'];
       oEditor.BaseHref = '' ;
       oEditor.UserFilesPath = '' ;
@@ -251,7 +251,7 @@ if ( isMailing ) {
   {/literal}
   {elseif $editor eq "tinymce"}
   {literal}
-    cj( function( ) {
+    CRM.$(function($) {
       if ( isMailing ) {
         cj('div.html').hover(
           function( ) {
@@ -274,7 +274,7 @@ if ( isMailing ) {
   {/literal}
   {elseif $editor eq "drupalwysiwyg"}
   {literal}
-    cj( function( ) {
+    CRM.$(function($) {
       if ( isMailing ) {
         cj('div.html').hover(
           verify,
@@ -287,7 +287,7 @@ if ( isMailing ) {
   {literal}
 }
 
-cj(function($) {
+CRM.$(function($) {
   function insertToken() {
     var
       token = $(this).val(),
index 3688ed67f7232433a9412e400705b25fe7b67d27..194856ae230da6b4be78ef2e3768eaf4f7726edc 100644 (file)
 <script type="text/javascript">
 {if $preview}
 {literal}
-cj(function() {
+CRM.$(function($) {
    cj().crmAccordions();
 });
 {/literal}
 {/if}
 
 {literal}
-cj(function() {
+CRM.$(function($) {
    cj('#start_date_display').change( function( ) {
        if ( cj(this).val( ) ) {
           cj('#now').prop('checked', false );
index edcb72e73d129e09d1f37999ef28966bcff0b86c..21f8abc5835b4cd84d0b0c430fe20847f3c65c15 100644 (file)
@@ -27,7 +27,7 @@
 <script  type="text/javascript">
 {literal}
 
-cj( function($) {
+CRM.$(function($) {
   // hide all the selects that contains only one option
   cj('.crm-message-select select').each(function (){
     if (cj(this).find('option').size() == 1) {
index d80b573eb27a2098bbeeb42bfe885be672e649c9..1c534a497f9582e361ef40ca604b0accb520d86a 100644 (file)
@@ -69,7 +69,7 @@
 {include file="CRM/common/formNavigate.tpl"}
 {literal}
 <script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
    cj().crmAccordions(); 
 });
 </script>
index 9b2e9a331a0808bd29d7a35b79ef928d81e29ca2..d22463560dd374e5446ba96933432905e8ccc304 100644 (file)
@@ -71,7 +71,7 @@
 {literal}
   <script type="text/javascript">
     var totalPages = {/literal}{$pager->_totalPages}{literal};
-    cj(function () {
+    CRM.$(function($) {
       cj("#crm-container .crm-pager input.form-submit").click(function () {
         submitPagerData(this);
       });
index bc383efd9738fbb29378b289a92e1342ba4f2c5f..667e889d7b6af52fdde622d3a73423232598d858 100644 (file)
@@ -40,7 +40,7 @@
 </div>
 {literal}
 <script type="text/javascript">
-  cj(function($) {
+  CRM.$(function($) {
     var oTable;
 
     buildMailingContact();
index ca5920542a6bdc5b07fda9ce13d5f455b1297650..042393167e3301344e389afaa6e43c4b45e43f0b 100644 (file)
@@ -1,4 +1,4 @@
-cj(function($) {
+CRM.$(function($) {
   checkExistingMemOrg();
 
   $("select[name='membership_type_id[0]']").change( checkExistingMemOrg );
index d06801e0ad6d5e6102d63f2d513d411098db8223..1a44e9da8f5edf6c713e4035029550e05c608dd9 100644 (file)
@@ -37,7 +37,7 @@
   {include file="CRM/Price/Form/PriceSet.tpl" context="standalone" extends="Membership"}
   {literal}
   <script type="text/javascript">
-  cj( function() {
+  CRM.$(function($) {
     var membershipValues = new Array;
     {/literal}{foreach from=$optionsMembershipTypes item=memType key=opId}{literal}
       membershipValues[{/literal}{$opId}{literal}] = {/literal}{$memType}{literal};
       {include file="CRM/common/customData.tpl"}
       {literal}
       <script type="text/javascript">
-      cj(function() {
+      CRM.$(function($) {
       {/literal}
         CRM.buildCustomData( '{$customDataType}' );
         {if $customDataSubType}
       }
 
 
-      cj( function( ) {
+      CRM.$(function($) {
       var mode   = {/literal}'{$membershipMode}'{literal};
       if ( !mode ) {
         // Offline form (mode = false) has the record_contribution checkbox
 
     {if $context eq 'standalone' and $outBound_option != 2 }
     {literal}
-    cj( function( ) {
+    CRM.$(function($) {
       cj("#contact_1").blur( function( ) {
         checkEmail( );
       } );
 
     {literal}
     //keep read only always checked.
-    cj( function( ) {
+    CRM.$(function($) {
       var allowAutoRenew   = {/literal}'{$allowAutoRenew}'{literal};
       var alreadyAutoRenew = {/literal}'{$alreadyAutoRenew}'{literal};
       if ( allowAutoRenew || alreadyAutoRenew ) {
index 11db8dec94fbc2dc66f11f73d5ade7bf7cadcd16..444a971f8ac0e67adb3b5f0c6daf2df369e58905 100644 (file)
 
 {literal}
 <script type="text/javascript">
-    cj( function() {
+    CRM.$(function($) {
         //show/hide membership block
         showHideMembershipBlock();
         cj('#member_is_active').click( function() {
index b212f62903c9b3174e8a8111172fcf29e249f450..17b220ae30170b6c013db5719318808fbd5324fa 100644 (file)
   {/if}
 {literal}
   <script type="text/javascript">
-    cj(function () {
+    CRM.$(function($) {
       cj('#membershipOrgType').hide();
       cj('#changeNumTerms').hide();
       {/literal}
       cj('#defaultNumTerms').hide();
     }
 
-    cj(function () {
+    CRM.$(function($) {
       cj('#record_contribution').click(function () {
         if (cj(this).prop('checked')) {
           cj('#recordContribution').show();
index b2a03d765e1b483b99f4cbddf7b13caa3810790c..63c9a16ee9463e7ded49768b99087637626b8bd0 100644 (file)
@@ -1,4 +1,4 @@
-cj(function($) {
+CRM.$(function($) {
   memberResults = new Array;
   $("input[name='contact[1]']").result( function() {
     var contact_id = cj("input[name='contact_select_id[1]']").val();
index 9558a9ffab651126f2398956f62d35f851759abe..f8d80fe46edf5d51d1ab37a7ba3d5060b34599a3 100644 (file)
 
 {literal}
 <script type="text/javascript">
-cj(function(){
+CRM.$(function($) {
   showHidePeriodSettings();
   cj('#duration_unit').change(function(){
     showHidePeriodSettings();
@@ -217,7 +217,7 @@ function showHidePeriodSettings() {
 
 //load the auto renew msg if recur allow.
 {/literal}{if $authorize and $allowAutoRenewMsg}{literal}
-cj( function(){
+CRM.$(function($) {
   setReminder( null );
 });
 {/literal}{/if}{literal}
index 6d90a3877558bddf4741b08f74da64707f664731..76338d461ff0e0c174d741e9c81eefca69022f3d 100644 (file)
@@ -73,7 +73,7 @@
 </div>
 {literal}
 <script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
    cj().crmAccordions();
 });
 </script>
index e5f6a3a0a8ddaf3b623d3f7e66304bfd5d167cc3..a5a3f4c398203268779d97044960de2265b244cb 100644 (file)
@@ -1,4 +1,4 @@
-cj(function ($) {
+CRM.$(function($) {
   'use strict';
   $('#per_membership').click(function() {
     if($(this).is(":checked")) {
index 832901ef1b01c9e2d1da54cdd37e01550ccc3ed7..1837f7d304770d03af0e15bf012cd65ccbeff484 100644 (file)
@@ -202,7 +202,7 @@ function loadPanes( id ) {
 </div>
 {literal}
 <script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
    cj().crmAccordions();
 });
 </script>
@@ -251,7 +251,7 @@ cj(function() {
     {/literal}
     {if $context eq 'standalone' and $outBound_option != 2 }
     {literal}
-    cj( function( ) {
+    CRM.$(function($) {
         cj("#contact_1").blur( function( ) {
             checkEmail( );
         });
index 1ac3edba2c4139b3bcdc69b32d3a888a404880bc..8f208fa020ecb0b24a69c18adcfe9cb43eff074d 100644 (file)
@@ -81,7 +81,7 @@
 {/if}
 {literal}
 <script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
    cj().crmAccordions();
 });
 </script>
index cbf923e3b7d137d886ae64eb3f8a670a8bfa22de..8735b8994dccb445e31dcdc434c651f695c05737 100644 (file)
 
     {literal}
       <script type="text/javascript">
-        cj(function() {
+        CRM.$(function($) {
           cj().crmAccordions();
         });
       </script>
 {/if}
 {literal}
   <script type="text/javascript">
-    cj(function(){
+    CRM.$(function($) {
       cj('#selector tr:even').addClass('odd-row ');
       cj('#selector tr:odd ').addClass('even-row');
     });
index f3bd6b9cd75c8c004ac30caf2702f85a14b9051d..d3805b5cd8bfea3af07f8e4d77f2d52f84228d81 100644 (file)
@@ -87,4 +87,4 @@
        class="button action-item"><span><div class="icon add-icon"></div>{ts}Add New Record{/ts}</span></a>
     {/if}
   {/if}
-{/if}
\ No newline at end of file
+{/if}
index edaa4758ca4aca6cd0725e378930453b21a6e6d0..dc9705e9664288d398b27a9eec8947487b48bfca 100644 (file)
@@ -14,7 +14,7 @@
 {literal}
 <script type="text/javascript">
 
-cj(function() {
+CRM.$(function($) {
   // Note: Queue API provides "#remaining tasks" but not "#completed tasks" or "#total tasks".
   // To compute a %complete, we manually track #completed. This only works nicely if we
   // assume that the queue began with a fixed #tasks.
index 2ba0c003f67f39032a57164a579710725dbcaff2..3018ead021f20500b93cc5a3e4a6180c11b25141 100644 (file)
 
     {literal}
     <script type="text/javascript">
-    cj(function() {
+    CRM.$(function($) {
       cj().crmAccordions();
     });
     </script>
index 7e5e0b79172e8c52706080586adb955dd452da09..b21a32e83a924abb8a00650598455200fa89a81a 100644 (file)
@@ -72,7 +72,7 @@
 
 {literal}
 <script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
    cj().crmAccordions();
 });
 </script>
index 6b9d82e3c07aecda84f83c0af76a737eade7fd7f..e4b638cf6dd86762e5c210ea078dd0a327a6a5d4 100644 (file)
   cj(document).ready(function() {
     cj('#title').data('initial_value', cj('#title').val());
   });
-  cj( function(){
+  CRM.$(function($) {
       var formName = {/literal}"{$form.formName}"{literal};
       cj('#_qf_' + formName + '_submit_save').click (
           function(){
index 45c0e948efcc0e724b1a8e22a2eec24d7c616186..c23920f0f2197f3d34f30f1ce73790c912d32ae0 100644 (file)
@@ -47,7 +47,7 @@
 
 {literal}
 <script type="text/javascript">
-   cj( function( ) {
+   CRM.$(function($) {
      buildChart( );
 
      cj("input[id$='submit_print'],input[id$='submit_pdf']").bind('click', function(e){
index f76274664ffb9a48dbebd038aa78b6b705c00be5..63c68126e329194b2e7cd31a762ae8480796b138 100644 (file)
@@ -84,7 +84,7 @@
 {/strip}
 {literal}
 <script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
    cj().crmAccordions();
 });
 </script>
index 176bd05af9041d11ace779e9454d34759da25a2b..0b38e6de624be698b18ec69847b6230b4dbb832b 100644 (file)
@@ -67,7 +67,7 @@
 
 {literal}
 <script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
    cj().crmAccordions();
 });
 </script>
index 2c9dc96f33e8e99ad583df3947fddb75184cd8e0..8d7b69c10d8cfaffdf5ad26914bac006b8faee37 100644 (file)
@@ -69,7 +69,7 @@
 
 {literal}
 <script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
    cj().crmAccordions();
 });
 </script>
index 265bd58f12e39e02ff53aa4076abcc78e0d0a757..f494d34cc5bdb1b0dc4410a9e7430a82f14907d7 100644 (file)
 <script type="text/javascript">
 {if $preview}
 {literal}
-cj(function() {
+CRM.$(function($) {
    cj().crmAccordions();
 });
 {/literal}
 {/if}
 
 {literal}
-cj(function() {
+CRM.$(function($) {
    cj('#start_date_display').change( function( ) { 
        if ( cj(this).val( ) ) {
           cj('#now').prop('checked', false );
index ed34dfd2ce4faf92281d611a23511b2e33aab244..dd6fe06e9bff728ff9c0bb70a831e8fa6ef1fc45 100644 (file)
@@ -73,7 +73,7 @@
       // update summary tab
       $("#contact-summary #tags").html(tags.join(', '));
     };
-  })(cj);
+  })(CRM.$);
   {/literal}
 </script>
 <div id="Tag" class="view-content">
index fb6b1312d9e9946b8733e0e937e7071f3eeb8a0f..f8a72de026d256cd440c329a9a4b293f74746325 100644 (file)
@@ -25,7 +25,7 @@
 *}
 {literal}
 <script type="text/javascript">
-    cj(function() {
+    CRM.$(function($) {
         cj().crmAccordions();
     });
 </script>
index 3c7a8b11b79061ce793f58616ccc4cb6f7b869e4..a7763289b698026624f13c7c2a423dda5d99edb2 100644 (file)
 
 {literal}
 <script type="text/javascript">
-  cj(function(){
+  CRM.$(function($) {
     cj('#selector tr:even').addClass('odd-row ');
     cj('#selector tr:odd ').addClass('even-row');
   });
index 23f7391907f92e4a47e5adb036fc377c1dd4cf42..5863edb675b2029e2bfd5098927a9d5793f0e1c4 100644 (file)
@@ -96,7 +96,7 @@ var otherModule = new Array( );
 otherModule[{/literal}{$mkey}{literal}] = '{/literal}{$mval}{literal}';
 {/literal}{/foreach}{literal}
 
-cj(function($) {
+CRM.$(function($) {
   if ( $.inArray( "Profile", otherModule ) > -1 && $.inArray( "Search Profile", otherModule ) == -1 ){
     $('#profile_visibility').show();
   }
@@ -202,7 +202,7 @@ cj("#field_name_1").bind( 'change blur', function( ) {
   showHideSeletorSearch( );
 });
 
-cj( function( ) {
+CRM.$(function($) {
   cj("#field_name_1").addClass( 'huge' );
   viewOnlyShowHide( );
   cj("#is_view").click( function(){
@@ -216,7 +216,7 @@ cj("#field_name_1").change(
     multiSummaryToggle(cj(this).val());
   });
 
-cj( function( ) {
+CRM.$(function($) {
   var fieldId = cj("#field_name_1").val();
   multiSummaryToggle(fieldId);
 });
index aaac4704c0059f006f59663b1b4921d4656f7b24..21289ec4821264f3d6584de20f2793d0696369b2 100644 (file)
 
   </div> {* maincontainer*}
   <script type='text/javascript'>
-      cj( function() {ldelim}
+      CRM.$(function($) {ldelim}
         var selectedTab = '{if $selectedChild}{$selectedChild}{else}user-profiles{/if}';
         var tabIndex = cj('#tab_' + selectedTab).prevAll().length;
         {literal}
index 3de42fc4cc09fa6ce1bed45d4bf239565b4680f4..6d35fa3fb1c0e590ac9dae410ec05d26495c3aa6 100644 (file)
@@ -20,7 +20,7 @@ If load the page directly from your browser, it automatically adds all the page
 
 <script>
 {literal}
-cj (function($) {
+CRM.$(function($) {
   $("#dialog").click (function () {
     var $n=$('<div>Loading '+window.location+'</div>').appendTo('body');
     $n.load(''+window.location, function(){
index f6217f0c4a75a1e5fdbc4cdfd1b4219781062b2a..98912302771dfd499c5b6aa6ec989dda90356df1 100644 (file)
@@ -153,4 +153,4 @@ $('#civicrm-menu').ready(function() {
   });
 });
 $('#civicrm-menu').menuBar({arrowSrc: CRM.config.resourceBase + 'packages/jquery/css/images/arrow.png'});
-})(cj);{/literal}
+})(CRM.$);{/literal}
index cb19b23a920635928f0de06cce631eaaafeb24f8..4eb99a5a154a6381a6b6e3fe74897c8cddfcb9cf 100644 (file)
@@ -4,7 +4,7 @@
  * Tabs with class 'ajaxForm' will use CRM.loadForm instead, suitable for most forms
  * Tabs with class 'livePage' will get popup action links, suitable for crud tables
  */
-cj(function($) {
+CRM.$(function($) {
   var tabSettings = CRM.tabSettings || {};
   tabSettings.active = tabSettings.active ? $('#tab_' + tabSettings.active).prevAll().length : 0;
   $("#mainTabContainer")
@@ -111,4 +111,4 @@ cj(function($) {
       $panel.data("civiCrmSnippet") && $panel.crmSnippet('destroy');
     }
   };
-})(cj);
+})(CRM.$);
index 34470ba710193175e85f4645715c2e84407df6ac..6dbff68fc2e15ad948de0ad5f77e9065ab1ee57e 100644 (file)
@@ -26,8 +26,7 @@
 {if $trackingFields and ! empty($trackingFields)}
 {literal}
 <script type="text/javascript">
-cj(
-   function( ) {
+CRM.$(function($) {
 {/literal}
     {foreach from=$trackingFields key=trackingFieldName item=dontCare}
        cj("#{$trackingFieldName}").parent().parent().hide( );
index 2543c629aa76d48903d7fe696b7669533f27c6f0..45adc63e4d883a27169173b2abcbf5fb31da0587 100644 (file)
@@ -25,7 +25,7 @@
 *}
 {literal}
 <script type="text/javascript" >
-cj( function( ) {
+CRM.$(function($) {
     {/literal}
     {if $generateAjaxRequest}
         {foreach from=$ajaxRequestBlocks key="blockName" item="instances"}
index a1c5957eaf5f92bd60794263f72473aa46c4af68..5582e9e0e881b29e49d2550bb91333b428e12b50 100644 (file)
@@ -25,7 +25,7 @@
 *}
 {literal}
 <script type="text/javascript">
-  cj( function() {
+  CRM.$(function($) {
     //bind the click event for action icon
     cj('.action-icon').click( function( ) {
       copyFieldValues( cj(this).attr('fname') );
index 95a8d720fcfb432817a71286bc4b0642f9f81b85..8aae1e3830c1a5a86c41cd1ef91fc8aa15bbbb01 100644 (file)
@@ -1,6 +1,6 @@
 <script>
 {literal}
-cj(function ($){
+CRM.$(function($) {
   $('.crm-editable').crmEditable ();
 });
 </script>
index fdc811509802106b1ee78904b98cceb80fff7cea..b67918377611bff1f68135e8fead89d11baff366 100644 (file)
@@ -26,7 +26,7 @@
 {literal}
 <script type="text/javascript">
 
-cj(function($) {
+CRM.$(function($) {
   // The set of options we can use to initialize jQuery.dashboard().
   var options = {
     // Optional. Defaults to 3.  You'll need to change the width of columns in CSS too.
index 29462f0578661926a8af01500d66fd48ce6c3451..838e39c4e9c307e1fefe393e7bc1481a97d1b399 100644 (file)
@@ -26,7 +26,7 @@
 {* handle common enable/disable actions *}
 {literal}
 <script type="text/javascript">
-  cj(function($) {
+  CRM.$(function($) {
     var $row, $table, info, enabled, fieldLabel;
 
     function successMsg() {
index 4e4662b8245ae73b040ac6132909e39a89a864f0..7c28ceaca815a656c8ab3112736313f7244eb600 100644 (file)
@@ -26,7 +26,7 @@
 {* Include this file in any form where we want to alert user if they've added or change form data, and then navigate away. *}
 {literal}
 <script type="text/javascript">
-     cj( function( ) {
+     CRM.$(function($) {
          cj("#{/literal}{$form.formName}{literal}").FormNavigate("{/literal}{ts escape='js'}You have unsaved changes.{/ts}{literal}"); 
      });
 </script>
index 3aefdcd56de1b6b6715e00a5f605b9d936f42133..5aebfb5e1c122208287072734849f617e4bbadf2 100644 (file)
@@ -25,7 +25,7 @@
 *}
 {* Highlight the required field during import (included within a <script>)*}
 {literal}
-cj(function($) {
+CRM.$(function($) {
   var highlightedFields = ["{/literal}{'","'|implode:$highlightedFields}{literal}"];
   $.each(highlightedFields, function() {
     $('select[id^="mapper"][id$="_0"] option[value='+ this + ']').append(' *').css({"color":"#FF0000"});
index 42d95f09ca11939185643b11f7d742b7067eb44b..75a3445ef580ef365c205c93b6225e1fada115d5 100644 (file)
@@ -69,7 +69,7 @@
 
 <script type="text/javascript">
     {literal}
-    cj( function() {
+    CRM.$(function($) {
       {/literal}
       var element_date   = "#{$displayDate}";
       var element_time  = "#{$elementId}_time";
index b8337cbf896ad7679963f433a0d6093a29d5dff1..e85f18d851270f03bd4081b45f03b0907b8dc1f6 100644 (file)
@@ -25,7 +25,7 @@
 *}
 {literal}
 <script type="text/javascript">
-cj( function( ) {
+CRM.$(function($) {
 // for date sorting see http://wiki.civicrm.org/confluence/display/CRMDOC/Sorting+Date+Fields+in+dataTables+Widget
 var useAjax = {/literal}{if $useAjax}1{else}0{/if}{literal};
 var sortEnabled = true;
index 4a36399bc12164fc4823e55f1c9bc0c32188c2d8..83edc911f51abe1fa9cf482b28826b6d95c953b2 100644 (file)
@@ -57,7 +57,7 @@
     {if $location neq 'top'}
       <script type="text/javascript">
         {literal}
-        cj(function($) {
+        CRM.$(function($) {
           {/literal}
           var
             $form = $('#{$form.formName}'),
index b8cc72de89ae546e7a697ca1bccbca4657aab942..8cb3c8a32b7c987bcada71a9dade6adff2c7786a 100644 (file)
@@ -58,7 +58,7 @@ function buildPaymentBlock( type ) {
   cj('#billing-payment-block').html(response).trigger('crmLoad').trigger('crmFormLoad');
 }
 
-cj( function() {
+CRM.$(function($) {
     cj('.crm-group.payment_options-group').show();
 
     cj('input[name="payment_processor"]').change( function() {
index c667beee470a197140d4c32cfa92d51f7fc0dcbe..c72a13646d6e4826b89c0f39a324a85266f90763 100644 (file)
@@ -78,7 +78,7 @@
 </div>
 {literal}
 <script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
   toggleTaskAction( );
   if (cj('#task option').length == 1 && !cj('#task option').val()) {
     cj('#task-section').remove();
index c86511e465ab9a925971c72aee5a5198fa6d21a0..fbea80400e67d9bddc4f7f009f40fa6e08862b54 100644 (file)
@@ -26,7 +26,7 @@
 {if $config->stateCountryMap}
 <script type="text/javascript">
   {literal}
-  cj(function($) {
+  CRM.$(function($) {
     function chainSelect(e) {
       var info = $(this).data('chainSelect');
       var val = info.target.val();
index e39e7a22e95240e0824c7a6c87f4d4999ba7aeea..2b50586f83b3f6aebeea2027170ceb2c545ebf7f 100644 (file)
@@ -111,7 +111,7 @@ class CRM_Core_RegionTest extends CiviUnitTestCase {
       . "callback-return<br/>"
       . "<script type=\"text/javascript\" src=\"/foo%20bar.js\">\n</script>\n"
       . "<script type=\"text/javascript\">\nalert(\"hi\");\n</script>\n"
-      . "<script type=\"text/javascript\">\ncj(function(\$){\n\$(\"div\");\n});\n</script>\n"
+      . "<script type=\"text/javascript\">\nCRM.\$(function(\$) {\n\$(\"div\");\n});\n</script>\n"
       . "<link href=\"/foo%20bar.css\" rel=\"stylesheet\" type=\"text/css\"/>\n"
       . "<style type=\"text/css\">\nbody { background: black; }\n</style>\n"
       ;
index 4c3391c55a98d0ed5ef4293640dfd75d60677ebf..473ca8b47ac4918d2be7bd0f0c4c003a1f2f0f95 100644 (file)
 {/if}
 {literal}
 <script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
    cj().crmaccordions(); 
 });
 </script>