问题
In a dialog file like
dialog (Result) {
match: Content (this)
template("Welcome!")
}
where Content is an an answer set and the user proceeds from browsing the answer set to each detail page, how do I customize so that the dialog is different for each mode -- list, summary, detail?
I am looking to do something along the lines of if mode = Detail then template = Content.text
回答1:
You can add this setting to your capsule.bxb file.
runtime-version (2) {
overrides {
allow-dialogs-on-detail-pages (true)
}
}
In your result-view, you can define your details dialog in the message section. For example:
message {
// A single result?
if (size(this) == 1) {
template (Details Dialog!!!)
}
}
来源:https://stackoverflow.com/questions/60133932/how-do-i-customize-dialog-to-the-detail-page-of-an-answer-set