PluginProbe
VikBooking Hotel Booking Engine & PMS / 1.8.16
VikBooking Hotel Booking Engine & PMS v1.8.16
1.8.16 1.8.15 1.8.14 1.8.13 1.8.12 1.8.11 1.8.10 1.8.9 1.8.6 1.8.7 1.8.8 trunk 1.6.0 1.6.1 1.6.2 1.6.3 1.6.4 1.6.5 1.6.6 1.6.7 1.6.8 1.6.9 1.7.0 1.7.1 1.7.2 All 37 releases
← All changes | admin/layouts/reports/report/settings.php +42 -0 1.7.2 → 1.8.16 View file →
@@ -29,8 +29,50 @@
29 29 <div class="vbo-admin-container vbo-admin-container-full vbo-admin-container-compact">
30 30 <div class="vbo-params-wrap">
31 31 <div class="vbo-params-container">
32 32
33 + <?php
34 + /**
35 + * Handle multiple report profile settings.
36 + *
37 + * @since 1.17.7 (J) - 1.7.7 (WP)
38 + */
39 + if ($instance->allowsProfileSettings()) {
40 + // load all the existing profiles
41 + $report_profiles = $instance->getSettingProfiles();
42 +
43 + // load the active profile
44 + $active_profile = $instance->getActiveProfile();
45 +
46 + // get the active profile name
47 + $profile_name = $active_profile ? ($report_profiles[$active_profile] ?? JText::translate('VBO_USE_DEFAULT')) : JText::translate('VBO_USE_DEFAULT');
48 +
49 + ?>
50 + <div class="vbo-params-block">
51 +
52 + <div class="vbo-param-container">
53 + <div class="vbo-param-label"><?php echo JText::translate('VBO_PROFILE_SETTINGS'); ?></div>
54 + <div class="vbo-param-setting">
55 + <select name="_profile" onchange="VBOCore.emitEvent('vbo-report-settings-profile-changed', {value: this.value});">
56 + <option value="<?php echo JHtml::fetch('esc_attr', $active_profile); ?>"><?php echo $profile_name; ?></option>
57 + <option value="_new"><?php echo JText::translate('VBO_PROFILE_NEW'); ?></option>
58 + </select>
59 + <span class="vbo-param-setting-comment"><?php echo JText::translate('VBO_PROFILE_SETTINGS_HELP'); ?></span>
60 + </div>
61 + </div>
62 +
63 + <div class="vbo-param-container" data-profile="_new" style="display: none;">
64 + <div class="vbo-param-label"><?php echo JText::translate('VBO_PROFILE_NAME'); ?></div>
65 + <div class="vbo-param-setting">
66 + <input type="text" name="_newprofile" value="" maxlength="64" />
67 + </div>
68 + </div>
69 +
70 + </div>
71 + <?php
72 + }
73 + ?>
74 +
33 75 <div class="vbo-params-block">
34 76
35 77 <?php
36 78 // render the report custom settings