Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
atlas
Project
Overview
Details
Activity
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
dataplatform
atlas
Commits
94ed0809
Commit
94ed0809
authored
May 26, 2015
by
dileep bhimineni
Committed by
Vishal Kadam
May 29, 2015
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
changes for my tracking purpose
parent
208b2bf1
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
37 additions
and
2 deletions
+37
-2
common.css
dashboard/v2/public/css/common.css
+19
-0
searchController.js
dashboard/v2/public/modules/search/searchController.js
+10
-0
searchResult.html
dashboard/v2/public/modules/search/views/searchResult.html
+8
-2
No files found.
dashboard/v2/public/css/common.css
View file @
94ed0809
...
@@ -89,3 +89,22 @@ footer.navbar-bottom img {
...
@@ -89,3 +89,22 @@ footer.navbar-bottom img {
padding-left
:
5px
;
padding-left
:
5px
;
margin-top
:
-21px
;
margin-top
:
-21px
;
}
}
.searchresults
{
border
:
1px
solid
#ddd
;
padding
:
10px
;
}
.mt10px
{
margin-top
:
10px
;
}
.searchresults
:first-child
{
border-top-right-radius
:
4px
;
border-top-left-radius
:
4px
;
}
.searchresults
:last-child
{
margin-bottom
:
0
;
border-bottom-right-radius
:
4px
;
border-bottom-left-radius
:
4px
;
}
dashboard/v2/public/modules/search/searchController.js
View file @
94ed0809
...
@@ -45,6 +45,16 @@ angular.module('dgc.search').controller('SearchController', ['$scope', '$locatio
...
@@ -45,6 +45,16 @@ angular.module('dgc.search').controller('SearchController', ['$scope', '$locatio
return
$scope
.
types
.
indexOf
(
this
.
results
.
dataType
.
typeName
&&
this
.
results
.
dataType
.
typeName
.
toLowerCase
())
>
-
1
;
return
$scope
.
types
.
indexOf
(
this
.
results
.
dataType
.
typeName
&&
this
.
results
.
dataType
.
typeName
.
toLowerCase
())
>
-
1
;
};
};
$scope
.
filterSearchResults
=
function
(
items
)
{
var
res
=
{};
angular
.
forEach
(
items
,
function
(
value
,
key
)
{
if
(
!
(
typeof
value
==
'object'
))
res
[
key
]
=
value
+
','
;
});
return
res
;
}
$scope
.
query
=
$stateParams
.
query
;
$scope
.
query
=
$stateParams
.
query
;
if
(
$scope
.
query
)
{
if
(
$scope
.
query
)
{
$scope
.
search
(
$scope
.
query
);
$scope
.
search
(
$scope
.
query
);
...
...
dashboard/v2/public/modules/search/views/searchResult.html
View file @
94ed0809
...
@@ -18,8 +18,13 @@
...
@@ -18,8 +18,13 @@
<h4>
{{resultCount}} results matching your search query "{{query}}" were found
</h4>
<h4>
{{resultCount}} results matching your search query "{{query}}" were found
</h4>
<ul
class=
"list-unstyled"
>
<ul
class=
"list-unstyled"
>
<li
ng-repeat=
"result in results.rows"
>
<li
ng-repeat=
"result in results.rows"
class=
"searchresults"
>
<div
data-ng-if=
"typeAvailable()"
data-ng-include=
"'/modules/search/views/types/'+results.dataType.typeName.toLowerCase()+'.html'"
></div>
<div
data-ng-if=
"typeAvailable()"
>
<h4><a
data-ui-sref=
"details({id:result['$id$'].id})"
>
{{result.name}}
</a></h4>
<p>
{{result.description}}
</p>
<span
ng-repeat=
"(key, value) in filterSearchResults(result)"
><span
ng-show=
"$index < 4"
><b>
{{key}}:
</b>
{{value}}
</span></span><a
data-ui-sref=
"details({id:result.guid})"
>
..show more
</a>
<h5>
Tags :
<a
ng-repeat=
"(key, value) in result['$traits$']"
data-ui-sref=
"search.results({query: key})"
>
{{key}}
</a>
</h5>
</div>
<div
data-ng-if=
"!typeAvailable()"
data-ng-include=
"'/modules/search/views/types/guid.html'"
></div>
<div
data-ng-if=
"!typeAvailable()"
data-ng-include=
"'/modules/search/views/types/guid.html'"
></div>
</li>
</li>
</ul>
</ul>
\ No newline at end of file
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