Toggle navigation
Toggle navigation
This project
Loading...
Sign in
Зуев Егор
/
wiki.dev
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Snippets
Network
Create a new issue
Commits
Issue Boards
Files
Commits
Network
Compare
Branches
Tags
Authored by
Dan Brown
2017-04-09 21:12:13 +0100
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
Commit
46f3d78c8a9b8aa25c43d2449eb78e949d1dcc7e
46f3d78c
1 parent
1338ae2f
Fixed entity type filter bug in new search system
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
8 additions
and
8 deletions
app/Services/SearchService.php
resources/assets/js/vues/search.js
resources/views/search/all.blade.php
app/Services/SearchService.php
View file @
46f3d78
...
...
@@ -175,7 +175,7 @@ class SearchService
// Split filter values out
$splitFilters
=
[];
foreach
(
$terms
[
'filters'
]
as
$filter
)
{
$explodedFilter
=
explode
(
':'
,
$filter
,
1
);
$explodedFilter
=
explode
(
':'
,
$filter
,
2
);
$splitFilters
[
$explodedFilter
[
0
]]
=
(
count
(
$explodedFilter
)
>
1
)
?
$explodedFilter
[
1
]
:
''
;
}
$terms
[
'filters'
]
=
$splitFilters
;
...
...
resources/assets/js/vues/search.js
View file @
46f3d78
...
...
@@ -53,6 +53,10 @@ let methods = {
return
;
}
this
.
appendTerm
(
typeTerm
);
},
updateSearch
()
{
window
.
location
=
'/search?term='
+
encodeURIComponent
(
this
.
termString
);
}
};
...
...
resources/views/search/all.blade.php
View file @
46f3d78
...
...
@@ -40,6 +40,9 @@
<label><input
type=
"checkbox"
v-on:change=
"typeChange"
v-model=
"search.type.book"
value=
"book"
>
Book
</label>
</div>
<button
type=
"button"
class=
"button pos"
v-on:click=
"updateSearch"
>
Update Search
</button>
</div>
</div>
...
...
@@ -48,11 +51,4 @@
</div>
</div>
@stop
@section('scripts')
<script>
</script>
@stop
\ No newline at end of file
...
...
Please
register
or
sign in
to post a comment