Merge pull request #9438 from jmcclelland/CRM-19298
[civicrm-core.git] / templates / CRM / Contact / Page / DedupeException.tpl
CommitLineData
6a488035
TO
1{*
2 +--------------------------------------------------------------------+
2c4c49ca 3 | CiviCRM version 4.7 |
6a488035 4 +--------------------------------------------------------------------+
fa938177 5 | Copyright CiviCRM LLC (c) 2004-2016 |
6a488035
TO
6 +--------------------------------------------------------------------+
7 | This file is a part of CiviCRM. |
8 | |
9 | CiviCRM is free software; you can copy, modify, and distribute it |
10 | under the terms of the GNU Affero General Public License |
11 | Version 3, 19 November 2007 and the CiviCRM Licensing Exception. |
12 | |
13 | CiviCRM is distributed in the hope that it will be useful, but |
14 | WITHOUT ANY WARRANTY; without even the implied warranty of |
15 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. |
16 | See the GNU Affero General Public License for more details. |
17 | |
18 | You should have received a copy of the GNU Affero General Public |
19 | License and the CiviCRM Licensing Exception along |
20 | with this program; if not, contact CiviCRM LLC |
21 | at info[AT]civicrm[DOT]org. If you have questions about the |
22 | GNU Affero General Public License or the licensing of CiviCRM, |
23 | see the CiviCRM license FAQ at http://civicrm.org/licensing |
24 +--------------------------------------------------------------------+
25*}
b6c2c84e
SL
26<div class="crm-accordion-header">
27 {ts}Filter Contacts{/ts}
28</div>
29<div class="crm-accordion-body">
30 <table class="no-border form-layout-compressed" id="searchOptions" style="width:100%;">
31 <tr>
32 <td class="crm-contact-form-block-contact1">
33 <label for="contact1">{ts}Contact 1{/ts}</label><br />
34 <input type="text" placeholder="Search Contact1" search-column="0" />
35 </td>
36 <td class="crm-contact-form-block-contact2">
37 <label for="contact2">{ts}Contact 2{/ts}</label><br />
38 <input type="text" placeholder="Search Contact2" search-column="1" />
39 </td>
40 </tr>
41 </table>
42</div>
43<table id="dedupeExceptions" class="display crm-sortable" data-searching='true' data=filter='false'>
bff3913a
JL
44 <thead>
45 <tr class="columnheader">
46 <th>{ts}Contact 1{/ts}</th>
47 <th>{ts}Contact 2 (Duplicate){/ts}</th>
48 <th data-orderable="false"></th>
49 </tr>
50 </thead>
51 <tbody>
52 {foreach from=$dedupeExceptions item=exception key=id}
53 <tr id="dupeRow_{$id}" class="{cycle values="odd-row,even-row"}">
09a0e7ae 54 <td><a href ={crmURL p='civicrm/contact/view' q="reset=1&cid=`$exception.main.id`"}>{$exception.main.name}</a></td>
55 <td><a href ={crmURL p='civicrm/contact/view' q="reset=1&cid=`$exception.other.id`"}>{$exception.other.name}</a></td>
bff3913a
JL
56 <td><a id='duplicateContacts' href="#" title={ts}Remove Exception{/ts} onClick="processDupes( {$exception.main.id}, {$exception.other.id}, 'nondupe-dupe', 'dedupe-exception' );return false;">&raquo; {ts}Remove Exception{/ts}</a></td>
57 </tr>
58 {/foreach}
59 </tbody>
6a488035
TO
60</table>
61<div class="clear"><br /></div>
62<div class="action-link">
80bc2820 63 {crmButton p="civicrm/contact/deduperules" q="reset=1" icon="times"}{ts}Done{/ts}{/crmButton}
6a488035
TO
64</div>
65
6a488035 66{* process the dupe contacts *}
232624b1 67{include file="CRM/common/dedupe.tpl"}
b6c2c84e
SL
68{literal}
69 <script type="text/javascript">
70 (function($) {
71 var table = CRM.$('table#dedupeExceptions').DataTable();
72 // apply the search
73 $('#searchOptions input').on( 'keyup change', function () {
b6c2c84e
SL
74 table
75 .column($(this).attr('search-column'))
76 .search(this.value)
77 .draw();
78 });
79 })(CRM.$);
80 </script>
81{/literal}