Merge branch 'release/3.7.0' of https://bitbucket.org/colosa/processmaker into bugfix/PMCORE-3328

This commit is contained in:
Henry Jordan
2021-09-22 14:54:20 +00:00
18 changed files with 357 additions and 69 deletions

View File

@@ -40,9 +40,27 @@ export let menu = {
headers: { headers: {
'Authorization': 'Bearer ' + window.config.SYS_CREDENTIALS.accessToken, 'Authorization': 'Bearer ' + window.config.SYS_CREDENTIALS.accessToken,
"Accept-Language": window.config.SYS_LANG "Accept-Language": window.config.SYS_LANG
} }
}); });
}, },
/**
* Get the counter of a specific custom case list
* @param {Object} data
* @returns
*/
getTooltipCaseList(data) {
return axios.get(
window.config.SYS_SERVER_API +
'/api/1.0/' +
window.config.SYS_WORKSPACE +
'/home/' + data.page + '/counter/caseList/' + data.id, {
headers: {
'Authorization': 'Bearer ' + window.config.SYS_CREDENTIALS.accessToken,
"Accept-Language": window.config.SYS_LANG
}
}
);
},
/** /**
* Get the highlight * Get the highlight
* @returns * @returns

View File

@@ -1,7 +1,7 @@
<template> <template>
<div class="pm-vue-card"> <div class="pm-vue-card">
<div class="card pm-vue-card-inside" style="width: 20rem" @dblclick="dblClick"> <div class="card pm-vue-card-inside" style="width: 20rem" @dblclick="dblClick">
<div class="card-body"> <div class="card-view-body">
<slot> </slot> <slot> </slot>
</div> </div>
</div> </div>
@@ -42,7 +42,7 @@ export default {
.pm-vue-card-inside:hover { .pm-vue-card-inside:hover {
background-color: #cfd9e4; background-color: #cfd9e4;
} }
.card-body { .card-view-body {
height: 266px; height: 266px;
overflow-x: hidden; overflow-x: hidden;
} }

View File

@@ -14,19 +14,20 @@
</div> </div>
</b-col> </b-col>
<b-col sm="4" class="pm-multiview-header-actions-buttons"> <b-col sm="4" class="pm-multiview-header-actions-buttons">
<button <b-button
v-for="action in data.actions" v-for="action in data.actions"
:key="action.id" :key="action.id"
@click="action.onClick(action)" @click="action.onClick(action)"
class="pm-multiview-header-button" class="pm-multiview-header-button"
:title="action.title" :title="action.title"
variant="primary"
> >
<div> <div>
<span> <span>
<i :class="action.icon"></i> <i :class="action.icon"></i>
</span> </span>
</div> </div>
</button> </b-button>
</b-col> </b-col>
</b-row> </b-row>
</div> </div>

View File

@@ -39,20 +39,26 @@
" "
> >
<span :class="item.specialType != 'header'?'vsm--title': 'vsm--header vsm--title--header'"> <span :class="item.specialType != 'header'?'vsm--title': 'vsm--header vsm--title--header'">
<template v-if="itemTaskList"> <custom-tooltip
<custom-tooltip :data="item"
:data="item" ref="tooltip"
ref="tooltip" ></custom-tooltip>
></custom-tooltip> <span v-if="item.sortable">
</template> <b-icon
<template v-else> :id="`gear-${item.id}`"
<span> {{ item.title }} </span> :icon="item.sortIcon"
</template> @click="onClickSortSettings"
<b-icon @mouseover="hoverHandler"
v-if="item.sortable" @mouseleave="unhoverHandler"
:icon="item.sortIcon" v-bind:style="{color: sortColor}"
@click="onClickSortSettings" ></b-icon>
></b-icon> <b-tooltip
:target="`gear-${item.id}`"
triggers="hover"
>
{{ $t("ID_CASES_LIST_SETTINGS") }}
</b-tooltip>
</span>
</span> </span>
</template> </template>
</transition> </transition>
@@ -238,6 +244,7 @@ export default {
CASES_PAUSED: "paused", CASES_PAUSED: "paused",
CASES_SELFSERVICE: "unassigned" CASES_SELFSERVICE: "unassigned"
}, },
sortColor: "white",
}; };
}, },
mounted() { mounted() {
@@ -568,6 +575,12 @@ export default {
event.stopPropagation(); event.stopPropagation();
this.$refs["modal"].show(); this.$refs["modal"].show();
}, },
hoverHandler() {
this.sortColor = '#02feff';
},
unhoverHandler() {
this.sortColor = 'white';
}
}, },
inject: ["emitActiveShow", "emitItemClick", "emitItemUpdate"], inject: ["emitActiveShow", "emitItemClick", "emitItemUpdate"],
}; };

View File

@@ -12,6 +12,9 @@
v-if="showTooltip" v-if="showTooltip"
> >
{{ labelTooltip }} {{ labelTooltip }}
<p v-if="labelDescription !== ''">
{{ labelDescription }}
</p>
</b-tooltip> </b-tooltip>
</span> </span>
</template> </template>
@@ -27,6 +30,7 @@ export default {
data() { data() {
return { return {
labelTooltip: "", labelTooltip: "",
labelDescription: "",
hovering: "", hovering: "",
show: false, show: false,
menuMap: { menuMap: {
@@ -54,6 +58,7 @@ export default {
*/ */
unhoverHandler() { unhoverHandler() {
this.labelTooltip = ""; this.labelTooltip = "";
this.labelDescription = "";
this.showTooltip = false; this.showTooltip = false;
this.isLoading = false; this.isLoading = false;
clearTimeout(this.hovering); clearTimeout(this.hovering);
@@ -63,11 +68,21 @@ export default {
*/ */
setTooltip() { setTooltip() {
let that = this; let that = this;
api.menu.getTooltip(that.data.page).then((response) => { if (this.menuMap[this.data.id]) {
that.showTooltip = true; api.menu.getTooltip(that.data.page).then((response) => {
that.isLoading = false; that.showTooltip = true;
that.labelTooltip = response.data.label; that.isLoading = false;
}); that.labelTooltip = response.data.label;
});
} else {
api.menu.getTooltipCaseList(that.data)
.then((response) => {
that.showTooltip = true;
that.isLoading = false;
that.labelTooltip = response.data.label;
that.labelDescription = response.data.description;
});
}
}, },
/** /**
* Set bold the label * Set bold the label

View File

@@ -673,7 +673,7 @@ export default {
that.$emit("updateSettings", { that.$emit("updateSettings", {
data: data, data: data,
key: "orderBy", key: "orderBy",
parent: that.data.pageParent, page: that.data.pageParent,
type: "custom", type: "custom",
id: that.data.customListId id: that.data.customListId
}); });
@@ -687,7 +687,7 @@ export default {
this.$emit("updateSettings", { this.$emit("updateSettings", {
data: val, data: val,
key: "columns", key: "columns",
parent: this.data.pageParent, page: this.data.pageParent,
type: "custom", type: "custom",
id: this.data.customListId id: this.data.customListId
}); });
@@ -1024,7 +1024,7 @@ export default {
this.$emit("updateSettings", { this.$emit("updateSettings", {
data: newFilters, data: newFilters,
key: "filters", key: "filters",
parent: this.data.pageParent, page: this.data.pageParent,
type: "custom", type: "custom",
id: this.data.customListId id: this.data.customListId
}); });

View File

@@ -2,6 +2,15 @@
<div id="v-draft" ref="v-draft" class="v-container-draft"> <div id="v-draft" ref="v-draft" class="v-container-draft">
<button-fleft :data="newCase"></button-fleft> <button-fleft :data="newCase"></button-fleft>
<modal-new-request ref="newRequest"></modal-new-request> <modal-new-request ref="newRequest"></modal-new-request>
<b-alert
:show="dataAlert.dismissCountDown"
dismissible
:variant="dataAlert.variant"
@dismissed="dataAlert.dismissCountDown = 0"
@dismiss-count-down="countDownChanged"
>
{{ dataAlert.message }}
</b-alert>
<CasesFilter <CasesFilter
:filters="filters" :filters="filters"
:title="$t('ID_DRAFT')" :title="$t('ID_DRAFT')"
@@ -186,6 +195,10 @@
</span> </span>
</div> </div>
</VueListView> </VueListView>
<ModalComments
ref="modal-comments"
@postNotes="onPostNotes"
></ModalComments>
</div> </div>
</template> </template>
@@ -193,6 +206,7 @@
import HeaderCounter from "../../components/home/HeaderCounter.vue"; import HeaderCounter from "../../components/home/HeaderCounter.vue";
import ButtonFleft from "../../components/home/ButtonFleft.vue"; import ButtonFleft from "../../components/home/ButtonFleft.vue";
import ModalNewRequest from "../ModalNewRequest.vue"; import ModalNewRequest from "../ModalNewRequest.vue";
import ModalComments from "../modal/ModalComments.vue";
import CasesFilter from "../../components/search/CasesFilter"; import CasesFilter from "../../components/search/CasesFilter";
import TaskCell from "../../components/vuetable/TaskCell.vue"; import TaskCell from "../../components/vuetable/TaskCell.vue";
import api from "../../api/index"; import api from "../../api/index";
@@ -216,12 +230,19 @@ export default {
Ellipsis, Ellipsis,
MultiviewHeader, MultiviewHeader,
VueCardView, VueCardView,
VueListView VueListView,
ModalComments
}, },
props: ["defaultOption", "settings"], props: ["defaultOption", "settings"],
data() { data() {
let that = this; let that = this;
return { return {
dataAlert: {
dismissSecs: 5,
dismissCountDown: 0,
message: "",
variant: "info",
},
columMap: { columMap: {
case_number: "APP_NUMBER", case_number: "APP_NUMBER",
case_title: "DEL_TITLE", case_title: "DEL_TITLE",
@@ -326,7 +347,7 @@ export default {
that.$emit("updateSettings", { that.$emit("updateSettings", {
data: data, data: data,
key: "orderBy", key: "orderBy",
parent: this.page, page: "draft",
type: "normal", type: "normal",
id: this.id id: this.id
}); });
@@ -337,7 +358,7 @@ export default {
this.$emit("updateSettings", { this.$emit("updateSettings", {
data: val, data: val,
key: "columns", key: "columns",
parent: this.page, page: "draft",
type: "normal", type: "normal",
id: this.id id: this.id
}); });
@@ -562,7 +583,7 @@ export default {
this.$emit("updateSettings", { this.$emit("updateSettings", {
data: newFilters, data: newFilters,
key: "filters", key: "filters",
parent: this.page, page: "draft",
type: "normal", type: "normal",
id: this.id id: this.id
}); });
@@ -624,13 +645,48 @@ export default {
name: "case note", name: "case note",
icon: "far fa-comments", icon: "far fa-comments",
fn: function() { fn: function() {
that.openCaseDetail(data); that.openComments(data);
} }
}, },
} }
} }
} }
}, },
/**
* Show the alert message
* @param {string} message - message to be displayen in the body
* @param {string} type - alert type
*/
showAlert(message, type) {
this.dataAlert.message = message;
this.dataAlert.variant = type || "info";
this.dataAlert.dismissCountDown = this.dataAlert.dismissSecs;
},
/**
* Updates the alert dismiss value to update
* dismissCountDown and decrease
* @param {mumber}
*/
countDownChanged(dismissCountDown) {
this.dataAlert.dismissCountDown = dismissCountDown;
},
/**
* Open the case notes modal
* @param {object} data - needed to create the data
*/
openComments(data) {
let that = this;
api.cases.open(_.extend({ ACTION: "todo" }, data)).then(() => {
that.$refs["modal-comments"].dataCase = data;
that.$refs["modal-comments"].show();
});
},
/**
* Post notes event handler
*/
onPostNotes() {
this.$refs["vueTable"].getData();
},
}, },
}; };
</script> </script>

