[Fencommits] fenserve: returns to table go to the right category
Tuukka Hastrup
Tuukka.Hastrup at iki.fi
Thu May 31 21:15:28 EEST 2007
Thu May 31 21:14:55 EEST 2007 Tuukka Hastrup <Tuukka.Hastrup at iki.fi>
* returns to table go to the right category
diff -rN -u old-fenserve/fendata/Main.hs new-fenserve/fendata/Main.hs
--- old-fenserve/fendata/Main.hs 2007-05-31 21:15:28.000000000 +0300
+++ new-fenserve/fendata/Main.hs 2007-05-31 21:15:28.000000000 +0300
@@ -248,14 +248,14 @@
( hif (null items) $ ital ( "There are no ", plural cat,
" in the database. " ) & mdot
, formP (?root++"newItem")
- ( hidden "returnTo" "table"
+ ( hidden "returnTo" $ "table?cat="++cat
, hidden "cat" cat
, button $ bold ("[New ", cat, "]") ) )
, catFor (Map.toList allItems) $ \(id, Item fields cats) ->
hif (cat `Set.member` cats) $ tag "tr" [] $
catFor cols $ \col -> tag "td" [] $
- qlink ("item/"++show id) [P "returnTo" "table"]
+ qlink ("item/"++show id) [P "returnTo" $ "table?cat="++cat]
(fields Map.! col) ) )
where cat = lookI "cat" (head $ Map.keys schema)
More information about the Fencommits
mailing list