adamc@325: table t1 : {Id : int, A : int, B : string, C : float, D : bool}
adamc@325:
adamc@325: open Crud.Make(struct
adamc@325: val tab = t1
adamc@325:
adamc@325: val title = "Crud1"
adamc@325:
adamc@325: val cols = {
adamc@339: A = {
adamc@339: Nam = "A",
adamc@339: Show = txt _,
adamc@339: Widget = fn nm :: Name => ,
adamc@341: WidgetPopulated = fn (nm :: Name) n => ,
adamc@339: Parse = readError _,
adamc@349: Inject = _
adamc@339: },
adamc@339: B = {
adamc@339: Nam = "B",
adamc@339: Show = txt _,
adamc@339: Widget = fn nm :: Name => ,
adamc@341: WidgetPopulated = fn (nm :: Name) s => ,
adamc@339: Parse = readError _,
adamc@349: Inject = _
adamc@339: },
adamc@339: C = {
adamc@339: Nam = "C",
adamc@339: Show = txt _,
adamc@339: Widget = fn nm :: Name => ,
adamc@341: WidgetPopulated = fn (nm :: Name) n => ,
adamc@339: Parse = readError _,
adamc@349: Inject = _
adamc@339: },
adamc@339: D = {
adamc@339: Nam = "D",
adamc@339: Show = txt _,
adamc@347: Widget = fn nm :: Name => ,
adamc@347: WidgetPopulated = fn (nm :: Name) b => ,
adamc@347: Parse = fn x => x,
adamc@349: Inject = _
adamc@339: }
adamc@325: }
adamc@325: end)