Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
U
ulakbus-ui
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
ulakbus
ulakbus-ui
Commits
915ef261
Commit
915ef261
authored
Jun 23, 2016
by
Evren Kutar
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
typeahead custom search fix
parent
7281efe5
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
5 deletions
+8
-5
typeahead.html
app/shared/templates/typeahead.html
+1
-1
form_service.js
app/zetalib/form_service.js
+7
-4
No files found.
app/shared/templates/typeahead.html
View file @
915ef261
...
...
@@ -24,7 +24,7 @@
type=
"text"
autocomplete=
"off"
ng-model=
"$$value$$"
uib-typeahead=
"item as item.name for item in getTitleMap($viewValue)"
uib-typeahead=
"item as item.name for item in
form.
getTitleMap($viewValue)"
typeahead-wait-ms=
"500"
typeahead-loading=
"loadingTitleMap"
typeahead-on-select=
"form.onDropdownSelect($item, form.name)"
...
...
app/zetalib/form_service.js
View file @
915ef261
...
...
@@ -778,13 +778,16 @@ angular.module('ulakbus.formService', ['ui.bootstrap'])
scope
.
form
[
scope
.
form
.
indexOf
(
k
)]
=
{
type
:
"template"
,
title
:
v
.
title
,
widget
:
v
.
widget
,
getTitleMap
:
function
(
viewValue
)
{
// v.view is where that value will looked up
var
searchData
=
{
"url"
:
v
.
wf
,
"wf"
:
v
.
wf
,
"view"
:
v
.
view
,
"query"
:
viewValue
"form_params"
:
{
"url"
:
v
.
wf
,
"wf"
:
v
.
wf
,
"view"
:
v
.
view
,
"query"
:
viewValue
}
};
generator
.
get_list
(
searchData
).
then
(
function
(
res
)
{
// response must be in titleMap format
...
...
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