mirror of
https://github.com/grocy/grocy.git
synced 2026-04-06 21:06:15 +02:00
recipeposform postMessage back
This commit is contained in:
parent
aa0619dd73
commit
d94e52316c
|
|
@ -15,7 +15,8 @@ $('#save-recipe-pos-button').on('click', function (e)
|
||||||
Grocy.Api.Post('objects/recipes_pos', jsonData,
|
Grocy.Api.Post('objects/recipes_pos', jsonData,
|
||||||
function(result)
|
function(result)
|
||||||
{
|
{
|
||||||
window.location.href = U('/recipe/' + Grocy.EditObjectParentId);
|
window.parent.postMessage(WindowMessageBag("IngredientsChanged"), Grocy.BaseUrl);
|
||||||
|
window.parent.postMessage(WindowMessageBag("CloseAllModals"), Grocy.BaseUrl);
|
||||||
},
|
},
|
||||||
function(xhr)
|
function(xhr)
|
||||||
{
|
{
|
||||||
|
|
@ -29,7 +30,8 @@ $('#save-recipe-pos-button').on('click', function (e)
|
||||||
Grocy.Api.Put('objects/recipes_pos/' + Grocy.EditObjectId, jsonData,
|
Grocy.Api.Put('objects/recipes_pos/' + Grocy.EditObjectId, jsonData,
|
||||||
function(result)
|
function(result)
|
||||||
{
|
{
|
||||||
window.location.href = U('/recipe/' + Grocy.EditObjectParentId);
|
window.parent.postMessage(WindowMessageBag("IngredientsChanged"), Grocy.BaseUrl);
|
||||||
|
window.parent.postMessage(WindowMessageBag("CloseAllModals"), Grocy.BaseUrl);
|
||||||
},
|
},
|
||||||
function(xhr)
|
function(xhr)
|
||||||
{
|
{
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user