aboutsummaryrefslogtreecommitdiffstats
path: root/view
diff options
context:
space:
mode:
Diffstat (limited to 'view')
-rw-r--r--view/js/autocomplete.js13
-rwxr-xr-xview/tpl/settings_features.tpl22
2 files changed, 34 insertions, 1 deletions
diff --git a/view/js/autocomplete.js b/view/js/autocomplete.js
index 07b9bc449..69ccd1fe5 100644
--- a/view/js/autocomplete.js
+++ b/view/js/autocomplete.js
@@ -243,8 +243,19 @@ function string2bb(element) {
replace: basic_replace,
template: contact_format,
};
+
+ // Autocomplete forums
+ forums = {
+ match: /(^\!)([^\n]{3,})$/,
+ index: 2,
+ search: function(term, callback) { contact_search(term, callback, backend_url, 'f', [], spinelement='#nav-search-spinner'); },
+ replace: basic_replace,
+ template: contact_format
+ };
+
+
this.attr('autocomplete', 'off');
- var a = this.textcomplete([contacts], {className:'acpopup', maxCount:100, zIndex: 1020, appendTo:'nav'});
+ var a = this.textcomplete([contacts,forums], {className:'acpopup', maxCount:100, zIndex: 1020, appendTo:'nav'});
a.on('textComplete:select', function(e, value, strategy) { submit_form(this); });
};
})( jQuery );
diff --git a/view/tpl/settings_features.tpl b/view/tpl/settings_features.tpl
index f8c162e17..998199c8e 100755
--- a/view/tpl/settings_features.tpl
+++ b/view/tpl/settings_features.tpl
@@ -1,9 +1,31 @@
+<script>
+ $(document).ready(function() {
+ $('#id_techlevel').change(function() {
+ var techlvl = $('#id_techlevel').val();
+ window.location.href='{{$baseurl}}/settings/features?f=&techlevel=' + techlvl;
+ });
+ });
+</script>
+
<div class="generic-content-wrapper">
<div class="section-title-wrapper">
<h2>{{$title}}</h2>
</div>
<form action="settings/features" method="post" autocomplete="off">
<input type='hidden' name='form_security_token' value='{{$form_security_token}}'>
+ {{if ! $techlock}}
+ <div class="section-content-tools-wrapper">
+ {{include file="field_select.tpl" field=$techlevel}}
+ </div>
+ {{else}}
+ <input type="hidden" name="techlevel" value="{{$techlevel.2}}" />
+ {{/if}}
+
+ {{if $hiddens}}
+ {{foreach $hiddens as $k => $v}}
+ <input type="hidden" name="feature_{{$k}}" value="{{$v}}" />
+ {{/foreach}}
+ {{/if}}
<div class="panel-group" id="settings" role="tablist" aria-multiselectable="true">
{{foreach $features as $g => $f}}
<div class="panel">