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
b6e5ab46
Commit
b6e5ab46
authored
Mar 04, 2015
by
Vishal Kadam
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Added error handling for search
parent
582c2294
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
9 additions
and
7 deletions
+9
-7
gruntfile.js
dashboard/dashboard-v2/gruntfile.js
+5
-5
notifications.html
...d-v2/public/modules/notification/views/notifications.html
+1
-1
searchController.js
...rd/dashboard-v2/public/modules/search/searchController.js
+3
-1
No files found.
dashboard/dashboard-v2/gruntfile.js
View file @
b6e5ab46
...
...
@@ -2,7 +2,7 @@
var
git
=
require
(
'git-rev'
);
module
.
exports
=
function
(
grunt
)
{
module
.
exports
=
function
(
grunt
)
{
var
classPathSep
=
(
process
.
platform
===
"win32"
)
?
';'
:
':'
,
gitHash
=
''
,
pkg
=
grunt
.
file
.
readJSON
(
'package.json'
);
...
...
@@ -114,7 +114,7 @@ module.exports = function (grunt) {
compress
:
{
release
:
{
options
:
{
archive
:
function
()
{
archive
:
function
()
{
return
[
pkg
.
name
,
pkg
.
version
,
gitHash
].
join
(
'_'
)
+
'.tgz'
;
}
},
...
...
@@ -131,16 +131,16 @@ module.exports = function (grunt) {
grunt
.
registerTask
(
'server:prod'
,
[
'nodemon:prod'
]);
grunt
.
registerTask
(
'server:prod'
,
[
'nodemon:prod'
]);
grunt
.
registerTask
(
'minify'
,
'Minify the all js'
,
function
()
{
grunt
.
registerTask
(
'minify'
,
'Minify the all js'
,
function
()
{
var
done
=
this
.
async
();
grunt
.
file
.
mkdir
(
'public/dist'
);
grunt
.
task
.
run
([
'shell:min'
]);
done
();
});
grunt
.
registerTask
(
'release'
,
'Create release package'
,
function
()
{
grunt
.
registerTask
(
'release'
,
'Create release package'
,
function
()
{
var
done
=
this
.
async
();
git
.
short
(
function
(
str
)
{
git
.
short
(
function
(
str
)
{
gitHash
=
str
;
grunt
.
task
.
run
([
'minify'
,
'compress:release'
]);
done
();
...
...
dashboard/dashboard-v2/public/modules/notification/views/notifications.html
View file @
b6e5ab46
<div
data-ng-controller=
"NotificationController"
>
<div
class=
"container"
data-ng-controller=
"NotificationController"
>
<alert
data-ng-repeat=
"notification in getNotifications()"
data-type=
"{{notification.type}}"
data-close=
"close(notification)"
>
{{notification.message}}
</alert>
...
...
dashboard/dashboard-v2/public/modules/search/searchController.js
View file @
b6e5ab46
...
...
@@ -8,7 +8,7 @@ angular.module('dgc.search').controller('SearchController', ['$scope', '$locatio
$scope
.
search
=
function
(
query
)
{
$scope
.
results
=
[];
NotificationService
.
reset
();
SearchResource
.
search
(
$location
.
search
(
query
).
search
(),
function
(
response
)
{
SearchResource
.
search
(
$location
.
search
(
query
).
search
(),
function
searchSuccess
(
response
)
{
$scope
.
results
=
response
;
if
(
$scope
.
results
.
length
<
1
)
{
NotificationService
.
error
(
'No Result found'
,
false
);
...
...
@@ -16,6 +16,8 @@ angular.module('dgc.search').controller('SearchController', ['$scope', '$locatio
$state
.
go
(
'search.results'
,
{},
{
location
:
false
});
},
function
searchError
(
err
)
{
NotificationService
.
error
(
'Error occurred during executing search query, error status code = '
+
err
.
status
+
', status text = '
+
err
.
statusText
,
false
);
});
};
...
...
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