]> git.plutz.net Git - serve0/blobdiff - widgets.sh
ordering by grouplength
[serve0] / widgets.sh
index 896ca6cdfab3d97ebdcfd59374221f618100a336..ff6f2ddfacc158f91daa266c67bdb368bdb5527b 100644 (file)
@@ -56,6 +56,7 @@ fi
 [ "$ORDER" = Name   ] && w_coname=checked
 [ "$ORDER" = Date   ] && w_codate=checked
 [ "$ORDER" = Length ] && w_colength=checked
+[ "$ORDER" = Group  ] && w_cogroup=checked
 
 w_bookmarks(){
   local name='' cf='' cs='' bm="$_DATA/.index/bookmarks" proposed_name=''
@@ -116,11 +117,12 @@ w_search(){
       [option value=Name %s Name]
       [option value=Date %s Date]
       [option value=Length %s Length]
+      [option value=Group %s Grouplength]
     ]
     [input name=s placeholder=Search value="%s"]
   ]
   ' \
-  "$w_coname" "$w_codate" "$w_colength" \
+  "$w_coname" "$w_codate" "$w_colength" "$w_cogroup" \
   "$(HTML "$SEARCH")"
 }
 
@@ -221,11 +223,11 @@ w_advsearch(){
             [option value=Name %s Name]
             [option value=Date %s Date]
             [option value=Length %s Length]
+            [option value=Group %s Grouplength]
           ][button type=submit Apply Filter]]
           ]' \
-          "$w_coname" \
-          "$w_codate" \
-          "$w_colength"
+          "$w_coname" "$w_codate" \
+          "$w_colength" "$w_cogroup"
 }
 
 w_tagging(){