Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enotice fix #22436

Merged
merged 1 commit into from
Jan 10, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions templates/CRM/Financial/Page/BatchTransaction.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
</tbody>
</table>

<div class="crm-submit-buttons">{if in_array($batchStatus, array('Open', 'Reopened'))}{$form.close_batch.html}{/if} {$form.export_batch.html}</div>
<div class="crm-submit-buttons">{if array_key_exists('close_batch', $form)}{$form.close_batch.html}{/if} {if array_key_exists('close_batch', $form)}{$form.export_batch.html}{/if}</div>

{if in_array($batchStatus, array('Open', 'Reopened'))} {* Add / remove transactions only allowed for Open/Reopened batches *}
<br /><div class="form-layout-compressed">{$form.trans_remove.html}&nbsp;{$form.rSubmit.html}</div><br/>
Expand Down Expand Up @@ -75,17 +75,17 @@ CRM.$(function($) {
});
function assignRemove(recordID, op) {
var recordBAO = 'CRM_Batch_BAO_Batch';
if (op == 'assign' || op == 'remove') {
recordBAO = 'CRM_Batch_BAO_EntityBatch';
if (op === 'assign' || op === 'remove') {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@eileenmcnaughton does === do the same thing in JS as in php?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@seamuslee001 I think so since it was my IDE that wanted this change

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@seamuslee001 seems to be working fine
image

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes it does

recordBAO = 'CRM_Batch_BAO_EntityBatch';
}
var entityID = {/literal}"{$entityID}"{literal};
if (op == 'close' || op == 'export') {
if (op === 'close' || op === 'export') {
var mismatch = checkMismatch();
}
else {
CRM.$('#mark_x_' + recordID).closest('tr').block({message: {/literal}'{ts escape="js"}Updating{/ts}'{literal}});
}
if (op == 'close' || (op == 'export' && mismatch.length)) {
if (op === 'close' || (op === 'export' && mismatch.length)) {
CRM.$("#enableDisableStatusMsg").dialog({
title: {/literal}'{ts escape="js"}Close Batch{/ts}'{literal},
modal: true,
Expand Down