aboutsummaryrefslogtreecommitdiffstats
path: root/view/js/mod_photos.js
diff options
context:
space:
mode:
authorRedMatrix <info@friendica.com>2015-01-08 09:38:45 +1100
committerRedMatrix <info@friendica.com>2015-01-08 09:38:45 +1100
commit8771dee9cf90b9c8f76c1856ea7e5107aab5840e (patch)
tree0ab8af1ffb5a92962b2918e274cae26046897d11 /view/js/mod_photos.js
parenta373b9f1d4d0ee6781927c3fcf05e0e301a80b6e (diff)
parent7176eb88452b3c74652de09e44de41943051391c (diff)
downloadvolse-hubzilla-8771dee9cf90b9c8f76c1856ea7e5107aab5840e.tar.gz
volse-hubzilla-8771dee9cf90b9c8f76c1856ea7e5107aab5840e.tar.bz2
volse-hubzilla-8771dee9cf90b9c8f76c1856ea7e5107aab5840e.zip
Merge pull request #829 from pafcu/oneautocompleter
Steps towards a single autocompleter
Diffstat (limited to 'view/js/mod_photos.js')
-rw-r--r--view/js/mod_photos.js18
1 files changed, 5 insertions, 13 deletions
diff --git a/view/js/mod_photos.js b/view/js/mod_photos.js
index 0a64f8102..4c724c5e1 100644
--- a/view/js/mod_photos.js
+++ b/view/js/mod_photos.js
@@ -2,19 +2,11 @@
var ispublic = aStr['everybody'];
$(document).ready(function() {
-
- var a;
- a = $("#photo-edit-newtag").autocomplete({
- serviceUrl: baseurl + '/acl',
- minChars: 2,
- width: 250,
- id: 'newtag-ac',
- onSelect: function(value,data) {
- $("#photo-edit-newtag").val(data);
- },
- });
- a.setOptions({ params: { type: 'p' }});
-
+ $(document).ready(function() {
+ $("#photo-edit-newtag").contact_autocomplete(baseurl + '/acl', 'p', false, function(data) {
+ $("#photo-edit-newtag").val('@' + data.name.replace(' ','_')); // TODO: Get rid of underscore
+ });
+ });
$('#contact_allow, #contact_deny, #group_allow, #group_deny').change(function() {
var selstr;