Skip to content

Commit

Permalink
FOUR-13078: Clicking in view all request shows server error
Browse files Browse the repository at this point in the history
  • Loading branch information
Rodrigo Quelca committed Feb 5, 2024
1 parent ea92b74 commit 1b2ff33
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/components/renderer/form-empty-table.vue
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ export default {
},
methods: {
openLink() {
window.open(this.link, "_blank");
window.open(this.url, "_blank");
}
}
};
Expand Down
7 changes: 6 additions & 1 deletion src/components/renderer/form-requests.vue
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@
</vuetable>
</div>
<div v-else>
<formEmpty link="Requests" title="No Requests to Show" url="/requests" />
<formEmpty link="Requests" title="No Requests to Show" :url="noDataUrl" />
</div>
</template>

Expand Down Expand Up @@ -81,6 +81,11 @@ export default {
]
};
},
computed: {
noDataUrl() {
return `${window.ProcessMaker?.app?.url}requests`;
}
},
mounted() {
this.setFields();
this.pmql = `requester = "${Processmaker.user.username}"`;
Expand Down
7 changes: 6 additions & 1 deletion src/components/renderer/form-tasks.vue
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@
<component :is="tasksPreview" ref="preview-sidebar" />
</div>
<div v-else>
<formEmpty link="Tasks" title="No tasks in sight" url="/tasks" />
<formEmpty link="Tasks" title="No tasks in sight" :url="noDataUrl" />
</div>
</template>

Expand Down Expand Up @@ -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")`;
Expand Down
3 changes: 3 additions & 0 deletions src/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -117,6 +117,9 @@ window.ProcessMaker = {
id: 1,
lang: "en"
},
app: {
url: window.location.href
},
apiClient: {
create() {
return this;
Expand Down

0 comments on commit 1b2ff33

Please sign in to comment.