Skip to content
Snippets Groups Projects

Add possibility to use Favorites

Merged CaTasTrOOf requested to merge CaTasTrOOf/wotwizard-ui:favourites-filter into master
+ 11
5
@@ -158,22 +158,28 @@ export default {
if (this.currentSort == "uid") {
if (a["uid"].toLowerCase() < b["uid"].toLowerCase())
return -1 * modifier
return 1 * modifier
if (a["uid"].toLowerCase() > b["uid"].toLowerCase())
return 1 * modifier
} else if (this.currentSort == "pubkey") {
if (a["pubkey"].toLowerCase() < b["pubkey"].toLowerCase())
return -1 * modifier
return 1 * modifier
if (a["pubkey"].toLowerCase() > b["pubkey"].toLowerCase())
return 1 * modifier
} else if (this.currentSort == "date_sortie") {
if (this.adhesion) {
if (a["limitDate"] < b["limitDate"]) return -1 * modifier
return 1 * modifier
if (a["limitDate"] > b["limitDate"]) return 1 * modifier
} else if (this.certif) {
if (
a["received_certifications"]["limit"] <
b["received_certifications"]["limit"]
)
return -1 * modifier
return 1 * modifier
if (
a["received_certifications"]["limit"] >
b["received_certifications"]["limit"]
)
return 1 * modifier
} else {
let minA = Math.min(
a["limitDate"],
@@ -184,7 +190,7 @@ export default {
b["received_certifications"]["limit"]
)
if (minA < minB) return -1 * modifier
return 1 * modifier
if (minA > minB) return 1 * modifier
}
}
Loading