CRM-12910, removed ajaxsuccess binding
authorDeepak Srivastava <deepak.srivastava@webaccess.co.in>
Tue, 13 Aug 2013 14:36:32 +0000 (20:06 +0530)
committerDeepak Srivastava <deepak.srivastava@webaccess.co.in>
Tue, 13 Aug 2013 14:36:32 +0000 (20:06 +0530)
templates/CRM/common/logButton.tpl

index c22a2f9e0b7099408f3b336bdf0eba50e415612b..9cd9016d06c8fc459d3303b6c167551fcd837dbf 100644 (file)
   Note: This file is used by CivHR
 *}
 
-{if !$onlyScript}
-  <a class="css_right {$snippet.css_class}" href="#" title="{ts}View Revisions{/ts}">View Revisions</a>
-{/if}
+<a class="css_right {$snippet.css_class}" href="#" title="{ts}View Revisions{/ts}">View Revisions</a>
 
 {literal}
 <script type="text/javascript">
 (function($, CRM) {
-  {/literal}{if $onajax}{literal}
-    $(document).ajaxSuccess(function() {
-  {/literal}{/if}{literal}
-      if ($(".{/literal}{$snippet.css_class}{literal}").length) {
-         $(".{/literal}{$snippet.css_class}{literal}").crmRevisionLink({
-           contactId: {/literal}{$snippet.contact_id}{literal},
-           tableName: "{/literal}{$snippet.table_name}{literal}",
-           reportId: {/literal}{$snippet.instance_id}{literal}
-         });
-      }
-  {/literal}{if $onajax}{literal}
+  if ($(".{/literal}{$snippet.css_class}{literal}").length) {
+    $(".{/literal}{$snippet.css_class}{literal}").crmRevisionLink({
+      contactId: {/literal}{$snippet.contact_id}{literal},
+      tableName: "{/literal}{$snippet.table_name}{literal}",
+      reportId: {/literal}{$snippet.instance_id}{literal}
     });
-  {/literal}{/if}{literal}
+  }
 })(cj, CRM);
 </script>
 {/literal}