summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/logikorr/servlet.clj12
-rw-r--r--war/style.css11
2 files changed, 19 insertions, 4 deletions
diff --git a/src/logikorr/servlet.clj b/src/logikorr/servlet.clj
index 00440d4..37038a9 100644
--- a/src/logikorr/servlet.clj
+++ b/src/logikorr/servlet.clj
@@ -104,10 +104,14 @@
student]
[:tr
[:td (str id)]
- [:td (map (fn [num]
- (html [:span {:style "min-width: 2em; display: inline-block;"} num]
- " "))
- score)]
+ [:td (mapcat (fn [nums]
+ (html
+ [:span.score-group {}
+ (map (fn [num]
+ (html [:span.score-entry num]
+ " "))
+ nums)]))
+ (partition 4 4 [] score))]
[:td last-name]
[:td first-name]]))
students)]
diff --git a/war/style.css b/war/style.css
index a7822e3..6830118 100644
--- a/war/style.css
+++ b/war/style.css
@@ -33,3 +33,14 @@ table.score-table {
table.score-table td {
padding: 5px 5px 5px 5px;
}
+
+.score-group {
+ border: 1px solid gray;
+ padding: 2px 2px 2px 2px;
+ margin-left: 5px; margin-right: 5px;
+ background-color: #eee;
+}
+.score-entry {
+ min-width: 2em;
+ display: inline-block;
+}