diff --git a/src/components/renderer/form-empty-table.vue b/src/components/renderer/form-empty-table.vue index b43126a61..86307c5fb 100644 --- a/src/components/renderer/form-empty-table.vue +++ b/src/components/renderer/form-empty-table.vue @@ -21,7 +21,7 @@ export default { }, methods: { openLink() { - window.open(this.link, "_blank"); + window.open(this.url, "_blank"); } } }; diff --git a/src/components/renderer/form-requests.vue b/src/components/renderer/form-requests.vue index d515ca365..3a5d1e6bb 100755 --- a/src/components/renderer/form-requests.vue +++ b/src/components/renderer/form-requests.vue @@ -48,7 +48,7 @@
- +
@@ -81,6 +81,11 @@ export default { ] }; }, + computed: { + noDataUrl() { + return `${window.ProcessMaker?.app?.url}/requests`; + } + }, mounted() { this.setFields(); this.pmql = `requester = "${Processmaker.user.username}"`; diff --git a/src/components/renderer/form-tasks.vue b/src/components/renderer/form-tasks.vue index 1fea03d38..77b247279 100755 --- a/src/components/renderer/form-tasks.vue +++ b/src/components/renderer/form-tasks.vue @@ -46,7 +46,7 @@
- +
@@ -82,6 +82,11 @@ export default { (window.SharedComponents && window.SharedComponents.TasksHome) || {} }; }, + computed: { + noDataUrl() { + return `${window.ProcessMaker?.app?.url}/tasks`; + } + }, mounted() { this.setFields(); this.pmql = `(user_id = ${ProcessMaker.user.id}) AND (status = "In Progress")`; diff --git a/src/main.js b/src/main.js index b601ea2c1..054840fe0 100644 --- a/src/main.js +++ b/src/main.js @@ -110,13 +110,17 @@ const cacheEnabled = document.head.querySelector( const cacheTimeout = document.head.querySelector( "meta[name='screen-cache-timeout']" ); - +// Get the current protocol, hostname, and port +const { protocol, hostname, port } = window.location; window.ProcessMaker = { isStub: true, user: { id: 1, lang: "en" }, + app: { + url: `${protocol}//${hostname}:${port}` // Create a URL with the current port + }, apiClient: { create() { return this;