PMCORE-3456:Advanced Search Clear Order does not dissapear after being clicked PMCORE_3.7.0-5487
This commit is contained in:
@@ -100,6 +100,7 @@ import api from "../../api/index";
|
||||
import utils from "../../utils/utils";
|
||||
import defaultMixin from "./defaultMixins.js";
|
||||
import customMixin from "./customMixins";
|
||||
import { Event } from "vue-tables-2";
|
||||
|
||||
export default {
|
||||
name: "AdvancedSearch",
|
||||
@@ -183,7 +184,6 @@ export default {
|
||||
selectAllMode: "page",
|
||||
programmatic: false,
|
||||
},
|
||||
sortable: [],
|
||||
sortable: ["case_number"],
|
||||
requestFunction(data) {
|
||||
return this.$parent.$parent.getCasesForVueTable(data);
|
||||
@@ -202,6 +202,9 @@ export default {
|
||||
}
|
||||
};
|
||||
},
|
||||
mounted() {
|
||||
Event.$on('clearSortEvent', this.clearSort);
|
||||
},
|
||||
watch: {
|
||||
id: function() {
|
||||
this.$refs.vueTable.refresh();
|
||||
@@ -594,6 +597,14 @@ export default {
|
||||
onPostNotes() {
|
||||
this.$refs["vueTable"].getData();
|
||||
},
|
||||
/**
|
||||
* Reset the sort in the table
|
||||
*/
|
||||
clearSort() {
|
||||
if (this.$refs['vueTable']) {
|
||||
this.$refs['vueTable'].setOrder(false);
|
||||
}
|
||||
},
|
||||
},
|
||||
};
|
||||
</script>
|
||||
|
||||
Reference in New Issue
Block a user