A button is provided in the report designer detail band that, when clicked, should add new panels immediately before and after the detail panel.
$parentpanel = $this.parents(".designer-panel:first");
This code snippet is used to locate the parent panel using jQuery and then use .prepend() / .append() to add new panels as child elements of the Detail panel.
The goal is to add panels before and after the Detail panel at the same DOM level, similar to how group header and footer panels are structured in the sample HTML provided.
To achieve this, it is suggested to add the new elements to $parentpanel.parent()
element list before and after the $parentpanel
element.
Are there any specific selectors or append commands in jQuery that can facilitate this process?
$(function() {
// jQuery functions for adding panels dynamically
});
.panel-resizable {
/* CSS styling properties */
}
.designer-field {
/* CSS styling properties */
}
/* Additional CSS rules */
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/css/bootstrap.min.css">
<link rel="stylesheet" href="http://code.jquery.com/ui/1.11.4/themes/smoothness/jquery-ui.css">
<script src="http://code.jquery.com/jquery-1.11.3.min.js"></script>
<script src="http://code.jquery.com/ui/1.11.4/jquery-ui.js"></script>
<body>
<!-- Sample HTML structure -->