Bug 35265: Remove drag and drop in Elasticsearch mappings
Bug 18827 says ordering search fields in Elasticsearch mappings is useless.
This patch removes it.
Drag and drop is kept for facets.
Test plan :
1) Enable Elasticsearch
2) Go to Administration > Search engine configuration (Elasticsearch)
3) Go to tab 'Bibliographic records'
4) Check there is no Javscript error
5) Check you can't drag and drop lines anymore
Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Barbara Petritsch <barbara.petritsch@wienmuseum.at>
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit c5f28855ad
)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
This commit is contained in:
parent
9825c7ea36
commit
c83d743193
2 changed files with 2 additions and 11 deletions
|
@ -261,7 +261,7 @@ a.add, a.delete {
|
|||
[% WRAPPER tab_panel tabname="mapping_${ index.index_name }" %]
|
||||
<table class="mappings" data-index_name="[% index.index_name | html %]" data-ordering="false" id="mapping_[% index.index_name | html %]_table">
|
||||
<thead>
|
||||
<tr class="nodrag nodrop">
|
||||
<tr>
|
||||
<th>Search field</th>
|
||||
<th>Sortable</th>
|
||||
<th>Facetable</th>
|
||||
|
@ -387,7 +387,7 @@ a.add, a.delete {
|
|||
[% END %]
|
||||
</tbody>
|
||||
<tfoot>
|
||||
<tr class="nodrag nodrop">
|
||||
<tr>
|
||||
<td>
|
||||
<input data-id="mapping_index_name" type="hidden" value="[% index.index_name | html %]" />
|
||||
<select data-id="mapping_search_field_name">
|
||||
|
|
|
@ -7,7 +7,6 @@ function clean_line(line) {
|
|||
|
||||
function clone_line(line) {
|
||||
var new_line = $(line).clone();
|
||||
$(new_line).removeClass("nodrag nodrop");
|
||||
$(new_line).find('td:last-child>a').removeClass("add").addClass("delete").html( __("Delete") );
|
||||
$(new_line).find('[data-id]').each(function () {
|
||||
$(this).attr({ name: $(this).attr('data-id') }).removeAttr('data-id');
|
||||
|
@ -58,10 +57,6 @@ $(document).ready(function () {
|
|||
}
|
||||
});
|
||||
|
||||
$("table.mappings").tableDnD({
|
||||
onDragClass: "dragClass highlighted-row",
|
||||
});
|
||||
|
||||
$('.add').click(function () {
|
||||
var table = $(this).closest('table');
|
||||
let table_id = table.attr('id');
|
||||
|
@ -81,10 +76,6 @@ $(document).ready(function () {
|
|||
} );
|
||||
|
||||
clean_line(line);
|
||||
|
||||
$(table).tableDnD({
|
||||
onDragClass: "dragClass highlighted-row",
|
||||
});
|
||||
}
|
||||
});
|
||||
$("#facet_biblios > table").tableDnD({
|
||||
|
|
Loading…
Reference in a new issue