View File

@@ -127,13 +127,19 @@ export default {
parseInt(window.config.FORMATS.casesListRefreshTime) * 1000 parseInt(window.config.FORMATS.casesListRefreshTime) * 1000
); );
// adding eventBus listener // adding eventBus listener
eventBus.$on('sort-menu', (data) => { eventBus.$on('sort-menu', (data) => {
let page;
let newData = []; let newData = [];
data.forEach(item => newData.push({id: item.id})); data.forEach(item => {
newData.push({id: item.id});
if (!page) {
page = item.page;
}
});
that.updateSettings({ that.updateSettings({
data: newData, data: newData,
key: "customCaseListOrder", key: "customCaseListOrder",
parent: this.page, page: page,
type: "normal", type: "normal",
id: this.id id: this.id
}); });
@@ -227,21 +233,21 @@ export default {
*/ */
updateSettings (params){ updateSettings (params){
if (params.type === "custom") { if (params.type === "custom") {
if (!this.config.setting[params.parent]) { if (!this.config.setting[params.page]) {
this.config.setting[params.parent] = {}; this.config.setting[params.page] = {};
} }
if (!this.config.setting[params.parent]["customCaseList"]) { if (!this.config.setting[params.page]["customCaseList"]) {
this.config.setting[params.parent]["customCaseList"] = {}; this.config.setting[params.page]["customCaseList"] = {};
} }
if (!this.config.setting[params.parent].customCaseList[params.id]) { if (!this.config.setting[params.page].customCaseList[params.id]) {
this.config.setting[params.parent].customCaseList[params.id] = {} this.config.setting[params.page].customCaseList[params.id] = {}
} }
this.config.setting[params.parent].customCaseList[params.id][params.key] = params.data; this.config.setting[params.page].customCaseList[params.id][params.key] = params.data;
} else { } else {
if (!this.config.setting[this.page]) { if (!this.config.setting[params.page]) {
this.config.setting[this.page] = {}; this.config.setting[params.page] = {};
} }
this.config.setting[this.page][params.key] = params.data; this.config.setting[params.page][params.key] = params.data;
} }
api.config api.config
.put(this.config) .put(this.config)
@@ -308,9 +314,9 @@ export default {
if (data[i].customCasesList) { if (data[i].customCasesList) {
data[i]["child"] = this.sortCustomCasesList( data[i]["child"] = this.sortCustomCasesList(
data[i].customCasesList, data[i].customCasesList,
this.config.setting[this.page] && this.config.setting[data[i]["page"]] &&
this.config.setting[this.page].customCaseListOrder this.config.setting[data[i]["page"]].customCaseListOrder
? this.config.setting[this.page].customCaseListOrder ? this.config.setting[data[i]["page"]].customCaseListOrder
: [] : []
); );
data[i]["sortable"] = data[i].customCasesList.length > 1; data[i]["sortable"] = data[i].customCasesList.length > 1;

View File

@@ -4,6 +4,15 @@
<modal-new-request ref="newRequest"></modal-new-request> <modal-new-request ref="newRequest"></modal-new-request>
<ModalPauseCase ref="modal-pause-case"></ModalPauseCase> <ModalPauseCase ref="modal-pause-case"></ModalPauseCase>
<ModalReassignCase ref="modal-reassign-case"></ModalReassignCase> <ModalReassignCase ref="modal-reassign-case"></ModalReassignCase>
<b-alert
:show="dataAlert.dismissCountDown"
dismissible
:variant="dataAlert.variant"
@dismissed="dataAlert.dismissCountDown = 0"
@dismiss-count-down="countDownChanged"
>
{{ dataAlert.message }}
</b-alert>
<CasesFilter <CasesFilter
:filters="filters" :filters="filters"
:title="$t('ID_INBOX')" :title="$t('ID_INBOX')"
@@ -209,6 +218,10 @@
</span> </span>
</div> </div>
</VueListView> </VueListView>
<ModalComments
ref="modal-comments"
@postNotes="onPostNotes"
></ModalComments>
</div> </div>
</template> </template>
@@ -227,6 +240,7 @@ import defaultMixins from "./defaultMixins";
import Ellipsis from '../../components/utils/ellipsis.vue'; import Ellipsis from '../../components/utils/ellipsis.vue';
import ModalPauseCase from '../modal/ModalPauseCase.vue'; import ModalPauseCase from '../modal/ModalPauseCase.vue';
import ModalReassignCase from '../modal/ModalReassignCase.vue'; import ModalReassignCase from '../modal/ModalReassignCase.vue';
import ModalComments from "../modal/ModalComments.vue";
import { Event } from 'vue-tables-2'; import { Event } from 'vue-tables-2';
import CurrentUserCell from "../../components/vuetable/CurrentUserCell.vue"; import CurrentUserCell from "../../components/vuetable/CurrentUserCell.vue";
@@ -246,11 +260,18 @@ export default {
ModalPauseCase, ModalPauseCase,
ModalReassignCase, ModalReassignCase,
CurrentUserCell, CurrentUserCell,
ModalComments
}, },
props: ["defaultOption", "settings"], props: ["defaultOption", "settings"],
data() { data() {
let that = this; let that = this;
return { return {
dataAlert: {
dismissSecs: 5,
dismissCountDown: 0,
message: "",
variant: "info",
},
columMap: { columMap: {
case_number: "APP_NUMBER", case_number: "APP_NUMBER",
case_title: "DEL_TITLE", case_title: "DEL_TITLE",
@@ -361,7 +382,7 @@ export default {
that.$emit("updateSettings", { that.$emit("updateSettings", {
data: data, data: data,
key: "orderBy", key: "orderBy",
parent: this.page, page: "inbox",
type: "normal", type: "normal",
id: this.id id: this.id
}); });
@@ -375,7 +396,7 @@ export default {
this.$emit("updateSettings", { this.$emit("updateSettings", {
data: val, data: val,
key: "columns", key: "columns",
parent: this.page, page: "inbox",
type: "normal", type: "normal",
id: this.id id: this.id
}); });
@@ -637,7 +658,7 @@ export default {
this.$emit("updateSettings", { this.$emit("updateSettings", {
data: newFilters, data: newFilters,
key: "filters", key: "filters",
parent: this.page, page: "inbox",
type: "normal", type: "normal",
id: this.id id: this.id
}); });
@@ -716,7 +737,7 @@ export default {
name: "case note", name: "case note",
icon: "far fa-comments", icon: "far fa-comments",
fn: function() { fn: function() {
that.openCaseDetail(data); that.openComments(data);
} }
}, },
reassign: { reassign: {
@@ -737,6 +758,41 @@ export default {
} }
} }
}, },
/**
* Show the alert message
* @param {string} message - message to be displayen in the body
* @param {string} type - alert type
*/
showAlert(message, type) {
this.dataAlert.message = message;
this.dataAlert.variant = type || "info";
this.dataAlert.dismissCountDown = this.dataAlert.dismissSecs;
},
/**
* Updates the alert dismiss value to update
* dismissCountDown and decrease
* @param {mumber}
*/
countDownChanged(dismissCountDown) {
this.dataAlert.dismissCountDown = dismissCountDown;
},
/**
* Open the case notes modal
* @param {object} data - needed to create the data
*/
openComments(data) {
let that = this;
api.cases.open(_.extend({ ACTION: "todo" }, data)).then(() => {
that.$refs["modal-comments"].dataCase = data;
that.$refs["modal-comments"].show();
});
},
/**
* Post notes event handler
*/
onPostNotes() {
this.$refs["vueTable"].getData();
},
}, },
}; };
</script> </script>

View File

@@ -236,7 +236,7 @@ export default {
that.$emit("updateSettings", { that.$emit("updateSettings", {
data: data, data: data,
key: "orderBy", key: "orderBy",
parent: this.page, page: "MyCases",
type: "normal", type: "normal",
id: this.id id: this.id
}); });
@@ -247,7 +247,7 @@ export default {
this.$emit("updateSettings", { this.$emit("updateSettings", {
data: val, data: val,
key: "columns", key: "columns",
parent: this.page, page: "MyCases",
type: "normal", type: "normal",
id: this.id id: this.id
}); });
@@ -674,7 +674,7 @@ export default {
this.$emit("updateSettings", { this.$emit("updateSettings", {
data: newFilters, data: newFilters,
key: "filters", key: "filters",
parent: this.page, page: "MyCases",
type: "normal", type: "normal",
id: this.id id: this.id
}); });

View File

@@ -3,6 +3,15 @@
<button-fleft :data="newCase"></button-fleft> <button-fleft :data="newCase"></button-fleft>
<modal-new-request ref="newRequest"></modal-new-request> <modal-new-request ref="newRequest"></modal-new-request>
<ModalReassignCase ref="modal-reassign-case"></ModalReassignCase> <ModalReassignCase ref="modal-reassign-case"></ModalReassignCase>
<b-alert
:show="dataAlert.dismissCountDown"
dismissible
:variant="dataAlert.variant"
@dismissed="dataAlert.dismissCountDown = 0"
@dismiss-count-down="countDownChanged"
>
{{ dataAlert.message }}
</b-alert>
<CasesFilter <CasesFilter
:filters="filters" :filters="filters"
:title="$t('ID_PAUSED')" :title="$t('ID_PAUSED')"
@@ -208,6 +217,10 @@
</span> </span>
</div> </div>
</VueListView> </VueListView>
<ModalComments
ref="modal-comments"
@postNotes="onPostNotes"
></ModalComments>
<ModalUnpauseCase ref="modal-unpause-case"></ModalUnpauseCase> <ModalUnpauseCase ref="modal-unpause-case"></ModalUnpauseCase>
</div> </div>
</template> </template>
@@ -227,6 +240,7 @@ import VueListView from "../../components/dataViews/vueListView/VueListView.vue"
import defaultMixins from "./defaultMixins"; import defaultMixins from "./defaultMixins";
import Ellipsis from '../../components/utils/ellipsis.vue'; import Ellipsis from '../../components/utils/ellipsis.vue';
import ModalReassignCase from '../modal/ModalReassignCase.vue'; import ModalReassignCase from '../modal/ModalReassignCase.vue';
import ModalComments from "../modal/ModalComments.vue";
import { Event } from 'vue-tables-2'; import { Event } from 'vue-tables-2';
import CurrentUserCell from "../../components/vuetable/CurrentUserCell.vue"; import CurrentUserCell from "../../components/vuetable/CurrentUserCell.vue";
@@ -246,11 +260,18 @@ export default {
VueListView, VueListView,
ModalReassignCase, ModalReassignCase,
CurrentUserCell, CurrentUserCell,
ModalComments
}, },
props: ["defaultOption", "settings"], props: ["defaultOption", "settings"],
data() { data() {
let that = this; let that = this;
return { return {
dataAlert: {
dismissSecs: 5,
dismissCountDown: 0,
message: "",
variant: "info",
},
columMap: { columMap: {
case_number: "APP_NUMBER", case_number: "APP_NUMBER",
case_title: "DEL_TITLE", case_title: "DEL_TITLE",
@@ -360,7 +381,7 @@ export default {
that.$emit("updateSettings", { that.$emit("updateSettings", {
data: data, data: data,
key: "orderBy", key: "orderBy",
parent: this.page, page: "paused",
type: "normal", type: "normal",
id: this.id id: this.id
}); });
@@ -371,7 +392,7 @@ export default {
this.$emit("updateSettings", { this.$emit("updateSettings", {
data: val, data: val,
key: "columns", key: "columns",
parent: this.page, page: "paused",
type: "normal", type: "normal",
id: this.id id: this.id
}); });
@@ -632,7 +653,7 @@ export default {
this.$emit("updateSettings", { this.$emit("updateSettings", {
data: newFilters, data: newFilters,
key: "filters", key: "filters",
parent: this.page, page: "paused",
type: "normal", type: "normal",
id: this.id id: this.id
}); });
@@ -695,7 +716,7 @@ export default {
name: "case note", name: "case note",
icon: "far fa-comments", icon: "far fa-comments",
fn: function() { fn: function() {
that.openCaseDetail(data); that.openComments(data);
} }
}, },
play: { play: {
@@ -716,6 +737,41 @@ export default {
} }
} }
}, },
/**
* Show the alert message
* @param {string} message - message to be displayen in the body
* @param {string} type - alert type
*/
showAlert(message, type) {
this.dataAlert.message = message;
this.dataAlert.variant = type || "info";
this.dataAlert.dismissCountDown = this.dataAlert.dismissSecs;
},
/**
* Updates the alert dismiss value to update
* dismissCountDown and decrease
* @param {mumber}
*/
countDownChanged(dismissCountDown) {
this.dataAlert.dismissCountDown = dismissCountDown;
},
/**
* Open the case notes modal
* @param {object} data - needed to create the data
*/
openComments(data) {
let that = this;
api.cases.open(_.extend({ ACTION: "todo" }, data)).then(() => {
that.$refs["modal-comments"].dataCase = data;
that.$refs["modal-comments"].show();
});
},
/**
* Post notes event handler
*/
onPostNotes() {
this.$refs["vueTable"].getData();
},
}, },
}; };
</script> </script>

View File

@@ -268,7 +268,6 @@ export default {
//Update the labels //Update the labels
this.dataProcesses = data; this.dataProcesses = data;
this.updateLabels(data);
}, },
/** /**
* Change the options in TOTAL CASES BY PROCESS * Change the options in TOTAL CASES BY PROCESS

View File

@@ -9,6 +9,15 @@
@onRemoveFilter="onRemoveFilter" @onRemoveFilter="onRemoveFilter"
@onUpdateFilters="onUpdateFilters" @onUpdateFilters="onUpdateFilters"
/> />
<b-alert
:show="dataAlert.dismissCountDown"
dismissible
:variant="dataAlert.variant"
@dismissed="dataAlert.dismissCountDown = 0"
@dismiss-count-down="countDownChanged"
>
{{ dataAlert.message }}
</b-alert>
<multiview-header <multiview-header
:data="dataMultiviewHeader" :data="dataMultiviewHeader"
:dataSubtitle="dataSubtitle" :dataSubtitle="dataSubtitle"
@@ -203,6 +212,10 @@
</span> </span>
</div> </div>
</VueListView> </VueListView>
<ModalComments
ref="modal-comments"
@postNotes="onPostNotes"
></ModalComments>
<ModalClaimCase ref="modal-claim-case"></ModalClaimCase> <ModalClaimCase ref="modal-claim-case"></ModalClaimCase>
<ModalPauseCase ref="modal-pause-case"></ModalPauseCase> <ModalPauseCase ref="modal-pause-case"></ModalPauseCase>
</div> </div>
@@ -223,6 +236,7 @@ import VueCardView from "../../components/dataViews/vueCardView/VueCardView.vue"
import VueListView from "../../components/dataViews/vueListView/VueListView.vue"; import VueListView from "../../components/dataViews/vueListView/VueListView.vue";
import defaultMixins from "./defaultMixins"; import defaultMixins from "./defaultMixins";
import ModalPauseCase from '../modal/ModalPauseCase.vue'; import ModalPauseCase from '../modal/ModalPauseCase.vue';
import ModalComments from "../modal/ModalComments.vue";
import { Event } from 'vue-tables-2'; import { Event } from 'vue-tables-2';
import CurrentUserCell from "../../components/vuetable/CurrentUserCell.vue"; import CurrentUserCell from "../../components/vuetable/CurrentUserCell.vue";
@@ -242,11 +256,18 @@ export default {
VueListView, VueListView,
ModalPauseCase, ModalPauseCase,
CurrentUserCell, CurrentUserCell,
ModalComments
}, },
props: ["defaultOption", "settings"], props: ["defaultOption", "settings"],
data() { data() {
let that = this; let that = this;
return { return {
dataAlert: {
dismissSecs: 5,
dismissCountDown: 0,
message: "",
variant: "info",
},
columMap: { columMap: {
case_number: "APP_NUMBER", case_number: "APP_NUMBER",
case_title: "DEL_TITLE", case_title: "DEL_TITLE",
@@ -352,8 +373,7 @@ export default {
that.$emit("updateSettings", { that.$emit("updateSettings", {
data: data, data: data,
key: "orderBy", key: "orderBy",
parent: this.page, page: "unassigned",
type: "normal",
id: this.id id: this.id
}); });
}); });
@@ -363,7 +383,7 @@ export default {
this.$emit("updateSettings", { this.$emit("updateSettings", {
data: val, data: val,
key: "columns", key: "columns",
parent: this.page, page: "unassigned",
type: "normal", type: "normal",
id: this.id id: this.id
}); });
@@ -602,7 +622,7 @@ export default {
this.$emit("updateSettings", { this.$emit("updateSettings", {
data: newFilters, data: newFilters,
key: "filters", key: "filters",
parent: this.page, page: "unassigned",
type: "normal", type: "normal",
id: this.id id: this.id
}); });
@@ -665,7 +685,7 @@ export default {
name: "case note", name: "case note",
icon: "far fa-comments", icon: "far fa-comments",
fn: function() { fn: function() {
that.openCaseDetail(data); that.openComments(data);
} }
}, },
pause: { pause: {
@@ -686,6 +706,41 @@ export default {
} }
} }
}, },
/**
* Show the alert message
* @param {string} message - message to be displayen in the body
* @param {string} type - alert type
*/
showAlert(message, type) {
this.dataAlert.message = message;
this.dataAlert.variant = type || "info";
this.dataAlert.dismissCountDown = this.dataAlert.dismissSecs;
},
/**
* Updates the alert dismiss value to update
* dismissCountDown and decrease
* @param {mumber}
*/
countDownChanged(dismissCountDown) {
this.dataAlert.dismissCountDown = dismissCountDown;
},
/**
* Open the case notes modal
* @param {object} data - needed to create the data
*/
openComments(data) {
let that = this;
api.cases.open(_.extend({ ACTION: "todo" }, data)).then(() => {
that.$refs["modal-comments"].dataCase = data;
that.$refs["modal-comments"].show();
});
},
/**
* Post notes event handler
*/
onPostNotes() {
this.$refs["vueTable"].getData();
},
}, },
}; };
</script> </script>

View File

@@ -3767,6 +3767,12 @@ msgstr "Case List Fields"
msgid "Loading Cases List, please wait..." msgid "Loading Cases List, please wait..."
msgstr "Loading Cases List, please wait..." msgstr "Loading Cases List, please wait..."
# TRANSLATION
# LABEL/ID_CASES_LIST_SETTINGS
#: LABEL/ID_CASES_LIST_SETTINGS
msgid "Cases List Settings"
msgstr "Cases List Settings"
# TRANSLATION # TRANSLATION
# LABEL/ID_CASES_LIST_SETUP # LABEL/ID_CASES_LIST_SETUP
#: LABEL/ID_CASES_LIST_SETUP #: LABEL/ID_CASES_LIST_SETUP

View File

@@ -57439,6 +57439,7 @@ INSERT INTO TRANSLATION (TRN_CATEGORY,TRN_ID,TRN_LANG,TRN_VALUE,TRN_UPDATE_DATE
( 'LABEL','ID_CASES_LIST','en','Cases Lists','2015-04-28') , ( 'LABEL','ID_CASES_LIST','en','Cases Lists','2015-04-28') ,
( 'LABEL','ID_CASES_LIST_FIELDS','en','Case List Fields','2017-02-21') , ( 'LABEL','ID_CASES_LIST_FIELDS','en','Case List Fields','2017-02-21') ,
( 'LABEL','ID_CASES_LIST_GRID_LOADING','en','Loading Cases List, please wait...','2014-01-15') , ( 'LABEL','ID_CASES_LIST_GRID_LOADING','en','Loading Cases List, please wait...','2014-01-15') ,
( 'LABEL','ID_CASES_LIST_SETTINGS','en','Cases List Settings','2021-09-20') ,
( 'LABEL','ID_CASES_LIST_SETUP','en','Case Lists','2017-02-21') , ( 'LABEL','ID_CASES_LIST_SETUP','en','Case Lists','2017-02-21') ,
( 'LABEL','ID_CASES_MENU_ADMIN','en','Process Supervisor','2014-01-15') , ( 'LABEL','ID_CASES_MENU_ADMIN','en','Process Supervisor','2014-01-15') ,
( 'LABEL','ID_CASES_MENU_FOLDERS','en','Cases','2014-01-15') , ( 'LABEL','ID_CASES_MENU_FOLDERS','en','Cases','2014-01-15') ,

View File

@@ -42,7 +42,7 @@ $appDelegation = new AppDelegation();
$delegation = $appDelegation->load($appUid, $delIndex); $delegation = $appDelegation->load($appUid, $delIndex);
// if there are no user in the delegation row, this case is still in selfservice // if there are no user in the delegation row, this case is still in selfservice
if (empty($delegation['USR_UID'])) { if ($delegation['USR_UID'] == "") {
$case->setCatchUser($_SESSION['APPLICATION'], $_SESSION['INDEX'], $_SESSION['USER_LOGGED']); $case->setCatchUser($_SESSION['APPLICATION'], $_SESSION['INDEX'], $_SESSION['USER_LOGGED']);
/*----------------------------------********---------------------------------*/ /*----------------------------------********---------------------------------*/
$licensedFeatures = PMLicensedFeatures::getSingleton(); $licensedFeatures = PMLicensedFeatures::getSingleton();
@@ -71,7 +71,13 @@ if (empty($delegation['USR_UID'])) {
</script>'); </script>');
} }
} else { } else {
G::SendMessageText(G::LoadTranslation('ID_CASE_ALREADY_DERIVATED'), 'error'); $hideMessage = false;
if (isset($_REQUEST['hideMessage'])) {
$hideMessage = $_REQUEST['hideMessage'] === 'true' ? true : false;
}
if ($hideMessage === false) {
G::SendMessageText(G::LoadTranslation('ID_CASE_ALREADY_DERIVATED'), 'error');
}
} }
$validation = (SYS_SKIN != 'uxs') ? 'true' : 'false'; $validation = (SYS_SKIN != 'uxs') ? 'true' : 'false';

View File

@@ -2015,7 +2015,7 @@ class Delegation extends Model
$results = $query->get(); $results = $query->get();
$results->transform(function ($item) { $results->transform(function ($item) {
$abs = new AbstractCases(); $abs = new AbstractCases();
$item['TAS_COLOR'] = $abs->getTaskColor($item['DEL_TASK_DUE_DATE']); $item['TAS_COLOR'] = $abs->getTaskColor($item['DEL_TASK_DUE_DATE'], $item['DEL_THREAD_STATUS']);
$item['TAS_COLOR_LABEL'] = AbstractCases::TASK_COLORS[$item['TAS_COLOR']]; $item['TAS_COLOR_LABEL'] = AbstractCases::TASK_COLORS[$item['TAS_COLOR']];
$item['UNASSIGNED'] = ($item['TAS_ASSIGN_TYPE'] === 'SELF_SERVICE' ? true : false); $item['UNASSIGNED'] = ($item['TAS_ASSIGN_TYPE'] === 'SELF_SERVICE' ? true : false);
$userInfo = User::getInformation($item['USR_ID']); $userInfo = User::getInformation($item['USR_ID']);

View File

@@ -457,7 +457,7 @@ Ext.onReady(function(){
*/ */
function claimCase() { function claimCase() {
Ext.Ajax.request({ Ext.Ajax.request({
url: 'cases_CatchExecute', url: 'cases_CatchExecute?hideMessage=true',
success: function (response, opts) { success: function (response, opts) {
Ext.Ajax.request({ Ext.Ajax.request({
url: 'ajaxListener', url: 'ajaxListener',