Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <script src="jquery-3.3.1.min.js"></script>
- <script>
- $('#layout2').click(function(){
- var form = new FormData();
- form.append("layoutId", "2");
- form.append("changeMode", "replace");
- form.append("displayGroupId", "2");
- var settings = {
- "async": true,
- "crossDomain": true,
- "url": "http://192.168.0.131/api/displaygroup/2/action/changeLayout?envelope=1",
- "method": "POST",
- "headers": {
- "Authorization": "Bearer xxx",
- "Cache-Control": "no-cache",
- "Postman-Token": "xxx"
- },
- "processData": false,
- "contentType": false,
- "mimeType": "multipart/form-data",
- "data": form
- }
- $.ajax(settings).done(function (response) {
- console.log(response);
- });
- });
- </script>
- </head>
- <body>
- <button id="layout2">Test</button>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement