}
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)) {
-cj(function ($) {
+CRM.$(function($) {
'use strict';
// Behind the scenes method deals with browser for setting cursor position
</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} );
</select>
{literal}
<script type="text/javascript">
- cj(function($) {
+ CRM.$(function($) {
$('[name=other_activity].crm-action-menu').change(function() {
var
$el = $(this),
{/if}
{literal}
<script type="text/javascript">
- cj(function () {
+ CRM.$(function($) {
cj().crmAccordions();
var roleId = cj('input[name=activity_role]:checked', '#Search').val();
{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( ) {
</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},
<script type="text/javascript">
var {/literal}{$context}{literal}oTable;
- cj(function ( ) {
+ CRM.$(function($) {
cj().crmAccordions();
var context = {/literal}"{$context}"{literal};
var filterSearchOnLoad = false;
{include file="CRM/Mailing/Form/InsertTokens.tpl"}
{literal}
<script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
cj().crmAccordions();
});
</script>
{if $form.contact_edit_options.html}
{literal}
<script type="text/javascript">
- cj(function () {
+ CRM.$(function($) {
cj("#contactEditBlocks").sortable({
placeholder: 'ui-state-highlight',
update: getSorting
{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();
}
</div>
{literal}
<script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
showHideMapAPIkey( cj('#mapProvider').val( ) );
});
function showHideMapAPIkey( mapProvider ) {
{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}"
});
}
-cj( function( ) {
+CRM.$(function($) {
{/literal}
{if $stringOverrideInstances}
{foreach from=$stringOverrideInstances key="index" item="instance"}
{* 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});
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} );
});
}
</style>
<script type="text/javascript">
- cj(function($) {
+ CRM.$(function($) {
cj("#navigation-tree").jstree({
plugins : [ "themes", "json_data", "dnd","ui", "crrm","contextmenu" ],
json_data : {
{literal}
<script type="text/javascript">
-cj(function($) {
+CRM.$(function($) {
var tag;
$('.merge_tag').click(function(e) {
tag = $(this).crmEditableEntity();
// http://civicrm.org/licensing
-cj(function ($) {
+CRM.$(function($) {
function openKCFinder(field) {
var field = $(this);
window.KCFinder = {
//@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')
</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}
{literal}
<script type="text/javascript">
-cj( function() {
+CRM.$(function($) {
buildBatchSelector( false );
cj('#_qf_Search_refresh').click( function() {
buildBatchSelector(true);
</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');
}
{literal}
<script type="text/javascript">
- cj( function( ){
+ CRM.$(function($) {
loadVoterList( );
});
</script>
{* load selector when force *}
{if $force and !$buildSelector}
{literal}
- cj( function( ) {
+ CRM.$(function($) {
searchVoters( {/literal}'{$qfKey}'{literal} );
});
{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());
{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});
});
{literal}
<script type="text/javascript">
- cj(function() {
+ CRM.$(function($) {
cj().crmAccordions();
{/literal}
{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} );
});
{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} );
});
{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());
<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( ) {
{literal}
<script type="text/javascript">
- cj(function() {
+ CRM.$(function($) {
cj().crmAccordions();
setDefaultGroup( );
});
<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')) {
{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();
{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},
{* 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');
{literal}
<script type="text/javascript">
-cj(function( ) {
+CRM.$(function($) {
buildCaseActivities(false);
});
});
}
</script>
-{/literal}
\ No newline at end of file
+{/literal}
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,
<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);
});
{/if}
{literal}
<script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
cj().crmAccordions();
});
</script>
{literal}
<script type="text/javascript">
- cj(function() {
+ CRM.$(function($) {
cj().crmAccordions();
});
</script>
{literal}
<script type="text/javascript" >
- cj(function($) {
+ CRM.$(function($) {
var action = "{/literal}{$action}{literal}";
$().crmAccordions();
{/if}
{/if}
-{include file="CRM/Form/attachmentjs.tpl"}
\ No newline at end of file
+{include file="CRM/Form/attachmentjs.tpl"}
{/literal}
{literal}
<script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
cj().crmAccordions();
});
</script>
{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( ) {
{* 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}";
{literal}
<script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
if (cj('#update_modified_date').length == 0) {
return;
}
{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( ) {
}
}
-cj( function() {
+CRM.$(function($) {
showDeceasedDate( );
});
</script>
{literal}
<script type="text/javascript">
- cj(function($) {
+ CRM.$(function($) {
// check first primary radio
$('#Email_1_IsPrimary').prop('checked', true );
});
{literal}
<script type="text/javascript">
- cj(function($) {
+ CRM.$(function($) {
// check first primary radio
$('#IM_1_IsPrimary').prop('checked', true );
});
{literal}
<script type="text/javascript">
- cj(function($) {
+ CRM.$(function($) {
// check first primary radio
$('#OpenID_1_IsPrimary').prop('checked', true );
});
{literal}
<script type="text/javascript">
- cj(function($) {
+ CRM.$(function($) {
// check first primary radio
$('#Phone_1_IsPrimary').prop('checked', true );
});
{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 ) {
{* 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}");
{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};
{* 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()
{/strip}
{literal}
<script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
cj().crmAccordions();
});
</script>
{$form.group_type.html}
{literal}
<script type="text/javascript">
- cj(function(){
+ CRM.$(function($) {
function showGroupSearch(){
cj('#grouptypeselect').hide();
cj('#groupselect').show();
{literal}
<script type="text/javascript">
- cj(function () {
+ CRM.$(function($) {
updateChangeLogLabels();
});
}
-cj(function( ) {
+CRM.$(function($) {
if ( cj('#street_name').val( ).length > 0 ||
cj('#street_unit').val( ).length > 0 ||
cj('#street_number').val( ).length > 0 ) {
{/if}
{literal}
<script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
cj().crmAccordions();
});
{/if}
{literal}
<script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
cj().crmAccordions();
});
</script>
{/if}
{literal}
<script type="text/javascript">
- cj(function() {
+ CRM.$(function($) {
cj().crmAccordions();
});
</script>
{/if}
{literal}
<script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
cj().crmAccordions();
});
</script>
{/strip}
{literal}
<script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
cj().crmAccordions();
});
</script>
{/if}
{literal}
<script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
cj().crmAccordions();
});
</script>
{literal}
<script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
toggleTaskAction( );
});
</script>
<script type="text/javascript">
{literal}
- cj(function($) {
+ CRM.$(function($) {
cj("#toggleSelect, input[id^=mark_x_]").prop('checked', false);
var cids = [];
var i = 0;
}
}
-cj( function( ) {
+CRM.$(function($) {
var blockNo = {/literal}{$blockId}{literal};
// call this when form loads
{if $searchtype eq 'ts_sel'}
{literal}
<script type="text/javascript">
- cj(function($) {
+ CRM.$(function($) {
$("#popupContainer").css({
"background-color":"#E0E0E0",
'display':'none',
-cj(function ($) {
+CRM.$(function($) {
//do not copy & paste this - find a way to generalise it
'use strict';
$().crmAccordions();
{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());
{include file="CRM/Mailing/Form/InsertTokens.tpl"}
{literal}
<script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
cj().crmAccordions();
});
{* // 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() {
{literal}
<script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
cj().crmAccordions();
});
<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'),
{literal}
<script type="text/javascript">
- cj(function() {
+ CRM.$(function($) {
var currentReSortEvent;
cj(".dash-column").sortable({
connectWith: '.dash-column',
{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');
{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);
});
<script type="text/javascript">
var {/literal}{$context}{literal}oTable;
- cj(function () {
+ CRM.$(function($) {
buildContactRelationships{/literal}{$context}{literal}();
});
{* 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}",
eval( 'cj( "#recurringPaymentBlock" ).' + funName + "( )" );
}
- cj( function() {
+ CRM.$(function($) {
buildRecurBlock( null );
enablePeriod( );
});
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'));
{/if}
{literal}
<script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
cj().crmAccordions();
});
</script>
{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();
});
toggleConfirmButton();
});
- cj(function() {
+ CRM.$(function($) {
toggleConfirmButton();
});
}
}
- cj(function(){
+ CRM.$(function($) {
// highlight price sets
function updatePriceSetHighlight() {
cj('#priceset .price-set-row').removeClass('highlight');
</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();
{if $membershipBlock AND $quickConfig}
{literal}
<script type="text/javascript">
-cj(function(){
+CRM.$(function($) {
showHideAutoRenew( null );
});
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' ) ) {
{* 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}");
{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();
});
{literal}
<script type="text/javascript">
- cj( function( ) {
+ CRM.$(function($) {
buildChart( );
});
cj('#amountFields').hide();
}
- cj(function() {
+ CRM.$(function($) {
payLater('is_pay_later');
});
<script type="text/javascript">
{literal}
- cj(function () {
+ CRM.$(function($) {
cj().crmAccordions();
// bind click event to premiums_active checkbox
{literal}
<script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
cj().crmAccordions();
});
</script>
{/if}
{literal}
<script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
cj().crmAccordions();
});
</script>
{/if}
{literal}
<script type="text/javascript">
- cj(function($) {
+ CRM.$(function($) {
var $form = $("#{/literal}{$form.formName}{literal}");
$('#showPCP, #showSoftCredit').click(function(){
return showHideSoftCreditAndPCP();
// http://civicrm.org/licensing
/*jslint indent: 2 */
/*global CRM, cj */
-cj(function ($) {
+CRM.$(function($) {
'use strict';
var load = {
{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({
}
-cj(function ($) {
+CRM.$(function($) {
$('h2.entity').click ( function(){APIDoc($(this).attr('id'))} );
entity=window.location.hash;
if (entity.substring(0, 1) === '#') {
<script>
{literal}
-cj(function($) {
+CRM.$(function($) {
var restURL = CRM.url("civicrm/ajax/rest");
function toggleField (name, label, type) {
$(function() {
$('#billing-payment-block').on('crmFormLoad', civicrm_billingblock_creditcard_helper);
});
-})(cj);
+})(CRM.$);
<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 = {};
*}
{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}";
{/foreach}
<script type="text/javascript">
{literal}
- cj(function() {
+ CRM.$(function($) {
cj().crmAccordions();
});
{/literal}
{$initHideBlocks}
{literal}
<script type="text/Javascript">
-cj(function($) {
+CRM.$(function($) {
showHideStyle();
cj('#extends_0').change(function() {
{/foreach}
{literal}
<script type="text/javascript">
- cj(function () {
+ CRM.$(function($) {
cj().crmAccordions();
});
</script>
{if $context eq 'standalone' and $outBound_option != 2 }
<script type="text/javascript">
{literal}
-cj( function( ) {
+CRM.$(function($) {
cj("#contact_1").blur( function( ) {
checkEmail( );
} );
</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()})})
{if $discountSection eq 2}
<script type="text/javascript">
{literal}
- cj( function() {
+ CRM.$(function($) {
cj('#discounted_label_1').focus( );
});
{/literal}
}
//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());
{literal}
<script type='text/javascript'>
- cj(function() {
+ CRM.$(function($) {
populateRecipient();
cj('#recipient').click( function( ) {
populateRecipient();
{literal}
<script>
-cj(function($) {
+CRM.$(function($) {
$('body').click(function() {
$('#crm-event-links-list, #crm-participant-list').hide();
});
{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}
cj('#balance-fee').text(symbol+" "+balanceAmt);
}
-cj(function(){
+CRM.$(function($) {
// assign statuses
var partiallyPaid = {/literal}{$partiallyPaid}{literal};
var pendingRefund = {/literal}{$pendingRefund}{literal};
{/if}
{literal}
<script type='text/javascript'>
-cj(function($){
+CRM.$(function($) {
cj('.total_amount-section').remove();
cj('#ParticipantFeeSelection').submit(function(e) {
toggleConfirmButton();
});
- cj(function () {
+ CRM.$(function($) {
toggleConfirmButton();
skipPaymentMethod();
});
{/if}
{literal}
<script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
cj().crmAccordions();
});
</script>
{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},
/**
* 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() );
{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();
</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();
{include file="CRM/Form/validate.tpl"}
{literal}
<script type="text/javascript">
-cj(function($){
+CRM.$(function($) {
$().crmAccordions();
});
</script>
{include file="CRM/Form/validate.tpl"}
{literal}
<script type="text/javascript">
-cj(function($) {
+CRM.$(function($) {
var batchSelector;
buildBatchSelector();
$("#batch_update").prop('disabled', false);
{literal}
<script type="text/javascript">
-cj( function() {
+CRM.$(function($) {
var entityID = {/literal}{$entityID}{literal};
batchSummary(entityID);
cj('#close_batch').click( function() {
{if !$noexpand}
{literal}
<script type="text/javascript">
- cj(function() {
+ CRM.$(function($) {
cj().crmAccordions();
});
</script>
<script type="text/javascript">
{literal}
- cj(function($) {
+ CRM.$(function($) {
$('a.delete-attachment').click(function() {
var $el = $(this),
$row = $el.closest('.crm-attachment-wrapper'),
{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}",
{literal}
<script type="text/javascript">
- cj( function( ) {
+ CRM.$(function($) {
{/literal}
CRM.buildCustomData( '{$customDataType}' );
{if $customDataSubType}
{literal}
});
- cj(function() {
+ CRM.$(function($) {
cj().crmAccordions();
});
</script>
</div><!-- /.crm-content-block -->
{literal}
<script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
cj().crmAccordions();
});
</script>
{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
{literal}
<script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
cj().crmAccordions();
});
</script>
});
});
- cj( function( ) {
+ CRM.$(function($) {
var count = 0; var columns=''; var sortColumn = '';
cj('#selectedRecords th').each( function( ) {
{literal}
<script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
cj().crmAccordions();
});
</script>
{/literal}
{if $editor eq "ckeditor"}
{literal}
- cj( function() {
+ CRM.$(function($) {
oEditor = CKEDITOR.instances['html_message'];
oEditor.BaseHref = '' ;
oEditor.UserFilesPath = '' ;
{/literal}
{elseif $editor eq "tinymce"}
{literal}
- cj( function( ) {
+ CRM.$(function($) {
if ( isMailing ) {
cj('div.html').hover(
function( ) {
{/literal}
{elseif $editor eq "drupalwysiwyg"}
{literal}
- cj( function( ) {
+ CRM.$(function($) {
if ( isMailing ) {
cj('div.html').hover(
verify,
{literal}
}
-cj(function($) {
+CRM.$(function($) {
function insertToken() {
var
token = $(this).val(),
<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 );
<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) {
{include file="CRM/common/formNavigate.tpl"}
{literal}
<script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
cj().crmAccordions();
});
</script>
{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);
});
</div>
{literal}
<script type="text/javascript">
- cj(function($) {
+ CRM.$(function($) {
var oTable;
buildMailingContact();
-cj(function($) {
+CRM.$(function($) {
checkExistingMemOrg();
$("select[name='membership_type_id[0]']").change( checkExistingMemOrg );
{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 ) {
{literal}
<script type="text/javascript">
- cj( function() {
+ CRM.$(function($) {
//show/hide membership block
showHideMembershipBlock();
cj('#member_is_active').click( function() {
{/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();
-cj(function($) {
+CRM.$(function($) {
memberResults = new Array;
$("input[name='contact[1]']").result( function() {
var contact_id = cj("input[name='contact_select_id[1]']").val();
{literal}
<script type="text/javascript">
-cj(function(){
+CRM.$(function($) {
showHidePeriodSettings();
cj('#duration_unit').change(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}
</div>
{literal}
<script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
cj().crmAccordions();
});
</script>
-cj(function ($) {
+CRM.$(function($) {
'use strict';
$('#per_membership').click(function() {
if($(this).is(":checked")) {
</div>
{literal}
<script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
cj().crmAccordions();
});
</script>
{/literal}
{if $context eq 'standalone' and $outBound_option != 2 }
{literal}
- cj( function( ) {
+ CRM.$(function($) {
cj("#contact_1").blur( function( ) {
checkEmail( );
});
{/if}
{literal}
<script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
cj().crmAccordions();
});
</script>
{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');
});
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}
{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.
{literal}
<script type="text/javascript">
- cj(function() {
+ CRM.$(function($) {
cj().crmAccordions();
});
</script>
{literal}
<script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
cj().crmAccordions();
});
</script>
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(){
{literal}
<script type="text/javascript">
- cj( function( ) {
+ CRM.$(function($) {
buildChart( );
cj("input[id$='submit_print'],input[id$='submit_pdf']").bind('click', function(e){
{/strip}
{literal}
<script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
cj().crmAccordions();
});
</script>
{literal}
<script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
cj().crmAccordions();
});
</script>
{literal}
<script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
cj().crmAccordions();
});
</script>
<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 );
// update summary tab
$("#contact-summary #tags").html(tags.join(', '));
};
- })(cj);
+ })(CRM.$);
{/literal}
</script>
<div id="Tag" class="view-content">
*}
{literal}
<script type="text/javascript">
- cj(function() {
+ CRM.$(function($) {
cj().crmAccordions();
});
</script>
{literal}
<script type="text/javascript">
- cj(function(){
+ CRM.$(function($) {
cj('#selector tr:even').addClass('odd-row ');
cj('#selector tr:odd ').addClass('even-row');
});
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();
}
showHideSeletorSearch( );
});
-cj( function( ) {
+CRM.$(function($) {
cj("#field_name_1").addClass( 'huge' );
viewOnlyShowHide( );
cj("#is_view").click( function(){
multiSummaryToggle(cj(this).val());
});
-cj( function( ) {
+CRM.$(function($) {
var fieldId = cj("#field_name_1").val();
multiSummaryToggle(fieldId);
});
</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}
<script>
{literal}
-cj (function($) {
+CRM.$(function($) {
$("#dialog").click (function () {
var $n=$('<div>Loading '+window.location+'</div>').appendTo('body');
$n.load(''+window.location, function(){
});
});
$('#civicrm-menu').menuBar({arrowSrc: CRM.config.resourceBase + 'packages/jquery/css/images/arrow.png'});
-})(cj);{/literal}
+})(CRM.$);{/literal}
* 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")
$panel.data("civiCrmSnippet") && $panel.crmSnippet('destroy');
}
};
-})(cj);
+})(CRM.$);
{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( );
*}
{literal}
<script type="text/javascript" >
-cj( function( ) {
+CRM.$(function($) {
{/literal}
{if $generateAjaxRequest}
{foreach from=$ajaxRequestBlocks key="blockName" item="instances"}
*}
{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') );
<script>
{literal}
-cj(function ($){
+CRM.$(function($) {
$('.crm-editable').crmEditable ();
});
</script>
{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.
{* handle common enable/disable actions *}
{literal}
<script type="text/javascript">
- cj(function($) {
+ CRM.$(function($) {
var $row, $table, info, enabled, fieldLabel;
function successMsg() {
{* 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>
*}
{* 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"});
<script type="text/javascript">
{literal}
- cj( function() {
+ CRM.$(function($) {
{/literal}
var element_date = "#{$displayDate}";
var element_time = "#{$elementId}_time";
*}
{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;
{if $location neq 'top'}
<script type="text/javascript">
{literal}
- cj(function($) {
+ CRM.$(function($) {
{/literal}
var
$form = $('#{$form.formName}'),
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() {
</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();
{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();
. "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"
;
{/if}
{literal}
<script type="text/javascript">
-cj(function() {
+CRM.$(function($) {
cj().crmaccordions();
});
</script>