This commit is contained in:
grandeljay 2022-05-28 18:03:31 +02:00
parent aad8c7cd14
commit f9be136345

View file

@ -1,4 +1,8 @@
$(function () { $(function () {
var wishlist = {
'id' : $_GET.id
};
/** /**
* Get Wishlists * Get Wishlists
*/ */
@ -17,8 +21,8 @@ $(function () {
placeholder : text.wishlist_no_selection placeholder : text.wishlist_no_selection
}) })
if ($_GET.id) { if (wishlist.id) {
element.dropdown('set selected', $_GET.id); element.dropdown('set selected', wishlist.id);
} else { } else {
if (wishlists[0]) { if (wishlists[0]) {
element.dropdown('set selected', wishlists[0].value); element.dropdown('set selected', wishlists[0].value);
@ -43,7 +47,7 @@ $(function () {
progress.addClass('indeterminate'); progress.addClass('indeterminate');
if (wishlistValue) { if (wishlistValue) {
$_GET.id = wishlistValue; wishlist.id = wishlistValue;
$('.wishlist-share').attr('href', '/?wishlist=' + wishlists[wishlistIndex].hash); $('.wishlist-share').attr('href', '/?wishlist=' + wishlists[wishlistIndex].hash);