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
65b1dee9
Commit
65b1dee9
authored
Jul 22, 2016
by
Suma Shivaprasad
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ATLAS-1001 UI Paginate search APIs (kevalbhatt18 via sumasai)
parent
a10444d3
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
76 additions
and
11 deletions
+76
-11
AuditTableLayoutView_tmpl.html
.../public/js/templates/audit/AuditTableLayoutView_tmpl.html
+2
-2
SearchResultLayoutView_tmpl.html
...blic/js/templates/search/SearchResultLayoutView_tmpl.html
+14
-1
AuditTableLayoutView.js
dashboardv2/public/js/views/audit/AuditTableLayoutView.js
+1
-1
SearchResultLayoutView.js
dashboardv2/public/js/views/search/SearchResultLayoutView.js
+57
-6
release-log.txt
release-log.txt
+2
-1
No files found.
dashboardv2/public/js/templates/audit/AuditTableLayoutView_tmpl.html
View file @
65b1dee9
...
@@ -23,10 +23,10 @@
...
@@ -23,10 +23,10 @@
<div
id=
"r_auditTableLayoutView"
></div>
<div
id=
"r_auditTableLayoutView"
></div>
<ul
class=
"pager"
>
<ul
class=
"pager"
>
<li>
<li>
<button
data-id=
"previousAuditData"
>
Previous
</button>
<button
class=
"btn"
data-id=
"previousAuditData"
>
Previous
</button>
</li>
</li>
<li>
<li>
<button
data-id=
"nextAuditData"
>
Next
</button>
<button
class=
"btn"
data-id=
"nextAuditData"
>
Next
</button>
</li>
</li>
</ul>
</ul>
</div>
</div>
dashboardv2/public/js/templates/search/SearchResultLayoutView_tmpl.html
View file @
65b1dee9
...
@@ -19,5 +19,18 @@
...
@@ -19,5 +19,18 @@
<i
class=
"fa fa-refresh fa-spin-custom"
></i>
<i
class=
"fa fa-refresh fa-spin-custom"
></i>
</div>
</div>
<div
class=
"ellipsis"
><span
class=
"searchResult"
style=
" font-size: 16px;"
></span></div>
<div
class=
"ellipsis"
><span
class=
"searchResult"
style=
" font-size: 16px;"
></span></div>
<div
id=
"r_searchResultTableLayoutView"
class=
"searchTable"
></div>
<div
class=
"searchTable"
>
<div
id=
"r_searchResultTableLayoutView"
>
</div>
<div
data-id=
"paginationDiv"
style=
"display:none"
>
<ul
class=
"pager"
>
<li>
<button
class=
"btn"
data-id=
"previousData"
disabled=
true
>
Previous
</button>
</li>
<li>
<button
class=
"btn"
data-id=
"nextData"
>
Next
</button>
</li>
</ul>
</div>
</div>
</div>
</div>
dashboardv2/public/js/views/audit/AuditTableLayoutView.js
View file @
65b1dee9
...
@@ -101,12 +101,12 @@ define(['require',
...
@@ -101,12 +101,12 @@ define(['require',
that
.
$
(
'.auditTable'
).
show
();
that
.
$
(
'.auditTable'
).
show
();
options
.
previous
.
attr
(
'disabled'
,
true
);
options
.
previous
.
attr
(
'disabled'
,
true
);
if
(
that
.
entityCollection
.
models
.
length
<=
1
)
{
if
(
that
.
entityCollection
.
models
.
length
<=
1
)
{
that
.
pervOld
.
pop
();
options
.
next
.
attr
(
'disabled'
,
true
);
options
.
next
.
attr
(
'disabled'
,
true
);
}
}
if
(
that
.
entityCollection
.
models
.
length
==
1
&&
that
.
next
==
that
.
entityCollection
.
last
().
get
(
'eventKey'
))
{
if
(
that
.
entityCollection
.
models
.
length
==
1
&&
that
.
next
==
that
.
entityCollection
.
last
().
get
(
'eventKey'
))
{
options
.
next
.
attr
(
'disabled'
,
true
);
options
.
next
.
attr
(
'disabled'
,
true
);
options
.
previous
.
removeAttr
(
"disabled"
);
options
.
previous
.
removeAttr
(
"disabled"
);
that
.
entityCollection
.
reset
();
}
else
{
}
else
{
if
(
that
.
entityCollection
.
models
.
length
>
0
)
{
if
(
that
.
entityCollection
.
models
.
length
>
0
)
{
that
.
next
=
that
.
entityCollection
.
last
().
get
(
'eventKey'
);
that
.
next
=
that
.
entityCollection
.
last
().
get
(
'eventKey'
);
...
...
dashboardv2/public/js/views/search/SearchResultLayoutView.js
View file @
65b1dee9
...
@@ -50,7 +50,10 @@ define(['require',
...
@@ -50,7 +50,10 @@ define(['require',
addTag
:
'[data-id="addTag"]'
,
addTag
:
'[data-id="addTag"]'
,
addTerm
:
'[data-id="addTerm"]'
,
addTerm
:
'[data-id="addTerm"]'
,
showMoreLess
:
'[data-id="showMoreLess"]'
,
showMoreLess
:
'[data-id="showMoreLess"]'
,
showMoreLessTerm
:
'[data-id="showMoreLessTerm"]'
showMoreLessTerm
:
'[data-id="showMoreLessTerm"]'
,
paginationDiv
:
'[data-id="paginationDiv"]'
,
previousData
:
"[data-id='previousData']"
,
nextData
:
"[data-id='nextData']"
},
},
/** ui events hash */
/** ui events hash */
...
@@ -97,6 +100,8 @@ define(['require',
...
@@ -97,6 +100,8 @@ define(['require',
$
(
e
.
currentTarget
).
find
(
'span'
).
text
(
'Show less'
);
$
(
e
.
currentTarget
).
find
(
'span'
).
text
(
'Show less'
);
}
}
};
};
events
[
"click "
+
this
.
ui
.
nextData
]
=
"onClicknextData"
;
events
[
"click "
+
this
.
ui
.
previousData
]
=
"onClickpreviousData"
;
return
events
;
return
events
;
},
},
/**
/**
...
@@ -105,15 +110,22 @@ define(['require',
...
@@ -105,15 +110,22 @@ define(['require',
*/
*/
initialize
:
function
(
options
)
{
initialize
:
function
(
options
)
{
_
.
extend
(
this
,
_
.
pick
(
options
,
'globalVent'
,
'vent'
,
'value'
));
_
.
extend
(
this
,
_
.
pick
(
options
,
'globalVent'
,
'vent'
,
'value'
));
var
pagination
=
""
;
this
.
entityModel
=
new
VEntity
();
this
.
entityModel
=
new
VEntity
();
this
.
searchCollection
=
new
VSearchList
();
this
.
searchCollection
=
new
VSearchList
();
this
.
limit
=
25
;
this
.
fetchList
=
0
;
this
.
fetchList
=
0
;
if
(
options
.
value
.
searchType
==
"dsl"
)
{
pagination
=
false
;
}
else
{
pagination
=
true
;
}
this
.
commonTableOptions
=
{
this
.
commonTableOptions
=
{
collection
:
this
.
searchCollection
,
collection
:
this
.
searchCollection
,
includeFilter
:
false
,
includeFilter
:
false
,
includePagination
:
true
,
includePagination
:
pagination
,
includePageSize
:
false
,
includePageSize
:
false
,
includeFooterRecords
:
tru
e
,
includeFooterRecords
:
fals
e
,
includeSizeAbleColumns
:
false
,
includeSizeAbleColumns
:
false
,
gridOpts
:
{
gridOpts
:
{
emptyText
:
'No Record found!'
,
emptyText
:
'No Record found!'
,
...
@@ -162,7 +174,6 @@ define(['require',
...
@@ -162,7 +174,6 @@ define(['require',
},
this
);
},
this
);
},
},
onRender
:
function
()
{
onRender
:
function
()
{
//this.renderTableLayoutView();
var
value
=
{},
var
value
=
{},
that
=
this
;
that
=
this
;
if
(
this
.
value
)
{
if
(
this
.
value
)
{
...
@@ -171,7 +182,6 @@ define(['require',
...
@@ -171,7 +182,6 @@ define(['require',
value
=
{
value
=
{
'query'
:
''
,
'query'
:
''
,
'searchType'
:
'fulltext'
'searchType'
:
'fulltext'
};
};
}
}
this
.
fetchCollection
(
value
);
this
.
fetchCollection
(
value
);
...
@@ -193,14 +203,22 @@ define(['require',
...
@@ -193,14 +203,22 @@ define(['require',
if
(
Globals
.
searchApiCallRef
)
{
if
(
Globals
.
searchApiCallRef
)
{
Globals
.
searchApiCallRef
.
abort
();
Globals
.
searchApiCallRef
.
abort
();
}
}
$
.
extend
(
this
.
searchCollection
.
queryParams
,
{
limit
:
this
.
limit
});
if
(
value
)
{
if
(
value
)
{
if
(
value
.
searchType
)
{
if
(
value
.
searchType
)
{
this
.
searchCollection
.
url
=
"/api/atlas/discovery/search/"
+
value
.
searchType
;
this
.
searchCollection
.
url
=
"/api/atlas/discovery/search/"
+
value
.
searchType
;
if
(
value
.
searchType
===
"dsl"
)
{
$
.
extend
(
this
.
searchCollection
.
queryParams
,
{
limit
:
this
.
limit
});
this
.
offset
=
0
;
}
}
}
_
.
extend
(
this
.
searchCollection
.
queryParams
,
{
'query'
:
value
.
query
});
_
.
extend
(
this
.
searchCollection
.
queryParams
,
{
'query'
:
value
.
query
});
}
}
Globals
.
searchApiCallRef
=
this
.
searchCollection
.
fetch
({
Globals
.
searchApiCallRef
=
this
.
searchCollection
.
fetch
({
success
:
function
()
{
success
:
function
()
{
if
(
that
.
searchCollection
.
length
===
0
)
{
that
.
ui
.
nextData
.
attr
(
'disabled'
,
true
);
}
Globals
.
searchApiCallRef
=
undefined
;
Globals
.
searchApiCallRef
=
undefined
;
if
(
that
.
searchCollection
.
toJSON
().
length
==
0
)
{
if
(
that
.
searchCollection
.
toJSON
().
length
==
0
)
{
that
.
checkTableFetch
();
that
.
checkTableFetch
();
...
@@ -264,6 +282,11 @@ define(['require',
...
@@ -264,6 +282,11 @@ define(['require',
this
.
$
(
'.fontLoader'
).
hide
();
this
.
$
(
'.fontLoader'
).
hide
();
this
.
$
(
'.searchTable'
).
show
();
this
.
$
(
'.searchTable'
).
show
();
this
.
$
(
'.searchResult'
).
show
();
this
.
$
(
'.searchResult'
).
show
();
if
(
this
.
value
.
searchType
==
"dsl"
)
{
this
.
ui
.
paginationDiv
.
show
();
}
else
{
this
.
ui
.
paginationDiv
.
hide
();
}
}
}
},
},
getEntityTableColumns
:
function
()
{
getEntityTableColumns
:
function
()
{
...
@@ -555,7 +578,35 @@ define(['require',
...
@@ -555,7 +578,35 @@ define(['require',
that
.
fetchCollection
();
that
.
fetchCollection
();
}
}
});
});
}
},
onClicknextData
:
function
()
{
var
that
=
this
;
this
.
ui
.
previousData
.
removeAttr
(
"disabled"
);
$
.
extend
(
this
.
searchCollection
.
queryParams
,
{
offset
:
function
()
{
that
.
offset
=
that
.
offset
+
that
.
limit
;
return
that
.
offset
;
}
});
if
(
this
.
offset
>
this
.
limit
)
{
this
.
ui
.
nextData
.
attr
(
'disabled'
,
true
);
}
this
.
fetchCollection
();
},
onClickpreviousData
:
function
()
{
var
that
=
this
;
this
.
ui
.
nextData
.
removeAttr
(
"disabled"
);
$
.
extend
(
this
.
searchCollection
.
queryParams
,
{
offset
:
function
()
{
that
.
offset
=
that
.
offset
-
that
.
limit
;
return
that
.
offset
;
}
});
if
(
this
.
offset
<=
that
.
limit
)
{
this
.
ui
.
previousData
.
attr
(
'disabled'
,
true
);
}
this
.
fetchCollection
();
},
});
});
return
SearchResultLayoutView
;
return
SearchResultLayoutView
;
});
});
release-log.txt
View file @
65b1dee9
...
@@ -6,8 +6,9 @@ INCOMPATIBLE CHANGES:
...
@@ -6,8 +6,9 @@ INCOMPATIBLE CHANGES:
ALL CHANGES:
ALL CHANGES:
ATLAS-1001 UI Paginate search APIs (kevalbhatt18 via sumasai)
ATLAS-1042 Performance improvement changes for propertykey+typeName based queries (sumasai via shwethags)
ATLAS-1042 Performance improvement changes for propertykey+typeName based queries (sumasai via shwethags)
ATLAS-103
6
Multiple instances of AtlasPluginClassloader getting initialized (sumasai, mneethiraj)
ATLAS-103
8
Multiple instances of AtlasPluginClassloader getting initialized (sumasai, mneethiraj)
ATLAS-1033 fix for issues flagged by Coverity scan (mneethiraj via sumasai)
ATLAS-1033 fix for issues flagged by Coverity scan (mneethiraj via sumasai)
ATLAS-1036 Compilation error on java 1.8 - GraphBackedDiscoveryService (shwethags via sumasai)
ATLAS-1036 Compilation error on java 1.8 - GraphBackedDiscoveryService (shwethags via sumasai)
ATLAS-1034 Incorrect Falcon hook impl class name in Falcon hook shim (mneethiraj via shwethags)
ATLAS-1034 Incorrect Falcon hook impl class name in Falcon hook shim (mneethiraj via shwethags)
...
...
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