@processmaker/screen-builder 2.77.17 → 2.78.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@processmaker/screen-builder",
3
- "version": "2.77.17",
3
+ "version": "2.78.0",
4
4
  "scripts": {
5
5
  "serve": "vue-cli-service serve",
6
6
  "build": "vue-cli-service build",
@@ -115,11 +115,7 @@ export default {
115
115
  .then((response) => {
116
116
  this.spin = 0;
117
117
  const instance = response.data;
118
- if (this.$cookies.get("isMobile")) {
119
- window.location = `/requests/mobile/${instance.id}?fromRedirect=true`;
120
- } else {
121
- window.location = `/requests/${instance.id}?fromRedirect=true`;
122
- }
118
+ window.location = `/requests/${instance.id}?fromRedirect=true`;
123
119
  })
124
120
  .catch((err) => {
125
121
  this.disabled = false;
@@ -6,14 +6,6 @@
6
6
  :key="`category-${index}`"
7
7
  class="mt-3"
8
8
  >
9
- <!--
10
- <h5 class="mb-n2">
11
- {{ index }}
12
- <span class="badge badge-pill badge-secondary">
13
- {{ category.length }}
14
- </span>
15
- </h5>
16
- -->
17
9
  <b-container fluid>
18
10
  <b-card-group>
19
11
  <template v-for="(process, id) in category">
@@ -64,40 +56,37 @@ export default {
64
56
  },
65
57
  fetch() {
66
58
  Vue.nextTick(() => {
67
-
68
- window.ProcessMaker.apiClient
69
- .get(
70
- `start_processes?page=${this.page}&per_page=${this.perPage}&filter=${
71
- this.filter
72
- }&order_by=category.name,name` +
73
- "&order_direction=asc,asc" +
74
- "&include=events,categories" +
75
- "&without_event_definitions=true"
76
- )
77
- .then((response) => {
78
- const { data } = response;
79
- // Empty processes
80
- this.processes = {};
81
- // Now populate our processes array with data for rendering
82
- this.populate(data.data);
83
- // Do initial filter
84
- // Set data in paginate
85
- data.meta.from -= 1;
86
- this.$refs.listProcess.data = data;
87
- this.$refs.listProcess.setPaginationData(data.meta);
88
- const dataControls = {
89
- count: "0",
90
- showControl: true,
91
- showAvatar: false,
92
- colorTextStart: "color: #57646F",
93
- url: ""
94
- };
95
- const tasksDropdown = [];
96
- this.$emit("startControl", { dataControls, tasksDropdown });
97
- })
98
- .catch(() => {
99
- this.error = true;
100
- });
59
+ window.ProcessMaker.apiClient
60
+ .get(
61
+ `start_processes?page=${this.page}&per_page=${this.perPage}&filter=${this.filter}&order_by=category.name,name` +
62
+ "&order_direction=asc,asc" +
63
+ "&include=events,categories" +
64
+ "&without_event_definitions=true"
65
+ )
66
+ .then((response) => {
67
+ const { data } = response;
68
+ // Empty processes
69
+ this.processes = {};
70
+ // Now populate our processes array with data for rendering
71
+ this.populate(data.data);
72
+ // Do initial filter
73
+ // Set data in paginate
74
+ data.meta.from -= 1;
75
+ this.$refs.listProcess.data = data;
76
+ this.$refs.listProcess.setPaginationData(data.meta);
77
+ const dataControls = {
78
+ count: "0",
79
+ showControl: true,
80
+ showAvatar: false,
81
+ colorTextStart: "color: #57646F",
82
+ url: ""
83
+ };
84
+ const tasksDropdown = [];
85
+ this.$emit("startControl", { dataControls, tasksDropdown });
86
+ })
87
+ .catch(() => {
88
+ this.error = true;
89
+ });
101
90
  });
102
91
  },
103
92
  populate(data) {
@@ -84,7 +84,7 @@ export default {
84
84
  },
85
85
  mounted() {
86
86
  this.setFields();
87
- this.pmql = `(user_id = ${ProcessMaker.user.id})`;
87
+ this.pmql = `(user_id = ${ProcessMaker.user.id}) AND (status = "In Progress")`;
88
88
  this.fetch();
89
89
  this.$root.$on("dropdownSelectionTask", this.fetchData);
90
90
  this.$root.$on("searchTask", this.fetchSearch);
@@ -293,17 +293,12 @@ export default {
293
293
  : "text-dark";
294
294
  },
295
295
  fetchData(selectedOption) {
296
- if (selectedOption === "In Progress") {
296
+ if (selectedOption === "In Progress" || selectedOption === "all") {
297
297
  this.filterDropdowns = "";
298
298
  this.pmql = `(user_id = ${ProcessMaker.user.id}) AND (status = "In Progress")`;
299
299
  }
300
- if (selectedOption === "all") {
301
- this.filterDropdowns = "";
302
- this.pmql = `(user_id = ${ProcessMaker.user.id})`;
303
- }
304
300
  if (selectedOption === "Overdue") {
305
301
  this.filterDropdowns = "overdue=true";
306
- this.pmql = "";
307
302
  }
308
303
  this.fetch();
309
304
  },