Modify

Opened 16 years ago

Closed 12 years ago

#4832 closed enhancement (duplicate)

Add additional support for admistration user fields (like in permission)

Reported by: anonymous Owned by: Ryan J Ollos
Priority: normal Component: AutocompleteUsersPlugin
Severity: normal Keywords:
Cc: Sebastian Krysmanski Trac Release: 0.11

Description

it would be nice if the autocomplition for users where also available at the administration sites, like permissions and so on.

Attachments (0)

Change History (5)

comment:1 Changed 15 years ago by rupert thurner

Cc: Sebastian Krysmanski added; anonymous removed

what would be necessary to add this to SvnAuthzAdminPlugin, either add another field, or here:

<form id="addgroupmember" class="addnew" method="post"><div><input type="hidden" name="__FORM_TOKEN" value="2aabb428fff0de2c34c35b31" /></div>
 <input type="hidden" name="editgroup" value="mysvngroup" />
 <fieldset>
  <legend>Add Group Member to mysvngroup</legend>
  <div class="field">
   <label>Subject:
    <select name="subject">
     <option value="*">*</option><option value="rupert.thurner">rupert.thurner</option><option value="scott.james">scott.james</option><option value="@anothersvngroup">@anothersvngroup</option>

    </select>
   </label>
  </div>
  <p class="help">Add a new subject to a Subversion group.</p>
  <div class="buttons">
   <input type="submit" name="addgroupmember" value=" Add " />
  </div>
 </fieldset>

</form>

comment:2 Changed 15 years ago by Mario

Summary: Add additional support for admistration user fields (like in permission)Add

Added support for defaultcc plugin (admin section).

===================================================================
--- D:/trac/my_trac/plugins/autocomplete user/autocompleteusers/htdocs/js/autocomplete_admin_default_cc.js	(revision 0)
+++ D:/trac/my_trac/plugins/autocomplete user/autocompleteusers/htdocs/js/autocomplete_admin_default_cc.js	(revision 88)
@@ -0,0 +1,6 @@
+$(document).ready(function() {
+	$("#default-cc").autocomplete("../../../users", {
+		multiple: true,
+		    formatItem: formatItem});
+
+});
\ No newline at end of file
Index: D:/trac/my_trac/plugins/autocomplete user/autocompleteusers/autocompleteusers.py
===================================================================
--- D:/trac/my_trac/plugins/autocomplete user/autocompleteusers/autocompleteusers.py	(revision 87)
+++ D:/trac/my_trac/plugins/autocomplete user/autocompleteusers/autocompleteusers.py	(revision 88)
@@ -138,6 +138,14 @@
                 add_script(req, '%s/js/autocomplete_ticket_cc.js' % self.prefix)
                 if not restrict_owner:
                     add_script(req, '%s/js/autocomplete_ticket.js' % self.prefix)
+        if template =='admin_components.html':
+            add_stylesheet(req, '%s/css/autocomplete.css' % self.prefix)
+            add_script(req, '%s/js/autocomplete.js' % self.prefix)
+            restrict_owner = self.env.config.getbool('ticket', 'restrict_owner')
+            add_script(req, '%s/js/format_item.js' % self.prefix)
+            add_script(req, '%s/js/autocomplete_admin_default_cc.js' % self.prefix)
+
+
         return (template, data, content_type)
 
     def pre_process_request(self, req, handler):

changes for defaultcc plugin

===================================================================
--- D:/trac/my_trac/plugins/defaultcc/defaultcc/admin.py	(revision 89)
+++ D:/trac/my_trac/plugins/defaultcc/defaultcc/admin.py	(revision 90)
@@ -136,7 +136,7 @@
                 filter = Transformer('//form[@id="modcomp"]/fieldset/div[@class="buttons"]')
                 filter = filter.before(tag.div("Default CC:",
                                                tag.br(),
-                                               tag.input(type="text", name="defaultcc", value=cc.cc),
+                                               tag.input(type="text", id="default-cc",name="defaultcc", value=cc.cc),
                                                class_="field")) \
                                                .before(tag.input(type='hidden', name='old_name', value=cc.name))
                 return stream | filter
}}

greetings

comment:3 Changed 15 years ago by Mario

Summary: AddAdd additional support for admistration user fields (like in permission)

comment:4 Changed 14 years ago by Ryan J Ollos

Owner: changed from Jeff Hammel to Ryan J Ollos

Changing ticket owner to be new maintainer.

comment:5 Changed 12 years ago by Ryan J Ollos

Resolution: duplicate
Status: newclosed

Duplicate of #7324.

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain Ryan J Ollos.
The resolution will be deleted. Next status will be 'reopened'.

Add Comment


E-mail address and name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.