Fix wishlist change on wish add
This commit is contained in:
parent
05f9aed12a
commit
0ca354cfc3
2 changed files with 5 additions and 5 deletions
|
@ -40,8 +40,8 @@ $(function() {
|
|||
placeholder: text.wishlist_no_selection
|
||||
})
|
||||
|
||||
if ($_GET.wishlist) {
|
||||
element.dropdown('set selected', $_GET.wishlist);
|
||||
if ($_GET.id) {
|
||||
element.dropdown('set selected', $_GET.id);
|
||||
} else {
|
||||
if (response.results[0]) {
|
||||
element.dropdown('set selected', response.results[0].value);
|
||||
|
|
|
@ -43,7 +43,7 @@ $(function () {
|
|||
progress.addClass('indeterminate');
|
||||
|
||||
if (wishlistValue) {
|
||||
$_GET.wishlist = wishlistValue;
|
||||
$_GET.id = wishlistValue;
|
||||
|
||||
$('.wishlist-share').attr('href', '/?wishlist=' + wishlists[wishlistIndex].hash);
|
||||
|
||||
|
@ -274,7 +274,7 @@ $(function () {
|
|||
|
||||
wishlists.dropdown('clear');
|
||||
|
||||
urlParams.delete('wishlist');
|
||||
urlParams.delete('id');
|
||||
|
||||
$('body').toast({ message:text.toast_wishlist_delete });
|
||||
|
||||
|
@ -426,7 +426,7 @@ $(function () {
|
|||
.then(function(response) {
|
||||
modalWishlistCreate.modal('hide');
|
||||
|
||||
urlParams.set('wishlist', response.data.lastInsertId);
|
||||
urlParams.set('id', response.data.lastInsertId);
|
||||
|
||||
$('body').toast({ message: text.toast_wish_create });
|
||||
|
||||
|
|
Loading…
Reference in a new issue