|
|
@ -17,12 +17,9 @@ function messageListener(event) { |
|
|
|
if (event.data && event.data.action === 'sendUrl') { |
|
|
|
if (event.data && event.data.action === 'sendUrl') { |
|
|
|
const parentUrl = event.data.url; |
|
|
|
const parentUrl = event.data.url; |
|
|
|
|
|
|
|
|
|
|
|
// Remove the base URL and hash
|
|
|
|
|
|
|
|
const path = parentUrl.replace("https://adw.ospro.id/#/dashboard-project/", ""); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// Split the remaining path by "/"
|
|
|
|
// Split the remaining path by "/"
|
|
|
|
parts = path.split("/"); |
|
|
|
parts = parentUrl.split("/"); |
|
|
|
if (parts[2] && parts[2] == "1") { |
|
|
|
if (parts[7] && parts[7] == "1") { |
|
|
|
$.ajax({ |
|
|
|
$.ajax({ |
|
|
|
headers: { |
|
|
|
headers: { |
|
|
|
"Content-Type": "application/json", |
|
|
|
"Content-Type": "application/json", |
|
|
|