Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
CIRCLE
/
cloud
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
94
Merge Requests
10
Pipelines
Wiki
Snippets
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
A prog2-höz tartozó friss repo anyagok itt elérhetőek:
https://git.iit.bme.hu/
Commit
4102bb64
authored
Jul 27, 2014
by
Bach Dániel
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/fix-autocomplete'
parents
4684a0a9
88a19949
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
19 additions
and
0 deletions
+19
-0
circle/dashboard/autocomplete_light_registry.py
+12
-0
circle/dashboard/templates/base.html
+7
-0
No files found.
circle/dashboard/autocomplete_light_registry.py
View file @
4102bb64
...
@@ -10,6 +10,18 @@ class AclUserAutocomplete(autocomplete_light.AutocompleteGenericBase):
...
@@ -10,6 +10,18 @@ class AclUserAutocomplete(autocomplete_light.AutocompleteGenericBase):
(
'^name'
,
'groupprofile__org_id'
),
(
'^name'
,
'groupprofile__org_id'
),
)
)
autocomplete_js_attributes
=
{
'placeholder'
:
_
(
"Name of group or user"
)}
autocomplete_js_attributes
=
{
'placeholder'
:
_
(
"Name of group or user"
)}
choice_html_format
=
u'<span data-value="
%
s"><span>
%
s</span>
%
s</span>'
def
choice_html
(
self
,
choice
):
try
:
name
=
choice
.
get_full_name
()
except
AttributeError
:
name
=
_
(
'group'
)
if
name
:
name
=
u'(
%
s)'
%
name
return
self
.
choice_html_format
%
(
self
.
choice_value
(
choice
),
self
.
choice_label
(
choice
),
name
)
def
choices_for_request
(
self
):
def
choices_for_request
(
self
):
user
=
self
.
request
.
user
user
=
self
.
request
.
user
...
...
circle/dashboard/templates/base.html
View file @
4102bb64
...
@@ -80,4 +80,11 @@
...
@@ -80,4 +80,11 @@
{% block extra_etc %}
{% block extra_etc %}
{% endblock %}
{% endblock %}
<script>
yourlabs
.
TextWidget
.
prototype
.
getValue
=
function
(
choice
)
{
return
choice
.
children
().
html
();
}
</script>
</html>
</html>
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment