summaryrefslogtreecommitdiff
path: root/demo/more/conference.ur
diff options
context:
space:
mode:
Diffstat (limited to 'demo/more/conference.ur')
-rw-r--r--demo/more/conference.ur9
1 files changed, 8 insertions, 1 deletions
diff --git a/demo/more/conference.ur b/demo/more/conference.ur
index 8f6dff2a..bf8e364a 100644
--- a/demo/more/conference.ur
+++ b/demo/more/conference.ur
@@ -16,6 +16,11 @@ signature INPUT = sig
table paper : ([Id = paperId, Document = blob] ++ paper)
PRIMARY KEY Id
+ con review :: {Type}
+ constraint [Paper, User] ~ review
+ table review : ([Paper = paperId, User = userId] ++ review)
+ PRIMARY KEY (Paper, User)
+
val checkLogin : transaction (option {Id : userId, Nam : string, Chair : bool, OnPc : bool})
val getLogin : transaction {Id : userId, Nam : string, Chair : bool, OnPc : bool}
val getPcLogin : transaction {Id : userId, Nam : string, Chair : bool}
@@ -63,7 +68,8 @@ functor Make(M : sig
val summarizePaper : ctx ::: {Unit} -> [[Body] ~ ctx] => $(map fst paper ++ paperPrivate)
-> xml ([Body] ++ ctx) [] []
- functor Make (M : INPUT where con paper = map fst paper ++ paperPrivate)
+ functor Make (M : INPUT where con paper = map fst paper ++ paperPrivate
+ where con review = map fst review)
: OUTPUT where con paper = map fst paper ++ paperPrivate
where con userId = M.userId
where con paperId = M.paperId
@@ -126,6 +132,7 @@ functor Make(M : sig
structure O = M.Make(struct
val user = user
val paper = paper
+ val review = review
val checkLogin = checkLogin
val getLogin = getLogin
val getPcLogin = getPcLogin