abinjohnedamanaabinjohnedamana MemberComments: 36 Received thanks: 9 Member since: February 2019 edited October 2019

hi

I am creating a plugin with the backend list, add, edit and delete options. When I click on the edit button new window will open and update the existing data. But after the update I want to close the edit window and reload the listing window. unfortunately I cannot find anything to refresh the parent window. I am using the lightweight backend module with postmessage API.

Can you please help me?

Answers

  • KMSW5DEVKMSW5DEV MemberComments: 23 Received thanks: 2 Member since: April 28

    in short, i did this with payments and shipping constellations use at your own risk:

    <script>
    	function zw() {
    		var zahlartenwechsel = window.open('../account/payment','Zahlartwechsel','width=600, height=400'); 
    		var timer = setInterval(function() { 
    			if(zahlartenwechsel.closed) {
            			clearInterval(timer);
            			location.reload();
        			}
    		}, 500);
    	}
    </script>
    {if $sUserLoggedIn}
    			<a href="#" onClick="zw()" title="Bevorzugte Zahlart &auml;ndern" style="text-decoration: underline; color: rgb(102, 102, 102);"> 
    			<span class="frontend_checkout_actions shopware_studio_snippet">Zahlart wechseln</span>
    			</a>
    {/if}

    you're welcome. cheers

Sign In or Register to comment.