Merge branch 'main' of github.com:LazyBachelor/LazyPM
This commit is contained in:
@@ -2,6 +2,7 @@ package handler
|
|||||||
|
|
||||||
import (
|
import (
|
||||||
"net/http"
|
"net/http"
|
||||||
|
"sort"
|
||||||
"strings"
|
"strings"
|
||||||
|
|
||||||
"github.com/LazyBachelor/LazyPM/internal/models"
|
"github.com/LazyBachelor/LazyPM/internal/models"
|
||||||
@@ -20,6 +21,11 @@ func DashboardHandler(w http.ResponseWriter, r *http.Request) {
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Sort issues by highest priority first (4 -> 0)
|
||||||
|
sort.Slice(issues, func(i, j int) bool {
|
||||||
|
return issues[i].Priority > issues[j].Priority
|
||||||
|
})
|
||||||
|
|
||||||
// Check if board view is requested
|
// Check if board view is requested
|
||||||
isBoardView := r.URL.Query().Get("board") == "true"
|
isBoardView := r.URL.Query().Get("board") == "true"
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user