From 16836bf2833c792693fff8333269b25d6465dc04 Mon Sep 17 00:00:00 2001 From: Uwe Steinmann Date: Thu, 22 Oct 2020 12:30:49 +0200 Subject: [PATCH] add new methods getModelBox() and getModelBoxLink() --- views/bootstrap/class.Bootstrap.php | 47 +++++++++++++++++++++++++++++ 1 file changed, 47 insertions(+) diff --git a/views/bootstrap/class.Bootstrap.php b/views/bootstrap/class.Bootstrap.php index 2b4bfd4e5..84c58d331 100644 --- a/views/bootstrap/class.Bootstrap.php +++ b/views/bootstrap/class.Bootstrap.php @@ -1089,6 +1089,53 @@ background-image: linear-gradient(to bottom, #882222, #111111);; } } /* }}} */ + /** + * Get html for button opening a modal box + * + * @param array $config contains elements + * target: id of modal box + * remote: URL of data to be loaded into box + * title: text on button + * @return string + */ + function getModalBoxLink($config) { /* {{{ */ + $content = ''; + $content .= "".$config['title']."…\n"; + return $content; + } /* }}} */ + + /** + * Get html for a modal box with buttons + * + * @param array $config contains elements + * id: id of modal box (must match target of getModalBoxLink()) + * title: title of modal box + * buttons: array of buttons, each having a title and an optional id + * @return string + */ + function getModalBox($config) { /* {{{ */ + $content = ' + +'; + return $content; + } /* }}} */ + function printFileChooserJs() { /* {{{ */ ?> $(document).ready(function() {