Lines 1841-1858
Link Here
|
1841 |
$('#move_hold_biblio_confirm').prop('disabled' , true ); |
1841 |
$('#move_hold_biblio_confirm').prop('disabled' , true ); |
1842 |
|
1842 |
|
1843 |
let biblioID = $("#biblio_id").val(); |
1843 |
let biblioID = $("#biblio_id").val(); |
1844 |
let apiUrl = `/api/v1/items?q={"biblio_id":"${encodeURIComponent(biblioID)}"}`; |
1844 |
let apiUrl = `/api/v1/biblios?q={"biblio_id":"${encodeURIComponent(biblioID)}"}`; |
1845 |
$.ajax({ |
1845 |
$.ajax({ |
1846 |
url: apiUrl, |
1846 |
url: apiUrl, |
1847 |
method: "GET", |
1847 |
method: "GET", |
1848 |
dataType: "json", |
1848 |
dataType: "json", |
|
|
1849 |
headers: { |
1850 |
'Accept': 'application/json' |
1851 |
}, |
1849 |
success: function (data) { |
1852 |
success: function (data) { |
1850 |
if (data.length > 0) { |
1853 |
if (data.length > 0) { |
1851 |
const unique_data = data.filter((item, index, self) => |
|
|
1852 |
index === self.findIndex(t => t.biblio_id === item.biblio_id) |
1853 |
); |
1854 |
let resultHtml = ""; |
1854 |
let resultHtml = ""; |
1855 |
$.each(unique_data, function (index, item) { |
1855 |
$.each(data, function (index, item) { |
1856 |
resultHtml += ` |
1856 |
resultHtml += ` |
1857 |
<div class="alert alert-success"> |
1857 |
<div class="alert alert-success"> |
1858 |
<strong>Biblionumber:</strong> ${item.biblio_id} <br> |
1858 |
<strong>Biblionumber:</strong> ${item.biblio_id} <br> |
1859 |
- |
|
|